banhaten 0.1.2 → 0.2.0
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 +45 -0
- package/CONTRIBUTING.md +44 -0
- package/README.md +145 -328
- package/SECURITY.md +15 -0
- package/banhaten.config.example.json +1 -3
- package/docs/design-system/README.md +20 -0
- package/docs/design-system/adoption-quality-remediation.md +87 -0
- package/docs/design-system/agent-usage.md +13 -0
- package/docs/design-system/appearance-presets.md +189 -0
- package/docs/design-system/appearances/default.md +94 -0
- package/docs/design-system/appearances/rounded.md +95 -0
- package/docs/design-system/appearances/sharp.md +95 -0
- package/docs/design-system/component-docs-pattern.md +81 -0
- package/docs/design-system/component-showcase-consistency-report.md +217 -0
- package/docs/design-system/component-token-consistency-audit.md +173 -0
- package/docs/design-system/components/README.md +75 -0
- package/docs/design-system/components/accordion.md +67 -0
- package/docs/design-system/components/activity-feed.md +106 -0
- package/docs/design-system/components/alert-dialog.md +87 -0
- package/docs/design-system/components/alert.md +111 -0
- package/docs/design-system/components/aspect-ratio.md +59 -0
- package/docs/design-system/components/attribute.md +103 -0
- package/docs/design-system/components/autocomplete.md +93 -0
- package/docs/design-system/components/avatar.md +70 -0
- package/docs/design-system/components/badge.md +72 -0
- package/docs/design-system/components/banner.md +99 -0
- package/docs/design-system/components/breadcrumbs.md +188 -0
- package/docs/design-system/components/button-group.md +117 -0
- package/docs/design-system/components/button.md +95 -0
- package/docs/design-system/components/card.md +95 -0
- package/docs/design-system/components/carousel.md +61 -0
- package/docs/design-system/components/catalog-components.md +59 -0
- package/docs/design-system/components/chart.md +58 -0
- package/docs/design-system/components/checkbox.md +68 -0
- package/docs/design-system/components/collapsible.md +63 -0
- package/docs/design-system/components/command.md +75 -0
- package/docs/design-system/components/context-menu.md +59 -0
- package/docs/design-system/components/date-picker.md +97 -0
- package/docs/design-system/components/divider.md +117 -0
- package/docs/design-system/components/empty-state.md +72 -0
- package/docs/design-system/components/field.md +86 -0
- package/docs/design-system/components/file-upload.md +199 -0
- package/docs/design-system/components/hover-card.md +61 -0
- package/docs/design-system/components/icons.md +48 -0
- package/docs/design-system/components/input-group.md +73 -0
- package/docs/design-system/components/input-otp.md +73 -0
- package/docs/design-system/components/input.md +84 -0
- package/docs/design-system/components/item.md +72 -0
- package/docs/design-system/components/kbd.md +62 -0
- package/docs/design-system/components/label.md +64 -0
- package/docs/design-system/components/menu.md +76 -0
- package/docs/design-system/components/menubar.md +60 -0
- package/docs/design-system/components/modal.md +119 -0
- package/docs/design-system/components/native-select.md +70 -0
- package/docs/design-system/components/navigation-menu.md +63 -0
- package/docs/design-system/components/onboarding-step-list-item.md +94 -0
- package/docs/design-system/components/page-header.md +98 -0
- package/docs/design-system/components/pagination.md +71 -0
- package/docs/design-system/components/popover.md +77 -0
- package/docs/design-system/components/progress-slider.md +66 -0
- package/docs/design-system/components/progress.md +92 -0
- package/docs/design-system/components/radio-card.md +65 -0
- package/docs/design-system/components/radio-group.md +72 -0
- package/docs/design-system/components/resizable.md +57 -0
- package/docs/design-system/components/scroll-area.md +60 -0
- package/docs/design-system/components/segmented-control.md +71 -0
- package/docs/design-system/components/select.md +87 -0
- package/docs/design-system/components/sheet.md +82 -0
- package/docs/design-system/components/sidebar.md +83 -0
- package/docs/design-system/components/skeleton.md +91 -0
- package/docs/design-system/components/slideout.md +77 -0
- package/docs/design-system/components/slider.md +81 -0
- package/docs/design-system/components/social-button.md +65 -0
- package/docs/design-system/components/spinner.md +77 -0
- package/docs/design-system/components/steps.md +77 -0
- package/docs/design-system/components/table.md +411 -0
- package/docs/design-system/components/tabs.md +69 -0
- package/docs/design-system/components/tag.md +95 -0
- package/docs/design-system/components/textarea.md +64 -0
- package/docs/design-system/components/timeline.md +95 -0
- package/docs/design-system/components/toast.md +73 -0
- package/docs/design-system/components/toggle.md +96 -0
- package/docs/design-system/components/toolbar.md +105 -0
- package/docs/design-system/components/tooltip.md +107 -0
- package/docs/design-system/components/typography.md +18 -0
- package/docs/design-system/density-and-elevation.md +44 -0
- package/docs/design-system/design-system-test-missing-items.md +368 -0
- package/docs/design-system/direction-and-localization.md +23 -0
- package/docs/design-system/form-recipes.md +73 -0
- package/docs/design-system/gap-promotion-policy.md +21 -0
- package/docs/design-system/gap-promotion-report.md +166 -0
- package/docs/design-system/icons.md +69 -0
- package/docs/design-system/installation.md +68 -0
- package/docs/design-system/launch-comparison-shadcn.md +98 -0
- package/docs/design-system/registry-and-cli.md +64 -0
- package/docs/design-system/release-policy.md +30 -0
- package/docs/design-system/roadmap.md +14 -0
- package/docs/design-system/support-matrix.md +23 -0
- package/docs/design-system/tabs.md +53 -0
- package/docs/design-system/token-governance.md +60 -0
- package/package.json +97 -65
- package/registry/component-contract.json +40 -0
- package/registry/components/alert-dialog.tsx +297 -0
- package/registry/components/alert.tsx +86 -65
- package/registry/components/aspect-ratio.tsx +30 -0
- package/registry/components/autocomplete.tsx +23 -9
- package/registry/components/avatar.tsx +7 -7
- package/registry/components/badge.tsx +1 -1
- package/registry/components/button-group.tsx +321 -4
- package/registry/components/button.tsx +38 -17
- package/registry/components/card.tsx +68 -59
- package/registry/components/carousel.tsx +282 -0
- package/registry/components/chart.tsx +203 -0
- package/registry/components/checkbox.tsx +3 -3
- package/registry/components/collapsible.tsx +69 -0
- package/registry/components/command.tsx +174 -0
- package/registry/components/context-menu.tsx +236 -0
- package/registry/components/date-picker.tsx +246 -105
- package/registry/components/expanded/ActivityFeed.tsx +6 -15
- package/registry/components/expanded/Banner.tsx +3 -3
- package/registry/components/expanded/Breadcrumbs.tsx +5 -5
- package/registry/components/expanded/CatalogComponentsShowcase.tsx +13 -13
- package/registry/components/expanded/CatalogDivider.tsx +1 -1
- package/registry/components/expanded/EmptyState.tsx +1 -1
- package/registry/components/expanded/FileUpload.tsx +9 -2
- package/registry/components/expanded/OnboardingStepListItem.tsx +2 -4
- package/registry/components/expanded/PageHeader.tsx +14 -14
- package/registry/components/expanded/Slideout.tsx +15 -415
- package/registry/components/expanded/Steps.tsx +4 -4
- package/registry/components/expanded/Table.tsx +116 -69
- package/registry/components/expanded/Timeline.tsx +3 -3
- package/registry/components/expanded/activityFeed.css +1 -1
- package/registry/components/expanded/breadcrumbs.css +139 -139
- package/registry/components/expanded/catalogComponentsShowcase.css +83 -83
- package/registry/components/expanded/divider.css +1 -1
- package/registry/components/expanded/emptyState.css +1 -1
- package/registry/components/expanded/fileUpload.css +6 -6
- package/registry/components/expanded/slideout.css +9 -685
- package/registry/components/expanded/steps.css +274 -274
- package/registry/components/expanded/table.css +2 -2
- package/registry/components/expanded/timeline.css +264 -264
- package/registry/components/field.tsx +230 -0
- package/registry/components/hover-card.tsx +48 -0
- package/registry/components/input-content.ts +1 -0
- package/registry/components/input-group.tsx +130 -0
- package/registry/components/input-otp.tsx +13 -3
- package/registry/components/input.tsx +70 -45
- package/registry/components/item.tsx +189 -0
- package/registry/components/kbd.tsx +151 -0
- package/registry/components/label.tsx +78 -0
- package/registry/components/menu.tsx +34 -246
- package/registry/components/menubar.tsx +226 -0
- package/registry/components/modal.tsx +216 -143
- package/registry/components/native-select.tsx +205 -0
- package/registry/components/navigation-menu.tsx +171 -0
- package/registry/components/pagination.tsx +80 -58
- package/registry/components/popover.tsx +162 -664
- package/registry/components/radio-card.tsx +116 -87
- package/registry/components/radio-group.tsx +1 -1
- package/registry/components/resizable.tsx +74 -0
- package/registry/components/scroll-area.tsx +67 -0
- package/registry/components/segmented-control.tsx +87 -0
- package/registry/components/select-content.tsx +2 -2
- package/registry/components/select.tsx +54 -20
- package/registry/components/sheet.tsx +305 -0
- package/registry/components/sidebar.tsx +352 -0
- package/registry/components/skeleton.css +0 -3
- package/registry/components/social-button.tsx +116 -30
- package/registry/components/spinner.tsx +18 -55
- package/registry/components/{expanded/tabs.css → tabs.css} +127 -106
- package/registry/components/tabs.tsx +246 -0
- package/registry/components/tag.tsx +2 -2
- package/registry/components/textarea.tsx +4 -4
- package/registry/components/toast.tsx +136 -0
- package/registry/components/toggle.tsx +2 -2
- package/registry/components/toolbar.tsx +89 -17
- package/registry/components/tooltip.tsx +1 -1
- package/registry/examples/alert-demo.tsx +25 -5
- package/registry/examples/alert-dialog-demo.tsx +42 -0
- package/registry/examples/aspect-ratio-demo.tsx +11 -0
- package/registry/examples/attribute-demo.tsx +1 -1
- package/registry/examples/autocomplete-demo.tsx +3 -3
- package/registry/examples/avatar-demo.tsx +7 -7
- package/registry/examples/badge-demo.tsx +1 -1
- package/registry/examples/button-demo.tsx +6 -6
- package/registry/examples/button-group-demo.tsx +23 -2
- package/registry/examples/card-demo.tsx +46 -8
- package/registry/examples/carousel-demo.tsx +43 -0
- package/registry/examples/chart-demo.tsx +33 -0
- package/registry/examples/checkbox-demo.tsx +5 -5
- package/registry/examples/collapsible-demo.tsx +16 -0
- package/registry/examples/collection-filter-bar-demo.tsx +135 -0
- package/registry/examples/command-demo.tsx +42 -0
- package/registry/examples/{expanded/command-bar-demo.tsx → command-palette-demo.tsx} +5 -15
- package/registry/examples/context-menu-demo.tsx +29 -0
- package/registry/examples/control-density-contract-demo.tsx +61 -0
- package/registry/examples/date-picker-demo.tsx +12 -12
- package/registry/examples/divider-demo.tsx +3 -3
- package/registry/examples/expanded/banner-demo.tsx +1 -1
- package/registry/examples/expanded/breadcrumbs-demo.tsx +1 -1
- package/registry/examples/expanded/empty-state-demo.tsx +1 -1
- package/registry/examples/expanded/file-upload-demo.tsx +1 -1
- package/registry/examples/expanded/onboarding-step-demo.tsx +1 -1
- package/registry/examples/expanded/slideout-demo.tsx +2 -2
- package/registry/examples/expanded/steps-demo.tsx +1 -1
- package/registry/examples/expanded/tabs-demo.tsx +2 -2
- package/registry/examples/expanded/timeline-demo.tsx +1 -1
- package/registry/examples/field-demo.tsx +51 -0
- package/registry/examples/hover-card-demo.tsx +23 -0
- package/registry/examples/input-demo.tsx +6 -6
- package/registry/examples/input-group-demo.tsx +16 -0
- package/registry/examples/input-otp-demo.tsx +4 -4
- package/registry/examples/item-demo.tsx +46 -0
- package/registry/examples/kbd-demo.tsx +11 -0
- package/registry/examples/label-demo.tsx +20 -0
- package/registry/examples/menu-demo.tsx +1 -1
- package/registry/examples/menubar-demo.tsx +34 -0
- package/registry/examples/modal-demo.tsx +67 -9
- package/registry/examples/native-select-demo.tsx +16 -0
- package/registry/examples/navigation-menu-demo.tsx +29 -0
- package/registry/examples/pagination-demo.tsx +6 -3
- package/registry/examples/popover-demo.tsx +19 -19
- package/registry/examples/progress-demo.tsx +1 -1
- package/registry/examples/progress-slider-demo.tsx +1 -1
- package/registry/examples/radio-card-demo.tsx +4 -4
- package/registry/examples/radio-group-demo.tsx +2 -2
- package/registry/examples/resizable-demo.tsx +22 -0
- package/registry/examples/results-toolbar-demo.tsx +44 -0
- package/registry/examples/scroll-area-demo.tsx +15 -0
- package/registry/examples/segmented-control-demo.tsx +39 -0
- package/registry/examples/select-demo.tsx +1 -1
- package/registry/examples/sheet-demo.tsx +47 -0
- package/registry/examples/sidebar-demo.tsx +55 -0
- package/registry/examples/slider-demo.tsx +3 -3
- package/registry/examples/social-button-demo.tsx +18 -8
- package/registry/examples/spinner-demo.tsx +13 -13
- package/registry/examples/tabs-demo.tsx +13 -0
- package/registry/examples/tag-demo.tsx +1 -1
- package/registry/examples/textarea-demo.tsx +4 -4
- package/registry/examples/toast-demo.tsx +35 -0
- package/registry/examples/toggle-demo.tsx +6 -6
- package/registry/examples/tooltip-demo.tsx +4 -4
- package/registry/guidance/USAGE.md +27 -0
- package/registry/hooks/use-direction.ts +193 -13
- package/registry/index.json +6010 -432
- package/registry/styles/globals.css +3112 -4690
- package/registry.json +1582 -0
- package/schema/config.schema.json +51 -0
- package/schema/registry.schema.json +190 -0
- package/schema/tokens.schema.json +163 -0
- package/src/cli/command-line.js +194 -0
- package/src/cli/config-editors.js +9 -0
- package/src/cli/doctor.js +399 -0
- package/src/cli/file-transaction.js +295 -0
- package/src/cli/global-css.js +153 -0
- package/src/cli/index.js +639 -1391
- package/src/cli/install-plan.js +592 -0
- package/src/cli/install-receipt.js +171 -0
- package/src/cli/jsonc.js +203 -0
- package/src/cli/package-install-state.js +254 -0
- package/src/cli/package-manager.js +238 -0
- package/src/cli/package-plan.js +185 -0
- package/src/cli/package-version.js +97 -0
- package/src/cli/registry-query.js +207 -0
- package/src/cli/reporting.js +55 -0
- package/src/cli/schema-validation.js +19 -0
- package/src/cli/source-scanner.js +686 -0
- package/src/cli/vite-config.js +478 -0
- package/tokens/banhaten.tokens.json +4313 -310
- package/registry/assets/avatars/avatar-02.jpg +0 -0
- package/registry/assets/avatars/avatar-03.jpg +0 -0
- package/registry/assets/avatars/avatar-04.jpg +0 -0
- package/registry/assets/avatars/avatar-05.jpg +0 -0
- package/registry/assets/avatars/avatar-06.jpg +0 -0
- package/registry/assets/avatars/avatar-07.jpg +0 -0
- package/registry/assets/avatars/avatar-08.jpg +0 -0
- package/registry/assets/avatars/avatar-09.jpg +0 -0
- package/registry/assets/avatars/avatar-10.jpg +0 -0
- package/registry/assets/avatars/avatar-11.jpg +0 -0
- package/registry/assets/avatars/avatar-12.jpg +0 -0
- package/registry/assets/avatars/avatar-13.jpg +0 -0
- package/registry/assets/avatars/avatar-14.jpg +0 -0
- package/registry/assets/avatars/avatar-15.jpg +0 -0
- package/registry/assets/avatars/avatar-16.jpg +0 -0
- package/registry/assets/avatars/avatar-17.jpg +0 -0
- package/registry/assets/avatars/avatar-18.jpg +0 -0
- package/registry/assets/avatars/avatar-19.jpg +0 -0
- package/registry/assets/avatars/avatar-20.jpg +0 -0
- package/registry/assets/avatars/avatar-21.jpg +0 -0
- package/registry/assets/avatars/avatar-22.jpg +0 -0
- package/registry/assets/avatars/avatar-23.jpg +0 -0
- package/registry/assets/avatars/avatar-24.jpg +0 -0
- package/registry/assets/avatars/avatar-25.jpg +0 -0
- package/registry/assets/avatars/avatar-26.jpg +0 -0
- package/registry/assets/avatars/avatar-27.jpg +0 -0
- package/registry/assets/avatars/avatar-28.jpg +0 -0
- package/registry/assets/avatars/avatar-29.jpg +0 -0
- package/registry/assets/avatars/avatar-30.jpg +0 -0
- package/registry/assets/avatars/avatar-31.jpg +0 -0
- package/registry/assets/avatars/avatar-32.jpg +0 -0
- package/registry/assets/avatars/avatar-33.jpg +0 -0
- package/registry/assets/avatars/avatar-34.jpg +0 -0
- package/registry/assets/avatars/avatar-35.jpg +0 -0
- package/registry/assets/image-assets.json +0 -744
- package/registry/assets/images/art-02.jpg +0 -0
- package/registry/assets/images/art-03.jpg +0 -0
- package/registry/assets/images/art-04.jpg +0 -0
- package/registry/assets/images/art-05.jpg +0 -0
- package/registry/assets/images/art-06.jpg +0 -0
- package/registry/assets/images/art-07.jpg +0 -0
- package/registry/assets/images/art-08.jpg +0 -0
- package/registry/assets/images/art-09.jpg +0 -0
- package/registry/assets/images/art-10.jpg +0 -0
- package/registry/assets/images/art-11.jpg +0 -0
- package/registry/assets/images/art-12.jpg +0 -0
- package/registry/assets/images/art-13.jpg +0 -0
- package/registry/assets/images/art-14.jpg +0 -0
- package/registry/assets/images/art-15.jpg +0 -0
- package/registry/assets/images/art-16.jpg +0 -0
- package/registry/assets/images/art-17.jpg +0 -0
- package/registry/assets/images/art-18.jpg +0 -0
- package/registry/assets/images/art-19.jpg +0 -0
- package/registry/assets/images/art-20.jpg +0 -0
- package/registry/assets/images/art-21.jpg +0 -0
- package/registry/assets/images/art-22.jpg +0 -0
- package/registry/assets/images/art-23.jpg +0 -0
- package/registry/assets/images/art-24.jpg +0 -0
- package/registry/assets/images/art-25.jpg +0 -0
- package/registry/assets/images/art-26.jpg +0 -0
- package/registry/assets/images/art-27.jpg +0 -0
- package/registry/assets/images/nature-01.jpg +0 -0
- package/registry/assets/images/nature-02.jpg +0 -0
- package/registry/assets/images/nature-03.jpg +0 -0
- package/registry/assets/images/nature-04.jpg +0 -0
- package/registry/assets/images/nature-05.jpg +0 -0
- package/registry/assets/images/nature-06.jpg +0 -0
- package/registry/assets/images/nature-07.jpg +0 -0
- package/registry/assets/images/nature-08.jpg +0 -0
- package/registry/assets/images/nature-09.jpg +0 -0
- package/registry/assets/images/nature-10.jpg +0 -0
- package/registry/assets/images/nature-11.jpg +0 -0
- package/registry/assets/images/nature-12.jpg +0 -0
- package/registry/assets/images/nature-13.jpg +0 -0
- package/registry/assets/images/nature-14.jpg +0 -0
- package/registry/assets/images/nature-15.jpg +0 -0
- package/registry/assets/images/nature-16.jpg +0 -0
- package/registry/assets/images/nature-17.jpg +0 -0
- package/registry/assets/images/nature-18.jpg +0 -0
- package/registry/assets/images/nature-19.jpg +0 -0
- package/registry/assets/images/nature-20.jpg +0 -0
- package/registry/components/expanded/BannerBoard.tsx +0 -225
- package/registry/components/expanded/CatalogTag.tsx +0 -85
- package/registry/components/expanded/CommandBar.tsx +0 -386
- package/registry/components/expanded/IconExplorer.tsx +0 -612
- package/registry/components/expanded/Tabs.tsx +0 -86
- package/registry/components/expanded/TimelineShowcase.tsx +0 -158
- package/registry/components/expanded/commandBar.css +0 -470
- package/registry/components/expanded/iconExplorer.css +0 -764
- package/registry/components/expanded/iconPacks.ts +0 -866
- package/registry/components/expanded/tag.css +0 -148
- package/registry/examples/expanded/icons-demo.tsx +0 -5
- package/tokens/Color mode.zip +0 -0
- package/tokens/Numbers.zip +0 -0
- package/tokens/Radius.zip +0 -0
- package/tokens/Theme.zip +0 -0
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# Navigation Menu
|
|
2
|
+
|
|
3
|
+
Navigation Menu wraps Radix NavigationMenu for top navigation with trigger, content, link, viewport, and indicator parts.
|
|
4
|
+
|
|
5
|
+
## API
|
|
6
|
+
|
|
7
|
+
```tsx
|
|
8
|
+
<NavigationMenu>
|
|
9
|
+
<NavigationMenuList>
|
|
10
|
+
<NavigationMenuItem>
|
|
11
|
+
<NavigationMenuTrigger>Product</NavigationMenuTrigger>
|
|
12
|
+
<NavigationMenuContent>
|
|
13
|
+
<NavigationMenuLink href="#">Components</NavigationMenuLink>
|
|
14
|
+
</NavigationMenuContent>
|
|
15
|
+
</NavigationMenuItem>
|
|
16
|
+
</NavigationMenuList>
|
|
17
|
+
<NavigationMenuViewport />
|
|
18
|
+
</NavigationMenu>
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Token Contract
|
|
22
|
+
|
|
23
|
+
Navigation Menu uses Banhaten ghost hover, soft active state, raised content, popover shadow, radius, and body typography tokens.
|
|
24
|
+
|
|
25
|
+
## RTL
|
|
26
|
+
|
|
27
|
+
The list and content inherit direction. Links use logical text alignment.
|
|
28
|
+
|
|
29
|
+
## Accessibility
|
|
30
|
+
|
|
31
|
+
Radix handles trigger relationships, viewport sizing, keyboard navigation, and focus.
|
|
32
|
+
|
|
33
|
+
## Install
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
npx banhaten add navigation-menu
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
## Examples
|
|
40
|
+
|
|
41
|
+
Primary registry example: `examples/navigation-menu-demo.tsx`.
|
|
42
|
+
|
|
43
|
+
Open the live component page or run `npx banhaten docs navigation-menu` to inspect source files, install command, and examples.
|
|
44
|
+
|
|
45
|
+
## RTL Rules
|
|
46
|
+
|
|
47
|
+
- `inheritsDirection`: true
|
|
48
|
+
- `spacing`: Triggers, links, and content use logical layout and inherited direction.
|
|
49
|
+
|
|
50
|
+
<!-- registry-contract:start -->
|
|
51
|
+
## Registry Contract
|
|
52
|
+
|
|
53
|
+
This table is generated from `registry/index.json`; edit the component-owned source under `registry/catalog/components/`, not this table or the compiled index.
|
|
54
|
+
`supportedExports` is the exhaustive runtime import contract grouped by source module. `parts` is an ordered, non-exhaustive anatomy list.
|
|
55
|
+
|
|
56
|
+
| Field | Values |
|
|
57
|
+
| --- | --- |
|
|
58
|
+
| `supportedExports` | `components/navigation-menu.tsx: NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport` |
|
|
59
|
+
| `parts` | `NavigationMenu`, `NavigationMenuList`, `NavigationMenuItem`, `NavigationMenuTrigger`, `NavigationMenuContent`, `NavigationMenuLink`, `NavigationMenuViewport`, `NavigationMenuIndicator` |
|
|
60
|
+
| `registryDependencies` | None |
|
|
61
|
+
| `features` | `top navigation`, `viewport`, `indicator`, `dropdown content` |
|
|
62
|
+
| `tokens` | `--bh-bg-raised`, `--bh-content-default`, `--bh-content-disabled`, `--bh-interactive-ghost-hover`, `--bh-interactive-soft-default`, `--bh-radius-2xl-12`, `--bh-radius-lg-8`, `--bh-radius-sm-4`, `--bh-space-19xl-384`, `--bh-space-3xl-16`, `--bh-space-7xl-40`, `--bh-space-lg-10`, `--bh-space-xl-12`, `--bh-space-xs-4`, `--bh-text-body-sm-medium-font-size`, `--bh-text-body-sm-medium-font-weight`, `--bh-text-body-sm-medium-letter-spacing`, `--bh-text-body-sm-medium-line-height`, `--bh-text-body-sm-regular-font-size`, `--bh-text-body-sm-regular-font-weight`, `--bh-text-body-sm-regular-letter-spacing`, `--bh-text-body-sm-regular-line-height`, `--bh-z-popover`, `--bh-z-raised`, `--shadow-popover` |
|
|
63
|
+
<!-- registry-contract:end -->
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
# Onboarding Step List Item
|
|
2
|
+
|
|
3
|
+
`OnboardingStepListItem` renders one vertical progress-list row for onboarding, setup, or guided task flows. It should be composed into a list by the parent flow, which controls line visibility for first and last items.
|
|
4
|
+
|
|
5
|
+
Figma reference: `OnboardingStepListItem`, node `587:27227`.
|
|
6
|
+
|
|
7
|
+
## Variants
|
|
8
|
+
|
|
9
|
+
The Figma component defines these variants:
|
|
10
|
+
|
|
11
|
+
| State | Direction |
|
|
12
|
+
| --- | --- |
|
|
13
|
+
| `Finished` | LTR and RTL |
|
|
14
|
+
| `Active` | LTR and RTL |
|
|
15
|
+
| `inactive` | LTR and RTL |
|
|
16
|
+
|
|
17
|
+
Code uses lowercase semantic state values: `finished`, `active`, and `inactive`.
|
|
18
|
+
|
|
19
|
+
## API
|
|
20
|
+
|
|
21
|
+
```tsx
|
|
22
|
+
<OnboardingStepListItem
|
|
23
|
+
state="finished"
|
|
24
|
+
label="Label"
|
|
25
|
+
dir="ltr"
|
|
26
|
+
showLeadingLine
|
|
27
|
+
showTrailingLine
|
|
28
|
+
/>
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
| Prop | Values | Default |
|
|
32
|
+
| --- | --- | --- |
|
|
33
|
+
| `state` | `finished`, `active`, `inactive` | `finished` |
|
|
34
|
+
| `label` | `string` | `Label` |
|
|
35
|
+
| `dir` | `ltr`, `rtl` | `ltr` |
|
|
36
|
+
| `showLeadingLine` | `boolean` | `true` |
|
|
37
|
+
| `showTrailingLine` | `boolean` | `true` |
|
|
38
|
+
|
|
39
|
+
## Token Contract
|
|
40
|
+
|
|
41
|
+
The component consumes Banhaten semantic tokens and component aliases. Do not hard-code Figma fallback literals in component source; promote any Figma value into its owned `tokens/source/` fragment as a `--bh-*` token or alias first.
|
|
42
|
+
|
|
43
|
+
- Backgrounds: `--bh-bg-raised`
|
|
44
|
+
- Borders: `--bh-border-brand-strong`, `--bh-border-default`
|
|
45
|
+
- Content: `--bh-content-brand-default`, `--bh-content-default`, `--bh-content-subtle`, `--bh-content-success-default`
|
|
46
|
+
- Shape: `--bh-control-default`
|
|
47
|
+
- Space: `--bh-space-lg-10`, `--bh-space-xl-12`
|
|
48
|
+
|
|
49
|
+
## Pixel Rules
|
|
50
|
+
|
|
51
|
+
- The row is `280px` wide and `40px` tall.
|
|
52
|
+
- Padding is `8px 12px` with a `10px` gap between the line wrap and label.
|
|
53
|
+
- Text uses Inter Medium `15px / 24px` with zero letter spacing.
|
|
54
|
+
- The line wrap is `24px` square.
|
|
55
|
+
- Finished uses a `20px` success check-circle icon with `2px` default connector lines.
|
|
56
|
+
- Active uses a `2px x 20px` brand line, a default border, white raised fill, `8px` radius, and component shadow.
|
|
57
|
+
- Inactive uses a `2px x 40px` default connector line and subtle content color.
|
|
58
|
+
- RTL mirrors visual order through `dir="rtl"` and right-aligns the label.
|
|
59
|
+
|
|
60
|
+
## Accessibility
|
|
61
|
+
|
|
62
|
+
- Connector lines and the finished icon are decorative in this primitive and are hidden from assistive technology.
|
|
63
|
+
- Parent onboarding lists should expose the overall progress semantics, current step, and completion status.
|
|
64
|
+
- Keep labels as real text and avoid using this row as the only status announcement.
|
|
65
|
+
|
|
66
|
+
## Install
|
|
67
|
+
|
|
68
|
+
```bash
|
|
69
|
+
npx banhaten add onboarding-step
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
## Examples
|
|
73
|
+
|
|
74
|
+
Primary registry example: `examples/expanded/onboarding-step-demo.tsx`.
|
|
75
|
+
|
|
76
|
+
Open the live component page or run `npx banhaten docs onboarding-step` to inspect source files, install command, and examples.
|
|
77
|
+
|
|
78
|
+
## RTL Rules
|
|
79
|
+
|
|
80
|
+
This component has no special RTL contract beyond inherited document direction and logical spacing.
|
|
81
|
+
|
|
82
|
+
<!-- registry-contract:start -->
|
|
83
|
+
## Registry Contract
|
|
84
|
+
|
|
85
|
+
This table is generated from `registry/index.json`; edit the component-owned source under `registry/catalog/components/`, not this table or the compiled index.
|
|
86
|
+
`supportedExports` is the exhaustive runtime import contract grouped by source module. `parts` is an ordered, non-exhaustive anatomy list.
|
|
87
|
+
|
|
88
|
+
| Field | Values |
|
|
89
|
+
| --- | --- |
|
|
90
|
+
| `supportedExports` | `components/expanded/OnboardingStepListItem.tsx: OnboardingStepListItem` |
|
|
91
|
+
| `parts` | `OnboardingStepListItem` |
|
|
92
|
+
| `registryDependencies` | None |
|
|
93
|
+
| `tokens` | `--bh-bg-raised`, `--bh-border-brand-strong`, `--bh-border-default`, `--bh-content-brand-default`, `--bh-content-default`, `--bh-content-subtle`, `--bh-content-success-default`, `--bh-control-default`, `--bh-font-family`, `--bh-icon-stroke-225`, `--bh-space-17xl-288`, `--bh-space-2xl-14`, `--bh-space-4xl-20`, `--bh-space-5xl-24`, `--bh-space-7xl-40`, `--bh-space-lg-10`, `--bh-space-md-8`, `--bh-space-xl-12`, `--bh-space-xxs-2`, `--bh-space-xxxs-1`, `--bh-text-body-md-medium-font-size`, `--bh-text-body-md-medium-font-weight`, `--bh-text-body-md-medium-letter-spacing`, `--bh-text-body-md-medium-line-height`, `--shadow-component-default` |
|
|
94
|
+
<!-- registry-contract:end -->
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
# Page Header
|
|
2
|
+
|
|
3
|
+
Page headers introduce a page or section with optional hierarchy, title metadata, actions, description, and local tabs.
|
|
4
|
+
|
|
5
|
+
Figma reference: `Page Header`, node `1154:2816` in `Design system 3.0 Copy`.
|
|
6
|
+
|
|
7
|
+
## API
|
|
8
|
+
|
|
9
|
+
```tsx
|
|
10
|
+
<PageHeader
|
|
11
|
+
title="Section Tile"
|
|
12
|
+
metaInfo="Meta info"
|
|
13
|
+
description="Section description"
|
|
14
|
+
breadcrumbs={[{ label: "Home" }, { label: "Home" }]}
|
|
15
|
+
actions={[{ label: "Button" }, { label: "Button" }]}
|
|
16
|
+
tabs={{ items: ["Tab item", "Tab item", "Tab item"] }}
|
|
17
|
+
/>
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
| Prop | Type | Default |
|
|
21
|
+
| --- | --- | --- |
|
|
22
|
+
| `title` | `string` | `Section Tile` |
|
|
23
|
+
| `metaInfo` | `string` | `Meta info` |
|
|
24
|
+
| `description` | `string` | `Section description` |
|
|
25
|
+
| `icon` | `ReactNode` or `false` | home icon |
|
|
26
|
+
| `breadcrumbs` | `PageHeaderBreadcrumb[]` or `false` | four `Home` items |
|
|
27
|
+
| `actions` | `PageHeaderAction[]` or `false` | four `Button` actions |
|
|
28
|
+
| `tabs` | `PageHeaderTabs` or `false` | underline `Tabs` |
|
|
29
|
+
| `dir` | `ltr` or `rtl` | `ltr` |
|
|
30
|
+
|
|
31
|
+
## Structure
|
|
32
|
+
|
|
33
|
+
The implementation follows the Figma hierarchy:
|
|
34
|
+
|
|
35
|
+
- Breadcrumb navigation above the section body.
|
|
36
|
+
- Title row with optional icon, title, and meta text.
|
|
37
|
+
- Action group aligned to the end of the title row.
|
|
38
|
+
- Optional body description below the title row.
|
|
39
|
+
- Underline `Tabs` spanning the full header width.
|
|
40
|
+
|
|
41
|
+
`PageHeader` reuses the existing `Tabs` component instead of duplicating tab behavior.
|
|
42
|
+
|
|
43
|
+
## Token Contract
|
|
44
|
+
|
|
45
|
+
The component consumes Banhaten semantic tokens and component aliases. Do not hard-code Figma fallback literals in component source; promote any Figma value into its owned `tokens/source/` fragment as a `--bh-*` token or alias first.
|
|
46
|
+
|
|
47
|
+
- Borders: `--bh-border-default`
|
|
48
|
+
- Content: `--bh-content-brand-default`, `--bh-content-default`, `--bh-content-heading`, `--bh-content-muted`, `--bh-content-subtle`
|
|
49
|
+
- Interactive: `--bh-interactive-secondary-default`
|
|
50
|
+
- Shape: `--bh-control-default`
|
|
51
|
+
|
|
52
|
+
## Pixel Rules
|
|
53
|
+
|
|
54
|
+
- Header root is vertically padded by `20px`.
|
|
55
|
+
- Breadcrumb and body text use `15px / 24px`.
|
|
56
|
+
- Title uses `24px / 28px` at weight `600`.
|
|
57
|
+
- Meta text uses `12px / 16px`.
|
|
58
|
+
- Title row and action group are separated by `40px`.
|
|
59
|
+
- Action buttons are `36px` high with an `8px` radius, subtle border, drop shadow, and inner bottom shadow.
|
|
60
|
+
- Tabs use the existing `underline`, `md`, `fullWidth` tab treatment.
|
|
61
|
+
|
|
62
|
+
## Accessibility
|
|
63
|
+
|
|
64
|
+
- Breadcrumbs render as `<nav aria-label="Breadcrumb">` with an ordered list.
|
|
65
|
+
- Mark the current breadcrumb with `current: true` so it receives `aria-current="page"`.
|
|
66
|
+
- Separators are decorative and hidden from assistive technology.
|
|
67
|
+
- Action items render as real buttons or anchors.
|
|
68
|
+
- Focus states use the brand token and remain visible for keyboard users.
|
|
69
|
+
|
|
70
|
+
## Install
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
npx banhaten add page-header
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
## Examples
|
|
77
|
+
|
|
78
|
+
Primary registry example: `examples/expanded/page-header-demo.tsx`.
|
|
79
|
+
|
|
80
|
+
Open the live component page or run `npx banhaten docs page-header` to inspect source files, install command, and examples.
|
|
81
|
+
|
|
82
|
+
## RTL Rules
|
|
83
|
+
|
|
84
|
+
This component has no special RTL contract beyond inherited document direction and logical spacing.
|
|
85
|
+
|
|
86
|
+
<!-- registry-contract:start -->
|
|
87
|
+
## Registry Contract
|
|
88
|
+
|
|
89
|
+
This table is generated from `registry/index.json`; edit the component-owned source under `registry/catalog/components/`, not this table or the compiled index.
|
|
90
|
+
`supportedExports` is the exhaustive runtime import contract grouped by source module. `parts` is an ordered, non-exhaustive anatomy list.
|
|
91
|
+
|
|
92
|
+
| Field | Values |
|
|
93
|
+
| --- | --- |
|
|
94
|
+
| `supportedExports` | `components/expanded/PageHeader.tsx: PageHeader` |
|
|
95
|
+
| `parts` | `PageHeader` |
|
|
96
|
+
| `registryDependencies` | `tabs` |
|
|
97
|
+
| `tokens` | `--bh-bg-raised`, `--bh-border-default`, `--bh-content-brand-default`, `--bh-content-default`, `--bh-content-muted`, `--bh-content-subtle`, `--bh-control-default`, `--bh-focus-ring-width`, `--bh-font-family`, `--bh-icon-stroke-190`, `--bh-interactive-secondary-default`, `--bh-opacity-muted`, `--bh-space-2xl-14`, `--bh-space-3xl-16`, `--bh-space-4xl-20`, `--bh-space-5xl-24`, `--bh-space-6xl-32`, `--bh-space-7xl-40`, `--bh-space-lg-10`, `--bh-space-md-8`, `--bh-space-xl-12`, `--bh-space-xs-4`, `--bh-space-xxs-2`, `--bh-space-xxxs-1`, `--bh-text-body-2xs-regular-font-size`, `--bh-text-body-2xs-regular-font-weight`, `--bh-text-body-2xs-regular-line-height`, `--bh-text-body-md-medium-font-size`, `--bh-text-body-md-medium-font-weight`, `--bh-text-body-md-medium-line-height`, `--bh-text-body-md-regular-font-size`, `--bh-text-body-md-regular-font-weight`, `--bh-text-body-md-regular-letter-spacing`, `--bh-text-body-md-regular-line-height`, `--bh-text-heading-md-semibold-font-size`, `--bh-text-heading-md-semibold-font-weight`, `--bh-text-heading-md-semibold-line-height`, `--shadow-button-secondary` |
|
|
98
|
+
<!-- registry-contract:end -->
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
# Pagination
|
|
2
|
+
|
|
3
|
+
Pagination navigates paged result sets, tables, and long lists. It supports numeric, simple, and summary layouts, soft and ghost styles, exact control geometry, captions, RTL layout, and explicit localized messages.
|
|
4
|
+
|
|
5
|
+
## API
|
|
6
|
+
|
|
7
|
+
```tsx
|
|
8
|
+
<Pagination page={3} pages={[1, 2, 3, "ellipsis", 12]} type="numeric" />
|
|
9
|
+
<Pagination
|
|
10
|
+
dir="rtl"
|
|
11
|
+
messages={{ previous: "הקודם", next: "הבא" }}
|
|
12
|
+
page={2}
|
|
13
|
+
type="summary"
|
|
14
|
+
/>
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
| Prop | Values | Default |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| `type` | `numeric`, `simple`, `summary` | `numeric` |
|
|
20
|
+
| `variant` | `soft`, `ghost` | `soft` |
|
|
21
|
+
| `page` | number | `2` |
|
|
22
|
+
| `pages` | page numbers, page descriptors, `ellipsis` | built-in demo sequence |
|
|
23
|
+
| `messages` | partial localized message catalog | English defaults |
|
|
24
|
+
| `caption`, `summary`, previous/next label and ARIA props | direct overrides | matching message value |
|
|
25
|
+
|
|
26
|
+
## Token Contract
|
|
27
|
+
|
|
28
|
+
Pagination uses Banhaten control height, radius, border, background, content, focus, icon, caption, and shadow tokens.
|
|
29
|
+
|
|
30
|
+
## RTL
|
|
31
|
+
|
|
32
|
+
Passing `dir="rtl"` mirrors previous/next directional icons with `data-rtl-flip="true"` and leaves the selected message catalog unchanged. Use `arabicPaginationMessages` or product-owned messages when the locale is Arabic.
|
|
33
|
+
|
|
34
|
+
## Accessibility
|
|
35
|
+
|
|
36
|
+
Wrap pagination in a navigation landmark with a descriptive label. Current page controls should expose current state, and previous/next buttons should have readable labels.
|
|
37
|
+
|
|
38
|
+
## Install
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
npx banhaten add pagination
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
## Examples
|
|
45
|
+
|
|
46
|
+
Primary registry example: `examples/pagination-demo.tsx`.
|
|
47
|
+
|
|
48
|
+
Open the live component page or run `npx banhaten docs pagination` to inspect source files, install command, and examples.
|
|
49
|
+
|
|
50
|
+
## RTL Rules
|
|
51
|
+
|
|
52
|
+
- `inheritsDirection`: true
|
|
53
|
+
- `messages`: Direction does not select language. English defaults are stable; pass messages for Arabic, Hebrew, Persian, Urdu, or another locale.
|
|
54
|
+
- `directionalIconFlip`: Inline Figma arrow vectors use data-rtl-flip="true" so previous and next controls mirror in RTL.
|
|
55
|
+
- `spacing`: Uses logical flex direction, gap, and text direction so English and Arabic captions align naturally.
|
|
56
|
+
|
|
57
|
+
<!-- registry-contract:start -->
|
|
58
|
+
## Registry Contract
|
|
59
|
+
|
|
60
|
+
This table is generated from `registry/index.json`; edit the component-owned source under `registry/catalog/components/`, not this table or the compiled index.
|
|
61
|
+
`supportedExports` is the exhaustive runtime import contract grouped by source module. `parts` is an ordered, non-exhaustive anatomy list.
|
|
62
|
+
|
|
63
|
+
| Field | Values |
|
|
64
|
+
| --- | --- |
|
|
65
|
+
| `supportedExports` | `components/pagination.tsx: Pagination, arabicPaginationMessages, paginationControlVariants, paginationItemVariants, paginationVariants` |
|
|
66
|
+
| `parts` | `Pagination` |
|
|
67
|
+
| `registryDependencies` | None |
|
|
68
|
+
| `tokens` | `--bh-border-brand-strong`, `--bh-content-disabled`, `--bh-icon-stroke-225`, `--bh-pagination-action-gap`, `--bh-pagination-active-bg`, `--bh-pagination-active-border`, `--bh-pagination-active-content`, `--bh-pagination-caption-content`, `--bh-pagination-caption-font-weight`, `--bh-pagination-caption-width`, `--bh-pagination-control-content`, `--bh-pagination-control-gap`, `--bh-pagination-control-ghost-bg`, `--bh-pagination-control-ghost-hover`, `--bh-pagination-control-ghost-pressed`, `--bh-pagination-control-label-padding-x`, `--bh-pagination-control-label-rtl-padding-x`, `--bh-pagination-control-soft-bg`, `--bh-pagination-control-soft-hover`, `--bh-pagination-control-soft-pressed`, `--bh-pagination-control-text-gap`, `--bh-pagination-control-text-padding-x`, `--bh-pagination-control-text-rtl-gap`, `--bh-pagination-control-text-rtl-padding-x`, `--bh-pagination-font-size`, `--bh-pagination-icon-size`, `--bh-pagination-item-size`, `--bh-pagination-label-font-weight`, `--bh-pagination-letter-spacing`, `--bh-pagination-line-height`, `--bh-pagination-numeric-width`, `--bh-pagination-page-bg`, `--bh-pagination-page-content`, `--bh-pagination-page-gap`, `--bh-pagination-page-hover`, `--bh-pagination-page-pressed`, `--bh-pagination-radius`, `--bh-pagination-root-gap`, `--bh-pagination-simple-width`, `--bh-space-md-8`, `--shadow-pagination-active`, `--shadow-pagination-control`, `--shadow-pagination-focus` |
|
|
69
|
+
| `types` | `numeric`, `simple`, `summary` |
|
|
70
|
+
| `variants` | `soft`, `ghost` |
|
|
71
|
+
<!-- registry-contract:end -->
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
# Popover
|
|
2
|
+
|
|
3
|
+
Popover presents contextual controls, filters, actions, settings, and short help content near a trigger. It supports controlled and uncontrolled state, click, focus, and hover-capable triggers, positioned content, optional arrow, alignment, offsets, sizes, close affordance, and RTL-safe composition.
|
|
4
|
+
|
|
5
|
+
## API
|
|
6
|
+
|
|
7
|
+
```tsx
|
|
8
|
+
<Popover>
|
|
9
|
+
<PopoverTrigger>Filters</PopoverTrigger>
|
|
10
|
+
<PopoverContent side="bottom" align="start">
|
|
11
|
+
<PopoverHeader>
|
|
12
|
+
<PopoverTitle>Filters</PopoverTitle>
|
|
13
|
+
<PopoverClose />
|
|
14
|
+
</PopoverHeader>
|
|
15
|
+
<PopoverBody>Filter controls go here.</PopoverBody>
|
|
16
|
+
</PopoverContent>
|
|
17
|
+
</Popover>
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
| Prop | Values |
|
|
21
|
+
| --- | --- |
|
|
22
|
+
| `open`, `defaultOpen`, `onOpenChange` | controlled or uncontrolled state |
|
|
23
|
+
| `side` | `top`, `right`, `bottom`, `left` |
|
|
24
|
+
| `align` | `start`, `center`, `end` |
|
|
25
|
+
| `size` | `sm`, `md`, `lg`, `auto` |
|
|
26
|
+
| `offset` | `tight`, `default`, `loose` |
|
|
27
|
+
| `showArrow` | `boolean` |
|
|
28
|
+
|
|
29
|
+
## Token Contract
|
|
30
|
+
|
|
31
|
+
Popover uses Banhaten popover width, padding, arrow, offset, surface, border, radius, shadow, trigger, typography, and z-index tokens.
|
|
32
|
+
|
|
33
|
+
## RTL
|
|
34
|
+
|
|
35
|
+
Top and bottom alignment use logical start/end behavior. Title and description slots use `dir="auto"` and product content can inherit the nearest direction.
|
|
36
|
+
|
|
37
|
+
## Accessibility
|
|
38
|
+
|
|
39
|
+
Use popovers for non-modal contextual content. Use Dialog or Sheet for workflows that require focus trapping or stronger dismissal semantics.
|
|
40
|
+
|
|
41
|
+
## Install
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
npx banhaten add popover
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
## Examples
|
|
48
|
+
|
|
49
|
+
Primary registry example: `examples/popover-demo.tsx`.
|
|
50
|
+
|
|
51
|
+
Open the live component page or run `npx banhaten docs popover` to inspect source files, install command, and examples.
|
|
52
|
+
|
|
53
|
+
## RTL Rules
|
|
54
|
+
|
|
55
|
+
- `inheritsDirection`: true
|
|
56
|
+
- `alignment`: Top and bottom alignments use logical start/end so the panel edge and arrow align correctly in LTR and RTL.
|
|
57
|
+
- `spacing`: Uses logical layout and Banhaten spacing tokens for headers, bodies, footers, arrows, and trigger gaps.
|
|
58
|
+
- `textDirection`: Title and description slots use dir="auto" while product content can inherit the nearest direction.
|
|
59
|
+
|
|
60
|
+
<!-- registry-contract:start -->
|
|
61
|
+
## Registry Contract
|
|
62
|
+
|
|
63
|
+
This table is generated from `registry/index.json`; edit the component-owned source under `registry/catalog/components/`, not this table or the compiled index.
|
|
64
|
+
`supportedExports` is the exhaustive runtime import contract grouped by source module. `parts` is an ordered, non-exhaustive anatomy list.
|
|
65
|
+
|
|
66
|
+
| Field | Values |
|
|
67
|
+
| --- | --- |
|
|
68
|
+
| `supportedExports` | `components/popover.tsx: Popover, PopoverAnchor, PopoverBody, PopoverClose, PopoverContent, PopoverDescription, PopoverFooter, PopoverHeader, PopoverRoot, PopoverTitle, PopoverTrigger, popoverContentVariants` |
|
|
69
|
+
| `parts` | `Popover`, `PopoverRoot`, `PopoverAnchor`, `PopoverTrigger`, `PopoverContent`, `PopoverHeader`, `PopoverTitle`, `PopoverDescription`, `PopoverBody`, `PopoverFooter`, `PopoverClose` |
|
|
70
|
+
| `registryDependencies` | None |
|
|
71
|
+
| `alignments` | `start`, `center`, `end` |
|
|
72
|
+
| `features` | `filter popover`, `settings popover`, `actions popover`, `focus trigger`, `text link trigger`, `icon button trigger`, `optional arrow`, `RTL` |
|
|
73
|
+
| `offsets` | `tight`, `default`, `loose` |
|
|
74
|
+
| `sides` | `top`, `right`, `bottom`, `left` |
|
|
75
|
+
| `sizes` | `sm`, `md`, `lg`, `auto` |
|
|
76
|
+
| `tokens` | `--bh-content-default`, `--bh-content-disabled`, `--bh-content-subtle`, `--bh-control-default`, `--bh-font-family`, `--bh-icon-stroke-200`, `--bh-interactive-ghost-hover`, `--bh-popover-arrow-depth`, `--bh-popover-arrow-width`, `--bh-popover-bg`, `--bh-popover-body-gap`, `--bh-popover-border`, `--bh-popover-close-icon-size`, `--bh-popover-close-size`, `--bh-popover-content-gap`, `--bh-popover-footer-gap`, `--bh-popover-header-gap`, `--bh-popover-lg-width`, `--bh-popover-max-width`, `--bh-popover-md-width`, `--bh-popover-offset`, `--bh-popover-offset-default`, `--bh-popover-offset-loose`, `--bh-popover-offset-tight`, `--bh-popover-padding`, `--bh-popover-radius`, `--bh-popover-sm-width`, `--bh-popover-trigger-gap`, `--bh-radius-full`, `--bh-text-base-letter-spacing`, `--bh-text-body-sm-medium-font-size`, `--bh-text-body-sm-medium-font-weight`, `--bh-text-body-sm-medium-letter-spacing`, `--bh-text-body-sm-medium-line-height`, `--bh-text-body-xs-regular-font-size`, `--bh-text-body-xs-regular-font-weight`, `--bh-text-body-xs-regular-letter-spacing`, `--bh-text-body-xs-regular-line-height`, `--bh-z-popover`, `--shadow-button-focus`, `--shadow-popover` |
|
|
77
|
+
<!-- registry-contract:end -->
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# Progress Slider
|
|
2
|
+
|
|
3
|
+
Progress Slider is an adjustable, start-anchored progress control. It is built on Radix Slider and keeps the filled surface growing from the logical start edge while the grip handle remains at the active value edge.
|
|
4
|
+
|
|
5
|
+
## API
|
|
6
|
+
|
|
7
|
+
```tsx
|
|
8
|
+
<ProgressSlider value={[45]} aria-label="Upload progress" />
|
|
9
|
+
<ProgressSlider defaultValue={[70]} tone="success" showTicks />
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
| Prop | Values |
|
|
13
|
+
| --- | --- |
|
|
14
|
+
| `value`, `defaultValue` | Radix slider value array |
|
|
15
|
+
| `size` | `default`, `lg` |
|
|
16
|
+
| `tone` | `brand`, `neutral`, `success`, `warning`, `danger` |
|
|
17
|
+
| `disabled` | `boolean` |
|
|
18
|
+
| `showTicks` | `boolean` |
|
|
19
|
+
|
|
20
|
+
## Token Contract
|
|
21
|
+
|
|
22
|
+
Progress Slider uses Banhaten slider, progress, semantic tone, track, handle, pill radius, focus, and disabled tokens. Keep tone styling semantic so alert and status palettes can theme consistently.
|
|
23
|
+
|
|
24
|
+
## RTL
|
|
25
|
+
|
|
26
|
+
Radix receives the inherited `dir` attribute for keyboard and value direction. The fill stays anchored to the logical start edge in both LTR and RTL.
|
|
27
|
+
|
|
28
|
+
## Accessibility
|
|
29
|
+
|
|
30
|
+
Provide an accessible name through `aria-label` or `aria-labelledby`. Use `aria-valuetext` when the numeric value needs domain-specific phrasing.
|
|
31
|
+
|
|
32
|
+
## Install
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
npx banhaten add progress-slider
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
## Examples
|
|
39
|
+
|
|
40
|
+
Primary registry example: `examples/progress-slider-demo.tsx`.
|
|
41
|
+
|
|
42
|
+
Open the live component page or run `npx banhaten docs progress-slider` to inspect source files, install command, and examples.
|
|
43
|
+
|
|
44
|
+
## RTL Rules
|
|
45
|
+
|
|
46
|
+
- `inheritsDirection`: true
|
|
47
|
+
- `valueDirection`: Radix Slider handles direction and keyboard behavior through the inherited dir attribute; the fill stays anchored to the logical start edge.
|
|
48
|
+
- `spacing`: Uses tokenized pill geometry and logical direction through Radix.
|
|
49
|
+
|
|
50
|
+
<!-- registry-contract:start -->
|
|
51
|
+
## Registry Contract
|
|
52
|
+
|
|
53
|
+
This table is generated from `registry/index.json`; edit the component-owned source under `registry/catalog/components/`, not this table or the compiled index.
|
|
54
|
+
`supportedExports` is the exhaustive runtime import contract grouped by source module. `parts` is an ordered, non-exhaustive anatomy list.
|
|
55
|
+
|
|
56
|
+
| Field | Values |
|
|
57
|
+
| --- | --- |
|
|
58
|
+
| `supportedExports` | `components/progress-slider.tsx: ProgressSlider, progressSliderVariants` |
|
|
59
|
+
| `parts` | `ProgressSlider` |
|
|
60
|
+
| `registryDependencies` | None |
|
|
61
|
+
| `features` | `start-anchored fill`, `grip handle`, `ticks` |
|
|
62
|
+
| `sizes` | `default`, `lg` |
|
|
63
|
+
| `states` | `default`, `disabled` |
|
|
64
|
+
| `tokens` | `--bh-bg-brand-soft`, `--bh-bg-brand-subtle`, `--bh-bg-danger-soft`, `--bh-bg-danger-subtle`, `--bh-bg-neutral-soft`, `--bh-bg-neutral-subtle`, `--bh-bg-success-soft`, `--bh-bg-success-subtle`, `--bh-bg-warning-soft`, `--bh-bg-warning-subtle`, `--bh-border-brand-strong`, `--bh-border-brand-subtle`, `--bh-border-danger-strong`, `--bh-border-danger-subtle`, `--bh-border-strong`, `--bh-border-subtle`, `--bh-border-success-strong`, `--bh-border-success-subtle`, `--bh-border-warning-strong`, `--bh-border-warning-subtle`, `--bh-content-disabled`, `--bh-opacity-60`, `--bh-progress-slider-border-width-current`, `--bh-progress-slider-border-width-lg`, `--bh-progress-slider-border-width-md`, `--bh-progress-slider-fill-bg`, `--bh-progress-slider-fill-border`, `--bh-progress-slider-grip-bg`, `--bh-progress-slider-grip-height-current`, `--bh-progress-slider-grip-height-lg`, `--bh-progress-slider-grip-height-md`, `--bh-progress-slider-grip-width`, `--bh-progress-slider-handle-width-current`, `--bh-progress-slider-handle-width-lg`, `--bh-progress-slider-handle-width-md`, `--bh-progress-slider-height-current`, `--bh-progress-slider-height-lg`, `--bh-progress-slider-height-md`, `--bh-progress-slider-radius`, `--bh-progress-slider-tick-bg`, `--bh-progress-slider-tick-gap`, `--bh-progress-slider-tick-padding`, `--bh-progress-slider-tick-size`, `--bh-progress-slider-track-bg`, `--bh-progress-slider-width-current`, `--bh-progress-slider-width-lg`, `--bh-progress-slider-width-md`, `--bh-radius-full`, `--bh-z-overlay`, `--bh-z-popover`, `--bh-z-raised`, `--shadow-progress-slider-thumb-focus` |
|
|
65
|
+
| `tones` | `brand`, `neutral`, `success`, `warning`, `danger` |
|
|
66
|
+
<!-- registry-contract:end -->
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
# Progress
|
|
2
|
+
|
|
3
|
+
Progress is a read-only progress meter for upload, setup, usage, and completion states. It supports top label, bottom label, helper-only, and inline indicator layouts, two track sizes, helper text, optional label text, an information icon, a spinner indicator, and inherited LTR/RTL direction.
|
|
4
|
+
|
|
5
|
+
The implementation follows the Figma progress components at `Design system 3.0 Copy / Progress` (`177:7992`) and `Progress Label` (`177:8141`).
|
|
6
|
+
|
|
7
|
+
## API
|
|
8
|
+
|
|
9
|
+
```tsx
|
|
10
|
+
<Progress
|
|
11
|
+
aria-label="Upload progress"
|
|
12
|
+
helperText="Preparing the final file"
|
|
13
|
+
label="Upload"
|
|
14
|
+
optional="(Optional)"
|
|
15
|
+
showInfo
|
|
16
|
+
showSpinner
|
|
17
|
+
value={40}
|
|
18
|
+
/>
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Variants
|
|
22
|
+
|
|
23
|
+
| Prop | Values |
|
|
24
|
+
| --- | --- |
|
|
25
|
+
| `size` | `lg`, `sm` |
|
|
26
|
+
| `labelPosition` | `top`, `bottom`, `none`, `inline` |
|
|
27
|
+
| `value` | number clamped between `min` and `max` |
|
|
28
|
+
| `showIndicator` | `boolean` |
|
|
29
|
+
| `showInfo` | `boolean` |
|
|
30
|
+
| `showSpinner` | `boolean` |
|
|
31
|
+
|
|
32
|
+
## Tokens
|
|
33
|
+
|
|
34
|
+
Progress uses existing Banhaten tokens only:
|
|
35
|
+
|
|
36
|
+
| Part | Token |
|
|
37
|
+
| --- | --- |
|
|
38
|
+
| Fill | `--bh-interactive-indicator-default` |
|
|
39
|
+
| Track | `--bh-bg-neutral-soft` |
|
|
40
|
+
| Radius | `--bh-radius-full` |
|
|
41
|
+
| Label | `--bh-text-body-xs-medium-*`, `--bh-content-default` |
|
|
42
|
+
| Optional and indicator | `--bh-text-body-xs-regular-*`, `--bh-text-body-2xs-regular-*`, `--bh-content-subtle` |
|
|
43
|
+
| Track height | `--bh-space-md-8`, `--bh-space-xs-4` |
|
|
44
|
+
|
|
45
|
+
## RTL
|
|
46
|
+
|
|
47
|
+
Progress inherits `dir` from its parent. The fill is anchored to the logical start edge, so LTR fills from the left and RTL fills from the right. Text nodes use `dir="auto"` and tokenized body styles.
|
|
48
|
+
|
|
49
|
+
## Install
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
npx banhaten add progress
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
## Examples
|
|
56
|
+
|
|
57
|
+
Primary registry example: `examples/progress-demo.tsx`.
|
|
58
|
+
|
|
59
|
+
Open the live component page or run `npx banhaten docs progress` to inspect source files, install command, and examples.
|
|
60
|
+
|
|
61
|
+
## Token Contract
|
|
62
|
+
|
|
63
|
+
Component styles must resolve through Banhaten semantic tokens, component aliases, or documented exception-ledger values.
|
|
64
|
+
Do not add raw colors, pixel values, opacity utilities, z-index values, durations, or shadow literals directly to component source.
|
|
65
|
+
Covered source files: `components/progress.tsx`.
|
|
66
|
+
|
|
67
|
+
## RTL Rules
|
|
68
|
+
|
|
69
|
+
- `inheritsDirection`: true
|
|
70
|
+
- `valueDirection`: The fill is anchored with logical start positioning, so LTR fills from left and RTL fills from right.
|
|
71
|
+
- `spacing`: Label, optional text, indicator, and helper copy use inherited direction, logical text alignment, and tokenized gaps.
|
|
72
|
+
|
|
73
|
+
## Accessibility
|
|
74
|
+
|
|
75
|
+
Keep native semantics, accessible names, keyboard reachability, focus-visible treatment, and status/error announcements intact when composing this component.
|
|
76
|
+
|
|
77
|
+
<!-- registry-contract:start -->
|
|
78
|
+
## Registry Contract
|
|
79
|
+
|
|
80
|
+
This table is generated from `registry/index.json`; edit the component-owned source under `registry/catalog/components/`, not this table or the compiled index.
|
|
81
|
+
`supportedExports` is the exhaustive runtime import contract grouped by source module. `parts` is an ordered, non-exhaustive anatomy list.
|
|
82
|
+
|
|
83
|
+
| Field | Values |
|
|
84
|
+
| --- | --- |
|
|
85
|
+
| `supportedExports` | `components/progress.tsx: Progress, progressTrackVariants, progressVariants` |
|
|
86
|
+
| `parts` | `Progress` |
|
|
87
|
+
| `registryDependencies` | None |
|
|
88
|
+
| `features` | `progressbar semantics`, `helper text`, `optional label text`, `info icon`, `spinner indicator`, `logical start fill` |
|
|
89
|
+
| `labelPositions` | `top`, `bottom`, `none`, `inline` |
|
|
90
|
+
| `sizes` | `sm`, `lg` |
|
|
91
|
+
| `tokens` | `--bh-bg-neutral-soft`, `--bh-content-default`, `--bh-content-muted`, `--bh-content-subtle`, `--bh-interactive-indicator-default`, `--bh-progress-gap`, `--bh-progress-indicator-size`, `--bh-progress-track-height-current`, `--bh-radius-full`, `--bh-space-3xl-16`, `--bh-space-md-8`, `--bh-space-sm-6`, `--bh-space-xs-4`, `--bh-space-xxs-2`, `--bh-text-body-2xs-regular-font-size`, `--bh-text-body-2xs-regular-font-weight`, `--bh-text-body-2xs-regular-letter-spacing`, `--bh-text-body-2xs-regular-line-height`, `--bh-text-body-xs-medium-font-size`, `--bh-text-body-xs-medium-font-weight`, `--bh-text-body-xs-medium-letter-spacing`, `--bh-text-body-xs-medium-line-height`, `--bh-text-body-xs-regular-font-size`, `--bh-text-body-xs-regular-font-weight`, `--bh-text-body-xs-regular-letter-spacing`, `--bh-text-body-xs-regular-line-height` |
|
|
92
|
+
<!-- registry-contract:end -->
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
# Radio Card
|
|
2
|
+
|
|
3
|
+
Radio Card is a Figma-matched option card for richer single-choice selections. It supports icon, payment, avatar, company, support-label, icon-radio-left, icon-radio-right, and label-only layouts across default, active, disabled, LTR, and RTL states.
|
|
4
|
+
|
|
5
|
+
## API
|
|
6
|
+
|
|
7
|
+
```tsx
|
|
8
|
+
<RadioCard
|
|
9
|
+
title="Business"
|
|
10
|
+
description="For teams and advanced permissions."
|
|
11
|
+
type="with-icon"
|
|
12
|
+
/>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
| Prop | Values |
|
|
16
|
+
| --- | --- |
|
|
17
|
+
| `type` | `with-icon`, `icon-radio-right`, `payment`, `with-avatar`, `company-icon`, `icon-radio-left`, `radio-label` |
|
|
18
|
+
| `state` | `default`, `active`, `disabled` |
|
|
19
|
+
| `dir` | `ltr`, `rtl` |
|
|
20
|
+
|
|
21
|
+
## Token Contract
|
|
22
|
+
|
|
23
|
+
Radio Card consumes Banhaten card spacing, border, radius, shadow, typography, radio-control, hover, active, disabled, and semantic content tokens.
|
|
24
|
+
|
|
25
|
+
## RTL
|
|
26
|
+
|
|
27
|
+
Radio Card follows the explicit Figma RTL ordering for each card type. Text nodes render in RTL and right alignment where the variant requires physical RTL composition.
|
|
28
|
+
|
|
29
|
+
## Accessibility
|
|
30
|
+
|
|
31
|
+
Use Radio Card inside a semantic radio group or connect it to a native radio input in product code. Do not rely on the visual active state alone for form submission.
|
|
32
|
+
|
|
33
|
+
## Install
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
npx banhaten add radio-card
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
## Examples
|
|
40
|
+
|
|
41
|
+
Primary registry example: `examples/radio-card-demo.tsx`.
|
|
42
|
+
|
|
43
|
+
Open the live component page or run `npx banhaten docs radio-card` to inspect source files, install command, and examples.
|
|
44
|
+
|
|
45
|
+
## RTL Rules
|
|
46
|
+
|
|
47
|
+
- `inheritsDirection`: false
|
|
48
|
+
- `layout`: Uses the explicit Figma RTL physical order while text nodes use RTL direction and right alignment.
|
|
49
|
+
- `spacing`: Company icon and icon-radio-left RTL variants use the Figma 12px card gap; other variants use the 10px card gap.
|
|
50
|
+
|
|
51
|
+
<!-- registry-contract:start -->
|
|
52
|
+
## Registry Contract
|
|
53
|
+
|
|
54
|
+
This table is generated from `registry/index.json`; edit the component-owned source under `registry/catalog/components/`, not this table or the compiled index.
|
|
55
|
+
`supportedExports` is the exhaustive runtime import contract grouped by source module. `parts` is an ordered, non-exhaustive anatomy list.
|
|
56
|
+
|
|
57
|
+
| Field | Values |
|
|
58
|
+
| --- | --- |
|
|
59
|
+
| `supportedExports` | `components/radio-card.tsx: RadioCard, radioCardVariants` |
|
|
60
|
+
| `parts` | `RadioCard` |
|
|
61
|
+
| `registryDependencies` | None |
|
|
62
|
+
| `states` | `default`, `active`, `disabled` |
|
|
63
|
+
| `tokens` | `--bh-bg-accent-blue-soft`, `--bh-bg-accent-purple-soft`, `--bh-bg-always-white`, `--bh-bg-neutral-subtle`, `--bh-bg-raised`, `--bh-bg-raised-hover`, `--bh-border-brand-strong`, `--bh-border-default`, `--bh-border-disabled`, `--bh-border-input`, `--bh-border-subtle`, `--bh-border-width-default`, `--bh-content-default`, `--bh-content-disabled`, `--bh-content-subtle`, `--bh-icon-stroke-180`, `--bh-icon-stroke-200`, `--bh-interactive-radiobutton-default`, `--bh-opacity-disabled-media`, `--bh-radio-card-bg`, `--bh-radio-card-border`, `--bh-radio-card-border-width`, `--bh-radio-card-border-width-active`, `--bh-radio-card-company-mark-color`, `--bh-radio-card-payment-height`, `--bh-radio-card-payment-logo-color`, `--bh-radio-card-payment-logo-height`, `--bh-radio-card-payment-logo-width`, `--bh-radio-card-payment-width`, `--bh-radio-card-width`, `--bh-radio-control-border`, `--bh-radius-full`, `--bh-radius-md-6`, `--bh-radius-xl-10`, `--bh-space-3xl-16`, `--bh-space-4xl-20`, `--bh-space-5xl-24`, `--bh-space-7xl-40`, `--bh-space-lg-10`, `--bh-space-sm-6`, `--bh-space-xl-12`, `--bh-space-xs-4`, `--bh-space-xxs-2`, `--bh-text-body-md-medium-font-size`, `--bh-text-body-md-medium-font-weight`, `--bh-text-body-md-medium-letter-spacing`, `--bh-text-body-md-medium-line-height`, `--bh-text-body-sm-regular-font-size`, `--bh-text-body-sm-regular-font-weight`, `--bh-text-body-sm-regular-letter-spacing`, `--bh-text-body-sm-regular-line-height`, `--shadow-component-default`, `--shadow-radio-card`, `--shadow-radio-card-current`, `--shadow-radio-card-disabled`, `--shadow-radio-control` |
|
|
64
|
+
| `types` | `with-icon`, `icon-radio-right`, `payment`, `with-avatar`, `company-icon`, `icon-radio-left`, `radio-label` |
|
|
65
|
+
<!-- registry-contract:end -->
|