@spark-ui/components 18.1.0 → 18.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (187) hide show
  1. package/dist/{FormFieldRequiredIndicator-DY3STDp1.js → FormFieldRequiredIndicator-BxZgeZ9H.js} +2 -2
  2. package/dist/{FormFieldRequiredIndicator-DY3STDp1.js.map → FormFieldRequiredIndicator-BxZgeZ9H.js.map} +1 -1
  3. package/dist/{FormFieldRequiredIndicator-COKYxTNs.mjs → FormFieldRequiredIndicator-CfE6AOta.mjs} +2 -2
  4. package/dist/{FormFieldRequiredIndicator-COKYxTNs.mjs.map → FormFieldRequiredIndicator-CfE6AOta.mjs.map} +1 -1
  5. package/dist/accordion/index.js +1 -1
  6. package/dist/accordion/index.js.map +1 -1
  7. package/dist/accordion/index.mjs +45 -50
  8. package/dist/accordion/index.mjs.map +1 -1
  9. package/dist/alert-dialog/AlertDialogAction.d.ts +1 -1
  10. package/dist/alert-dialog/AlertDialogCancel.d.ts +1 -1
  11. package/dist/alert-dialog/AlertDialogTrigger.d.ts +1 -1
  12. package/dist/alert-dialog/index.js +1 -1
  13. package/dist/alert-dialog/index.js.map +1 -1
  14. package/dist/alert-dialog/index.mjs +53 -56
  15. package/dist/alert-dialog/index.mjs.map +1 -1
  16. package/dist/avatar/index.js +1 -1
  17. package/dist/avatar/index.mjs +2 -2
  18. package/dist/badge/BadgeItem.styles.d.ts +1 -1
  19. package/dist/badge/index.js +1 -1
  20. package/dist/badge/index.mjs +13 -13
  21. package/dist/breadcrumb/index.js +1 -1
  22. package/dist/breadcrumb/index.mjs +1 -1
  23. package/dist/button/Button.styles.d.ts +1 -1
  24. package/dist/button/index.js +1 -1
  25. package/dist/button/index.mjs +1 -1
  26. package/dist/{button-D0s-21qo.js → button-3vvMrf1L.js} +2 -2
  27. package/dist/{button-D0s-21qo.js.map → button-3vvMrf1L.js.map} +1 -1
  28. package/dist/{button-DwLTXeJX.mjs → button-DBNjh3Bi.mjs} +76 -76
  29. package/dist/{button-DwLTXeJX.mjs.map → button-DBNjh3Bi.mjs.map} +1 -1
  30. package/dist/card/Backdrop.d.ts +1 -1
  31. package/dist/card/Card.styles.d.ts +1 -1
  32. package/dist/card/Content.styles.d.ts +1 -1
  33. package/dist/card/Type.d.ts +1 -1
  34. package/dist/card/index.js +1 -1
  35. package/dist/card/index.mjs +53 -53
  36. package/dist/carousel/index.js +1 -1
  37. package/dist/carousel/index.mjs +2 -2
  38. package/dist/checkbox/CheckboxInput.styles.d.ts +1 -1
  39. package/dist/checkbox/index.js +1 -1
  40. package/dist/checkbox/index.mjs +1 -1
  41. package/dist/{checkbox-uSINHQYe.mjs → checkbox-BEo9AVSB.mjs} +26 -26
  42. package/dist/{checkbox-uSINHQYe.mjs.map → checkbox-BEo9AVSB.mjs.map} +1 -1
  43. package/dist/{checkbox-Cbewcw6G.js → checkbox-Cr60_jql.js} +2 -2
  44. package/dist/{checkbox-Cbewcw6G.js.map → checkbox-Cr60_jql.js.map} +1 -1
  45. package/dist/chip/Chip.styles.d.ts +1 -1
  46. package/dist/chip/index.js +1 -1
  47. package/dist/chip/index.mjs +86 -86
  48. package/dist/collapsible/index.js +1 -1
  49. package/dist/collapsible/index.js.map +1 -1
  50. package/dist/collapsible/index.mjs +18 -24
  51. package/dist/collapsible/index.mjs.map +1 -1
  52. package/dist/combobox/index.js +1 -1
  53. package/dist/combobox/index.mjs +4 -4
  54. package/dist/dialog/DialogClose.d.ts +1 -1
  55. package/dist/dialog/DialogTrigger.d.ts +1 -1
  56. package/dist/dialog/index.js +1 -1
  57. package/dist/dialog/index.js.map +1 -1
  58. package/dist/dialog/index.mjs +13 -11
  59. package/dist/dialog/index.mjs.map +1 -1
  60. package/dist/divider/index.js +1 -1
  61. package/dist/divider/index.mjs +26 -26
  62. package/dist/drawer/DrawerClose.d.ts +1 -1
  63. package/dist/drawer/DrawerTrigger.d.ts +1 -1
  64. package/dist/drawer/index.js +1 -1
  65. package/dist/drawer/index.js.map +1 -1
  66. package/dist/drawer/index.mjs +13 -11
  67. package/dist/drawer/index.mjs.map +1 -1
  68. package/dist/dropdown/index.js +1 -1
  69. package/dist/dropdown/index.mjs +2 -2
  70. package/dist/file-upload/index.js +1 -1
  71. package/dist/file-upload/index.mjs +3 -3
  72. package/dist/form-field/index.js +1 -1
  73. package/dist/form-field/index.mjs +1 -1
  74. package/dist/{form-field-B38U0zp8.js → form-field-DMHwopHt.js} +2 -2
  75. package/dist/{form-field-B38U0zp8.js.map → form-field-DMHwopHt.js.map} +1 -1
  76. package/dist/{form-field-DCKyhBmv.mjs → form-field-Doq4zLEX.mjs} +4 -4
  77. package/dist/{form-field-DCKyhBmv.mjs.map → form-field-Doq4zLEX.mjs.map} +1 -1
  78. package/dist/icon/Icon.styles.d.ts +1 -1
  79. package/dist/icon/index.js +1 -1
  80. package/dist/icon/index.mjs +1 -1
  81. package/dist/icon-CfEsla9z.js +2 -0
  82. package/dist/{icon-DY4l9nsc.js.map → icon-CfEsla9z.js.map} +1 -1
  83. package/dist/{icon-Bs-39J-H.mjs → icon-VM_Ys9Xn.mjs} +11 -11
  84. package/dist/{icon-Bs-39J-H.mjs.map → icon-VM_Ys9Xn.mjs.map} +1 -1
  85. package/dist/icon-button/index.js +1 -1
  86. package/dist/icon-button/index.mjs +1 -1
  87. package/dist/icon-button-B2TM0Xby.js +2 -0
  88. package/dist/{icon-button-DRFf308H.js.map → icon-button-B2TM0Xby.js.map} +1 -1
  89. package/dist/icon-button-CexCkoV0.mjs +29 -0
  90. package/dist/{icon-button-C1ThqdK1.mjs.map → icon-button-CexCkoV0.mjs.map} +1 -1
  91. package/dist/input/index.js +1 -1
  92. package/dist/input/index.mjs +1 -1
  93. package/dist/{input-BoxJZira.js → input-CADvgFpY.js} +2 -2
  94. package/dist/{input-BoxJZira.js.map → input-CADvgFpY.js.map} +1 -1
  95. package/dist/{input-Du9YSgAt.mjs → input-CmlNZ4Bo.mjs} +2 -2
  96. package/dist/{input-Du9YSgAt.mjs.map → input-CmlNZ4Bo.mjs.map} +1 -1
  97. package/dist/label/index.js +1 -1
  98. package/dist/label/index.mjs +1 -1
  99. package/dist/{label-DO48yda7.js → label-B085X0Sg.js} +2 -2
  100. package/dist/{label-DO48yda7.js.map → label-B085X0Sg.js.map} +1 -1
  101. package/dist/{label-RKaPen31.mjs → label-BqWu-wLT.mjs} +6 -6
  102. package/dist/{label-RKaPen31.mjs.map → label-BqWu-wLT.mjs.map} +1 -1
  103. package/dist/menu/MenuItemStyles.d.ts +1 -1
  104. package/dist/menu/index.js +1 -1
  105. package/dist/menu/index.js.map +1 -1
  106. package/dist/menu/index.mjs +131 -140
  107. package/dist/menu/index.mjs.map +1 -1
  108. package/dist/meter/MeterTrack.styles.d.ts +1 -1
  109. package/dist/pagination/index.js +1 -1
  110. package/dist/pagination/index.mjs +3 -3
  111. package/dist/popover/PopoverContent.styles.d.ts +1 -1
  112. package/dist/popover/index.js +1 -1
  113. package/dist/popover/index.mjs +1 -1
  114. package/dist/{popover-DVz0JvON.js → popover-B-mcHcLF.js} +2 -2
  115. package/dist/{popover-DVz0JvON.js.map → popover-B-mcHcLF.js.map} +1 -1
  116. package/dist/{popover-CGhSHQzb.mjs → popover-COqbFikI.mjs} +17 -17
  117. package/dist/{popover-CGhSHQzb.mjs.map → popover-COqbFikI.mjs.map} +1 -1
  118. package/dist/progress/ProgressIndicator.d.ts +1 -1
  119. package/dist/progress-tracker/index.js +1 -1
  120. package/dist/progress-tracker/index.mjs +1 -1
  121. package/dist/radio-group/RadioIndicator.styles.d.ts +1 -1
  122. package/dist/radio-group/RadioInput.styles.d.ts +1 -1
  123. package/dist/radio-group/index.js +1 -1
  124. package/dist/radio-group/index.mjs +37 -37
  125. package/dist/rating/index.js +1 -1
  126. package/dist/rating/index.mjs +2 -2
  127. package/dist/rating-display/index.js +1 -1
  128. package/dist/rating-display/index.mjs +1 -1
  129. package/dist/scrolling-list/index.js +1 -1
  130. package/dist/scrolling-list/index.mjs +3 -3
  131. package/dist/select/index.js +1 -1
  132. package/dist/select/index.mjs +1 -1
  133. package/dist/slider/SliderThumb.styles.d.ts +1 -1
  134. package/dist/slider/SliderTrack.styles.d.ts +1 -1
  135. package/dist/slider/index.js +1 -1
  136. package/dist/slider/index.mjs +2 -2
  137. package/dist/slot/index.js +1 -1
  138. package/dist/slot/index.mjs +3 -3
  139. package/dist/spinner/Spinner.styles.d.ts +1 -1
  140. package/dist/spinner/index.js +1 -1
  141. package/dist/spinner/index.mjs +1 -1
  142. package/dist/{spinner-CmPypfJR.js → spinner-BAreohbs.js} +2 -2
  143. package/dist/{spinner-CmPypfJR.js.map → spinner-BAreohbs.js.map} +1 -1
  144. package/dist/{spinner-TfGcjNm3.mjs → spinner-DnrZf01S.mjs} +9 -9
  145. package/dist/{spinner-TfGcjNm3.mjs.map → spinner-DnrZf01S.mjs.map} +1 -1
  146. package/dist/stepper/index.js +1 -1
  147. package/dist/stepper/index.mjs +3 -3
  148. package/dist/switch/SwitchInput.d.ts +1 -1
  149. package/dist/switch/index.js +1 -1
  150. package/dist/switch/index.js.map +1 -1
  151. package/dist/switch/index.mjs +43 -44
  152. package/dist/switch/index.mjs.map +1 -1
  153. package/dist/table/index.js +1 -1
  154. package/dist/table/index.mjs +3 -3
  155. package/dist/tabs/index.js +1 -1
  156. package/dist/tabs/index.js.map +1 -1
  157. package/dist/tabs/index.mjs +144 -153
  158. package/dist/tabs/index.mjs.map +1 -1
  159. package/dist/tag/Tag.styles.d.ts +1 -1
  160. package/dist/tag/index.js +1 -1
  161. package/dist/tag/index.mjs +37 -37
  162. package/dist/text-link/TextLink.d.ts +1 -1
  163. package/dist/textarea/index.js +1 -1
  164. package/dist/textarea/index.mjs +1 -1
  165. package/dist/toast/Toast.styles.d.ts +1 -1
  166. package/dist/toast/index.js +1 -1
  167. package/dist/toast/index.mjs +3 -3
  168. package/dist/toggle-group/index.js +1 -1
  169. package/dist/toggle-group/index.js.map +1 -1
  170. package/dist/toggle-group/index.mjs +16 -21
  171. package/dist/toggle-group/index.mjs.map +1 -1
  172. package/package.json +6 -6
  173. package/dist/accordion/useRenderSlot.d.ts +0 -3
  174. package/dist/alert-dialog/useRenderSlot.d.ts +0 -3
  175. package/dist/collapsible/useRenderSlot.d.ts +0 -3
  176. package/dist/drawer/useRenderSlot.d.ts +0 -3
  177. package/dist/icon-DY4l9nsc.js +0 -2
  178. package/dist/icon-button-C1ThqdK1.mjs +0 -29
  179. package/dist/icon-button-DRFf308H.js +0 -2
  180. package/dist/menu/useRenderSlot.d.ts +0 -1
  181. package/dist/tabs/useRenderSlot.d.ts +0 -1
  182. package/dist/toast/useRenderSlot.d.ts +0 -3
  183. package/dist/toggle-group/useRenderSlot.d.ts +0 -1
  184. package/dist/useRenderSlot-5CPC9Lkj.mjs +0 -11
  185. package/dist/useRenderSlot-5CPC9Lkj.mjs.map +0 -1
  186. package/dist/useRenderSlot-DHV0CegV.js +0 -2
  187. package/dist/useRenderSlot-DHV0CegV.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../src/menu/Menu.tsx","../../src/menu/MenuItemStyles.tsx","../../src/menu/useRenderSlot.tsx","../../src/menu/MenuCheckboxItem.tsx","../../src/menu/MenuGroup.tsx","../../src/menu/MenuGroupLabel.tsx","../../src/menu/MenuItem.tsx","../../src/menu/MenuLinkItem.tsx","../../src/menu/MenuPopup.tsx","../../src/menu/MenuPortal.tsx","../../src/menu/MenuSubmenuContext.tsx","../../src/menu/MenuPositioner.tsx","../../src/menu/MenuRadioGroup.tsx","../../src/menu/MenuRadioItem.tsx","../../src/menu/MenuSeparator.tsx","../../src/menu/MenuSubmenu.tsx","../../src/menu/MenuSubmenuTrigger.tsx","../../src/menu/MenuTrigger.tsx","../../src/menu/index.ts"],"sourcesContent":["import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { type ComponentProps, type ReactNode } from 'react'\n\nexport interface MenuProps extends Omit<ComponentProps<typeof BaseMenu.Root>, 'children'> {\n /**\n * The content of the menu (trigger, portal, etc.)\n */\n children: ReactNode\n}\n\n/**\n * Root container for menu state and styling context.\n */\nexport const Menu = ({ children, ...rest }: MenuProps) => {\n return (\n <BaseMenu.Root data-spark-component=\"menu\" {...rest}>\n {children}\n </BaseMenu.Root>\n )\n}\n\nMenu.displayName = 'Menu'\n","import { makeVariants } from '@spark-ui/internal-utils'\nimport { cva, type VariantProps } from 'class-variance-authority'\n\nexport const menuItemStyles = cva(\n [\n 'gap-md flex w-full cursor-pointer items-center justify-start',\n 'text-left text-body-1',\n 'transition-colors duration-100',\n 'outline-none',\n 'focus-visible:u-outline focus-visible:-outline-offset-2',\n 'data-disabled:cursor-not-allowed data-disabled:opacity-dim-3',\n 'min-h-sz-44',\n 'px-lg py-md',\n 'data-highlighted:bg-surface-hovered',\n 'data-popup-open:bg-surface-hovered',\n ],\n {\n variants: {\n intent: makeVariants<\n 'intent',\n ['surface', 'main', 'support', 'accent', 'success', 'alert', 'danger', 'info', 'neutral']\n >({\n surface: ['text-on-surface'],\n main: ['text-on-surface'],\n support: ['text-on-surface'],\n accent: ['text-on-surface'],\n success: ['text-on-surface'],\n alert: ['text-on-surface'],\n danger: ['text-on-surface'],\n info: ['text-on-surface'],\n neutral: ['text-on-surface'],\n }),\n },\n defaultVariants: {\n intent: 'surface',\n },\n }\n)\n\nexport type MenuItemStylesProps = VariantProps<typeof menuItemStyles>\n","import { Slot } from '../slot'\n\nexport function useRenderSlot(asChild: boolean) {\n return asChild ? ({ ...props }: object) => <Slot {...props} /> : undefined\n}\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { Check } from '@spark-ui/icons/Check'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps, type Ref } from 'react'\n\nimport { Icon } from '../icon'\nimport { menuItemStyles } from './MenuItemStyles'\nimport { useRenderSlot } from './useRenderSlot'\n\nexport interface MenuCheckboxItemProps extends Omit<\n ComponentProps<typeof BaseMenu.CheckboxItem>,\n 'render'\n> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * A menu item with checkbox functionality.\n * Can be toggled on and off, allowing multiple selections.\n * The checkbox indicator is automatically rendered on the left side.\n */\nexport const MenuCheckboxItem = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuCheckboxItemProps) => {\n const renderSlot = useRenderSlot(asChild)\n\n return (\n <BaseMenu.CheckboxItem\n ref={ref}\n data-spark-component=\"menu-checkbox-item\"\n render={renderSlot}\n className={cx(\n menuItemStyles({\n className,\n }),\n 'data-checked:font-bold'\n )}\n {...rest}\n >\n <BaseMenu.CheckboxItemIndicator\n keepMounted\n className={cx(\n 'mr-md flex shrink-0 items-center justify-center',\n 'w-sz-16 h-sz-16',\n 'transition-opacity',\n 'data-checked:opacity-100',\n 'opacity-0'\n )}\n >\n <Icon size=\"sm\" intent=\"current\">\n <Check />\n </Icon>\n </BaseMenu.CheckboxItemIndicator>\n {children}\n </BaseMenu.CheckboxItem>\n )\n}\n\nMenuCheckboxItem.displayName = 'Menu.CheckboxItem'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps } from 'react'\n\nexport interface MenuGroupProps extends ComponentProps<typeof BaseMenu.Group> {}\n\n/**\n * A container for grouping related menu items together.\n * Works with Menu.GroupLabel for semantic grouping.\n */\nexport const MenuGroup = ({ children, className, ...rest }: MenuGroupProps) => {\n return (\n <BaseMenu.Group data-spark-component=\"menu-group\" className={cx('py-sm', className)} {...rest}>\n {children}\n </BaseMenu.Group>\n )\n}\n\nMenuGroup.displayName = 'Menu.Group'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps, type Ref } from 'react'\n\nimport { useRenderSlot } from './useRenderSlot'\n\nexport interface MenuGroupLabelProps extends Omit<\n ComponentProps<typeof BaseMenu.GroupLabel>,\n 'render'\n> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * A label for a group of menu items.\n * Provides semantic context and visual separation for grouped items.\n */\nexport const MenuGroupLabel = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuGroupLabelProps) => {\n const renderSlot = useRenderSlot(asChild)\n\n return (\n <BaseMenu.GroupLabel\n ref={ref}\n data-spark-component=\"menu-group-label\"\n render={renderSlot}\n className={cx('text-on-surface/dim-1 text-body-2 font-bold', 'px-lg py-sm', className)}\n {...rest}\n >\n {children}\n </BaseMenu.GroupLabel>\n )\n}\n\nMenuGroupLabel.displayName = 'Menu.GroupLabel'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { type ComponentProps, type Ref } from 'react'\n\nimport { menuItemStyles } from './MenuItemStyles'\nimport { useRenderSlot } from './useRenderSlot'\n\nexport interface MenuItemProps extends Omit<ComponentProps<typeof BaseMenu.Item>, 'render'> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * A menu item that triggers an action when activated.\n * Renders a clickable menu option with keyboard support.\n */\nexport const MenuItem = ({ asChild = false, children, className, ref, ...rest }: MenuItemProps) => {\n const renderSlot = useRenderSlot(asChild)\n\n return (\n <BaseMenu.Item\n ref={ref}\n data-spark-component=\"menu-item\"\n render={renderSlot}\n className={menuItemStyles({\n className,\n })}\n {...rest}\n >\n {children}\n </BaseMenu.Item>\n )\n}\n\nMenuItem.displayName = 'Menu.Item'\n","import { Link } from '@spark-ui/icons/Link'\nimport { type ComponentPropsWithoutRef } from 'react'\n\nimport { Icon } from '../icon'\nimport { MenuItem } from './MenuItem'\n\nexport interface MenuLinkItemProps extends Omit<\n ComponentPropsWithoutRef<typeof MenuItem>,\n 'asChild'\n> {\n /**\n * The URL to navigate to.\n */\n href: string\n /**\n * Where to display the linked URL.\n * @default undefined\n */\n target?: string\n /**\n * The relationship between the current document and the linked document.\n * @default undefined\n */\n rel?: string\n}\n\n/**\n * A menu item that acts as a link.\n * Navigates to a URL when activated, useful for navigation menus.\n * Use with Next.js Link or React Router Link via the children prop.\n */\nexport const MenuLinkItem = ({ children, href, target, rel, ...rest }: MenuLinkItemProps) => {\n return (\n <MenuItem asChild {...rest}>\n <a href={href} target={target} rel={rel}>\n <Icon size=\"sm\" intent=\"current\" className=\"ml-auto shrink-0\">\n <Link />\n </Icon>\n <span className=\"flex-1\">{children}</span>\n </a>\n </MenuItem>\n )\n}\n\nMenuLinkItem.displayName = 'Menu.LinkItem'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps, type Ref } from 'react'\n\nimport { useRenderSlot } from './useRenderSlot'\n\nexport interface MenuPopupProps extends Omit<ComponentProps<typeof BaseMenu.Popup>, 'render'> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * The scrollable menu container that holds menu items.\n * Serves as the viewport for menu content with overflow handling.\n */\nexport const MenuPopup = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuPopupProps) => {\n const renderSlot = useRenderSlot(asChild)\n\n return (\n <BaseMenu.Popup\n ref={ref}\n data-spark-component=\"menu-popup\"\n render={renderSlot}\n className={cx(\n [\n 'rounded-md bg-surface shadow-lg min-w-sz-192',\n 'p-sm',\n 'overflow-auto',\n 'z-popover',\n 'data-starting-style:opacity-0',\n 'data-ending-style:opacity-0',\n 'opacity-100',\n 'transition-opacity duration-200',\n ],\n className\n )}\n {...rest}\n >\n {children}\n </BaseMenu.Popup>\n )\n}\n\nMenuPopup.displayName = 'Menu.Popup'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { type ComponentProps } from 'react'\n\nexport interface MenuPortalProps extends ComponentProps<typeof BaseMenu.Portal> {}\n\n/**\n * Portal wrapper that renders the menu in a different part of the DOM tree.\n * Useful for avoiding z-index and overflow issues.\n */\nexport const MenuPortal = ({ children, ...rest }: MenuPortalProps) => {\n return <BaseMenu.Portal {...rest}>{children}</BaseMenu.Portal>\n}\n\nMenuPortal.displayName = 'Menu.Portal'\n","import { createContext, useContext } from 'react'\n\n/**\n * Context to track if we're inside a submenu\n */\nexport const MenuSubmenuContext = createContext<boolean>(false)\n\n/**\n * Hook to check if the current menu is a submenu\n */\nexport const useIsSubmenu = () => {\n return useContext(MenuSubmenuContext)\n}\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { type ComponentProps } from 'react'\n\nimport { useIsSubmenu } from './MenuSubmenuContext'\n\nexport interface MenuPositionerProps extends ComponentProps<typeof BaseMenu.Positioner> {}\n\n/**\n * Positioning wrapper for the menu with collision detection.\n * Handles menu placement relative to the trigger and viewport boundaries.\n */\nexport const MenuPositioner = ({ children, sideOffset, ...rest }: MenuPositionerProps) => {\n const isSubmenu = useIsSubmenu()\n\n // Apply sideOffset of 8 for root menu, 0 for submenus (unless explicitly overridden)\n const defaultSideOffset = isSubmenu ? 0 : 8\n const finalSideOffset = sideOffset ?? defaultSideOffset\n\n return (\n <BaseMenu.Positioner sideOffset={finalSideOffset} {...rest}>\n {children}\n </BaseMenu.Positioner>\n )\n}\n\nMenuPositioner.displayName = 'Menu.Positioner'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps } from 'react'\n\nexport interface MenuRadioGroupProps extends ComponentProps<typeof BaseMenu.RadioGroup> {}\n\n/**\n * A container for radio menu items where only one item can be selected at a time.\n * Manages the selection state for its radio items.\n */\nexport const MenuRadioGroup = ({ children, className, ...rest }: MenuRadioGroupProps) => {\n return (\n <BaseMenu.RadioGroup\n data-spark-component=\"menu-radio-group\"\n className={cx('py-sm', className)}\n {...rest}\n >\n {children}\n </BaseMenu.RadioGroup>\n )\n}\n\nMenuRadioGroup.displayName = 'Menu.RadioGroup'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { Check } from '@spark-ui/icons/Check'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps, type Ref } from 'react'\n\nimport { Icon } from '../icon'\nimport { menuItemStyles } from './MenuItemStyles'\nimport { useRenderSlot } from './useRenderSlot'\n\nexport interface MenuRadioItemProps extends Omit<\n ComponentProps<typeof BaseMenu.RadioItem>,\n 'render'\n> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * A menu item with radio button functionality.\n * Only one radio item can be selected within its RadioGroup.\n * The radio indicator is automatically rendered on the left side.\n */\nexport const MenuRadioItem = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuRadioItemProps) => {\n const renderSlot = useRenderSlot(asChild)\n\n return (\n <BaseMenu.RadioItem\n ref={ref}\n data-spark-component=\"menu-radio-item\"\n render={renderSlot}\n className={cx(\n menuItemStyles({\n className,\n }),\n 'data-checked:font-bold'\n )}\n {...rest}\n >\n <BaseMenu.RadioItemIndicator\n keepMounted\n className={cx(\n 'mr-md flex shrink-0 items-center justify-center',\n 'w-sz-16 h-sz-16',\n 'transition-opacity',\n 'data-checked:opacity-100',\n 'opacity-0'\n )}\n >\n <Icon size=\"sm\" intent=\"current\">\n <Check />\n </Icon>\n </BaseMenu.RadioItemIndicator>\n {children}\n </BaseMenu.RadioItem>\n )\n}\n\nMenuRadioItem.displayName = 'Menu.RadioItem'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps } from 'react'\n\nexport interface MenuSeparatorProps extends ComponentProps<typeof BaseMenu.Separator> {}\n\n/**\n * A visual divider between menu items or groups.\n * Creates clear separation between different sections of the menu.\n */\nexport const MenuSeparator = ({ className, ...rest }: MenuSeparatorProps) => {\n return (\n <BaseMenu.Separator\n data-spark-component=\"menu-separator\"\n className={cx('my-sm h-px bg-outline/dim-2', className)}\n {...rest}\n />\n )\n}\n\nMenuSeparator.displayName = 'Menu.Separator'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { type ComponentProps, type ReactNode } from 'react'\n\nimport { MenuSubmenuContext } from './MenuSubmenuContext'\n\nexport interface MenuSubmenuProps extends Omit<\n ComponentProps<typeof BaseMenu.SubmenuRoot>,\n 'children'\n> {\n /**\n * The content of the submenu (trigger, positioner, popup, etc.)\n */\n children: ReactNode\n}\n\n/**\n * A nested submenu that appears when its trigger is activated.\n * Inherits styling context from the parent menu.\n */\nexport const MenuSubmenu = ({ children, ...rest }: MenuSubmenuProps) => {\n return (\n <BaseMenu.SubmenuRoot data-spark-component=\"menu-submenu\" {...rest}>\n <MenuSubmenuContext value={true}>{children}</MenuSubmenuContext>\n </BaseMenu.SubmenuRoot>\n )\n}\n\nMenuSubmenu.displayName = 'Menu.Submenu'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { ArrowVerticalRight } from '@spark-ui/icons/ArrowVerticalRight'\nimport { type ComponentProps, type Ref } from 'react'\n\nimport { Icon } from '../icon'\nimport { menuItemStyles } from './MenuItemStyles'\nimport { useRenderSlot } from './useRenderSlot'\n\nexport interface MenuSubmenuTriggerProps extends Omit<\n ComponentProps<typeof BaseMenu.SubmenuTrigger>,\n 'render'\n> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * A menu item that opens a submenu when activated.\n * Displays an arrow indicator to show submenu availability.\n */\nexport const MenuSubmenuTrigger = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuSubmenuTriggerProps) => {\n const renderSlot = useRenderSlot(asChild)\n\n return (\n <BaseMenu.SubmenuTrigger\n ref={ref}\n data-spark-component=\"menu-submenu-trigger\"\n render={renderSlot}\n className={menuItemStyles({\n className,\n })}\n {...rest}\n >\n <span className=\"flex-1\">{children}</span>\n <Icon size=\"sm\" intent=\"current\" className=\"ml-auto shrink-0\">\n <ArrowVerticalRight />\n </Icon>\n </BaseMenu.SubmenuTrigger>\n )\n}\n\nMenuSubmenuTrigger.displayName = 'Menu.SubmenuTrigger'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { ArrowHorizontalDown } from '@spark-ui/icons/ArrowHorizontalDown'\nimport { cx } from 'class-variance-authority'\nimport {\n cloneElement,\n isValidElement,\n type ComponentProps,\n type ReactElement,\n type Ref,\n} from 'react'\n\nimport { Icon } from '../icon'\nimport { useRenderSlot } from './useRenderSlot'\n\nexport interface MenuTriggerProps extends Omit<ComponentProps<typeof BaseMenu.Trigger>, 'render'> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLButtonElement>\n}\n\n/**\n * The button that toggles the menu.\n * Renders a <button> element by default, or uses asChild for custom elements.\n * When used with asChild and a Button component, automatically adds an ArrowHorizontalDown icon.\n * Button components should use design=\"outlined\" and intent=\"support\".\n */\nexport const MenuTrigger = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuTriggerProps) => {\n const renderSlot = useRenderSlot(asChild)\n\n // When asChild is used with a Button, enhance it with the arrow icon\n const enhancedChildren =\n asChild && isValidElement(children)\n ? cloneElement(\n children as ReactElement,\n {\n design: (children.props as { design?: string }).design ?? 'outlined',\n intent: (children.props as { intent?: string }).intent ?? 'support',\n children: (\n <>\n {(children.props as { children: React.ReactNode }).children}\n <Icon size=\"sm\" intent=\"current\" className=\"shrink-0\">\n <ArrowHorizontalDown />\n </Icon>\n </>\n ),\n } as Partial<unknown>\n )\n : children\n\n return (\n <BaseMenu.Trigger\n ref={ref}\n data-spark-component=\"menu-trigger\"\n render={renderSlot}\n className={cx(\n 'inline-flex items-center justify-center',\n 'focus-visible:u-outline',\n className\n )}\n {...rest}\n >\n {enhancedChildren}\n </BaseMenu.Trigger>\n )\n}\n\nMenuTrigger.displayName = 'Menu.Trigger'\n","import { Menu as Root } from './Menu'\nimport { MenuCheckboxItem } from './MenuCheckboxItem'\nimport { MenuGroup } from './MenuGroup'\nimport { MenuGroupLabel } from './MenuGroupLabel'\nimport { MenuItem } from './MenuItem'\nimport { MenuLinkItem } from './MenuLinkItem'\nimport { MenuPopup } from './MenuPopup'\nimport { MenuPortal } from './MenuPortal'\nimport { MenuPositioner } from './MenuPositioner'\nimport { MenuRadioGroup } from './MenuRadioGroup'\nimport { MenuRadioItem } from './MenuRadioItem'\nimport { MenuSeparator } from './MenuSeparator'\nimport { MenuSubmenu } from './MenuSubmenu'\nimport { MenuSubmenuTrigger } from './MenuSubmenuTrigger'\nimport { MenuTrigger } from './MenuTrigger'\n\n/**\n * A menu component that enables users to select options from a dropdown menu triggered by a button or other interactive element.\n */\nexport const Menu: typeof Root & {\n Trigger: typeof MenuTrigger\n Portal: typeof MenuPortal\n Positioner: typeof MenuPositioner\n Popup: typeof MenuPopup\n Item: typeof MenuItem\n LinkItem: typeof MenuLinkItem\n Submenu: typeof MenuSubmenu\n SubmenuTrigger: typeof MenuSubmenuTrigger\n Group: typeof MenuGroup\n GroupLabel: typeof MenuGroupLabel\n RadioGroup: typeof MenuRadioGroup\n RadioItem: typeof MenuRadioItem\n CheckboxItem: typeof MenuCheckboxItem\n Separator: typeof MenuSeparator\n} = Object.assign(Root, {\n Trigger: MenuTrigger,\n Portal: MenuPortal,\n Positioner: MenuPositioner,\n Popup: MenuPopup,\n Item: MenuItem,\n LinkItem: MenuLinkItem,\n Submenu: MenuSubmenu,\n SubmenuTrigger: MenuSubmenuTrigger,\n Group: MenuGroup,\n GroupLabel: MenuGroupLabel,\n RadioGroup: MenuRadioGroup,\n RadioItem: MenuRadioItem,\n CheckboxItem: MenuCheckboxItem,\n Separator: MenuSeparator,\n})\n\nMenu.displayName = 'Menu'\nMenuTrigger.displayName = 'Menu.Trigger'\nMenuPortal.displayName = 'Menu.Portal'\nMenuPositioner.displayName = 'Menu.Positioner'\nMenuPopup.displayName = 'Menu.Popup'\nMenuItem.displayName = 'Menu.Item'\nMenuLinkItem.displayName = 'Menu.LinkItem'\nMenuSubmenu.displayName = 'Menu.Submenu'\nMenuSubmenuTrigger.displayName = 'Menu.SubmenuTrigger'\nMenuGroup.displayName = 'Menu.Group'\nMenuGroupLabel.displayName = 'Menu.GroupLabel'\nMenuRadioGroup.displayName = 'Menu.RadioGroup'\nMenuRadioItem.displayName = 'Menu.RadioItem'\nMenuCheckboxItem.displayName = 'Menu.CheckboxItem'\nMenuSeparator.displayName = 'Menu.Separator'\n\nexport { type MenuProps } from './Menu'\nexport { type MenuTriggerProps } from './MenuTrigger'\nexport { type MenuPortalProps } from './MenuPortal'\nexport { type MenuPositionerProps } from './MenuPositioner'\nexport { type MenuPopupProps } from './MenuPopup'\nexport { type MenuItemProps } from './MenuItem'\nexport { type MenuLinkItemProps } from './MenuLinkItem'\nexport { type MenuSubmenuProps } from './MenuSubmenu'\nexport { type MenuSubmenuTriggerProps } from './MenuSubmenuTrigger'\nexport { type MenuGroupProps } from './MenuGroup'\nexport { type MenuGroupLabelProps } from './MenuGroupLabel'\nexport { type MenuRadioGroupProps } from './MenuRadioGroup'\nexport { type MenuRadioItemProps } from './MenuRadioItem'\nexport { type MenuCheckboxItemProps } from './MenuCheckboxItem'\nexport { type MenuSeparatorProps } from './MenuSeparator'\n"],"mappings":"idAaA,IAAa,GAAQ,CAAE,WAAU,GAAG,MAEhC,EAAA,EAAA,IAAA,CAAC,EAAA,KAAS,KAAV,CAAe,uBAAqB,OAAO,GAAI,EAC5C,UACY,CAAA,EAInB,EAAK,YAAc,OClBnB,IAAa,GAAA,EAAA,E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A,CAA0B,CAAQ,GAAA,EAAA,EAAA,aAAA,CAE5B,EACA,CACE,OAAS,EAAS,MAA8B,QAAU,WAC1D,OAAS,EAAS,MAA8B,QAAU,UAC1D,UACE,EAAA,EAAA,KAAA,CAAA,EAAA,SAAA,CAAA,SAAA,CACI,EAAS,MAAwC,UACnD,EAAA,EAAA,IAAA,CAAC,EAAA,EAAD,CAAM,KAAK,KAAK,OAAO,UAAU,UAAU,qBACzC,EAAA,EAAA,IAAA,CAAC,EAAA,oBAAD,CAAsB,CAAA,CAClB,CAAA,CACN,CAAA,CAAA,CAEN,CACF,EACA,EAEN,OACE,EAAA,EAAA,IAAA,CAAC,EAAA,KAAS,QAAV,CACO,MACL,uBAAqB,eACrB,OAAQ,EACR,WAAA,EAAA,EAAA,GAAA,CACE,0CACA,0BACA,CACF,EACA,GAAI,WAEH,CACe,CAAA,CAEtB,EAEA,EAAY,YAAc,eCzD1B,IAAa,EAeT,OAAO,OAAO,EAAM,CACtB,QAAS,EACT,OAAQ,EACR,WAAY,EACZ,MAAO,EACP,KAAM,EACN,SAAU,EACV,QAAS,EACT,eAAgB,EAChB,MAAO,EACP,WAAY,EACZ,WAAY,EACZ,UAAW,EACX,aAAc,EACd,UAAW,CACb,CAAC,EAED,EAAK,YAAc,OACnB,EAAY,YAAc,eAC1B,EAAW,YAAc,cACzB,EAAe,YAAc,kBAC7B,EAAU,YAAc,aACxB,EAAS,YAAc,YACvB,EAAa,YAAc,gBAC3B,EAAY,YAAc,eAC1B,EAAmB,YAAc,sBACjC,EAAU,YAAc,aACxB,EAAe,YAAc,kBAC7B,EAAe,YAAc,kBAC7B,EAAc,YAAc,iBAC5B,EAAiB,YAAc,oBAC/B,EAAc,YAAc"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/menu/Menu.tsx","../../src/menu/MenuItemStyles.tsx","../../src/menu/MenuCheckboxItem.tsx","../../src/menu/MenuGroup.tsx","../../src/menu/MenuGroupLabel.tsx","../../src/menu/MenuItem.tsx","../../src/menu/MenuLinkItem.tsx","../../src/menu/MenuPopup.tsx","../../src/menu/MenuPortal.tsx","../../src/menu/MenuSubmenuContext.tsx","../../src/menu/MenuPositioner.tsx","../../src/menu/MenuRadioGroup.tsx","../../src/menu/MenuRadioItem.tsx","../../src/menu/MenuSeparator.tsx","../../src/menu/MenuSubmenu.tsx","../../src/menu/MenuSubmenuTrigger.tsx","../../src/menu/MenuTrigger.tsx","../../src/menu/index.ts"],"sourcesContent":["import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { type ComponentProps, type ReactNode } from 'react'\n\nexport interface MenuProps extends Omit<ComponentProps<typeof BaseMenu.Root>, 'children'> {\n /**\n * The content of the menu (trigger, portal, etc.)\n */\n children: ReactNode\n}\n\n/**\n * Root container for menu state and styling context.\n */\nexport const Menu = ({ children, ...rest }: MenuProps) => {\n return (\n <BaseMenu.Root data-spark-component=\"menu\" {...rest}>\n {children}\n </BaseMenu.Root>\n )\n}\n\nMenu.displayName = 'Menu'\n","import { makeVariants } from '@spark-ui/internal-utils'\nimport { cva, type VariantProps } from 'class-variance-authority'\n\nexport const menuItemStyles = cva(\n [\n 'gap-md flex w-full cursor-pointer items-center justify-start',\n 'text-left text-body-1',\n 'transition-colors duration-100',\n 'outline-none',\n 'focus-visible:u-outline focus-visible:-outline-offset-2',\n 'data-disabled:cursor-not-allowed data-disabled:opacity-dim-3',\n 'min-h-sz-44',\n 'px-lg py-md',\n 'data-highlighted:bg-surface-hovered',\n 'data-popup-open:bg-surface-hovered',\n ],\n {\n variants: {\n intent: makeVariants<\n 'intent',\n ['surface', 'main', 'support', 'accent', 'success', 'alert', 'danger', 'info', 'neutral']\n >({\n surface: ['text-on-surface'],\n main: ['text-on-surface'],\n support: ['text-on-surface'],\n accent: ['text-on-surface'],\n success: ['text-on-surface'],\n alert: ['text-on-surface'],\n danger: ['text-on-surface'],\n info: ['text-on-surface'],\n neutral: ['text-on-surface'],\n }),\n },\n defaultVariants: {\n intent: 'surface',\n },\n }\n)\n\nexport type MenuItemStylesProps = VariantProps<typeof menuItemStyles>\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { Check } from '@spark-ui/icons/Check'\nimport { createRenderSlot } from '@spark-ui/internal-utils'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps, type Ref } from 'react'\n\nimport { Icon } from '../icon'\nimport { menuItemStyles } from './MenuItemStyles'\n\nexport interface MenuCheckboxItemProps extends Omit<\n ComponentProps<typeof BaseMenu.CheckboxItem>,\n 'render'\n> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * A menu item with checkbox functionality.\n * Can be toggled on and off, allowing multiple selections.\n * The checkbox indicator is automatically rendered on the left side.\n */\nexport const MenuCheckboxItem = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuCheckboxItemProps) => {\n const { renderProp, innerChildren } = createRenderSlot(asChild, children)\n\n return (\n <BaseMenu.CheckboxItem\n ref={ref}\n data-spark-component=\"menu-checkbox-item\"\n render={renderProp}\n className={cx(\n menuItemStyles({\n className,\n }),\n 'data-checked:font-bold'\n )}\n {...rest}\n >\n <BaseMenu.CheckboxItemIndicator\n keepMounted\n className={cx(\n 'mr-md flex shrink-0 items-center justify-center',\n 'w-sz-16 h-sz-16',\n 'transition-opacity',\n 'data-checked:opacity-100',\n 'opacity-0'\n )}\n >\n <Icon size=\"sm\" intent=\"current\">\n <Check />\n </Icon>\n </BaseMenu.CheckboxItemIndicator>\n {innerChildren}\n </BaseMenu.CheckboxItem>\n )\n}\n\nMenuCheckboxItem.displayName = 'Menu.CheckboxItem'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps } from 'react'\n\nexport interface MenuGroupProps extends ComponentProps<typeof BaseMenu.Group> {}\n\n/**\n * A container for grouping related menu items together.\n * Works with Menu.GroupLabel for semantic grouping.\n */\nexport const MenuGroup = ({ children, className, ...rest }: MenuGroupProps) => {\n return (\n <BaseMenu.Group data-spark-component=\"menu-group\" className={cx('py-sm', className)} {...rest}>\n {children}\n </BaseMenu.Group>\n )\n}\n\nMenuGroup.displayName = 'Menu.Group'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { createRenderSlot } from '@spark-ui/internal-utils'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps, type Ref } from 'react'\n\nexport interface MenuGroupLabelProps extends Omit<\n ComponentProps<typeof BaseMenu.GroupLabel>,\n 'render'\n> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * A label for a group of menu items.\n * Provides semantic context and visual separation for grouped items.\n */\nexport const MenuGroupLabel = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuGroupLabelProps) => {\n const { renderProp, innerChildren } = createRenderSlot(asChild, children)\n\n return (\n <BaseMenu.GroupLabel\n ref={ref}\n data-spark-component=\"menu-group-label\"\n render={renderProp}\n className={cx('text-on-surface/dim-1 text-body-2 font-bold', 'px-lg py-sm', className)}\n {...rest}\n >\n {innerChildren}\n </BaseMenu.GroupLabel>\n )\n}\n\nMenuGroupLabel.displayName = 'Menu.GroupLabel'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { createRenderSlot } from '@spark-ui/internal-utils'\nimport { type ComponentProps, type Ref } from 'react'\n\nimport { menuItemStyles } from './MenuItemStyles'\n\nexport interface MenuItemProps extends Omit<ComponentProps<typeof BaseMenu.Item>, 'render'> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * A menu item that triggers an action when activated.\n * Renders a clickable menu option with keyboard support.\n */\nexport const MenuItem = ({ asChild = false, children, className, ref, ...rest }: MenuItemProps) => {\n const { renderProp, innerChildren } = createRenderSlot(asChild, children)\n\n return (\n <BaseMenu.Item\n ref={ref}\n data-spark-component=\"menu-item\"\n render={renderProp}\n className={menuItemStyles({\n className,\n })}\n {...rest}\n >\n {innerChildren}\n </BaseMenu.Item>\n )\n}\n\nMenuItem.displayName = 'Menu.Item'\n","import { Link } from '@spark-ui/icons/Link'\nimport { type ComponentPropsWithoutRef } from 'react'\n\nimport { Icon } from '../icon'\nimport { MenuItem } from './MenuItem'\n\nexport interface MenuLinkItemProps extends Omit<\n ComponentPropsWithoutRef<typeof MenuItem>,\n 'asChild'\n> {\n /**\n * The URL to navigate to.\n */\n href: string\n /**\n * Where to display the linked URL.\n * @default undefined\n */\n target?: string\n /**\n * The relationship between the current document and the linked document.\n * @default undefined\n */\n rel?: string\n}\n\n/**\n * A menu item that acts as a link.\n * Navigates to a URL when activated, useful for navigation menus.\n * Use with Next.js Link or React Router Link via the children prop.\n */\nexport const MenuLinkItem = ({ children, href, target, rel, ...rest }: MenuLinkItemProps) => {\n return (\n <MenuItem asChild {...rest}>\n <a href={href} target={target} rel={rel}>\n <Icon size=\"sm\" intent=\"current\" className=\"ml-auto shrink-0\">\n <Link />\n </Icon>\n <span className=\"flex-1\">{children}</span>\n </a>\n </MenuItem>\n )\n}\n\nMenuLinkItem.displayName = 'Menu.LinkItem'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { createRenderSlot } from '@spark-ui/internal-utils'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps, type Ref } from 'react'\n\nexport interface MenuPopupProps extends Omit<ComponentProps<typeof BaseMenu.Popup>, 'render'> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * The scrollable menu container that holds menu items.\n * Serves as the viewport for menu content with overflow handling.\n */\nexport const MenuPopup = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuPopupProps) => {\n const { renderProp, innerChildren } = createRenderSlot(asChild, children)\n\n return (\n <BaseMenu.Popup\n ref={ref}\n data-spark-component=\"menu-popup\"\n render={renderProp}\n className={cx(\n [\n 'rounded-md bg-surface shadow-lg min-w-sz-192',\n 'p-sm',\n 'overflow-auto',\n 'z-popover',\n 'data-starting-style:opacity-0',\n 'data-ending-style:opacity-0',\n 'opacity-100',\n 'transition-opacity duration-200',\n ],\n className\n )}\n {...rest}\n >\n {innerChildren}\n </BaseMenu.Popup>\n )\n}\n\nMenuPopup.displayName = 'Menu.Popup'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { type ComponentProps } from 'react'\n\nexport interface MenuPortalProps extends ComponentProps<typeof BaseMenu.Portal> {}\n\n/**\n * Portal wrapper that renders the menu in a different part of the DOM tree.\n * Useful for avoiding z-index and overflow issues.\n */\nexport const MenuPortal = ({ children, ...rest }: MenuPortalProps) => {\n return <BaseMenu.Portal {...rest}>{children}</BaseMenu.Portal>\n}\n\nMenuPortal.displayName = 'Menu.Portal'\n","import { createContext, useContext } from 'react'\n\n/**\n * Context to track if we're inside a submenu\n */\nexport const MenuSubmenuContext = createContext<boolean>(false)\n\n/**\n * Hook to check if the current menu is a submenu\n */\nexport const useIsSubmenu = () => {\n return useContext(MenuSubmenuContext)\n}\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { type ComponentProps } from 'react'\n\nimport { useIsSubmenu } from './MenuSubmenuContext'\n\nexport interface MenuPositionerProps extends ComponentProps<typeof BaseMenu.Positioner> {}\n\n/**\n * Positioning wrapper for the menu with collision detection.\n * Handles menu placement relative to the trigger and viewport boundaries.\n */\nexport const MenuPositioner = ({ children, sideOffset, ...rest }: MenuPositionerProps) => {\n const isSubmenu = useIsSubmenu()\n\n // Apply sideOffset of 8 for root menu, 0 for submenus (unless explicitly overridden)\n const defaultSideOffset = isSubmenu ? 0 : 8\n const finalSideOffset = sideOffset ?? defaultSideOffset\n\n return (\n <BaseMenu.Positioner sideOffset={finalSideOffset} {...rest}>\n {children}\n </BaseMenu.Positioner>\n )\n}\n\nMenuPositioner.displayName = 'Menu.Positioner'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps } from 'react'\n\nexport interface MenuRadioGroupProps extends ComponentProps<typeof BaseMenu.RadioGroup> {}\n\n/**\n * A container for radio menu items where only one item can be selected at a time.\n * Manages the selection state for its radio items.\n */\nexport const MenuRadioGroup = ({ children, className, ...rest }: MenuRadioGroupProps) => {\n return (\n <BaseMenu.RadioGroup\n data-spark-component=\"menu-radio-group\"\n className={cx('py-sm', className)}\n {...rest}\n >\n {children}\n </BaseMenu.RadioGroup>\n )\n}\n\nMenuRadioGroup.displayName = 'Menu.RadioGroup'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { Check } from '@spark-ui/icons/Check'\nimport { createRenderSlot } from '@spark-ui/internal-utils'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps, type Ref } from 'react'\n\nimport { Icon } from '../icon'\nimport { menuItemStyles } from './MenuItemStyles'\n\nexport interface MenuRadioItemProps extends Omit<\n ComponentProps<typeof BaseMenu.RadioItem>,\n 'render'\n> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * A menu item with radio button functionality.\n * Only one radio item can be selected within its RadioGroup.\n * The radio indicator is automatically rendered on the left side.\n */\nexport const MenuRadioItem = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuRadioItemProps) => {\n const { renderProp, innerChildren } = createRenderSlot(asChild, children)\n\n return (\n <BaseMenu.RadioItem\n ref={ref}\n data-spark-component=\"menu-radio-item\"\n render={renderProp}\n className={cx(\n menuItemStyles({\n className,\n }),\n 'data-checked:font-bold'\n )}\n {...rest}\n >\n <BaseMenu.RadioItemIndicator\n keepMounted\n className={cx(\n 'mr-md flex shrink-0 items-center justify-center',\n 'w-sz-16 h-sz-16',\n 'transition-opacity',\n 'data-checked:opacity-100',\n 'opacity-0'\n )}\n >\n <Icon size=\"sm\" intent=\"current\">\n <Check />\n </Icon>\n </BaseMenu.RadioItemIndicator>\n {innerChildren}\n </BaseMenu.RadioItem>\n )\n}\n\nMenuRadioItem.displayName = 'Menu.RadioItem'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { cx } from 'class-variance-authority'\nimport { type ComponentProps } from 'react'\n\nexport interface MenuSeparatorProps extends ComponentProps<typeof BaseMenu.Separator> {}\n\n/**\n * A visual divider between menu items or groups.\n * Creates clear separation between different sections of the menu.\n */\nexport const MenuSeparator = ({ className, ...rest }: MenuSeparatorProps) => {\n return (\n <BaseMenu.Separator\n data-spark-component=\"menu-separator\"\n className={cx('my-sm h-px bg-outline/dim-2', className)}\n {...rest}\n />\n )\n}\n\nMenuSeparator.displayName = 'Menu.Separator'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { type ComponentProps, type ReactNode } from 'react'\n\nimport { MenuSubmenuContext } from './MenuSubmenuContext'\n\nexport interface MenuSubmenuProps extends Omit<\n ComponentProps<typeof BaseMenu.SubmenuRoot>,\n 'children'\n> {\n /**\n * The content of the submenu (trigger, positioner, popup, etc.)\n */\n children: ReactNode\n}\n\n/**\n * A nested submenu that appears when its trigger is activated.\n * Inherits styling context from the parent menu.\n */\nexport const MenuSubmenu = ({ children, ...rest }: MenuSubmenuProps) => {\n return (\n <BaseMenu.SubmenuRoot data-spark-component=\"menu-submenu\" {...rest}>\n <MenuSubmenuContext value={true}>{children}</MenuSubmenuContext>\n </BaseMenu.SubmenuRoot>\n )\n}\n\nMenuSubmenu.displayName = 'Menu.Submenu'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { ArrowVerticalRight } from '@spark-ui/icons/ArrowVerticalRight'\nimport { createRenderSlot } from '@spark-ui/internal-utils'\nimport { type ComponentProps, type Ref } from 'react'\n\nimport { Icon } from '../icon'\nimport { menuItemStyles } from './MenuItemStyles'\n\nexport interface MenuSubmenuTriggerProps extends Omit<\n ComponentProps<typeof BaseMenu.SubmenuTrigger>,\n 'render'\n> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLDivElement>\n}\n\n/**\n * A menu item that opens a submenu when activated.\n * Displays an arrow indicator to show submenu availability.\n */\nexport const MenuSubmenuTrigger = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuSubmenuTriggerProps) => {\n const { renderProp, innerChildren } = createRenderSlot(asChild, children)\n\n return (\n <BaseMenu.SubmenuTrigger\n ref={ref}\n data-spark-component=\"menu-submenu-trigger\"\n render={renderProp}\n className={menuItemStyles({\n className,\n })}\n {...rest}\n >\n <span className=\"flex-1\">{innerChildren}</span>\n <Icon size=\"sm\" intent=\"current\" className=\"ml-auto shrink-0\">\n <ArrowVerticalRight />\n </Icon>\n </BaseMenu.SubmenuTrigger>\n )\n}\n\nMenuSubmenuTrigger.displayName = 'Menu.SubmenuTrigger'\n","import { Menu as BaseMenu } from '@base-ui/react/menu'\nimport { ArrowHorizontalDown } from '@spark-ui/icons/ArrowHorizontalDown'\nimport { createRenderSlot } from '@spark-ui/internal-utils'\nimport { cx } from 'class-variance-authority'\nimport {\n cloneElement,\n isValidElement,\n type ComponentProps,\n type ReactElement,\n type Ref,\n} from 'react'\n\nimport { Icon } from '../icon'\n\nexport interface MenuTriggerProps extends Omit<ComponentProps<typeof BaseMenu.Trigger>, 'render'> {\n /**\n * Change the component to the HTML tag or custom component of the only child.\n * This will merge the original component props with the props of the supplied element/component and change the underlying DOM node.\n * @default false\n */\n asChild?: boolean\n ref?: Ref<HTMLButtonElement>\n}\n\n/**\n * The button that toggles the menu.\n * Renders a <button> element by default, or uses asChild for custom elements.\n * When used with asChild and a Button component, automatically adds an ArrowHorizontalDown icon.\n * Button components should use design=\"outlined\" and intent=\"support\".\n */\nexport const MenuTrigger = ({\n asChild = false,\n children,\n className,\n ref,\n ...rest\n}: MenuTriggerProps) => {\n // When asChild is used with a Button, enhance it with the arrow icon\n const enhancedChildren =\n asChild && isValidElement(children)\n ? cloneElement(\n children as ReactElement,\n {\n design: (children.props as { design?: string }).design ?? 'outlined',\n intent: (children.props as { intent?: string }).intent ?? 'support',\n children: (\n <>\n {(children.props as { children: React.ReactNode }).children}\n <Icon size=\"sm\" intent=\"current\" className=\"shrink-0\">\n <ArrowHorizontalDown />\n </Icon>\n </>\n ),\n } as Partial<unknown>\n )\n : children\n\n const { renderProp, innerChildren } = createRenderSlot(asChild, enhancedChildren)\n\n return (\n <BaseMenu.Trigger\n ref={ref}\n data-spark-component=\"menu-trigger\"\n render={renderProp}\n className={cx(\n 'inline-flex items-center justify-center',\n 'focus-visible:u-outline',\n className\n )}\n {...rest}\n >\n {innerChildren}\n </BaseMenu.Trigger>\n )\n}\n\nMenuTrigger.displayName = 'Menu.Trigger'\n","import { Menu as Root } from './Menu'\nimport { MenuCheckboxItem } from './MenuCheckboxItem'\nimport { MenuGroup } from './MenuGroup'\nimport { MenuGroupLabel } from './MenuGroupLabel'\nimport { MenuItem } from './MenuItem'\nimport { MenuLinkItem } from './MenuLinkItem'\nimport { MenuPopup } from './MenuPopup'\nimport { MenuPortal } from './MenuPortal'\nimport { MenuPositioner } from './MenuPositioner'\nimport { MenuRadioGroup } from './MenuRadioGroup'\nimport { MenuRadioItem } from './MenuRadioItem'\nimport { MenuSeparator } from './MenuSeparator'\nimport { MenuSubmenu } from './MenuSubmenu'\nimport { MenuSubmenuTrigger } from './MenuSubmenuTrigger'\nimport { MenuTrigger } from './MenuTrigger'\n\n/**\n * A menu component that enables users to select options from a dropdown menu triggered by a button or other interactive element.\n */\nexport const Menu: typeof Root & {\n Trigger: typeof MenuTrigger\n Portal: typeof MenuPortal\n Positioner: typeof MenuPositioner\n Popup: typeof MenuPopup\n Item: typeof MenuItem\n LinkItem: typeof MenuLinkItem\n Submenu: typeof MenuSubmenu\n SubmenuTrigger: typeof MenuSubmenuTrigger\n Group: typeof MenuGroup\n GroupLabel: typeof MenuGroupLabel\n RadioGroup: typeof MenuRadioGroup\n RadioItem: typeof MenuRadioItem\n CheckboxItem: typeof MenuCheckboxItem\n Separator: typeof MenuSeparator\n} = Object.assign(Root, {\n Trigger: MenuTrigger,\n Portal: MenuPortal,\n Positioner: MenuPositioner,\n Popup: MenuPopup,\n Item: MenuItem,\n LinkItem: MenuLinkItem,\n Submenu: MenuSubmenu,\n SubmenuTrigger: MenuSubmenuTrigger,\n Group: MenuGroup,\n GroupLabel: MenuGroupLabel,\n RadioGroup: MenuRadioGroup,\n RadioItem: MenuRadioItem,\n CheckboxItem: MenuCheckboxItem,\n Separator: MenuSeparator,\n})\n\nMenu.displayName = 'Menu'\nMenuTrigger.displayName = 'Menu.Trigger'\nMenuPortal.displayName = 'Menu.Portal'\nMenuPositioner.displayName = 'Menu.Positioner'\nMenuPopup.displayName = 'Menu.Popup'\nMenuItem.displayName = 'Menu.Item'\nMenuLinkItem.displayName = 'Menu.LinkItem'\nMenuSubmenu.displayName = 'Menu.Submenu'\nMenuSubmenuTrigger.displayName = 'Menu.SubmenuTrigger'\nMenuGroup.displayName = 'Menu.Group'\nMenuGroupLabel.displayName = 'Menu.GroupLabel'\nMenuRadioGroup.displayName = 'Menu.RadioGroup'\nMenuRadioItem.displayName = 'Menu.RadioItem'\nMenuCheckboxItem.displayName = 'Menu.CheckboxItem'\nMenuSeparator.displayName = 'Menu.Separator'\n\nexport { type MenuProps } from './Menu'\nexport { type MenuTriggerProps } from './MenuTrigger'\nexport { type MenuPortalProps } from './MenuPortal'\nexport { type MenuPositionerProps } from './MenuPositioner'\nexport { type MenuPopupProps } from './MenuPopup'\nexport { type MenuItemProps } from './MenuItem'\nexport { type MenuLinkItemProps } from './MenuLinkItem'\nexport { type MenuSubmenuProps } from './MenuSubmenu'\nexport { type MenuSubmenuTriggerProps } from './MenuSubmenuTrigger'\nexport { type MenuGroupProps } from './MenuGroup'\nexport { type MenuGroupLabelProps } from './MenuGroupLabel'\nexport { type MenuRadioGroupProps } from './MenuRadioGroup'\nexport { type MenuRadioItemProps } from './MenuRadioItem'\nexport { type MenuCheckboxItemProps } from './MenuCheckboxItem'\nexport { type MenuSeparatorProps } from './MenuSeparator'\n"],"mappings":"mbAaA,IAAa,GAAQ,CAAE,WAAU,GAAG,MAEhC,EAAA,EAAA,IAAA,CAAC,EAAA,KAAS,KAAV,CAAe,uBAAqB,OAAO,GAAI,EAC5C,UACY,CAAA,EAInB,EAAK,YAAc,OClBnB,IAAa,GAAA,EAAA,EAAA,IAAA,CACX,CACE,+DACA,wBACA,iCACA,eACA,0DACA,+DACA,cACA,cACA,sCACA,oCACF,EACA,CACE,SAAU,CACR,QAAA,EAAA,EAAA,aAAA,CAGE,CACA,QAAS,CAAC,iBAAiB,EAC3B,KAAM,CAAC,iBAAiB,EACxB,QAAS,CAAC,iBAAiB,EAC3B,OAAQ,CAAC,iBAAiB,EAC1B,QAAS,CAAC,iBAAiB,EAC3B,MAAO,CAAC,iBAAiB,EACzB,OAAQ,CAAC,iBAAiB,EAC1B,KAAM,CAAC,iBAAiB,EACxB,QAAS,CAAC,iBAAiB,CAC7B,CAAC,CACH,EACA,gBAAiB,CACf,OAAQ,SACV,CACF,CACF,ECVa,GAAoB,CAC/B,UAAU,GACV,WACA,YACA,MACA,GAAG,KACwB,CAC3B,GAAM,CAAE,aAAY,kBAAA,EAAA,EAAA,iBAAA,CAAmC,EAAS,CAAQ,EAExE,OACE,EAAA,EAAA,KAAA,CAAC,EAAA,KAAS,aAAV,CACO,MACL,uBAAqB,qBACrB,OAAQ,EACR,WAAA,EAAA,EAAA,GAAA,CACE,EAAe,CACb,WACF,CAAC,EACD,wBACF,EACA,GAAI,WAVN,EAYE,EAAA,EAAA,IAAA,CAAC,EA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AY,EACZ,MAAO,EACP,KAAM,EACN,SAAU,EACV,QAAS,EACT,eAAgB,EAChB,MAAO,EACP,WAAY,EACZ,WAAY,EACZ,UAAW,EACX,aAAc,EACd,UAAW,CACb,CAAC,EAED,EAAK,YAAc,OACnB,EAAY,YAAc,eAC1B,EAAW,YAAc,cACzB,EAAe,YAAc,kBAC7B,EAAU,YAAc,aACxB,EAAS,YAAc,YACvB,EAAa,YAAc,gBAC3B,EAAY,YAAc,eAC1B,EAAmB,YAAc,sBACjC,EAAU,YAAc,aACxB,EAAe,YAAc,kBAC7B,EAAe,YAAc,kBAC7B,EAAc,YAAc,iBAC5B,EAAiB,YAAc,oBAC/B,EAAc,YAAc"}
@@ -1,16 +1,15 @@
1
- import { Slot as e } from "../slot/index.mjs";
2
- import { t } from "../icon-Bs-39J-H.mjs";
3
- import { cva as n, cx as r } from "class-variance-authority";
4
- import { cloneElement as i, createContext as a, isValidElement as o, useContext as s } from "react";
5
- import { Fragment as c, jsx as l, jsxs as u } from "react/jsx-runtime";
6
- import { ArrowHorizontalDown as d } from "@spark-ui/icons/ArrowHorizontalDown";
7
- import { makeVariants as f } from "@spark-ui/internal-utils";
1
+ import { t as e } from "../icon-VM_Ys9Xn.mjs";
2
+ import { createRenderSlot as t, makeVariants as n } from "@spark-ui/internal-utils";
3
+ import { cva as r, cx as i } from "class-variance-authority";
4
+ import { cloneElement as a, createContext as o, isValidElement as s, useContext as c } from "react";
5
+ import { Fragment as l, jsx as u, jsxs as d } from "react/jsx-runtime";
6
+ import { ArrowHorizontalDown as f } from "@spark-ui/icons/ArrowHorizontalDown";
8
7
  import { ArrowVerticalRight as p } from "@spark-ui/icons/ArrowVerticalRight";
9
8
  import { Check as m } from "@spark-ui/icons/Check";
10
9
  import { Menu as h } from "@base-ui/react/menu";
11
10
  import { Link as g } from "@spark-ui/icons/Link";
12
11
  //#region src/menu/Menu.tsx
13
- var _ = ({ children: e, ...t }) => /* @__PURE__ */ l(h.Root, {
12
+ var _ = ({ children: e, ...t }) => /* @__PURE__ */ u(h.Root, {
14
13
  "data-spark-component": "menu",
15
14
  ...t,
16
15
  children: e
@@ -18,7 +17,7 @@ var _ = ({ children: e, ...t }) => /* @__PURE__ */ l(h.Root, {
18
17
  _.displayName = "Menu";
19
18
  //#endregion
20
19
  //#region src/menu/MenuItemStyles.tsx
21
- var v = n([
20
+ var v = r([
22
21
  "gap-md flex w-full cursor-pointer items-center justify-start",
23
22
  "text-left text-body-1",
24
23
  "transition-colors duration-100",
@@ -30,7 +29,7 @@ var v = n([
30
29
  "data-highlighted:bg-surface-hovered",
31
30
  "data-popup-open:bg-surface-hovered"
32
31
  ], {
33
- variants: { intent: f({
32
+ variants: { intent: n({
34
33
  surface: ["text-on-surface"],
35
34
  main: ["text-on-surface"],
36
35
  support: ["text-on-surface"],
@@ -42,101 +41,93 @@ var v = n([
42
41
  neutral: ["text-on-surface"]
43
42
  }) },
44
43
  defaultVariants: { intent: "surface" }
45
- });
46
- //#endregion
47
- //#region src/menu/useRenderSlot.tsx
48
- function y(t) {
49
- return t ? ({ ...t }) => /* @__PURE__ */ l(e, { ...t }) : void 0;
50
- }
51
- //#endregion
52
- //#region src/menu/MenuCheckboxItem.tsx
53
- var b = ({ asChild: e = !1, children: n, className: i, ref: a, ...o }) => {
54
- let s = y(e);
55
- return /* @__PURE__ */ u(h.CheckboxItem, {
56
- ref: a,
44
+ }), y = ({ asChild: n = !1, children: r, className: a, ref: o, ...s }) => {
45
+ let { renderProp: c, innerChildren: l } = t(n, r);
46
+ return /* @__PURE__ */ d(h.CheckboxItem, {
47
+ ref: o,
57
48
  "data-spark-component": "menu-checkbox-item",
58
- render: s,
59
- className: r(v({ className: i }), "data-checked:font-bold"),
60
- ...o,
61
- children: [/* @__PURE__ */ l(h.CheckboxItemIndicator, {
49
+ render: c,
50
+ className: i(v({ className: a }), "data-checked:font-bold"),
51
+ ...s,
52
+ children: [/* @__PURE__ */ u(h.CheckboxItemIndicator, {
62
53
  keepMounted: !0,
63
- className: r("mr-md flex shrink-0 items-center justify-center", "w-sz-16 h-sz-16", "transition-opacity", "data-checked:opacity-100", "opacity-0"),
64
- children: /* @__PURE__ */ l(t, {
54
+ className: i("mr-md flex shrink-0 items-center justify-center", "w-sz-16 h-sz-16", "transition-opacity", "data-checked:opacity-100", "opacity-0"),
55
+ children: /* @__PURE__ */ u(e, {
65
56
  size: "sm",
66
57
  intent: "current",
67
- children: /* @__PURE__ */ l(m, {})
58
+ children: /* @__PURE__ */ u(m, {})
68
59
  })
69
- }), n]
60
+ }), l]
70
61
  });
71
62
  };
72
- b.displayName = "Menu.CheckboxItem";
63
+ y.displayName = "Menu.CheckboxItem";
73
64
  //#endregion
74
65
  //#region src/menu/MenuGroup.tsx
75
- var x = ({ children: e, className: t, ...n }) => /* @__PURE__ */ l(h.Group, {
66
+ var b = ({ children: e, className: t, ...n }) => /* @__PURE__ */ u(h.Group, {
76
67
  "data-spark-component": "menu-group",
77
- className: r("py-sm", t),
68
+ className: i("py-sm", t),
78
69
  ...n,
79
70
  children: e
80
71
  });
81
- x.displayName = "Menu.Group";
72
+ b.displayName = "Menu.Group";
82
73
  //#endregion
83
74
  //#region src/menu/MenuGroupLabel.tsx
84
- var S = ({ asChild: e = !1, children: t, className: n, ref: i, ...a }) => {
85
- let o = y(e);
86
- return /* @__PURE__ */ l(h.GroupLabel, {
87
- ref: i,
75
+ var x = ({ asChild: e = !1, children: n, className: r, ref: a, ...o }) => {
76
+ let { renderProp: s, innerChildren: c } = t(e, n);
77
+ return /* @__PURE__ */ u(h.GroupLabel, {
78
+ ref: a,
88
79
  "data-spark-component": "menu-group-label",
89
- render: o,
90
- className: r("text-on-surface/dim-1 text-body-2 font-bold", "px-lg py-sm", n),
91
- ...a,
92
- children: t
80
+ render: s,
81
+ className: i("text-on-surface/dim-1 text-body-2 font-bold", "px-lg py-sm", r),
82
+ ...o,
83
+ children: c
93
84
  });
94
85
  };
95
- S.displayName = "Menu.GroupLabel";
86
+ x.displayName = "Menu.GroupLabel";
96
87
  //#endregion
97
88
  //#region src/menu/MenuItem.tsx
98
- var C = ({ asChild: e = !1, children: t, className: n, ref: r, ...i }) => {
99
- let a = y(e);
100
- return /* @__PURE__ */ l(h.Item, {
101
- ref: r,
89
+ var S = ({ asChild: e = !1, children: n, className: r, ref: i, ...a }) => {
90
+ let { renderProp: o, innerChildren: s } = t(e, n);
91
+ return /* @__PURE__ */ u(h.Item, {
92
+ ref: i,
102
93
  "data-spark-component": "menu-item",
103
- render: a,
104
- className: v({ className: n }),
105
- ...i,
106
- children: t
94
+ render: o,
95
+ className: v({ className: r }),
96
+ ...a,
97
+ children: s
107
98
  });
108
99
  };
109
- C.displayName = "Menu.Item";
100
+ S.displayName = "Menu.Item";
110
101
  //#endregion
111
102
  //#region src/menu/MenuLinkItem.tsx
112
- var w = ({ children: e, href: n, target: r, rel: i, ...a }) => /* @__PURE__ */ l(C, {
103
+ var C = ({ children: t, href: n, target: r, rel: i, ...a }) => /* @__PURE__ */ u(S, {
113
104
  asChild: !0,
114
105
  ...a,
115
- children: /* @__PURE__ */ u("a", {
106
+ children: /* @__PURE__ */ d("a", {
116
107
  href: n,
117
108
  target: r,
118
109
  rel: i,
119
- children: [/* @__PURE__ */ l(t, {
110
+ children: [/* @__PURE__ */ u(e, {
120
111
  size: "sm",
121
112
  intent: "current",
122
113
  className: "ml-auto shrink-0",
123
- children: /* @__PURE__ */ l(g, {})
124
- }), /* @__PURE__ */ l("span", {
114
+ children: /* @__PURE__ */ u(g, {})
115
+ }), /* @__PURE__ */ u("span", {
125
116
  className: "flex-1",
126
- children: e
117
+ children: t
127
118
  })]
128
119
  })
129
120
  });
130
- w.displayName = "Menu.LinkItem";
121
+ C.displayName = "Menu.LinkItem";
131
122
  //#endregion
132
123
  //#region src/menu/MenuPopup.tsx
133
- var T = ({ asChild: e = !1, children: t, className: n, ref: i, ...a }) => {
134
- let o = y(e);
135
- return /* @__PURE__ */ l(h.Popup, {
136
- ref: i,
124
+ var w = ({ asChild: e = !1, children: n, className: r, ref: a, ...o }) => {
125
+ let { renderProp: s, innerChildren: c } = t(e, n);
126
+ return /* @__PURE__ */ u(h.Popup, {
127
+ ref: a,
137
128
  "data-spark-component": "menu-popup",
138
- render: o,
139
- className: r([
129
+ render: s,
130
+ className: i([
140
131
  "rounded-md bg-surface shadow-lg min-w-sz-192",
141
132
  "p-sm",
142
133
  "overflow-auto",
@@ -145,145 +136,145 @@ var T = ({ asChild: e = !1, children: t, className: n, ref: i, ...a }) => {
145
136
  "data-ending-style:opacity-0",
146
137
  "opacity-100",
147
138
  "transition-opacity duration-200"
148
- ], n),
149
- ...a,
150
- children: t
139
+ ], r),
140
+ ...o,
141
+ children: c
151
142
  });
152
143
  };
153
- T.displayName = "Menu.Popup";
144
+ w.displayName = "Menu.Popup";
154
145
  //#endregion
155
146
  //#region src/menu/MenuPortal.tsx
156
- var E = ({ children: e, ...t }) => /* @__PURE__ */ l(h.Portal, {
147
+ var T = ({ children: e, ...t }) => /* @__PURE__ */ u(h.Portal, {
157
148
  ...t,
158
149
  children: e
159
150
  });
160
- E.displayName = "Menu.Portal";
151
+ T.displayName = "Menu.Portal";
161
152
  //#endregion
162
153
  //#region src/menu/MenuSubmenuContext.tsx
163
- var D = a(!1), O = () => s(D), k = ({ children: e, sideOffset: t, ...n }) => {
164
- let r = O() ? 0 : 8, i = t ?? r;
165
- return /* @__PURE__ */ l(h.Positioner, {
154
+ var E = o(!1), D = () => c(E), O = ({ children: e, sideOffset: t, ...n }) => {
155
+ let r = D() ? 0 : 8, i = t ?? r;
156
+ return /* @__PURE__ */ u(h.Positioner, {
166
157
  sideOffset: i,
167
158
  ...n,
168
159
  children: e
169
160
  });
170
161
  };
171
- k.displayName = "Menu.Positioner";
162
+ O.displayName = "Menu.Positioner";
172
163
  //#endregion
173
164
  //#region src/menu/MenuRadioGroup.tsx
174
- var A = ({ children: e, className: t, ...n }) => /* @__PURE__ */ l(h.RadioGroup, {
165
+ var k = ({ children: e, className: t, ...n }) => /* @__PURE__ */ u(h.RadioGroup, {
175
166
  "data-spark-component": "menu-radio-group",
176
- className: r("py-sm", t),
167
+ className: i("py-sm", t),
177
168
  ...n,
178
169
  children: e
179
170
  });
180
- A.displayName = "Menu.RadioGroup";
171
+ k.displayName = "Menu.RadioGroup";
181
172
  //#endregion
182
173
  //#region src/menu/MenuRadioItem.tsx
183
- var j = ({ asChild: e = !1, children: n, className: i, ref: a, ...o }) => {
184
- let s = y(e);
185
- return /* @__PURE__ */ u(h.RadioItem, {
186
- ref: a,
174
+ var A = ({ asChild: n = !1, children: r, className: a, ref: o, ...s }) => {
175
+ let { renderProp: c, innerChildren: l } = t(n, r);
176
+ return /* @__PURE__ */ d(h.RadioItem, {
177
+ ref: o,
187
178
  "data-spark-component": "menu-radio-item",
188
- render: s,
189
- className: r(v({ className: i }), "data-checked:font-bold"),
190
- ...o,
191
- children: [/* @__PURE__ */ l(h.RadioItemIndicator, {
179
+ render: c,
180
+ className: i(v({ className: a }), "data-checked:font-bold"),
181
+ ...s,
182
+ children: [/* @__PURE__ */ u(h.RadioItemIndicator, {
192
183
  keepMounted: !0,
193
- className: r("mr-md flex shrink-0 items-center justify-center", "w-sz-16 h-sz-16", "transition-opacity", "data-checked:opacity-100", "opacity-0"),
194
- children: /* @__PURE__ */ l(t, {
184
+ className: i("mr-md flex shrink-0 items-center justify-center", "w-sz-16 h-sz-16", "transition-opacity", "data-checked:opacity-100", "opacity-0"),
185
+ children: /* @__PURE__ */ u(e, {
195
186
  size: "sm",
196
187
  intent: "current",
197
- children: /* @__PURE__ */ l(m, {})
188
+ children: /* @__PURE__ */ u(m, {})
198
189
  })
199
- }), n]
190
+ }), l]
200
191
  });
201
192
  };
202
- j.displayName = "Menu.RadioItem";
193
+ A.displayName = "Menu.RadioItem";
203
194
  //#endregion
204
195
  //#region src/menu/MenuSeparator.tsx
205
- var M = ({ className: e, ...t }) => /* @__PURE__ */ l(h.Separator, {
196
+ var j = ({ className: e, ...t }) => /* @__PURE__ */ u(h.Separator, {
206
197
  "data-spark-component": "menu-separator",
207
- className: r("my-sm h-px bg-outline/dim-2", e),
198
+ className: i("my-sm h-px bg-outline/dim-2", e),
208
199
  ...t
209
200
  });
210
- M.displayName = "Menu.Separator";
201
+ j.displayName = "Menu.Separator";
211
202
  //#endregion
212
203
  //#region src/menu/MenuSubmenu.tsx
213
- var N = ({ children: e, ...t }) => /* @__PURE__ */ l(h.SubmenuRoot, {
204
+ var M = ({ children: e, ...t }) => /* @__PURE__ */ u(h.SubmenuRoot, {
214
205
  "data-spark-component": "menu-submenu",
215
206
  ...t,
216
- children: /* @__PURE__ */ l(D, {
207
+ children: /* @__PURE__ */ u(E, {
217
208
  value: !0,
218
209
  children: e
219
210
  })
220
211
  });
221
- N.displayName = "Menu.Submenu";
212
+ M.displayName = "Menu.Submenu";
222
213
  //#endregion
223
214
  //#region src/menu/MenuSubmenuTrigger.tsx
224
- var P = ({ asChild: e = !1, children: n, className: r, ref: i, ...a }) => {
225
- let o = y(e);
226
- return /* @__PURE__ */ u(h.SubmenuTrigger, {
227
- ref: i,
215
+ var N = ({ asChild: n = !1, children: r, className: i, ref: a, ...o }) => {
216
+ let { renderProp: s, innerChildren: c } = t(n, r);
217
+ return /* @__PURE__ */ d(h.SubmenuTrigger, {
218
+ ref: a,
228
219
  "data-spark-component": "menu-submenu-trigger",
229
- render: o,
230
- className: v({ className: r }),
231
- ...a,
232
- children: [/* @__PURE__ */ l("span", {
220
+ render: s,
221
+ className: v({ className: i }),
222
+ ...o,
223
+ children: [/* @__PURE__ */ u("span", {
233
224
  className: "flex-1",
234
- children: n
235
- }), /* @__PURE__ */ l(t, {
225
+ children: c
226
+ }), /* @__PURE__ */ u(e, {
236
227
  size: "sm",
237
228
  intent: "current",
238
229
  className: "ml-auto shrink-0",
239
- children: /* @__PURE__ */ l(p, {})
230
+ children: /* @__PURE__ */ u(p, {})
240
231
  })]
241
232
  });
242
233
  };
243
- P.displayName = "Menu.SubmenuTrigger";
234
+ N.displayName = "Menu.SubmenuTrigger";
244
235
  //#endregion
245
236
  //#region src/menu/MenuTrigger.tsx
246
- var F = ({ asChild: e = !1, children: n, className: a, ref: s, ...f }) => {
247
- let p = y(e), m = e && o(n) ? i(n, {
248
- design: n.props.design ?? "outlined",
249
- intent: n.props.intent ?? "support",
250
- children: /* @__PURE__ */ u(c, { children: [n.props.children, /* @__PURE__ */ l(t, {
237
+ var P = ({ asChild: n = !1, children: r, className: o, ref: c, ...p }) => {
238
+ let { renderProp: m, innerChildren: g } = t(n, n && s(r) ? a(r, {
239
+ design: r.props.design ?? "outlined",
240
+ intent: r.props.intent ?? "support",
241
+ children: /* @__PURE__ */ d(l, { children: [r.props.children, /* @__PURE__ */ u(e, {
251
242
  size: "sm",
252
243
  intent: "current",
253
244
  className: "shrink-0",
254
- children: /* @__PURE__ */ l(d, {})
245
+ children: /* @__PURE__ */ u(f, {})
255
246
  })] })
256
- }) : n;
257
- return /* @__PURE__ */ l(h.Trigger, {
258
- ref: s,
247
+ }) : r);
248
+ return /* @__PURE__ */ u(h.Trigger, {
249
+ ref: c,
259
250
  "data-spark-component": "menu-trigger",
260
- render: p,
261
- className: r("inline-flex items-center justify-center", "focus-visible:u-outline", a),
262
- ...f,
263
- children: m
251
+ render: m,
252
+ className: i("inline-flex items-center justify-center", "focus-visible:u-outline", o),
253
+ ...p,
254
+ children: g
264
255
  });
265
256
  };
266
- F.displayName = "Menu.Trigger";
257
+ P.displayName = "Menu.Trigger";
267
258
  //#endregion
268
259
  //#region src/menu/index.ts
269
- var I = Object.assign(_, {
270
- Trigger: F,
271
- Portal: E,
272
- Positioner: k,
273
- Popup: T,
274
- Item: C,
275
- LinkItem: w,
276
- Submenu: N,
277
- SubmenuTrigger: P,
278
- Group: x,
279
- GroupLabel: S,
280
- RadioGroup: A,
281
- RadioItem: j,
282
- CheckboxItem: b,
283
- Separator: M
260
+ var F = Object.assign(_, {
261
+ Trigger: P,
262
+ Portal: T,
263
+ Positioner: O,
264
+ Popup: w,
265
+ Item: S,
266
+ LinkItem: C,
267
+ Submenu: M,
268
+ SubmenuTrigger: N,
269
+ Group: b,
270
+ GroupLabel: x,
271
+ RadioGroup: k,
272
+ RadioItem: A,
273
+ CheckboxItem: y,
274
+ Separator: j
284
275
  });
285
- I.displayName = "Menu", F.displayName = "Menu.Trigger", E.displayName = "Menu.Portal", k.displayName = "Menu.Positioner", T.displayName = "Menu.Popup", C.displayName = "Menu.Item", w.displayName = "Menu.LinkItem", N.displayName = "Menu.Submenu", P.displayName = "Menu.SubmenuTrigger", x.displayName = "Menu.Group", S.displayName = "Menu.GroupLabel", A.displayName = "Menu.RadioGroup", j.displayName = "Menu.RadioItem", b.displayName = "Menu.CheckboxItem", M.displayName = "Menu.Separator";
276
+ F.displayName = "Menu", P.displayName = "Menu.Trigger", T.displayName = "Menu.Portal", O.displayName = "Menu.Positioner", w.displayName = "Menu.Popup", S.displayName = "Menu.Item", C.displayName = "Menu.LinkItem", M.displayName = "Menu.Submenu", N.displayName = "Menu.SubmenuTrigger", b.displayName = "Menu.Group", x.displayName = "Menu.GroupLabel", k.displayName = "Menu.RadioGroup", A.displayName = "Menu.RadioItem", y.displayName = "Menu.CheckboxItem", j.displayName = "Menu.Separator";
286
277
  //#endregion
287
- export { I as Menu };
278
+ export { F as Menu };
288
279
 
289
280
  //# sourceMappingURL=index.mjs.map