cc-viewer 1.6.205 → 1.6.206

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/README.md +15 -49
  2. package/cli.js +3 -1
  3. package/dist/assets/{App-BTjeN9V9.js → App-1EBXFSaQ.js} +1 -1
  4. package/dist/assets/{AppHeader.module-DoWoVI_4.js → AppHeader.module-BIXYwV2k.js} +2 -2
  5. package/dist/assets/{Mobile-CNYUcZow.js → Mobile-B2g25XyH.js} +1 -1
  6. package/dist/assets/{_baseUniq-2rspTRM1.js → _baseUniq-DM-jh9fR.js} +1 -1
  7. package/dist/assets/{arc-CkKce3YH.js → arc-DLfV_ywp.js} +1 -1
  8. package/dist/assets/{architectureDiagram-Q4EWVU46-DZ5gqhfT.js → architectureDiagram-Q4EWVU46-i_Y5Sr7z.js} +1 -1
  9. package/dist/assets/{blockDiagram-DXYQGD6D-BSGF28v_.js → blockDiagram-DXYQGD6D-DWySD37i.js} +1 -1
  10. package/dist/assets/{c4Diagram-AHTNJAMY-Bv0DOcHS.js → c4Diagram-AHTNJAMY-CjFkhoZV.js} +1 -1
  11. package/dist/assets/{channel-D9_F4M5H.js → channel-cy8PPAbu.js} +1 -1
  12. package/dist/assets/{chunk-4BX2VUAB-CmQ3fXKy.js → chunk-4BX2VUAB-AQTkeZ-_.js} +1 -1
  13. package/dist/assets/{chunk-4TB4RGXK-Dx-u1umf.js → chunk-4TB4RGXK-D7r0wR4D.js} +1 -1
  14. package/dist/assets/{chunk-55IACEB6-BU-37oI-.js → chunk-55IACEB6-D5aPAM7a.js} +1 -1
  15. package/dist/assets/{chunk-EDXVE4YY-V4qo8M7X.js → chunk-EDXVE4YY-o363fQzV.js} +1 -1
  16. package/dist/assets/{chunk-FMBD7UC4-CtbiQMb_.js → chunk-FMBD7UC4-BEvXbVcn.js} +1 -1
  17. package/dist/assets/{chunk-OYMX7WX6-DMcB2Igk.js → chunk-OYMX7WX6-DCKiPSja.js} +1 -1
  18. package/dist/assets/{chunk-QZHKN3VN-C5YAFQCC.js → chunk-QZHKN3VN-Bdp_HL-0.js} +1 -1
  19. package/dist/assets/{chunk-YZCP3GAM-CeCyCLmu.js → chunk-YZCP3GAM-CjBcP8g6.js} +1 -1
  20. package/dist/assets/classDiagram-6PBFFD2Q-CM-MQBqn.js +1 -0
  21. package/dist/assets/classDiagram-v2-HSJHXN6E-CM-MQBqn.js +1 -0
  22. package/dist/assets/clone-Bvoiky9_.js +1 -0
  23. package/dist/assets/{cose-bilkent-S5V4N54A-Vb8gMs5M.js → cose-bilkent-S5V4N54A-C-8wthYD.js} +1 -1
  24. package/dist/assets/{dagre-KV5264BT-Dw5lr4LF.js → dagre-KV5264BT-BuRkfp24.js} +1 -1
  25. package/dist/assets/{diagram-5BDNPKRD-Crm-6e2T.js → diagram-5BDNPKRD-ZBcE2u0G.js} +1 -1
  26. package/dist/assets/{diagram-G4DWMVQ6-C5VKs9jR.js → diagram-G4DWMVQ6-CquZuRrl.js} +1 -1
  27. package/dist/assets/{diagram-MMDJMWI5-ByW2uRek.js → diagram-MMDJMWI5-CKTIA2qn.js} +1 -1
  28. package/dist/assets/{diagram-TYMM5635-DGZpotfJ.js → diagram-TYMM5635-B1yPui9V.js} +1 -1
  29. package/dist/assets/{erDiagram-SMLLAGMA-D_VT1HKf.js → erDiagram-SMLLAGMA-CrGWmoQf.js} +1 -1
  30. package/dist/assets/{flowDiagram-DWJPFMVM-DmTXO3g7.js → flowDiagram-DWJPFMVM-B5QAn02v.js} +1 -1
  31. package/dist/assets/{ganttDiagram-T4ZO3ILL-C2hVdQSW.js → ganttDiagram-T4ZO3ILL-Co1keQwV.js} +1 -1
  32. package/dist/assets/{gitGraphDiagram-UUTBAWPF-CunALLEY.js → gitGraphDiagram-UUTBAWPF-B4oAtvQj.js} +1 -1
  33. package/dist/assets/{graph-gDEcyhy6.js → graph-Cwe-8dju.js} +1 -1
  34. package/dist/assets/{index-DCPatXd8.js → index-DwsF2mS0.js} +2 -2
  35. package/dist/assets/{infoDiagram-42DDH7IO-DhSX7nf5.js → infoDiagram-42DDH7IO-DQ_wjoV2.js} +1 -1
  36. package/dist/assets/{ishikawaDiagram-UXIWVN3A-XuRZi2h-.js → ishikawaDiagram-UXIWVN3A-DU_qWigx.js} +1 -1
  37. package/dist/assets/{journeyDiagram-VCZTEJTY-CzUtUYAB.js → journeyDiagram-VCZTEJTY-ZmWOa1tO.js} +1 -1
  38. package/dist/assets/{kanban-definition-6JOO6SKY-B7l60mHZ.js → kanban-definition-6JOO6SKY-QbnykpM4.js} +1 -1
  39. package/dist/assets/{layout-CASNtMcd.js → layout-CTKhjB2Y.js} +1 -1
  40. package/dist/assets/{linear-Dop4emwb.js → linear-DI7qeQYx.js} +1 -1
  41. package/dist/assets/{mermaid.core-CzELgf-b.js → mermaid.core-B-unhfOP.js} +2 -2
  42. package/dist/assets/{min-DrpXrLeV.js → min-C8481a9I.js} +1 -1
  43. package/dist/assets/{mindmap-definition-QFDTVHPH-1hhXLxLE.js → mindmap-definition-QFDTVHPH-1T8owtGC.js} +1 -1
  44. package/dist/assets/{pieDiagram-DEJITSTG-BpvsqwgD.js → pieDiagram-DEJITSTG-BT2wN0BL.js} +1 -1
  45. package/dist/assets/{quadrantDiagram-34T5L4WZ-snHPyXO1.js → quadrantDiagram-34T5L4WZ-C94BP1nv.js} +1 -1
  46. package/dist/assets/{requirementDiagram-MS252O5E-BERvVcfD.js → requirementDiagram-MS252O5E-4XgSHkEz.js} +1 -1
  47. package/dist/assets/{sankeyDiagram-XADWPNL6-Fb4kSdbJ.js → sankeyDiagram-XADWPNL6-m6WqYCxs.js} +1 -1
  48. package/dist/assets/{sequenceDiagram-FGHM5R23-CvxI3cu9.js → sequenceDiagram-FGHM5R23-Wzo7qG0c.js} +1 -1
  49. package/dist/assets/{stateDiagram-FHFEXIEX-CqGeIZxq.js → stateDiagram-FHFEXIEX-CtCVtBPI.js} +1 -1
  50. package/dist/assets/{stateDiagram-v2-QKLJ7IA2-CZEsDgEA.js → stateDiagram-v2-QKLJ7IA2-BvxQU8Lz.js} +1 -1
  51. package/dist/assets/{timeline-definition-GMOUNBTQ-CQROCUM5.js → timeline-definition-GMOUNBTQ-BG7BBhYU.js} +1 -1
  52. package/dist/assets/{vennDiagram-DHZGUBPP-DpZZHper.js → vennDiagram-DHZGUBPP-B2ouQLFv.js} +1 -1
  53. package/dist/assets/{wardley-RL74JXVD-DxrGND7E.js → wardley-RL74JXVD-BTOKrpN3.js} +1 -1
  54. package/dist/assets/{wardleyDiagram-NUSXRM2D-ySAfXx-k.js → wardleyDiagram-NUSXRM2D-nYgUkIIc.js} +1 -1
  55. package/dist/assets/{xychartDiagram-5P7HB3ND-CM7FnJ-o.js → xychartDiagram-5P7HB3ND-BWTg8eD3.js} +1 -1
  56. package/dist/index.html +1 -1
  57. package/lib/ask-bridge.js +10 -1
  58. package/lib/perm-bridge.js +10 -1
  59. package/lib/plugin-loader.js +54 -25
  60. package/lib/sdk-manager.js +38 -1
  61. package/package.json +2 -1
  62. package/pty-manager.js +7 -4
  63. package/server.js +97 -5
  64. package/dist/assets/classDiagram-6PBFFD2Q-Cl6bNHmI.js +0 -1
  65. package/dist/assets/classDiagram-v2-HSJHXN6E-Cl6bNHmI.js +0 -1
  66. package/dist/assets/clone-B0RzsPMv.js +0 -1
package/README.md CHANGED
@@ -1,11 +1,14 @@
1
- # CC-Viewer
1
+ <img width="1500" height="150" alt="ccv" src="https://github.com/user-attachments/assets/433e79d4-8d55-4e3a-9efe-69bf4aa54426" />
2
2
 
3
- A Claude Code request monitoring system that captures and visualizes all API requests and responses from Claude Code in real time (raw text, unredacted). Helps developers monitor their context for review and troubleshooting during Vibe Coding sessions.
4
- The latest version of CC-Viewer also provides a server-deployed web programming solution and mobile programming tools. Feel free to use them in your own projects — more plugin features and cloud deployment support are coming in the future.
3
+ # CC-Viewer
5
4
 
6
- Check out the fun part here's what you can see on mobile:
5
+ A Vibe Coding toolkit distilled from 15+ years of internet-industry R&D experience, built on top of Claude Code:
7
6
 
8
- <img width="1700" height="790" alt="image" src="https://github.com/user-attachments/assets/da3e519f-ff66-4cd2-81d1-f4e131215f6c" />
7
+ 1. Run /ultraPlan and /ultraReview locally, so your code never has to be fully exposed to Claude's cloud;
8
+ 2. Enables mobile programming over your local network (user-extensible);
9
+ 3. Full Claude Code payload interception and analysis — great for logging, debugging, learning, and reverse-engineering;
10
+ 4. Ships with accumulated study notes and hands-on experience (look for the "?" icons throughout the app), so we can explore and grow together;
11
+ 5. Web UI adapts to every size mode — drop it into browser extensions, OS split views, and any embedding scenario; a native installer is also available.
9
12
 
10
13
  English | [简体中文](./docs/README.zh.md) | [繁體中文](./docs/README.zh-TW.md) | [한국어](./docs/README.ko.md) | [日本語](./docs/README.ja.md) | [Deutsch](./docs/README.de.md) | [Español](./docs/README.es.md) | [Français](./docs/README.fr.md) | [Italiano](./docs/README.it.md) | [Dansk](./docs/README.da.md) | [Polski](./docs/README.pl.md) | [Русский](./docs/README.ru.md) | [العربية](./docs/README.ar.md) | [Norsk](./docs/README.no.md) | [Português (Brasil)](./docs/README.pt-BR.md) | [ไทย](./docs/README.th.md) | [Türkçe](./docs/README.tr.md) | [Українська](./docs/README.uk.md)
11
14
 
@@ -37,16 +40,15 @@ ccv -c --d # == claude --continue --dangerously-skip-permissions
37
40
 
38
41
  After launching in programming mode, a web page will open automatically.
39
42
 
40
- You can use Claude directly from the web page while viewing the full request payloads and code changes.
41
-
42
- Even better — you can even code from your mobile device!
43
+ CC-Viewer also ships as a native desktop app grab the build for your platform from GitHub.
44
+ [Download page](https://github.com/weiesky/cc-viewer/releases)
43
45
 
44
46
 
45
47
  ### Logger Mode
46
48
 
47
- ⚠️ If you still prefer using the native claude tool or VS Code extension, use this mode.
49
+ If you still prefer the native claude tool or the VS Code extension, use this mode.
48
50
 
49
- In this mode, launching `claude` or `claude --dangerously-skip-permissions` will automatically start a logging process that records request logs to ~/.claude/cc-viewer/*yourproject*/date.jsonl
51
+ In this mode, launching `claude` will automatically start a logging process that records request logs to ~/.claude/cc-viewer/*yourproject*/date.jsonl
50
52
 
51
53
  Enable logger mode:
52
54
  ```bash
@@ -55,12 +57,6 @@ ccv -logger
55
57
 
56
58
  When the console cannot print the specific port, the default first port is 127.0.0.1:7008. Multiple instances use sequential ports like 7009, 7010.
57
59
 
58
- This command automatically detects how Claude Code is installed locally (NPM or Native Install) and adapts accordingly.
59
-
60
- - **NPM version Claude Code**: Automatically injects an interceptor script into Claude Code's `cli.js`.
61
- - **Native version Claude Code**: Automatically detects the `claude` binary, configures a local transparent proxy, and sets up a Zsh Shell Hook to forward traffic automatically.
62
- - NPM-installed Claude Code is the recommended approach for this project.
63
-
64
60
  Uninstall logger mode:
65
61
  ```bash
66
62
  ccv --uninstall
@@ -82,6 +78,7 @@ Letting Claude Code diagnose the issue itself is more effective than asking anyo
82
78
 
83
79
  After the above instruction is completed, `findcc.js` will be updated. If your project frequently requires local deployment, or if forked code often needs to resolve installation issues, keeping this file lets you simply copy it next time. At this stage, many projects and companies using Claude Code are not deploying on Mac but rather on server-side hosted environments, so the author has separated `findcc.js` to make it easier to track cc-viewer source code updates going forward.
84
80
 
81
+
85
82
  ### Other Commands
86
83
 
87
84
  See:
@@ -90,10 +87,6 @@ See:
90
87
  ccv -h
91
88
  ```
92
89
 
93
- ### Configuration Override
94
-
95
- If you need to use a custom API endpoint (e.g., a corporate proxy), simply configure it in `~/.claude/settings.json` or set the `ANTHROPIC_BASE_URL` environment variable. `ccv` will automatically detect and correctly forward requests.
96
-
97
90
  ### Silent Mode
98
91
 
99
92
  By default, `ccv` runs in silent mode when wrapping `claude`, keeping your terminal output clean and consistent with the native experience. All logs are captured in the background and can be viewed at `http://localhost:7008`.
@@ -122,10 +115,10 @@ While you can open files and code manually, manual coding is not recommended —
122
115
  You can even scan a QR code to code from your mobile device:
123
116
 
124
117
  <img width="3018" height="1460" alt="image" src="https://github.com/user-attachments/assets/8debf48e-daec-420c-b37a-609f8b81cd20" />
118
+ <img width="1700" height="790" alt="image" src="https://github.com/user-attachments/assets/da3e519f-ff66-4cd2-81d1-f4e131215f6c" />
125
119
 
126
120
  Fulfill your imagination of mobile programming. There's also a plugin mechanism — if you need to customize for your coding habits, stay tuned for plugin hooks updates.
127
121
 
128
- **Voice input:** tap the microphone icon in the chat input for voice-to-text (Web Speech API; requires HTTPS or localhost, so it's hidden on LAN HTTP access). Alternatively, on Android use Gboard's built-in 🎤 key, and on iOS use the system dictation on the keyboard — both work offline and without any HTTPS requirement.
129
122
 
130
123
  ### Logger Mode (View Complete Claude Code Sessions)
131
124
 
@@ -144,7 +137,6 @@ Click the "Conversation Mode" button in the top-right corner to parse the Main A
144
137
 
145
138
  <img width="1500" height="764" alt="image" src="https://github.com/user-attachments/assets/725b57c8-6128-4225-b157-7dba2738b1c6" />
146
139
 
147
-
148
140
  - Agent Team display is not yet supported
149
141
  - User messages are right-aligned (blue bubbles), Main Agent replies are left-aligned (dark bubbles)
150
142
  - `thinking` blocks are collapsed by default, rendered as Markdown — click to expand and view the thinking process; one-click translation is supported (feature is still unstable)
@@ -153,22 +145,10 @@ Click the "Conversation Mode" button in the top-right corner to parse the Main A
153
145
  - Settings panel: toggle default collapse state for tool results and thinking blocks
154
146
  - Mobile conversation browsing: in mobile CLI mode, tap the "Conversation Browse" button in the top bar to slide out a read-only conversation view for browsing the complete conversation history on mobile
155
147
 
156
- ### Statistics Tool
157
-
158
- The "Data Statistics" floating panel in the header area:
159
-
160
- <img width="1500" height="765" alt="image" src="https://github.com/user-attachments/assets/a3d2db47-eac3-463a-9b44-3fa64994bf3b" />
161
-
162
- - Displays cache creation/read counts and cache hit rate
163
- - Cache rebuild statistics: grouped by reason (TTL, system/tools/model changes, message truncation/modification, key changes) showing counts and cache_creation tokens
164
- - Tool usage statistics: displays call frequency for each tool sorted by number of calls
165
- - Skill usage statistics: displays call frequency for each skill sorted by number of calls
166
- - Supports teammate statistics
167
- - Concept help (?) icon: click to view built-in documentation for MainAgent, CacheRebuild, and each tool
168
-
169
148
  ### Log Management
170
149
 
171
150
  Via the CC-Viewer dropdown menu in the top-left corner:
151
+
172
152
  <img width="1500" height="760" alt="image" src="https://github.com/user-attachments/assets/33295e2b-f2e0-4968-a6f1-6f3d1404454e" />
173
153
 
174
154
  **Log Compression**
@@ -200,24 +180,10 @@ You can customize plugins, manage all CC-Viewer processes, and CC-Viewer support
200
180
 
201
181
  ---
202
182
 
203
-
204
183
  <img width="1500" height="746" alt="image" src="https://github.com/user-attachments/assets/b1f60c7c-1438-4ecc-8c64-193d21ee3445" />
205
184
 
206
185
  More features waiting to be discovered... For example: the system supports Agent Team, and has a built-in Code Reviewer. Codex Code Reviewer integration is coming soon (the author highly recommends using Codex to review Claude Code's code).
207
186
 
208
-
209
- ### Auto-Update
210
-
211
- CC-Viewer automatically checks for updates on startup (at most once every 4 hours). Within the same major version (e.g., 1.x.x -> 1.y.z), updates are applied automatically and take effect on the next restart. Cross-major-version updates only show a notification.
212
-
213
- Auto-update follows Claude Code's global configuration in `~/.claude/settings.json`. If Claude Code has auto-updates disabled (`autoUpdates: false`), CC-Viewer will also skip auto-updates.
214
-
215
- ### Multi-language Support
216
-
217
- CC-Viewer supports 18 languages, automatically switching based on system locale:
218
-
219
- 简体中文 | English | 繁體中文 | 한국어 | Deutsch | Español | Français | Italiano | Dansk | 日本語 | Polski | Русский | العربية | Norsk | Português (Brasil) | ไทย | Türkçe | Українська
220
-
221
187
  ## License
222
188
 
223
189
  MIT
package/cli.js CHANGED
@@ -362,11 +362,12 @@ async function runCliMode(extraClaudeArgs = [], cwd, noOpen = false) {
362
362
  });
363
363
 
364
364
  const port = serverMod.getPort();
365
+ const serverProtocol = serverMod.getProtocol();
365
366
 
366
367
  // 3. 启动 PTY 中的 claude
367
368
  const { spawnClaude, killPty } = await import('./pty-manager.js');
368
369
  try {
369
- await spawnClaude(proxyPort, workingDir, extraClaudeArgs, claudePath, isNpmVersion, port);
370
+ await spawnClaude(proxyPort, workingDir, extraClaudeArgs, claudePath, isNpmVersion, port, serverProtocol);
370
371
  } catch (err) {
371
372
  console.error('[CC Viewer] Failed to spawn Claude:', err.message);
372
373
  await serverMod.stopViewer();
@@ -456,6 +457,7 @@ async function runSdkMode(extraClaudeArgs = [], cwd, noOpen = false) {
456
457
  onStreamingStatus: (data) => serverMod.setSdkStreamingState(data),
457
458
  broadcastWs: (msg) => serverMod.broadcastWsMessage(msg),
458
459
  permissionMode,
460
+ runWaterfallHook: (await import('./lib/plugin-loader.js')).runWaterfallHook,
459
461
  });
460
462
 
461
463
  // 注册 SDK 回调到 server.js(WS 消息路由用)