@kimuson/claude-code-viewer 0.0.1

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 (101) hide show
  1. package/README.md +126 -0
  2. package/dist/index.js +6 -0
  3. package/dist/standalone/.next/BUILD_ID +1 -0
  4. package/dist/standalone/.next/app-build-manifest.json +63 -0
  5. package/dist/standalone/.next/app-path-routes-manifest.json +8 -0
  6. package/dist/standalone/.next/build-manifest.json +33 -0
  7. package/dist/standalone/.next/package.json +1 -0
  8. package/dist/standalone/.next/prerender-manifest.json +61 -0
  9. package/dist/standalone/.next/react-loadable-manifest.json +1886 -0
  10. package/dist/standalone/.next/required-server-files.json +319 -0
  11. package/dist/standalone/.next/routes-manifest.json +85 -0
  12. package/dist/standalone/.next/server/app/_not-found/page.js +2 -0
  13. package/dist/standalone/.next/server/app/_not-found/page.js.nft.json +1 -0
  14. package/dist/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -0
  15. package/dist/standalone/.next/server/app/_not-found.html +1 -0
  16. package/dist/standalone/.next/server/app/_not-found.meta +8 -0
  17. package/dist/standalone/.next/server/app/_not-found.rsc +20 -0
  18. package/dist/standalone/.next/server/app/api/[[...route]]/route.js +18 -0
  19. package/dist/standalone/.next/server/app/api/[[...route]]/route.js.nft.json +1 -0
  20. package/dist/standalone/.next/server/app/api/[[...route]]/route_client-reference-manifest.js +1 -0
  21. package/dist/standalone/.next/server/app/index.html +1 -0
  22. package/dist/standalone/.next/server/app/index.meta +9 -0
  23. package/dist/standalone/.next/server/app/index.rsc +21 -0
  24. package/dist/standalone/.next/server/app/page.js +2 -0
  25. package/dist/standalone/.next/server/app/page.js.nft.json +1 -0
  26. package/dist/standalone/.next/server/app/page_client-reference-manifest.js +1 -0
  27. package/dist/standalone/.next/server/app/projects/[projectId]/page.js +2 -0
  28. package/dist/standalone/.next/server/app/projects/[projectId]/page.js.nft.json +1 -0
  29. package/dist/standalone/.next/server/app/projects/[projectId]/page_client-reference-manifest.js +1 -0
  30. package/dist/standalone/.next/server/app/projects/[projectId]/sessions/[sessionId]/page.js +21 -0
  31. package/dist/standalone/.next/server/app/projects/[projectId]/sessions/[sessionId]/page.js.nft.json +1 -0
  32. package/dist/standalone/.next/server/app/projects/[projectId]/sessions/[sessionId]/page_client-reference-manifest.js +1 -0
  33. package/dist/standalone/.next/server/app/projects/page.js +2 -0
  34. package/dist/standalone/.next/server/app/projects/page.js.nft.json +1 -0
  35. package/dist/standalone/.next/server/app/projects/page_client-reference-manifest.js +1 -0
  36. package/dist/standalone/.next/server/app-paths-manifest.json +8 -0
  37. package/dist/standalone/.next/server/chunks/227.js +9 -0
  38. package/dist/standalone/.next/server/chunks/430.js +1 -0
  39. package/dist/standalone/.next/server/chunks/434.js +1 -0
  40. package/dist/standalone/.next/server/chunks/565.js +6 -0
  41. package/dist/standalone/.next/server/chunks/767.js +22 -0
  42. package/dist/standalone/.next/server/functions-config-manifest.json +4 -0
  43. package/dist/standalone/.next/server/middleware-build-manifest.js +1 -0
  44. package/dist/standalone/.next/server/middleware-manifest.json +6 -0
  45. package/dist/standalone/.next/server/middleware-react-loadable-manifest.js +1 -0
  46. package/dist/standalone/.next/server/next-font-manifest.js +1 -0
  47. package/dist/standalone/.next/server/next-font-manifest.json +1 -0
  48. package/dist/standalone/.next/server/pages/404.html +1 -0
  49. package/dist/standalone/.next/server/pages/500.html +1 -0
  50. package/dist/standalone/.next/server/pages/_app.js +1 -0
  51. package/dist/standalone/.next/server/pages/_app.js.nft.json +1 -0
  52. package/dist/standalone/.next/server/pages/_document.js +1 -0
  53. package/dist/standalone/.next/server/pages/_document.js.nft.json +1 -0
  54. package/dist/standalone/.next/server/pages/_error.js +19 -0
  55. package/dist/standalone/.next/server/pages/_error.js.nft.json +1 -0
  56. package/dist/standalone/.next/server/pages-manifest.json +6 -0
  57. package/dist/standalone/.next/server/server-reference-manifest.js +1 -0
  58. package/dist/standalone/.next/server/server-reference-manifest.json +1 -0
  59. package/dist/standalone/.next/server/webpack-runtime.js +1 -0
  60. package/dist/standalone/.next/static/-bAyRz7I7Uct3-uKwsaVj/_buildManifest.js +1 -0
  61. package/dist/standalone/.next/static/-bAyRz7I7Uct3-uKwsaVj/_ssgManifest.js +1 -0
  62. package/dist/standalone/.next/static/MsWzv0dKwhqj0PgrFnPqt/_buildManifest.js +1 -0
  63. package/dist/standalone/.next/static/MsWzv0dKwhqj0PgrFnPqt/_ssgManifest.js +1 -0
  64. package/dist/standalone/.next/static/ZuOqnYSxCLcM8jWgoFok5/_buildManifest.js +1 -0
  65. package/dist/standalone/.next/static/ZuOqnYSxCLcM8jWgoFok5/_ssgManifest.js +1 -0
  66. package/dist/standalone/.next/static/chunks/2c913ea3-36aa7bd637622470.js +1 -0
  67. package/dist/standalone/.next/static/chunks/341-8b4909db05986cae.js +1 -0
  68. package/dist/standalone/.next/static/chunks/449-c035709aa8092b3b.js +1 -0
  69. package/dist/standalone/.next/static/chunks/655-a32d6fd8f19448f0.js +1 -0
  70. package/dist/standalone/.next/static/chunks/771-7ade401d2bcf557c.js +1 -0
  71. package/dist/standalone/.next/static/chunks/889-c0fb777d081684b2.js +16 -0
  72. package/dist/standalone/.next/static/chunks/app/_not-found/page-2b111b86d54b32e3.js +1 -0
  73. package/dist/standalone/.next/static/chunks/app/api/[[...route]]/route-065b2b751f08088c.js +1 -0
  74. package/dist/standalone/.next/static/chunks/app/layout-d1ed032e27034a80.js +1 -0
  75. package/dist/standalone/.next/static/chunks/app/layout-ea51e88a137c433d.js +1 -0
  76. package/dist/standalone/.next/static/chunks/app/page-065b2b751f08088c.js +1 -0
  77. package/dist/standalone/.next/static/chunks/app/projects/[projectId]/page-a2c860799ee8f587.js +1 -0
  78. package/dist/standalone/.next/static/chunks/app/projects/[projectId]/page-cb0896b46dfbb71a.js +1 -0
  79. package/dist/standalone/.next/static/chunks/app/projects/[projectId]/sessions/[sessionId]/page-80afc861d53d73a3.js +1 -0
  80. package/dist/standalone/.next/static/chunks/app/projects/[projectId]/sessions/[sessionId]/page-f102a0278b121a35.js +1 -0
  81. package/dist/standalone/.next/static/chunks/app/projects/page-51ec3584f0b3531b.js +1 -0
  82. package/dist/standalone/.next/static/chunks/app/projects/page-699c53d41e9dfd5b.js +1 -0
  83. package/dist/standalone/.next/static/chunks/framework-a164f82cd8755073.js +1 -0
  84. package/dist/standalone/.next/static/chunks/main-app-0ebf83e8ce07651b.js +1 -0
  85. package/dist/standalone/.next/static/chunks/main-fa0c4fdedaf16ad5.js +1 -0
  86. package/dist/standalone/.next/static/chunks/pages/_app-9df37aca1cc9efd0.js +1 -0
  87. package/dist/standalone/.next/static/chunks/pages/_error-7c44112af45da2e9.js +1 -0
  88. package/dist/standalone/.next/static/chunks/polyfills-42372ed130431b0a.js +1 -0
  89. package/dist/standalone/.next/static/chunks/webpack-37af2f5780141d68.js +1 -0
  90. package/dist/standalone/.next/static/css/6e09e605dcaa88b1.css +3 -0
  91. package/dist/standalone/.next/static/css/b418a93e1e29c5ac.css +3 -0
  92. package/dist/standalone/.next/static/media/569ce4b8f30dc480-s.p.woff2 +0 -0
  93. package/dist/standalone/.next/static/media/747892c23ea88013-s.woff2 +0 -0
  94. package/dist/standalone/.next/static/media/8d697b304b401681-s.woff2 +0 -0
  95. package/dist/standalone/.next/static/media/93f479601ee12b01-s.p.woff2 +0 -0
  96. package/dist/standalone/.next/static/media/9610d9e46709d722-s.woff2 +0 -0
  97. package/dist/standalone/.next/static/media/ba015fad6dcf6784-s.woff2 +0 -0
  98. package/dist/standalone/package.json +66 -0
  99. package/dist/standalone/public/.gitkeep +0 -0
  100. package/dist/standalone/server.js +44 -0
  101. package/package.json +74 -0
package/README.md ADDED
@@ -0,0 +1,126 @@
1
+ # Claude Code Viewer
2
+
3
+ A web-based viewer for browsing Claude Code conversation history files. View and navigate your Claude Code project conversations through a clean, intuitive interface.
4
+
5
+ ## Overview
6
+
7
+ Claude Code Viewer parses JSONL conversation files stored in `~/.claude/projects/` and presents them in a human-readable web UI. Browse projects, sessions, and detailed conversation history with support for tool usage, subtasks, and real-time file monitoring.
8
+
9
+ ## Features
10
+
11
+ - **Project Browser** - View all Claude Code projects with metadata and session counts
12
+ - **Session Navigation** - Browse conversation sessions within projects with filtering options
13
+ - **Conversation Display** - Human-readable format for Claude Code logs with syntax highlighting
14
+ - **Subtask Support** - Separate display for subtasks and sidechain conversations
15
+ - **Real-time Updates** - Automatic refresh when conversation files are modified
16
+ - **File System Watching** - Monitors `~/.claude/projects/` for changes and updates the UI
17
+ - **Responsive Design** - Works on desktop and mobile devices
18
+
19
+ ## Installation & Usage
20
+
21
+ ### Quick Start
22
+
23
+ Run directly from GitHub without installation:
24
+
25
+ ```bash
26
+ PORT=3400 npx github:d-kimuson/claude-code-viewer
27
+ ```
28
+
29
+ The server will start on port 3400 (or the specified PORT). Open `http://localhost:3400` in your browser.
30
+
31
+ ### Alternative Installation
32
+
33
+ Clone and run locally:
34
+
35
+ ```bash
36
+ git clone https://github.com/d-kimuson/claude-code-viewer.git
37
+ cd claude-code-viewer
38
+ pnpm i
39
+ pnpm build
40
+ pnpm start
41
+ ```
42
+
43
+ ## Requirements
44
+
45
+ - **Node.js** 18 or later
46
+ - **Claude Code** with conversation history in `~/.claude/projects/`
47
+
48
+ ## Data Source
49
+
50
+ The application reads Claude Code conversation files from:
51
+
52
+ - **Location**: `~/.claude/projects/<project>/<session-id>.jsonl`
53
+ - **Format**: JSONL files containing conversation entries
54
+ - **Auto-detection**: Automatically discovers new projects and sessions
55
+
56
+ ## Usage Guide
57
+
58
+ ### 1. Project List
59
+
60
+ - Browse all Claude Code projects
61
+ - View project metadata (name, path, session count, last modified)
62
+ - Click any project to view its sessions
63
+
64
+ ### 2. Session Browser
65
+
66
+ - View all conversation sessions within a project
67
+ - Filter to hide empty sessions
68
+ - Sessions show message counts and timestamps
69
+ - Click to view detailed conversation
70
+
71
+ ### 3. Conversation Viewer
72
+
73
+ - Full conversation history with proper formatting
74
+ - Syntax highlighting for code blocks
75
+ - Tool usage and results clearly displayed
76
+ - Navigation sidebar for jumping between sessions
77
+ - Support for different message types (user, assistant, system, tools)
78
+
79
+ ## Configuration
80
+
81
+ ### Port Configuration
82
+
83
+ Set a custom port using the `PORT` environment variable:
84
+
85
+ ```bash
86
+ PORT=8080 npx github:d-kimuson/claude-code-viewer
87
+ ```
88
+
89
+ ### Data Directory
90
+
91
+ The application automatically detects the standard Claude Code directory at `~/.claude/projects/`. No additional configuration is required.
92
+
93
+ ## Browser Support
94
+
95
+ - Chrome/Chromium 90+
96
+ - Firefox 88+
97
+ - Safari 14+
98
+ - Edge 90+
99
+
100
+ ## Troubleshooting
101
+
102
+ ### No Projects Found
103
+
104
+ - Ensure Claude Code has been used and has created conversation files
105
+ - Check that `~/.claude/projects/` exists and contains project directories
106
+ - Verify file permissions allow reading the projects directory
107
+
108
+ ### Connection Issues
109
+
110
+ - Check that the specified port is not in use
111
+ - Ensure firewall settings allow local connections
112
+ - Try a different port using the `PORT` environment variable
113
+
114
+ ### Real-time Updates Not Working
115
+
116
+ - The application uses Server-Sent Events for real-time updates
117
+ - Some browsers or network configurations may block SSE connections
118
+ - Refresh the page manually to see latest changes
119
+
120
+ ## License
121
+
122
+ This project is available under the MIT License. See the LICENSE file for details.
123
+
124
+ ## Contributing
125
+
126
+ See [docs/dev.md](docs/dev.md) for development setup and contribution guidelines.
package/dist/index.js ADDED
@@ -0,0 +1,6 @@
1
+ #!/usr/bin/env node
2
+
3
+ await import("./standalone/server.js").catch((error) => {
4
+ console.error(error);
5
+ process.exit(1);
6
+ });
@@ -0,0 +1 @@
1
+ -bAyRz7I7Uct3-uKwsaVj
@@ -0,0 +1,63 @@
1
+ {
2
+ "pages": {
3
+ "/_not-found/page": [
4
+ "static/chunks/webpack-37af2f5780141d68.js",
5
+ "static/chunks/2c913ea3-36aa7bd637622470.js",
6
+ "static/chunks/341-8b4909db05986cae.js",
7
+ "static/chunks/main-app-0ebf83e8ce07651b.js",
8
+ "static/chunks/app/_not-found/page-2b111b86d54b32e3.js"
9
+ ],
10
+ "/layout": [
11
+ "static/chunks/webpack-37af2f5780141d68.js",
12
+ "static/chunks/2c913ea3-36aa7bd637622470.js",
13
+ "static/chunks/341-8b4909db05986cae.js",
14
+ "static/chunks/main-app-0ebf83e8ce07651b.js",
15
+ "static/css/6e09e605dcaa88b1.css",
16
+ "static/chunks/449-c035709aa8092b3b.js",
17
+ "static/chunks/app/layout-ea51e88a137c433d.js"
18
+ ],
19
+ "/api/[[...route]]/route": [
20
+ "static/chunks/webpack-37af2f5780141d68.js",
21
+ "static/chunks/2c913ea3-36aa7bd637622470.js",
22
+ "static/chunks/341-8b4909db05986cae.js",
23
+ "static/chunks/main-app-0ebf83e8ce07651b.js",
24
+ "static/chunks/app/api/[[...route]]/route-065b2b751f08088c.js"
25
+ ],
26
+ "/page": [
27
+ "static/chunks/webpack-37af2f5780141d68.js",
28
+ "static/chunks/2c913ea3-36aa7bd637622470.js",
29
+ "static/chunks/341-8b4909db05986cae.js",
30
+ "static/chunks/main-app-0ebf83e8ce07651b.js",
31
+ "static/chunks/app/page-065b2b751f08088c.js"
32
+ ],
33
+ "/projects/[projectId]/page": [
34
+ "static/chunks/webpack-37af2f5780141d68.js",
35
+ "static/chunks/2c913ea3-36aa7bd637622470.js",
36
+ "static/chunks/341-8b4909db05986cae.js",
37
+ "static/chunks/main-app-0ebf83e8ce07651b.js",
38
+ "static/chunks/449-c035709aa8092b3b.js",
39
+ "static/chunks/771-7ade401d2bcf557c.js",
40
+ "static/chunks/655-a32d6fd8f19448f0.js",
41
+ "static/chunks/app/projects/[projectId]/page-cb0896b46dfbb71a.js"
42
+ ],
43
+ "/projects/page": [
44
+ "static/chunks/webpack-37af2f5780141d68.js",
45
+ "static/chunks/2c913ea3-36aa7bd637622470.js",
46
+ "static/chunks/341-8b4909db05986cae.js",
47
+ "static/chunks/main-app-0ebf83e8ce07651b.js",
48
+ "static/chunks/449-c035709aa8092b3b.js",
49
+ "static/chunks/771-7ade401d2bcf557c.js",
50
+ "static/chunks/app/projects/page-699c53d41e9dfd5b.js"
51
+ ],
52
+ "/projects/[projectId]/sessions/[sessionId]/page": [
53
+ "static/chunks/webpack-37af2f5780141d68.js",
54
+ "static/chunks/2c913ea3-36aa7bd637622470.js",
55
+ "static/chunks/341-8b4909db05986cae.js",
56
+ "static/chunks/main-app-0ebf83e8ce07651b.js",
57
+ "static/chunks/449-c035709aa8092b3b.js",
58
+ "static/chunks/771-7ade401d2bcf557c.js",
59
+ "static/chunks/889-c0fb777d081684b2.js",
60
+ "static/chunks/app/projects/[projectId]/sessions/[sessionId]/page-80afc861d53d73a3.js"
61
+ ]
62
+ }
63
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "/_not-found/page": "/_not-found",
3
+ "/api/[[...route]]/route": "/api/[[...route]]",
4
+ "/page": "/",
5
+ "/projects/[projectId]/page": "/projects/[projectId]",
6
+ "/projects/page": "/projects",
7
+ "/projects/[projectId]/sessions/[sessionId]/page": "/projects/[projectId]/sessions/[sessionId]"
8
+ }
@@ -0,0 +1,33 @@
1
+ {
2
+ "polyfillFiles": [
3
+ "static/chunks/polyfills-42372ed130431b0a.js"
4
+ ],
5
+ "devFiles": [],
6
+ "ampDevFiles": [],
7
+ "lowPriorityFiles": [
8
+ "static/-bAyRz7I7Uct3-uKwsaVj/_buildManifest.js",
9
+ "static/-bAyRz7I7Uct3-uKwsaVj/_ssgManifest.js"
10
+ ],
11
+ "rootMainFiles": [
12
+ "static/chunks/webpack-37af2f5780141d68.js",
13
+ "static/chunks/2c913ea3-36aa7bd637622470.js",
14
+ "static/chunks/341-8b4909db05986cae.js",
15
+ "static/chunks/main-app-0ebf83e8ce07651b.js"
16
+ ],
17
+ "rootMainFilesTree": {},
18
+ "pages": {
19
+ "/_app": [
20
+ "static/chunks/webpack-37af2f5780141d68.js",
21
+ "static/chunks/framework-a164f82cd8755073.js",
22
+ "static/chunks/main-fa0c4fdedaf16ad5.js",
23
+ "static/chunks/pages/_app-9df37aca1cc9efd0.js"
24
+ ],
25
+ "/_error": [
26
+ "static/chunks/webpack-37af2f5780141d68.js",
27
+ "static/chunks/framework-a164f82cd8755073.js",
28
+ "static/chunks/main-fa0c4fdedaf16ad5.js",
29
+ "static/chunks/pages/_error-7c44112af45da2e9.js"
30
+ ]
31
+ },
32
+ "ampFirstPages": []
33
+ }
@@ -0,0 +1 @@
1
+ {"type": "commonjs"}
@@ -0,0 +1,61 @@
1
+ {
2
+ "version": 4,
3
+ "routes": {
4
+ "/_not-found": {
5
+ "initialStatus": 404,
6
+ "experimentalBypassFor": [
7
+ {
8
+ "type": "header",
9
+ "key": "next-action"
10
+ },
11
+ {
12
+ "type": "header",
13
+ "key": "content-type",
14
+ "value": "multipart/form-data;.*"
15
+ }
16
+ ],
17
+ "initialRevalidateSeconds": false,
18
+ "srcRoute": "/_not-found",
19
+ "dataRoute": "/_not-found.rsc",
20
+ "allowHeader": [
21
+ "host",
22
+ "x-matched-path",
23
+ "x-prerender-revalidate",
24
+ "x-prerender-revalidate-if-generated",
25
+ "x-next-revalidated-tags",
26
+ "x-next-revalidate-tag-token"
27
+ ]
28
+ },
29
+ "/": {
30
+ "experimentalBypassFor": [
31
+ {
32
+ "type": "header",
33
+ "key": "next-action"
34
+ },
35
+ {
36
+ "type": "header",
37
+ "key": "content-type",
38
+ "value": "multipart/form-data;.*"
39
+ }
40
+ ],
41
+ "initialRevalidateSeconds": false,
42
+ "srcRoute": "/",
43
+ "dataRoute": "/index.rsc",
44
+ "allowHeader": [
45
+ "host",
46
+ "x-matched-path",
47
+ "x-prerender-revalidate",
48
+ "x-prerender-revalidate-if-generated",
49
+ "x-next-revalidated-tags",
50
+ "x-next-revalidate-tag-token"
51
+ ]
52
+ }
53
+ },
54
+ "dynamicRoutes": {},
55
+ "notFoundRoutes": [],
56
+ "preview": {
57
+ "previewModeId": "306b502f6c883a93e25d563ae506eb07",
58
+ "previewModeSigningKey": "c3a648f53335250803402f05ca56c4e6d6931efcab1942337a0f049fdb22aeff",
59
+ "previewModeEncryptionKey": "b1a96b185eb198fb8258ac344083272b7fcf7bd3718d890fe16096df031d716f"
60
+ }
61
+ }