feat(desktop): Chrome Web Store拡張機能インストール + ツールバーUI#20
Conversation
- ExtensionPopupManager: フレームレスBrowserWindowでpopup.htmlを表示 - chrome-extension:// URLでロード、同一session partitionで通信自動対応 - enablePreferredSizeModeによる自動サイズ調整 - blurイベントで自動クローズ、同時1つのみ排他制御 - アイコン直下に配置、画面端クランプ対応 - extension-icon-protocol: superset-ext-icon:// プロトコルでアイコン画像配信 - ExtensionToolbar/ExtensionIcon: BrowserPaneツールバーに拡張アイコン表示 - tRPC: listToolbarExtensions/openPopup/closePopup エンドポイント追加 - 互換性チェッカーからpopup "unsupported" 警告を削除
- sandbox: true が chrome-extension:// プロトコルをブロックしていた問題を修正 - chrome-extension:// ロード失敗時に file:// からの直接ロードにフォールバック - 未使用変数を削除
ダークモード時に白文字が白背景で見えなくなる問題を修正。 nativeTheme.shouldUseDarkColors に合わせて背景色を設定。
CRX展開時にmanifestのkeyフィールドが失われるため、Electronが Chrome Web Store IDとは異なるIDを割り当てる。loadExtension()の 戻り値からelectronIdを取得・永続化し、popup URLに使用するよう修正。
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 8 minutes and 18 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (15)
✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
Summary
Changes
Chrome Web Store インストール基盤
crx-downloader.ts- CRXダウンロード、CRX2/CRX3ヘッダー除去、JSZipで展開compatibility-checker.ts- manifest解析 + JSコードスキャンによるElectron互換性判定extension-manager.ts- インストール/アンインストール/有効無効切替/永続化 + Electron割当ID管理settings/extensions/- Extensions設定ページ(インストールフォーム + 拡張一覧)ツールバーUI(アイコン + ポップアップ)
extension-popup-manager.ts- フレームレスBrowserWindowでpopup.htmlを表示chrome-extension://URLでロード(同一session partitionでchrome.runtime.sendMessage自動対応)enablePreferredSizeModeによる自動サイズ調整extension-icon-protocol.ts-superset-ext-icon://プロトコルでアイコン画像配信ExtensionToolbar/ExtensionIcon- BrowserPaneツールバーにアイコン表示listToolbarExtensions/openPopup/closePopupエンドポイント既存ファイルへの変更(最小限)
routers/index.ts- extensionsルーターにgetWindow渡し(1行変更)main/index.ts- プロトコル登録 + loadInstalledExtensions(+17行)BrowserPane.tsx- ExtensionToolbar配置(+2行)Design decisions
electron-chrome-extensionsを使わず、Electron標準APIのみで実装loadExtension()の戻り値からElectron IDを取得・永続化してchrome-extension://URLに使用Known limitations
Test plan