@ngrok/mantle 0.59.0 → 0.60.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 (73) hide show
  1. package/dist/alert-dialog.js +1 -1
  2. package/dist/alert-dialog.js.map +1 -1
  3. package/dist/alert.js +1 -1
  4. package/dist/alert.js.map +1 -1
  5. package/dist/anchor.js +1 -1
  6. package/dist/anchor.js.map +1 -1
  7. package/dist/badge.js +1 -1
  8. package/dist/badge.js.map +1 -1
  9. package/dist/button.js +1 -1
  10. package/dist/calendar.js +1 -1
  11. package/dist/calendar.js.map +1 -1
  12. package/dist/card.js +1 -1
  13. package/dist/card.js.map +1 -1
  14. package/dist/{chunk-GPMVEDRP.js → chunk-4IX2UWKO.js} +2 -2
  15. package/dist/chunk-BRV6XRNS.js +2 -0
  16. package/dist/chunk-BRV6XRNS.js.map +1 -0
  17. package/dist/chunk-DRVKSKOI.js +2 -0
  18. package/dist/chunk-DRVKSKOI.js.map +1 -0
  19. package/dist/{chunk-5QSZM7K4.js → chunk-EVAIBP32.js} +2 -2
  20. package/dist/chunk-OE4YWO7O.js +2 -0
  21. package/dist/chunk-OE4YWO7O.js.map +1 -0
  22. package/dist/chunk-UKS7NFNC.js +2 -0
  23. package/dist/chunk-UKS7NFNC.js.map +1 -0
  24. package/dist/chunk-UNFO4DZV.js +2 -0
  25. package/dist/chunk-UNFO4DZV.js.map +1 -0
  26. package/dist/chunk-YKYEISYH.js +2 -0
  27. package/dist/chunk-YKYEISYH.js.map +1 -0
  28. package/dist/code-block.d.ts +1 -1
  29. package/dist/code-block.js +1 -1
  30. package/dist/code-block.js.map +1 -1
  31. package/dist/combobox.js +1 -1
  32. package/dist/combobox.js.map +1 -1
  33. package/dist/command.js +1 -1
  34. package/dist/command.js.map +1 -1
  35. package/dist/data-table.js +1 -1
  36. package/dist/data-table.js.map +1 -1
  37. package/dist/dialog.js +1 -1
  38. package/dist/dropdown-menu.js +1 -1
  39. package/dist/dropdown-menu.js.map +1 -1
  40. package/dist/media-object.js +1 -1
  41. package/dist/media-object.js.map +1 -1
  42. package/dist/pagination.js +1 -1
  43. package/dist/pagination.js.map +1 -1
  44. package/dist/radio-group.d.ts +3 -3
  45. package/dist/radio-group.js +1 -1
  46. package/dist/radio-group.js.map +1 -1
  47. package/dist/sandboxed-on-click.js +1 -1
  48. package/dist/sandboxed-on-click.js.map +1 -1
  49. package/dist/select.js +1 -1
  50. package/dist/separator.js +1 -1
  51. package/dist/sheet.js +1 -1
  52. package/dist/sheet.js.map +1 -1
  53. package/dist/skeleton.js +1 -1
  54. package/dist/skeleton.js.map +1 -1
  55. package/dist/slot.d.ts +20 -0
  56. package/dist/slot.js +2 -0
  57. package/dist/slot.js.map +1 -0
  58. package/dist/toast.js +1 -1
  59. package/dist/tooltip.d.ts +7 -7
  60. package/dist/tooltip.js.map +1 -1
  61. package/package.json +8 -3
  62. package/dist/chunk-4DVFVPF2.js +0 -2
  63. package/dist/chunk-4DVFVPF2.js.map +0 -1
  64. package/dist/chunk-BWGCYXLX.js +0 -2
  65. package/dist/chunk-BWGCYXLX.js.map +0 -1
  66. package/dist/chunk-QXNUFNG4.js +0 -2
  67. package/dist/chunk-QXNUFNG4.js.map +0 -1
  68. package/dist/chunk-VIKPHWPP.js +0 -2
  69. package/dist/chunk-VIKPHWPP.js.map +0 -1
  70. package/dist/chunk-WY3TZBNK.js +0 -2
  71. package/dist/chunk-WY3TZBNK.js.map +0 -1
  72. /package/dist/{chunk-GPMVEDRP.js.map → chunk-4IX2UWKO.js.map} +0 -0
  73. /package/dist/{chunk-5QSZM7K4.js.map → chunk-EVAIBP32.js.map} +0 -0
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/components/radio-group/radio-group.tsx"],"sourcesContent":["\"use client\";\n\nimport {\n\tRadio as HeadlessRadio,\n\tRadioGroup as HeadlessRadioGroup,\n} from \"@headlessui/react\";\nimport type {\n\tRadioGroupProps as HeadlessRadioGroupProps,\n\tRadioProps as HeadlessRadioProps,\n} from \"@headlessui/react\";\nimport { Slot } from \"@radix-ui/react-slot\";\nimport clsx from \"clsx\";\nimport {\n\tChildren,\n\tcloneElement,\n\tcreateContext,\n\tforwardRef,\n\tisValidElement,\n\tuseContext,\n\tuseRef,\n} from \"react\";\nimport type {\n\tComponentRef,\n\tHTMLAttributes,\n\tPropsWithChildren,\n\tReactNode,\n} from \"react\";\nimport type { WithAsChild } from \"../../types/as-child.js\";\nimport { cx } from \"../../utils/cx/cx.js\";\nimport { isInput } from \"../input/is-input.js\";\n\ntype RadioGroupProps = PropsWithChildren<\n\tOmit<HeadlessRadioGroupProps, \"as\" | \"children\">\n>;\n\n/**\n * A group of radio items. It manages the state of the children radios. Unstyled and simple.\n * Used as the root component for grouping related radio items where only one can be selected.\n *\n * @see https://mantle.ngrok.com/components/radio-group#api-radio-group\n *\n * @example\n * ```tsx\n * <RadioGroup value={value} onValueChange={setValue}>\n * <RadioGroup.Item value=\"option1\">\n * <RadioGroup.Indicator />\n * <span>Option 1</span>\n * </RadioGroup.Item>\n * <RadioGroup.Item value=\"option2\">\n * <RadioGroup.Indicator />\n * <span>Option 2</span>\n * </RadioGroup.Item>\n * </RadioGroup>\n * ```\n */\nconst Root = forwardRef<\n\tComponentRef<typeof HeadlessRadioGroup>,\n\tRadioGroupProps\n>((props, ref) => <HeadlessRadioGroup {...props} ref={ref} />);\nRoot.displayName = \"RadioGroup\";\n\n/**\n * The shape of the radio state context.\n */\ntype RadioStateContextValue = {\n\tautofocus: boolean;\n\tchecked: boolean;\n\tdisabled: boolean;\n\tfocus: boolean;\n\thover: boolean;\n};\n\n/**\n * The radio state. It's used to pass the state of the radio to its children components.\n * It's used internally by the radio components to manage the state/style of the radio items.\n * Used in place of css classes to avoid specificity issues and slightly improve performance.\n */\nconst RadioStateContext = createContext<RadioStateContextValue>({\n\tautofocus: false,\n\tchecked: false,\n\tdisabled: false,\n\tfocus: false,\n\thover: false,\n});\n\ntype RadioItemProps = Omit<HeadlessRadioProps, \"children\"> & PropsWithChildren;\n\n/**\n * A simple radio item that can be used inside a radio group. The \"conventional\" use-case.\n * Must be a child of `RadioGroup`.\n *\n * @see https://mantle.ngrok.com/components/radio-group#api-radio-item\n *\n * @example\n * ```tsx\n * <RadioGroup value={value} onValueChange={setValue}>\n * <RadioGroup.Item value=\"option1\">\n * <RadioGroup.Indicator />\n * <span>Option 1</span>\n * </RadioGroup.Item>\n * </RadioGroup>\n * ```\n */\nconst Item = forwardRef<ComponentRef<\"div\">, RadioItemProps>(\n\t({ children, className, ...props }, ref) => (\n\t\t<HeadlessRadio\n\t\t\tclassName={cx(\n\t\t\t\t\"group/radio cursor-pointer aria-disabled:cursor-default [&_label]:cursor-inherit flex gap-2 py-1 text-sm focus:outline-hidden\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tas=\"div\"\n\t\t\t{...props}\n\t\t\tref={ref}\n\t\t>\n\t\t\t{(ctx) => (\n\t\t\t\t<RadioStateContext.Provider value={ctx}>\n\t\t\t\t\t{children}\n\t\t\t\t</RadioStateContext.Provider>\n\t\t\t)}\n\t\t</HeadlessRadio>\n\t),\n);\nItem.displayName = \"RadioItem\";\n\ntype RadioIndicatorProps = Omit<HTMLAttributes<HTMLDivElement>, \"children\"> & {\n\tchildren?: ReactNode | ((context: RadioStateContextValue) => ReactNode);\n};\n\n/**\n * The default radio indicator.\n * @private\n */\nconst DefaultRadioIndicator = ({\n\tchecked,\n\tdisabled,\n\tfocus,\n\thover,\n}: RadioStateContextValue) => (\n\t<span\n\t\tclassName={cx(\n\t\t\t\"border-form flex size-4 items-center justify-center rounded-full border shrink-0\",\n\t\t\tdisabled && \"cursor-default opacity-50\",\n\t\t\tchecked && \"border-accent-500 bg-accent-500\",\n\t\t\tfocus && !disabled && \"border-accent-600 ring-focus-accent ring-4\",\n\t\t\thover && \"border-accent-600\",\n\t\t)}\n\t>\n\t\t{checked && <span className=\"size-2 rounded-full bg-[#fff] shrink-0\" />}\n\t</span>\n);\n\n/**\n * The selection indicator for any radio item.\n * Use it as a child of `RadioGroup.Item`, `RadioGroup.ListItem`, or `RadioGroup.Card`.\n * By default, it's a circle that changes color when checked.\n * You can customize the indicator by passing children:\n * - a different component\n * - a render-props function that receives the radio state context and should return a component.\n *\n * @see https://mantle.ngrok.com/components/radio-group#api-radio-indicator\n *\n * @example\n * ```tsx\n * <RadioGroup.Item value=\"option1\">\n * <RadioGroup.Indicator />\n * <span>Option 1</span>\n * </RadioGroup.Item>\n * ```\n */\nconst Indicator = ({ children, className, ...props }: RadioIndicatorProps) => {\n\tconst ctx = useContext(RadioStateContext);\n\n\treturn (\n\t\t<div\n\t\t\tclassName={cx(\n\t\t\t\t\"radio-indicator inline-flex size-5 select-none items-center justify-center shrink-0\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children == null ? (\n\t\t\t\t<DefaultRadioIndicator {...ctx} />\n\t\t\t) : typeof children === \"function\" ? (\n\t\t\t\tchildren(ctx)\n\t\t\t) : (\n\t\t\t\tchildren\n\t\t\t)}\n\t\t</div>\n\t);\n};\nIndicator.displayName = \"RadioIndicator\";\n\n/**\n * A group of radio list items. Use RadioGroup.ListItem as direct children.\n */\nconst List = forwardRef<ComponentRef<typeof Root>, RadioGroupProps>(\n\t({ className, ...props }, ref) => {\n\t\treturn (\n\t\t\t<Root className={clsx(\"-space-y-px\", className)} {...props} ref={ref} />\n\t\t);\n\t},\n);\nList.displayName = \"RadioGroupList\";\n\ntype RadioListItemProps = RadioItemProps;\n\n/**\n * A radio list item that is used inside a `RadioGroup.List`.\n */\nconst ListItem = forwardRef<ComponentRef<\"div\">, RadioListItemProps>(\n\t({ children, className, ...props }, ref) => {\n\t\treturn (\n\t\t\t<HeadlessRadio\n\t\t\t\tas=\"div\"\n\t\t\t\tclassName={cx(\n\t\t\t\t\t\"group/radio border-form [&_label]:cursor-inherit relative flex select-none gap-2 border px-3 py-2 text-sm\",\n\t\t\t\t\t\"cursor-pointer aria-disabled:cursor-default focus:outline-hidden\",\n\t\t\t\t\t\"focus-visible:ring-focus-accent not-aria-disabled:focus-visible:border-accent-600 focus-visible:ring-4\",\n\t\t\t\t\t\"first-of-type:rounded-tl-md first-of-type:rounded-tr-md last-of-type:rounded-bl-md last-of-type:rounded-br-md\",\n\t\t\t\t\t\"aria-disabled:border-form/50 not-aria-disabled:hover:z-1 not-aria-disabled:hover:border-accent-600\",\n\t\t\t\t\t\"aria-checked:z-1 aria-checked:border-accent-500/40 aria-checked:bg-accent-500/10 dark-high-contrast:aria-checked:border-accent-400 high-contrast:aria-checked:border-accent-400 not-aria-disabled:hover:aria-checked:border-accent-600\",\n\t\t\t\t\t\"has-[.radio-indicator:first-child]:pl-2 has-[.radio-indicator:last-child]:pr-2\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{(ctx) => (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<RadioStateContext.Provider value={ctx}>\n\t\t\t\t\t\t\t{children}\n\t\t\t\t\t\t</RadioStateContext.Provider>\n\t\t\t\t\t</>\n\t\t\t\t)}\n\t\t\t</HeadlessRadio>\n\t\t);\n\t},\n);\nListItem.displayName = \"RadioListItem\";\n\ntype RadioItemContentProps = HTMLAttributes<HTMLDivElement> & WithAsChild;\n\ntype RadioCardProps = RadioItemProps;\n\n/**\n * A radio card item. Use it as a child of `RadioGroup`\n */\nconst Card = forwardRef<ComponentRef<\"div\">, RadioCardProps>(\n\t({ children, className, ...props }, ref) => {\n\t\treturn (\n\t\t\t<HeadlessRadio\n\t\t\t\tas=\"div\"\n\t\t\t\tclassName={clsx(\n\t\t\t\t\t\"group/radio border-card bg-card [&_label]:cursor-inherit relative rounded-md border p-4 text-sm\",\n\t\t\t\t\t\"cursor-pointer aria-disabled:cursor-default focus:outline-hidden\",\n\t\t\t\t\t\"focus-visible:ring-focus-accent not-aria-disabled:focus-visible:border-accent-600 focus-visible:ring-4\",\n\t\t\t\t\t\"first-of-type:rounded-tl-md first-of-type:rounded-tr-md last-of-type:rounded-bl-md last-of-type:rounded-br-md\",\n\t\t\t\t\t\"aria-disabled:border-form/50 not-aria-disabled:hover:z-1 not-aria-disabled:hover:border-accent-600\",\n\t\t\t\t\t\"aria-checked:z-1 aria-checked:border-accent-500/40 aria-checked:bg-accent-500/10 not-aria-disabled:hover:aria-checked:border-accent-600 dark-high-contrast:aria-checked:border-accent-400 high-contrast:aria-checked:border-accent-400\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t\tref={ref}\n\t\t\t>\n\t\t\t\t{(ctx) => (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<RadioStateContext.Provider value={ctx}>\n\t\t\t\t\t\t\t{children}\n\t\t\t\t\t\t</RadioStateContext.Provider>\n\t\t\t\t\t</>\n\t\t\t\t)}\n\t\t\t</HeadlessRadio>\n\t\t);\n\t},\n);\nCard.displayName = \"RadioCard\";\n\n/**\n * The content of any radio item. Use it to wrap any labels, descriptions, or content of a radio item.\n * Use it as a child of `RadioGroup.Item`, `RadioGroup.ListItem`, or `RadioGroup.Card`.\n */\nconst ItemContent = ({\n\tasChild = false,\n\tchildren,\n\tclassName,\n\t...props\n}: RadioItemContentProps) => {\n\tconst ctx = useContext(RadioStateContext);\n\tconst Component = asChild ? Slot : \"div\";\n\n\treturn (\n\t\t<Component\n\t\t\tclassName={clsx(\n\t\t\t\t\"min-w-0 flex-1\",\n\t\t\t\tctx.disabled && \"opacity-50\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t</Component>\n\t);\n};\nItemContent.displayName = \"RadioItemContent\";\n\n/**\n * An inline group of radio buttons. Use RadioGroup.Button as direct children.\n */\nconst ButtonGroup = forwardRef<ComponentRef<typeof Root>, RadioGroupProps>(\n\t({ className, ...props }, ref) => {\n\t\treturn (\n\t\t\t<Root\n\t\t\t\tclassName={clsx(\"flex flex-row flex-nowrap -space-x-px\", className)}\n\t\t\t\t{...props}\n\t\t\t\tref={ref}\n\t\t\t/>\n\t\t);\n\t},\n);\nButtonGroup.displayName = \"RadioButtonGroup\";\n\ntype RadioButtonProps = RadioItemProps;\n\n/**\n * A radio button that is used inside a `RadioGroup.ButtonGroup`.\n */\nconst Button = forwardRef<ComponentRef<\"div\">, RadioButtonProps>(\n\t({ children, className, ...props }, ref) => {\n\t\treturn (\n\t\t\t<HeadlessRadio\n\t\t\t\tas=\"div\"\n\t\t\t\tclassName={cx(\n\t\t\t\t\t\"group/radio border-form [&_label]:cursor-inherit relative flex flex-1 select-none items-center justify-center gap-2 border px-3 text-sm\",\n\t\t\t\t\t\"h-9\",\n\t\t\t\t\t\"focus-visible:ring-focus-accent not-aria-disabled:focus-visible:border-accent-600 focus-visible:ring-4\",\n\t\t\t\t\t\"cursor-pointer aria-disabled:cursor-default focus:outline-hidden\",\n\t\t\t\t\t\"first-of-type:rounded-bl-md first-of-type:rounded-tl-md last-of-type:rounded-br-md last-of-type:rounded-tr-md\",\n\t\t\t\t\t\"not-aria-disabled:hover:z-1 not-aria-disabled:hover:border-accent-600 aria-disabled:opacity-50\",\n\t\t\t\t\t\"aria-checked:z-1 aria-checked:border-accent-500/40 aria-checked:bg-accent-500/10 not-aria-disabled:hover:aria-checked:border-accent-600\",\n\t\t\t\t\t\"has-[.radio-indicator:first-child]:pl-2 has-[.radio-indicator:last-child]:pr-2\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{(ctx) => (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<RadioStateContext.Provider value={ctx}>\n\t\t\t\t\t\t\t{children}\n\t\t\t\t\t\t</RadioStateContext.Provider>\n\t\t\t\t\t</>\n\t\t\t\t)}\n\t\t\t</HeadlessRadio>\n\t\t);\n\t},\n);\nButton.displayName = \"RadioButton\";\n\ntype RadioInputSandboxProps = HTMLAttributes<HTMLDivElement>;\n\n/**\n * A sandbox container for input elements composed within radio group items.\n * It prevents the default behavior of the radio group when clicking on the input element or accepting keyboard input.\n */\nconst InputSandbox = ({\n\tchildren,\n\tonClick,\n\tonKeyDown,\n\t...props\n}: RadioInputSandboxProps) => {\n\tconst ref = useRef<HTMLDivElement>(null);\n\tconst ctx = useContext(RadioStateContext);\n\n\tconst singleChild = Children.only(children);\n\n\t// Prevent the child input from receiving focus when the parent radio group item is disabled or unchecked.\n\tconst shouldPreventTabIndex = ctx.disabled || !ctx.checked;\n\n\treturn (\n\t\t<div\n\t\t\tref={ref}\n\t\t\taria-disabled={ctx.disabled}\n\t\t\tonKeyDown={(event) => {\n\t\t\t\tif (ctx.disabled) {\n\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tswitch (event.key) {\n\t\t\t\t\tcase \"Enter\":\n\t\t\t\t\tcase \"Tab\":\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t}\n\t\t\t\tonKeyDown?.(event);\n\t\t\t}}\n\t\t\tonClick={(event) => {\n\t\t\t\tif (ctx.disabled) {\n\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tconst target = event.target;\n\t\t\t\tif (isInput(target)) {\n\t\t\t\t\twindow.requestAnimationFrame(() => {\n\t\t\t\t\t\ttarget.focus();\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\tonClick?.(event);\n\t\t\t}}\n\t\t\t{...props}\n\t\t>\n\t\t\t{isValidElement<HTMLInputElement>(singleChild)\n\t\t\t\t? cloneElement(singleChild, {\n\t\t\t\t\t\tdisabled: ctx.disabled || singleChild.props.disabled,\n\t\t\t\t\t\ttabIndex: shouldPreventTabIndex ? -1 : singleChild.props.tabIndex,\n\t\t\t\t\t})\n\t\t\t\t: null}\n\t\t</div>\n\t);\n};\nInputSandbox.displayName = \"RadioInputSandbox\";\n\n/**\n * A group of radio items. It manages the state of the children radios.\n *\n * @see https://mantle.ngrok.com/components/radio-group\n *\n * @example\n * ```tsx\n * <RadioGroup value={value} onValueChange={setValue}>\n * <RadioGroup.Item value=\"option1\">\n * <RadioGroup.Indicator />\n * <span>Option 1</span>\n * </RadioGroup.Item>\n * <RadioGroup.Item value=\"option2\">\n * <RadioGroup.Indicator />\n * <span>Option 2</span>\n * </RadioGroup.Item>\n * </RadioGroup>\n * ```\n */\nconst RadioGroup = {\n\t/**\n\t * A radio button that is used inside a RadioGroup.ButtonGroup for inline grouped radio options.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-button\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"option1\">\n\t * <RadioGroup.ButtonGroup>\n\t * <RadioGroup.Button value=\"option1\">Option 1</RadioGroup.Button>\n\t * <RadioGroup.Button value=\"option2\">Option 2</RadioGroup.Button>\n\t * <RadioGroup.Button value=\"option3\">Option 3</RadioGroup.Button>\n\t * </RadioGroup.ButtonGroup>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tButton,\n\t/**\n\t * An inline group of radio buttons. Use RadioGroup.Button as direct children for horizontal radio layouts.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-button-group\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"small\">\n\t * <Label htmlFor=\"size-group\">Size</Label>\n\t * <RadioGroup.ButtonGroup>\n\t * <RadioGroup.Button value=\"small\">Small</RadioGroup.Button>\n\t * <RadioGroup.Button value=\"medium\">Medium</RadioGroup.Button>\n\t * <RadioGroup.Button value=\"large\">Large</RadioGroup.Button>\n\t * </RadioGroup.ButtonGroup>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tButtonGroup,\n\t/**\n\t * A radio card item with enhanced styling. Use it as a child of RadioGroup for card-based radio options.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-card\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"basic\">\n\t * <div className=\"space-y-3\">\n\t * <RadioGroup.Card value=\"basic\">\n\t * <RadioGroup.ItemContent>\n\t * <Text weight=\"strong\">Basic Plan</Text>\n\t * <Text>$10/month</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.Card>\n\t * <RadioGroup.Card value=\"pro\">\n\t * <RadioGroup.ItemContent>\n\t * <Text weight=\"strong\">Pro Plan</Text>\n\t * <Text>$25/month</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.Card>\n\t * </div>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tCard,\n\t/**\n\t * The selection indicator for any radio item. Shows the checked state with customizable appearance.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-indicator\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Item value=\"option1\">\n\t * <RadioGroup.Indicator />\n\t * <span>Option 1</span>\n\t * </RadioGroup.Item>\n\t * ```\n\t */\n\tIndicator,\n\t/**\n\t * A sandbox container for input elements composed within radio group items. Prevents default radio behavior.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-input-sandbox\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"custom\">\n\t * <RadioGroup.Item value=\"custom\">\n\t * <RadioGroup.Indicator />\n\t * <RadioGroup.ItemContent>\n\t * <Text>Custom amount</Text>\n\t * <RadioGroup.InputSandbox>\n\t * <Input type=\"number\" placeholder=\"Enter amount\" />\n\t * </RadioGroup.InputSandbox>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.Item>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tInputSandbox,\n\t/**\n\t * A simple radio item that can be used inside a radio group. The conventional use-case for basic radio options.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-item\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Item value=\"option1\">\n\t * <RadioGroup.Indicator />\n\t * <span>Option 1</span>\n\t * </RadioGroup.Item>\n\t * ```\n\t */\n\tItem,\n\t/**\n\t * The content wrapper for any radio item. Use it to wrap labels, descriptions, or content of a radio item.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-item-content\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"option1\">\n\t * <RadioGroup.Item value=\"option1\">\n\t * <RadioGroup.Indicator />\n\t * <RadioGroup.ItemContent>\n\t * <Text weight=\"strong\">Option 1</Text>\n\t * <Text size=\"sm\">Description for option 1</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.Item>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tItemContent,\n\t/**\n\t * A group of radio list items with connected borders. Use RadioGroup.ListItem as direct children.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-list\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"option1\">\n\t * <RadioGroup.List>\n\t * <RadioGroup.ListItem value=\"option1\">\n\t * <RadioGroup.ItemContent>\n\t * <Text>Option 1</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.ListItem>\n\t * <RadioGroup.ListItem value=\"option2\">\n\t * <RadioGroup.ItemContent>\n\t * <Text>Option 2</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.ListItem>\n\t * </RadioGroup.List>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tList,\n\t/**\n\t * A radio list item that is used inside a RadioGroup.List for connected list-style radio options.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-list-item\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"item1\">\n\t * <RadioGroup.List>\n\t * <RadioGroup.ListItem value=\"item1\">\n\t * <RadioGroup.ItemContent>\n\t * <Text>List Item 1</Text>\n\t * <Text size=\"sm\" className=\"text-muted\">First option</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.ListItem>\n\t * <RadioGroup.ListItem value=\"item2\">\n\t * <RadioGroup.ItemContent>\n\t * <Text>List Item 2</Text>\n\t * <Text size=\"sm\" className=\"text-muted\">Second option</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.ListItem>\n\t * </RadioGroup.List>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tListItem,\n\t/**\n\t * The root radio group component. Manages the state of the children radios where only one can be selected.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-group\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root value={value} onValueChange={setValue}>\n\t * <RadioGroup.Item value=\"option1\">\n\t * <RadioGroup.Indicator />\n\t * <span>Option 1</span>\n\t * </RadioGroup.Item>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tRoot,\n} as const;\n\nexport {\n\t//\n\tRadioGroup,\n};\n"],"mappings":"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","names":["HeadlessRadio","HeadlessRadioGroup","Slot","clsx","Children","cloneElement","createContext","forwardRef","isValidElement","useContext","useRef","Fragment","jsx","Root","forwardRef","props","ref","HeadlessRadioGroup","RadioStateContext","createContext","Item","children","className","HeadlessRadio","cx","ctx","DefaultRadioIndicator","checked","disabled","focus","hover","Indicator","useContext","List","clsx","ListItem","Card","ItemContent","asChild","Slot","ButtonGroup","Button","InputSandbox","onClick","onKeyDown","useRef","singleChild","Children","shouldPreventTabIndex","event","target","isInput","isValidElement","cloneElement","RadioGroup"]}
1
+ {"version":3,"sources":["../src/components/radio-group/radio-group.tsx"],"sourcesContent":["\"use client\";\n\nimport {\n\tRadio as HeadlessRadio,\n\tRadioGroup as HeadlessRadioGroup,\n} from \"@headlessui/react\";\nimport type {\n\tRadioGroupProps as HeadlessRadioGroupProps,\n\tRadioProps as HeadlessRadioProps,\n} from \"@headlessui/react\";\nimport clsx from \"clsx\";\nimport {\n\tChildren,\n\tcloneElement,\n\tcreateContext,\n\tforwardRef,\n\tisValidElement,\n\tuseContext,\n\tuseRef,\n} from \"react\";\nimport type {\n\tComponentRef,\n\tHTMLAttributes,\n\tPropsWithChildren,\n\tReactNode,\n} from \"react\";\nimport type { WithAsChild } from \"../../types/as-child.js\";\nimport { cx } from \"../../utils/cx/cx.js\";\nimport { isInput } from \"../input/is-input.js\";\nimport { Slot } from \"../slot/index.js\";\n\ntype RadioGroupProps = PropsWithChildren<\n\tOmit<HeadlessRadioGroupProps, \"as\" | \"children\">\n>;\n\n/**\n * A group of radio items. It manages the state of the children radios. Unstyled and simple.\n * Used as the root component for grouping related radio items where only one can be selected.\n *\n * @see https://mantle.ngrok.com/components/radio-group#api-radio-group\n *\n * @example\n * ```tsx\n * <RadioGroup value={value} onValueChange={setValue}>\n * <RadioGroup.Item value=\"option1\">\n * <RadioGroup.Indicator />\n * <span>Option 1</span>\n * </RadioGroup.Item>\n * <RadioGroup.Item value=\"option2\">\n * <RadioGroup.Indicator />\n * <span>Option 2</span>\n * </RadioGroup.Item>\n * </RadioGroup>\n * ```\n */\nconst Root = forwardRef<\n\tComponentRef<typeof HeadlessRadioGroup>,\n\tRadioGroupProps\n>((props, ref) => <HeadlessRadioGroup {...props} ref={ref} />);\nRoot.displayName = \"RadioGroup\";\n\n/**\n * The shape of the radio state context.\n */\ntype RadioStateContextValue = {\n\tautofocus: boolean;\n\tchecked: boolean;\n\tdisabled: boolean;\n\tfocus: boolean;\n\thover: boolean;\n};\n\n/**\n * The radio state. It's used to pass the state of the radio to its children components.\n * It's used internally by the radio components to manage the state/style of the radio items.\n * Used in place of css classes to avoid specificity issues and slightly improve performance.\n */\nconst RadioStateContext = createContext<RadioStateContextValue>({\n\tautofocus: false,\n\tchecked: false,\n\tdisabled: false,\n\tfocus: false,\n\thover: false,\n});\n\ntype RadioItemProps = Omit<HeadlessRadioProps, \"children\"> & PropsWithChildren;\n\n/**\n * A simple radio item that can be used inside a radio group. The \"conventional\" use-case.\n * Must be a child of `RadioGroup`.\n *\n * @see https://mantle.ngrok.com/components/radio-group#api-radio-item\n *\n * @example\n * ```tsx\n * <RadioGroup value={value} onValueChange={setValue}>\n * <RadioGroup.Item value=\"option1\">\n * <RadioGroup.Indicator />\n * <span>Option 1</span>\n * </RadioGroup.Item>\n * </RadioGroup>\n * ```\n */\nconst Item = forwardRef<ComponentRef<\"div\">, RadioItemProps>(\n\t({ children, className, ...props }, ref) => (\n\t\t<HeadlessRadio\n\t\t\tclassName={cx(\n\t\t\t\t\"group/radio cursor-pointer aria-disabled:cursor-default [&_label]:cursor-inherit flex gap-2 py-1 text-sm focus:outline-hidden\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tas=\"div\"\n\t\t\t{...props}\n\t\t\tref={ref}\n\t\t>\n\t\t\t{(ctx) => (\n\t\t\t\t<RadioStateContext.Provider value={ctx}>\n\t\t\t\t\t{children}\n\t\t\t\t</RadioStateContext.Provider>\n\t\t\t)}\n\t\t</HeadlessRadio>\n\t),\n);\nItem.displayName = \"RadioItem\";\n\ntype RadioIndicatorProps = Omit<HTMLAttributes<HTMLDivElement>, \"children\"> & {\n\tchildren?: ReactNode | ((context: RadioStateContextValue) => ReactNode);\n};\n\n/**\n * The default radio indicator.\n * @private\n */\nconst DefaultRadioIndicator = ({\n\tchecked,\n\tdisabled,\n\tfocus,\n\thover,\n}: RadioStateContextValue) => (\n\t<span\n\t\tclassName={cx(\n\t\t\t\"border-form flex size-4 items-center justify-center rounded-full border shrink-0\",\n\t\t\tdisabled && \"cursor-default opacity-50\",\n\t\t\tchecked && \"border-accent-500 bg-accent-500\",\n\t\t\tfocus && !disabled && \"border-accent-600 ring-focus-accent ring-4\",\n\t\t\thover && \"border-accent-600\",\n\t\t)}\n\t>\n\t\t{checked && <span className=\"size-2 rounded-full bg-[#fff] shrink-0\" />}\n\t</span>\n);\n\n/**\n * The selection indicator for any radio item.\n * Use it as a child of `RadioGroup.Item`, `RadioGroup.ListItem`, or `RadioGroup.Card`.\n * By default, it's a circle that changes color when checked.\n * You can customize the indicator by passing children:\n * - a different component\n * - a render-props function that receives the radio state context and should return a component.\n *\n * @see https://mantle.ngrok.com/components/radio-group#api-radio-indicator\n *\n * @example\n * ```tsx\n * <RadioGroup.Item value=\"option1\">\n * <RadioGroup.Indicator />\n * <span>Option 1</span>\n * </RadioGroup.Item>\n * ```\n */\nconst Indicator = ({ children, className, ...props }: RadioIndicatorProps) => {\n\tconst ctx = useContext(RadioStateContext);\n\n\treturn (\n\t\t<div\n\t\t\tclassName={cx(\n\t\t\t\t\"radio-indicator inline-flex size-5 select-none items-center justify-center shrink-0\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children == null ? (\n\t\t\t\t<DefaultRadioIndicator {...ctx} />\n\t\t\t) : typeof children === \"function\" ? (\n\t\t\t\tchildren(ctx)\n\t\t\t) : (\n\t\t\t\tchildren\n\t\t\t)}\n\t\t</div>\n\t);\n};\nIndicator.displayName = \"RadioIndicator\";\n\n/**\n * A group of radio list items. Use RadioGroup.ListItem as direct children.\n */\nconst List = forwardRef<ComponentRef<typeof Root>, RadioGroupProps>(\n\t({ className, ...props }, ref) => {\n\t\treturn (\n\t\t\t<Root className={clsx(\"-space-y-px\", className)} {...props} ref={ref} />\n\t\t);\n\t},\n);\nList.displayName = \"RadioGroupList\";\n\ntype RadioListItemProps = RadioItemProps;\n\n/**\n * A radio list item that is used inside a `RadioGroup.List`.\n */\nconst ListItem = forwardRef<ComponentRef<\"div\">, RadioListItemProps>(\n\t({ children, className, ...props }, ref) => {\n\t\treturn (\n\t\t\t<HeadlessRadio\n\t\t\t\tas=\"div\"\n\t\t\t\tclassName={cx(\n\t\t\t\t\t\"group/radio border-form [&_label]:cursor-inherit relative flex select-none gap-2 border px-3 py-2 text-sm\",\n\t\t\t\t\t\"cursor-pointer aria-disabled:cursor-default focus:outline-hidden\",\n\t\t\t\t\t\"focus-visible:ring-focus-accent not-aria-disabled:focus-visible:border-accent-600 focus-visible:ring-4\",\n\t\t\t\t\t\"first-of-type:rounded-tl-md first-of-type:rounded-tr-md last-of-type:rounded-bl-md last-of-type:rounded-br-md\",\n\t\t\t\t\t\"aria-disabled:border-form/50 not-aria-disabled:hover:z-1 not-aria-disabled:hover:border-accent-600\",\n\t\t\t\t\t\"aria-checked:z-1 aria-checked:border-accent-500/40 aria-checked:bg-accent-500/10 dark-high-contrast:aria-checked:border-accent-400 high-contrast:aria-checked:border-accent-400 not-aria-disabled:hover:aria-checked:border-accent-600\",\n\t\t\t\t\t\"has-[.radio-indicator:first-child]:pl-2 has-[.radio-indicator:last-child]:pr-2\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{(ctx) => (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<RadioStateContext.Provider value={ctx}>\n\t\t\t\t\t\t\t{children}\n\t\t\t\t\t\t</RadioStateContext.Provider>\n\t\t\t\t\t</>\n\t\t\t\t)}\n\t\t\t</HeadlessRadio>\n\t\t);\n\t},\n);\nListItem.displayName = \"RadioListItem\";\n\ntype RadioItemContentProps = HTMLAttributes<HTMLDivElement> & WithAsChild;\n\ntype RadioCardProps = RadioItemProps;\n\n/**\n * A radio card item. Use it as a child of `RadioGroup`\n */\nconst Card = forwardRef<ComponentRef<\"div\">, RadioCardProps>(\n\t({ children, className, ...props }, ref) => {\n\t\treturn (\n\t\t\t<HeadlessRadio\n\t\t\t\tas=\"div\"\n\t\t\t\tclassName={clsx(\n\t\t\t\t\t\"group/radio border-card bg-card [&_label]:cursor-inherit relative rounded-md border p-4 text-sm\",\n\t\t\t\t\t\"cursor-pointer aria-disabled:cursor-default focus:outline-hidden\",\n\t\t\t\t\t\"focus-visible:ring-focus-accent not-aria-disabled:focus-visible:border-accent-600 focus-visible:ring-4\",\n\t\t\t\t\t\"first-of-type:rounded-tl-md first-of-type:rounded-tr-md last-of-type:rounded-bl-md last-of-type:rounded-br-md\",\n\t\t\t\t\t\"aria-disabled:border-form/50 not-aria-disabled:hover:z-1 not-aria-disabled:hover:border-accent-600\",\n\t\t\t\t\t\"aria-checked:z-1 aria-checked:border-accent-500/40 aria-checked:bg-accent-500/10 not-aria-disabled:hover:aria-checked:border-accent-600 dark-high-contrast:aria-checked:border-accent-400 high-contrast:aria-checked:border-accent-400\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\t{...props}\n\t\t\t\tref={ref}\n\t\t\t>\n\t\t\t\t{(ctx) => (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<RadioStateContext.Provider value={ctx}>\n\t\t\t\t\t\t\t{children}\n\t\t\t\t\t\t</RadioStateContext.Provider>\n\t\t\t\t\t</>\n\t\t\t\t)}\n\t\t\t</HeadlessRadio>\n\t\t);\n\t},\n);\nCard.displayName = \"RadioCard\";\n\n/**\n * The content of any radio item. Use it to wrap any labels, descriptions, or content of a radio item.\n * Use it as a child of `RadioGroup.Item`, `RadioGroup.ListItem`, or `RadioGroup.Card`.\n */\nconst ItemContent = ({\n\tasChild = false,\n\tchildren,\n\tclassName,\n\t...props\n}: RadioItemContentProps) => {\n\tconst ctx = useContext(RadioStateContext);\n\tconst Component = asChild ? Slot : \"div\";\n\n\treturn (\n\t\t<Component\n\t\t\tclassName={clsx(\n\t\t\t\t\"min-w-0 flex-1\",\n\t\t\t\tctx.disabled && \"opacity-50\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t{children}\n\t\t</Component>\n\t);\n};\nItemContent.displayName = \"RadioItemContent\";\n\n/**\n * An inline group of radio buttons. Use RadioGroup.Button as direct children.\n */\nconst ButtonGroup = forwardRef<ComponentRef<typeof Root>, RadioGroupProps>(\n\t({ className, ...props }, ref) => {\n\t\treturn (\n\t\t\t<Root\n\t\t\t\tclassName={clsx(\"flex flex-row flex-nowrap -space-x-px\", className)}\n\t\t\t\t{...props}\n\t\t\t\tref={ref}\n\t\t\t/>\n\t\t);\n\t},\n);\nButtonGroup.displayName = \"RadioButtonGroup\";\n\ntype RadioButtonProps = RadioItemProps;\n\n/**\n * A radio button that is used inside a `RadioGroup.ButtonGroup`.\n */\nconst Button = forwardRef<ComponentRef<\"div\">, RadioButtonProps>(\n\t({ children, className, ...props }, ref) => {\n\t\treturn (\n\t\t\t<HeadlessRadio\n\t\t\t\tas=\"div\"\n\t\t\t\tclassName={cx(\n\t\t\t\t\t\"group/radio border-form [&_label]:cursor-inherit relative flex flex-1 select-none items-center justify-center gap-2 border px-3 text-sm\",\n\t\t\t\t\t\"h-9\",\n\t\t\t\t\t\"focus-visible:ring-focus-accent not-aria-disabled:focus-visible:border-accent-600 focus-visible:ring-4\",\n\t\t\t\t\t\"cursor-pointer aria-disabled:cursor-default focus:outline-hidden\",\n\t\t\t\t\t\"first-of-type:rounded-bl-md first-of-type:rounded-tl-md last-of-type:rounded-br-md last-of-type:rounded-tr-md\",\n\t\t\t\t\t\"not-aria-disabled:hover:z-1 not-aria-disabled:hover:border-accent-600 aria-disabled:opacity-50\",\n\t\t\t\t\t\"aria-checked:z-1 aria-checked:border-accent-500/40 aria-checked:bg-accent-500/10 not-aria-disabled:hover:aria-checked:border-accent-600\",\n\t\t\t\t\t\"has-[.radio-indicator:first-child]:pl-2 has-[.radio-indicator:last-child]:pr-2\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{(ctx) => (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<RadioStateContext.Provider value={ctx}>\n\t\t\t\t\t\t\t{children}\n\t\t\t\t\t\t</RadioStateContext.Provider>\n\t\t\t\t\t</>\n\t\t\t\t)}\n\t\t\t</HeadlessRadio>\n\t\t);\n\t},\n);\nButton.displayName = \"RadioButton\";\n\ntype RadioInputSandboxProps = HTMLAttributes<HTMLDivElement>;\n\n/**\n * A sandbox container for input elements composed within radio group items.\n * It prevents the default behavior of the radio group when clicking on the input element or accepting keyboard input.\n */\nconst InputSandbox = ({\n\tchildren,\n\tonClick,\n\tonKeyDown,\n\t...props\n}: RadioInputSandboxProps) => {\n\tconst ref = useRef<HTMLDivElement>(null);\n\tconst ctx = useContext(RadioStateContext);\n\n\tconst singleChild = Children.only(children);\n\n\t// Prevent the child input from receiving focus when the parent radio group item is disabled or unchecked.\n\tconst shouldPreventTabIndex = ctx.disabled || !ctx.checked;\n\n\treturn (\n\t\t<div\n\t\t\tref={ref}\n\t\t\taria-disabled={ctx.disabled}\n\t\t\tonKeyDown={(event) => {\n\t\t\t\tif (ctx.disabled) {\n\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tswitch (event.key) {\n\t\t\t\t\tcase \"Enter\":\n\t\t\t\t\tcase \"Tab\":\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t}\n\t\t\t\tonKeyDown?.(event);\n\t\t\t}}\n\t\t\tonClick={(event) => {\n\t\t\t\tif (ctx.disabled) {\n\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tconst target = event.target;\n\t\t\t\tif (isInput(target)) {\n\t\t\t\t\twindow.requestAnimationFrame(() => {\n\t\t\t\t\t\ttarget.focus();\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\tonClick?.(event);\n\t\t\t}}\n\t\t\t{...props}\n\t\t>\n\t\t\t{isValidElement<HTMLInputElement>(singleChild)\n\t\t\t\t? cloneElement(singleChild, {\n\t\t\t\t\t\tdisabled: ctx.disabled || singleChild.props.disabled,\n\t\t\t\t\t\ttabIndex: shouldPreventTabIndex ? -1 : singleChild.props.tabIndex,\n\t\t\t\t\t})\n\t\t\t\t: null}\n\t\t</div>\n\t);\n};\nInputSandbox.displayName = \"RadioInputSandbox\";\n\n/**\n * A group of radio items. It manages the state of the children radios.\n *\n * @see https://mantle.ngrok.com/components/radio-group\n *\n * @example\n * ```tsx\n * <RadioGroup value={value} onValueChange={setValue}>\n * <RadioGroup.Item value=\"option1\">\n * <RadioGroup.Indicator />\n * <span>Option 1</span>\n * </RadioGroup.Item>\n * <RadioGroup.Item value=\"option2\">\n * <RadioGroup.Indicator />\n * <span>Option 2</span>\n * </RadioGroup.Item>\n * </RadioGroup>\n * ```\n */\nconst RadioGroup = {\n\t/**\n\t * A radio button that is used inside a RadioGroup.ButtonGroup for inline grouped radio options.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-button\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"option1\">\n\t * <RadioGroup.ButtonGroup>\n\t * <RadioGroup.Button value=\"option1\">Option 1</RadioGroup.Button>\n\t * <RadioGroup.Button value=\"option2\">Option 2</RadioGroup.Button>\n\t * <RadioGroup.Button value=\"option3\">Option 3</RadioGroup.Button>\n\t * </RadioGroup.ButtonGroup>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tButton,\n\t/**\n\t * An inline group of radio buttons. Use RadioGroup.Button as direct children for horizontal radio layouts.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-button-group\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"small\">\n\t * <Label htmlFor=\"size-group\">Size</Label>\n\t * <RadioGroup.ButtonGroup>\n\t * <RadioGroup.Button value=\"small\">Small</RadioGroup.Button>\n\t * <RadioGroup.Button value=\"medium\">Medium</RadioGroup.Button>\n\t * <RadioGroup.Button value=\"large\">Large</RadioGroup.Button>\n\t * </RadioGroup.ButtonGroup>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tButtonGroup,\n\t/**\n\t * A radio card item with enhanced styling. Use it as a child of RadioGroup for card-based radio options.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-card\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"basic\">\n\t * <div className=\"space-y-3\">\n\t * <RadioGroup.Card value=\"basic\">\n\t * <RadioGroup.ItemContent>\n\t * <Text weight=\"strong\">Basic Plan</Text>\n\t * <Text>$10/month</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.Card>\n\t * <RadioGroup.Card value=\"pro\">\n\t * <RadioGroup.ItemContent>\n\t * <Text weight=\"strong\">Pro Plan</Text>\n\t * <Text>$25/month</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.Card>\n\t * </div>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tCard,\n\t/**\n\t * The selection indicator for any radio item. Shows the checked state with customizable appearance.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-indicator\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Item value=\"option1\">\n\t * <RadioGroup.Indicator />\n\t * <span>Option 1</span>\n\t * </RadioGroup.Item>\n\t * ```\n\t */\n\tIndicator,\n\t/**\n\t * A sandbox container for input elements composed within radio group items. Prevents default radio behavior.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-input-sandbox\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"custom\">\n\t * <RadioGroup.Item value=\"custom\">\n\t * <RadioGroup.Indicator />\n\t * <RadioGroup.ItemContent>\n\t * <Text>Custom amount</Text>\n\t * <RadioGroup.InputSandbox>\n\t * <Input type=\"number\" placeholder=\"Enter amount\" />\n\t * </RadioGroup.InputSandbox>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.Item>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tInputSandbox,\n\t/**\n\t * A simple radio item that can be used inside a radio group. The conventional use-case for basic radio options.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-item\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Item value=\"option1\">\n\t * <RadioGroup.Indicator />\n\t * <span>Option 1</span>\n\t * </RadioGroup.Item>\n\t * ```\n\t */\n\tItem,\n\t/**\n\t * The content wrapper for any radio item. Use it to wrap labels, descriptions, or content of a radio item.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-item-content\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"option1\">\n\t * <RadioGroup.Item value=\"option1\">\n\t * <RadioGroup.Indicator />\n\t * <RadioGroup.ItemContent>\n\t * <Text weight=\"strong\">Option 1</Text>\n\t * <Text size=\"sm\">Description for option 1</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.Item>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tItemContent,\n\t/**\n\t * A group of radio list items with connected borders. Use RadioGroup.ListItem as direct children.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-list\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"option1\">\n\t * <RadioGroup.List>\n\t * <RadioGroup.ListItem value=\"option1\">\n\t * <RadioGroup.ItemContent>\n\t * <Text>Option 1</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.ListItem>\n\t * <RadioGroup.ListItem value=\"option2\">\n\t * <RadioGroup.ItemContent>\n\t * <Text>Option 2</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.ListItem>\n\t * </RadioGroup.List>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tList,\n\t/**\n\t * A radio list item that is used inside a RadioGroup.List for connected list-style radio options.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-list-item\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root defaultValue=\"item1\">\n\t * <RadioGroup.List>\n\t * <RadioGroup.ListItem value=\"item1\">\n\t * <RadioGroup.ItemContent>\n\t * <Text>List Item 1</Text>\n\t * <Text size=\"sm\" className=\"text-muted\">First option</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.ListItem>\n\t * <RadioGroup.ListItem value=\"item2\">\n\t * <RadioGroup.ItemContent>\n\t * <Text>List Item 2</Text>\n\t * <Text size=\"sm\" className=\"text-muted\">Second option</Text>\n\t * </RadioGroup.ItemContent>\n\t * </RadioGroup.ListItem>\n\t * </RadioGroup.List>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tListItem,\n\t/**\n\t * The root radio group component. Manages the state of the children radios where only one can be selected.\n\t *\n\t * @see https://mantle.ngrok.com/components/radio-group#api-radio-group\n\t *\n\t * @example\n\t * ```tsx\n\t * <RadioGroup.Root value={value} onValueChange={setValue}>\n\t * <RadioGroup.Item value=\"option1\">\n\t * <RadioGroup.Indicator />\n\t * <span>Option 1</span>\n\t * </RadioGroup.Item>\n\t * </RadioGroup.Root>\n\t * ```\n\t */\n\tRoot,\n} as const;\n\nexport {\n\t//\n\tRadioGroup,\n};\n"],"mappings":"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","names":["HeadlessRadio","HeadlessRadioGroup","clsx","Children","cloneElement","createContext","forwardRef","isValidElement","useContext","useRef","Fragment","jsx","Root","forwardRef","props","ref","HeadlessRadioGroup","RadioStateContext","createContext","Item","children","className","HeadlessRadio","cx","ctx","DefaultRadioIndicator","checked","disabled","focus","hover","Indicator","useContext","List","clsx","ListItem","Card","ItemContent","asChild","Slot","ButtonGroup","Button","InputSandbox","onClick","onKeyDown","useRef","singleChild","Children","shouldPreventTabIndex","event","target","isInput","isValidElement","cloneElement","RadioGroup"]}
@@ -1,2 +1,2 @@
1
- import{Slot as l}from"@radix-ui/react-slot";import{forwardRef as a}from"react";import{jsx as d}from"react/jsx-runtime";var n=({allowClickEventDefault:e=!1,onClick:t}={})=>({role:"presentation",onClick:o=>{o.stopPropagation(),e||o.preventDefault(),t?.(o)}}),s=a(({allowClickEventDefault:e=!1,asChild:t=!1,children:o,onClick:p,...r},i)=>d(t?l:"div",{ref:i,...r,...n({allowClickEventDefault:e,onClick:p}),children:o}));s.displayName="SandboxedOnClick";export{s as SandboxedOnClick,n as sandboxedOnClickProps};
1
+ import{a as n}from"./chunk-UNFO4DZV.js";import"./chunk-PFXFESEN.js";import{forwardRef as a}from"react";import{jsx as d}from"react/jsx-runtime";var s=({allowClickEventDefault:e=!1,onClick:t}={})=>({role:"presentation",onClick:o=>{o.stopPropagation(),e||o.preventDefault(),t?.(o)}}),p=a(({allowClickEventDefault:e=!1,asChild:t=!1,children:o,onClick:r,...i},l)=>d(t?n:"div",{ref:l,...i,...s({allowClickEventDefault:e,onClick:r}),children:o}));p.displayName="SandboxedOnClick";export{p as SandboxedOnClick,s as sandboxedOnClickProps};
2
2
  //# sourceMappingURL=sandboxed-on-click.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/components/sandboxed-on-click/sandboxed-on-click.tsx"],"sourcesContent":["\"use client\";\n\nimport { Slot } from \"@radix-ui/react-slot\";\nimport type {\n\tComponentProps,\n\tComponentRef,\n\tHTMLAttributes,\n\tMouseEventHandler,\n} from \"react\";\nimport { forwardRef } from \"react\";\nimport type { WithAsChild } from \"../../types/as-child.js\";\n\ntype BaseProps = {\n\t/**\n\t * Only call `event.preventDefault()` in the `onClick` handler if the user\n\t * has not set `allowClickEventDefault` to `true`. This allows the user to\n\t * control whether or not the default behavior of the click event should be\n\t * allowed.\n\t *\n\t * This is useful for links or buttons that should navigate or perform some\n\t * action on click.\n\t *\n\t * @default false\n\t */\n\tallowClickEventDefault?: boolean;\n};\n\ntype EventProps = BaseProps & {\n\t/**\n\t * The click event handler.\n\t */\n\tonClick?: MouseEventHandler<HTMLElement>;\n};\n\n/**\n * Props for the sandboxed onClick container. Spread this on the element you want\n * to prevent the click event from bubbling out of.\n *\n * @see https://mantle.ngrok.com/components/sandboxed-on-click#api-sandboxed-on-click\n */\nconst sandboxedOnClickProps = ({\n\tallowClickEventDefault = false,\n\tonClick,\n}: EventProps = {}) =>\n\t({\n\t\t/**\n\t\t * Marking an element with the role presentation indicates to assistive\n\t\t * technology that this element should be ignored; it exists to support the\n\t\t * web application and is not meant for humans to interact with directly.\n\t\t *\n\t\t * @see https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/65be35b0f6c6cf8b79e9a748cb657a64b78c6535/docs/rules/no-noninteractive-element-interactions.md#case-this-element-is-catching-bubbled-events-from-elements-that-it-contains\n\t\t * @see https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/presentation_role\n\t\t */\n\t\trole: \"presentation\",\n\t\tonClick: (event) => {\n\t\t\t/**\n\t\t\t * we _always_ want to stop propagation to prevent the event from bubbling\n\t\t\t * out of the sandboxed container\n\t\t\t */\n\t\t\tevent.stopPropagation();\n\n\t\t\t/**\n\t\t\t * Only call `event.preventDefault()` if the user has not set\n\t\t\t * `allowClickEventDefault` to true. This allows the user to control\n\t\t\t * whether or not the default behavior of the click event should be\n\t\t\t * allowed.\n\t\t\t *\n\t\t\t * This is useful for links or buttons that should navigate or perform\n\t\t\t * some action on click.\n\t\t\t */\n\t\t\tif (!allowClickEventDefault) {\n\t\t\t\tevent.preventDefault();\n\t\t\t}\n\t\t\tonClick?.(event);\n\t\t},\n\t}) as const satisfies HTMLAttributes<HTMLElement>;\n\ntype Props = ComponentProps<\"div\"> & WithAsChild & BaseProps;\n\n/**\n * A container that prevents the click event from bubbling out of it.\n *\n * @see https://mantle.ngrok.com/components/sandboxed-on-click#api-sandboxed-on-click\n *\n * @example\n * ```tsx\n * <TableRow onClick={() => navigate(\"/somewhere\")}>\n * <TableRowCell>\n * <SandboxedOnClick allowClickEventDefault>\n * <Anchor href=\"https://ngrok.com/docs\">\n * See ngrok docs\n * </Anchor>\n * </SandboxedOnClick>\n * </TableRowCell>\n * </TableRow>\n */\nconst SandboxedOnClick = forwardRef<ComponentRef<\"div\">, Props>(\n\t(\n\t\t{\n\t\t\t//,\n\t\t\tallowClickEventDefault = false,\n\t\t\tasChild = false,\n\t\t\tchildren,\n\t\t\tonClick,\n\t\t\t...props\n\t\t},\n\t\tref,\n\t) => {\n\t\tconst Component = asChild ? Slot : \"div\";\n\n\t\treturn (\n\t\t\t<Component\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t\t{...sandboxedOnClickProps({ allowClickEventDefault, onClick })}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</Component>\n\t\t);\n\t},\n);\nSandboxedOnClick.displayName = \"SandboxedOnClick\";\n\nexport {\n\t//,\n\tSandboxedOnClick,\n\tsandboxedOnClickProps,\n};\n"],"mappings":"AAEA,OAAS,QAAAA,MAAY,uBAOrB,OAAS,cAAAC,MAAkB,QAsGxB,cAAAC,MAAA,oBAvEH,IAAMC,EAAwB,CAAC,CAC9B,uBAAAC,EAAyB,GACzB,QAAAC,CACD,EAAgB,CAAC,KACf,CASA,KAAM,eACN,QAAUC,GAAU,CAKnBA,EAAM,gBAAgB,EAWjBF,GACJE,EAAM,eAAe,EAEtBD,IAAUC,CAAK,CAChB,CACD,GAqBKC,EAAmBN,EACxB,CACC,CAEC,uBAAAG,EAAyB,GACzB,QAAAI,EAAU,GACV,SAAAC,EACA,QAAAJ,EACA,GAAGK,CACJ,EACAC,IAKCT,EAHiBM,EAAUR,EAAO,MAGjC,CACA,IAAKW,EACJ,GAAGD,EACH,GAAGP,EAAsB,CAAE,uBAAAC,EAAwB,QAAAC,CAAQ,CAAC,EAE5D,SAAAI,EACF,CAGH,EACAF,EAAiB,YAAc","names":["Slot","forwardRef","jsx","sandboxedOnClickProps","allowClickEventDefault","onClick","event","SandboxedOnClick","asChild","children","props","ref"]}
1
+ {"version":3,"sources":["../src/components/sandboxed-on-click/sandboxed-on-click.tsx"],"sourcesContent":["\"use client\";\n\nimport type {\n\tComponentProps,\n\tComponentRef,\n\tHTMLAttributes,\n\tMouseEventHandler,\n} from \"react\";\nimport { forwardRef } from \"react\";\nimport type { WithAsChild } from \"../../types/as-child.js\";\nimport { Slot } from \"../slot/index.js\";\n\ntype BaseProps = {\n\t/**\n\t * Only call `event.preventDefault()` in the `onClick` handler if the user\n\t * has not set `allowClickEventDefault` to `true`. This allows the user to\n\t * control whether or not the default behavior of the click event should be\n\t * allowed.\n\t *\n\t * This is useful for links or buttons that should navigate or perform some\n\t * action on click.\n\t *\n\t * @default false\n\t */\n\tallowClickEventDefault?: boolean;\n};\n\ntype EventProps = BaseProps & {\n\t/**\n\t * The click event handler.\n\t */\n\tonClick?: MouseEventHandler<HTMLElement>;\n};\n\n/**\n * Props for the sandboxed onClick container. Spread this on the element you want\n * to prevent the click event from bubbling out of.\n *\n * @see https://mantle.ngrok.com/components/sandboxed-on-click#api-sandboxed-on-click\n */\nconst sandboxedOnClickProps = ({\n\tallowClickEventDefault = false,\n\tonClick,\n}: EventProps = {}) =>\n\t({\n\t\t/**\n\t\t * Marking an element with the role presentation indicates to assistive\n\t\t * technology that this element should be ignored; it exists to support the\n\t\t * web application and is not meant for humans to interact with directly.\n\t\t *\n\t\t * @see https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/65be35b0f6c6cf8b79e9a748cb657a64b78c6535/docs/rules/no-noninteractive-element-interactions.md#case-this-element-is-catching-bubbled-events-from-elements-that-it-contains\n\t\t * @see https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/presentation_role\n\t\t */\n\t\trole: \"presentation\",\n\t\tonClick: (event) => {\n\t\t\t/**\n\t\t\t * we _always_ want to stop propagation to prevent the event from bubbling\n\t\t\t * out of the sandboxed container\n\t\t\t */\n\t\t\tevent.stopPropagation();\n\n\t\t\t/**\n\t\t\t * Only call `event.preventDefault()` if the user has not set\n\t\t\t * `allowClickEventDefault` to true. This allows the user to control\n\t\t\t * whether or not the default behavior of the click event should be\n\t\t\t * allowed.\n\t\t\t *\n\t\t\t * This is useful for links or buttons that should navigate or perform\n\t\t\t * some action on click.\n\t\t\t */\n\t\t\tif (!allowClickEventDefault) {\n\t\t\t\tevent.preventDefault();\n\t\t\t}\n\t\t\tonClick?.(event);\n\t\t},\n\t}) as const satisfies HTMLAttributes<HTMLElement>;\n\ntype Props = ComponentProps<\"div\"> & WithAsChild & BaseProps;\n\n/**\n * A container that prevents the click event from bubbling out of it.\n *\n * @see https://mantle.ngrok.com/components/sandboxed-on-click#api-sandboxed-on-click\n *\n * @example\n * ```tsx\n * <TableRow onClick={() => navigate(\"/somewhere\")}>\n * <TableRowCell>\n * <SandboxedOnClick allowClickEventDefault>\n * <Anchor href=\"https://ngrok.com/docs\">\n * See ngrok docs\n * </Anchor>\n * </SandboxedOnClick>\n * </TableRowCell>\n * </TableRow>\n */\nconst SandboxedOnClick = forwardRef<ComponentRef<\"div\">, Props>(\n\t(\n\t\t{\n\t\t\t//,\n\t\t\tallowClickEventDefault = false,\n\t\t\tasChild = false,\n\t\t\tchildren,\n\t\t\tonClick,\n\t\t\t...props\n\t\t},\n\t\tref,\n\t) => {\n\t\tconst Component = asChild ? Slot : \"div\";\n\n\t\treturn (\n\t\t\t<Component\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t\t{...sandboxedOnClickProps({ allowClickEventDefault, onClick })}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</Component>\n\t\t);\n\t},\n);\nSandboxedOnClick.displayName = \"SandboxedOnClick\";\n\nexport {\n\t//,\n\tSandboxedOnClick,\n\tsandboxedOnClickProps,\n};\n"],"mappings":"oEAQA,OAAS,cAAAA,MAAkB,QAuGxB,cAAAC,MAAA,oBAvEH,IAAMC,EAAwB,CAAC,CAC9B,uBAAAC,EAAyB,GACzB,QAAAC,CACD,EAAgB,CAAC,KACf,CASA,KAAM,eACN,QAAUC,GAAU,CAKnBA,EAAM,gBAAgB,EAWjBF,GACJE,EAAM,eAAe,EAEtBD,IAAUC,CAAK,CAChB,CACD,GAqBKC,EAAmBC,EACxB,CACC,CAEC,uBAAAJ,EAAyB,GACzB,QAAAK,EAAU,GACV,SAAAC,EACA,QAAAL,EACA,GAAGM,CACJ,EACAC,IAKCV,EAHiBO,EAAUI,EAAO,MAGjC,CACA,IAAKD,EACJ,GAAGD,EACH,GAAGR,EAAsB,CAAE,uBAAAC,EAAwB,QAAAC,CAAQ,CAAC,EAE5D,SAAAK,EACF,CAGH,EACAH,EAAiB,YAAc","names":["forwardRef","jsx","sandboxedOnClickProps","allowClickEventDefault","onClick","event","SandboxedOnClick","forwardRef","asChild","children","props","ref","Slot"]}
package/dist/select.js CHANGED
@@ -1,2 +1,2 @@
1
- import{a as e}from"./chunk-5QSZM7K4.js";import"./chunk-4DVFVPF2.js";import"./chunk-MF2QITTY.js";import"./chunk-2NIR7PCL.js";import"./chunk-NZ6DRFAL.js";import"./chunk-PFXFESEN.js";export{e as Select};
1
+ import{a as e}from"./chunk-EVAIBP32.js";import"./chunk-YKYEISYH.js";import"./chunk-MF2QITTY.js";import"./chunk-2NIR7PCL.js";import"./chunk-UNFO4DZV.js";import"./chunk-NZ6DRFAL.js";import"./chunk-PFXFESEN.js";export{e as Select};
2
2
  //# sourceMappingURL=select.js.map
package/dist/separator.js CHANGED
@@ -1,2 +1,2 @@
1
- import{a as r,b as o}from"./chunk-4DVFVPF2.js";import"./chunk-PFXFESEN.js";export{r as HorizontalSeparatorGroup,o as Separator};
1
+ import{a as r,b as o}from"./chunk-YKYEISYH.js";import"./chunk-UNFO4DZV.js";import"./chunk-PFXFESEN.js";export{r as HorizontalSeparatorGroup,o as Separator};
2
2
  //# sourceMappingURL=separator.js.map
package/dist/sheet.js CHANGED
@@ -1,2 +1,2 @@
1
- import{a as u,b as v,c as S,d as m,e as p,f as d,g as h,h as f}from"./chunk-VIKPHWPP.js";import{d as c}from"./chunk-WY3TZBNK.js";import"./chunk-VBNDWNIJ.js";import"./chunk-6J7D73WA.js";import"./chunk-NJNFZ2EG.js";import"./chunk-KMNACVH6.js";import{c as y}from"./chunk-QXNUFNG4.js";import"./chunk-4LSFAAZW.js";import"./chunk-72TJUKMV.js";import"./chunk-3C5O3AQA.js";import"./chunk-2NIR7PCL.js";import"./chunk-NZ6DRFAL.js";import{a}from"./chunk-PFXFESEN.js";import{XIcon as W}from"@phosphor-icons/react/X";import{cva as E}from"class-variance-authority";import{forwardRef as s}from"react";import{jsx as o,jsxs as z}from"react/jsx-runtime";var P=u;P.displayName="Sheet";var C=v;C.displayName="SheetTrigger";var g=m;g.displayName="SheetClose";var N=S;N.displayName="SheetPortal";var b=s(({className:e,...t},i)=>o(p,{className:a("bg-overlay data-state-closed:animate-out data-state-closed:fade-out-0 data-state-open:animate-in data-state-open:fade-in-0 fixed inset-0 z-40 backdrop-blur-xs",e),...t,ref:i}));b.displayName=p.displayName;var V=E("bg-dialog border-dialog inset-y-0 h-full w-full fixed z-40 flex flex-col shadow-lg outline-hidden transition ease-in-out focus-within:outline-hidden data-state-closed:duration-100 data-state-closed:animate-out data-state-open:duration-100 data-state-open:animate-in",{variants:{side:{left:"data-state-closed:slide-out-to-left data-state-open:slide-in-from-left left-0 border-r",right:"data-state-closed:slide-out-to-right data-state-open:slide-in-from-right right-0 border-l"}},defaultVariants:{side:"right"}}),x=s(({children:e,className:t,onInteractOutside:i,onPointerDownOutside:r,preferredWidth:l="sm:max-w-[30rem]",side:B="right",...O},A)=>z(N,{children:[o(b,{}),o(d,{className:a(V({side:B}),l,t),onInteractOutside:n=>{c(n),i?.(n)},onPointerDownOutside:n=>{c(n),r?.(n)},ref:A,...O,children:e})]}));x.displayName=d.displayName;var T=({size:e="md",type:t="button",label:i="Close Sheet",appearance:r="ghost",...l})=>o(m,{asChild:!0,children:o(y,{appearance:r,icon:o(W,{}),label:i,size:e,type:t,...l})});T.displayName="SheetCloseIconButton";var R=({className:e,...t})=>o("div",{className:a("scrollbar text-body flex-1 overflow-y-auto p-6",e),...t});R.displayName="SheetBody";var H=({className:e,...t})=>o("div",{className:a("border-dialog-muted flex shrink-0 flex-col gap-2 border-b py-4 pl-6 pr-4","has-[.icon-button]:pr-4",e),...t});H.displayName="SheetHeader";var D=({className:e,...t})=>o("div",{className:a("border-dialog-muted flex shrink-0 justify-end gap-2 border-t px-6 py-2.5",e),...t});D.displayName="SheetFooter";var L=s(({className:e,...t},i)=>o(h,{ref:i,className:a("text-strong flex-1 truncate text-lg font-medium",e),...t}));L.displayName=h.displayName;var M=s(({children:e,className:t,...i},r)=>o("div",{className:a("flex items-center justify-between gap-2",t),...i,ref:r,children:e}));M.displayName="SheetTitleGroup";var I=s(({className:e,...t},i)=>o(f,{ref:i,className:a("text-body text-sm",e),...t}));I.displayName=f.displayName;var w=s(({children:e,className:t,...i},r)=>o("div",{className:a("flex h-full items-center gap-2",t),...i,ref:r,children:e}));w.displayName="SheetActions";var k={Root:P,Actions:w,Body:R,Close:g,CloseIconButton:T,Content:x,Description:I,Footer:D,Header:H,Title:L,TitleGroup:M,Trigger:C};export{k as Sheet};
1
+ import{a as u,b as v,c as S,d as m,e as p,f as d,g as h,h as f}from"./chunk-OE4YWO7O.js";import{d as c}from"./chunk-UKS7NFNC.js";import"./chunk-VBNDWNIJ.js";import"./chunk-6J7D73WA.js";import"./chunk-NJNFZ2EG.js";import"./chunk-KMNACVH6.js";import{c as y}from"./chunk-BRV6XRNS.js";import"./chunk-4LSFAAZW.js";import"./chunk-72TJUKMV.js";import"./chunk-3C5O3AQA.js";import"./chunk-2NIR7PCL.js";import"./chunk-UNFO4DZV.js";import"./chunk-NZ6DRFAL.js";import{a}from"./chunk-PFXFESEN.js";import{XIcon as W}from"@phosphor-icons/react/X";import{cva as E}from"class-variance-authority";import{forwardRef as s}from"react";import{jsx as o,jsxs as z}from"react/jsx-runtime";var P=u;P.displayName="Sheet";var C=v;C.displayName="SheetTrigger";var g=m;g.displayName="SheetClose";var N=S;N.displayName="SheetPortal";var b=s(({className:e,...t},i)=>o(p,{className:a("bg-overlay data-state-closed:animate-out data-state-closed:fade-out-0 data-state-open:animate-in data-state-open:fade-in-0 fixed inset-0 z-40 backdrop-blur-xs",e),...t,ref:i}));b.displayName=p.displayName;var V=E("bg-dialog border-dialog inset-y-0 h-full w-full fixed z-40 flex flex-col shadow-lg outline-hidden transition ease-in-out focus-within:outline-hidden data-state-closed:duration-100 data-state-closed:animate-out data-state-open:duration-100 data-state-open:animate-in",{variants:{side:{left:"data-state-closed:slide-out-to-left data-state-open:slide-in-from-left left-0 border-r",right:"data-state-closed:slide-out-to-right data-state-open:slide-in-from-right right-0 border-l"}},defaultVariants:{side:"right"}}),x=s(({children:e,className:t,onInteractOutside:i,onPointerDownOutside:r,preferredWidth:l="sm:max-w-[30rem]",side:B="right",...O},A)=>z(N,{children:[o(b,{}),o(d,{className:a(V({side:B}),l,t),onInteractOutside:n=>{c(n),i?.(n)},onPointerDownOutside:n=>{c(n),r?.(n)},ref:A,...O,children:e})]}));x.displayName=d.displayName;var T=({size:e="md",type:t="button",label:i="Close Sheet",appearance:r="ghost",...l})=>o(m,{asChild:!0,children:o(y,{appearance:r,icon:o(W,{}),label:i,size:e,type:t,...l})});T.displayName="SheetCloseIconButton";var R=({className:e,...t})=>o("div",{className:a("scrollbar text-body flex-1 overflow-y-auto p-6",e),...t});R.displayName="SheetBody";var H=({className:e,...t})=>o("div",{className:a("border-dialog-muted flex shrink-0 flex-col gap-2 border-b py-4 pl-6 pr-4","has-[.icon-button]:pr-4",e),...t});H.displayName="SheetHeader";var D=({className:e,...t})=>o("div",{className:a("border-dialog-muted flex shrink-0 justify-end gap-2 border-t px-6 py-2.5",e),...t});D.displayName="SheetFooter";var L=s(({className:e,...t},i)=>o(h,{ref:i,className:a("text-strong flex-1 truncate text-lg font-medium",e),...t}));L.displayName=h.displayName;var M=s(({children:e,className:t,...i},r)=>o("div",{className:a("flex items-center justify-between gap-2",t),...i,ref:r,children:e}));M.displayName="SheetTitleGroup";var I=s(({className:e,...t},i)=>o(f,{ref:i,className:a("text-body text-sm",e),...t}));I.displayName=f.displayName;var w=s(({children:e,className:t,...i},r)=>o("div",{className:a("flex h-full items-center gap-2",t),...i,ref:r,children:e}));w.displayName="SheetActions";var k={Root:P,Actions:w,Body:R,Close:g,CloseIconButton:T,Content:x,Description:I,Footer:D,Header:H,Title:L,TitleGroup:M,Trigger:C};export{k as Sheet};
2
2
  //# sourceMappingURL=sheet.js.map
package/dist/sheet.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/components/sheet/sheet.tsx"],"sourcesContent":["import { XIcon } from \"@phosphor-icons/react/X\";\nimport { type VariantProps, cva } from \"class-variance-authority\";\nimport type {\n\tComponentPropsWithoutRef,\n\tComponentRef,\n\tHTMLAttributes,\n} from \"react\";\nimport { forwardRef } from \"react\";\nimport { cx } from \"../../utils/cx/cx.js\";\nimport { IconButton, type IconButtonProps } from \"../button/icon-button.js\";\nimport * as SheetPrimitive from \"../dialog/primitive.js\";\nimport { preventCloseOnPromptInteraction } from \"../toast/toast.js\";\n\n/**\n * The root component for a `Sheet`. Should compose the `Sheet.Trigger` and `Sheet.Content`.\n * Acts as a stateful provider for the Sheet's open/closed state.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet\n *\n * @example\n * ```tsx\n * // Triggering a stateful sheet\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Root = SheetPrimitive.Root;\nRoot.displayName = \"Sheet\";\n\n/**\n * The button trigger for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-trigger\n *\n * @example\n * ```tsx\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Trigger = SheetPrimitive.Trigger;\nTrigger.displayName = \"SheetTrigger\";\n\n/**\n * The close button for a `Sheet`. Should be rendered as a child of the `Sheet.Content` component.\n * Usually contained within the `Sheet.Footer` component.\n * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-close\n *\n * @example\n * ```tsx\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Close = SheetPrimitive.Close;\nClose.displayName = \"SheetClose\";\n\n/**\n * The portal for a sheet. Should be rendered as a child of the `Sheet` component.\n * Renders a portal that the `SheetOverlay` and `Sheet.Content` is rendered into.\n *\n * @private\n */\nconst SheetPortal = SheetPrimitive.Portal;\nSheetPortal.displayName = \"SheetPortal\";\n\n/**\n * The overlay backdrop for a sheet. Should be rendered as a child of the `SheetPortal` component.\n *\n * You likely don't need to use this component directly, as it is used internally by the `Sheet.Content` component.\n *\n * @private\n */\nconst SheetOverlay = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Overlay>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Overlay>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Overlay\n\t\tclassName={cx(\n\t\t\t\"bg-overlay data-state-closed:animate-out data-state-closed:fade-out-0 data-state-open:animate-in data-state-open:fade-in-0 fixed inset-0 z-40 backdrop-blur-xs\",\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t\tref={ref}\n\t/>\n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst SheetVariants = cva(\n\t\"bg-dialog border-dialog inset-y-0 h-full w-full fixed z-40 flex flex-col shadow-lg outline-hidden transition ease-in-out focus-within:outline-hidden data-state-closed:duration-100 data-state-closed:animate-out data-state-open:duration-100 data-state-open:animate-in\",\n\t{\n\t\tvariants: {\n\t\t\t/**\n\t\t\t * The side of the screen the sheet should slide in from.\n\t\t\t */\n\t\t\tside: {\n\t\t\t\tleft: \"data-state-closed:slide-out-to-left data-state-open:slide-in-from-left left-0 border-r\",\n\t\t\t\tright:\n\t\t\t\t\t\"data-state-closed:slide-out-to-right data-state-open:slide-in-from-right right-0 border-l\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tside: \"right\",\n\t\t},\n\t},\n);\n\ntype SheetContentProps = ComponentPropsWithoutRef<\n\ttypeof SheetPrimitive.Content\n> &\n\tVariantProps<typeof SheetVariants> & {\n\t\t/**\n\t\t * The preferred width of the `Sheet.Content` as a tailwind `max-w-` class.\n\t\t *\n\t\t * By default, a `Sheet`'s content width is responsive with a default\n\t\t * preferred width: the maximum width of the `Sheet.Content` when the window\n\t\t * viewport is larger than the mobile breakpoint (`sm`).\n\t\t *\n\t\t * @default `sm:max-w-[30rem]`\n\t\t */\n\t\tpreferredWidth?: `sm:max-w-${string}`;\n\t};\n\n/**\n * The main container for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n * Renders on top of the overlay backdrop.\n * Should contain the `Sheet.Header`, `Sheet.Body`, and `Sheet.Footer`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-content\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Content = forwardRef<ComponentRef<\"div\">, SheetContentProps>(\n\t(\n\t\t{\n\t\t\tchildren,\n\t\t\tclassName,\n\t\t\tonInteractOutside,\n\t\t\tonPointerDownOutside,\n\t\t\tpreferredWidth = \"sm:max-w-[30rem]\",\n\t\t\tside = \"right\",\n\t\t\t...props\n\t\t},\n\t\tref,\n\t) => (\n\t\t<SheetPortal>\n\t\t\t<SheetOverlay />\n\t\t\t<SheetPrimitive.Content\n\t\t\t\tclassName={cx(SheetVariants({ side }), preferredWidth, className)}\n\t\t\t\tonInteractOutside={(event) => {\n\t\t\t\t\tpreventCloseOnPromptInteraction(event);\n\t\t\t\t\tonInteractOutside?.(event);\n\t\t\t\t}}\n\t\t\t\tonPointerDownOutside={(event) => {\n\t\t\t\t\tpreventCloseOnPromptInteraction(event);\n\t\t\t\t\tonPointerDownOutside?.(event);\n\t\t\t\t}}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</SheetPrimitive.Content>\n\t\t</SheetPortal>\n\t),\n);\nContent.displayName = SheetPrimitive.Content.displayName;\n\ntype SheetCloseIconButtonProps = Partial<Omit<IconButtonProps, \"icon\">>;\n\n/**\n * An icon button that closes the `Sheet` when clicked.\n * Should be rendered within the `Sheet.Header` as a child of `Sheet.Actions`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-close-icon-button\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst CloseIconButton = ({\n\tsize = \"md\",\n\ttype = \"button\",\n\tlabel = \"Close Sheet\",\n\tappearance = \"ghost\",\n\t...props\n}: SheetCloseIconButtonProps) => (\n\t<SheetPrimitive.Close asChild>\n\t\t<IconButton\n\t\t\tappearance={appearance}\n\t\t\ticon={<XIcon />}\n\t\t\tlabel={label}\n\t\t\tsize={size}\n\t\t\ttype={type}\n\t\t\t{...props}\n\t\t/>\n\t</SheetPrimitive.Close>\n);\nCloseIconButton.displayName = \"SheetCloseIconButton\";\n\n/**\n * The body container for a `Sheet`. This is where you would typically place the main content of the sheet, such as forms or text.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-body\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Body = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div\n\t\tclassName={cx(\"scrollbar text-body flex-1 overflow-y-auto p-6\", className)}\n\t\t{...props}\n\t/>\n);\nBody.displayName = \"SheetBody\";\n\n/**\n * The header container for a `Sheet`. This is where you would typically place the title, description, and actions.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-header\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Header = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div\n\t\tclassName={cx(\n\t\t\t\"border-dialog-muted flex shrink-0 flex-col gap-2 border-b py-4 pl-6 pr-4\",\n\t\t\t\"has-[.icon-button]:pr-4\", // when there are actions in the header, shorten the padding\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t/>\n);\nHeader.displayName = \"SheetHeader\";\n\n/**\n * The footer container for a `Sheet`. This is where you would typically place close and submit buttons.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-footer\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Footer = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div\n\t\tclassName={cx(\n\t\t\t\"border-dialog-muted flex shrink-0 justify-end gap-2 border-t px-6 py-2.5\",\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t/>\n);\nFooter.displayName = \"SheetFooter\";\n\n/**\n * The title for a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n * Defaults to an `h2` element, but can be changed via the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-title\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Title = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Title>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Title>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Title\n\t\tref={ref}\n\t\tclassName={cx(\"text-strong flex-1 truncate text-lg font-medium\", className)}\n\t\t{...props}\n\t/>\n));\nTitle.displayName = SheetPrimitive.Title.displayName;\n\n/**\n * A group container for the title and actions of a sheet. Typically rendered as a child of `Sheet.Header`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-title-group\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst TitleGroup = forwardRef<\n\tComponentRef<\"div\">,\n\tHTMLAttributes<HTMLDivElement>\n>(({ children, className, ...props }, ref) => (\n\t<div\n\t\tclassName={cx(\"flex items-center justify-between gap-2\", className)}\n\t\t{...props}\n\t\tref={ref}\n\t>\n\t\t{children}\n\t</div>\n));\nTitleGroup.displayName = \"SheetTitleGroup\";\n\n/**\n * A description for a sheet. Typically rendered as a child of `Sheet.Header`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-description\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Description = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Description>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Description>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Description\n\t\tref={ref}\n\t\tclassName={cx(\"text-body text-sm\", className)}\n\t\t{...props}\n\t/>\n));\nDescription.displayName = SheetPrimitive.Description.displayName;\n\n/**\n * A group container for the actions of a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-actions\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Actions = forwardRef<ComponentRef<\"div\">, HTMLAttributes<HTMLDivElement>>(\n\t({ children, className, ...props }, ref) => (\n\t\t<div\n\t\t\tclassName={cx(\"flex h-full items-center gap-2\", className)}\n\t\t\t{...props}\n\t\t\tref={ref}\n\t\t>\n\t\t\t{children}\n\t\t</div>\n\t),\n);\nActions.displayName = \"SheetActions\";\n\n/**\n * A container that overlays the current view from the edge of the screen.\n * It is a lightweight way of allowing users to complete a task without losing\n * contextual information of the view beneath it.\n *\n * @see https://mantle.ngrok.com/components/sheet\n *\n * @example\n * ```tsx\n * // Triggering a stateful sheet\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Sheet = {\n\t/**\n\t * The root component for a `Sheet`. Should compose the `Sheet.Trigger` and `Sheet.Content`.\n\t * Acts as a stateful provider for the Sheet's open/closed state.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet\n\t *\n\t * @example\n\t * ```tsx\n\t * // Triggering a stateful sheet\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tRoot,\n\t/**\n\t * A group container for the actions of a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-actions\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * ```\n\t */\n\tActions,\n\t/**\n\t * The body container for a `Sheet`. This is where you would typically place the main content of the sheet, such as forms or text.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-body\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tBody,\n\t/**\n\t * The close button for a `Sheet`. Should be rendered as a child of the `Sheet.Content` component.\n\t * Usually contained within the `Sheet.Footer` component.\n\t * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-close\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Footer>\n\t * <Sheet.Close asChild>\n\t * <Button type=\"button\">Close</Button>\n\t * </Sheet.Close>\n\t * </Sheet.Footer>\n\t * ```\n\t */\n\tClose,\n\t/**\n\t * An icon button that closes the `Sheet` when clicked.\n\t * Should be rendered within the `Sheet.Header` as a child of `Sheet.Actions`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-close-icon-button\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tCloseIconButton,\n\t/**\n\t * The main container for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n\t * Renders on top of the overlay backdrop.\n\t * Should contain the `Sheet.Header`, `Sheet.Body`, and `Sheet.Footer`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-content\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tContent,\n\t/**\n\t * A description for a sheet. Typically rendered as a child of `Sheet.Header`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-description\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * <Sheet.Description>\n\t * This action cannot be undone.\n\t * </Sheet.Description>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tDescription,\n\t/**\n\t * The footer container for a `Sheet`. This is where you would typically place close and submit buttons.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-footer\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * <Sheet.Footer>\n\t * <Sheet.Close asChild>\n\t * <Button type=\"button\">Close</Button>\n\t * </Sheet.Close>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Save\n\t * </Button>\n\t * </Sheet.Footer>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tFooter,\n\t/**\n\t * The header container for a `Sheet`. This is where you would typically place the title, description, and actions.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-header\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * <Sheet.Description>\n\t * This action cannot be undone.\n\t * </Sheet.Description>\n\t * </Sheet.Header>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tHeader,\n\t/**\n\t * The title for a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n\t * Defaults to an `h2` element, but can be changed via the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-title\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tTitle,\n\t/**\n\t * A group container for the title and actions of a sheet. Typically rendered as a child of `Sheet.Header`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-title-group\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tTitleGroup,\n\t/**\n\t * The button trigger for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n\t * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-trigger\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tTrigger,\n} as const;\n\nexport {\n\t//,\n\tSheet,\n};\n"],"mappings":"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","names":["XIcon","cva","forwardRef","jsx","jsxs","Root","Trigger","Close","SheetPortal","Portal","SheetOverlay","forwardRef","className","props","ref","Overlay","cx","SheetVariants","cva","Content","children","onInteractOutside","onPointerDownOutside","preferredWidth","side","event","preventCloseOnPromptInteraction","CloseIconButton","size","type","label","appearance","IconButton","XIcon","Body","Header","Footer","Title","TitleGroup","Description","Actions","Sheet"]}
1
+ {"version":3,"sources":["../src/components/sheet/sheet.tsx"],"sourcesContent":["import { XIcon } from \"@phosphor-icons/react/X\";\nimport { type VariantProps, cva } from \"class-variance-authority\";\nimport type {\n\tComponentPropsWithoutRef,\n\tComponentRef,\n\tHTMLAttributes,\n} from \"react\";\nimport { forwardRef } from \"react\";\nimport { cx } from \"../../utils/cx/cx.js\";\nimport { IconButton, type IconButtonProps } from \"../button/icon-button.js\";\nimport * as SheetPrimitive from \"../dialog/primitive.js\";\nimport { preventCloseOnPromptInteraction } from \"../toast/toast.js\";\n\n/**\n * The root component for a `Sheet`. Should compose the `Sheet.Trigger` and `Sheet.Content`.\n * Acts as a stateful provider for the Sheet's open/closed state.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet\n *\n * @example\n * ```tsx\n * // Triggering a stateful sheet\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Root = SheetPrimitive.Root;\nRoot.displayName = \"Sheet\";\n\n/**\n * The button trigger for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-trigger\n *\n * @example\n * ```tsx\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Trigger = SheetPrimitive.Trigger;\nTrigger.displayName = \"SheetTrigger\";\n\n/**\n * The close button for a `Sheet`. Should be rendered as a child of the `Sheet.Content` component.\n * Usually contained within the `Sheet.Footer` component.\n * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-close\n *\n * @example\n * ```tsx\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Close = SheetPrimitive.Close;\nClose.displayName = \"SheetClose\";\n\n/**\n * The portal for a sheet. Should be rendered as a child of the `Sheet` component.\n * Renders a portal that the `SheetOverlay` and `Sheet.Content` is rendered into.\n *\n * @private\n */\nconst SheetPortal = SheetPrimitive.Portal;\nSheetPortal.displayName = \"SheetPortal\";\n\n/**\n * The overlay backdrop for a sheet. Should be rendered as a child of the `SheetPortal` component.\n *\n * You likely don't need to use this component directly, as it is used internally by the `Sheet.Content` component.\n *\n * @private\n */\nconst SheetOverlay = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Overlay>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Overlay>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Overlay\n\t\tclassName={cx(\n\t\t\t\"bg-overlay data-state-closed:animate-out data-state-closed:fade-out-0 data-state-open:animate-in data-state-open:fade-in-0 fixed inset-0 z-40 backdrop-blur-xs\",\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t\tref={ref}\n\t/>\n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst SheetVariants = cva(\n\t\"bg-dialog border-dialog inset-y-0 h-full w-full fixed z-40 flex flex-col shadow-lg outline-hidden transition ease-in-out focus-within:outline-hidden data-state-closed:duration-100 data-state-closed:animate-out data-state-open:duration-100 data-state-open:animate-in\",\n\t{\n\t\tvariants: {\n\t\t\t/**\n\t\t\t * The side of the screen the sheet should slide in from.\n\t\t\t */\n\t\t\tside: {\n\t\t\t\tleft: \"data-state-closed:slide-out-to-left data-state-open:slide-in-from-left left-0 border-r\",\n\t\t\t\tright:\n\t\t\t\t\t\"data-state-closed:slide-out-to-right data-state-open:slide-in-from-right right-0 border-l\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tside: \"right\",\n\t\t},\n\t},\n);\n\ntype SheetContentProps = ComponentPropsWithoutRef<\n\ttypeof SheetPrimitive.Content\n> &\n\tVariantProps<typeof SheetVariants> & {\n\t\t/**\n\t\t * The preferred width of the `Sheet.Content` as a tailwind `max-w-` class.\n\t\t *\n\t\t * By default, a `Sheet`'s content width is responsive with a default\n\t\t * preferred width: the maximum width of the `Sheet.Content` when the window\n\t\t * viewport is larger than the mobile breakpoint (`sm`).\n\t\t *\n\t\t * @default `sm:max-w-[30rem]`\n\t\t */\n\t\tpreferredWidth?: `sm:max-w-${string}`;\n\t};\n\n/**\n * The main container for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n * Renders on top of the overlay backdrop.\n * Should contain the `Sheet.Header`, `Sheet.Body`, and `Sheet.Footer`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-content\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Content = forwardRef<ComponentRef<\"div\">, SheetContentProps>(\n\t(\n\t\t{\n\t\t\tchildren,\n\t\t\tclassName,\n\t\t\tonInteractOutside,\n\t\t\tonPointerDownOutside,\n\t\t\tpreferredWidth = \"sm:max-w-[30rem]\",\n\t\t\tside = \"right\",\n\t\t\t...props\n\t\t},\n\t\tref,\n\t) => (\n\t\t<SheetPortal>\n\t\t\t<SheetOverlay />\n\t\t\t<SheetPrimitive.Content\n\t\t\t\tclassName={cx(SheetVariants({ side }), preferredWidth, className)}\n\t\t\t\tonInteractOutside={(event) => {\n\t\t\t\t\tpreventCloseOnPromptInteraction(event);\n\t\t\t\t\tonInteractOutside?.(event);\n\t\t\t\t}}\n\t\t\t\tonPointerDownOutside={(event) => {\n\t\t\t\t\tpreventCloseOnPromptInteraction(event);\n\t\t\t\t\tonPointerDownOutside?.(event);\n\t\t\t\t}}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</SheetPrimitive.Content>\n\t\t</SheetPortal>\n\t),\n);\nContent.displayName = SheetPrimitive.Content.displayName;\n\ntype SheetCloseIconButtonProps = Partial<Omit<IconButtonProps, \"icon\">>;\n\n/**\n * An icon button that closes the `Sheet` when clicked.\n * Should be rendered within the `Sheet.Header` as a child of `Sheet.Actions`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-close-icon-button\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst CloseIconButton = ({\n\tsize = \"md\",\n\ttype = \"button\",\n\tlabel = \"Close Sheet\",\n\tappearance = \"ghost\",\n\t...props\n}: SheetCloseIconButtonProps) => (\n\t<SheetPrimitive.Close asChild>\n\t\t<IconButton\n\t\t\tappearance={appearance}\n\t\t\ticon={<XIcon />}\n\t\t\tlabel={label}\n\t\t\tsize={size}\n\t\t\ttype={type}\n\t\t\t{...props}\n\t\t/>\n\t</SheetPrimitive.Close>\n);\nCloseIconButton.displayName = \"SheetCloseIconButton\";\n\n/**\n * The body container for a `Sheet`. This is where you would typically place the main content of the sheet, such as forms or text.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-body\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Body = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div\n\t\tclassName={cx(\"scrollbar text-body flex-1 overflow-y-auto p-6\", className)}\n\t\t{...props}\n\t/>\n);\nBody.displayName = \"SheetBody\";\n\n/**\n * The header container for a `Sheet`. This is where you would typically place the title, description, and actions.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-header\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Header = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div\n\t\tclassName={cx(\n\t\t\t\"border-dialog-muted flex shrink-0 flex-col gap-2 border-b py-4 pl-6 pr-4\",\n\t\t\t\"has-[.icon-button]:pr-4\", // when there are actions in the header, shorten the padding\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t/>\n);\nHeader.displayName = \"SheetHeader\";\n\n/**\n * The footer container for a `Sheet`. This is where you would typically place close and submit buttons.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-footer\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Footer = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div\n\t\tclassName={cx(\n\t\t\t\"border-dialog-muted flex shrink-0 justify-end gap-2 border-t px-6 py-2.5\",\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t/>\n);\nFooter.displayName = \"SheetFooter\";\n\n/**\n * The title for a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n * Defaults to an `h2` element, but can be changed via the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-title\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Title = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Title>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Title>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Title\n\t\tref={ref}\n\t\tclassName={cx(\"text-strong flex-1 truncate text-lg font-medium\", className)}\n\t\t{...props}\n\t/>\n));\nTitle.displayName = SheetPrimitive.Title.displayName;\n\n/**\n * A group container for the title and actions of a sheet. Typically rendered as a child of `Sheet.Header`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-title-group\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst TitleGroup = forwardRef<\n\tComponentRef<\"div\">,\n\tHTMLAttributes<HTMLDivElement>\n>(({ children, className, ...props }, ref) => (\n\t<div\n\t\tclassName={cx(\"flex items-center justify-between gap-2\", className)}\n\t\t{...props}\n\t\tref={ref}\n\t>\n\t\t{children}\n\t</div>\n));\nTitleGroup.displayName = \"SheetTitleGroup\";\n\n/**\n * A description for a sheet. Typically rendered as a child of `Sheet.Header`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-description\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Description = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Description>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Description>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Description\n\t\tref={ref}\n\t\tclassName={cx(\"text-body text-sm\", className)}\n\t\t{...props}\n\t/>\n));\nDescription.displayName = SheetPrimitive.Description.displayName;\n\n/**\n * A group container for the actions of a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-actions\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Actions = forwardRef<ComponentRef<\"div\">, HTMLAttributes<HTMLDivElement>>(\n\t({ children, className, ...props }, ref) => (\n\t\t<div\n\t\t\tclassName={cx(\"flex h-full items-center gap-2\", className)}\n\t\t\t{...props}\n\t\t\tref={ref}\n\t\t>\n\t\t\t{children}\n\t\t</div>\n\t),\n);\nActions.displayName = \"SheetActions\";\n\n/**\n * A container that overlays the current view from the edge of the screen.\n * It is a lightweight way of allowing users to complete a task without losing\n * contextual information of the view beneath it.\n *\n * @see https://mantle.ngrok.com/components/sheet\n *\n * @example\n * ```tsx\n * // Triggering a stateful sheet\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Sheet = {\n\t/**\n\t * The root component for a `Sheet`. Should compose the `Sheet.Trigger` and `Sheet.Content`.\n\t * Acts as a stateful provider for the Sheet's open/closed state.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet\n\t *\n\t * @example\n\t * ```tsx\n\t * // Triggering a stateful sheet\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tRoot,\n\t/**\n\t * A group container for the actions of a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-actions\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * ```\n\t */\n\tActions,\n\t/**\n\t * The body container for a `Sheet`. This is where you would typically place the main content of the sheet, such as forms or text.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-body\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tBody,\n\t/**\n\t * The close button for a `Sheet`. Should be rendered as a child of the `Sheet.Content` component.\n\t * Usually contained within the `Sheet.Footer` component.\n\t * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-close\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Footer>\n\t * <Sheet.Close asChild>\n\t * <Button type=\"button\">Close</Button>\n\t * </Sheet.Close>\n\t * </Sheet.Footer>\n\t * ```\n\t */\n\tClose,\n\t/**\n\t * An icon button that closes the `Sheet` when clicked.\n\t * Should be rendered within the `Sheet.Header` as a child of `Sheet.Actions`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-close-icon-button\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tCloseIconButton,\n\t/**\n\t * The main container for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n\t * Renders on top of the overlay backdrop.\n\t * Should contain the `Sheet.Header`, `Sheet.Body`, and `Sheet.Footer`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-content\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tContent,\n\t/**\n\t * A description for a sheet. Typically rendered as a child of `Sheet.Header`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-description\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * <Sheet.Description>\n\t * This action cannot be undone.\n\t * </Sheet.Description>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tDescription,\n\t/**\n\t * The footer container for a `Sheet`. This is where you would typically place close and submit buttons.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-footer\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * <Sheet.Footer>\n\t * <Sheet.Close asChild>\n\t * <Button type=\"button\">Close</Button>\n\t * </Sheet.Close>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Save\n\t * </Button>\n\t * </Sheet.Footer>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tFooter,\n\t/**\n\t * The header container for a `Sheet`. This is where you would typically place the title, description, and actions.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-header\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * <Sheet.Description>\n\t * This action cannot be undone.\n\t * </Sheet.Description>\n\t * </Sheet.Header>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tHeader,\n\t/**\n\t * The title for a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n\t * Defaults to an `h2` element, but can be changed via the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-title\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tTitle,\n\t/**\n\t * A group container for the title and actions of a sheet. Typically rendered as a child of `Sheet.Header`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-title-group\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tTitleGroup,\n\t/**\n\t * The button trigger for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n\t * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-trigger\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tTrigger,\n} as const;\n\nexport {\n\t//,\n\tSheet,\n};\n"],"mappings":"oeAAA,OAAS,SAAAA,MAAa,0BACtB,OAA4B,OAAAC,MAAW,2BAMvC,OAAS,cAAAC,MAAkB,QA4L1B,cAAAC,EA6GC,QAAAC,MA7GD,oBArFD,IAAMC,EAAsBA,EAC5BA,EAAK,YAAc,QA2BnB,IAAMC,EAAyBA,EAC/BA,EAAQ,YAAc,eAiCtB,IAAMC,EAAuBA,EAC7BA,EAAM,YAAc,aAQpB,IAAMC,EAA6BC,EACnCD,EAAY,YAAc,cAS1B,IAAME,EAAeC,EAGnB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC3BX,EAAgBY,EAAf,CACA,UAAWC,EACV,iKACAJ,CACD,EACC,GAAGC,EACJ,IAAKC,EACN,CACA,EACDJ,EAAa,YAA6BK,EAAQ,YAElD,IAAME,EAAgBC,EACrB,4QACA,CACC,SAAU,CAIT,KAAM,CACL,KAAM,yFACN,MACC,2FACF,CACD,EACA,gBAAiB,CAChB,KAAM,OACP,CACD,CACD,EAoEMC,EAAUR,EACf,CACC,CACC,SAAAS,EACA,UAAAR,EACA,kBAAAS,EACA,qBAAAC,EACA,eAAAC,EAAiB,mBACjB,KAAAC,EAAO,QACP,GAAGX,CACJ,EACAC,IAEAV,EAACI,EAAA,CACA,UAAAL,EAACO,EAAA,EAAa,EACdP,EAAgBgB,EAAf,CACA,UAAWH,EAAGC,EAAc,CAAE,KAAAO,CAAK,CAAC,EAAGD,EAAgBX,CAAS,EAChE,kBAAoBa,GAAU,CAC7BC,EAAgCD,CAAK,EACrCJ,IAAoBI,CAAK,CAC1B,EACA,qBAAuBA,GAAU,CAChCC,EAAgCD,CAAK,EACrCH,IAAuBG,CAAK,CAC7B,EACA,IAAKX,EACJ,GAAGD,EAEH,SAAAO,EACF,GACD,CAEF,EACAD,EAAQ,YAA6BA,EAAQ,YAqD7C,IAAMQ,EAAkB,CAAC,CACxB,KAAAC,EAAO,KACP,KAAAC,EAAO,SACP,MAAAC,EAAQ,cACR,WAAAC,EAAa,QACb,GAAGlB,CACJ,IACCV,EAAgBI,EAAf,CAAqB,QAAO,GAC5B,SAAAJ,EAAC6B,EAAA,CACA,WAAYD,EACZ,KAAM5B,EAAC8B,EAAA,EAAM,EACb,MAAOH,EACP,KAAMF,EACN,KAAMC,EACL,GAAGhB,EACL,EACD,EAEDc,EAAgB,YAAc,uBAmD9B,IAAMO,EAAO,CAAC,CAAE,UAAAtB,EAAW,GAAGC,CAAM,IACnCV,EAAC,OACA,UAAWa,EAAG,iDAAkDJ,CAAS,EACxE,GAAGC,EACL,EAEDqB,EAAK,YAAc,YAmDnB,IAAMC,EAAS,CAAC,CAAE,UAAAvB,EAAW,GAAGC,CAAM,IACrCV,EAAC,OACA,UAAWa,EACV,2EACA,0BACAJ,CACD,EACC,GAAGC,EACL,EAEDsB,EAAO,YAAc,cAmDrB,IAAMC,EAAS,CAAC,CAAE,UAAAxB,EAAW,GAAGC,CAAM,IACrCV,EAAC,OACA,UAAWa,EACV,2EACAJ,CACD,EACC,GAAGC,EACL,EAEDuB,EAAO,YAAc,cAmDrB,IAAMC,EAAQ1B,EAGZ,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC3BX,EAAgBkC,EAAf,CACA,IAAKvB,EACL,UAAWE,EAAG,kDAAmDJ,CAAS,EACzE,GAAGC,EACL,CACA,EACDwB,EAAM,YAA6BA,EAAM,YAkDzC,IAAMC,EAAa3B,EAGjB,CAAC,CAAE,SAAAS,EAAU,UAAAR,EAAW,GAAGC,CAAM,EAAGC,IACrCX,EAAC,OACA,UAAWa,EAAG,0CAA2CJ,CAAS,EACjE,GAAGC,EACJ,IAAKC,EAEJ,SAAAM,EACF,CACA,EACDkB,EAAW,YAAc,kBAkDzB,IAAMC,EAAc5B,EAGlB,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAC3BX,EAAgBoC,EAAf,CACA,IAAKzB,EACL,UAAWE,EAAG,oBAAqBJ,CAAS,EAC3C,GAAGC,EACL,CACA,EACD0B,EAAY,YAA6BA,EAAY,YAkDrD,IAAMC,EAAU7B,EACf,CAAC,CAAE,SAAAS,EAAU,UAAAR,EAAW,GAAGC,CAAM,EAAGC,IACnCX,EAAC,OACA,UAAWa,EAAG,iCAAkCJ,CAAS,EACxD,GAAGC,EACJ,IAAKC,EAEJ,SAAAM,EACF,CAEF,EACAoB,EAAQ,YAAc,eAoGtB,IAAMC,EAAQ,CA6Bb,KAAApC,EAgBA,QAAAmC,EAwBA,KAAAN,EAiBA,MAAA3B,EAmBA,gBAAAoB,EAgCA,QAAAR,EAqBA,YAAAoB,EAgCA,OAAAH,EAwBA,OAAAD,EAmBA,MAAAE,EAkBA,WAAAC,EAqBA,QAAAhC,CACD","names":["XIcon","cva","forwardRef","jsx","jsxs","Root","Trigger","Close","SheetPortal","Portal","SheetOverlay","forwardRef","className","props","ref","Overlay","cx","SheetVariants","cva","Content","children","onInteractOutside","onPointerDownOutside","preferredWidth","side","event","preventCloseOnPromptInteraction","CloseIconButton","size","type","label","appearance","IconButton","XIcon","Body","Header","Footer","Title","TitleGroup","Description","Actions","Sheet"]}
package/dist/skeleton.js CHANGED
@@ -1,2 +1,2 @@
1
- import{a as o}from"./chunk-PFXFESEN.js";import{Slot as l}from"@radix-ui/react-slot";import{forwardRef as s}from"react";import{jsx as i}from"react/jsx-runtime";var e=s(({asChild:t=!1,className:r,...n},p)=>i(t?l:"div",{className:o("dark-high-contrast:bg-black/30 high-contrast:bg-black/30 h-4 animate-pulse rounded-md bg-gray-300/25 dark:bg-gray-950/10",r),ref:p,...n}));e.displayName="Skeleton";export{e as Skeleton};
1
+ import{a as e}from"./chunk-UNFO4DZV.js";import{a as o}from"./chunk-PFXFESEN.js";import{forwardRef as s}from"react";import{jsx as i}from"react/jsx-runtime";var t=s(({asChild:r=!1,className:n,...p},l)=>i(r?e:"div",{className:o("dark-high-contrast:bg-black/30 high-contrast:bg-black/30 h-4 animate-pulse rounded-md bg-gray-300/25 dark:bg-gray-950/10",n),ref:l,...p}));t.displayName="Skeleton";export{t as Skeleton};
2
2
  //# sourceMappingURL=skeleton.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/components/skeleton/skeleton.tsx"],"sourcesContent":["import { Slot } from \"@radix-ui/react-slot\";\nimport { type ComponentProps, type ComponentRef, forwardRef } from \"react\";\nimport type { SelfClosingWithAsChild } from \"../../types/as-child.js\";\nimport { cx } from \"../../utils/cx/cx.js\";\n\ntype Props = Exclude<ComponentProps<\"div\">, \"children\"> &\n\tSelfClosingWithAsChild;\n\n/**\n * A skeleton is a placeholder for content that is loading.\n * By using a skeleton, you can give the user an idea of what the content will\n * look like and reduce the perceived loading time and CLS (Cumulative Layout Shift).\n *\n * @note Default height is 1rem.\n *\n * @see https://mantle.ngrok.com/components/skeleton#api\n *\n * @example\n * ```tsx\n * <Skeleton className=\"w-1/2\" />\n *\n * <Skeleton className=\"w-1/2\" />\n *\n * <Skeleton className=\"h-12 w-12 rounded-full\" />\n * ```\n */\nconst Skeleton = forwardRef<ComponentRef<\"div\">, Props>(\n\t({ asChild = false, className, ...props }, ref) => {\n\t\tconst Component = asChild ? Slot : \"div\";\n\n\t\treturn (\n\t\t\t<Component\n\t\t\t\tclassName={cx(\n\t\t\t\t\t\"dark-high-contrast:bg-black/30 high-contrast:bg-black/30 h-4 animate-pulse rounded-md bg-gray-300/25 dark:bg-gray-950/10\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t);\n\t},\n);\nSkeleton.displayName = \"Skeleton\";\n\nexport {\n\t//,\n\tSkeleton,\n};\n"],"mappings":"wCAAA,OAAS,QAAAA,MAAY,uBACrB,OAAiD,cAAAC,MAAkB,QA8BhE,cAAAC,MAAA,oBALH,IAAMC,EAAWC,EAChB,CAAC,CAAE,QAAAC,EAAU,GAAO,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAIzCN,EAHiBG,EAAUI,EAAO,MAGjC,CACA,UAAWC,EACV,2HACAJ,CACD,EACA,IAAKE,EACJ,GAAGD,EACL,CAGH,EACAJ,EAAS,YAAc","names":["Slot","forwardRef","jsx","Skeleton","forwardRef","asChild","className","props","ref","Slot","cx"]}
1
+ {"version":3,"sources":["../src/components/skeleton/skeleton.tsx"],"sourcesContent":["import { type ComponentProps, type ComponentRef, forwardRef } from \"react\";\nimport type { SelfClosingWithAsChild } from \"../../types/as-child.js\";\nimport { cx } from \"../../utils/cx/cx.js\";\nimport { Slot } from \"../slot/index.js\";\n\ntype Props = Exclude<ComponentProps<\"div\">, \"children\"> &\n\tSelfClosingWithAsChild;\n\n/**\n * A skeleton is a placeholder for content that is loading.\n * By using a skeleton, you can give the user an idea of what the content will\n * look like and reduce the perceived loading time and CLS (Cumulative Layout Shift).\n *\n * @note Default height is 1rem.\n *\n * @see https://mantle.ngrok.com/components/skeleton#api\n *\n * @example\n * ```tsx\n * <Skeleton className=\"w-1/2\" />\n *\n * <Skeleton className=\"w-1/2\" />\n *\n * <Skeleton className=\"h-12 w-12 rounded-full\" />\n * ```\n */\nconst Skeleton = forwardRef<ComponentRef<\"div\">, Props>(\n\t({ asChild = false, className, ...props }, ref) => {\n\t\tconst Component = asChild ? Slot : \"div\";\n\n\t\treturn (\n\t\t\t<Component\n\t\t\t\tclassName={cx(\n\t\t\t\t\t\"dark-high-contrast:bg-black/30 high-contrast:bg-black/30 h-4 animate-pulse rounded-md bg-gray-300/25 dark:bg-gray-950/10\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t);\n\t},\n);\nSkeleton.displayName = \"Skeleton\";\n\nexport {\n\t//,\n\tSkeleton,\n};\n"],"mappings":"gFAAA,OAAiD,cAAAA,MAAkB,QA+BhE,cAAAC,MAAA,oBALH,IAAMC,EAAWC,EAChB,CAAC,CAAE,QAAAC,EAAU,GAAO,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAIzCN,EAHiBG,EAAUI,EAAO,MAGjC,CACA,UAAWC,EACV,2HACAJ,CACD,EACA,IAAKE,EACJ,GAAGD,EACL,CAGH,EACAJ,EAAS,YAAc","names":["forwardRef","jsx","Skeleton","forwardRef","asChild","className","props","ref","Slot","cx"]}
package/dist/slot.d.ts ADDED
@@ -0,0 +1,20 @@
1
+ import * as react from 'react';
2
+ import * as _radix_ui_react_slot from '@radix-ui/react-slot';
3
+
4
+ /**
5
+ * Merges its props onto its immediate child. This is useful for creating
6
+ * components that can be rendered as different elements. Automatically merges
7
+ * className props using `cx` for proper Tailwind class handling.
8
+ *
9
+ * @see https://mantle.ngrok.com/components/slot#api
10
+ *
11
+ * @example
12
+ * ```tsx
13
+ * <Slot className="custom-class">
14
+ * <a href="/">Home</a>
15
+ * </Slot>
16
+ * ```
17
+ */
18
+ declare const Slot: react.ForwardRefExoticComponent<Omit<_radix_ui_react_slot.SlotProps & react.RefAttributes<HTMLElement>, "ref"> & react.RefAttributes<HTMLElement>>;
19
+
20
+ export { Slot };
package/dist/slot.js ADDED
@@ -0,0 +1,2 @@
1
+ import{a}from"./chunk-UNFO4DZV.js";import"./chunk-PFXFESEN.js";export{a as Slot};
2
+ //# sourceMappingURL=slot.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
package/dist/toast.js CHANGED
@@ -1,2 +1,2 @@
1
- import{a as o,b as t,c as r}from"./chunk-WY3TZBNK.js";import"./chunk-VBNDWNIJ.js";import"./chunk-6J7D73WA.js";import"./chunk-NJNFZ2EG.js";import"./chunk-KMNACVH6.js";import"./chunk-2NIR7PCL.js";import"./chunk-NZ6DRFAL.js";import"./chunk-PFXFESEN.js";export{r as Toast,o as Toaster,t as makeToast};
1
+ import{a as o,b as t,c as r}from"./chunk-UKS7NFNC.js";import"./chunk-VBNDWNIJ.js";import"./chunk-6J7D73WA.js";import"./chunk-NJNFZ2EG.js";import"./chunk-KMNACVH6.js";import"./chunk-2NIR7PCL.js";import"./chunk-UNFO4DZV.js";import"./chunk-NZ6DRFAL.js";import"./chunk-PFXFESEN.js";export{r as Toast,o as Toaster,t as makeToast};
2
2
  //# sourceMappingURL=toast.js.map
package/dist/tooltip.d.ts CHANGED
@@ -7,7 +7,7 @@ import * as TooltipPrimitive from '@radix-ui/react-tooltip';
7
7
  * Wraps your app to provide global functionality to your tooltips.
8
8
  * Only one instance of this component should be rendered in your app, preferably at the root.
9
9
  *
10
- * @see https://mantle.ngrok.com/tooltip#tooltip-provider
10
+ * @see https://mantle.ngrok.com/components/tooltip#tooltip-provider
11
11
  *
12
12
  * @example
13
13
  * ```tsx
@@ -25,7 +25,7 @@ declare const TooltipProvider: {
25
25
  * This is the root, stateful component that manages the open/closed state of the tooltip.
26
26
  * Will throw if you have not wrapped your app in a `TooltipProvider`.
27
27
  *
28
- * @see https://mantle.ngrok.com/tooltip#tooltip-root
28
+ * @see https://mantle.ngrok.com/components/tooltip#tooltip-root
29
29
  *
30
30
  * @example
31
31
  * ```tsx
@@ -48,7 +48,7 @@ declare namespace Root {
48
48
  /**
49
49
  * The trigger button that opens the tooltip.
50
50
  *
51
- * @see https://mantle.ngrok.com/tooltip#tooltip-trigger
51
+ * @see https://mantle.ngrok.com/components/tooltip#tooltip-trigger
52
52
  *
53
53
  * @example
54
54
  * ```tsx
@@ -73,7 +73,7 @@ declare namespace Trigger {
73
73
  * This is the root, stateful component that manages the open/closed state of the tooltip.
74
74
  * Will throw if you have not wrapped your app in a `TooltipProvider`.
75
75
  *
76
- * @see https://mantle.ngrok.com/tooltip
76
+ * @see https://mantle.ngrok.com/components/tooltip
77
77
  *
78
78
  * @example
79
79
  * ```tsx
@@ -95,7 +95,7 @@ declare const Tooltip: {
95
95
  * This is the root, stateful component that manages the open/closed state of the tooltip.
96
96
  * Will throw if you have not wrapped your app in a `TooltipProvider`.
97
97
  *
98
- * @see https://mantle.ngrok.com/tooltip#tooltip-root
98
+ * @see https://mantle.ngrok.com/components/tooltip#tooltip-root
99
99
  *
100
100
  * @example
101
101
  * ```tsx
@@ -115,7 +115,7 @@ declare const Tooltip: {
115
115
  /**
116
116
  * The content to render inside the tooltip.
117
117
  *
118
- * @see https://mantle.ngrok.com/tooltip#tooltip-content
118
+ * @see https://mantle.ngrok.com/components/tooltip#tooltip-content
119
119
  *
120
120
  * @example
121
121
  * ```tsx
@@ -135,7 +135,7 @@ declare const Tooltip: {
135
135
  /**
136
136
  * The trigger button that opens the tooltip.
137
137
  *
138
- * @see https://mantle.ngrok.com/tooltip#tooltip-trigger
138
+ * @see https://mantle.ngrok.com/components/tooltip#tooltip-trigger
139
139
  *
140
140
  * @example
141
141
  * ```tsx