@forte-ui/react 1.0.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (304) hide show
  1. package/README.md +240 -0
  2. package/dist/Accordion-9JunkjgY.js +111 -0
  3. package/dist/Alert-Cn_WUF3L.js +183 -0
  4. package/dist/AspectRatio-gSjpTVk-.js +39 -0
  5. package/dist/Avatar-BuitDluH.js +87 -0
  6. package/dist/Badge-sArNWMre.js +33 -0
  7. package/dist/Breadcrumb-Cq7tFtMX.js +170 -0
  8. package/dist/Button-AiyKnx5I.js +42 -0
  9. package/dist/ButtonGroup-C-CrwPXP.js +54 -0
  10. package/dist/Calendar-D7Q-QJ_e.js +503 -0
  11. package/dist/Checkbox-DfNbmOed.js +56 -0
  12. package/dist/Collapsible-D8UKiGip.js +86 -0
  13. package/dist/ColorPicker-B-eCI31W.js +612 -0
  14. package/dist/Combobox-D-BN-Tvp.js +302 -0
  15. package/dist/ContextMenu-D81uDaMG.js +44 -0
  16. package/dist/DatePicker-CfkMsaI-.js +192 -0
  17. package/dist/Dialog-_n8FpFs5.js +432 -0
  18. package/dist/Drawer-DKQF3OO7.js +158 -0
  19. package/dist/Field-FLFEO70D.js +58 -0
  20. package/dist/Fieldset-CYhh71Qt.js +28 -0
  21. package/dist/Form-DVPmW9XV.js +17 -0
  22. package/dist/Input-BgGWhO2q.js +18 -0
  23. package/dist/InputGroup-DsZyDXNn.js +89 -0
  24. package/dist/Menu-CKu9xE2h.js +261 -0
  25. package/dist/Menubar-Dax027Db.js +19 -0
  26. package/dist/NavList-DGvcIoJm.js +176 -0
  27. package/dist/NavigationMenu-BayQkUUb.js +209 -0
  28. package/dist/NumberField-P55SA8T7.js +191 -0
  29. package/dist/OTPField-CjHvBNSN.js +55 -0
  30. package/dist/Popover-BXhn2Wwt.js +142 -0
  31. package/dist/PreviewCard-Dnitrky0.js +99 -0
  32. package/dist/Progress-BlomDp-X.js +81 -0
  33. package/dist/ProgressCircle-j6XBl0fk.js +112 -0
  34. package/dist/Radio-BIcX4INJ.js +37 -0
  35. package/dist/Resizable-7nJJM97e.js +609 -0
  36. package/dist/ScrollArea-CBMGJ6hh.js +83 -0
  37. package/dist/Select-BP-zvdXm.js +237 -0
  38. package/dist/Separator-DewJBzaJ.js +21 -0
  39. package/dist/Skeleton-zr6ObCCq.js +79 -0
  40. package/dist/Slider-Bh8_cti1.js +104 -0
  41. package/dist/Spinner-BF0uD4hR.js +53 -0
  42. package/dist/Switch-OBewMMvM.js +39 -0
  43. package/dist/Tabs-LgkSbPSF.js +132 -0
  44. package/dist/Textarea-CqZJL41e.js +51 -0
  45. package/dist/Toast-BWayxAcd.js +304 -0
  46. package/dist/Toggle-BrhMnkF5.js +45 -0
  47. package/dist/Toolbar-OmOVCk3i.js +88 -0
  48. package/dist/Tooltip-CI4chsRw.js +101 -0
  49. package/dist/clsx-By2n9mTe.js +16 -0
  50. package/dist/cn.d.ts +8 -0
  51. package/dist/cn.js +11 -0
  52. package/dist/components/accordion/Accordion.d.ts +117 -0
  53. package/dist/components/accordion/Accordion.js +3 -0
  54. package/dist/components/accordion/index.d.ts +2 -0
  55. package/dist/components/accordion/index.js +2 -0
  56. package/dist/components/alert/Alert.d.ts +167 -0
  57. package/dist/components/alert/Alert.js +3 -0
  58. package/dist/components/alert/index.d.ts +2 -0
  59. package/dist/components/alert/index.js +2 -0
  60. package/dist/components/aspect-ratio/AspectRatio.d.ts +128 -0
  61. package/dist/components/aspect-ratio/AspectRatio.js +3 -0
  62. package/dist/components/aspect-ratio/index.d.ts +2 -0
  63. package/dist/components/aspect-ratio/index.js +2 -0
  64. package/dist/components/avatar/Avatar.d.ts +176 -0
  65. package/dist/components/avatar/Avatar.js +3 -0
  66. package/dist/components/avatar/index.d.ts +2 -0
  67. package/dist/components/avatar/index.js +2 -0
  68. package/dist/components/badge/Badge.d.ts +117 -0
  69. package/dist/components/badge/Badge.js +3 -0
  70. package/dist/components/badge/index.d.ts +2 -0
  71. package/dist/components/badge/index.js +2 -0
  72. package/dist/components/breadcrumb/Breadcrumb.d.ts +244 -0
  73. package/dist/components/breadcrumb/Breadcrumb.js +3 -0
  74. package/dist/components/breadcrumb/index.d.ts +2 -0
  75. package/dist/components/breadcrumb/index.js +2 -0
  76. package/dist/components/button/Button.d.ts +73 -0
  77. package/dist/components/button/Button.js +3 -0
  78. package/dist/components/button/index.d.ts +2 -0
  79. package/dist/components/button/index.js +2 -0
  80. package/dist/components/button-group/ButtonGroup.d.ts +113 -0
  81. package/dist/components/button-group/ButtonGroup.js +3 -0
  82. package/dist/components/button-group/index.d.ts +2 -0
  83. package/dist/components/button-group/index.js +2 -0
  84. package/dist/components/calendar/Calendar.d.ts +201 -0
  85. package/dist/components/calendar/Calendar.js +3 -0
  86. package/dist/components/calendar/index.d.ts +2 -0
  87. package/dist/components/calendar/index.js +2 -0
  88. package/dist/components/checkbox/Checkbox.d.ts +130 -0
  89. package/dist/components/checkbox/Checkbox.js +3 -0
  90. package/dist/components/checkbox/index.d.ts +2 -0
  91. package/dist/components/checkbox/index.js +2 -0
  92. package/dist/components/collapsible/Collapsible.d.ts +91 -0
  93. package/dist/components/collapsible/Collapsible.js +3 -0
  94. package/dist/components/collapsible/index.d.ts +2 -0
  95. package/dist/components/collapsible/index.js +2 -0
  96. package/dist/components/color-picker/ColorPicker.d.ts +553 -0
  97. package/dist/components/color-picker/ColorPicker.js +4 -0
  98. package/dist/components/color-picker/color.d.ts +102 -0
  99. package/dist/components/color-picker/color.js +249 -0
  100. package/dist/components/color-picker/index.d.ts +2 -0
  101. package/dist/components/color-picker/index.js +3 -0
  102. package/dist/components/combobox/Combobox.d.ts +553 -0
  103. package/dist/components/combobox/Combobox.js +3 -0
  104. package/dist/components/combobox/index.d.ts +2 -0
  105. package/dist/components/combobox/index.js +2 -0
  106. package/dist/components/context-menu/ContextMenu.d.ts +103 -0
  107. package/dist/components/context-menu/ContextMenu.js +3 -0
  108. package/dist/components/context-menu/index.d.ts +3 -0
  109. package/dist/components/context-menu/index.js +2 -0
  110. package/dist/components/date-picker/DatePicker.d.ts +268 -0
  111. package/dist/components/date-picker/DatePicker.js +3 -0
  112. package/dist/components/date-picker/index.d.ts +2 -0
  113. package/dist/components/date-picker/index.js +2 -0
  114. package/dist/components/dialog/Dialog.d.ts +567 -0
  115. package/dist/components/dialog/Dialog.js +3 -0
  116. package/dist/components/dialog/index.d.ts +2 -0
  117. package/dist/components/dialog/index.js +2 -0
  118. package/dist/components/drawer/Drawer.d.ts +351 -0
  119. package/dist/components/drawer/Drawer.js +3 -0
  120. package/dist/components/drawer/index.d.ts +2 -0
  121. package/dist/components/drawer/index.js +2 -0
  122. package/dist/components/field/Field.d.ts +170 -0
  123. package/dist/components/field/Field.js +3 -0
  124. package/dist/components/field/index.d.ts +2 -0
  125. package/dist/components/field/index.js +2 -0
  126. package/dist/components/fieldset/Fieldset.d.ts +60 -0
  127. package/dist/components/fieldset/Fieldset.js +3 -0
  128. package/dist/components/fieldset/index.d.ts +2 -0
  129. package/dist/components/fieldset/index.js +2 -0
  130. package/dist/components/form/Form.d.ts +76 -0
  131. package/dist/components/form/Form.js +3 -0
  132. package/dist/components/form/index.d.ts +2 -0
  133. package/dist/components/form/index.js +2 -0
  134. package/dist/components/input/Input.d.ts +67 -0
  135. package/dist/components/input/Input.js +3 -0
  136. package/dist/components/input/index.d.ts +2 -0
  137. package/dist/components/input/index.js +2 -0
  138. package/dist/components/input-group/InputGroup.d.ts +214 -0
  139. package/dist/components/input-group/InputGroup.js +3 -0
  140. package/dist/components/input-group/index.d.ts +2 -0
  141. package/dist/components/input-group/index.js +2 -0
  142. package/dist/components/menu/Menu.d.ts +587 -0
  143. package/dist/components/menu/Menu.js +3 -0
  144. package/dist/components/menu/index.d.ts +2 -0
  145. package/dist/components/menu/index.js +2 -0
  146. package/dist/components/menubar/Menubar.d.ts +104 -0
  147. package/dist/components/menubar/Menubar.js +3 -0
  148. package/dist/components/menubar/index.d.ts +2 -0
  149. package/dist/components/menubar/index.js +2 -0
  150. package/dist/components/nav-list/NavList.d.ts +290 -0
  151. package/dist/components/nav-list/NavList.js +3 -0
  152. package/dist/components/nav-list/index.d.ts +2 -0
  153. package/dist/components/nav-list/index.js +2 -0
  154. package/dist/components/navigation-menu/NavigationMenu.d.ts +483 -0
  155. package/dist/components/navigation-menu/NavigationMenu.js +3 -0
  156. package/dist/components/navigation-menu/index.d.ts +2 -0
  157. package/dist/components/navigation-menu/index.js +2 -0
  158. package/dist/components/number-field/NumberField.d.ts +303 -0
  159. package/dist/components/number-field/NumberField.js +3 -0
  160. package/dist/components/number-field/index.d.ts +2 -0
  161. package/dist/components/number-field/index.js +2 -0
  162. package/dist/components/otp-field/OTPField.d.ts +206 -0
  163. package/dist/components/otp-field/OTPField.js +3 -0
  164. package/dist/components/otp-field/index.d.ts +2 -0
  165. package/dist/components/otp-field/index.js +2 -0
  166. package/dist/components/popover/Popover.d.ts +394 -0
  167. package/dist/components/popover/Popover.js +3 -0
  168. package/dist/components/popover/index.d.ts +2 -0
  169. package/dist/components/popover/index.js +2 -0
  170. package/dist/components/preview-card/PreviewCard.d.ts +307 -0
  171. package/dist/components/preview-card/PreviewCard.js +3 -0
  172. package/dist/components/preview-card/index.d.ts +2 -0
  173. package/dist/components/preview-card/index.js +2 -0
  174. package/dist/components/progress/Progress.d.ts +156 -0
  175. package/dist/components/progress/Progress.js +3 -0
  176. package/dist/components/progress/ProgressCircle.d.ts +166 -0
  177. package/dist/components/progress/ProgressCircle.js +3 -0
  178. package/dist/components/progress/index.d.ts +4 -0
  179. package/dist/components/progress/index.js +3 -0
  180. package/dist/components/radio/Radio.d.ts +144 -0
  181. package/dist/components/radio/Radio.js +3 -0
  182. package/dist/components/radio/index.d.ts +2 -0
  183. package/dist/components/radio/index.js +2 -0
  184. package/dist/components/resizable/Resizable.d.ts +211 -0
  185. package/dist/components/resizable/Resizable.js +3 -0
  186. package/dist/components/resizable/index.d.ts +2 -0
  187. package/dist/components/resizable/index.js +2 -0
  188. package/dist/components/scroll-area/ScrollArea.d.ts +113 -0
  189. package/dist/components/scroll-area/ScrollArea.js +3 -0
  190. package/dist/components/scroll-area/index.d.ts +2 -0
  191. package/dist/components/scroll-area/index.js +2 -0
  192. package/dist/components/select/Select.d.ts +345 -0
  193. package/dist/components/select/Select.js +3 -0
  194. package/dist/components/select/index.d.ts +2 -0
  195. package/dist/components/select/index.js +2 -0
  196. package/dist/components/separator/Separator.d.ts +75 -0
  197. package/dist/components/separator/Separator.js +3 -0
  198. package/dist/components/separator/index.d.ts +2 -0
  199. package/dist/components/separator/index.js +2 -0
  200. package/dist/components/skeleton/Skeleton.d.ts +169 -0
  201. package/dist/components/skeleton/Skeleton.js +3 -0
  202. package/dist/components/skeleton/index.d.ts +2 -0
  203. package/dist/components/skeleton/index.js +2 -0
  204. package/dist/components/slider/Slider.d.ts +208 -0
  205. package/dist/components/slider/Slider.js +3 -0
  206. package/dist/components/slider/index.d.ts +2 -0
  207. package/dist/components/slider/index.js +2 -0
  208. package/dist/components/spinner/Spinner.d.ts +92 -0
  209. package/dist/components/spinner/Spinner.js +3 -0
  210. package/dist/components/spinner/index.d.ts +2 -0
  211. package/dist/components/spinner/index.js +2 -0
  212. package/dist/components/switch/Switch.d.ts +80 -0
  213. package/dist/components/switch/Switch.js +3 -0
  214. package/dist/components/switch/index.d.ts +2 -0
  215. package/dist/components/switch/index.js +2 -0
  216. package/dist/components/tabs/Tabs.d.ts +125 -0
  217. package/dist/components/tabs/Tabs.js +3 -0
  218. package/dist/components/tabs/index.d.ts +2 -0
  219. package/dist/components/tabs/index.js +2 -0
  220. package/dist/components/textarea/Textarea.d.ts +119 -0
  221. package/dist/components/textarea/Textarea.js +3 -0
  222. package/dist/components/textarea/index.d.ts +2 -0
  223. package/dist/components/textarea/index.js +2 -0
  224. package/dist/components/toast/Toast.d.ts +517 -0
  225. package/dist/components/toast/Toast.js +3 -0
  226. package/dist/components/toast/index.d.ts +2 -0
  227. package/dist/components/toast/index.js +2 -0
  228. package/dist/components/toggle/Toggle.d.ts +171 -0
  229. package/dist/components/toggle/Toggle.js +3 -0
  230. package/dist/components/toggle/index.d.ts +2 -0
  231. package/dist/components/toggle/index.js +2 -0
  232. package/dist/components/toolbar/Toolbar.d.ts +318 -0
  233. package/dist/components/toolbar/Toolbar.js +3 -0
  234. package/dist/components/toolbar/index.d.ts +2 -0
  235. package/dist/components/toolbar/index.js +2 -0
  236. package/dist/components/tooltip/Tooltip.d.ts +361 -0
  237. package/dist/components/tooltip/Tooltip.js +3 -0
  238. package/dist/components/tooltip/index.d.ts +2 -0
  239. package/dist/components/tooltip/index.js +2 -0
  240. package/dist/index.d.ts +92 -0
  241. package/dist/index.js +86 -0
  242. package/dist/styles/Accordion.css +1 -0
  243. package/dist/styles/Alert.css +1 -0
  244. package/dist/styles/AspectRatio.css +1 -0
  245. package/dist/styles/Avatar.css +1 -0
  246. package/dist/styles/Badge.css +1 -0
  247. package/dist/styles/Breadcrumb.css +1 -0
  248. package/dist/styles/Button.css +1 -0
  249. package/dist/styles/ButtonGroup.css +1 -0
  250. package/dist/styles/Calendar.css +1 -0
  251. package/dist/styles/Checkbox.css +1 -0
  252. package/dist/styles/Collapsible.css +1 -0
  253. package/dist/styles/ColorPicker.css +1 -0
  254. package/dist/styles/Combobox.css +1 -0
  255. package/dist/styles/ContextMenu.css +1 -0
  256. package/dist/styles/DatePicker.css +1 -0
  257. package/dist/styles/Dialog.css +1 -0
  258. package/dist/styles/Drawer.css +1 -0
  259. package/dist/styles/Field.css +1 -0
  260. package/dist/styles/Fieldset.css +1 -0
  261. package/dist/styles/Form.css +1 -0
  262. package/dist/styles/Input.css +1 -0
  263. package/dist/styles/InputGroup.css +1 -0
  264. package/dist/styles/Menu.css +1 -0
  265. package/dist/styles/Menubar.css +1 -0
  266. package/dist/styles/NavList.css +1 -0
  267. package/dist/styles/NavigationMenu.css +1 -0
  268. package/dist/styles/NumberField.css +1 -0
  269. package/dist/styles/OTPField.css +1 -0
  270. package/dist/styles/Popover.css +1 -0
  271. package/dist/styles/PreviewCard.css +1 -0
  272. package/dist/styles/Progress.css +1 -0
  273. package/dist/styles/ProgressCircle.css +1 -0
  274. package/dist/styles/Radio.css +1 -0
  275. package/dist/styles/Resizable.css +1 -0
  276. package/dist/styles/ScrollArea.css +1 -0
  277. package/dist/styles/Select.css +1 -0
  278. package/dist/styles/Separator.css +1 -0
  279. package/dist/styles/Skeleton.css +1 -0
  280. package/dist/styles/Slider.css +1 -0
  281. package/dist/styles/Spinner.css +1 -0
  282. package/dist/styles/Switch.css +1 -0
  283. package/dist/styles/Tabs.css +1 -0
  284. package/dist/styles/Textarea.css +1 -0
  285. package/dist/styles/Toast.css +1 -0
  286. package/dist/styles/Toggle.css +1 -0
  287. package/dist/styles/Toolbar.css +1 -0
  288. package/dist/styles/Tooltip.css +1 -0
  289. package/dist/styles/a11y.css +119 -0
  290. package/dist/styles/layers.css +39 -0
  291. package/dist/styles/motion.css +194 -0
  292. package/dist/styles/patterns.css +236 -0
  293. package/dist/styles/properties.css +62 -0
  294. package/dist/styles/reset.css +11 -0
  295. package/dist/styles/tailwind.css +281 -0
  296. package/dist/styles/theme.css +57 -0
  297. package/dist/styles/tokens.color.css +223 -0
  298. package/dist/styles/tokens.css +460 -0
  299. package/dist/tailwind-merge.d.ts +52 -0
  300. package/dist/tailwind-merge.js +52 -0
  301. package/docs-data/props.json +8047 -0
  302. package/docs-data/theming.json +9600 -0
  303. package/docs-data/tokens.json +4070 -0
  304. package/package.json +78 -0
@@ -0,0 +1,104 @@
1
+ import { Menubar as BaseMenubar } from '@base-ui/react/menubar';
2
+ import * as React from "react";
3
+ export type MenubarVariant = "plain" | "contained";
4
+ export type MenubarOrientation = "horizontal" | "vertical";
5
+ type BaseMenubarProps = React.ComponentPropsWithoutRef<typeof BaseMenubar>;
6
+ export interface MenubarProps extends Omit<BaseMenubarProps, "className"> {
7
+ /**
8
+ * The `<Menu.Root>`s that make up the bar, and any
9
+ * `<Menu.Separator orientation="vertical">` between them.
10
+ */
11
+ children?: React.ReactNode;
12
+ /**
13
+ * How loud the bar itself is. `plain` draws nothing — the strip is the
14
+ * menus, which is what an application menu bar sitting under a title bar
15
+ * should look like. `contained` puts it on a panel with a hairline, for a
16
+ * bar that has to read as its own toolbar inside a busier page.
17
+ * @default "plain"
18
+ */
19
+ variant?: MenubarVariant;
20
+ /**
21
+ * Which way the bar runs. `vertical` is a sidebar of menus, and each one
22
+ * still opens below its trigger — pass `side="inline-end"` to the popups if
23
+ * they should open alongside instead.
24
+ *
25
+ * It is also what Base UI reports as `aria-orientation`, and it decides
26
+ * which arrow keys move between triggers.
27
+ * @default "horizontal"
28
+ */
29
+ orientation?: MenubarOrientation;
30
+ /**
31
+ * Whether an open menu locks page scroll and blocks pointer interaction
32
+ * with the rest of the document. On by default, which is what a desktop
33
+ * menu bar does — and what makes clicking anywhere else close the menu
34
+ * rather than act.
35
+ * @default true
36
+ */
37
+ modal?: BaseMenubarProps["modal"];
38
+ /**
39
+ * Whether every menu in the bar ignores user interaction. Base UI hands
40
+ * this down to each `<Menu.Trigger>`, so they all report `data-disabled`
41
+ * without being given the prop individually.
42
+ * @default false
43
+ */
44
+ disabled?: BaseMenubarProps["disabled"];
45
+ /**
46
+ * Whether the arrow keys wrap from the last trigger back to the first.
47
+ * @default true
48
+ */
49
+ loopFocus?: BaseMenubarProps["loopFocus"];
50
+ /**
51
+ * Replaces the rendered `<div>` with another element or component — a
52
+ * `<header>` for an application chrome bar, say. Base UI still applies
53
+ * `role="menubar"` and the keyboard behaviour to whatever comes back.
54
+ */
55
+ render?: BaseMenubarProps["render"];
56
+ /**
57
+ * Additional class name(s). Applied after the internal styles so consumer
58
+ * utilities (e.g. Tailwind) win without needing `!important`.
59
+ */
60
+ className?: string;
61
+ }
62
+ /**
63
+ * A row of menus that behave as one strip, built on Base UI's `Menubar`
64
+ * primitive.
65
+ *
66
+ * It has no parts of its own: the menus inside it are ordinary
67
+ * [`Menu`](/components/menu) components, which is Base UI's own anatomy and
68
+ * is what makes every Menu feature — submenus, checkable rows, shortcuts,
69
+ * `render` on the trigger — available here without a second set of
70
+ * components to learn.
71
+ *
72
+ * ```tsx
73
+ * <Menubar>
74
+ * <Menu.Root>
75
+ * <Menu.Trigger>File</Menu.Trigger>
76
+ * <Menu.Popup>
77
+ * <Menu.Item>New document</Menu.Item>
78
+ * <Menu.Item>Open…</Menu.Item>
79
+ * </Menu.Popup>
80
+ * </Menu.Root>
81
+ * <Menu.Root>
82
+ * <Menu.Trigger>Edit</Menu.Trigger>
83
+ * <Menu.Popup>
84
+ * <Menu.Item>Undo</Menu.Item>
85
+ * </Menu.Popup>
86
+ * </Menu.Root>
87
+ * </Menubar>
88
+ * ```
89
+ *
90
+ * Being in the bar is what changes the menus' behaviour, and Base UI does all
91
+ * of it: `Tab` reaches the bar once and the arrow keys move between triggers
92
+ * from there, and once one menu is open the others take over on hover, so the
93
+ * whole row reads as a single control rather than a line of buttons. The
94
+ * library's contribution is the look — a `<Menu.Trigger>` inside a `Menubar`
95
+ * drops its standalone button chrome for the flat strip item the bar wants.
96
+ * A trigger given `render` keeps whatever it was rendered as.
97
+ *
98
+ * Every visual decision is a `--forte-menubar-*` custom property declared on
99
+ * this element, including the ones the triggers read, so a bar can be
100
+ * re-skinned from plain CSS or targeted with Tailwind arbitrary variants
101
+ * (`data-[variant=contained]:...`) without wrapping.
102
+ */
103
+ export declare const Menubar: React.ForwardRefExoticComponent<MenubarProps & React.RefAttributes<HTMLDivElement>>;
104
+ export {};
@@ -0,0 +1,3 @@
1
+ "use client";
2
+ import { t as e } from "../../Menubar-Dax027Db.js";
3
+ export { e as Menubar };
@@ -0,0 +1,2 @@
1
+ export { Menubar } from './Menubar';
2
+ export type { MenubarProps, MenubarVariant, MenubarOrientation, } from './Menubar';
@@ -0,0 +1,2 @@
1
+ import { t as e } from "../../Menubar-Dax027Db.js";
2
+ export { e as Menubar };
@@ -0,0 +1,290 @@
1
+ import { Collapsible as BaseCollapsible } from '@base-ui/react/collapsible';
2
+ import { useRender } from '@base-ui/react/use-render';
3
+ import * as React from "react";
4
+ export type NavListSize = "sm" | "md" | "lg";
5
+ export type NavListMarker = "fill" | "rail";
6
+ type BaseGroupProps = React.ComponentPropsWithoutRef<typeof BaseCollapsible.Root>;
7
+ type BaseGroupTriggerProps = React.ComponentPropsWithoutRef<typeof BaseCollapsible.Trigger>;
8
+ type BaseGroupPanelProps = React.ComponentPropsWithoutRef<typeof BaseCollapsible.Panel>;
9
+ export interface NavListRootProps extends Omit<React.ComponentPropsWithoutRef<"nav">, "className"> {
10
+ /**
11
+ * Row height and text size for every link and group trigger inside.
12
+ * @default "md"
13
+ */
14
+ size?: NavListSize;
15
+ /**
16
+ * How the current item is marked. `"fill"` is a tinted row. `"rail"` adds a
17
+ * short accent bar along the row's inline-start edge on top of the fill —
18
+ * the classic sidebar treatment, and a second, non-colour-only cue.
19
+ * @default "fill"
20
+ */
21
+ marker?: NavListMarker;
22
+ /**
23
+ * Replaces the rendered `<nav>` with another element or component — pass
24
+ * `render={<div />}` when the list sits inside a `<nav>` landmark you
25
+ * already own, so the page does not grow a second one.
26
+ */
27
+ render?: useRender.RenderProp;
28
+ /**
29
+ * Additional class name(s). Applied after the internal styles so consumer
30
+ * utilities (e.g. Tailwind) win without needing `!important`.
31
+ */
32
+ className?: string;
33
+ }
34
+ /**
35
+ * The list container. Renders a `<nav>` landmark.
36
+ *
37
+ * ```tsx
38
+ * <NavList.Root aria-label="Documentation">
39
+ * <NavList.Section>
40
+ * <NavList.SectionLabel>Guides</NavList.SectionLabel>
41
+ * <NavList.List>
42
+ * <NavList.Item>
43
+ * <NavList.Link href="/intro" active>Introduction</NavList.Link>
44
+ * </NavList.Item>
45
+ * </NavList.List>
46
+ * </NavList.Section>
47
+ * </NavList.Root>
48
+ * ```
49
+ *
50
+ * Give it an `aria-label` (or `aria-labelledby`): a page routinely carries
51
+ * more than one navigation landmark — a header, a sidebar, a table of
52
+ * contents — and an unnamed one cannot be told from the others in a screen
53
+ * reader's landmark list.
54
+ *
55
+ * Which item is current is the consumer's call, made per `Link` through its
56
+ * `active` prop. The component deliberately does not read a router: matching
57
+ * an href against a location is the app's business, and every framework does
58
+ * it differently.
59
+ */
60
+ export declare const NavListRoot: React.ForwardRefExoticComponent<NavListRootProps & React.RefAttributes<HTMLElement>>;
61
+ export interface NavListSectionProps extends Omit<React.ComponentPropsWithoutRef<"div">, "className"> {
62
+ /**
63
+ * Additional class name(s). Applied after the internal styles so consumer
64
+ * utilities (e.g. Tailwind) win without needing `!important`.
65
+ */
66
+ className?: string;
67
+ }
68
+ /**
69
+ * One titled block of the list: a `SectionLabel` and a `List`. Renders a
70
+ * `<div role="group">`, named by its label once one is present — which is
71
+ * what lets a screen reader report "Components, group" instead of a run of
72
+ * links with a stray line of text above them.
73
+ *
74
+ * Purely structural: sections do not collapse. For a block the reader can
75
+ * fold away, use `NavList.Group` inside a `List` instead.
76
+ */
77
+ export declare const NavListSection: React.ForwardRefExoticComponent<NavListSectionProps & React.RefAttributes<HTMLDivElement>>;
78
+ export interface NavListSectionLabelProps extends Omit<React.ComponentPropsWithoutRef<"div">, "className"> {
79
+ /**
80
+ * Additional class name(s). Applied after the internal styles so consumer
81
+ * utilities (e.g. Tailwind) win without needing `!important`.
82
+ */
83
+ className?: string;
84
+ }
85
+ /**
86
+ * The section's title. Renders a `<div>` — deliberately not a heading:
87
+ * sidebars sit beside a document with its own outline, and a run of `<h2>`s
88
+ * in the chrome would interleave with the page's real headings in a screen
89
+ * reader's outline view. The enclosing `Section` picks the text up as its
90
+ * accessible name instead, which conveys the same structure in the right
91
+ * channel.
92
+ */
93
+ export declare const NavListSectionLabel: React.ForwardRefExoticComponent<NavListSectionLabelProps & React.RefAttributes<HTMLDivElement>>;
94
+ export interface NavListListProps extends Omit<React.ComponentPropsWithoutRef<"ul">, "className"> {
95
+ /**
96
+ * Additional class name(s). Applied after the internal styles so consumer
97
+ * utilities (e.g. Tailwind) win without needing `!important`.
98
+ */
99
+ className?: string;
100
+ }
101
+ /**
102
+ * The `<ul>` holding the rows. A real list on purpose: screen readers
103
+ * announce "list, N items", which is the count a reader wants before deciding
104
+ * whether to walk it.
105
+ *
106
+ * Nest one inside a `GroupPanel` — or inside an `Item`, after its `Link` —
107
+ * and it indents itself and draws the guide line. Depth is expressed by
108
+ * nesting alone; there is no `level` prop to keep in sync with the markup.
109
+ */
110
+ export declare const NavListList: React.ForwardRefExoticComponent<NavListListProps & React.RefAttributes<HTMLUListElement>>;
111
+ export interface NavListItemProps extends Omit<React.ComponentPropsWithoutRef<"li">, "className"> {
112
+ /**
113
+ * Additional class name(s). Applied after the internal styles so consumer
114
+ * utilities (e.g. Tailwind) win without needing `!important`.
115
+ */
116
+ className?: string;
117
+ }
118
+ /**
119
+ * One row's `<li>`. Structural — the interactive element is the `Link` (or
120
+ * `Group`) inside it. It exists as its own part rather than being fused into
121
+ * `Link` so a row can hold more than a link: a link plus a nested `List` is
122
+ * how a subtree with a navigable parent is written.
123
+ */
124
+ export declare const NavListItem: React.ForwardRefExoticComponent<NavListItemProps & React.RefAttributes<HTMLLIElement>>;
125
+ export interface NavListLinkProps extends Omit<React.ComponentPropsWithoutRef<"a">, "className"> {
126
+ /**
127
+ * Whether this row is where the reader currently is. Publishes
128
+ * `data-active` for styling and `aria-current="page"`, so the cue is never
129
+ * colour alone. For a same-page target — a table of contents — pass your
130
+ * own `aria-current="location"` alongside it; an explicit value wins over
131
+ * the derived one.
132
+ * @default false
133
+ */
134
+ active?: boolean;
135
+ /**
136
+ * Disables the row. The default `<a>` drops its `href` (an anchor without
137
+ * one is unfocusable and inert), `aria-disabled` is set, and clicks are
138
+ * swallowed — which is also what covers an element supplied through
139
+ * `render`, whose own `href` this component cannot remove.
140
+ * @default false
141
+ */
142
+ disabled?: boolean;
143
+ /**
144
+ * Replaces the rendered `<a>` with another element or component —
145
+ * `render={<Link href="/pricing" />}` is how a framework's router link goes
146
+ * in without losing the row's styling and states.
147
+ */
148
+ render?: useRender.RenderProp;
149
+ /**
150
+ * Additional class name(s). Applied after the internal styles so consumer
151
+ * utilities (e.g. Tailwind) win without needing `!important`.
152
+ */
153
+ className?: string;
154
+ }
155
+ /**
156
+ * The navigable row. Renders an `<a>`.
157
+ *
158
+ * Children lay out on a flex row, so an icon in front of the text and a
159
+ * `NavList.Badge` after it need no wrapper — the badge floats itself to the
160
+ * inline-end edge.
161
+ */
162
+ export declare const NavListLink: React.ForwardRefExoticComponent<NavListLinkProps & React.RefAttributes<HTMLAnchorElement>>;
163
+ export interface NavListGroupProps extends Omit<BaseGroupProps, "className"> {
164
+ /**
165
+ * Additional class name(s). Applied after the internal styles so consumer
166
+ * utilities (e.g. Tailwind) win without needing `!important`.
167
+ */
168
+ className?: string;
169
+ }
170
+ /**
171
+ * A collapsible subtree: a `GroupTrigger` and a `GroupPanel` holding a nested
172
+ * `List`. Built on Base UI's `Collapsible`, so it takes the same state props —
173
+ * `defaultOpen` uncontrolled, `open` plus `onOpenChange` controlled, and
174
+ * `disabled`.
175
+ *
176
+ * Renders an `<li>` (via `render`, which you can still override), so it sits
177
+ * in a `List` as a sibling of ordinary `Item`s.
178
+ */
179
+ export declare const NavListGroup: React.ForwardRefExoticComponent<NavListGroupProps & React.RefAttributes<HTMLLIElement>>;
180
+ export interface NavListGroupTriggerProps extends Omit<BaseGroupTriggerProps, "className"> {
181
+ /**
182
+ * Whether the reader is currently somewhere INSIDE this group — the cue
183
+ * that keeps the current location visible while the group is closed over
184
+ * it. Styling only (`data-active`): no `aria-current`, because the current
185
+ * page is a link, and this is the button that reveals it.
186
+ * @default false
187
+ */
188
+ active?: boolean;
189
+ /**
190
+ * The marker at the inline-end edge. Defaults to a chevron that rotates as
191
+ * the panel opens. Pass your own node — it goes in the same rotating,
192
+ * `aria-hidden` box — or `null` to drop it.
193
+ * @default a chevron
194
+ */
195
+ icon?: React.ReactNode;
196
+ /**
197
+ * Additional class name(s). Applied after the internal styles so consumer
198
+ * utilities (e.g. Tailwind) win without needing `!important`.
199
+ */
200
+ className?: string;
201
+ }
202
+ /**
203
+ * The row that opens and closes its group. Renders a `<button>` styled like a
204
+ * `Link`, carrying `aria-expanded` and an `aria-controls` pointing at the
205
+ * panel.
206
+ *
207
+ * Keep the text as the accessible name — `aria-expanded` already announces
208
+ * open and closed, so the label needs no "show/hide" of its own.
209
+ */
210
+ export declare const NavListGroupTrigger: React.ForwardRefExoticComponent<NavListGroupTriggerProps & React.RefAttributes<HTMLButtonElement>>;
211
+ export interface NavListGroupPanelProps extends Omit<BaseGroupPanelProps, "className"> {
212
+ /**
213
+ * Keep the panel in the DOM while closed. On by default — the opposite of
214
+ * Base UI's — because these are NAVIGATION links: unmounted, they are
215
+ * invisible to crawlers and to find-in-page, and a closed group is exactly
216
+ * where the page a crawler wants usually is. `hidden` keeps the closed
217
+ * copy out of the accessibility tree and the tab order either way.
218
+ * @default true
219
+ */
220
+ keepMounted?: BaseGroupPanelProps["keepMounted"];
221
+ /**
222
+ * Additional class name(s). Applied after the internal styles so consumer
223
+ * utilities (e.g. Tailwind) win without needing `!important`.
224
+ */
225
+ className?: string;
226
+ }
227
+ /**
228
+ * The collapsible region under a `GroupTrigger` — put a `NavList.List` in it.
229
+ * Base UI measures it and publishes `--collapsible-panel-height`, which the
230
+ * stylesheet transitions.
231
+ */
232
+ export declare const NavListGroupPanel: React.ForwardRefExoticComponent<NavListGroupPanelProps & React.RefAttributes<HTMLDivElement>>;
233
+ export interface NavListBadgeProps extends Omit<React.ComponentPropsWithoutRef<"span">, "className"> {
234
+ /**
235
+ * Additional class name(s). Applied after the internal styles so consumer
236
+ * utilities (e.g. Tailwind) win without needing `!important`.
237
+ */
238
+ className?: string;
239
+ }
240
+ /**
241
+ * A small pill at the row's inline-end edge — "New", "Beta", a count. Drop it
242
+ * inside a `Link` or `GroupTrigger` after the text; `margin-inline-start:
243
+ * auto` walks it to the far edge on its own.
244
+ *
245
+ * It reads in the row's flow, so a screen reader announces "Changelog, New" —
246
+ * no extra wiring. Drawn from the secondary ramp rather than the accent, so
247
+ * it stays legible sitting on the active row's accent fill.
248
+ */
249
+ export declare const NavListBadge: React.ForwardRefExoticComponent<NavListBadgeProps & React.RefAttributes<HTMLSpanElement>>;
250
+ /**
251
+ * A sidebar-style list of navigation links: titled sections, collapsible
252
+ * groups, nested levels with a guide line, and a controlled notion of "where
253
+ * you are".
254
+ *
255
+ * ```tsx
256
+ * <NavList.Root aria-label="Documentation">
257
+ * <NavList.Section>
258
+ * <NavList.SectionLabel>Components</NavList.SectionLabel>
259
+ * <NavList.List>
260
+ * <NavList.Item>
261
+ * <NavList.Link href="/button" active>Button</NavList.Link>
262
+ * </NavList.Item>
263
+ * <NavList.Group defaultOpen>
264
+ * <NavList.GroupTrigger>Forms</NavList.GroupTrigger>
265
+ * <NavList.GroupPanel>
266
+ * <NavList.List>…</NavList.List>
267
+ * </NavList.GroupPanel>
268
+ * </NavList.Group>
269
+ * </NavList.List>
270
+ * </NavList.Section>
271
+ * </NavList.Root>
272
+ * ```
273
+ *
274
+ * Styling is driven entirely by `data-*` attributes and `--forte-nav-list-*`
275
+ * custom properties, so it can be re-skinned from plain CSS or targeted with
276
+ * Tailwind arbitrary variants (`data-[active]:...`) without wrapping.
277
+ */
278
+ export declare const NavList: {
279
+ Root: React.ForwardRefExoticComponent<NavListRootProps & React.RefAttributes<HTMLElement>>;
280
+ Section: React.ForwardRefExoticComponent<NavListSectionProps & React.RefAttributes<HTMLDivElement>>;
281
+ SectionLabel: React.ForwardRefExoticComponent<NavListSectionLabelProps & React.RefAttributes<HTMLDivElement>>;
282
+ List: React.ForwardRefExoticComponent<NavListListProps & React.RefAttributes<HTMLUListElement>>;
283
+ Item: React.ForwardRefExoticComponent<NavListItemProps & React.RefAttributes<HTMLLIElement>>;
284
+ Link: React.ForwardRefExoticComponent<NavListLinkProps & React.RefAttributes<HTMLAnchorElement>>;
285
+ Group: React.ForwardRefExoticComponent<NavListGroupProps & React.RefAttributes<HTMLLIElement>>;
286
+ GroupTrigger: React.ForwardRefExoticComponent<NavListGroupTriggerProps & React.RefAttributes<HTMLButtonElement>>;
287
+ GroupPanel: React.ForwardRefExoticComponent<NavListGroupPanelProps & React.RefAttributes<HTMLDivElement>>;
288
+ Badge: React.ForwardRefExoticComponent<NavListBadgeProps & React.RefAttributes<HTMLSpanElement>>;
289
+ };
290
+ export {};
@@ -0,0 +1,3 @@
1
+ "use client";
2
+ import { a as e, c as t, d as n, i as r, l as i, n as a, o, r as s, s as c, t as l, u } from "../../NavList-DGvcIoJm.js";
3
+ export { l as NavList, a as NavListBadge, s as NavListGroup, r as NavListGroupPanel, e as NavListGroupTrigger, o as NavListItem, c as NavListLink, t as NavListList, i as NavListRoot, u as NavListSection, n as NavListSectionLabel };
@@ -0,0 +1,2 @@
1
+ export { NavList } from './NavList';
2
+ export type { NavListSize, NavListMarker, NavListRootProps, NavListSectionProps, NavListSectionLabelProps, NavListListProps, NavListItemProps, NavListLinkProps, NavListGroupProps, NavListGroupTriggerProps, NavListGroupPanelProps, NavListBadgeProps, } from './NavList';
@@ -0,0 +1,2 @@
1
+ import { t as e } from "../../NavList-DGvcIoJm.js";
2
+ export { e as NavList };