Skip to main content

extension-ui-reference

Reference guide for comparing cc-office UI against the real Claude Code VS Code Extension via live MCP debugmcp inspection. Use when building or redesigning UI components, aligning visuals with the extension, creating OpenSpec changes for UI alignment, or unsure what the extension renders for a given element.

설치로 이동

소스 정보

저장소
recca0120/code-quest
최근 소스 활동
2026년 4월 19일 22:05
감지된 SKILL.md 언어
영어
스타
11
포크
2

설치 방법

기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.

소스 파일 검토

설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.

SKILL.md 표시 중

SKILL.md
소스 지침 · 읽기 전용 미리보기
name
extension-ui-reference
description
Reference guide for comparing cc-office UI against the real Claude Code VS Code Extension via live MCP debugmcp inspection. Use when building or redesigning UI components, aligning visuals with the extension, creating OpenSpec changes for UI alignment, or unsure what the extension renders for a given element.
# Extension UI Reference — Live Inspection with MCP ## Extension Folder ``` /Users/user/Desktop/anthropic.claude-code-2.1.45-darwin-arm64/ ├── src/ │ ├── core/main.js ← 核心邏輯(~70k 行,可讀性高,首選) │ ├── core/runtime.js ← esbuild helper │ ├── modules/ ← 第三方 npm 模組(210 個) │ └── module-map.json ← 模組索引 ├── extension.js ← bundled(94k 行,備案,不優先讀) ├── webview/index.js ← webview React app (compiled) └── .vscode/ └── launch.json ← "Run Extension" debug config ``` **讀程式碼時以 `src/core/main.js` 為主,`extension.js` 為備案。** `src/core/main.js` 經過 webcrack + prettier + normalize,class/method 名保留,可讀性遠高於 bundled extension.js。 ## Step 1: Launch Extension in Debug Mode Use MCP debugmcp `start_debugging` to launch the extension: ``` tool: start_debugging fileFullPath: /Users/user/Desktop/anthropic.claude-code-2.1.45-darwin-arm64/extension.js workingDirectory: /Users/user/Desktop/anthropic.claude-code-2.1.45-darwin-arm64 configurationName: Run Extension ``` This opens a new VS Code Extension Development Host window with the Claude Code UI. ## Step 2: Inspect the Live UI ### Option A — VS Code Developer Tools (visual inspection) In the Extension Development Host window: 1. **Help → Toggle Developer Tools** (opens Chromium DevTools) 2. Use **Element Inspector** to click any UI element and see its CSS classes and computed styles 3. Look for class patterns like `camelCase_randomHash` (e.g., `menuPopup_pZbgXw`, `fileItem_pZbgXw`) 4. Check the **Styles** panel for actual computed CSS values ### Option B — evaluate_expression (programmatic) After `start_debugging`, use `evaluate_expression` to query the extension host context. To inspect webview content (if accessible from extension host): ```javascript // Get computed styles of a specific element getComputedStyle(document.querySelector('.menuPopup_pZbgXw')) ``` ## Step 3: Map Extension CSS → cc-office Design Tokens | Extension CSS Variable | cc-office Token / Class | |---|---| | `--app-menu-background` | `bg-surface` | | `--app-input-border` | `border-border` | | `--app-primary-foreground` | `text-text` | | `--app-secondary-foreground` | `text-text-muted` | | `--app-list-active-background` | `hover:bg-white/5` | | `--corner-radius-large` (8px) | `rounded-lg` | | `--app-list-border-radius` (4px) | `rounded` | | `--app-list-item-padding` (4px 8px) | `py-1 px-2` | | `--app-monospace-font-family` | `font-mono` | ## Step 4: Implement in cc-office After inspecting the live UI: 1. Map extension layout → Tailwind classes using the token table above 2. For custom effects (animations, scrollbars) → add as `@utility` in `App.css` 3. **Never install packages** — `scrollbar-thin`, `fadeIn`, `slideUp` already defined in `App.css` ## Key UI Patterns (from live inspection) ### @ Mention File Picker Trigger by typing `@` in the Claude input box and observe in DevTools: - Container: `position:absolute; bottom:100%; left:0; right:0` inside input wrapper - Background: surface color, 1px border, 8px border-radius - Max height: ~300px, `overflow-y:auto` - Animation: `fadeIn 0.15s ease-out` - File items: flex row — icon (20×20, opacity 0.6) + monospace path text ### Slash Action Menu Trigger by typing `/` in the input: - Same popup container style as @ mention - Filter input at top separated by `border-bottom` - Sections with small uppercase headers: Context / Model / Customize / Slash Commands ### Input Footer Observe the bottom bar: - `display:flex; align-items:center; gap:6px; padding:5px` - Left: permission mode label | context % usage - Right: model name | attach 📎 | / menu | send ↑ ## Scrollbar Already defined in `App.css` — no package needed: ``` className="overflow-y-auto scrollbar-thin" ```
GitHub에서 보기