Skip to content

Commit 89158de

Browse files
KevenWMarkhamclaude
andcommitted
feat: extract @transcript-parser/ui package (6/8)
- Extracted 46+ UI components from src/components/ - Included all shadcn/ui components (11 files) - Added custom hooks (5 files) and utilities (7 files) - Created comprehensive index.ts with all exports - Updated all imports across codebase to use @transcript-parser/ui - Configured external dependencies (@google/genai, @transcript-parser/ai-services) - All builds passing with improved bundle size (622 KB vs 730 KB) Deleted from src/: - src/components/ (all UI components) - src/hooks/ (all custom hooks) - src/lib/ (utils moved to UI package) This completes Sprint 01: All 8 packages successfully extracted! 🎉 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 840d61f commit 89158de

File tree

82 files changed

+1215
-754
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

82 files changed

+1215
-754
lines changed

.claude/settings.local.json

Lines changed: 3 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,9 @@
11
{
22
"permissions": {
33
"allow": [
4-
"Bash(powershell:*)",
5-
"Bash(npx asar:*)",
6-
"Bash(taskkill:*)",
7-
"Bash(npm run electron:dev:*)",
8-
"Bash(node -p:*)",
9-
"Bash(npx electron .)",
10-
"Bash(cat:*)",
11-
"Bash(./node_modules/electron/dist/electron.exe:*)",
12-
"Bash(git add:*)",
13-
"Bash(git commit:*)",
14-
"Bash(git push)",
15-
"Bash(gh run list:*)",
16-
"Bash(gh run watch:*)",
17-
"Bash(gh run download:*)",
18-
"Bash(explorer.exe \"Transcript Parser Installer\")",
19-
"Bash(wait)",
20-
"Bash(explorer.exe \"Transcript Parser v1.0.0 - Production Build\")",
21-
"Bash(npm run dev:*)",
22-
"Bash($null)",
23-
"Bash(npm run build:*)",
24-
"Bash(npm run build:windows:*)",
25-
"Bash(npm run)",
26-
"Bash(npm run electron:build:win:*)",
27-
"Bash(npm install:*)",
28-
"Bash(git push:*)",
29-
"Bash(git mv:*)",
30-
"Bash(dir:*)",
31-
"Bash(pnpm --version:*)",
32-
"Bash(pnpm install)",
33-
"Bash(npm test:*)",
34-
"Bash(pnpm build:*)",
35-
"Bash(find:*)",
36-
"Bash(mkdir:*)",
37-
"Bash(tree:*)",
38-
"Bash(pnpm add:*)"
4+
"Bash(do sed -i \"s|from ''@/hooks/|from ''./|g\" \"$file\")",
5+
"Bash(npm run type-check:*)",
6+
"Bash(npx tsc:*)"
397
],
408
"deny": [],
419
"ask": []

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@
5555
"@transcript-parser/export": "workspace:*",
5656
"@transcript-parser/module-sdk": "workspace:*",
5757
"@transcript-parser/types": "workspace:*",
58+
"@transcript-parser/ui": "workspace:*",
5859
"@radix-ui/react-dialog": "^1.1.15",
5960
"@radix-ui/react-progress": "^1.1.8",
6061
"@radix-ui/react-slot": "^1.2.4",

packages/ui/package.json

Lines changed: 21 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@transcript-parser/ui",
33
"version": "0.1.0",
4-
"description": "Shared UI components for Transcript Parser",
4+
"description": "UI components library with shadcn/ui and custom components",
55
"main": "./dist/index.js",
66
"module": "./dist/index.mjs",
77
"types": "./dist/index.d.ts",
@@ -10,38 +10,45 @@
1010
"import": "./dist/index.mjs",
1111
"require": "./dist/index.js",
1212
"types": "./dist/index.d.ts"
13-
},
14-
"./styles": "./dist/styles.css"
13+
}
1514
},
1615
"scripts": {
17-
"build": "tsup src/index.ts --format cjs,esm --dts --external react --external react-dom",
18-
"dev": "tsup src/index.ts --format cjs,esm --dts --watch --external react --external react-dom",
16+
"build": "tsup",
17+
"dev": "tsup --watch",
1918
"clean": "rm -rf dist",
2019
"type-check": "tsc --noEmit"
2120
},
22-
"keywords": ["ui", "components", "react"],
21+
"keywords": [
22+
"ui",
23+
"components",
24+
"react",
25+
"shadcn"
26+
],
2327
"author": "Keven Markham",
2428
"license": "ISC",
25-
"devDependencies": {
26-
"@types/react": "^18.3.18",
27-
"@types/react-dom": "^18.3.5",
28-
"tsup": "^8.0.1",
29-
"typescript": "~5.6.2"
30-
},
29+
"sideEffects": false,
3130
"peerDependencies": {
3231
"react": "^18.3.1",
33-
"react-dom": "^18.3.1"
32+
"react-dom": "^18.3.1",
33+
"@transcript-parser/ai-services": "workspace:*"
3434
},
3535
"dependencies": {
3636
"@radix-ui/react-dialog": "^1.1.15",
3737
"@radix-ui/react-progress": "^1.1.8",
3838
"@radix-ui/react-slot": "^1.2.4",
39-
"@tanstack/react-virtual": "^3.13.13",
4039
"@transcript-parser/types": "workspace:*",
4140
"class-variance-authority": "^0.7.1",
4241
"clsx": "^2.1.1",
4342
"framer-motion": "^12.23.26",
4443
"lucide-react": "^0.561.0",
4544
"tailwind-merge": "^3.4.0"
45+
},
46+
"devDependencies": {
47+
"@types/node": "^25.0.3",
48+
"@types/react": "^18.3.27",
49+
"@types/react-dom": "^18.3.7",
50+
"tsup": "^8.0.1",
51+
"typescript": "~5.6.2",
52+
"vite": "^6.0.5"
4653
}
4754
}
File renamed without changes.

src/components/ApiKeySettings.tsx renamed to packages/ui/src/components/ApiKeySettings.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*/
55

66
import { useState, useEffect } from 'react'
7-
import { Button } from '@/components/ui/button'
7+
import { Button } from './ui/button'
88
import {
99
X,
1010
Key,

src/components/BalanceAlert.tsx renamed to packages/ui/src/components/BalanceAlert.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*/
55

66
import { AlertTriangle, CreditCard, X } from 'lucide-react'
7-
import { Button } from '@/components/ui/button'
7+
import { Button } from './ui/button'
88

99
interface BalanceAlertProps {
1010
balance: number

src/components/CostSummaryModal.tsx renamed to packages/ui/src/components/CostSummaryModal.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ import {
66
BarChart3,
77
Calendar,
88
} from 'lucide-react'
9-
import { Dialog, DialogContent } from '@/components/ui/dialog'
10-
import { Card } from '@/components/ui/card'
11-
import { Button } from '@/components/ui/button'
9+
import { Dialog, DialogContent } from './ui/dialog'
10+
import { Card } from './ui/card'
11+
import { Button } from './ui/button'
1212
import { motion } from 'framer-motion'
1313

1414
interface CostSummaryModalProps {

src/components/ExportDialog.tsx renamed to packages/ui/src/components/ExportDialog.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ import { Download, Copy, X, FileText, Film, Code, Table } from 'lucide-react'
33
import {
44
Dialog,
55
DialogContent,
6-
} from '@/components/ui/dialog'
7-
import { Button } from '@/components/ui/button'
8-
import { Badge } from '@/components/ui/badge'
9-
import { Checkbox } from '@/components/ui/checkbox'
10-
import { useToast } from '@/components/ui/toast'
6+
} from './ui/dialog'
7+
import { Button } from './ui/button'
8+
import { Badge } from './ui/badge'
9+
import { Checkbox } from './ui/checkbox'
10+
import { useToast } from './ui/toast'
1111
import type { TranscriptEntry } from '@transcript-parser/types'
1212
import {
1313
toPlainText,
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { motion } from 'framer-motion'
22
import { Video } from 'lucide-react'
3-
import { Card } from '@/components/ui/card'
3+
import { Card } from './ui/card'
44

55
export function Header() {
66
return (

src/components/KeyboardShortcuts.tsx renamed to packages/ui/src/components/KeyboardShortcuts.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ import {
55
DialogContent,
66
DialogHeader,
77
DialogTitle,
8-
} from '@/components/ui/dialog'
9-
import { Button } from '@/components/ui/button'
8+
} from './ui/dialog'
9+
import { Button } from './ui/button'
1010

1111
interface ShortcutGroup {
1212
title: string

0 commit comments

Comments
 (0)