@moduix/solid-tailwind 1.0.0 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (124) hide show
  1. package/dist/components/accordion/Accordion.js +19 -13
  2. package/dist/components/accordion/Accordion.jsx +7 -7
  3. package/dist/components/alert/Alert.js +19 -13
  4. package/dist/components/alert/Alert.jsx +7 -7
  5. package/dist/components/angle-slider/AngleSlider.d.ts +2 -6
  6. package/dist/components/angle-slider/AngleSlider.js +21 -16
  7. package/dist/components/angle-slider/AngleSlider.jsx +10 -11
  8. package/dist/components/avatar/Avatar.js +10 -7
  9. package/dist/components/avatar/Avatar.jsx +6 -6
  10. package/dist/components/bleed/Bleed.js +1 -1
  11. package/dist/components/bleed/Bleed.jsx +1 -1
  12. package/dist/components/button/Button.js +1 -6
  13. package/dist/components/button/Button.jsx +2 -4
  14. package/dist/components/card/Card.js +54 -44
  15. package/dist/components/card/Card.jsx +12 -12
  16. package/dist/components/carousel/Carousel.d.ts +1 -1
  17. package/dist/components/carousel/Carousel.js +32 -23
  18. package/dist/components/carousel/Carousel.jsx +12 -13
  19. package/dist/components/checkbox/Checkbox.js +16 -14
  20. package/dist/components/checkbox/Checkbox.jsx +6 -6
  21. package/dist/components/clipboard/Clipboard.js +28 -17
  22. package/dist/components/clipboard/Clipboard.jsx +12 -11
  23. package/dist/components/collapsible/Collapsible.js +16 -11
  24. package/dist/components/collapsible/Collapsible.jsx +6 -6
  25. package/dist/components/color-picker/ColorPicker.js +69 -48
  26. package/dist/components/color-picker/ColorPicker.jsx +28 -28
  27. package/dist/components/combobox/Combobox.js +44 -31
  28. package/dist/components/combobox/Combobox.jsx +18 -18
  29. package/dist/components/command-palette/CommandPalette.js +71 -52
  30. package/dist/components/command-palette/CommandPalette.jsx +28 -31
  31. package/dist/components/container/Container.js +5 -5
  32. package/dist/components/container/Container.jsx +5 -5
  33. package/dist/components/date-input/DateInput.js +18 -12
  34. package/dist/components/date-input/DateInput.jsx +7 -7
  35. package/dist/components/date-picker/DatePicker.js +73 -51
  36. package/dist/components/date-picker/DatePicker.jsx +29 -29
  37. package/dist/components/dialog/Dialog.js +30 -20
  38. package/dist/components/dialog/Dialog.jsx +10 -10
  39. package/dist/components/drawer/Drawer.js +45 -30
  40. package/dist/components/drawer/Drawer.jsx +15 -15
  41. package/dist/components/editable/Editable.js +24 -17
  42. package/dist/components/editable/Editable.jsx +10 -10
  43. package/dist/components/empty/Empty.js +1 -1
  44. package/dist/components/empty/Empty.jsx +1 -1
  45. package/dist/components/file-upload/FileUpload.js +39 -28
  46. package/dist/components/file-upload/FileUpload.jsx +17 -17
  47. package/dist/components/floating-panel/FloatingPanel.js +35 -23
  48. package/dist/components/floating-panel/FloatingPanel.jsx +12 -12
  49. package/dist/components/hover-card/HoverCard.js +16 -11
  50. package/dist/components/hover-card/HoverCard.jsx +6 -6
  51. package/dist/components/image-cropper/ImageCropper.js +21 -14
  52. package/dist/components/image-cropper/ImageCropper.jsx +7 -7
  53. package/dist/components/input-group/InputGroup.js +3 -2
  54. package/dist/components/input-group/InputGroup.jsx +3 -2
  55. package/dist/components/json-tree-view/JsonTreeView.js +1 -1
  56. package/dist/components/json-tree-view/JsonTreeView.jsx +1 -1
  57. package/dist/components/lightbox/Lightbox.d.ts +1 -0
  58. package/dist/components/lightbox/Lightbox.js +41 -27
  59. package/dist/components/lightbox/Lightbox.jsx +13 -12
  60. package/dist/components/listbox/Listbox.js +48 -32
  61. package/dist/components/listbox/Listbox.jsx +17 -17
  62. package/dist/components/marquee/Marquee.js +18 -12
  63. package/dist/components/marquee/Marquee.jsx +9 -9
  64. package/dist/components/menu/Menu.js +66 -44
  65. package/dist/components/menu/Menu.jsx +28 -28
  66. package/dist/components/navigation-menu/NavigationMenu.js +36 -24
  67. package/dist/components/navigation-menu/NavigationMenu.jsx +12 -12
  68. package/dist/components/number-input/NumberInput.js +19 -14
  69. package/dist/components/number-input/NumberInput.jsx +9 -9
  70. package/dist/components/pagination/Pagination.js +10 -9
  71. package/dist/components/pagination/Pagination.jsx +8 -8
  72. package/dist/components/password-input/PasswordInput.js +16 -11
  73. package/dist/components/password-input/PasswordInput.jsx +6 -6
  74. package/dist/components/pin-input/PinInput.js +15 -10
  75. package/dist/components/pin-input/PinInput.jsx +6 -6
  76. package/dist/components/popover/Popover.js +37 -25
  77. package/dist/components/popover/Popover.jsx +13 -13
  78. package/dist/components/progress-circular/ProgressCircular.js +18 -13
  79. package/dist/components/progress-circular/ProgressCircular.jsx +8 -8
  80. package/dist/components/progress-linear/ProgressLinear.js +17 -12
  81. package/dist/components/progress-linear/ProgressLinear.jsx +7 -7
  82. package/dist/components/qr-code/QrCode.js +8 -7
  83. package/dist/components/qr-code/QrCode.jsx +6 -6
  84. package/dist/components/rating-group/RatingGroup.js +15 -10
  85. package/dist/components/rating-group/RatingGroup.jsx +6 -6
  86. package/dist/components/segment-group/SegmentGroup.js +17 -12
  87. package/dist/components/segment-group/SegmentGroup.jsx +7 -7
  88. package/dist/components/select/Select.js +50 -35
  89. package/dist/components/select/Select.jsx +20 -20
  90. package/dist/components/sidebar/Sidebar.js +72 -43
  91. package/dist/components/sidebar/Sidebar.jsx +34 -27
  92. package/dist/components/signature-pad/SignaturePad.js +16 -12
  93. package/dist/components/signature-pad/SignaturePad.jsx +8 -8
  94. package/dist/components/slider/Slider.js +29 -20
  95. package/dist/components/slider/Slider.jsx +11 -11
  96. package/dist/components/split-button/SplitButton.d.ts +4 -3
  97. package/dist/components/split-button/SplitButton.js +20 -9
  98. package/dist/components/split-button/SplitButton.jsx +13 -7
  99. package/dist/components/splitter/Splitter.js +13 -9
  100. package/dist/components/splitter/Splitter.jsx +5 -5
  101. package/dist/components/steps/Steps.js +34 -23
  102. package/dist/components/steps/Steps.jsx +12 -12
  103. package/dist/components/swap/Swap.js +9 -6
  104. package/dist/components/swap/Swap.jsx +3 -3
  105. package/dist/components/switch/Switch.js +9 -7
  106. package/dist/components/switch/Switch.jsx +5 -5
  107. package/dist/components/tabs/Tabs.js +18 -12
  108. package/dist/components/tabs/Tabs.jsx +6 -6
  109. package/dist/components/tags-input/TagsInput.js +28 -20
  110. package/dist/components/tags-input/TagsInput.jsx +12 -12
  111. package/dist/components/timer/Timer.js +21 -14
  112. package/dist/components/timer/Timer.jsx +7 -7
  113. package/dist/components/toast/Toast.js +11 -9
  114. package/dist/components/toast/Toast.jsx +7 -7
  115. package/dist/components/toc/Toc.js +31 -20
  116. package/dist/components/toc/Toc.jsx +10 -10
  117. package/dist/components/tooltip/Tooltip.js +13 -9
  118. package/dist/components/tooltip/Tooltip.jsx +5 -5
  119. package/dist/components/tour/Tour.js +38 -26
  120. package/dist/components/tour/Tour.jsx +13 -13
  121. package/dist/components/tree-view/TreeView.js +39 -28
  122. package/dist/components/tree-view/TreeView.jsx +17 -17
  123. package/dist/styles/animations.css +8 -8
  124. package/package.json +1 -1
@@ -16,7 +16,7 @@ const Combobox_ComboboxRoot = function(props) {
16
16
  'unmountOnExit'
17
17
  ]);
18
18
  return <OverlayPortalProvider portalled={local.portalled} portalRef={local.portalRef}>
19
- <Combobox.Root asChild={local.asChild} data-slot="combobox-root" class={cn('box-border flex w-64 max-w-full min-w-0 flex-col gap-1.5 text-foreground', local.class)} lazyMount={local.lazyMount ?? true} unmountOnExit={local.unmountOnExit ?? true} {...others}>
19
+ <Combobox.Root asChild={local.asChild} class={cn('box-border flex w-64 max-w-full min-w-0 flex-col gap-1.5 text-foreground', local.class)} lazyMount={local.lazyMount ?? true} unmountOnExit={local.unmountOnExit ?? true} {...others} data-slot="combobox-root">
20
20
  {local.children}
21
21
  </Combobox.Root>
22
22
  </OverlayPortalProvider>;
@@ -32,7 +32,7 @@ const Combobox_ComboboxRootProvider = function(props) {
32
32
  'unmountOnExit'
33
33
  ]);
34
34
  return <OverlayPortalProvider portalled={local.portalled} portalRef={local.portalRef}>
35
- <Combobox.RootProvider asChild={local.asChild} data-slot="combobox-root-provider" class={cn('box-border flex w-64 max-w-full min-w-0 flex-col gap-1.5 text-foreground', local.class)} lazyMount={local.lazyMount ?? true} unmountOnExit={local.unmountOnExit ?? true} {...others}>
35
+ <Combobox.RootProvider asChild={local.asChild} class={cn('box-border flex w-64 max-w-full min-w-0 flex-col gap-1.5 text-foreground', local.class)} lazyMount={local.lazyMount ?? true} unmountOnExit={local.unmountOnExit ?? true} {...others} data-slot="combobox-root-provider">
36
36
  {local.children}
37
37
  </Combobox.RootProvider>
38
38
  </OverlayPortalProvider>;
@@ -41,20 +41,20 @@ function ComboboxLabel(props) {
41
41
  const [local, others] = splitProps(props, [
42
42
  'class'
43
43
  ]);
44
- return <Combobox.Label data-slot="combobox-label" class={cn('inline-flex items-center text-sm font-medium text-foreground select-none data-disabled:opacity-50', local.class)} {...others}/>;
44
+ return <Combobox.Label class={cn('inline-flex items-center text-sm font-medium text-foreground select-none data-disabled:opacity-50', local.class)} {...others} data-slot="combobox-label"/>;
45
45
  }
46
46
  function ComboboxControl(props) {
47
47
  const [local, others] = splitProps(props, [
48
48
  'class'
49
49
  ]);
50
- return <Combobox.Control data-slot="combobox-control" class={cn('group/combobox-control relative flex w-full min-w-0 items-center rounded-md border border-border bg-background text-foreground outline-1 -outline-offset-1 outline-transparent transition-[background-color,border-color,outline-color] duration-200 ease-in-out data-disabled:opacity-50 data-focus:border-ring data-focus:outline-ring data-invalid:border-destructive data-invalid:outline-destructive data-[state=open]:border-ring data-[state=open]:outline-ring motion-reduce:transition-none', local.class)} {...others}/>;
50
+ return <Combobox.Control class={cn('group/combobox-control relative flex w-full min-w-0 items-center rounded-md border border-border bg-background text-foreground outline-1 -outline-offset-1 outline-transparent transition-[background-color,border-color,outline-color] duration-200 ease-in-out data-disabled:opacity-50 data-focus:border-ring data-focus:outline-ring data-invalid:border-destructive data-invalid:outline-destructive data-[state=open]:border-ring data-[state=open]:outline-ring motion-reduce:transition-none', local.class)} {...others} data-slot="combobox-control"/>;
51
51
  }
52
52
  function ComboboxInput(props) {
53
53
  const [local, others] = splitProps(props, [
54
54
  'asChild',
55
55
  'class'
56
56
  ]);
57
- return <Combobox.Input asChild={local.asChild} data-slot="combobox-input" class={cn(!local.asChild && 'm-0 box-border h-control-md w-full min-w-0 rounded-[inherit] border-0 bg-transparent px-3.5 text-inherit outline-0 [font:inherit] group-has-[>[data-slot=combobox-clear-trigger]]/combobox-control:pe-[4.375rem] group-has-[>[data-slot=combobox-trigger]]/combobox-control:pe-11 group-has-[>[data-slot=combobox-clear-trigger]]/combobox-control:group-has-[>[data-slot=combobox-trigger]]/combobox-control:pe-[4.375rem] placeholder:text-muted-foreground', local.class)} {...others}/>;
57
+ return <Combobox.Input asChild={local.asChild} class={cn(!local.asChild && 'm-0 box-border h-control-md w-full min-w-0 rounded-[inherit] border-0 bg-transparent px-3.5 text-inherit outline-0 [font:inherit] group-has-[>[data-slot=combobox-clear-trigger]]/combobox-control:pe-[4.375rem] group-has-[>[data-slot=combobox-trigger]]/combobox-control:pe-11 group-has-[>[data-slot=combobox-clear-trigger]]/combobox-control:group-has-[>[data-slot=combobox-trigger]]/combobox-control:pe-[4.375rem] placeholder:text-muted-foreground', local.class)} {...others} data-slot="combobox-input"/>;
58
58
  }
59
59
  function ComboboxClearTrigger(props) {
60
60
  const [local, others] = splitProps(props, [
@@ -66,7 +66,7 @@ function ComboboxClearTrigger(props) {
66
66
  ]);
67
67
  const resolvedChildren = children(()=>local.children);
68
68
  const triggerClass = cn('absolute inset-y-0 end-[2.125rem] my-auto size-control-xs transition-[background-color,color,opacity] duration-200 ease-in-out focus-visible:outline-1 focus-visible:outline-offset-1 motion-reduce:transition-none [&>svg]:size-4', local.class);
69
- if (local.asChild) return <Combobox.ClearTrigger asChild={local.asChild} aria-label={local['aria-label']} aria-labelledby={local['aria-labelledby']} data-slot="combobox-clear-trigger" class={triggerClass} {...others}>
69
+ if (local.asChild) return <Combobox.ClearTrigger asChild={local.asChild} aria-label={local['aria-label']} aria-labelledby={local['aria-labelledby']} class={triggerClass} {...others} data-slot="combobox-clear-trigger">
70
70
  {local.children}
71
71
  </Combobox.ClearTrigger>;
72
72
  return <Combobox.ClearTrigger asChild={(triggerProps)=>{
@@ -74,7 +74,7 @@ function ComboboxClearTrigger(props) {
74
74
  return <CloseButton.Root {...resolvedProps} aria-label={local['aria-label'] ?? (null == local['aria-labelledby'] ? 'Clear selection' : void 0)} aria-labelledby={local['aria-labelledby']}>
75
75
  {resolvedChildren()}
76
76
  </CloseButton.Root>;
77
- }} data-slot="combobox-clear-trigger" class={triggerClass} {...others}/>;
77
+ }} class={triggerClass} {...others} data-slot="combobox-clear-trigger"/>;
78
78
  }
79
79
  function ComboboxTrigger(props) {
80
80
  const [local, others] = splitProps(props, [
@@ -82,7 +82,7 @@ function ComboboxTrigger(props) {
82
82
  'class'
83
83
  ]);
84
84
  const resolvedChildren = children(()=>local.children);
85
- return <Combobox.Trigger data-slot="combobox-trigger" class={cn('absolute end-2 top-1/2 m-0 box-border inline-flex size-control-xs shrink-0 -translate-y-1/2 cursor-pointer items-center justify-center rounded-sm border-0 bg-transparent p-0 [line-height:0] text-muted-foreground transition-[background-color,color,opacity] duration-200 ease-in-out focus-visible:outline-1 focus-visible:outline-offset-1 focus-visible:outline-ring disabled:cursor-default data-disabled:cursor-default motion-reduce:transition-none [&>svg]:block [&>svg]:size-4 [@media(hover:hover)]:[&:not(:disabled):not([data-disabled]):hover]:bg-muted [@media(hover:hover)]:[&:not(:disabled):not([data-disabled]):hover]:text-foreground', local.class)} {...others}>
85
+ return <Combobox.Trigger class={cn('absolute end-2 top-1/2 m-0 box-border inline-flex size-control-xs shrink-0 -translate-y-1/2 cursor-pointer items-center justify-center rounded-sm border-0 bg-transparent p-0 [line-height:0] text-muted-foreground transition-[background-color,color,opacity] duration-200 ease-in-out focus-visible:outline-1 focus-visible:outline-offset-1 focus-visible:outline-ring disabled:cursor-default data-disabled:cursor-default motion-reduce:transition-none [&>svg]:block [&>svg]:size-4 [@media(hover:hover)]:[&:not(:disabled):not([data-disabled]):hover]:bg-muted [@media(hover:hover)]:[&:not(:disabled):not([data-disabled]):hover]:text-foreground', local.class)} {...others} data-slot="combobox-trigger">
86
86
  {resolvedChildren() ?? <ChevronUpDownIcon/>}
87
87
  </Combobox.Trigger>;
88
88
  }
@@ -91,56 +91,56 @@ function ComboboxPositioner(props) {
91
91
  'class'
92
92
  ]);
93
93
  return <OverlayPortal>
94
- <Combobox.Positioner data-slot="combobox-positioner" class={cn('z-[var(--z-index)] outline-0', local.class)} {...others}/>
94
+ <Combobox.Positioner class={cn('z-[var(--z-index)] outline-0', local.class)} {...others} data-slot="combobox-positioner"/>
95
95
  </OverlayPortal>;
96
96
  }
97
97
  function ComboboxContent(props) {
98
98
  const [local, others] = splitProps(props, [
99
99
  'class'
100
100
  ]);
101
- return <Combobox.Content data-slot="combobox-content" class={cn('z-[calc(60+var(--layer-index,0))] box-border flex max-h-[min(24rem,var(--available-height))] max-w-[var(--available-width)] min-w-[var(--reference-width)] origin-[var(--transform-origin)] scroll-py-1 flex-col overflow-auto overscroll-contain rounded-md border border-border bg-popover py-1 text-popover-foreground shadow-lg outline-0 data-[state=closed]:animate-moduix-menu-closed data-[state=open]:animate-moduix-menu-open motion-reduce:[animation-delay:0ms] motion-reduce:[animation-duration:1ms]', local.class)} {...others}/>;
101
+ return <Combobox.Content class={cn('z-[calc(60+var(--layer-index,0))] box-border flex max-h-[min(24rem,var(--available-height))] max-w-[var(--available-width)] min-w-[var(--reference-width)] origin-[var(--transform-origin)] scroll-py-1 flex-col overflow-auto overscroll-contain rounded-md border border-border bg-popover py-1 text-popover-foreground shadow-lg outline-0 data-[state=closed]:animate-moduix-menu-closed data-[state=open]:animate-moduix-menu-open motion-reduce:[animation-delay:0ms] motion-reduce:[animation-duration:1ms]', local.class)} {...others} data-slot="combobox-content"/>;
102
102
  }
103
103
  function ComboboxEmpty(props) {
104
104
  const [local, others] = splitProps(props, [
105
105
  'class'
106
106
  ]);
107
- return <Combobox.Empty data-slot="combobox-empty" class={cn('px-4 py-1 text-sm text-muted-foreground', local.class)} {...others}/>;
107
+ return <Combobox.Empty class={cn('px-4 py-1 text-sm text-muted-foreground', local.class)} {...others} data-slot="combobox-empty"/>;
108
108
  }
109
109
  function ComboboxStatus(props) {
110
110
  const [local, others] = splitProps(props, [
111
111
  'class'
112
112
  ]);
113
- return <ark.div data-slot="combobox-status" class={cn('px-4 py-1 text-sm text-muted-foreground', local.class)} {...others}/>;
113
+ return <ark.div class={cn('px-4 py-1 text-sm text-muted-foreground', local.class)} {...others} data-slot="combobox-status"/>;
114
114
  }
115
115
  function ComboboxList(props) {
116
116
  const [local, others] = splitProps(props, [
117
117
  'class'
118
118
  ]);
119
- return <Combobox.List data-slot="combobox-list" class={cn('flex min-h-0 flex-col outline-0 data-empty:hidden', local.class)} {...others}/>;
119
+ return <Combobox.List class={cn('flex min-h-0 flex-col outline-0 data-empty:hidden', local.class)} {...others} data-slot="combobox-list"/>;
120
120
  }
121
121
  function ComboboxItemGroup(props) {
122
122
  const [local, others] = splitProps(props, [
123
123
  'class'
124
124
  ]);
125
- return <Combobox.ItemGroup data-slot="combobox-item-group" class={cn('flex flex-col [&+&]:mt-2', local.class)} {...others}/>;
125
+ return <Combobox.ItemGroup class={cn('flex flex-col [&+&]:mt-2', local.class)} {...others} data-slot="combobox-item-group"/>;
126
126
  }
127
127
  function ComboboxItemGroupLabel(props) {
128
128
  const [local, others] = splitProps(props, [
129
129
  'class'
130
130
  ]);
131
- return <Combobox.ItemGroupLabel data-slot="combobox-item-group-label" class={cn('sticky -top-1 z-1 bg-popover px-2.5 py-1 text-xs font-normal text-muted-foreground', local.class)} {...others}/>;
131
+ return <Combobox.ItemGroupLabel class={cn('sticky -top-1 z-1 bg-popover px-2.5 py-1 text-xs font-normal text-muted-foreground', local.class)} {...others} data-slot="combobox-item-group-label"/>;
132
132
  }
133
133
  function ComboboxItem(props) {
134
134
  const [local, others] = splitProps(props, [
135
135
  'class'
136
136
  ]);
137
- return <Combobox.Item data-slot="combobox-item" class={cn('relative mx-1 box-border flex min-h-control-sm w-[calc(100%-0.5rem)] cursor-default items-center justify-between gap-2 rounded-sm border-0 bg-transparent px-3 py-1 text-sm text-popover-foreground outline-0 select-none data-disabled:pointer-events-none data-disabled:text-muted-foreground data-disabled:opacity-50 data-highlighted:bg-accent data-highlighted:text-accent-foreground data-[state=checked]:text-popover-foreground', local.class)} {...others}/>;
137
+ return <Combobox.Item class={cn('relative mx-1 box-border flex min-h-control-sm w-[calc(100%-0.5rem)] cursor-default items-center justify-between gap-2 rounded-sm border-0 bg-transparent px-3 py-1 text-sm text-popover-foreground outline-0 select-none data-disabled:pointer-events-none data-disabled:text-muted-foreground data-disabled:opacity-50 data-highlighted:bg-accent data-highlighted:text-accent-foreground data-[state=checked]:text-popover-foreground', local.class)} {...others} data-slot="combobox-item"/>;
138
138
  }
139
139
  function ComboboxItemText(props) {
140
140
  const [local, others] = splitProps(props, [
141
141
  'class'
142
142
  ]);
143
- return <Combobox.ItemText data-slot="combobox-item-text" class={cn('min-w-0 flex-1 overflow-hidden text-ellipsis whitespace-nowrap', local.class)} {...others}/>;
143
+ return <Combobox.ItemText class={cn('min-w-0 flex-1 overflow-hidden text-ellipsis whitespace-nowrap', local.class)} {...others} data-slot="combobox-item-text"/>;
144
144
  }
145
145
  function ComboboxItemIndicator(props) {
146
146
  const [local, others] = splitProps(props, [
@@ -148,7 +148,7 @@ function ComboboxItemIndicator(props) {
148
148
  'class'
149
149
  ]);
150
150
  const resolvedChildren = children(()=>local.children);
151
- return <Combobox.ItemIndicator data-slot="combobox-item-indicator" class={cn('inline-flex size-3 shrink-0 items-center justify-center [&>svg]:size-full', local.class)} {...others}>
151
+ return <Combobox.ItemIndicator class={cn('inline-flex size-3 shrink-0 items-center justify-center [&>svg]:size-full', local.class)} {...others} data-slot="combobox-item-indicator">
152
152
  {resolvedChildren() ?? <CheckIcon/>}
153
153
  </Combobox.ItemIndicator>;
154
154
  }
@@ -111,11 +111,12 @@ function CommandPaletteTrigger(props) {
111
111
  get asChild () {
112
112
  return local.asChild;
113
113
  },
114
- "data-slot": "command-palette-trigger",
115
114
  get ["class"] () {
116
115
  return cn(!local.asChild && 'inline-flex min-h-control-md cursor-pointer items-center justify-center gap-2 rounded-md border border-border bg-background px-3.5 py-1 text-md leading-6 text-foreground transition-[background-color,border-color,color] duration-200 ease-in-out select-none focus-visible:outline-1 focus-visible:-outline-offset-1 focus-visible:outline-ring [@media(hover:hover)]:hover:bg-accent', local.class);
117
116
  }
118
- }, others));
117
+ }, others, {
118
+ "data-slot": "command-palette-trigger"
119
+ }));
119
120
  }
120
121
  function CommandPaletteBackdrop(props) {
121
122
  const [local, others] = splitProps(props, [
@@ -124,11 +125,12 @@ function CommandPaletteBackdrop(props) {
124
125
  return createComponent(OverlayPortal, {
125
126
  get children () {
126
127
  return createComponent(Dialog.Backdrop, mergeProps({
127
- "data-slot": "command-palette-backdrop",
128
128
  get ["class"] () {
129
129
  return cn('fixed inset-0 z-[calc(40+var(--layer-index,0))] bg-overlay backdrop-blur-[4px] data-[state=closed]:animate-[moduix-fade-out_200ms_ease-in-out_forwards] data-[state=open]:animate-[moduix-fade-in_200ms_ease-in-out] motion-reduce:animate-none', local.class);
130
130
  }
131
- }, others));
131
+ }, others, {
132
+ "data-slot": "command-palette-backdrop"
133
+ }));
132
134
  }
133
135
  });
134
136
  }
@@ -139,11 +141,12 @@ function CommandPalettePositioner(props) {
139
141
  return createComponent(OverlayPortal, {
140
142
  get children () {
141
143
  return createComponent(Dialog.Positioner, mergeProps({
142
- "data-slot": "command-palette-positioner",
143
144
  get ["class"] () {
144
145
  return cn('fixed inset-0 z-[calc(50+var(--layer-index,0))] grid items-start justify-items-center overflow-hidden overscroll-contain px-4 pt-[10dvh] pb-4', local.class);
145
146
  }
146
- }, others));
147
+ }, others, {
148
+ "data-slot": "command-palette-positioner"
149
+ }));
147
150
  }
148
151
  });
149
152
  }
@@ -152,11 +155,12 @@ function CommandPaletteContent(props) {
152
155
  'class'
153
156
  ]);
154
157
  return createComponent(Dialog.Content, mergeProps({
155
- "data-slot": "command-palette-content",
156
158
  get ["class"] () {
157
159
  return cn('flex max-h-[min(34rem,calc(100dvh-5rem))] w-[min(37.5rem,calc(100vw-2rem))] origin-top flex-col overflow-hidden rounded-lg border border-border/84 bg-popover bg-linear-to-b from-white/4 to-transparent text-popover-foreground shadow-lg outline-0 data-[state=closed]:animate-moduix-menu-closed data-[state=open]:animate-moduix-menu-open motion-reduce:animate-none', local.class);
158
160
  }
159
- }, others));
161
+ }, others, {
162
+ "data-slot": "command-palette-content"
163
+ }));
160
164
  }
161
165
  function CommandPalettePanel(props) {
162
166
  const [local, others] = splitProps(props, [
@@ -184,44 +188,48 @@ function CommandPaletteTitle(props) {
184
188
  'class'
185
189
  ]);
186
190
  return createComponent(Dialog.Title, mergeProps({
187
- "data-slot": "command-palette-title",
188
191
  get ["class"] () {
189
192
  return cn('text-md leading-6 font-semibold text-popover-foreground', local.class);
190
193
  }
191
- }, others));
194
+ }, others, {
195
+ "data-slot": "command-palette-title"
196
+ }));
192
197
  }
193
198
  function CommandPaletteDescription(props) {
194
199
  const [local, others] = splitProps(props, [
195
200
  'class'
196
201
  ]);
197
202
  return createComponent(Dialog.Description, mergeProps({
198
- "data-slot": "command-palette-description",
199
203
  get ["class"] () {
200
204
  return cn('text-sm leading-5 text-muted-foreground', local.class);
201
205
  }
202
- }, others));
206
+ }, others, {
207
+ "data-slot": "command-palette-description"
208
+ }));
203
209
  }
204
210
  function CommandPaletteHeader(props) {
205
211
  const [local, others] = splitProps(props, [
206
212
  'class'
207
213
  ]);
208
214
  return createComponent(ark.div, mergeProps({
209
- "data-slot": "command-palette-header",
210
215
  get ["class"] () {
211
216
  return cn('grid gap-1 px-4 pt-4', local.class);
212
217
  }
213
- }, others));
218
+ }, others, {
219
+ "data-slot": "command-palette-header"
220
+ }));
214
221
  }
215
222
  function CommandPaletteBody(props) {
216
223
  const [local, others] = splitProps(props, [
217
224
  'class'
218
225
  ]);
219
226
  return createComponent(ark.div, mergeProps({
220
- "data-slot": "command-palette-body",
221
227
  get ["class"] () {
222
228
  return cn('flex min-h-0 flex-1 flex-col', local.class);
223
229
  }
224
- }, others));
230
+ }, others, {
231
+ "data-slot": "command-palette-body"
232
+ }));
225
233
  }
226
234
  const CommandPalette_CommandPaletteCombobox = function(props) {
227
235
  const [local, others] = splitProps(props, [
@@ -240,7 +248,6 @@ const CommandPalette_CommandPaletteCombobox = function(props) {
240
248
  if (local.closeOnSelect ?? true) dialog().setOpen(false);
241
249
  };
242
250
  return createComponent(Combobox.Root, mergeProps({
243
- "data-slot": "command-palette-combobox",
244
251
  get ["class"] () {
245
252
  return cn('flex min-h-0 flex-1 flex-col overflow-hidden', local.class);
246
253
  },
@@ -261,6 +268,7 @@ const CommandPalette_CommandPaletteCombobox = function(props) {
261
268
  },
262
269
  onSelect: handleSelect
263
270
  }, others, {
271
+ "data-slot": "command-palette-combobox",
264
272
  get children () {
265
273
  return local.children;
266
274
  }
@@ -271,22 +279,24 @@ function CommandPaletteControl(props) {
271
279
  'class'
272
280
  ]);
273
281
  return createComponent(Combobox.Control, mergeProps({
274
- "data-slot": "command-palette-control",
275
282
  get ["class"] () {
276
283
  return cn('relative mx-3 mt-3 flex min-h-control-md flex-none items-center gap-2 rounded-md border border-border bg-background px-3 py-1 text-foreground transition-[background-color,border-color] duration-200 ease-in-out has-[[aria-invalid=true]]:border-destructive has-[[data-invalid]]:border-destructive', local.class);
277
284
  }
278
- }, others));
285
+ }, others, {
286
+ "data-slot": "command-palette-control"
287
+ }));
279
288
  }
280
289
  function CommandPaletteInput(props) {
281
290
  const [local, others] = splitProps(props, [
282
291
  'class'
283
292
  ]);
284
293
  return createComponent(Combobox.Input, mergeProps({
285
- "data-slot": "command-palette-input",
286
294
  get ["class"] () {
287
295
  return cn('h-auto w-full min-w-0 flex-1 bg-transparent text-sm leading-5 text-inherit outline-0 placeholder:text-muted-foreground data-invalid:text-destructive', local.class);
288
296
  }
289
- }, others));
297
+ }, others, {
298
+ "data-slot": "command-palette-input"
299
+ }));
290
300
  }
291
301
  function CommandPaletteSearch(props) {
292
302
  const [local, others] = splitProps(props, [
@@ -325,7 +335,6 @@ function CommandPaletteClearTrigger(props) {
325
335
  get asChild () {
326
336
  return local.asChild;
327
337
  },
328
- "data-slot": "command-palette-clear-trigger",
329
338
  get hidden () {
330
339
  return 0 === combobox().inputValue.length;
331
340
  },
@@ -344,12 +353,10 @@ function CommandPaletteClearTrigger(props) {
344
353
  },
345
354
  onPointerDown: (event)=>{
346
355
  local.onPointerDown?.(event);
347
- if (0 === event.button) {
348
- event.preventDefault();
349
- combobox().setInputValue('');
350
- }
356
+ if (0 === event.button) event.preventDefault();
351
357
  }
352
358
  }, others, {
359
+ "data-slot": "command-palette-clear-trigger",
353
360
  get children () {
354
361
  return resolvedChildren() ?? createComponent(CloseIcon, {});
355
362
  }
@@ -362,11 +369,11 @@ function CommandPaletteList(props) {
362
369
  'children'
363
370
  ]);
364
371
  return createComponent(Combobox.Content, mergeProps({
365
- "data-slot": "command-palette-list",
366
372
  get ["class"] () {
367
373
  return cn('group/list flex min-h-0 flex-1 overflow-hidden outline-0', local.class);
368
374
  }
369
375
  }, others, {
376
+ "data-slot": "command-palette-list",
370
377
  get children () {
371
378
  return createComponent(ScrollArea, {
372
379
  "data-slot": "command-palette-scroll-area",
@@ -395,55 +402,60 @@ function CommandPaletteEmpty(props) {
395
402
  'class'
396
403
  ]);
397
404
  return createComponent(Combobox.Empty, mergeProps({
398
- "data-slot": "command-palette-empty",
399
405
  get ["class"] () {
400
406
  return cn('[&:not(:empty)]:px-4 [&:not(:empty)]:py-3 [&:not(:empty)]:text-sm [&:not(:empty)]:leading-5 [&:not(:empty)]:text-muted-foreground', local.class);
401
407
  }
402
- }, others));
408
+ }, others, {
409
+ "data-slot": "command-palette-empty"
410
+ }));
403
411
  }
404
412
  function CommandPaletteItemGroup(props) {
405
413
  const [local, others] = splitProps(props, [
406
414
  'class'
407
415
  ]);
408
416
  return createComponent(Combobox.ItemGroup, mergeProps({
409
- "data-slot": "command-palette-item-group",
410
417
  get ["class"] () {
411
418
  return cn('grid gap-1 [&:not(:last-child)]:pb-2', local.class);
412
419
  }
413
- }, others));
420
+ }, others, {
421
+ "data-slot": "command-palette-item-group"
422
+ }));
414
423
  }
415
424
  function CommandPaletteItemGroupLabel(props) {
416
425
  const [local, others] = splitProps(props, [
417
426
  'class'
418
427
  ]);
419
428
  return createComponent(Combobox.ItemGroupLabel, mergeProps({
420
- "data-slot": "command-palette-item-group-label",
421
429
  get ["class"] () {
422
430
  return cn('sticky top-0 z-1 block bg-popover px-3 py-1 text-xs leading-4 font-normal text-muted-foreground', local.class);
423
431
  }
424
- }, others));
432
+ }, others, {
433
+ "data-slot": "command-palette-item-group-label"
434
+ }));
425
435
  }
426
436
  function CommandPaletteItem(props) {
427
437
  const [local, others] = splitProps(props, [
428
438
  'class'
429
439
  ]);
430
440
  return createComponent(Combobox.Item, mergeProps({
431
- "data-slot": "command-palette-item",
432
441
  get ["class"] () {
433
442
  return cn('relative z-0 grid min-h-control-sm cursor-default grid-cols-[auto_minmax(0,1fr)_auto_auto] items-center gap-3 rounded-md px-3 py-1 text-sm leading-5 text-popover-foreground outline-0 select-none data-disabled:pointer-events-none data-disabled:opacity-50 data-highlighted:bg-accent data-highlighted:text-foreground data-[state=checked]:text-foreground', local.class);
434
443
  }
435
- }, others));
444
+ }, others, {
445
+ "data-slot": "command-palette-item"
446
+ }));
436
447
  }
437
448
  function CommandPaletteItemText(props) {
438
449
  const [local, others] = splitProps(props, [
439
450
  'class'
440
451
  ]);
441
452
  return createComponent(Combobox.ItemText, mergeProps({
442
- "data-slot": "command-palette-item-text",
443
453
  get ["class"] () {
444
454
  return cn('grid min-w-0 gap-1', local.class);
445
455
  }
446
- }, others));
456
+ }, others, {
457
+ "data-slot": "command-palette-item-text"
458
+ }));
447
459
  }
448
460
  function CommandPaletteItemIndicator(props) {
449
461
  const [local, others] = splitProps(props, [
@@ -452,11 +464,11 @@ function CommandPaletteItemIndicator(props) {
452
464
  ]);
453
465
  const resolvedChildren = children(()=>local.children);
454
466
  return createComponent(Combobox.ItemIndicator, mergeProps({
455
- "data-slot": "command-palette-item-indicator",
456
467
  get ["class"] () {
457
468
  return cn('inline-flex size-8 items-center justify-center justify-self-end rounded-md border border-transparent bg-transparent text-muted-foreground [&>svg]:size-4 [&>svg]:shrink-0', local.class);
458
469
  }
459
470
  }, others, {
471
+ "data-slot": "command-palette-item-indicator",
460
472
  get children () {
461
473
  return resolvedChildren() ?? createComponent(CheckIcon, {});
462
474
  }
@@ -467,44 +479,48 @@ function CommandPaletteItemIcon(props) {
467
479
  'class'
468
480
  ]);
469
481
  return createComponent(ark.span, mergeProps({
470
- "data-slot": "command-palette-item-icon",
471
482
  get ["class"] () {
472
483
  return cn('inline-flex size-8 items-center justify-center rounded-md border border-border bg-muted text-muted-foreground [&>svg]:size-4 [&>svg]:shrink-0', local.class);
473
484
  }
474
- }, others));
485
+ }, others, {
486
+ "data-slot": "command-palette-item-icon"
487
+ }));
475
488
  }
476
489
  function CommandPaletteItemLabel(props) {
477
490
  const [local, others] = splitProps(props, [
478
491
  'class'
479
492
  ]);
480
493
  return createComponent(ark.span, mergeProps({
481
- "data-slot": "command-palette-item-label",
482
494
  get ["class"] () {
483
495
  return cn('min-w-0 overflow-hidden font-medium text-ellipsis whitespace-nowrap', local.class);
484
496
  }
485
- }, others));
497
+ }, others, {
498
+ "data-slot": "command-palette-item-label"
499
+ }));
486
500
  }
487
501
  function CommandPaletteItemDescription(props) {
488
502
  const [local, others] = splitProps(props, [
489
503
  'class'
490
504
  ]);
491
505
  return createComponent(ark.span, mergeProps({
492
- "data-slot": "command-palette-item-description",
493
506
  get ["class"] () {
494
507
  return cn('min-w-0 overflow-hidden text-xs leading-4 text-ellipsis whitespace-nowrap text-muted-foreground', local.class);
495
508
  }
496
- }, others));
509
+ }, others, {
510
+ "data-slot": "command-palette-item-description"
511
+ }));
497
512
  }
498
513
  function CommandPaletteItemMeta(props) {
499
514
  const [local, others] = splitProps(props, [
500
515
  'class'
501
516
  ]);
502
517
  return createComponent(ark.span, mergeProps({
503
- "data-slot": "command-palette-item-meta",
504
518
  get ["class"] () {
505
519
  return cn('justify-self-end text-xs leading-4 whitespace-nowrap text-muted-foreground', local.class);
506
520
  }
507
- }, others));
521
+ }, others, {
522
+ "data-slot": "command-palette-item-meta"
523
+ }));
508
524
  }
509
525
  function CommandPaletteSeparator(props) {
510
526
  const [local, others] = splitProps(props, [
@@ -512,33 +528,36 @@ function CommandPaletteSeparator(props) {
512
528
  ]);
513
529
  return createComponent(ark.div, mergeProps({
514
530
  role: "separator",
515
- "data-slot": "command-palette-separator",
516
531
  get ["class"] () {
517
532
  return cn('mx-2 my-2 h-px bg-border', local.class);
518
533
  }
519
- }, others));
534
+ }, others, {
535
+ "data-slot": "command-palette-separator"
536
+ }));
520
537
  }
521
538
  function CommandPaletteFooter(props) {
522
539
  const [local, others] = splitProps(props, [
523
540
  'class'
524
541
  ]);
525
542
  return createComponent(ark.div, mergeProps({
526
- "data-slot": "command-palette-footer",
527
543
  get ["class"] () {
528
544
  return cn('flex flex-none items-center justify-between gap-3 border-t border-border px-4 py-2 text-xs leading-4 text-muted-foreground', local.class);
529
545
  }
530
- }, others));
546
+ }, others, {
547
+ "data-slot": "command-palette-footer"
548
+ }));
531
549
  }
532
550
  function CommandPaletteKbd(props) {
533
551
  const [local, others] = splitProps(props, [
534
552
  'class'
535
553
  ]);
536
554
  return createComponent(Kbd.Root, mergeProps({
537
- "data-slot": "command-palette-kbd",
538
555
  get ["class"] () {
539
556
  return cn('min-h-5 min-w-5 rounded-sm px-1 text-xs leading-4 text-muted-foreground', local.class);
540
557
  }
541
- }, others));
558
+ }, others, {
559
+ "data-slot": "command-palette-kbd"
560
+ }));
542
561
  }
543
562
  const CommandPalette = Object.assign(CommandPaletteRoot, {
544
563
  Root: CommandPaletteRoot,