@arolariu/components 1.0.0 → 1.1.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.
Files changed (218) hide show
  1. package/CHANGELOG.md +57 -0
  2. package/EXAMPLES.md +2510 -0
  3. package/dist/components/ui/alert-dialog.d.ts +4 -16
  4. package/dist/components/ui/alert-dialog.d.ts.map +1 -1
  5. package/dist/components/ui/alert-dialog.js +18 -14
  6. package/dist/components/ui/alert-dialog.js.map +1 -1
  7. package/dist/components/ui/avatar.d.ts +3 -12
  8. package/dist/components/ui/avatar.d.ts.map +1 -1
  9. package/dist/components/ui/avatar.js +18 -15
  10. package/dist/components/ui/avatar.js.map +1 -1
  11. package/dist/components/ui/button-group.d.ts +1 -1
  12. package/dist/components/ui/button-group.d.ts.map +1 -1
  13. package/dist/components/ui/calendar.d.ts +1 -4
  14. package/dist/components/ui/calendar.d.ts.map +1 -1
  15. package/dist/components/ui/calendar.js +7 -7
  16. package/dist/components/ui/calendar.js.map +1 -1
  17. package/dist/components/ui/carousel.d.ts.map +1 -1
  18. package/dist/components/ui/carousel.js.map +1 -1
  19. package/dist/components/ui/chart.d.ts.map +1 -1
  20. package/dist/components/ui/chart.js +125 -59
  21. package/dist/components/ui/chart.js.map +1 -1
  22. package/dist/components/ui/checkbox-group.d.ts +2 -6
  23. package/dist/components/ui/checkbox-group.d.ts.map +1 -1
  24. package/dist/components/ui/checkbox-group.js +8 -7
  25. package/dist/components/ui/checkbox-group.js.map +1 -1
  26. package/dist/components/ui/checkbox.d.ts +3 -1
  27. package/dist/components/ui/checkbox.d.ts.map +1 -1
  28. package/dist/components/ui/checkbox.js +4 -1
  29. package/dist/components/ui/checkbox.js.map +1 -1
  30. package/dist/components/ui/collapsible.d.ts.map +1 -1
  31. package/dist/components/ui/collapsible.js.map +1 -1
  32. package/dist/components/ui/combobox.d.ts +335 -0
  33. package/dist/components/ui/combobox.d.ts.map +1 -0
  34. package/dist/components/ui/combobox.js +206 -0
  35. package/dist/components/ui/combobox.js.map +1 -0
  36. package/dist/components/ui/combobox.module.js +23 -0
  37. package/dist/components/ui/combobox.module.js.map +1 -0
  38. package/dist/components/ui/combobox_module.css +142 -0
  39. package/dist/components/ui/combobox_module.css.map +1 -0
  40. package/dist/components/ui/command.d.ts.map +1 -1
  41. package/dist/components/ui/command.js +25 -16
  42. package/dist/components/ui/command.js.map +1 -1
  43. package/dist/components/ui/context-menu.d.ts.map +1 -1
  44. package/dist/components/ui/context-menu.js.map +1 -1
  45. package/dist/components/ui/drawer.d.ts.map +1 -1
  46. package/dist/components/ui/drawer.js.map +1 -1
  47. package/dist/components/ui/dropdown-menu.d.ts.map +1 -1
  48. package/dist/components/ui/dropdown-menu.js.map +1 -1
  49. package/dist/components/ui/dropdrawer.d.ts +10 -16
  50. package/dist/components/ui/dropdrawer.d.ts.map +1 -1
  51. package/dist/components/ui/dropdrawer.js +28 -20
  52. package/dist/components/ui/dropdrawer.js.map +1 -1
  53. package/dist/components/ui/item.d.ts +1 -1
  54. package/dist/components/ui/item.d.ts.map +1 -1
  55. package/dist/components/ui/menubar.d.ts +11 -13
  56. package/dist/components/ui/menubar.d.ts.map +1 -1
  57. package/dist/components/ui/menubar.js.map +1 -1
  58. package/dist/components/ui/meter.d.ts +8 -24
  59. package/dist/components/ui/meter.d.ts.map +1 -1
  60. package/dist/components/ui/meter.js +23 -19
  61. package/dist/components/ui/meter.js.map +1 -1
  62. package/dist/components/ui/navigation-menu.d.ts +3 -12
  63. package/dist/components/ui/navigation-menu.d.ts.map +1 -1
  64. package/dist/components/ui/navigation-menu.js +14 -11
  65. package/dist/components/ui/navigation-menu.js.map +1 -1
  66. package/dist/components/ui/number-field.d.ts +6 -12
  67. package/dist/components/ui/number-field.d.ts.map +1 -1
  68. package/dist/components/ui/number-field.js.map +1 -1
  69. package/dist/components/ui/progress.d.ts +1 -4
  70. package/dist/components/ui/progress.d.ts.map +1 -1
  71. package/dist/components/ui/progress.js +10 -9
  72. package/dist/components/ui/progress.js.map +1 -1
  73. package/dist/components/ui/radio-group.d.ts +2 -4
  74. package/dist/components/ui/radio-group.d.ts.map +1 -1
  75. package/dist/components/ui/radio-group.js.map +1 -1
  76. package/dist/components/ui/resizable.d.ts +3 -3
  77. package/dist/components/ui/resizable.d.ts.map +1 -1
  78. package/dist/components/ui/resizable.js.map +1 -1
  79. package/dist/components/ui/scratcher.d.ts +1 -1
  80. package/dist/components/ui/scratcher.d.ts.map +1 -1
  81. package/dist/components/ui/scratcher.js +5 -4
  82. package/dist/components/ui/scratcher.js.map +1 -1
  83. package/dist/components/ui/scroll-area.d.ts +2 -4
  84. package/dist/components/ui/scroll-area.d.ts.map +1 -1
  85. package/dist/components/ui/scroll-area.js.map +1 -1
  86. package/dist/components/ui/separator.d.ts +1 -4
  87. package/dist/components/ui/separator.d.ts.map +1 -1
  88. package/dist/components/ui/separator.js +9 -8
  89. package/dist/components/ui/separator.js.map +1 -1
  90. package/dist/components/ui/sheet.d.ts.map +1 -1
  91. package/dist/components/ui/sheet.js.map +1 -1
  92. package/dist/components/ui/sidebar.d.ts +1 -1
  93. package/dist/components/ui/sidebar.d.ts.map +1 -1
  94. package/dist/components/ui/sidebar.js.map +1 -1
  95. package/dist/components/ui/sonner.d.ts +5 -4
  96. package/dist/components/ui/sonner.d.ts.map +1 -1
  97. package/dist/components/ui/sonner.js +7 -6
  98. package/dist/components/ui/sonner.js.map +1 -1
  99. package/dist/components/ui/toggle-group.d.ts +2 -8
  100. package/dist/components/ui/toggle-group.d.ts.map +1 -1
  101. package/dist/components/ui/toggle-group.js +12 -10
  102. package/dist/components/ui/toggle-group.js.map +1 -1
  103. package/dist/components/ui/toolbar.d.ts +10 -30
  104. package/dist/components/ui/toolbar.d.ts.map +1 -1
  105. package/dist/components/ui/toolbar.js +28 -23
  106. package/dist/components/ui/toolbar.js.map +1 -1
  107. package/dist/hooks/useClipboard.d.ts +77 -0
  108. package/dist/hooks/useClipboard.d.ts.map +1 -0
  109. package/dist/hooks/useClipboard.js +42 -0
  110. package/dist/hooks/useClipboard.js.map +1 -0
  111. package/dist/hooks/useControllableState.d.ts +54 -0
  112. package/dist/hooks/useControllableState.d.ts.map +1 -0
  113. package/dist/hooks/useControllableState.js +29 -0
  114. package/dist/hooks/useControllableState.js.map +1 -0
  115. package/dist/hooks/useDebounce.d.ts +33 -0
  116. package/dist/hooks/useDebounce.d.ts.map +1 -0
  117. package/dist/hooks/useDebounce.js +20 -0
  118. package/dist/hooks/useDebounce.js.map +1 -0
  119. package/dist/hooks/useEventCallback.d.ts +34 -0
  120. package/dist/hooks/useEventCallback.d.ts.map +1 -0
  121. package/dist/hooks/useEventCallback.js +12 -0
  122. package/dist/hooks/useEventCallback.js.map +1 -0
  123. package/dist/hooks/useId.d.ts +30 -0
  124. package/dist/hooks/useId.d.ts.map +1 -0
  125. package/dist/hooks/useId.js +9 -0
  126. package/dist/hooks/useId.js.map +1 -0
  127. package/dist/hooks/useIntersectionObserver.d.ts +51 -0
  128. package/dist/hooks/useIntersectionObserver.d.ts.map +1 -0
  129. package/dist/hooks/useIntersectionObserver.js +25 -0
  130. package/dist/hooks/useIntersectionObserver.js.map +1 -0
  131. package/dist/hooks/useInterval.d.ts +55 -0
  132. package/dist/hooks/useInterval.d.ts.map +1 -0
  133. package/dist/hooks/useInterval.js +24 -0
  134. package/dist/hooks/useInterval.js.map +1 -0
  135. package/dist/hooks/useLocalStorage.d.ts +43 -0
  136. package/dist/hooks/useLocalStorage.d.ts.map +1 -0
  137. package/dist/hooks/useLocalStorage.js +53 -0
  138. package/dist/hooks/useLocalStorage.js.map +1 -0
  139. package/dist/hooks/useMergedRefs.d.ts +27 -0
  140. package/dist/hooks/useMergedRefs.d.ts.map +1 -0
  141. package/dist/hooks/useMergedRefs.js +11 -0
  142. package/dist/hooks/useMergedRefs.js.map +1 -0
  143. package/dist/hooks/useOnClickOutside.d.ts +32 -0
  144. package/dist/hooks/useOnClickOutside.d.ts.map +1 -0
  145. package/dist/hooks/useOnClickOutside.js +23 -0
  146. package/dist/hooks/useOnClickOutside.js.map +1 -0
  147. package/dist/hooks/usePrevious.d.ts +33 -0
  148. package/dist/hooks/usePrevious.d.ts.map +1 -0
  149. package/dist/hooks/usePrevious.js +14 -0
  150. package/dist/hooks/usePrevious.js.map +1 -0
  151. package/dist/hooks/useThrottle.d.ts +37 -0
  152. package/dist/hooks/useThrottle.d.ts.map +1 -0
  153. package/dist/hooks/useThrottle.js +34 -0
  154. package/dist/hooks/useThrottle.js.map +1 -0
  155. package/dist/hooks/useTimeout.d.ts +28 -0
  156. package/dist/hooks/useTimeout.d.ts.map +1 -0
  157. package/dist/hooks/useTimeout.js +24 -0
  158. package/dist/hooks/useTimeout.js.map +1 -0
  159. package/dist/index.d.ts +14 -0
  160. package/dist/index.d.ts.map +1 -1
  161. package/dist/index.js +14 -0
  162. package/dist/lib/utilities.d.ts +2 -3
  163. package/dist/lib/utilities.d.ts.map +1 -1
  164. package/dist/lib/utilities.js.map +1 -1
  165. package/dist/motion/tokens.js +5 -5
  166. package/dist/motion/tokens.js.map +1 -1
  167. package/dist/rslib-runtime.js +39 -0
  168. package/dist/rslib-runtime.js.map +1 -0
  169. package/package.json +82 -3
  170. package/src/components/ui/alert-dialog.tsx +15 -8
  171. package/src/components/ui/avatar.tsx +9 -6
  172. package/src/components/ui/calendar.tsx +7 -13
  173. package/src/components/ui/carousel.tsx +2 -0
  174. package/src/components/ui/chart.tsx +63 -60
  175. package/src/components/ui/checkbox-group.tsx +4 -5
  176. package/src/components/ui/checkbox.tsx +10 -2
  177. package/src/components/ui/collapsible.tsx +1 -0
  178. package/src/components/ui/combobox.module.css +158 -0
  179. package/src/components/ui/combobox.tsx +569 -0
  180. package/src/components/ui/command.tsx +31 -15
  181. package/src/components/ui/context-menu.tsx +3 -0
  182. package/src/components/ui/drawer.tsx +2 -0
  183. package/src/components/ui/dropdown-menu.tsx +3 -0
  184. package/src/components/ui/dropdrawer.tsx +80 -62
  185. package/src/components/ui/menubar.tsx +9 -10
  186. package/src/components/ui/meter.tsx +16 -17
  187. package/src/components/ui/navigation-menu.tsx +41 -33
  188. package/src/components/ui/number-field.tsx +6 -13
  189. package/src/components/ui/progress.tsx +3 -2
  190. package/src/components/ui/radio-group.tsx +2 -5
  191. package/src/components/ui/resizable.tsx +2 -2
  192. package/src/components/ui/scratcher.tsx +6 -10
  193. package/src/components/ui/scroll-area.tsx +2 -5
  194. package/src/components/ui/separator.tsx +4 -3
  195. package/src/components/ui/sheet.tsx +3 -0
  196. package/src/components/ui/sidebar.tsx +1 -0
  197. package/src/components/ui/sonner.tsx +20 -12
  198. package/src/components/ui/toggle-group.tsx +6 -4
  199. package/src/components/ui/toolbar.tsx +20 -21
  200. package/src/hooks/useClipboard.tsx +137 -0
  201. package/src/hooks/useControllableState.tsx +81 -0
  202. package/src/hooks/useDebounce.tsx +50 -0
  203. package/src/hooks/useEventCallback.tsx +47 -0
  204. package/src/hooks/useId.tsx +36 -0
  205. package/src/hooks/useIntersectionObserver.tsx +81 -0
  206. package/src/hooks/useInterval.tsx +80 -0
  207. package/src/hooks/useLocalStorage.tsx +111 -0
  208. package/src/hooks/useMergedRefs.tsx +48 -0
  209. package/src/hooks/useOnClickOutside.tsx +55 -0
  210. package/src/hooks/usePrevious.tsx +44 -0
  211. package/src/hooks/useThrottle.tsx +78 -0
  212. package/src/hooks/useTimeout.tsx +51 -0
  213. package/src/index.ts +23 -0
  214. package/src/lib/utilities.ts +4 -4
  215. package/src/motion/tokens.ts +4 -4
  216. package/src/stories/DesignPrinciples.mdx +48 -0
  217. package/src/stories/GettingStarted.mdx +92 -0
  218. package/src/stories/Welcome.mdx +44 -0
@@ -1 +1 @@
1
- {"version":3,"file":"components/ui/menubar.js","sources":["../../../src/components/ui/menubar.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {Menu as BaseMenu} from \"@base-ui/react/menu\";\r\nimport {Menubar as BaseMenubar} from \"@base-ui/react/menubar\";\r\nimport {mergeProps} from \"@base-ui/react/merge-props\";\r\nimport {useRender} from \"@base-ui/react/use-render\";\r\nimport {Check, ChevronRight, Circle} from \"lucide-react\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\nimport styles from \"./menubar.module.css\";\r\n\r\ntype MenubarProps = Omit<React.ComponentPropsWithRef<typeof BaseMenubar>, \"className\"> & {className?: string};\r\ninterface MenubarTriggerProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.Trigger>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\ninterface MenubarSubTriggerProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.SubmenuTrigger>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n /**\r\n * Applies inset spacing to align nested content.\r\n * @default false\r\n */\r\n inset?: boolean;\r\n}\r\ninterface MenubarContentProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.Positioner>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\ninterface MenubarItemProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.Item>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n /**\r\n * Applies inset spacing to align nested content.\r\n * @default false\r\n */\r\n inset?: boolean;\r\n}\r\ninterface MenubarCheckboxItemProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.CheckboxItem>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\ninterface MenubarRadioItemProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.RadioItem>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\ninterface MenubarLabelProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.GroupLabel>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n /**\r\n * Applies inset spacing to align nested content.\r\n * @default false\r\n */\r\n inset?: boolean;\r\n}\r\ninterface MenubarSeparatorProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.Separator>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\ninterface MenubarShortcutProps extends React.ComponentPropsWithRef<\"span\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n /**\r\n * Overrides the default rendered element while preserving component behavior.\r\n * @default undefined\r\n */\r\n render?: useRender.RenderProp<Record<string, never>>;\r\n /**\r\n * Enables child element composition instead of rendering the default wrapper.\r\n * @default false\r\n * @deprecated Prefer Base UI's `render` prop.\r\n */\r\n asChild?: boolean;\r\n}\r\n\r\n/**\r\n * Renders the menubar menu.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarMenu>Content</MenubarMenu>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarMenu: typeof BaseMenu.Root & {displayName?: string} = BaseMenu.Root;\r\n/**\r\n * Renders the menubar group.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarGroup>Content</MenubarGroup>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarGroup = BaseMenu.Group;\r\n/**\r\n * Provides the menubar portal container.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarPortal>Content</MenubarPortal>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarPortal = BaseMenu.Portal;\r\n/**\r\n * Coordinates the menubar radio group.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarRadioGroup>Content</MenubarRadioGroup>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarRadioGroup = BaseMenu.RadioGroup;\r\n/**\r\n * Coordinates the menubar sub.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarSub>Content</MenubarSub>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarSub: typeof BaseMenu.SubmenuRoot & {displayName?: string} = BaseMenu.SubmenuRoot;\r\n\r\n/**\r\n * Coordinates menubar state and accessibility behavior.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <Menubar>Content</Menubar>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction Menubar(props: Readonly<Menubar.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenubar\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.root, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenubar>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar trigger.\r\n *\r\n * @remarks\r\n * - Renders a `<button>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarTrigger>Content</MenubarTrigger>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarTrigger = React.forwardRef<HTMLButtonElement, MenubarTrigger.Props>(\r\n (props: Readonly<MenubarTrigger.Props>, ref): React.ReactElement => {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.Trigger\r\n ref={ref}\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"button\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.trigger, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenu.Trigger>\r\n );\r\n },\r\n);\r\n\r\n/**\r\n * Renders the menubar sub trigger.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarSubTrigger>Content</MenubarSubTrigger>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarSubTrigger(props: Readonly<MenubarSubTrigger.Props>): React.ReactElement {\r\n const {className, children, inset = false, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.SubmenuTrigger\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.item, styles.subTrigger, inset && styles.inset, className)}, {}),\r\n })}>\r\n {children}\r\n <ChevronRight className={styles.subTriggerIcon} />\r\n </BaseMenu.SubmenuTrigger>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar sub content.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarSubContent>Content</MenubarSubContent>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarSubContent(props: Readonly<MenubarContent.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.Positioner\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n props: mergeProps({className: styles.positioner}, {}),\r\n })}>\r\n <BaseMenu.Popup\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.content, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenu.Popup>\r\n </BaseMenu.Positioner>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar content.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarContent>Content</MenubarContent>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarContent = React.forwardRef<React.ComponentRef<typeof BaseMenu.Popup>, MenubarContent.Props>(\r\n (props: Readonly<MenubarContent.Props>, ref): React.ReactElement => {\r\n const {alignOffset = -4, className, children, render, sideOffset = 8, ...otherProps} = props;\r\n\r\n return (\r\n <MenubarPortal>\r\n <BaseMenu.Positioner\r\n alignOffset={alignOffset}\r\n sideOffset={sideOffset}\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n props: mergeProps({className: styles.positioner}, {}),\r\n })}>\r\n <BaseMenu.Popup\r\n ref={ref}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.content, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenu.Popup>\r\n </BaseMenu.Positioner>\r\n </MenubarPortal>\r\n );\r\n },\r\n);\r\n\r\n/**\r\n * Renders the menubar item.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarItem>Content</MenubarItem>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarItem(props: Readonly<MenubarItem.Props>): React.ReactElement {\r\n const {className, children, inset = false, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.Item\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.item, inset && styles.inset, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenu.Item>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar checkbox item.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarCheckboxItem>Content</MenubarCheckboxItem>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarCheckboxItem(props: Readonly<MenubarCheckboxItem.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.CheckboxItem\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.item, styles.indicatorItem, className)}, {}),\r\n })}>\r\n <span className={styles.indicatorSlot}>\r\n <BaseMenu.CheckboxItemIndicator>\r\n <Check className={styles.indicatorIcon} />\r\n </BaseMenu.CheckboxItemIndicator>\r\n </span>\r\n {children}\r\n </BaseMenu.CheckboxItem>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar radio item.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarRadioItem>Content</MenubarRadioItem>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarRadioItem(props: Readonly<MenubarRadioItem.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.RadioItem\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.item, styles.indicatorItem, className)}, {}),\r\n })}>\r\n <span className={styles.indicatorSlot}>\r\n <BaseMenu.RadioItemIndicator>\r\n <Circle className={styles.radioIndicatorIcon} />\r\n </BaseMenu.RadioItemIndicator>\r\n </span>\r\n {children}\r\n </BaseMenu.RadioItem>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar label.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarLabel>Content</MenubarLabel>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarLabel(props: Readonly<MenubarLabel.Props>): React.ReactElement {\r\n const {className, children, inset = false, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.GroupLabel\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.label, inset && styles.inset, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenu.GroupLabel>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar separator.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarSeparator>Content</MenubarSeparator>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarSeparator(props: Readonly<MenubarSeparator.Props>): React.ReactElement {\r\n const {className, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.Separator\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.separator, className)}, {}),\r\n })}\r\n />\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar shortcut.\r\n *\r\n * @remarks\r\n * - Renders a `<span>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarShortcut>Content</MenubarShortcut>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarShortcut(props: Readonly<MenubarShortcut.Props>): React.ReactElement {\r\n const {asChild = false, children, className, render, ...otherProps} = props;\r\n const renderProp = asChild && React.isValidElement(children) ? children : render;\r\n\r\n return useRender({\r\n defaultTagName: \"span\",\r\n render: renderProp as never,\r\n props: mergeProps({className: cn(styles.shortcut, className)}, otherProps, {\r\n children: renderProp ? undefined : children,\r\n }),\r\n });\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace Menubar {\r\n export type Props = MenubarProps;\r\n export type State = BaseMenubar.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarTrigger {\r\n export type Props = MenubarTriggerProps;\r\n export type State = BaseMenu.Trigger.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarSubTrigger {\r\n export type Props = MenubarSubTriggerProps;\r\n export type State = BaseMenu.SubmenuTrigger.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarContent {\r\n export type Props = MenubarContentProps;\r\n export type State = BaseMenu.Popup.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarSubContent {\r\n export type Props = MenubarContentProps;\r\n export type State = BaseMenu.Popup.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarItem {\r\n export type Props = MenubarItemProps;\r\n export type State = BaseMenu.Item.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarCheckboxItem {\r\n export type Props = MenubarCheckboxItemProps;\r\n export type State = BaseMenu.CheckboxItem.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarRadioItem {\r\n export type Props = MenubarRadioItemProps;\r\n export type State = BaseMenu.RadioItem.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarLabel {\r\n export type Props = MenubarLabelProps;\r\n export type State = BaseMenu.GroupLabel.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarSeparator {\r\n export type Props = MenubarSeparatorProps;\r\n export type State = BaseMenu.Separator.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarShortcut {\r\n export type Props = MenubarShortcutProps;\r\n export type State = Record<string, never>;\r\n}\r\n\r\nMenubarMenu.displayName = \"MenubarMenu\";\r\nMenubarGroup.displayName = \"MenubarGroup\";\r\nMenubarPortal.displayName = \"MenubarPortal\";\r\nMenubarRadioGroup.displayName = \"MenubarRadioGroup\";\r\nMenubarSub.displayName = \"MenubarSub\";\r\nMenubar.displayName = \"Menubar\";\r\nMenubarTrigger.displayName = \"MenubarTrigger\";\r\nMenubarSubTrigger.displayName = \"MenubarSubTrigger\";\r\nMenubarSubContent.displayName = \"MenubarSubContent\";\r\nMenubarContent.displayName = \"MenubarContent\";\r\nMenubarItem.displayName = \"MenubarItem\";\r\nMenubarCheckboxItem.displayName = \"MenubarCheckboxItem\";\r\nMenubarRadioItem.displayName = \"MenubarRadioItem\";\r\nMenubarLabel.displayName = \"MenubarLabel\";\r\nMenubarSeparator.displayName = \"MenubarSeparator\";\r\nMenubarShortcut.displayName = \"MenubarShortcut\";\r\n\r\nexport {\r\n Menubar,\r\n MenubarCheckboxItem,\r\n MenubarContent,\r\n MenubarGroup,\r\n MenubarItem,\r\n MenubarLabel,\r\n MenubarMenu,\r\n MenubarPortal,\r\n MenubarRadioGroup,\r\n MenubarRadioItem,\r\n MenubarSeparator,\r\n MenubarShortcut,\r\n MenubarSub,\r\n MenubarSubContent,\r\n MenubarSubTrigger,\r\n MenubarTrigger,\r\n};\r\n"],"names":["MenubarMenu","BaseMenu","MenubarGroup","MenubarPortal","MenubarRadioGroup","MenubarSub","Menubar","props","className","children","render","otherProps","BaseMenubar","useRender","mergeProps","cn","styles","MenubarTrigger","React","ref","MenubarSubTrigger","inset","ChevronRight","MenubarSubContent","MenubarContent","alignOffset","sideOffset","MenubarItem","MenubarCheckboxItem","Check","MenubarRadioItem","Circle","MenubarLabel","MenubarSeparator","MenubarShortcut","asChild","renderProp","undefined"],"mappings":";;;;;;;;;;AAsHA,MAAMA,cAA6DC,KAAAA,IAAa;AAgBhF,MAAMC,eAAeD,KAAAA,KA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AW,GAAG;AAClCE,iBAAiB,WAAW,GAAG;AAC/BE,aAAa,WAAW,GAAG;AAC3BC,iBAAiB,WAAW,GAAG;AAC/BC,gBAAgB,WAAW,GAAG"}
1
+ {"version":3,"file":"components/ui/menubar.js","sources":["../../../src/components/ui/menubar.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {Menu as BaseMenu} from \"@base-ui/react/menu\";\r\nimport {Menubar as BaseMenubar} from \"@base-ui/react/menubar\";\r\nimport {mergeProps} from \"@base-ui/react/merge-props\";\r\nimport {useRender} from \"@base-ui/react/use-render\";\r\nimport {Check, ChevronRight, Circle} from \"lucide-react\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\nimport styles from \"./menubar.module.css\";\r\n\r\ninterface MenubarSubTriggerProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.SubmenuTrigger>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n /**\r\n * Applies inset spacing to align nested content.\r\n * @default false\r\n */\r\n inset?: boolean;\r\n}\r\ninterface MenubarContentProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.Positioner>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\ninterface MenubarItemProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.Item>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n /**\r\n * Applies inset spacing to align nested content.\r\n * @default false\r\n */\r\n inset?: boolean;\r\n}\r\ninterface MenubarCheckboxItemProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.CheckboxItem>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\ninterface MenubarRadioItemProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.RadioItem>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\ninterface MenubarLabelProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.GroupLabel>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n /**\r\n * Applies inset spacing to align nested content.\r\n * @default false\r\n */\r\n inset?: boolean;\r\n}\r\ninterface MenubarSeparatorProps extends Omit<React.ComponentPropsWithRef<typeof BaseMenu.Separator>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\ninterface MenubarShortcutProps extends React.ComponentPropsWithRef<\"span\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n /**\r\n * Overrides the default rendered element while preserving component behavior.\r\n * @default undefined\r\n */\r\n render?: useRender.RenderProp<Record<string, never>>;\r\n /**\r\n * Enables child element composition instead of rendering the default wrapper.\r\n * @default false\r\n * @deprecated Prefer Base UI's `render` prop.\r\n */\r\n asChild?: boolean;\r\n}\r\n\r\n/**\r\n * Renders the menubar menu.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarMenu>Content</MenubarMenu>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarMenu: typeof BaseMenu.Root & {displayName?: string} = BaseMenu.Root;\r\n/**\r\n * Renders the menubar group.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarGroup>Content</MenubarGroup>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarGroup = BaseMenu.Group;\r\n/**\r\n * Provides the menubar portal container.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarPortal>Content</MenubarPortal>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarPortal = BaseMenu.Portal;\r\n/**\r\n * Coordinates the menubar radio group.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarRadioGroup>Content</MenubarRadioGroup>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarRadioGroup = BaseMenu.RadioGroup;\r\n/**\r\n * Coordinates the menubar sub.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarSub>Content</MenubarSub>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarSub: typeof BaseMenu.SubmenuRoot & {displayName?: string} = BaseMenu.SubmenuRoot;\r\n\r\n/**\r\n * Coordinates menubar state and accessibility behavior.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <Menubar>Content</Menubar>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction Menubar(props: Readonly<Menubar.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenubar\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.root, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenubar>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar trigger.\r\n *\r\n * @remarks\r\n * - Renders a `<button>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarTrigger>Content</MenubarTrigger>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarTrigger = React.forwardRef<HTMLButtonElement, MenubarTrigger.Props>(\r\n (props: Readonly<MenubarTrigger.Props>, ref): React.ReactElement => {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.Trigger\r\n ref={ref}\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"button\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.trigger, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenu.Trigger>\r\n );\r\n },\r\n);\r\n\r\n/**\r\n * Renders the menubar sub trigger.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarSubTrigger>Content</MenubarSubTrigger>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarSubTrigger(props: Readonly<MenubarSubTrigger.Props>): React.ReactElement {\r\n const {className, children, inset = false, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.SubmenuTrigger\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.item, styles.subTrigger, inset && styles.inset, className)}, {}),\r\n })}>\r\n {children}\r\n <ChevronRight className={styles.subTriggerIcon} />\r\n </BaseMenu.SubmenuTrigger>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar sub content.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarSubContent>Content</MenubarSubContent>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarSubContent(props: Readonly<MenubarContent.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.Positioner\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n props: mergeProps({className: styles.positioner}, {}),\r\n })}>\r\n <BaseMenu.Popup\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.content, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenu.Popup>\r\n </BaseMenu.Positioner>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar content.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarContent>Content</MenubarContent>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nconst MenubarContent = React.forwardRef<React.ComponentRef<typeof BaseMenu.Popup>, MenubarContent.Props>(\r\n (props: Readonly<MenubarContent.Props>, ref): React.ReactElement => {\r\n const {alignOffset = -4, className, children, render, sideOffset = 8, ...otherProps} = props;\r\n\r\n return (\r\n <MenubarPortal>\r\n <BaseMenu.Positioner\r\n alignOffset={alignOffset}\r\n sideOffset={sideOffset}\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n props: mergeProps({className: styles.positioner}, {}),\r\n })}>\r\n <BaseMenu.Popup\r\n ref={ref}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.content, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenu.Popup>\r\n </BaseMenu.Positioner>\r\n </MenubarPortal>\r\n );\r\n },\r\n);\r\n\r\n/**\r\n * Renders the menubar item.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarItem>Content</MenubarItem>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarItem(props: Readonly<MenubarItem.Props>): React.ReactElement {\r\n const {className, children, inset = false, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.Item\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.item, inset && styles.inset, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenu.Item>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar checkbox item.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarCheckboxItem>Content</MenubarCheckboxItem>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarCheckboxItem(props: Readonly<MenubarCheckboxItem.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.CheckboxItem\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.item, styles.indicatorItem, className)}, {}),\r\n })}>\r\n <span className={styles.indicatorSlot}>\r\n <BaseMenu.CheckboxItemIndicator>\r\n <Check className={styles.indicatorIcon} />\r\n </BaseMenu.CheckboxItemIndicator>\r\n </span>\r\n {children}\r\n </BaseMenu.CheckboxItem>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar radio item.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarRadioItem>Content</MenubarRadioItem>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarRadioItem(props: Readonly<MenubarRadioItem.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.RadioItem\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.item, styles.indicatorItem, className)}, {}),\r\n })}>\r\n <span className={styles.indicatorSlot}>\r\n <BaseMenu.RadioItemIndicator>\r\n <Circle className={styles.radioIndicatorIcon} />\r\n </BaseMenu.RadioItemIndicator>\r\n </span>\r\n {children}\r\n </BaseMenu.RadioItem>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar label.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarLabel>Content</MenubarLabel>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarLabel(props: Readonly<MenubarLabel.Props>): React.ReactElement {\r\n const {className, children, inset = false, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.GroupLabel\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.label, inset && styles.inset, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMenu.GroupLabel>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar separator.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarSeparator>Content</MenubarSeparator>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarSeparator(props: Readonly<MenubarSeparator.Props>): React.ReactElement {\r\n const {className, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMenu.Separator\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.separator, className)}, {}),\r\n })}\r\n />\r\n );\r\n}\r\n\r\n/**\r\n * Renders the menubar shortcut.\r\n *\r\n * @remarks\r\n * - Renders a `<span>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/menubar | Base UI Menubar}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <MenubarShortcut>Content</MenubarShortcut>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/menubar | Base UI Documentation}\r\n */\r\nfunction MenubarShortcut(props: Readonly<MenubarShortcut.Props>): React.ReactElement {\r\n // eslint-disable-next-line sonarjs/deprecation -- backward-compatible asChild API\r\n const {asChild = false, children, className, render, ...otherProps} = props;\r\n const renderProp = asChild && React.isValidElement(children) ? children : render;\r\n\r\n return useRender({\r\n defaultTagName: \"span\",\r\n render: renderProp as never,\r\n props: mergeProps({className: cn(styles.shortcut, className)}, otherProps, {\r\n children: renderProp ? undefined : children,\r\n }),\r\n });\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace Menubar {\r\n export type Props = Omit<React.ComponentPropsWithRef<typeof BaseMenubar>, \"className\"> & {className?: string};\r\n export type State = BaseMenubar.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarTrigger {\r\n export type Props = Omit<React.ComponentPropsWithRef<typeof BaseMenu.Trigger>, \"className\"> & {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n };\r\n export type State = BaseMenu.Trigger.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarSubTrigger {\r\n export type Props = MenubarSubTriggerProps;\r\n export type State = BaseMenu.SubmenuTrigger.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarContent {\r\n export type Props = MenubarContentProps;\r\n export type State = BaseMenu.Popup.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarSubContent {\r\n export type Props = MenubarContentProps;\r\n export type State = BaseMenu.Popup.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarItem {\r\n export type Props = MenubarItemProps;\r\n export type State = BaseMenu.Item.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarCheckboxItem {\r\n export type Props = MenubarCheckboxItemProps;\r\n export type State = BaseMenu.CheckboxItem.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarRadioItem {\r\n export type Props = MenubarRadioItemProps;\r\n export type State = BaseMenu.RadioItem.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarLabel {\r\n export type Props = MenubarLabelProps;\r\n export type State = BaseMenu.GroupLabel.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarSeparator {\r\n export type Props = MenubarSeparatorProps;\r\n export type State = BaseMenu.Separator.State;\r\n}\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MenubarShortcut {\r\n export type Props = MenubarShortcutProps;\r\n export type State = Record<string, never>;\r\n}\r\n\r\nMenubarMenu.displayName = \"MenubarMenu\";\r\nMenubarGroup.displayName = \"MenubarGroup\";\r\nMenubarPortal.displayName = \"MenubarPortal\";\r\nMenubarRadioGroup.displayName = \"MenubarRadioGroup\";\r\nMenubarSub.displayName = \"MenubarSub\";\r\nMenubar.displayName = \"Menubar\";\r\nMenubarTrigger.displayName = \"MenubarTrigger\";\r\nMenubarSubTrigger.displayName = \"MenubarSubTrigger\";\r\nMenubarSubContent.displayName = \"MenubarSubContent\";\r\nMenubarContent.displayName = \"MenubarContent\";\r\nMenubarItem.displayName = \"MenubarItem\";\r\nMenubarCheckboxItem.displayName = \"MenubarCheckboxItem\";\r\nMenubarRadioItem.displayName = \"MenubarRadioItem\";\r\nMenubarLabel.displayName = \"MenubarLabel\";\r\nMenubarSeparator.displayName = \"MenubarSeparator\";\r\nMenubarShortcut.displayName = \"MenubarShortcut\";\r\n\r\nexport {\r\n Menubar,\r\n MenubarCheckboxItem,\r\n MenubarContent,\r\n MenubarGroup,\r\n MenubarItem,\r\n MenubarLabel,\r\n MenubarMenu,\r\n MenubarPortal,\r\n MenubarRadioGroup,\r\n MenubarRadioItem,\r\n MenubarSeparator,\r\n MenubarShortcut,\r\n MenubarSub,\r\n MenubarSubContent,\r\n MenubarSubTrigger,\r\n MenubarTrigger,\r\n};\r\n"],"names":["MenubarMenu","BaseMenu","MenubarGroup","MenubarPortal","MenubarRadioGroup","MenubarSub","Menubar","props","className","children","render","otherProps","BaseMenubar","useRender","mergeProps","cn","styles","MenubarTrigger","React","ref","MenubarSubTrigger","inset","ChevronRight","MenubarSubContent","MenubarContent","alignOffset","sideOffset","MenubarItem","MenubarCheckboxItem","Check","MenubarRadioItem","Circle","MenubarLabel","MenubarSeparator","MenubarShortcut","asChild","renderProp","undefined"],"mappings":";;;;;;;;;;AA8GA,MAAMA,cAA6DC,KAAAA,IAAa;AAgBhF,MAAMC,eAAeD,KAAAA,KAAc;AAgBnC,MAAME,gBAAgBF,KAAAA,MAAe;AAgBrC,MAAMG,oBAAoBH,KAAAA,UAAmB;AAgB7C,MAAMI,aAAmEJ,KAAAA,WAAoB;AAiB7F,SAASK,gBAAQC,KAA8B;IAC7C,MAAM,EAACC,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGJ;IAErD,OAAO,WAAP,GACE,IAACK,SAAWA;QACT,GAAGD,UAAU;QACd,QAAQE,UAAU;YAChB,gBAAgB;YAChB,QAAQH;YACR,OAAOI,WAAW;gBAAC,WAAWC,GAAGC,eAAAA,IAAW,EAAER;YAAU,GAAG,CAAC;QAC9D;kBACCC;;AAGP;AAiBA,MAAMQ,iBAAiB,WAAHA,GAAGC,WACrB,CAACX,OAAuCY;IACtC,MAAM,EAACX,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGJ;IAErD,OAAO,WAAP,GACE,IAACN,KAAAA,OAAgB;QACf,KAAKkB;QACJ,GAAGR,UAAU;QACd,QAAQE,UAAU;YAChB,gBAAgB;YAChB,QAAQH;YACR,OAAOI,WAAW;gBAAC,WAAWC,GAAGC,eAAAA,OAAc,EAAER;YAAU,GAAG,CAAC;QACjE;kBACCC;;AAGP;AAkBF,SAASW,kBAAkBb,KAAwC;IACjE,MAAM,EAACC,SAAS,EAAEC,QAAQ,EAAEY,QAAQ,KAAK,EAAEX,MAAM,EAAE,GAAGC,YAAW,GAAGJ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F;AAiEAT,YAAY,WAAW,GAAG;AAC1BE,aAAa,WAAW,GAAG;AAC3BC,cAAc,WAAW,GAAG;AAC5BC,kBAAkB,WAAW,GAAG;AAChCC,WAAW,WAAW,GAAG;AACzBC,gBAAQ,WAAW,GAAG;AACtBW,eAAe,WAAW,GAAG;AAC7BG,kBAAkB,WAAW,GAAG;AAChCG,kBAAkB,WAAW,GAAG;AAChCC,eAAe,WAAW,GAAG;AAC7BG,YAAY,WAAW,GAAG;AAC1BC,oBAAoB,WAAW,GAAG;AAClCE,iBAAiB,WAAW,GAAG;AAC/BE,aAAa,WAAW,GAAG;AAC3BC,iBAAiB,WAAW,GAAG;AAC/BC,gBAAgB,WAAW,GAAG"}
@@ -1,9 +1,5 @@
1
1
  import { Meter as BaseMeter } from "@base-ui/react/meter";
2
2
  import * as React from "react";
3
- type MeterProps = React.ComponentPropsWithRef<typeof BaseMeter.Root>;
4
- type MeterTrackProps = React.ComponentPropsWithRef<typeof BaseMeter.Track>;
5
- type MeterIndicatorProps = React.ComponentPropsWithRef<typeof BaseMeter.Indicator>;
6
- type MeterLabelProps = React.ComponentPropsWithRef<typeof BaseMeter.Label>;
7
3
  /**
8
4
  * Displays a scalar measurement within a known range.
9
5
  *
@@ -23,10 +19,7 @@ type MeterLabelProps = React.ComponentPropsWithRef<typeof BaseMeter.Label>;
23
19
  *
24
20
  * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}
25
21
  */
26
- declare function Meter(props: Readonly<Meter.Props>): React.ReactElement;
27
- declare namespace Meter {
28
- var displayName: string;
29
- }
22
+ declare const Meter: React.ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").MeterRootProps, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
30
23
  /**
31
24
  * Renders the background track for a meter.
32
25
  *
@@ -41,10 +34,7 @@ declare namespace Meter {
41
34
  *
42
35
  * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}
43
36
  */
44
- declare function MeterTrack(props: Readonly<MeterTrack.Props>): React.ReactElement;
45
- declare namespace MeterTrack {
46
- var displayName: string;
47
- }
37
+ declare const MeterTrack: React.ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").MeterTrackProps, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
48
38
  /**
49
39
  * Renders the filled indicator that reflects the current meter value.
50
40
  *
@@ -59,10 +49,7 @@ declare namespace MeterTrack {
59
49
  *
60
50
  * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}
61
51
  */
62
- declare function MeterIndicator(props: Readonly<MeterIndicator.Props>): React.ReactElement;
63
- declare namespace MeterIndicator {
64
- var displayName: string;
65
- }
52
+ declare const MeterIndicator: React.ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").MeterIndicatorProps, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
66
53
  /**
67
54
  * Renders the accessible label associated with a meter.
68
55
  *
@@ -77,24 +64,21 @@ declare namespace MeterIndicator {
77
64
  *
78
65
  * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}
79
66
  */
80
- declare function MeterLabel(props: Readonly<MeterLabel.Props>): React.ReactElement;
81
- declare namespace MeterLabel {
82
- var displayName: string;
83
- }
67
+ declare const MeterLabel: React.ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").MeterLabelProps, "ref"> & React.RefAttributes<HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
84
68
  declare namespace Meter {
85
- type Props = MeterProps;
69
+ type Props = React.ComponentPropsWithRef<typeof BaseMeter.Root>;
86
70
  type State = BaseMeter.Root.State;
87
71
  }
88
72
  declare namespace MeterTrack {
89
- type Props = MeterTrackProps;
73
+ type Props = React.ComponentPropsWithRef<typeof BaseMeter.Track>;
90
74
  type State = BaseMeter.Track.State;
91
75
  }
92
76
  declare namespace MeterIndicator {
93
- type Props = MeterIndicatorProps;
77
+ type Props = React.ComponentPropsWithRef<typeof BaseMeter.Indicator>;
94
78
  type State = BaseMeter.Indicator.State;
95
79
  }
96
80
  declare namespace MeterLabel {
97
- type Props = MeterLabelProps;
81
+ type Props = React.ComponentPropsWithRef<typeof BaseMeter.Label>;
98
82
  type State = BaseMeter.Label.State;
99
83
  }
100
84
  export { Meter, MeterIndicator, MeterLabel, MeterTrack };
@@ -1 +1 @@
1
- {"version":3,"file":"meter.d.ts","sourceRoot":"","sources":["../../../src/components/ui/meter.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAC,KAAK,IAAI,SAAS,EAAC,MAAM,sBAAsB,CAAC;AAExD,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,KAAK,UAAU,GAAG,KAAK,CAAC,qBAAqB,CAAC,OAAO,SAAS,CAAC,IAAI,CAAC,CAAC;AACrE,KAAK,eAAe,GAAG,KAAK,CAAC,qBAAqB,CAAC,OAAO,SAAS,CAAC,KAAK,CAAC,CAAC;AAC3E,KAAK,mBAAmB,GAAG,KAAK,CAAC,qBAAqB,CAAC,OAAO,SAAS,CAAC,SAAS,CAAC,CAAC;AACnF,KAAK,eAAe,GAAG,KAAK,CAAC,qBAAqB,CAAC,OAAO,SAAS,CAAC,KAAK,CAAC,CAAC;AAE3E;;;;;;;;;;;;;;;;;;GAkBG;AACH,iBAAS,KAAK,CAAC,KAAK,EAAE,QAAQ,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC,YAAY,CAc/D;kBAdQ,KAAK;;;AAgBd;;;;;;;;;;;;;GAaG;AACH,iBAAS,UAAU,CAAC,KAAK,EAAE,QAAQ,CAAC,UAAU,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC,YAAY,CAczE;kBAdQ,UAAU;;;AAgBnB;;;;;;;;;;;;;GAaG;AACH,iBAAS,cAAc,CAAC,KAAK,EAAE,QAAQ,CAAC,cAAc,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC,YAAY,CAcjF;kBAdQ,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GAAG,KAAK,CAAC,qBAAqB,CAAC,OAAO,SAAS,CAAC,IAAI,CAAC,CAAC;IACvE,KAAY,KAAK,GAAG,SAAS,CAAC,IAAI,CAAC,KAAK,CAAC;CAC1C;AAGD,kBAAU,UAAU,CAAC;IACnB,KAAY,KAAK,GAAG,KAAK,CAAC,qBAAqB,CAAC,OAAO,SAAS,CAAC,KAAK,CAAC,CAAC;IACxE,KAAY,KAAK,GAAG,SAAS,CAAC,KAAK,CAAC,KAAK,CAAC;CAC3C;AAGD,kBAAU,cAAc,CAAC;IACvB,KAAY,KAAK,GAAG,KAAK,CAAC,qBAAqB,CAAC,OAAO,SAAS,CAAC,SAAS,CAAC,CAAC;IAC5E,KAAY,KAAK,GAAG,SAAS,CAAC,SAAS,CAAC,KAAK,CAAC;CAC/C;AAGD,kBAAU,UAAU,CAAC;IACnB,KAAY,KAAK,GAAG,KAAK,CAAC,qBAAqB,CAAC,OAAO,SAAS,CAAC,KAAK,CAAC,CAAC;IACxE,KAAY,KAAK,GAAG,SAAS,CAAC,KAAK,CAAC,KAAK,CAAC;CAC3C;AAOD,OAAO,EAAC,KAAK,EAAE,cAAc,EAAE,UAAU,EAAE,UAAU,EAAC,CAAC"}
@@ -1,15 +1,16 @@
1
1
  "use client";
2
2
  import { jsx } from "react/jsx-runtime";
3
3
  import { mergeProps } from "@base-ui/react/merge-props";
4
- import { Meter } from "@base-ui/react/meter";
4
+ import { Meter as meter_Meter } from "@base-ui/react/meter";
5
5
  import { useRender } from "@base-ui/react/use-render";
6
- import "react";
6
+ import { forwardRef } from "react";
7
7
  import { cn } from "../../lib/utilities.js";
8
8
  import meter_module from "./meter.module.js";
9
- function meter_Meter(props) {
9
+ const ui_meter_Meter = /*#__PURE__*/ forwardRef(function(props, forwardedRef) {
10
10
  const { className, children, render, ...otherProps } = props;
11
- return /*#__PURE__*/ jsx(Meter.Root, {
11
+ return /*#__PURE__*/ jsx(meter_Meter.Root, {
12
12
  ...otherProps,
13
+ ref: forwardedRef,
13
14
  render: useRender({
14
15
  defaultTagName: "div",
15
16
  render: render,
@@ -19,11 +20,12 @@ function meter_Meter(props) {
19
20
  }),
20
21
  children: children
21
22
  });
22
- }
23
- function MeterTrack(props) {
23
+ });
24
+ const meter_MeterTrack = /*#__PURE__*/ forwardRef(function(props, forwardedRef) {
24
25
  const { className, children, render, ...otherProps } = props;
25
- return /*#__PURE__*/ jsx(Meter.Track, {
26
+ return /*#__PURE__*/ jsx(meter_Meter.Track, {
26
27
  ...otherProps,
28
+ ref: forwardedRef,
27
29
  render: useRender({
28
30
  defaultTagName: "div",
29
31
  render: render,
@@ -33,11 +35,12 @@ function MeterTrack(props) {
33
35
  }),
34
36
  children: children
35
37
  });
36
- }
37
- function MeterIndicator(props) {
38
+ });
39
+ const meter_MeterIndicator = /*#__PURE__*/ forwardRef(function(props, forwardedRef) {
38
40
  const { className, children, render, ...otherProps } = props;
39
- return /*#__PURE__*/ jsx(Meter.Indicator, {
41
+ return /*#__PURE__*/ jsx(meter_Meter.Indicator, {
40
42
  ...otherProps,
43
+ ref: forwardedRef,
41
44
  render: useRender({
42
45
  defaultTagName: "div",
43
46
  render: render,
@@ -47,11 +50,12 @@ function MeterIndicator(props) {
47
50
  }),
48
51
  children: children
49
52
  });
50
- }
51
- function MeterLabel(props) {
53
+ });
54
+ const meter_MeterLabel = /*#__PURE__*/ forwardRef(function(props, forwardedRef) {
52
55
  const { className, children, render, ...otherProps } = props;
53
- return /*#__PURE__*/ jsx(Meter.Label, {
56
+ return /*#__PURE__*/ jsx(meter_Meter.Label, {
54
57
  ...otherProps,
58
+ ref: forwardedRef,
55
59
  render: useRender({
56
60
  defaultTagName: "span",
57
61
  render: render,
@@ -61,11 +65,11 @@ function MeterLabel(props) {
61
65
  }),
62
66
  children: children
63
67
  });
64
- }
65
- meter_Meter.displayName = "Meter";
66
- MeterTrack.displayName = "MeterTrack";
67
- MeterIndicator.displayName = "MeterIndicator";
68
- MeterLabel.displayName = "MeterLabel";
69
- export { MeterIndicator, MeterLabel, MeterTrack, meter_Meter as Meter };
68
+ });
69
+ ui_meter_Meter.displayName = "Meter";
70
+ meter_MeterTrack.displayName = "MeterTrack";
71
+ meter_MeterIndicator.displayName = "MeterIndicator";
72
+ meter_MeterLabel.displayName = "MeterLabel";
73
+ export { meter_MeterIndicator as MeterIndicator, meter_MeterLabel as MeterLabel, meter_MeterTrack as MeterTrack, ui_meter_Meter as Meter };
70
74
 
71
75
  //# sourceMappingURL=meter.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"components/ui/meter.js","sources":["../../../src/components/ui/meter.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {mergeProps} from \"@base-ui/react/merge-props\";\r\nimport {Meter as BaseMeter} from \"@base-ui/react/meter\";\r\nimport {useRender} from \"@base-ui/react/use-render\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\nimport styles from \"./meter.module.css\";\r\n\r\ntype MeterProps = React.ComponentPropsWithRef<typeof BaseMeter.Root>;\r\ntype MeterTrackProps = React.ComponentPropsWithRef<typeof BaseMeter.Track>;\r\ntype MeterIndicatorProps = React.ComponentPropsWithRef<typeof BaseMeter.Indicator>;\r\ntype MeterLabelProps = React.ComponentPropsWithRef<typeof BaseMeter.Label>;\r\n\r\n/**\r\n * Displays a scalar measurement within a known range.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on Base UI Meter primitives\r\n * - Intended for values such as storage usage, health, or completion\r\n *\r\n * @example\r\n * ```tsx\r\n * <Meter value={72}>\r\n * <MeterTrack>\r\n * <MeterIndicator />\r\n * </MeterTrack>\r\n * </Meter>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}\r\n */\r\nfunction Meter(props: Readonly<Meter.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMeter.Root\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.root, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMeter.Root>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the background track for a meter.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on Base UI Meter track primitives\r\n *\r\n * @example\r\n * ```tsx\r\n * <MeterTrack />\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}\r\n */\r\nfunction MeterTrack(props: Readonly<MeterTrack.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMeter.Track\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.track, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMeter.Track>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the filled indicator that reflects the current meter value.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on Base UI Meter indicator primitives\r\n *\r\n * @example\r\n * ```tsx\r\n * <MeterIndicator />\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}\r\n */\r\nfunction MeterIndicator(props: Readonly<MeterIndicator.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMeter.Indicator\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.indicator, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMeter.Indicator>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the accessible label associated with a meter.\r\n *\r\n * @remarks\r\n * - Renders a `<span>` element by default\r\n * - Built on Base UI Meter label primitives\r\n *\r\n * @example\r\n * ```tsx\r\n * <MeterLabel>Storage used</MeterLabel>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}\r\n */\r\nfunction MeterLabel(props: Readonly<MeterLabel.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMeter.Label\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"span\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.label, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMeter.Label>\r\n );\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace Meter {\r\n export type Props = MeterProps;\r\n export type State = BaseMeter.Root.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MeterTrack {\r\n export type Props = MeterTrackProps;\r\n export type State = BaseMeter.Track.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MeterIndicator {\r\n export type Props = MeterIndicatorProps;\r\n export type State = BaseMeter.Indicator.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MeterLabel {\r\n export type Props = MeterLabelProps;\r\n export type State = BaseMeter.Label.State;\r\n}\r\n\r\nMeter.displayName = \"Meter\";\r\nMeterTrack.displayName = \"MeterTrack\";\r\nMeterIndicator.displayName = \"MeterIndicator\";\r\nMeterLabel.displayName = \"MeterLabel\";\r\n\r\nexport {Meter, MeterIndicator, MeterLabel, MeterTrack};\r\n"],"names":["Meter","props","className","children","render","otherProps","BaseMeter","useRender","mergeProps","cn","styles","MeterTrack","MeterIndicator","MeterLabel"],"mappings":";;;;;;;;AAkCA,SAASA,YAAMC,KAA4B;IACzC,MAAM,EAACC,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGJ;IAErD,OAAO,WAAP,GACE,IAACK,MAAAA,IAAc;QACZ,GAAGD,UAAU;QACd,QAAQE,UAAU;YAChB,gBAAgB;YAChB,QAAQH;YACR,OAAOI,WAAW;gBAAC,WAAWC,GAAGC,aAAAA,IAAW,EAAER;YAAU,GAAG,CAAC;QAC9D;kBACCC;;AAGP;AAgBA,SAASQ,WAAWV,KAAiC;IACnD,MAAM,EAACC,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGJ;IAErD,OAAO,WAAP,GACE,IAACK,MAAAA,KAAe;QACb,GAAGD,UAAU;QACd,QAAQE,UAAU;YAChB,gBAAgB;YAChB,QAAQH;YACR,OAAOI,WAAW;gBAAC,WAAWC,GAAGC,aAAAA,KAAY,EAAER;YAAU,GAAG,CAAC;QAC/D;kBACCC;;AAGP;AAgBA,SAASS,eAAeX,KAAqC;IAC3D,MAAM,EAACC,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGJ;IAErD,OAAO,WAAP,GACE,IAACK,MAAAA,SAAmB;QACjB,GAAGD,UAAU;QACd,QAAQE,UAAU;YAChB,gBAAgB;YAChB,QAAQH;YACR,OAAOI,WAAW;gBAAC,WAAWC,GAAGC,aAAAA,SAAgB,EAAER;YAAU,GAAG,CAAC;QACnE;kBACCC;;AAGP;AAgBA,SAASU,WAAWZ,KAAiC;IACnD,MAAM,EAACC,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGJ;IAErD,OAAO,WAAP,GACE,IAACK,MAAAA,KAAe;QACb,GAAGD,UAAU;QACd,QAAQE,UAAU;YAChB,gBAAgB;YAChB,QAAQH;YACR,OAAOI,WAAW;gBAAC,WAAWC,GAAGC,aAAAA,KAAY,EAAER;YAAU,GAAG,CAAC;QAC/D;kBACCC;;AAGP;AA0BAH,YAAM,WAAW,GAAG;AACpBW,WAAW,WAAW,GAAG;AACzBC,eAAe,WAAW,GAAG;AAC7BC,WAAW,WAAW,GAAG"}
1
+ {"version":3,"file":"components/ui/meter.js","sources":["../../../src/components/ui/meter.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {mergeProps} from \"@base-ui/react/merge-props\";\r\nimport {Meter as BaseMeter} from \"@base-ui/react/meter\";\r\nimport {useRender} from \"@base-ui/react/use-render\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\nimport styles from \"./meter.module.css\";\r\n\r\n/**\r\n * Displays a scalar measurement within a known range.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on Base UI Meter primitives\r\n * - Intended for values such as storage usage, health, or completion\r\n *\r\n * @example\r\n * ```tsx\r\n * <Meter value={72}>\r\n * <MeterTrack>\r\n * <MeterIndicator />\r\n * </MeterTrack>\r\n * </Meter>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}\r\n */\r\nconst Meter = React.forwardRef<HTMLDivElement, Meter.Props>(function Meter(props, forwardedRef) {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMeter.Root\r\n {...otherProps}\r\n ref={forwardedRef}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.root, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMeter.Root>\r\n );\r\n});\r\n\r\n/**\r\n * Renders the background track for a meter.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on Base UI Meter track primitives\r\n *\r\n * @example\r\n * ```tsx\r\n * <MeterTrack />\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}\r\n */\r\nconst MeterTrack = React.forwardRef<HTMLDivElement, MeterTrack.Props>(function MeterTrack(props, forwardedRef) {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMeter.Track\r\n {...otherProps}\r\n ref={forwardedRef}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.track, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMeter.Track>\r\n );\r\n});\r\n\r\n/**\r\n * Renders the filled indicator that reflects the current meter value.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on Base UI Meter indicator primitives\r\n *\r\n * @example\r\n * ```tsx\r\n * <MeterIndicator />\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}\r\n */\r\nconst MeterIndicator = React.forwardRef<HTMLDivElement, MeterIndicator.Props>(function MeterIndicator(props, forwardedRef) {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMeter.Indicator\r\n {...otherProps}\r\n ref={forwardedRef}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.indicator, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMeter.Indicator>\r\n );\r\n});\r\n\r\n/**\r\n * Renders the accessible label associated with a meter.\r\n *\r\n * @remarks\r\n * - Renders a `<span>` element by default\r\n * - Built on Base UI Meter label primitives\r\n *\r\n * @example\r\n * ```tsx\r\n * <MeterLabel>Storage used</MeterLabel>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/meter | Base UI Meter Docs}\r\n */\r\nconst MeterLabel = React.forwardRef<HTMLSpanElement, MeterLabel.Props>(function MeterLabel(props, forwardedRef) {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseMeter.Label\r\n {...otherProps}\r\n ref={forwardedRef}\r\n render={useRender({\r\n defaultTagName: \"span\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.label, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseMeter.Label>\r\n );\r\n});\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace Meter {\r\n export type Props = React.ComponentPropsWithRef<typeof BaseMeter.Root>;\r\n export type State = BaseMeter.Root.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MeterTrack {\r\n export type Props = React.ComponentPropsWithRef<typeof BaseMeter.Track>;\r\n export type State = BaseMeter.Track.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MeterIndicator {\r\n export type Props = React.ComponentPropsWithRef<typeof BaseMeter.Indicator>;\r\n export type State = BaseMeter.Indicator.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace MeterLabel {\r\n export type Props = React.ComponentPropsWithRef<typeof BaseMeter.Label>;\r\n export type State = BaseMeter.Label.State;\r\n}\r\n\r\nMeter.displayName = \"Meter\";\r\nMeterTrack.displayName = \"MeterTrack\";\r\nMeterIndicator.displayName = \"MeterIndicator\";\r\nMeterLabel.displayName = \"MeterLabel\";\r\n\r\nexport {Meter, MeterIndicator, MeterLabel, MeterTrack};\r\n"],"names":["Meter","React","props","forwardedRef","className","children","render","otherProps","BaseMeter","useRender","mergeProps","cn","styles","MeterTrack","MeterIndicator","MeterLabel"],"mappings":";;;;;;;;AA6BA,MAAMA,iBAAQ,WAAHA,GAAGC,WAA8C,SAAeC,KAAK,EAAEC,YAAY;IAC5F,MAAM,EAACC,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGL;IAErD,OAAO,WAAP,GACE,IAACM,YAAAA,IAAc;QACZ,GAAGD,UAAU;QACd,KAAKJ;QACL,QAAQM,UAAU;YAChB,gBAAgB;YAChB,QAAQH;YACR,OAAOI,WAAW;gBAAC,WAAWC,GAAGC,aAAAA,IAAW,EAAER;YAAU,GAAG,CAAC;QAC9D;kBACCC;;AAGP;AAgBA,MAAMQ,mBAAa,WAAHA,GAAGZ,WAAmD,SAAoBC,KAAK,EAAEC,YAAY;IAC3G,MAAM,EAACC,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGL;IAErD,OAAO,WAAP,GACE,IAACM,YAAAA,KAAe;QACb,GAAGD,UAAU;QACd,KAAKJ;QACL,QAAQM,UAAU;YAChB,gBAAgB;YAChB,QAAQH;YACR,OAAOI,WAAW;gBAAC,WAAWC,GAAGC,aAAAA,KAAY,EAAER;YAAU,GAAG,CAAC;QAC/D;kBACCC;;AAGP;AAgBA,MAAMS,uBAAiB,WAAHA,GAAGb,WAAuD,SAAwBC,KAAK,EAAEC,YAAY;IACvH,MAAM,EAACC,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGL;IAErD,OAAO,WAAP,GACE,IAACM,YAAAA,SAAmB;QACjB,GAAGD,UAAU;QACd,KAAKJ;QACL,QAAQM,UAAU;YAChB,gBAAgB;YAChB,QAAQH;YACR,OAAOI,WAAW;gBAAC,WAAWC,GAAGC,aAAAA,SAAgB,EAAER;YAAU,GAAG,CAAC;QACnE;kBACCC;;AAGP;AAgBA,MAAMU,mBAAa,WAAHA,GAAGd,WAAoD,SAAoBC,KAAK,EAAEC,YAAY;IAC5G,MAAM,EAACC,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGL;IAErD,OAAO,WAAP,GACE,IAACM,YAAAA,KAAe;QACb,GAAGD,UAAU;QACd,KAAKJ;QACL,QAAQM,UAAU;YAChB,gBAAgB;YAChB,QAAQH;YACR,OAAOI,WAAW;gBAAC,WAAWC,GAAGC,aAAAA,KAAY,EAAER;YAAU,GAAG,CAAC;QAC/D;kBACCC;;AAGP;AA0BAL,eAAM,WAAW,GAAG;AACpBa,iBAAW,WAAW,GAAG;AACzBC,qBAAe,WAAW,GAAG;AAC7BC,iBAAW,WAAW,GAAG"}
@@ -132,10 +132,7 @@ declare const NavigationMenuItem: React.ForwardRefExoticComponent<Omit<import("@
132
132
  *
133
133
  * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}
134
134
  */
135
- declare function NavigationMenuTrigger(props: Readonly<NavigationMenuTrigger.Props>): React.ReactElement;
136
- declare namespace NavigationMenuTrigger {
137
- var displayName: string;
138
- }
135
+ declare const NavigationMenuTrigger: React.ForwardRefExoticComponent<Omit<NavigationMenuTriggerProps, "ref"> & React.RefAttributes<HTMLButtonElement>>;
139
136
  /**
140
137
  * Renders the navigation menu content.
141
138
  *
@@ -151,10 +148,7 @@ declare namespace NavigationMenuTrigger {
151
148
  *
152
149
  * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}
153
150
  */
154
- declare function NavigationMenuContent(props: Readonly<NavigationMenuContent.Props>): React.ReactElement;
155
- declare namespace NavigationMenuContent {
156
- var displayName: string;
157
- }
151
+ declare const NavigationMenuContent: React.ForwardRefExoticComponent<Omit<NavigationMenuContentProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
158
152
  /**
159
153
  * Renders the navigation menu link.
160
154
  *
@@ -170,10 +164,7 @@ declare namespace NavigationMenuContent {
170
164
  *
171
165
  * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}
172
166
  */
173
- declare function NavigationMenuLink(props: Readonly<NavigationMenuLink.Props>): React.ReactElement;
174
- declare namespace NavigationMenuLink {
175
- var displayName: string;
176
- }
167
+ declare const NavigationMenuLink: React.ForwardRefExoticComponent<Omit<NavigationMenuLinkProps, "ref"> & React.RefAttributes<HTMLAnchorElement>>;
177
168
  /**
178
169
  * Renders the navigation menu viewport.
179
170
  *
@@ -1 +1 @@
1
- {"version":3,"file":"navigation-menu.d.ts","sourceRoot":"","sources":["../../../src/components/ui/navigation-menu.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAC,cAAc,IAAI,kBAAkB,EAAC,MAAM,gCAAgC,CAAC;AACpF,OAAO,EAAC,SAAS,EAAC,MAAM,2BAA2B,CAAC;AAEpD,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,2EAA2E;AAC3E,wBAAgB,0BAA0B,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,CAErE;AAED,UAAU,mBAAoB,SAAQ,IAAI,CAAC,KAAK,CAAC,qBAAqB,CAAC,OAAO,kBAAkB,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC;IAClH;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AA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,GAAG,kBAAkB,CAAC,IAAI,CAAC,KAAK,CAAC;CACnD;AAGD,kBAAU,qBAAqB,CAAC;IAC9B,KAAY,KAAK,GAAG,0BAA0B,CAAC;IAC/C,KAAY,KAAK,GAAG,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;CACtD;AAGD,kBAAU,qBAAqB,CAAC;IAC9B,KAAY,KAAK,GAAG,0BAA0B,CAAC;IAC/C,KAAY,KAAK,GAAG,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;CACtD;AAGD,kBAAU,kBAAkB,CAAC;IAC3B,KAAY,KAAK,GAAG,uBAAuB,CAAC;IAC5C,KAAY,KAAK,GAAG,kBAAkB,CAAC,IAAI,CAAC,KAAK,CAAC;CACnD;AAGD,kBAAU,sBAAsB,CAAC;IAC/B,KAAY,KAAK,GAAG,2BAA2B,CAAC;IAChD,KAAY,KAAK,GAAG,kBAAkB,CAAC,QAAQ,CAAC,KAAK,CAAC;CACvD;AAGD,kBAAU,uBAAuB,CAAC;IAChC,KAAY,KAAK,GAAG,4BAA4B,CAAC;IACjD,KAAY,KAAK,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;CAC3C;AAWD,OAAO,EACL,cAAc,EACd,qBAAqB,EACrB,uBAAuB,EACvB,kBAAkB,EAClB,kBAAkB,EAClB,kBAAkB,EAClB,qBAAqB,EACrB,sBAAsB,GACvB,CAAC"}
@@ -4,7 +4,7 @@ import { mergeProps } from "@base-ui/react/merge-props";
4
4
  import { NavigationMenu } from "@base-ui/react/navigation-menu";
5
5
  import { useRender } from "@base-ui/react/use-render";
6
6
  import { ChevronDown } from "lucide-react";
7
- import { isValidElement } from "react";
7
+ import { forwardRef, isValidElement } from "react";
8
8
  import { cn } from "../../lib/utilities.js";
9
9
  import navigation_menu_module from "./navigation-menu.module.js";
10
10
  function navigationMenuTriggerStyle(className) {
@@ -42,10 +42,11 @@ function NavigationMenuList(props) {
42
42
  });
43
43
  }
44
44
  const NavigationMenuItem = NavigationMenu.Item;
45
- function NavigationMenuTrigger(props) {
45
+ const navigation_menu_NavigationMenuTrigger = /*#__PURE__*/ forwardRef(function(props, forwardedRef) {
46
46
  const { className, children, render, ...otherProps } = props;
47
47
  return /*#__PURE__*/ jsxs(NavigationMenu.Trigger, {
48
48
  ...otherProps,
49
+ ref: forwardedRef,
49
50
  render: useRender({
50
51
  defaultTagName: "button",
51
52
  render: render,
@@ -60,11 +61,12 @@ function NavigationMenuTrigger(props) {
60
61
  })
61
62
  ]
62
63
  });
63
- }
64
- function NavigationMenuContent(props) {
64
+ });
65
+ const navigation_menu_NavigationMenuContent = /*#__PURE__*/ forwardRef(function(props, forwardedRef) {
65
66
  const { className, children, render, ...otherProps } = props;
66
67
  return /*#__PURE__*/ jsx(NavigationMenu.Content, {
67
68
  ...otherProps,
69
+ ref: forwardedRef,
68
70
  render: useRender({
69
71
  defaultTagName: "div",
70
72
  render: render,
@@ -74,11 +76,12 @@ function NavigationMenuContent(props) {
74
76
  }),
75
77
  children: children
76
78
  });
77
- }
78
- function NavigationMenuLink(props) {
79
+ });
80
+ const navigation_menu_NavigationMenuLink = /*#__PURE__*/ forwardRef(function(props, forwardedRef) {
79
81
  const { className, children, render, ...otherProps } = props;
80
82
  return /*#__PURE__*/ jsx(NavigationMenu.Link, {
81
83
  ...otherProps,
84
+ ref: forwardedRef,
82
85
  render: useRender({
83
86
  defaultTagName: "a",
84
87
  render: render,
@@ -88,7 +91,7 @@ function NavigationMenuLink(props) {
88
91
  }),
89
92
  children: children
90
93
  });
91
- }
94
+ });
92
95
  function NavigationMenuViewport(props) {
93
96
  const { className, children, render, ...otherProps } = props;
94
97
  return /*#__PURE__*/ jsx("div", {
@@ -142,11 +145,11 @@ function NavigationMenuIndicator(props) {
142
145
  navigation_menu_NavigationMenu.displayName = "NavigationMenu";
143
146
  NavigationMenuList.displayName = "NavigationMenuList";
144
147
  NavigationMenuItem.displayName = "NavigationMenuItem";
145
- NavigationMenuTrigger.displayName = "NavigationMenuTrigger";
146
- NavigationMenuContent.displayName = "NavigationMenuContent";
147
- NavigationMenuLink.displayName = "NavigationMenuLink";
148
+ navigation_menu_NavigationMenuTrigger.displayName = "NavigationMenuTrigger";
149
+ navigation_menu_NavigationMenuContent.displayName = "NavigationMenuContent";
150
+ navigation_menu_NavigationMenuLink.displayName = "NavigationMenuLink";
148
151
  NavigationMenuViewport.displayName = "NavigationMenuViewport";
149
152
  NavigationMenuIndicator.displayName = "NavigationMenuIndicator";
150
- export { NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, navigationMenuTriggerStyle, navigation_menu_NavigationMenu as NavigationMenu };
153
+ export { NavigationMenuIndicator, NavigationMenuItem, NavigationMenuList, NavigationMenuViewport, navigationMenuTriggerStyle, navigation_menu_NavigationMenu as NavigationMenu, navigation_menu_NavigationMenuContent as NavigationMenuContent, navigation_menu_NavigationMenuLink as NavigationMenuLink, navigation_menu_NavigationMenuTrigger as NavigationMenuTrigger };
151
154
 
152
155
  //# sourceMappingURL=navigation-menu.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"components/ui/navigation-menu.js","sources":["../../../src/components/ui/navigation-menu.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {mergeProps} from \"@base-ui/react/merge-props\";\r\nimport {NavigationMenu as BaseNavigationMenu} from \"@base-ui/react/navigation-menu\";\r\nimport {useRender} from \"@base-ui/react/use-render\";\r\nimport {ChevronDown} from \"lucide-react\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\nimport styles from \"./navigation-menu.module.css\";\r\n\r\n/** Returns the CSS classes used by the navigation menu trigger wrapper. */\r\nexport function navigationMenuTriggerStyle(className?: string): string {\r\n return cn(styles.trigger, className);\r\n}\r\n\r\ninterface NavigationMenuProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.Root>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuListProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.List>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuTriggerProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.Trigger>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuContentProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.Content>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuLinkProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.Link>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuViewportProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.Viewport>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuIndicatorProps extends React.ComponentPropsWithRef<\"div\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n /**\r\n * Overrides the default rendered element while preserving component behavior.\r\n * @default undefined\r\n */\r\n render?: useRender.RenderProp<Record<string, never>>;\r\n /**\r\n * Enables child element composition instead of rendering the default wrapper.\r\n * @default false\r\n * @deprecated Prefer Base UI's `render` prop.\r\n */\r\n asChild?: boolean;\r\n}\r\n\r\n/**\r\n * Coordinates navigation menu state and accessibility behavior.\r\n *\r\n * @remarks\r\n * - Renders a `<nav>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenu>Content</NavigationMenu>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenu(props: Readonly<NavigationMenu.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseNavigationMenu.Root\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"nav\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.root, className)}, {}),\r\n })}>\r\n {children}\r\n <NavigationMenuViewport />\r\n </BaseNavigationMenu.Root>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the navigation menu list.\r\n *\r\n * @remarks\r\n * - Renders a `<ul>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuList>Content</NavigationMenuList>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenuList(props: Readonly<NavigationMenuList.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseNavigationMenu.List\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"ul\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.list, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseNavigationMenu.List>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the navigation menu item.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuItem>Content</NavigationMenuItem>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nconst NavigationMenuItem = BaseNavigationMenu.Item;\r\n\r\n/**\r\n * Renders the navigation menu trigger.\r\n *\r\n * @remarks\r\n * - Renders a `<button>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuTrigger>Content</NavigationMenuTrigger>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenuTrigger(props: Readonly<NavigationMenuTrigger.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseNavigationMenu.Trigger\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"button\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.trigger, className)}, {}),\r\n })}>\r\n {children}\r\n <ChevronDown className={styles.triggerIcon} />\r\n </BaseNavigationMenu.Trigger>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the navigation menu content.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuContent>Content</NavigationMenuContent>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenuContent(props: Readonly<NavigationMenuContent.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseNavigationMenu.Content\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.content, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseNavigationMenu.Content>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the navigation menu link.\r\n *\r\n * @remarks\r\n * - Renders a `<a>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuLink>Content</NavigationMenuLink>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenuLink(props: Readonly<NavigationMenuLink.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseNavigationMenu.Link\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"a\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.link, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseNavigationMenu.Link>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the navigation menu viewport.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuViewport>Content</NavigationMenuViewport>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenuViewport(props: Readonly<NavigationMenuViewport.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <div className={styles.viewportWrapper}>\r\n <BaseNavigationMenu.Portal>\r\n <BaseNavigationMenu.Positioner\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n props: mergeProps({className: styles.positioner}, {}),\r\n })}>\r\n <BaseNavigationMenu.Popup\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n props: mergeProps({className: styles.popup}, {}),\r\n })}>\r\n <BaseNavigationMenu.Viewport\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.viewport, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseNavigationMenu.Viewport>\r\n </BaseNavigationMenu.Popup>\r\n </BaseNavigationMenu.Positioner>\r\n </BaseNavigationMenu.Portal>\r\n </div>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the navigation menu indicator.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuIndicator>Content</NavigationMenuIndicator>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenuIndicator(props: Readonly<NavigationMenuIndicator.Props>): React.ReactElement {\r\n const {asChild = false, children, className, render, ...otherProps} = props;\r\n const renderProp = asChild && React.isValidElement(children) ? children : render;\r\n\r\n return useRender({\r\n defaultTagName: \"div\",\r\n render: renderProp as never,\r\n props: mergeProps({className: cn(styles.indicator, className)}, otherProps, {\r\n children: renderProp ? undefined : (children ?? <div className={styles.indicatorInner} />),\r\n }),\r\n });\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenu {\r\n export type Props = NavigationMenuProps;\r\n export type State = BaseNavigationMenu.Root.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuList {\r\n export type Props = NavigationMenuListProps;\r\n export type State = BaseNavigationMenu.List.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuTrigger {\r\n export type Props = NavigationMenuTriggerProps;\r\n export type State = BaseNavigationMenu.Trigger.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuContent {\r\n export type Props = NavigationMenuContentProps;\r\n export type State = BaseNavigationMenu.Content.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuLink {\r\n export type Props = NavigationMenuLinkProps;\r\n export type State = BaseNavigationMenu.Link.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuViewport {\r\n export type Props = NavigationMenuViewportProps;\r\n export type State = BaseNavigationMenu.Viewport.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuIndicator {\r\n export type Props = NavigationMenuIndicatorProps;\r\n export type State = Record<string, never>;\r\n}\r\n\r\nNavigationMenu.displayName = \"NavigationMenu\";\r\nNavigationMenuList.displayName = \"NavigationMenuList\";\r\nNavigationMenuItem.displayName = \"NavigationMenuItem\";\r\nNavigationMenuTrigger.displayName = \"NavigationMenuTrigger\";\r\nNavigationMenuContent.displayName = \"NavigationMenuContent\";\r\nNavigationMenuLink.displayName = \"NavigationMenuLink\";\r\nNavigationMenuViewport.displayName = \"NavigationMenuViewport\";\r\nNavigationMenuIndicator.displayName = \"NavigationMenuIndicator\";\r\n\r\nexport {\r\n NavigationMenu,\r\n NavigationMenuContent,\r\n NavigationMenuIndicator,\r\n NavigationMenuItem,\r\n NavigationMenuLink,\r\n NavigationMenuList,\r\n NavigationMenuTrigger,\r\n NavigationMenuViewport,\r\n};\r\n"],"names":["navigationMenuTriggerStyle","className","cn","styles","NavigationMenu","props","children","render","otherProps","BaseNavigationMenu","useRender","mergeProps","NavigationMenuViewport","NavigationMenuList","NavigationMenuItem","NavigationMenuTrigger","ChevronDown","NavigationMenuContent","NavigationMenuLink","NavigationMenuIndicator","asChild","renderProp","React","undefined"],"mappings":";;;;;;;;;AAYO,SAASA,2BAA2BC,SAAkB;IAC3D,OAAOC,GAAGC,uBAAAA,OAAc,EAAEF;AAC5B;AAoFA,SAASG,+BAAeC,KAAqC;IAC3D,MAAM,EAACJ,SAAS,EAAEK,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGH;IAErD,OAAO,WAAP,GACE,KAACI,e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E,OAAOG,UAAU;QACf,gBAAgB;QAChB,QAAQW;QACR,OAAOV,WAAW;YAAC,WAAWT,GAAGC,uBAAAA,SAAgB,EAAEF;QAAU,GAAGO,YAAY;YAC1E,UAAUa,aAAaE,SAAajB,YAAY,WAAZA,GAAY,IAAC;gBAAI,WAAWH,uBAAAA,cAAqB;;QACvF;IACF;AACF;AA4CAC,+BAAe,WAAW,GAAG;AAC7BS,mBAAmB,WAAW,GAAG;AACjCC,mBAAmB,WAAW,GAAG;AACjCC,sBAAsB,WAAW,GAAG;AACpCE,sBAAsB,WAAW,GAAG;AACpCC,mBAAmB,WAAW,GAAG;AACjCN,uBAAuB,WAAW,GAAG;AACrCO,wBAAwB,WAAW,GAAG"}
1
+ {"version":3,"file":"components/ui/navigation-menu.js","sources":["../../../src/components/ui/navigation-menu.tsx"],"sourcesContent":["\"use client\";\r\n\r\nimport {mergeProps} from \"@base-ui/react/merge-props\";\r\nimport {NavigationMenu as BaseNavigationMenu} from \"@base-ui/react/navigation-menu\";\r\nimport {useRender} from \"@base-ui/react/use-render\";\r\nimport {ChevronDown} from \"lucide-react\";\r\nimport * as React from \"react\";\r\n\r\nimport {cn} from \"@/lib/utilities\";\r\nimport styles from \"./navigation-menu.module.css\";\r\n\r\n/** Returns the CSS classes used by the navigation menu trigger wrapper. */\r\nexport function navigationMenuTriggerStyle(className?: string): string {\r\n return cn(styles.trigger, className);\r\n}\r\n\r\ninterface NavigationMenuProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.Root>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuListProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.List>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuTriggerProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.Trigger>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuContentProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.Content>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuLinkProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.Link>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuViewportProps extends Omit<React.ComponentPropsWithRef<typeof BaseNavigationMenu.Viewport>, \"className\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n}\r\n\r\ninterface NavigationMenuIndicatorProps extends React.ComponentPropsWithRef<\"div\"> {\r\n /**\r\n * Applies additional CSS classes to the component root element.\r\n * @default undefined\r\n */\r\n className?: string;\r\n /**\r\n * Overrides the default rendered element while preserving component behavior.\r\n * @default undefined\r\n */\r\n render?: useRender.RenderProp<Record<string, never>>;\r\n /**\r\n * Enables child element composition instead of rendering the default wrapper.\r\n * @default false\r\n * @deprecated Prefer Base UI's `render` prop.\r\n */\r\n asChild?: boolean;\r\n}\r\n\r\n/**\r\n * Coordinates navigation menu state and accessibility behavior.\r\n *\r\n * @remarks\r\n * - Renders a `<nav>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenu>Content</NavigationMenu>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenu(props: Readonly<NavigationMenu.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseNavigationMenu.Root\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"nav\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.root, className)}, {}),\r\n })}>\r\n {children}\r\n <NavigationMenuViewport />\r\n </BaseNavigationMenu.Root>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the navigation menu list.\r\n *\r\n * @remarks\r\n * - Renders a `<ul>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuList>Content</NavigationMenuList>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenuList(props: Readonly<NavigationMenuList.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseNavigationMenu.List\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"ul\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.list, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseNavigationMenu.List>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the navigation menu item.\r\n *\r\n * @remarks\r\n * - Delegates structure and state to the underlying Base UI primitive\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Preserves the underlying primitive API for advanced composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuItem>Content</NavigationMenuItem>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nconst NavigationMenuItem = BaseNavigationMenu.Item;\r\n\r\n/**\r\n * Renders the navigation menu trigger.\r\n *\r\n * @remarks\r\n * - Renders a `<button>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuTrigger>Content</NavigationMenuTrigger>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nconst NavigationMenuTrigger = React.forwardRef<HTMLButtonElement, NavigationMenuTrigger.Props>(\r\n function NavigationMenuTrigger(props, forwardedRef) {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseNavigationMenu.Trigger\r\n {...otherProps}\r\n ref={forwardedRef}\r\n render={useRender({\r\n defaultTagName: \"button\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.trigger, className)}, {}),\r\n })}>\r\n {children}\r\n <ChevronDown className={styles.triggerIcon} />\r\n </BaseNavigationMenu.Trigger>\r\n );\r\n },\r\n);\r\n\r\n/**\r\n * Renders the navigation menu content.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuContent>Content</NavigationMenuContent>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nconst NavigationMenuContent = React.forwardRef<HTMLDivElement, NavigationMenuContent.Props>(\r\n function NavigationMenuContent(props, forwardedRef) {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseNavigationMenu.Content\r\n {...otherProps}\r\n ref={forwardedRef}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.content, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseNavigationMenu.Content>\r\n );\r\n },\r\n);\r\n\r\n/**\r\n * Renders the navigation menu link.\r\n *\r\n * @remarks\r\n * - Renders a `<a>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuLink>Content</NavigationMenuLink>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nconst NavigationMenuLink = React.forwardRef<HTMLAnchorElement, NavigationMenuLink.Props>(function NavigationMenuLink(props, forwardedRef) {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <BaseNavigationMenu.Link\r\n {...otherProps}\r\n ref={forwardedRef}\r\n render={useRender({\r\n defaultTagName: \"a\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.link, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseNavigationMenu.Link>\r\n );\r\n});\r\n\r\n/**\r\n * Renders the navigation menu viewport.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuViewport>Content</NavigationMenuViewport>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenuViewport(props: Readonly<NavigationMenuViewport.Props>): React.ReactElement {\r\n const {className, children, render, ...otherProps} = props;\r\n\r\n return (\r\n <div className={styles.viewportWrapper}>\r\n <BaseNavigationMenu.Portal>\r\n <BaseNavigationMenu.Positioner\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n props: mergeProps({className: styles.positioner}, {}),\r\n })}>\r\n <BaseNavigationMenu.Popup\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n props: mergeProps({className: styles.popup}, {}),\r\n })}>\r\n <BaseNavigationMenu.Viewport\r\n {...otherProps}\r\n render={useRender({\r\n defaultTagName: \"div\",\r\n render: render as never,\r\n props: mergeProps({className: cn(styles.viewport, className)}, {}),\r\n })}>\r\n {children}\r\n </BaseNavigationMenu.Viewport>\r\n </BaseNavigationMenu.Popup>\r\n </BaseNavigationMenu.Positioner>\r\n </BaseNavigationMenu.Portal>\r\n </div>\r\n );\r\n}\r\n\r\n/**\r\n * Renders the navigation menu indicator.\r\n *\r\n * @remarks\r\n * - Renders a `<div>` element by default\r\n * - Built on {@link https://base-ui.com/react/components/navigation-menu | Base UI Navigation Menu}\r\n * - Supports the `render` prop for element composition\r\n *\r\n * @example\r\n * ```tsx\r\n * <NavigationMenuIndicator>Content</NavigationMenuIndicator>\r\n * ```\r\n *\r\n * @see {@link https://base-ui.com/react/components/navigation-menu | Base UI Documentation}\r\n */\r\nfunction NavigationMenuIndicator(props: Readonly<NavigationMenuIndicator.Props>): React.ReactElement {\r\n // eslint-disable-next-line sonarjs/deprecation -- backward-compatible asChild API\r\n const {asChild = false, children, className, render, ...otherProps} = props;\r\n const renderProp = asChild && React.isValidElement(children) ? children : render;\r\n\r\n return useRender({\r\n defaultTagName: \"div\",\r\n render: renderProp as never,\r\n props: mergeProps({className: cn(styles.indicator, className)}, otherProps, {\r\n children: renderProp ? undefined : (children ?? <div className={styles.indicatorInner} />),\r\n }),\r\n });\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenu {\r\n export type Props = NavigationMenuProps;\r\n export type State = BaseNavigationMenu.Root.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuList {\r\n export type Props = NavigationMenuListProps;\r\n export type State = BaseNavigationMenu.List.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuTrigger {\r\n export type Props = NavigationMenuTriggerProps;\r\n export type State = BaseNavigationMenu.Trigger.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuContent {\r\n export type Props = NavigationMenuContentProps;\r\n export type State = BaseNavigationMenu.Content.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuLink {\r\n export type Props = NavigationMenuLinkProps;\r\n export type State = BaseNavigationMenu.Link.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuViewport {\r\n export type Props = NavigationMenuViewportProps;\r\n export type State = BaseNavigationMenu.Viewport.State;\r\n}\r\n\r\n// eslint-disable-next-line no-redeclare -- required for the canonical component namespace typing API\r\nnamespace NavigationMenuIndicator {\r\n export type Props = NavigationMenuIndicatorProps;\r\n export type State = Record<string, never>;\r\n}\r\n\r\nNavigationMenu.displayName = \"NavigationMenu\";\r\nNavigationMenuList.displayName = \"NavigationMenuList\";\r\nNavigationMenuItem.displayName = \"NavigationMenuItem\";\r\nNavigationMenuTrigger.displayName = \"NavigationMenuTrigger\";\r\nNavigationMenuContent.displayName = \"NavigationMenuContent\";\r\nNavigationMenuLink.displayName = \"NavigationMenuLink\";\r\nNavigationMenuViewport.displayName = \"NavigationMenuViewport\";\r\nNavigationMenuIndicator.displayName = \"NavigationMenuIndicator\";\r\n\r\nexport {\r\n NavigationMenu,\r\n NavigationMenuContent,\r\n NavigationMenuIndicator,\r\n NavigationMenuItem,\r\n NavigationMenuLink,\r\n NavigationMenuList,\r\n NavigationMenuTrigger,\r\n NavigationMenuViewport,\r\n};\r\n"],"names":["navigationMenuTriggerStyle","className","cn","styles","NavigationMenu","props","children","render","otherProps","BaseNavigationMenu","useRender","mergeProps","NavigationMenuViewport","NavigationMenuList","NavigationMenuItem","NavigationMenuTrigger","React","forwardedRef","ChevronDown","NavigationMenuContent","NavigationMenuLink","NavigationMenuIndicator","asChild","renderProp","undefined"],"mappings":";;;;;;;;;AAYO,SAASA,2BAA2BC,SAAkB;IAC3D,OAAOC,GAAGC,uBAAAA,OAAc,EAAEF;AAC5B;AAoFA,SAASG,+BAAeC,KAAqC;IAC3D,MAAM,EAACJ,SAAS,EAAEK,QAAQ,EAAEC,MAAM,EAAE,GAAGC,YAAW,GAAGH;IAErD,OAAO,WAAP,GACE,KAACI,eAAAA,IAAuB;QACrB,GAAGD,UAAU;QACd,QA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