Skip to content

feat(desktop): ブラウザペインに Inspect Element を追加#23

Merged
MocA-Love merged 2 commits intomainfrom
feat/desktop-inspect-element
Mar 29, 2026
Merged

feat(desktop): ブラウザペインに Inspect Element を追加#23
MocA-Love merged 2 commits intomainfrom
feat/desktop-inspect-element

Conversation

@MocA-Love
Copy link
Copy Markdown
Owner

@MocA-Love MocA-Love commented Mar 29, 2026

Summary

  • ブラウザペイン(webview)の右クリックメニューに「Inspect Element」を追加
  • クリック位置の要素を直接 DevTools でインスペクト可能に
  • Chrome の「検証」と同等の機能を提供

Changes

  • apps/desktop/src/main/lib/browser/browser-manager.ts: コンテキストメニューに wc.inspectElement(x, y) を呼ぶメニュー項目を追加

Test plan

  • ブラウザペインで右クリック → 「Inspect Element」が表示される
  • クリックすると DevTools が開き、該当要素がハイライトされる
  • DevTools が既に開いている場合も正しく動作する

Summary by CodeRabbit

  • New Features
    • Extended the browser pane's right-click context menu with an "Inspect Element" option, enabling users to quickly inspect HTML elements and their properties directly within Developer Tools.

webviewのコンテキストメニューにDevTools検証機能を追加し、
右クリック位置の要素を直接インスペクトできるようにした。
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Mar 29, 2026

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 7a4c54a8-c3fb-4e99-a690-40a6c8aa32fc

📥 Commits

Reviewing files that changed from the base of the PR and between ba7ce3d and 87010a5.

📒 Files selected for processing (2)
  • README.md
  • apps/desktop/src/main/lib/browser/browser-manager.ts

📝 Walkthrough

Walkthrough

This change introduces an "Inspect Element" feature to the browser's right-click context menu. A new menu item is added that captures the click coordinates and passes them to an inspectElement method, enabling direct element inspection in DevTools. The change is documented in the README's changelog.

Changes

Cohort / File(s) Summary
Documentation
README.md
Added a changelog entry documenting the new "Inspect Element" fork-specific feature for right-click context menu integration.
Feature Implementation
apps/desktop/src/main/lib/browser/browser-manager.ts
Appended a context menu separator and "Inspect Element" menu item to setupContextMenu, which invokes wc.inspectElement() with click coordinates from Electron.ContextMenuParams.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

Poem

🐰 A click, a whisper, coordinates fly,
DevTools opens to inspect on high,
Right-click magic in the browser's hand,
Elements revealed at our command!
Simple yet swift, this feature so dear,
Hop along, the inspect is here! 🔍

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/desktop-inspect-element

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@MocA-Love MocA-Love self-assigned this Mar 29, 2026
@MocA-Love MocA-Love marked this pull request as ready for review March 29, 2026 17:21
@MocA-Love MocA-Love merged commit ecd6b43 into main Mar 29, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant