@gv-tech/design-system 2.5.0 → 2.5.2
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.
- package/CHANGELOG.md +15 -0
- package/package.json +5 -2
- package/.agent/skills/dogfood-components/SKILL.md +0 -34
- package/.agent/skills/maintain-component/SKILL.md +0 -77
- package/.agent/workflows/native-playground.md +0 -93
- package/.github/CODEOWNERS +0 -2
- package/.github/CONTRIBUTING.md +0 -42
- package/.github/FUNDING.yml +0 -4
- package/.github/PULL_REQUEST_TEMPLATE/build.md +0 -5
- package/.github/PULL_REQUEST_TEMPLATE/standard.md +0 -3
- package/.github/RELEASING.md +0 -37
- package/.github/copilot-instructions.md +0 -61
- package/.github/workflows/ci.yml +0 -91
- package/.github/workflows/codeql-analysis.yml +0 -34
- package/.github/workflows/release-please.yml +0 -79
- package/.husky/pre-commit +0 -1
- package/.prettierignore +0 -3
- package/.release-please-manifest.json +0 -9
- package/.tool-versions +0 -1
- package/.vscode/launch.json +0 -22
- package/.vscode/mcp.json +0 -8
- package/.vscode/settings.json +0 -30
- package/.yarnrc.yml +0 -7
- package/SECURITY.md +0 -9
- package/apps/.gitkeep +0 -0
- package/apps/native-playground/CHANGELOG.md +0 -8
- package/apps/native-playground/app.json +0 -37
- package/apps/native-playground/assets/fonts/.gitkeep +0 -0
- package/apps/native-playground/assets/images/adaptive-icon.png +0 -0
- package/apps/native-playground/assets/images/favicon.png +0 -0
- package/apps/native-playground/assets/images/icon.png +0 -0
- package/apps/native-playground/assets/images/splash-icon.png +0 -0
- package/apps/native-playground/babel.config.js +0 -6
- package/apps/native-playground/eas.json +0 -25
- package/apps/native-playground/index.js +0 -8
- package/apps/native-playground/metro.config.js +0 -26
- package/apps/native-playground/nativewind-env.d.ts +0 -1
- package/apps/native-playground/package.json +0 -23
- package/apps/native-playground/project.json +0 -15
- package/apps/native-playground/src/app/App.tsx +0 -842
- package/apps/native-playground/src/global.css +0 -49
- package/apps/native-playground/tailwind.config.js +0 -49
- package/apps/native-playground/tsconfig.app.json +0 -24
- package/apps/native-playground/tsconfig.json +0 -23
- package/apps/native-playground/tsconfig.spec.json +0 -24
- package/apps/playground-web/CHANGELOG.md +0 -8
- package/apps/playground-web/index.html +0 -13
- package/apps/playground-web/package.json +0 -31
- package/apps/playground-web/public/favicon.png +0 -0
- package/apps/playground-web/public/index.demo.html +0 -40
- package/apps/playground-web/public/logo192.png +0 -0
- package/apps/playground-web/public/logo512.png +0 -0
- package/apps/playground-web/public/manifest.json +0 -25
- package/apps/playground-web/public/robots.txt +0 -2
- package/apps/playground-web/src/App.tsx +0 -179
- package/apps/playground-web/src/components/docs/CodeBlock.tsx +0 -34
- package/apps/playground-web/src/components/docs/CombinedDocsLayout.tsx +0 -103
- package/apps/playground-web/src/components/docs/ComponentShowcase.tsx +0 -96
- package/apps/playground-web/src/components/docs/ErrorBoundary.tsx +0 -55
- package/apps/playground-web/src/components/docs/Footer.tsx +0 -146
- package/apps/playground-web/src/components/docs/PropsTable.tsx +0 -43
- package/apps/playground-web/src/components/docs/Search.tsx +0 -75
- package/apps/playground-web/src/components/docs/Sidebar.tsx +0 -77
- package/apps/playground-web/src/components/docs/ThemeToggle.tsx +0 -19
- package/apps/playground-web/src/components/docs/index.ts +0 -9
- package/apps/playground-web/src/config/docs.ts +0 -293
- package/apps/playground-web/src/globals.css +0 -148
- package/apps/playground-web/src/hooks/useDocMetadata.ts +0 -34
- package/apps/playground-web/src/hooks/usePackageManager.tsx +0 -42
- package/apps/playground-web/src/lib/react-native-shim.js +0 -34
- package/apps/playground-web/src/main.tsx +0 -11
- package/apps/playground-web/src/pages/index.ts +0 -4
- package/apps/playground-web/src/pages/native/AccordionDocs.tsx +0 -85
- package/apps/playground-web/src/pages/native/AlertDialogDocs.tsx +0 -128
- package/apps/playground-web/src/pages/native/AlertDocs.tsx +0 -89
- package/apps/playground-web/src/pages/native/AspectRatioDocs.tsx +0 -52
- package/apps/playground-web/src/pages/native/AvatarDocs.tsx +0 -92
- package/apps/playground-web/src/pages/native/BadgeDocs.tsx +0 -63
- package/apps/playground-web/src/pages/native/BreadcrumbDocs.tsx +0 -71
- package/apps/playground-web/src/pages/native/ButtonDocs.tsx +0 -103
- package/apps/playground-web/src/pages/native/CalendarDocs.tsx +0 -74
- package/apps/playground-web/src/pages/native/CardDocs.tsx +0 -75
- package/apps/playground-web/src/pages/native/CarouselDocs.tsx +0 -113
- package/apps/playground-web/src/pages/native/ChartDocs.tsx +0 -115
- package/apps/playground-web/src/pages/native/CheckboxDocs.tsx +0 -38
- package/apps/playground-web/src/pages/native/CollapsibleDocs.tsx +0 -89
- package/apps/playground-web/src/pages/native/CommandDocs.tsx +0 -170
- package/apps/playground-web/src/pages/native/ContextMenuDocs.tsx +0 -121
- package/apps/playground-web/src/pages/native/DialogDocs.tsx +0 -132
- package/apps/playground-web/src/pages/native/DrawerDocs.tsx +0 -158
- package/apps/playground-web/src/pages/native/DropdownMenuDocs.tsx +0 -168
- package/apps/playground-web/src/pages/native/HoverCardDocs.tsx +0 -119
- package/apps/playground-web/src/pages/native/InputDocs.tsx +0 -86
- package/apps/playground-web/src/pages/native/LabelDocs.tsx +0 -55
- package/apps/playground-web/src/pages/native/MenubarDocs.tsx +0 -197
- package/apps/playground-web/src/pages/native/NavigationMenuDocs.tsx +0 -190
- package/apps/playground-web/src/pages/native/PaginationDocs.tsx +0 -70
- package/apps/playground-web/src/pages/native/PopoverDocs.tsx +0 -156
- package/apps/playground-web/src/pages/native/ProgressDocs.tsx +0 -61
- package/apps/playground-web/src/pages/native/RadioGroupDocs.tsx +0 -125
- package/apps/playground-web/src/pages/native/ResizableDocs.tsx +0 -118
- package/apps/playground-web/src/pages/native/ScrollAreaDocs.tsx +0 -92
- package/apps/playground-web/src/pages/native/SearchDocs.tsx +0 -150
- package/apps/playground-web/src/pages/native/SelectDocs.tsx +0 -141
- package/apps/playground-web/src/pages/native/SeparatorDocs.tsx +0 -72
- package/apps/playground-web/src/pages/native/SheetDocs.tsx +0 -140
- package/apps/playground-web/src/pages/native/SkeletonDocs.tsx +0 -44
- package/apps/playground-web/src/pages/native/SliderDocs.tsx +0 -118
- package/apps/playground-web/src/pages/native/SonnerDocs.tsx +0 -111
- package/apps/playground-web/src/pages/native/SwitchDocs.tsx +0 -87
- package/apps/playground-web/src/pages/native/TableDocs.tsx +0 -67
- package/apps/playground-web/src/pages/native/TabsDocs.tsx +0 -175
- package/apps/playground-web/src/pages/native/TextareaDocs.tsx +0 -61
- package/apps/playground-web/src/pages/native/ThemeToggleDocs.tsx +0 -288
- package/apps/playground-web/src/pages/native/ToastDocs.tsx +0 -124
- package/apps/playground-web/src/pages/native/ToggleDocs.tsx +0 -81
- package/apps/playground-web/src/pages/native/ToggleGroupDocs.tsx +0 -128
- package/apps/playground-web/src/pages/native/TooltipDocs.tsx +0 -140
- package/apps/playground-web/src/pages/native/index.ts +0 -47
- package/apps/playground-web/src/pages/shared/ColorTokensDocs.tsx +0 -234
- package/apps/playground-web/src/pages/shared/GettingStarted.tsx +0 -413
- package/apps/playground-web/src/pages/web/AccordionDocs.tsx +0 -194
- package/apps/playground-web/src/pages/web/AlertDialogDocs.tsx +0 -157
- package/apps/playground-web/src/pages/web/AlertDocs.tsx +0 -110
- package/apps/playground-web/src/pages/web/AspectRatioDocs.tsx +0 -94
- package/apps/playground-web/src/pages/web/AvatarDocs.tsx +0 -81
- package/apps/playground-web/src/pages/web/BadgeDocs.tsx +0 -66
- package/apps/playground-web/src/pages/web/BreadcrumbDocs.tsx +0 -93
- package/apps/playground-web/src/pages/web/ButtonDocs.tsx +0 -129
- package/apps/playground-web/src/pages/web/CalendarDocs.tsx +0 -78
- package/apps/playground-web/src/pages/web/CardDocs.tsx +0 -115
- package/apps/playground-web/src/pages/web/CarouselDocs.tsx +0 -176
- package/apps/playground-web/src/pages/web/ChartDocs.tsx +0 -151
- package/apps/playground-web/src/pages/web/CheckboxDocs.tsx +0 -95
- package/apps/playground-web/src/pages/web/CollapsibleDocs.tsx +0 -111
- package/apps/playground-web/src/pages/web/CommandDocs.tsx +0 -219
- package/apps/playground-web/src/pages/web/ContextMenuDocs.tsx +0 -164
- package/apps/playground-web/src/pages/web/DialogDocs.tsx +0 -175
- package/apps/playground-web/src/pages/web/DrawerDocs.tsx +0 -283
- package/apps/playground-web/src/pages/web/DropdownMenuDocs.tsx +0 -319
- package/apps/playground-web/src/pages/web/FormDocs.tsx +0 -175
- package/apps/playground-web/src/pages/web/HoverCardDocs.tsx +0 -151
- package/apps/playground-web/src/pages/web/InputDocs.tsx +0 -118
- package/apps/playground-web/src/pages/web/LabelDocs.tsx +0 -59
- package/apps/playground-web/src/pages/web/MenubarDocs.tsx +0 -296
- package/apps/playground-web/src/pages/web/NavigationMenuDocs.tsx +0 -263
- package/apps/playground-web/src/pages/web/PaginationDocs.tsx +0 -102
- package/apps/playground-web/src/pages/web/PopoverDocs.tsx +0 -189
- package/apps/playground-web/src/pages/web/ProgressDocs.tsx +0 -70
- package/apps/playground-web/src/pages/web/RadioGroupDocs.tsx +0 -137
- package/apps/playground-web/src/pages/web/ResizableDocs.tsx +0 -143
- package/apps/playground-web/src/pages/web/ScrollAreaDocs.tsx +0 -107
- package/apps/playground-web/src/pages/web/SearchDocs.tsx +0 -203
- package/apps/playground-web/src/pages/web/SelectDocs.tsx +0 -164
- package/apps/playground-web/src/pages/web/SeparatorDocs.tsx +0 -88
- package/apps/playground-web/src/pages/web/SheetDocs.tsx +0 -186
- package/apps/playground-web/src/pages/web/SkeletonDocs.tsx +0 -53
- package/apps/playground-web/src/pages/web/SliderDocs.tsx +0 -119
- package/apps/playground-web/src/pages/web/SonnerDocs.tsx +0 -126
- package/apps/playground-web/src/pages/web/SwitchDocs.tsx +0 -91
- package/apps/playground-web/src/pages/web/TableDocs.tsx +0 -148
- package/apps/playground-web/src/pages/web/TabsDocs.tsx +0 -241
- package/apps/playground-web/src/pages/web/TextareaDocs.tsx +0 -65
- package/apps/playground-web/src/pages/web/ThemeToggleDocs.tsx +0 -303
- package/apps/playground-web/src/pages/web/ToastDocs.tsx +0 -149
- package/apps/playground-web/src/pages/web/ToggleDocs.tsx +0 -85
- package/apps/playground-web/src/pages/web/ToggleGroupDocs.tsx +0 -140
- package/apps/playground-web/src/pages/web/TooltipDocs.tsx +0 -150
- package/apps/playground-web/src/pages/web/index.ts +0 -47
- package/apps/playground-web/src/routes/doc-routes.tsx +0 -363
- package/apps/playground-web/tailwind.config.js +0 -47
- package/apps/playground-web/tsconfig.app.json +0 -16
- package/apps/playground-web/tsconfig.json +0 -4
- package/apps/playground-web/tsconfig.node.json +0 -13
- package/apps/playground-web/vite.config.ts +0 -41
- package/components.json +0 -20
- package/docs/architecture-pivot.md +0 -165
- package/docs/native-setup-decision.md +0 -57
- package/docs/phase-1-tracker.md +0 -144
- package/docs/release-tooling-evaluation.md +0 -67
- package/docs/universal-implementation.md +0 -195
- package/docs/update-plan.md +0 -268
- package/eslint.config.mjs +0 -13
- package/nx.json +0 -50
- package/packages/.gitkeep +0 -0
- package/packages/design-tokens/CHANGELOG.md +0 -8
- package/packages/design-tokens/package.json +0 -20
- package/packages/design-tokens/src/index.ts +0 -35
- package/packages/design-tokens/src/palette.ts +0 -36
- package/packages/design-tokens/src/radii.ts +0 -26
- package/packages/design-tokens/src/shadows.ts +0 -16
- package/packages/design-tokens/src/spacing.ts +0 -33
- package/packages/design-tokens/src/theme.ts +0 -54
- package/packages/design-tokens/src/typography.ts +0 -36
- package/packages/design-tokens/tsconfig.json +0 -17
- package/packages/ui-core/CHANGELOG.md +0 -8
- package/packages/ui-core/package.json +0 -40
- package/packages/ui-core/src/contracts/accordion.ts +0 -23
- package/packages/ui-core/src/contracts/alert-dialog.ts +0 -48
- package/packages/ui-core/src/contracts/alert.ts +0 -17
- package/packages/ui-core/src/contracts/aspect-ratio.ts +0 -7
- package/packages/ui-core/src/contracts/avatar.ts +0 -17
- package/packages/ui-core/src/contracts/badge.ts +0 -7
- package/packages/ui-core/src/contracts/breadcrumb.ts +0 -37
- package/packages/ui-core/src/contracts/button.ts +0 -17
- package/packages/ui-core/src/contracts/calendar.ts +0 -4
- package/packages/ui-core/src/contracts/card.ts +0 -11
- package/packages/ui-core/src/contracts/carousel.ts +0 -29
- package/packages/ui-core/src/contracts/chart.ts +0 -31
- package/packages/ui-core/src/contracts/checkbox.ts +0 -11
- package/packages/ui-core/src/contracts/collapsible.ts +0 -21
- package/packages/ui-core/src/contracts/command.ts +0 -43
- package/packages/ui-core/src/contracts/context-menu.ts +0 -78
- package/packages/ui-core/src/contracts/dialog.ts +0 -29
- package/packages/ui-core/src/contracts/drawer.ts +0 -39
- package/packages/ui-core/src/contracts/dropdown-menu.ts +0 -87
- package/packages/ui-core/src/contracts/form.ts +0 -29
- package/packages/ui-core/src/contracts/hover-card.ts +0 -21
- package/packages/ui-core/src/contracts/input.ts +0 -11
- package/packages/ui-core/src/contracts/label.ts +0 -7
- package/packages/ui-core/src/contracts/menubar.ts +0 -86
- package/packages/ui-core/src/contracts/navigation-menu.ts +0 -55
- package/packages/ui-core/src/contracts/pagination.ts +0 -38
- package/packages/ui-core/src/contracts/popover.ts +0 -28
- package/packages/ui-core/src/contracts/progress.ts +0 -4
- package/packages/ui-core/src/contracts/radio.ts +0 -16
- package/packages/ui-core/src/contracts/resizable.ts +0 -36
- package/packages/ui-core/src/contracts/scroll-area.ts +0 -15
- package/packages/ui-core/src/contracts/search.ts +0 -13
- package/packages/ui-core/src/contracts/select.ts +0 -64
- package/packages/ui-core/src/contracts/separator.ts +0 -5
- package/packages/ui-core/src/contracts/sheet.ts +0 -58
- package/packages/ui-core/src/contracts/skeleton.ts +0 -6
- package/packages/ui-core/src/contracts/slider.ts +0 -15
- package/packages/ui-core/src/contracts/sonner.ts +0 -15
- package/packages/ui-core/src/contracts/switch.ts +0 -11
- package/packages/ui-core/src/contracts/table.ts +0 -41
- package/packages/ui-core/src/contracts/tabs.ts +0 -31
- package/packages/ui-core/src/contracts/text.ts +0 -12
- package/packages/ui-core/src/contracts/textarea.ts +0 -7
- package/packages/ui-core/src/contracts/theme-provider.ts +0 -14
- package/packages/ui-core/src/contracts/theme-toggle.ts +0 -15
- package/packages/ui-core/src/contracts/toast.ts +0 -15
- package/packages/ui-core/src/contracts/toaster.ts +0 -3
- package/packages/ui-core/src/contracts/toggle-group.ts +0 -23
- package/packages/ui-core/src/contracts/toggle.ts +0 -49
- package/packages/ui-core/src/contracts/tooltip.ts +0 -28
- package/packages/ui-core/src/index.ts +0 -327
- package/packages/ui-core/tsconfig.json +0 -18
- package/packages/ui-native/CHANGELOG.md +0 -8
- package/packages/ui-native/package.json +0 -76
- package/packages/ui-native/src/accordion.tsx +0 -93
- package/packages/ui-native/src/alert-dialog.tsx +0 -123
- package/packages/ui-native/src/alert.tsx +0 -50
- package/packages/ui-native/src/aspect-ratio.tsx +0 -9
- package/packages/ui-native/src/avatar.tsx +0 -38
- package/packages/ui-native/src/badge.tsx +0 -51
- package/packages/ui-native/src/breadcrumb.tsx +0 -9
- package/packages/ui-native/src/button.test.tsx +0 -27
- package/packages/ui-native/src/button.tsx +0 -75
- package/packages/ui-native/src/calendar.tsx +0 -9
- package/packages/ui-native/src/card.test.tsx +0 -33
- package/packages/ui-native/src/card.tsx +0 -56
- package/packages/ui-native/src/carousel.tsx +0 -9
- package/packages/ui-native/src/chart.tsx +0 -9
- package/packages/ui-native/src/checkbox.test.tsx +0 -58
- package/packages/ui-native/src/checkbox.tsx +0 -31
- package/packages/ui-native/src/collapsible.test.tsx +0 -50
- package/packages/ui-native/src/collapsible.tsx +0 -15
- package/packages/ui-native/src/command.tsx +0 -9
- package/packages/ui-native/src/context-menu.tsx +0 -9
- package/packages/ui-native/src/dialog.test.tsx +0 -91
- package/packages/ui-native/src/dialog.tsx +0 -121
- package/packages/ui-native/src/drawer.tsx +0 -9
- package/packages/ui-native/src/dropdown-menu.tsx +0 -9
- package/packages/ui-native/src/form.tsx +0 -9
- package/packages/ui-native/src/hover-card.tsx +0 -9
- package/packages/ui-native/src/index.ts +0 -209
- package/packages/ui-native/src/input.test.tsx +0 -27
- package/packages/ui-native/src/input.tsx +0 -27
- package/packages/ui-native/src/label.tsx +0 -29
- package/packages/ui-native/src/lib/render-native.tsx +0 -17
- package/packages/ui-native/src/lib/utils.ts +0 -6
- package/packages/ui-native/src/menubar.tsx +0 -9
- package/packages/ui-native/src/nativewind-env.d.ts +0 -1
- package/packages/ui-native/src/navigation-menu.tsx +0 -9
- package/packages/ui-native/src/pagination.tsx +0 -9
- package/packages/ui-native/src/popover.tsx +0 -9
- package/packages/ui-native/src/progress.tsx +0 -9
- package/packages/ui-native/src/radio-group.test.tsx +0 -77
- package/packages/ui-native/src/radio-group.tsx +0 -42
- package/packages/ui-native/src/resizable.tsx +0 -25
- package/packages/ui-native/src/scroll-area.tsx +0 -9
- package/packages/ui-native/src/search.tsx +0 -17
- package/packages/ui-native/src/select.tsx +0 -229
- package/packages/ui-native/src/separator.tsx +0 -20
- package/packages/ui-native/src/sheet.test.tsx +0 -93
- package/packages/ui-native/src/sheet.tsx +0 -127
- package/packages/ui-native/src/skeleton.test.tsx +0 -29
- package/packages/ui-native/src/skeleton.tsx +0 -31
- package/packages/ui-native/src/slider.tsx +0 -9
- package/packages/ui-native/src/sonner.tsx +0 -9
- package/packages/ui-native/src/switch.tsx +0 -34
- package/packages/ui-native/src/table.tsx +0 -73
- package/packages/ui-native/src/tabs.tsx +0 -74
- package/packages/ui-native/src/text.test.tsx +0 -24
- package/packages/ui-native/src/text.tsx +0 -43
- package/packages/ui-native/src/textarea.test.tsx +0 -27
- package/packages/ui-native/src/textarea.tsx +0 -29
- package/packages/ui-native/src/theme-provider.tsx +0 -6
- package/packages/ui-native/src/theme-toggle.tsx +0 -11
- package/packages/ui-native/src/toast.test.tsx +0 -61
- package/packages/ui-native/src/toast.tsx +0 -88
- package/packages/ui-native/src/toaster.tsx +0 -9
- package/packages/ui-native/src/toggle-group.tsx +0 -78
- package/packages/ui-native/src/toggle.tsx +0 -35
- package/packages/ui-native/src/tooltip.tsx +0 -44
- package/packages/ui-native/tsconfig.json +0 -23
- package/packages/ui-native/vite.config.ts +0 -17
- package/packages/ui-web/CHANGELOG.md +0 -8
- package/packages/ui-web/package.json +0 -84
- package/packages/ui-web/src/accordion.test.tsx +0 -86
- package/packages/ui-web/src/accordion.tsx +0 -58
- package/packages/ui-web/src/alert-dialog.test.tsx +0 -91
- package/packages/ui-web/src/alert-dialog.tsx +0 -121
- package/packages/ui-web/src/alert.test.tsx +0 -47
- package/packages/ui-web/src/alert.tsx +0 -49
- package/packages/ui-web/src/aspect-ratio.test.tsx +0 -34
- package/packages/ui-web/src/aspect-ratio.tsx +0 -7
- package/packages/ui-web/src/avatar.test.tsx +0 -33
- package/packages/ui-web/src/avatar.tsx +0 -40
- package/packages/ui-web/src/badge.test.tsx +0 -24
- package/packages/ui-web/src/badge.tsx +0 -34
- package/packages/ui-web/src/breadcrumb.tsx +0 -105
- package/packages/ui-web/src/button.test.tsx +0 -62
- package/packages/ui-web/src/button.tsx +0 -47
- package/packages/ui-web/src/calendar.test.tsx +0 -23
- package/packages/ui-web/src/calendar.tsx +0 -163
- package/packages/ui-web/src/card.test.tsx +0 -35
- package/packages/ui-web/src/card.tsx +0 -46
- package/packages/ui-web/src/carousel.test.tsx +0 -37
- package/packages/ui-web/src/carousel.tsx +0 -234
- package/packages/ui-web/src/chart.test.tsx +0 -62
- package/packages/ui-web/src/chart.tsx +0 -296
- package/packages/ui-web/src/checkbox.test.tsx +0 -30
- package/packages/ui-web/src/checkbox.tsx +0 -31
- package/packages/ui-web/src/collapsible.test.tsx +0 -51
- package/packages/ui-web/src/collapsible.tsx +0 -15
- package/packages/ui-web/src/command.test.tsx +0 -79
- package/packages/ui-web/src/command.tsx +0 -154
- package/packages/ui-web/src/context-menu.test.tsx +0 -37
- package/packages/ui-web/src/context-menu.tsx +0 -208
- package/packages/ui-web/src/dialog.test.tsx +0 -66
- package/packages/ui-web/src/dialog.tsx +0 -95
- package/packages/ui-web/src/drawer.test.tsx +0 -68
- package/packages/ui-web/src/drawer.tsx +0 -110
- package/packages/ui-web/src/dropdown-menu.test.tsx +0 -93
- package/packages/ui-web/src/dropdown-menu.tsx +0 -212
- package/packages/ui-web/src/form.test.tsx +0 -84
- package/packages/ui-web/src/form.tsx +0 -160
- package/packages/ui-web/src/hooks/use-theme.ts +0 -15
- package/packages/ui-web/src/hooks/use-toast.ts +0 -189
- package/packages/ui-web/src/hover-card.test.tsx +0 -48
- package/packages/ui-web/src/hover-card.tsx +0 -35
- package/packages/ui-web/src/index.ts +0 -474
- package/packages/ui-web/src/input.test.tsx +0 -33
- package/packages/ui-web/src/input.tsx +0 -23
- package/packages/ui-web/src/label.test.tsx +0 -27
- package/packages/ui-web/src/label.tsx +0 -21
- package/packages/ui-web/src/lib/utils.ts +0 -6
- package/packages/ui-web/src/menubar.test.tsx +0 -92
- package/packages/ui-web/src/menubar.tsx +0 -244
- package/packages/ui-web/src/navigation-menu.test.tsx +0 -53
- package/packages/ui-web/src/navigation-menu.tsx +0 -143
- package/packages/ui-web/src/pagination.test.tsx +0 -57
- package/packages/ui-web/src/pagination.tsx +0 -107
- package/packages/ui-web/src/popover.test.tsx +0 -31
- package/packages/ui-web/src/popover.tsx +0 -45
- package/packages/ui-web/src/progress.test.tsx +0 -18
- package/packages/ui-web/src/progress.tsx +0 -28
- package/packages/ui-web/src/radio-group.test.tsx +0 -39
- package/packages/ui-web/src/radio-group.tsx +0 -41
- package/packages/ui-web/src/resizable.test.tsx +0 -23
- package/packages/ui-web/src/resizable.tsx +0 -59
- package/packages/ui-web/src/scroll-area.test.tsx +0 -15
- package/packages/ui-web/src/scroll-area.tsx +0 -42
- package/packages/ui-web/src/search.test.tsx +0 -81
- package/packages/ui-web/src/search.tsx +0 -87
- package/packages/ui-web/src/select.test.tsx +0 -42
- package/packages/ui-web/src/select.tsx +0 -169
- package/packages/ui-web/src/separator.test.tsx +0 -16
- package/packages/ui-web/src/separator.tsx +0 -24
- package/packages/ui-web/src/setupTests.ts +0 -114
- package/packages/ui-web/src/sheet.test.tsx +0 -48
- package/packages/ui-web/src/sheet.tsx +0 -136
- package/packages/ui-web/src/skeleton.test.tsx +0 -13
- package/packages/ui-web/src/skeleton.tsx +0 -10
- package/packages/ui-web/src/slider.test.tsx +0 -18
- package/packages/ui-web/src/slider.tsx +0 -27
- package/packages/ui-web/src/sonner.test.tsx +0 -13
- package/packages/ui-web/src/sonner.tsx +0 -32
- package/packages/ui-web/src/switch.test.tsx +0 -22
- package/packages/ui-web/src/switch.tsx +0 -31
- package/packages/ui-web/src/table.test.tsx +0 -29
- package/packages/ui-web/src/table.tsx +0 -104
- package/packages/ui-web/src/tabs.test.tsx +0 -43
- package/packages/ui-web/src/tabs.tsx +0 -62
- package/packages/ui-web/src/text.test.tsx +0 -34
- package/packages/ui-web/src/text.tsx +0 -55
- package/packages/ui-web/src/textarea.test.tsx +0 -21
- package/packages/ui-web/src/textarea.tsx +0 -25
- package/packages/ui-web/src/theme-provider.tsx +0 -15
- package/packages/ui-web/src/theme-toggle.test.tsx +0 -49
- package/packages/ui-web/src/theme-toggle.tsx +0 -92
- package/packages/ui-web/src/toast.test.tsx +0 -42
- package/packages/ui-web/src/toast.tsx +0 -111
- package/packages/ui-web/src/toaster.tsx +0 -27
- package/packages/ui-web/src/toggle-group.test.tsx +0 -40
- package/packages/ui-web/src/toggle-group.tsx +0 -55
- package/packages/ui-web/src/toggle.test.tsx +0 -21
- package/packages/ui-web/src/toggle.tsx +0 -24
- package/packages/ui-web/src/tooltip.tsx +0 -51
- package/packages/ui-web/tsconfig.json +0 -24
- package/packages/ui-web/vite.config.ts +0 -21
- package/postcss.config.mjs +0 -5
- package/release-please-config.json +0 -60
- package/scripts/build-registry.ts +0 -80
- package/scripts/sync-tokens.ts +0 -86
- package/scripts/validate.ts +0 -74
- package/src/globals.css +0 -146
- package/src/index.ts +0 -4
- package/src/setupTests.ts +0 -47
- package/src/types/nativewind.d.ts +0 -19
- package/tailwind.config.js +0 -48
- package/tsconfig.build.json +0 -22
- package/tsconfig.json +0 -30
- package/tsconfig.node.json +0 -11
- package/vite.config.ts +0 -106
- package/vitest.config.ts +0 -23
- package/wrangler.toml +0 -22
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
@tailwind components;
|
|
2
|
-
@tailwind utilities;
|
|
3
|
-
|
|
4
|
-
@layer base {
|
|
5
|
-
:root {
|
|
6
|
-
--background: 0 0% 100%;
|
|
7
|
-
--foreground: 222.2 84% 4.9%;
|
|
8
|
-
--card: 0 0% 100%;
|
|
9
|
-
--card-foreground: 222.2 84% 4.9%;
|
|
10
|
-
--popover: 0 0% 100%;
|
|
11
|
-
--popover-foreground: 222.2 84% 4.9%;
|
|
12
|
-
--primary: 222.2 47.4% 11.2%;
|
|
13
|
-
--primary-foreground: 210 40% 98%;
|
|
14
|
-
--secondary: 210 40% 96.1%;
|
|
15
|
-
--secondary-foreground: 222.2 47.4% 11.2%;
|
|
16
|
-
--muted: 210 40% 96.1%;
|
|
17
|
-
--muted-foreground: 215.4 16.3% 46.9%;
|
|
18
|
-
--accent: 210 40% 96.1%;
|
|
19
|
-
--accent-foreground: 222.2 47.4% 11.2%;
|
|
20
|
-
--destructive: 0 84.2% 60.2%;
|
|
21
|
-
--destructive-foreground: 210 40% 98%;
|
|
22
|
-
--border: 214.3 31.8% 91.4%;
|
|
23
|
-
--input: 214.3 31.8% 91.4%;
|
|
24
|
-
--ring: 222.2 84% 4.9%;
|
|
25
|
-
--radius: 0.5rem;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.dark {
|
|
29
|
-
--background: 222.2 84% 4.9%;
|
|
30
|
-
--foreground: 210 40% 98%;
|
|
31
|
-
--card: 222.2 84% 4.9%;
|
|
32
|
-
--card-foreground: 210 40% 98%;
|
|
33
|
-
--popover: 222.2 84% 4.9%;
|
|
34
|
-
--popover-foreground: 210 40% 98%;
|
|
35
|
-
--primary: 210 40% 98%;
|
|
36
|
-
--primary-foreground: 222.2 47.4% 11.2%;
|
|
37
|
-
--secondary: 217.2 32.6% 17.5%;
|
|
38
|
-
--secondary-foreground: 210 40% 98%;
|
|
39
|
-
--muted: 217.2 32.6% 17.5%;
|
|
40
|
-
--muted-foreground: 215 20.2% 65.1%;
|
|
41
|
-
--accent: 217.2 32.6% 17.5%;
|
|
42
|
-
--accent-foreground: 210 40% 98%;
|
|
43
|
-
--destructive: 0 62.8% 30.6%;
|
|
44
|
-
--destructive-foreground: 210 40% 98%;
|
|
45
|
-
--border: 217.2 32.6% 17.5%;
|
|
46
|
-
--input: 217.2 32.6% 17.5%;
|
|
47
|
-
--ring: 212.7 26.8% 83.9%;
|
|
48
|
-
}
|
|
49
|
-
}
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
const { theme: designTokens } = require('../../packages/design-tokens/src/theme');
|
|
2
|
-
|
|
3
|
-
/** @type {import('tailwindcss').Config} */
|
|
4
|
-
module.exports = {
|
|
5
|
-
// NOTE: NativeWind v4 uses the same content pattern as Tailwind
|
|
6
|
-
content: ['./src/**/*.{js,ts,jsx,tsx}', '../../packages/ui-native/src/**/*.{js,ts,jsx,tsx}'],
|
|
7
|
-
presets: [require('nativewind/preset')],
|
|
8
|
-
theme: {
|
|
9
|
-
extend: {
|
|
10
|
-
colors: {
|
|
11
|
-
background: 'hsl(var(--background))',
|
|
12
|
-
foreground: 'hsl(var(--foreground))',
|
|
13
|
-
primary: {
|
|
14
|
-
DEFAULT: 'hsl(var(--primary))',
|
|
15
|
-
foreground: 'hsl(var(--primary-foreground))',
|
|
16
|
-
},
|
|
17
|
-
secondary: {
|
|
18
|
-
DEFAULT: 'hsl(var(--secondary))',
|
|
19
|
-
foreground: 'hsl(var(--secondary-foreground))',
|
|
20
|
-
},
|
|
21
|
-
destructive: {
|
|
22
|
-
DEFAULT: 'hsl(var(--destructive))',
|
|
23
|
-
foreground: 'hsl(var(--destructive-foreground))',
|
|
24
|
-
},
|
|
25
|
-
muted: {
|
|
26
|
-
DEFAULT: 'hsl(var(--muted))',
|
|
27
|
-
foreground: 'hsl(var(--muted-foreground))',
|
|
28
|
-
},
|
|
29
|
-
accent: {
|
|
30
|
-
DEFAULT: 'hsl(var(--accent))',
|
|
31
|
-
foreground: 'hsl(var(--accent-foreground))',
|
|
32
|
-
},
|
|
33
|
-
popover: {
|
|
34
|
-
DEFAULT: 'hsl(var(--popover))',
|
|
35
|
-
foreground: 'hsl(var(--popover-foreground))',
|
|
36
|
-
},
|
|
37
|
-
card: {
|
|
38
|
-
DEFAULT: 'hsl(var(--card))',
|
|
39
|
-
foreground: 'hsl(var(--card-foreground))',
|
|
40
|
-
},
|
|
41
|
-
border: 'hsl(var(--border))',
|
|
42
|
-
input: 'hsl(var(--input))',
|
|
43
|
-
ring: 'hsl(var(--ring))',
|
|
44
|
-
},
|
|
45
|
-
borderRadius: designTokens.light.radius,
|
|
46
|
-
},
|
|
47
|
-
},
|
|
48
|
-
plugins: [],
|
|
49
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": "./tsconfig.json",
|
|
3
|
-
"compilerOptions": {
|
|
4
|
-
"outDir": "../../dist/out-tsc",
|
|
5
|
-
"types": ["node", "nativewind/types"]
|
|
6
|
-
},
|
|
7
|
-
"files": ["../../node_modules/@nx/expo/typings/svg.d.ts"],
|
|
8
|
-
"exclude": [
|
|
9
|
-
"**/*.test.ts",
|
|
10
|
-
"**/*.spec.ts",
|
|
11
|
-
"**/*.test.tsx",
|
|
12
|
-
"**/*.spec.tsx",
|
|
13
|
-
"**/*.test.js",
|
|
14
|
-
"**/*.spec.js",
|
|
15
|
-
"**/*.test.jsx",
|
|
16
|
-
"**/*.spec.jsx",
|
|
17
|
-
"src/test-setup.ts",
|
|
18
|
-
"jest.config.ts",
|
|
19
|
-
"jest.config.cts",
|
|
20
|
-
"src/**/*.spec.ts",
|
|
21
|
-
"src/**/*.test.ts"
|
|
22
|
-
],
|
|
23
|
-
"include": ["**/*.ts", "**/*.tsx", "**/*.js", "**/*.jsx", ".expo/types/**/*.ts", "expo-env.d.ts"]
|
|
24
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": "../../tsconfig.base.json",
|
|
3
|
-
"compilerOptions": {
|
|
4
|
-
"allowSyntheticDefaultImports": true,
|
|
5
|
-
"jsx": "react-native",
|
|
6
|
-
"lib": ["dom", "esnext"],
|
|
7
|
-
"moduleResolution": "node",
|
|
8
|
-
"skipLibCheck": true,
|
|
9
|
-
"resolveJsonModule": true,
|
|
10
|
-
"strict": true,
|
|
11
|
-
"declaration": true
|
|
12
|
-
},
|
|
13
|
-
"files": [],
|
|
14
|
-
"include": [],
|
|
15
|
-
"references": [
|
|
16
|
-
{
|
|
17
|
-
"path": "./tsconfig.app.json"
|
|
18
|
-
},
|
|
19
|
-
{
|
|
20
|
-
"path": "./tsconfig.spec.json"
|
|
21
|
-
}
|
|
22
|
-
]
|
|
23
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": "./tsconfig.json",
|
|
3
|
-
"compilerOptions": {
|
|
4
|
-
"outDir": "../../dist/out-tsc",
|
|
5
|
-
"module": "commonjs",
|
|
6
|
-
"moduleResolution": "node10",
|
|
7
|
-
"jsx": "react-jsx",
|
|
8
|
-
"types": ["jest", "node"]
|
|
9
|
-
},
|
|
10
|
-
"files": ["src/test-setup.ts"],
|
|
11
|
-
"include": [
|
|
12
|
-
"jest.config.ts",
|
|
13
|
-
"jest.config.cts",
|
|
14
|
-
"src/**/*.test.ts",
|
|
15
|
-
"src/**/*.spec.ts",
|
|
16
|
-
"src/**/*.test.tsx",
|
|
17
|
-
"src/**/*.spec.tsx",
|
|
18
|
-
"src/**/*.test.js",
|
|
19
|
-
"src/**/*.spec.js",
|
|
20
|
-
"src/**/*.test.jsx",
|
|
21
|
-
"src/**/*.spec.jsx",
|
|
22
|
-
"src/**/*.d.ts"
|
|
23
|
-
]
|
|
24
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
# Changelog
|
|
2
|
-
|
|
3
|
-
## [0.1.0](https://github.com/Garcia-Ventures/gvtech-design/compare/playground-web-v0.0.1...playground-web-v0.1.0) (2026-02-20)
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
### Features
|
|
7
|
-
|
|
8
|
-
* **universal:** pivot to monorepo architecture and stabilize react native support ([#63](https://github.com/Garcia-Ventures/gvtech-design/issues/63)) ([3458938](https://github.com/Garcia-Ventures/gvtech-design/commit/3458938c17bdfc7a7f5eea0053b7bf1786a571fa))
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
<!doctype html>
|
|
2
|
-
<html lang="en">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="UTF-8" />
|
|
5
|
-
<link rel="icon" type="image/png" href="/favicon.png" />
|
|
6
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
7
|
-
<title>GV Tech Design System Playground</title>
|
|
8
|
-
</head>
|
|
9
|
-
<body>
|
|
10
|
-
<div id="root"></div>
|
|
11
|
-
<script type="module" src="/src/main.tsx"></script>
|
|
12
|
-
</body>
|
|
13
|
-
</html>
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "playground-web",
|
|
3
|
-
"version": "0.1.0",
|
|
4
|
-
"private": true,
|
|
5
|
-
"scripts": {
|
|
6
|
-
"build": "vite build",
|
|
7
|
-
"dev": "vite",
|
|
8
|
-
"preview": "vite preview",
|
|
9
|
-
"typecheck": "yarn tsc --noEmit"
|
|
10
|
-
},
|
|
11
|
-
"dependencies": {
|
|
12
|
-
"@gv-tech/design-tokens": "workspace:*",
|
|
13
|
-
"@gv-tech/ui-core": "workspace:*",
|
|
14
|
-
"@gv-tech/ui-web": "workspace:*",
|
|
15
|
-
"lucide-react": "^0.563.0",
|
|
16
|
-
"next-themes": "^0.4.6",
|
|
17
|
-
"react": "19.2.4",
|
|
18
|
-
"react-dom": "19.2.4",
|
|
19
|
-
"react-router-dom": "^7.13.0",
|
|
20
|
-
"recharts": "2.15.4",
|
|
21
|
-
"sonner": "^2.0.7"
|
|
22
|
-
},
|
|
23
|
-
"devDependencies": {
|
|
24
|
-
"@vitejs/plugin-react-swc": "^4.2.3",
|
|
25
|
-
"autoprefixer": "^10.4.18",
|
|
26
|
-
"postcss": "^8.5.6",
|
|
27
|
-
"tailwindcss": "4.1.18",
|
|
28
|
-
"typescript": "^5.9.3",
|
|
29
|
-
"vite": "7.3.1"
|
|
30
|
-
}
|
|
31
|
-
}
|
|
Binary file
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
<!doctype html>
|
|
2
|
-
<html lang="en">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="utf-8" />
|
|
5
|
-
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
|
|
6
|
-
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
7
|
-
<meta name="theme-color" content="#000000" />
|
|
8
|
-
<meta name="description" content="Garcia Ventures design system" />
|
|
9
|
-
<link rel="apple-touch-icon" href="logo192.png" />
|
|
10
|
-
<!--
|
|
11
|
-
manifest.json provides metadata used when your web app is installed on a
|
|
12
|
-
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
|
|
13
|
-
-->
|
|
14
|
-
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
|
|
15
|
-
<!--
|
|
16
|
-
Notice the use of %PUBLIC_URL% in the tags above.
|
|
17
|
-
It will be replaced with the URL of the `public` folder during the build.
|
|
18
|
-
Only files inside the `public` folder can be referenced from the HTML.
|
|
19
|
-
|
|
20
|
-
Unlike "/favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
|
|
21
|
-
work correctly both with client-side routing and a non-root public URL.
|
|
22
|
-
Learn how to configure a non-root public URL by running `npm run build`.
|
|
23
|
-
-->
|
|
24
|
-
<title>GV Tech Design System</title>
|
|
25
|
-
</head>
|
|
26
|
-
<body>
|
|
27
|
-
<noscript>You need to enable JavaScript to run this app.</noscript>
|
|
28
|
-
<div id="root"></div>
|
|
29
|
-
<!--
|
|
30
|
-
This HTML file is a template.
|
|
31
|
-
If you open it directly in the browser, you will see an empty page.
|
|
32
|
-
|
|
33
|
-
You can add webfonts, meta tags, or analytics to this file.
|
|
34
|
-
The build step will place the bundled scripts into the <body> tag.
|
|
35
|
-
|
|
36
|
-
To begin the development, run `npm start` or `yarn start`.
|
|
37
|
-
To create a production bundle, use `npm run build` or `yarn build`.
|
|
38
|
-
-->
|
|
39
|
-
</body>
|
|
40
|
-
</html>
|
|
Binary file
|
|
Binary file
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"short_name": "GV Design",
|
|
3
|
-
"name": "GV Tech Design System",
|
|
4
|
-
"icons": [
|
|
5
|
-
{
|
|
6
|
-
"src": "favicon.png",
|
|
7
|
-
"sizes": "512x512",
|
|
8
|
-
"type": "image/png"
|
|
9
|
-
},
|
|
10
|
-
{
|
|
11
|
-
"src": "logo192.png",
|
|
12
|
-
"type": "image/png",
|
|
13
|
-
"sizes": "192x192"
|
|
14
|
-
},
|
|
15
|
-
{
|
|
16
|
-
"src": "logo512.png",
|
|
17
|
-
"type": "image/png",
|
|
18
|
-
"sizes": "512x512"
|
|
19
|
-
}
|
|
20
|
-
],
|
|
21
|
-
"start_url": ".",
|
|
22
|
-
"display": "standalone",
|
|
23
|
-
"theme_color": "#000000",
|
|
24
|
-
"background_color": "#ffffff"
|
|
25
|
-
}
|
|
@@ -1,179 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
Breadcrumb,
|
|
3
|
-
BreadcrumbItem,
|
|
4
|
-
BreadcrumbLink,
|
|
5
|
-
BreadcrumbList,
|
|
6
|
-
BreadcrumbPage,
|
|
7
|
-
BreadcrumbSeparator,
|
|
8
|
-
Button,
|
|
9
|
-
ScrollArea,
|
|
10
|
-
Sheet,
|
|
11
|
-
SheetContent,
|
|
12
|
-
SheetDescription,
|
|
13
|
-
SheetHeader,
|
|
14
|
-
SheetTitle,
|
|
15
|
-
SheetTrigger,
|
|
16
|
-
SonnerToaster,
|
|
17
|
-
ThemeProvider,
|
|
18
|
-
ThemeToggle,
|
|
19
|
-
Toaster,
|
|
20
|
-
TooltipProvider,
|
|
21
|
-
} from '@gv-tech/ui-web';
|
|
22
|
-
import { Loader2, Menu } from 'lucide-react';
|
|
23
|
-
import * as React from 'react';
|
|
24
|
-
import { BrowserRouter, Link, Navigate, Route, Routes, useLocation, useNavigate } from 'react-router-dom';
|
|
25
|
-
import { CombinedDocsLayout, DocSearch, DocSearchProvider, ErrorBoundary, Footer, Sidebar } from './components/docs';
|
|
26
|
-
import { docConfig } from './config/docs';
|
|
27
|
-
|
|
28
|
-
import { docRoutes } from './routes/doc-routes';
|
|
29
|
-
|
|
30
|
-
// Lazy load docs pages
|
|
31
|
-
import { PackageManagerProvider } from './hooks/usePackageManager';
|
|
32
|
-
|
|
33
|
-
const ColorTokensDocs = React.lazy(() => import('./pages').then((m) => ({ default: m.ColorTokensDocs })));
|
|
34
|
-
const GettingStartedPage = React.lazy(() => import('./pages').then((m) => ({ default: m.GettingStartedPage })));
|
|
35
|
-
const InstallationPage = React.lazy(() => import('./pages').then((m) => ({ default: m.InstallationPage })));
|
|
36
|
-
|
|
37
|
-
function PageLoader() {
|
|
38
|
-
return (
|
|
39
|
-
<div className="flex h-[400px] w-full items-center justify-center">
|
|
40
|
-
<Loader2 className="h-8 w-8 animate-spin text-muted-foreground" />
|
|
41
|
-
</div>
|
|
42
|
-
);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
function DocumentationLayout() {
|
|
46
|
-
const navigate = useNavigate();
|
|
47
|
-
const location = useLocation();
|
|
48
|
-
const [isSidebarOpen, setIsSidebarOpen] = React.useState(false);
|
|
49
|
-
|
|
50
|
-
// Find current doc based on URL path
|
|
51
|
-
const pathParts = location.pathname.split('/');
|
|
52
|
-
const docSlug = pathParts[2] || 'getting-started';
|
|
53
|
-
|
|
54
|
-
const currentDoc = React.useMemo(() => {
|
|
55
|
-
for (const category of docConfig) {
|
|
56
|
-
const found = category.items.find((item) => item.href === docSlug);
|
|
57
|
-
if (found) return found;
|
|
58
|
-
}
|
|
59
|
-
return null;
|
|
60
|
-
}, [docSlug]);
|
|
61
|
-
|
|
62
|
-
React.useEffect(() => {
|
|
63
|
-
if (!location.pathname.startsWith('/docs')) {
|
|
64
|
-
navigate('/docs/getting-started', { replace: true });
|
|
65
|
-
}
|
|
66
|
-
}, [location.pathname, navigate]);
|
|
67
|
-
|
|
68
|
-
return (
|
|
69
|
-
<DocSearchProvider>
|
|
70
|
-
<PackageManagerProvider>
|
|
71
|
-
<div className="flex h-screen bg-background text-foreground">
|
|
72
|
-
{/* Desktop Sidebar */}
|
|
73
|
-
<div className="hidden lg:flex h-full shrink-0">
|
|
74
|
-
<Sidebar />
|
|
75
|
-
</div>
|
|
76
|
-
|
|
77
|
-
<div className="flex-1 flex flex-col overflow-hidden">
|
|
78
|
-
<header className="h-14 border-b flex items-center justify-between px-4 md:px-6 shrink-0 bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60 sticky top-0 z-50">
|
|
79
|
-
<div className="flex items-center gap-2 min-w-0">
|
|
80
|
-
{/* Mobile Menu Toggle */}
|
|
81
|
-
<Sheet open={isSidebarOpen} onOpenChange={setIsSidebarOpen}>
|
|
82
|
-
<SheetTrigger asChild>
|
|
83
|
-
<Button variant="ghost" size="icon" className="lg:hidden shrink-0">
|
|
84
|
-
<Menu className="h-5 w-5" />
|
|
85
|
-
<span className="sr-only">Toggle menu</span>
|
|
86
|
-
</Button>
|
|
87
|
-
</SheetTrigger>
|
|
88
|
-
<SheetContent side="left" className="p-0 w-72">
|
|
89
|
-
<SheetHeader className="sr-only">
|
|
90
|
-
<SheetTitle>Navigation Menu</SheetTitle>
|
|
91
|
-
<SheetDescription>
|
|
92
|
-
Explore the components and documentation for GV Tech Design System.
|
|
93
|
-
</SheetDescription>
|
|
94
|
-
</SheetHeader>
|
|
95
|
-
<Sidebar className="w-full border-none" onLinkClick={() => setIsSidebarOpen(false)} />
|
|
96
|
-
</SheetContent>
|
|
97
|
-
</Sheet>
|
|
98
|
-
|
|
99
|
-
<Breadcrumb className="hidden md:flex min-w-0">
|
|
100
|
-
<BreadcrumbList>
|
|
101
|
-
<BreadcrumbItem>
|
|
102
|
-
<BreadcrumbLink asChild>
|
|
103
|
-
<Link to="/docs/getting-started">Docs</Link>
|
|
104
|
-
</BreadcrumbLink>
|
|
105
|
-
</BreadcrumbItem>
|
|
106
|
-
<BreadcrumbSeparator />
|
|
107
|
-
<BreadcrumbItem>
|
|
108
|
-
<BreadcrumbPage>{currentDoc?.title || 'Documentation'}</BreadcrumbPage>
|
|
109
|
-
</BreadcrumbItem>
|
|
110
|
-
</BreadcrumbList>
|
|
111
|
-
</Breadcrumb>
|
|
112
|
-
</div>
|
|
113
|
-
|
|
114
|
-
<div className="flex items-center gap-2 md:gap-4 shrink-0">
|
|
115
|
-
<DocSearch variant="compact" />
|
|
116
|
-
<ThemeToggle variant="ternary" />
|
|
117
|
-
</div>
|
|
118
|
-
</header>
|
|
119
|
-
<ScrollArea className="flex-1">
|
|
120
|
-
<main className="flex-1 flex flex-col p-4 md:p-8 max-w-4xl mx-auto w-full">
|
|
121
|
-
<div className="flex-1">
|
|
122
|
-
<ErrorBoundary>
|
|
123
|
-
<React.Suspense fallback={<PageLoader />}>
|
|
124
|
-
<Routes>
|
|
125
|
-
{/* Getting Started */}
|
|
126
|
-
<Route path="getting-started" element={<GettingStartedPage />} />
|
|
127
|
-
<Route path="installation" element={<InstallationPage />} />
|
|
128
|
-
<Route path="theming" element={<ColorTokensDocs />} />
|
|
129
|
-
<Route path="color-tokens" element={<Navigate to="/docs/theming" replace />} />
|
|
130
|
-
|
|
131
|
-
{/* Dynamic Component Routes */}
|
|
132
|
-
{docRoutes.map((route) => (
|
|
133
|
-
<Route
|
|
134
|
-
key={route.path}
|
|
135
|
-
path={route.path}
|
|
136
|
-
element={
|
|
137
|
-
<CombinedDocsLayout
|
|
138
|
-
title={route.title}
|
|
139
|
-
description={route.description}
|
|
140
|
-
web={route.web ? <route.web /> : undefined}
|
|
141
|
-
native={route.native ? <route.native /> : undefined}
|
|
142
|
-
/>
|
|
143
|
-
}
|
|
144
|
-
/>
|
|
145
|
-
))}
|
|
146
|
-
|
|
147
|
-
<Route path="*" element={<Navigate to="/docs/getting-started" replace />} />
|
|
148
|
-
</Routes>
|
|
149
|
-
</React.Suspense>
|
|
150
|
-
</ErrorBoundary>
|
|
151
|
-
</div>
|
|
152
|
-
<Footer />
|
|
153
|
-
</main>
|
|
154
|
-
</ScrollArea>
|
|
155
|
-
</div>
|
|
156
|
-
</div>
|
|
157
|
-
</PackageManagerProvider>
|
|
158
|
-
</DocSearchProvider>
|
|
159
|
-
);
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
function App() {
|
|
163
|
-
return (
|
|
164
|
-
<ThemeProvider>
|
|
165
|
-
<TooltipProvider>
|
|
166
|
-
<BrowserRouter>
|
|
167
|
-
<Routes>
|
|
168
|
-
<Route path="/" element={<Navigate to="/docs/getting-started" replace />} />
|
|
169
|
-
<Route path="/docs/*" element={<DocumentationLayout />} />
|
|
170
|
-
</Routes>
|
|
171
|
-
</BrowserRouter>
|
|
172
|
-
<Toaster />
|
|
173
|
-
<SonnerToaster />
|
|
174
|
-
</TooltipProvider>
|
|
175
|
-
</ThemeProvider>
|
|
176
|
-
);
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
export default App;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { cn } from '@gv-tech/ui-web';
|
|
2
|
-
import { Check, Copy } from 'lucide-react';
|
|
3
|
-
import * as React from 'react';
|
|
4
|
-
|
|
5
|
-
interface CodeBlockProps {
|
|
6
|
-
code: string;
|
|
7
|
-
language?: string;
|
|
8
|
-
className?: string;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
export function CodeBlock({ code, language = 'tsx', className }: CodeBlockProps) {
|
|
12
|
-
const [copied, setCopied] = React.useState(false);
|
|
13
|
-
|
|
14
|
-
const copyToClipboard = async () => {
|
|
15
|
-
await navigator.clipboard.writeText(code);
|
|
16
|
-
setCopied(true);
|
|
17
|
-
setTimeout(() => setCopied(false), 2000);
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
return (
|
|
21
|
-
<div className={cn('relative group', className)}>
|
|
22
|
-
<pre className="bg-zinc-950 text-zinc-100 rounded-lg p-4 overflow-x-auto text-sm font-mono">
|
|
23
|
-
<code className={`language-${language}`}>{code.trim()}</code>
|
|
24
|
-
</pre>
|
|
25
|
-
<button
|
|
26
|
-
onClick={copyToClipboard}
|
|
27
|
-
className="absolute top-3 right-3 p-2 rounded-md bg-zinc-800 text-zinc-400 hover:text-zinc-100 hover:bg-zinc-700 transition-colors opacity-0 group-hover:opacity-100"
|
|
28
|
-
aria-label="Copy code"
|
|
29
|
-
>
|
|
30
|
-
{copied ? <Check className="h-4 w-4 text-green-500" /> : <Copy className="h-4 w-4" />}
|
|
31
|
-
</button>
|
|
32
|
-
</div>
|
|
33
|
-
);
|
|
34
|
-
}
|
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
import { useDocMetadata } from '@/hooks/useDocMetadata';
|
|
2
|
-
import { Tabs, TabsContent, TabsList, TabsTrigger } from '@gv-tech/ui-web';
|
|
3
|
-
import { Info } from 'lucide-react';
|
|
4
|
-
import React from 'react';
|
|
5
|
-
|
|
6
|
-
interface CombinedDocsLayoutProps {
|
|
7
|
-
title?: string;
|
|
8
|
-
description?: string;
|
|
9
|
-
web?: React.ReactNode;
|
|
10
|
-
native?: React.ReactNode;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
export const PlatformContext = React.createContext<'web' | 'native'>('web');
|
|
14
|
-
|
|
15
|
-
export function CombinedDocsLayout({ title, description, web, native }: CombinedDocsLayoutProps) {
|
|
16
|
-
useDocMetadata({
|
|
17
|
-
title: title || 'Documentation',
|
|
18
|
-
description: description || 'GV Tech Design System documentation.',
|
|
19
|
-
});
|
|
20
|
-
// Use localStorage to persist platform preference
|
|
21
|
-
const [activeTab, setActiveTab] = React.useState<'web' | 'native'>(() => {
|
|
22
|
-
// Check if there is a saved preference
|
|
23
|
-
const saved = typeof window !== 'undefined' ? localStorage.getItem('gv-docs-platform') : null;
|
|
24
|
-
if (saved === 'web' || saved === 'native') {
|
|
25
|
-
// Ensure the saved preference is actually available for this component
|
|
26
|
-
if (saved === 'web' && web) return 'web';
|
|
27
|
-
if (saved === 'native' && native) return 'native';
|
|
28
|
-
}
|
|
29
|
-
// Default to web if available, otherwise native
|
|
30
|
-
return web ? 'web' : 'native';
|
|
31
|
-
});
|
|
32
|
-
|
|
33
|
-
// When navigating between pages, React Router reuses this component without
|
|
34
|
-
// remounting, so the useState initializer won't re-run. Sync activeTab
|
|
35
|
-
// whenever the set of available platforms changes to avoid showing a blank tab.
|
|
36
|
-
React.useEffect(() => {
|
|
37
|
-
if (activeTab === 'native' && !native) {
|
|
38
|
-
setActiveTab(web ? 'web' : 'native');
|
|
39
|
-
} else if (activeTab === 'web' && !web && native) {
|
|
40
|
-
setActiveTab('native');
|
|
41
|
-
}
|
|
42
|
-
}, [web, native, activeTab]);
|
|
43
|
-
|
|
44
|
-
const onTabChange = (value: string) => {
|
|
45
|
-
const newTab = value as 'web' | 'native';
|
|
46
|
-
setActiveTab(newTab);
|
|
47
|
-
localStorage.setItem('gv-docs-platform', newTab);
|
|
48
|
-
};
|
|
49
|
-
|
|
50
|
-
return (
|
|
51
|
-
<div className="space-y-6">
|
|
52
|
-
<div className="space-y-2">
|
|
53
|
-
<h1 className="text-2xl md:text-3xl font-bold tracking-tight">{title}</h1>
|
|
54
|
-
{description && <p className="text-base md:text-lg text-muted-foreground">{description}</p>}
|
|
55
|
-
</div>
|
|
56
|
-
|
|
57
|
-
<Tabs value={activeTab} onValueChange={onTabChange} className="w-full">
|
|
58
|
-
<TabsList className="w-full justify-start rounded-none border-b bg-transparent p-0">
|
|
59
|
-
{web && (
|
|
60
|
-
<TabsTrigger
|
|
61
|
-
value="web"
|
|
62
|
-
className="relative h-9 rounded-none border-b-2 border-transparent bg-transparent px-4 pb-3 pt-2 font-semibold text-muted-foreground shadow-none transition-none data-[state=active]:border-primary data-[state=active]:text-foreground data-[state=active]:shadow-none"
|
|
63
|
-
>
|
|
64
|
-
Web
|
|
65
|
-
</TabsTrigger>
|
|
66
|
-
)}
|
|
67
|
-
{native && (
|
|
68
|
-
<TabsTrigger
|
|
69
|
-
value="native"
|
|
70
|
-
className="relative h-9 rounded-none border-b-2 border-transparent bg-transparent px-4 pb-3 pt-2 font-semibold text-muted-foreground shadow-none transition-none data-[state=active]:border-primary data-[state=active]:text-foreground data-[state=active]:shadow-none"
|
|
71
|
-
>
|
|
72
|
-
Native
|
|
73
|
-
</TabsTrigger>
|
|
74
|
-
)}
|
|
75
|
-
</TabsList>
|
|
76
|
-
{web && (
|
|
77
|
-
<TabsContent value="web" className="mt-8 md:mt-10 border-none p-0 outline-none">
|
|
78
|
-
<PlatformContext.Provider value="web">
|
|
79
|
-
<div className="space-y-10 md:space-y-12">{web}</div>
|
|
80
|
-
</PlatformContext.Provider>
|
|
81
|
-
</TabsContent>
|
|
82
|
-
)}
|
|
83
|
-
{native && (
|
|
84
|
-
<TabsContent value="native" className="mt-8 md:mt-10 border-none p-0 outline-none">
|
|
85
|
-
<PlatformContext.Provider value="native">
|
|
86
|
-
<div className="rounded-lg bg-blue-500/10 border border-blue-500/20 p-4 mb-6 flex gap-3 text-blue-500">
|
|
87
|
-
<Info className="h-5 w-5 shrink-0" />
|
|
88
|
-
<div className="text-sm">
|
|
89
|
-
<p className="font-semibold">Native Implementation</p>
|
|
90
|
-
<p className="opacity-90">
|
|
91
|
-
These components are built for React Native environments. Previews below show implementation details
|
|
92
|
-
and code samples.
|
|
93
|
-
</p>
|
|
94
|
-
</div>
|
|
95
|
-
</div>
|
|
96
|
-
<div className="space-y-10 md:space-y-12">{native}</div>
|
|
97
|
-
</PlatformContext.Provider>
|
|
98
|
-
</TabsContent>
|
|
99
|
-
)}
|
|
100
|
-
</Tabs>
|
|
101
|
-
</div>
|
|
102
|
-
);
|
|
103
|
-
}
|