@moduix/react 1.1.0 → 2.0.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 (358) hide show
  1. package/README.md +16 -16
  2. package/dist/components/accordion/Accordion.css +21 -14
  3. package/dist/components/accordion/Accordion.d.ts +3 -2
  4. package/dist/components/accordion/Accordion.js +17 -5
  5. package/dist/components/accordion/Accordion.module.js +10 -9
  6. package/dist/components/accordion/index.d.ts +2 -2
  7. package/dist/components/alert/Alert.css +24 -10
  8. package/dist/components/alert/Alert.d.ts +5 -3
  9. package/dist/components/alert/Alert.js +17 -5
  10. package/dist/components/alert/Alert.module.js +6 -5
  11. package/dist/components/angle-slider/AngleSlider.css +8 -8
  12. package/dist/components/angle-slider/AngleSlider.d.ts +18 -2
  13. package/dist/components/angle-slider/AngleSlider.js +34 -18
  14. package/dist/components/angle-slider/AngleSlider.module.js +7 -7
  15. package/dist/components/angle-slider/index.d.ts +2 -2
  16. package/dist/components/aspect-ratio/AspectRatio.css +4 -2
  17. package/dist/components/aspect-ratio/AspectRatio.js +2 -2
  18. package/dist/components/aspect-ratio/AspectRatio.module.js +1 -1
  19. package/dist/components/avatar/Avatar.css +3 -3
  20. package/dist/components/avatar/Avatar.d.ts +6 -3
  21. package/dist/components/avatar/Avatar.js +12 -5
  22. package/dist/components/avatar/Avatar.module.js +3 -3
  23. package/dist/components/avatar/index.d.ts +2 -2
  24. package/dist/components/badge/Badge.css +46 -3
  25. package/dist/components/badge/Badge.d.ts +2 -2
  26. package/dist/components/badge/Badge.js +1 -1
  27. package/dist/components/badge/Badge.module.js +2 -2
  28. package/dist/components/bleed/Bleed.css +1 -1
  29. package/dist/components/bleed/Bleed.d.ts +6 -4
  30. package/dist/components/bleed/Bleed.js +3 -3
  31. package/dist/components/bleed/Bleed.module.js +1 -1
  32. package/dist/components/breadcrumbs/Breadcrumbs.css +17 -11
  33. package/dist/components/breadcrumbs/Breadcrumbs.d.ts +18 -0
  34. package/dist/components/breadcrumbs/Breadcrumbs.js +18 -4
  35. package/dist/components/breadcrumbs/Breadcrumbs.module.js +8 -7
  36. package/dist/components/breadcrumbs/index.d.ts +2 -0
  37. package/dist/components/button/Button.css +22 -2
  38. package/dist/components/button/Button.d.ts +6 -0
  39. package/dist/components/button/Button.js +12 -7
  40. package/dist/components/button/Button.module.js +1 -1
  41. package/dist/components/card/Card.css +29 -13
  42. package/dist/components/card/Card.d.ts +1 -0
  43. package/dist/components/card/Card.js +12 -1
  44. package/dist/components/card/Card.module.js +9 -8
  45. package/dist/components/carousel/Carousel.css +20 -18
  46. package/dist/components/carousel/Carousel.d.ts +4 -0
  47. package/dist/components/carousel/Carousel.js +15 -2
  48. package/dist/components/carousel/Carousel.module.js +12 -12
  49. package/dist/components/checkbox/Checkbox.css +11 -11
  50. package/dist/components/checkbox/Checkbox.d.ts +2 -3
  51. package/dist/components/checkbox/Checkbox.js +25 -22
  52. package/dist/components/checkbox/Checkbox.module.js +6 -6
  53. package/dist/components/checkbox/index.d.ts +2 -2
  54. package/dist/components/clipboard/Clipboard.css +8 -8
  55. package/dist/components/clipboard/Clipboard.d.ts +2 -0
  56. package/dist/components/clipboard/Clipboard.js +15 -4
  57. package/dist/components/clipboard/Clipboard.module.js +8 -8
  58. package/dist/components/close-button/CloseButton.css +1 -1
  59. package/dist/components/close-button/CloseButton.d.ts +12 -2
  60. package/dist/components/close-button/CloseButton.js +9 -9
  61. package/dist/components/close-button/CloseButton.module.js +1 -1
  62. package/dist/components/collapsible/Collapsible.css +17 -10
  63. package/dist/components/collapsible/Collapsible.d.ts +3 -2
  64. package/dist/components/collapsible/Collapsible.js +18 -6
  65. package/dist/components/collapsible/Collapsible.module.js +7 -6
  66. package/dist/components/collapsible/index.d.ts +2 -2
  67. package/dist/components/color-picker/ColorPicker.css +63 -34
  68. package/dist/components/color-picker/ColorPicker.d.ts +3 -3
  69. package/dist/components/color-picker/ColorPicker.js +78 -27
  70. package/dist/components/color-picker/ColorPicker.module.js +28 -27
  71. package/dist/components/color-picker/index.d.ts +2 -2
  72. package/dist/components/combobox/Combobox.css +55 -26
  73. package/dist/components/combobox/Combobox.d.ts +9 -2
  74. package/dist/components/combobox/Combobox.js +34 -8
  75. package/dist/components/combobox/Combobox.module.js +17 -17
  76. package/dist/components/combobox/index.d.ts +2 -2
  77. package/dist/components/command-palette/CommandPalette.css +80 -114
  78. package/dist/components/command-palette/CommandPalette.d.ts +13 -3
  79. package/dist/components/command-palette/CommandPalette.js +54 -43
  80. package/dist/components/command-palette/CommandPalette.module.js +35 -37
  81. package/dist/components/container/Container.css +1 -1
  82. package/dist/components/container/Container.js +1 -1
  83. package/dist/components/container/Container.module.js +1 -1
  84. package/dist/components/date-input/DateInput.css +9 -7
  85. package/dist/components/date-input/DateInput.d.ts +12 -7
  86. package/dist/components/date-input/DateInput.js +35 -14
  87. package/dist/components/date-input/DateInput.module.js +6 -6
  88. package/dist/components/date-input/index.d.ts +2 -2
  89. package/dist/components/date-picker/DatePicker.css +68 -40
  90. package/dist/components/date-picker/DatePicker.d.ts +30 -2
  91. package/dist/components/date-picker/DatePicker.js +94 -9
  92. package/dist/components/date-picker/DatePicker.module.js +23 -23
  93. package/dist/components/date-picker/index.d.ts +2 -2
  94. package/dist/components/dialog/Dialog.css +31 -27
  95. package/dist/components/dialog/Dialog.d.ts +2 -2
  96. package/dist/components/dialog/Dialog.js +3 -3
  97. package/dist/components/dialog/Dialog.module.js +15 -15
  98. package/dist/components/dialog/index.d.ts +2 -2
  99. package/dist/components/drawer/Drawer.css +40 -40
  100. package/dist/components/drawer/Drawer.d.ts +2 -2
  101. package/dist/components/drawer/Drawer.js +3 -3
  102. package/dist/components/drawer/Drawer.module.js +26 -26
  103. package/dist/components/drawer/index.d.ts +2 -2
  104. package/dist/components/editable/Editable.css +10 -10
  105. package/dist/components/editable/Editable.d.ts +9 -2
  106. package/dist/components/editable/Editable.js +14 -5
  107. package/dist/components/editable/Editable.module.js +7 -7
  108. package/dist/components/editable/index.d.ts +2 -2
  109. package/dist/components/empty/Empty.css +6 -6
  110. package/dist/components/empty/Empty.js +1 -1
  111. package/dist/components/empty/Empty.module.js +6 -6
  112. package/dist/components/field/Field.css +8 -12
  113. package/dist/components/field/Field.d.ts +3 -2
  114. package/dist/components/field/Field.js +6 -5
  115. package/dist/components/field/Field.module.js +8 -9
  116. package/dist/components/field/index.d.ts +2 -2
  117. package/dist/components/fieldset/Fieldset.css +6 -6
  118. package/dist/components/fieldset/Fieldset.d.ts +2 -2
  119. package/dist/components/fieldset/Fieldset.js +3 -3
  120. package/dist/components/fieldset/Fieldset.module.js +4 -4
  121. package/dist/components/fieldset/index.d.ts +2 -2
  122. package/dist/components/file-upload/FileUpload.css +97 -24
  123. package/dist/components/file-upload/FileUpload.d.ts +22 -5
  124. package/dist/components/file-upload/FileUpload.js +79 -21
  125. package/dist/components/file-upload/FileUpload.module.js +16 -13
  126. package/dist/components/file-upload/index.d.ts +2 -2
  127. package/dist/components/floating-panel/FloatingPanel.css +28 -24
  128. package/dist/components/floating-panel/FloatingPanel.d.ts +11 -3
  129. package/dist/components/floating-panel/FloatingPanel.js +15 -9
  130. package/dist/components/floating-panel/FloatingPanel.module.js +14 -14
  131. package/dist/components/heading/Heading.css +1 -1
  132. package/dist/components/heading/Heading.js +1 -1
  133. package/dist/components/heading/Heading.module.js +1 -1
  134. package/dist/components/highlight/Highlight.css +1 -1
  135. package/dist/components/highlight/Highlight.js +1 -1
  136. package/dist/components/highlight/Highlight.module.js +1 -1
  137. package/dist/components/hover-card/HoverCard.css +21 -17
  138. package/dist/components/hover-card/HoverCard.d.ts +3 -2
  139. package/dist/components/hover-card/HoverCard.js +5 -4
  140. package/dist/components/hover-card/HoverCard.module.js +7 -7
  141. package/dist/components/hover-card/index.d.ts +2 -2
  142. package/dist/components/image/Image.css +7 -0
  143. package/dist/components/image/Image.d.ts +12 -0
  144. package/dist/components/image/Image.js +28 -0
  145. package/dist/components/image/Image.module.js +5 -0
  146. package/dist/components/image/index.d.ts +2 -0
  147. package/dist/components/image-cropper/ImageCropper.css +6 -6
  148. package/dist/components/image-cropper/ImageCropper.d.ts +7 -2
  149. package/dist/components/image-cropper/ImageCropper.js +25 -3
  150. package/dist/components/image-cropper/ImageCropper.module.js +6 -6
  151. package/dist/components/image-cropper/index.d.ts +2 -2
  152. package/dist/components/input/Input.css +1 -1
  153. package/dist/components/input/Input.js +1 -1
  154. package/dist/components/input/Input.module.js +1 -1
  155. package/dist/components/input-group/InputGroup.css +6 -6
  156. package/dist/components/input-group/InputGroup.d.ts +3 -0
  157. package/dist/components/input-group/InputGroup.js +1 -1
  158. package/dist/components/input-group/InputGroup.module.js +5 -5
  159. package/dist/components/kbd/Kbd.css +2 -2
  160. package/dist/components/kbd/Kbd.js +1 -1
  161. package/dist/components/kbd/Kbd.module.js +2 -2
  162. package/dist/components/lightbox/Lightbox.css +30 -28
  163. package/dist/components/lightbox/Lightbox.d.ts +4 -2
  164. package/dist/components/lightbox/Lightbox.js +9 -7
  165. package/dist/components/lightbox/Lightbox.module.js +16 -16
  166. package/dist/components/lightbox/index.d.ts +2 -2
  167. package/dist/components/list/List.css +1 -1
  168. package/dist/components/list/List.js +1 -1
  169. package/dist/components/list/List.module.js +1 -1
  170. package/dist/components/listbox/Listbox.css +76 -17
  171. package/dist/components/listbox/Listbox.d.ts +14 -2
  172. package/dist/components/listbox/Listbox.js +41 -5
  173. package/dist/components/listbox/Listbox.module.js +17 -14
  174. package/dist/components/listbox/index.d.ts +2 -2
  175. package/dist/components/marquee/Marquee.css +10 -10
  176. package/dist/components/marquee/Marquee.d.ts +2 -1
  177. package/dist/components/marquee/Marquee.js +4 -3
  178. package/dist/components/marquee/Marquee.module.js +7 -7
  179. package/dist/components/marquee/index.d.ts +2 -2
  180. package/dist/components/menu/Menu.css +46 -40
  181. package/dist/components/menu/Menu.d.ts +3 -2
  182. package/dist/components/menu/Menu.js +6 -5
  183. package/dist/components/menu/Menu.module.js +27 -27
  184. package/dist/components/menu/index.d.ts +2 -2
  185. package/dist/components/native-select/NativeSelect.css +5 -5
  186. package/dist/components/native-select/NativeSelect.d.ts +6 -2
  187. package/dist/components/native-select/NativeSelect.js +5 -4
  188. package/dist/components/native-select/NativeSelect.module.js +3 -3
  189. package/dist/components/number-input/NumberInput.css +11 -17
  190. package/dist/components/number-input/NumberInput.d.ts +7 -2
  191. package/dist/components/number-input/NumberInput.js +17 -4
  192. package/dist/components/number-input/NumberInput.module.js +8 -8
  193. package/dist/components/number-input/index.d.ts +2 -2
  194. package/dist/components/pagination/Pagination.css +8 -8
  195. package/dist/components/pagination/Pagination.d.ts +4 -0
  196. package/dist/components/pagination/Pagination.js +13 -4
  197. package/dist/components/pagination/Pagination.module.js +6 -6
  198. package/dist/components/password-input/PasswordInput.css +7 -7
  199. package/dist/components/password-input/PasswordInput.d.ts +4 -0
  200. package/dist/components/password-input/PasswordInput.js +10 -2
  201. package/dist/components/password-input/PasswordInput.module.js +6 -6
  202. package/dist/components/pin-input/PinInput.css +5 -5
  203. package/dist/components/pin-input/PinInput.d.ts +6 -1
  204. package/dist/components/pin-input/PinInput.js +25 -16
  205. package/dist/components/pin-input/PinInput.module.js +5 -5
  206. package/dist/components/popover/Popover.css +33 -24
  207. package/dist/components/popover/Popover.js +1 -1
  208. package/dist/components/popover/Popover.module.js +14 -14
  209. package/dist/components/progress-circular/ProgressCircular.css +8 -8
  210. package/dist/components/progress-circular/ProgressCircular.d.ts +6 -0
  211. package/dist/components/progress-circular/ProgressCircular.js +14 -3
  212. package/dist/components/progress-circular/ProgressCircular.module.js +8 -8
  213. package/dist/components/progress-linear/ProgressLinear.css +8 -8
  214. package/dist/components/progress-linear/ProgressLinear.d.ts +3 -0
  215. package/dist/components/progress-linear/ProgressLinear.js +6 -3
  216. package/dist/components/progress-linear/ProgressLinear.module.js +8 -8
  217. package/dist/components/qr-code/QrCode.css +13 -12
  218. package/dist/components/qr-code/QrCode.d.ts +2 -2
  219. package/dist/components/qr-code/QrCode.js +3 -3
  220. package/dist/components/qr-code/QrCode.module.js +5 -5
  221. package/dist/components/qr-code/index.d.ts +2 -2
  222. package/dist/components/radio-group/RadioGroup.css +6 -6
  223. package/dist/components/radio-group/RadioGroup.d.ts +8 -4
  224. package/dist/components/radio-group/RadioGroup.js +22 -14
  225. package/dist/components/radio-group/RadioGroup.module.js +6 -6
  226. package/dist/components/radio-group/index.d.ts +2 -2
  227. package/dist/components/rating-group/RatingGroup.css +14 -14
  228. package/dist/components/rating-group/RatingGroup.d.ts +11 -4
  229. package/dist/components/rating-group/RatingGroup.js +29 -18
  230. package/dist/components/rating-group/RatingGroup.module.js +7 -7
  231. package/dist/components/rating-group/index.d.ts +2 -2
  232. package/dist/components/scroll-area/ScrollArea.css +14 -9
  233. package/dist/components/scroll-area/ScrollArea.d.ts +3 -0
  234. package/dist/components/scroll-area/ScrollArea.js +9 -6
  235. package/dist/components/scroll-area/ScrollArea.module.js +6 -6
  236. package/dist/components/segment-group/SegmentGroup.css +6 -6
  237. package/dist/components/segment-group/SegmentGroup.d.ts +13 -3
  238. package/dist/components/segment-group/SegmentGroup.js +23 -15
  239. package/dist/components/segment-group/SegmentGroup.module.js +6 -6
  240. package/dist/components/segment-group/index.d.ts +2 -2
  241. package/dist/components/select/Select.css +49 -40
  242. package/dist/components/select/Select.d.ts +18 -4
  243. package/dist/components/select/Select.js +65 -20
  244. package/dist/components/select/Select.module.js +21 -21
  245. package/dist/components/separator/Separator.css +1 -1
  246. package/dist/components/separator/Separator.js +1 -1
  247. package/dist/components/separator/Separator.module.js +1 -1
  248. package/dist/components/sidebar/Sidebar.css +169 -32
  249. package/dist/components/sidebar/Sidebar.d.ts +26 -0
  250. package/dist/components/sidebar/Sidebar.js +105 -13
  251. package/dist/components/sidebar/Sidebar.module.js +23 -17
  252. package/dist/components/signature-pad/SignaturePad.css +18 -47
  253. package/dist/components/signature-pad/SignaturePad.d.ts +14 -6
  254. package/dist/components/signature-pad/SignaturePad.js +56 -17
  255. package/dist/components/signature-pad/SignaturePad.module.js +6 -6
  256. package/dist/components/signature-pad/index.d.ts +2 -2
  257. package/dist/components/simple-grid/SimpleGrid.js +3 -3
  258. package/dist/components/skeleton/Skeleton.css +1 -1
  259. package/dist/components/skeleton/Skeleton.js +1 -1
  260. package/dist/components/skeleton/Skeleton.module.js +1 -1
  261. package/dist/components/slider/Slider.css +16 -14
  262. package/dist/components/slider/Slider.d.ts +12 -3
  263. package/dist/components/slider/Slider.js +24 -15
  264. package/dist/components/slider/Slider.module.js +10 -10
  265. package/dist/components/slider/index.d.ts +2 -2
  266. package/dist/components/spinner/Spinner.css +9 -9
  267. package/dist/components/spinner/Spinner.js +2 -2
  268. package/dist/components/spinner/Spinner.module.js +3 -3
  269. package/dist/components/split-button/SplitButton.css +9 -9
  270. package/dist/components/split-button/SplitButton.d.ts +1 -1
  271. package/dist/components/split-button/SplitButton.js +3 -4
  272. package/dist/components/split-button/SplitButton.module.js +3 -3
  273. package/dist/components/splitter/Splitter.css +27 -22
  274. package/dist/components/splitter/Splitter.d.ts +2 -2
  275. package/dist/components/splitter/Splitter.js +12 -11
  276. package/dist/components/splitter/Splitter.module.js +4 -4
  277. package/dist/components/splitter/index.d.ts +2 -2
  278. package/dist/components/stack/Stack.css +2 -2
  279. package/dist/components/stack/Stack.d.ts +1 -3
  280. package/dist/components/stack/Stack.js +4 -6
  281. package/dist/components/stack/Stack.module.js +1 -1
  282. package/dist/components/steps/Steps.css +14 -14
  283. package/dist/components/steps/Steps.d.ts +2 -1
  284. package/dist/components/steps/Steps.js +5 -4
  285. package/dist/components/steps/Steps.module.js +11 -11
  286. package/dist/components/swap/Swap.css +45 -0
  287. package/dist/components/swap/Swap.d.ts +11 -0
  288. package/dist/components/swap/Swap.js +39 -0
  289. package/dist/components/swap/Swap.module.js +11 -0
  290. package/dist/components/swap/index.d.ts +2 -0
  291. package/dist/components/switch/Switch.css +11 -11
  292. package/dist/components/switch/Switch.d.ts +4 -4
  293. package/dist/components/switch/Switch.js +19 -16
  294. package/dist/components/switch/Switch.module.js +4 -4
  295. package/dist/components/switch/index.d.ts +2 -2
  296. package/dist/components/table/Table.css +18 -18
  297. package/dist/components/table/Table.js +3 -2
  298. package/dist/components/table/Table.module.js +11 -12
  299. package/dist/components/tabs/Tabs.css +12 -10
  300. package/dist/components/tabs/Tabs.d.ts +3 -2
  301. package/dist/components/tabs/Tabs.js +5 -4
  302. package/dist/components/tabs/Tabs.module.js +5 -5
  303. package/dist/components/tabs/index.d.ts +2 -2
  304. package/dist/components/tag/Tag.css +16 -46
  305. package/dist/components/tag/Tag.js +7 -20
  306. package/dist/components/tag/Tag.module.js +5 -5
  307. package/dist/components/tags-input/TagsInput.css +13 -50
  308. package/dist/components/tags-input/TagsInput.d.ts +7 -4
  309. package/dist/components/tags-input/TagsInput.js +33 -21
  310. package/dist/components/tags-input/TagsInput.module.js +10 -10
  311. package/dist/components/tags-input/index.d.ts +2 -2
  312. package/dist/components/text/Text.css +1 -1
  313. package/dist/components/text/Text.d.ts +2 -2
  314. package/dist/components/text/Text.js +1 -1
  315. package/dist/components/text/Text.module.js +1 -1
  316. package/dist/components/textarea/Textarea.css +7 -7
  317. package/dist/components/textarea/Textarea.js +1 -1
  318. package/dist/components/textarea/Textarea.module.js +1 -1
  319. package/dist/components/timer/Timer.css +6 -6
  320. package/dist/components/timer/Timer.d.ts +14 -2
  321. package/dist/components/timer/Timer.js +13 -5
  322. package/dist/components/timer/Timer.module.js +6 -6
  323. package/dist/components/timer/index.d.ts +2 -2
  324. package/dist/components/toast/Toast.css +8 -8
  325. package/dist/components/toast/Toast.d.ts +3 -1
  326. package/dist/components/toast/Toast.js +11 -2
  327. package/dist/components/toast/Toast.module.js +6 -6
  328. package/dist/components/toggle/Toggle.css +5 -5
  329. package/dist/components/toggle/Toggle.d.ts +3 -2
  330. package/dist/components/toggle/Toggle.js +5 -4
  331. package/dist/components/toggle/Toggle.module.js +2 -2
  332. package/dist/components/toggle/index.d.ts +2 -2
  333. package/dist/components/toggle-group/ToggleGroup.css +3 -3
  334. package/dist/components/toggle-group/ToggleGroup.d.ts +3 -2
  335. package/dist/components/toggle-group/ToggleGroup.js +4 -3
  336. package/dist/components/toggle-group/ToggleGroup.module.js +2 -2
  337. package/dist/components/toggle-group/index.d.ts +2 -2
  338. package/dist/components/tooltip/Tooltip.css +21 -17
  339. package/dist/components/tooltip/Tooltip.d.ts +3 -2
  340. package/dist/components/tooltip/Tooltip.js +10 -3
  341. package/dist/components/tooltip/Tooltip.module.js +7 -7
  342. package/dist/components/tooltip/index.d.ts +2 -2
  343. package/dist/components/tour/Tour.css +42 -37
  344. package/dist/components/tour/Tour.d.ts +6 -0
  345. package/dist/components/tour/Tour.js +8 -1
  346. package/dist/components/tour/Tour.module.js +17 -17
  347. package/dist/components/tree-view/TreeView.css +22 -22
  348. package/dist/components/tree-view/TreeView.d.ts +2 -2
  349. package/dist/components/tree-view/TreeView.js +4 -4
  350. package/dist/components/tree-view/TreeView.module.js +20 -20
  351. package/dist/components/tree-view/index.d.ts +2 -2
  352. package/dist/index.d.ts +40 -39
  353. package/dist/index.js +40 -39
  354. package/dist/lib/moduix/icons/ui/Icons.d.ts +1 -45
  355. package/dist/lib/moduix/icons/ui/Icons.js +36 -263
  356. package/dist/lib/moduix/icons/ui/index.d.ts +2 -2
  357. package/dist/lib/moduix/overlayPortal.js +1 -1
  358. package/package.json +4 -3
@@ -1,5 +1,5 @@
1
1
  @layer ui.components {
2
- .v74_Gq_trigger {
2
+ ._4OfG0a_trigger {
3
3
  box-sizing: border-box;
4
4
  justify-content: center;
5
5
  align-items: center;
@@ -36,7 +36,7 @@
36
36
  }
37
37
  }
38
38
 
39
- .v74_Gq_backdrop {
39
+ ._4OfG0a_backdrop {
40
40
  z-index: var(--z-backdrop);
41
41
  background-color: var(--command-palette-backdrop-bg, var(--backdrop-bg, var(--color-overlay)));
42
42
  min-height: 100dvh;
@@ -45,18 +45,18 @@
45
45
  inset: 0;
46
46
 
47
47
  &[data-state="open"] {
48
- animation: v74_Gq_command-palette-backdrop-in
48
+ animation: _4OfG0a_command-palette-backdrop-in
49
49
  var(--command-palette-backdrop-transition, var(--transition-default));
50
50
  }
51
51
 
52
52
  &[data-state="closed"] {
53
- animation: v74_Gq_command-palette-backdrop-out
53
+ animation: _4OfG0a_command-palette-backdrop-out
54
54
  var(--command-palette-backdrop-transition, var(--transition-default));
55
55
  animation-fill-mode: forwards;
56
56
  }
57
57
  }
58
58
 
59
- .v74_Gq_positioner {
59
+ ._4OfG0a_positioner {
60
60
  box-sizing: border-box;
61
61
  z-index: var(--z-modal);
62
62
  overscroll-behavior: contain;
@@ -68,12 +68,7 @@
68
68
  overflow: hidden;
69
69
  }
70
70
 
71
- .v74_Gq_content {
72
- --command-palette-close-icon-size-effective: var(--command-palette-close-icon-size, var(--command-palette-clear-size, var(--size-sm)));
73
- --command-palette-close-offset-effective: var(--command-palette-close-offset, var(--spacing-3));
74
- --command-palette-header-padding-inline-end-effective: var(--command-palette-header-padding-inline-end, calc(var(--command-palette-header-padding-x, var(--spacing-4)) +
75
- var(--command-palette-close-icon-size-effective) +
76
- var(--command-palette-close-offset-effective)));
71
+ ._4OfG0a_content {
77
72
  box-sizing: border-box;
78
73
  width: min(var(--command-palette-width, 37.5rem),
79
74
  var(--command-palette-max-width, calc(100vw - var(--spacing-8, 2rem))));
@@ -90,30 +85,30 @@
90
85
  outline: 0;
91
86
  flex-direction: column;
92
87
  display: flex;
93
- position: relative;
94
88
  overflow: hidden;
95
89
 
96
90
  &[data-state="open"] {
97
- animation: v74_Gq_command-palette-content-in
98
- var(--command-palette-transition, var(--transition-default));
91
+ animation: _4OfG0a_command-palette-content-in
92
+ var(--command-palette-transition, var(--popup-motion-duration, var(--duration-normal))
93
+ var(--popup-motion-easing, var(--ease-in-out)));
99
94
  }
100
95
 
101
96
  &[data-state="closed"] {
102
- animation: v74_Gq_command-palette-content-out
103
- var(--command-palette-transition, var(--transition-default));
97
+ animation: _4OfG0a_command-palette-content-out
98
+ var(--command-palette-transition, var(--popup-motion-duration, var(--duration-normal))
99
+ var(--popup-motion-easing, var(--ease-in-out)));
104
100
  animation-fill-mode: forwards;
105
101
  }
106
102
  }
107
103
 
108
- .v74_Gq_header {
104
+ ._4OfG0a_header {
109
105
  gap: var(--command-palette-header-gap, var(--spacing-1));
110
106
  padding: var(--command-palette-header-padding-y, var(--spacing-4))
111
107
  var(--command-palette-header-padding-x, var(--spacing-4)) 0;
112
- padding-inline-end: var(--command-palette-header-padding-inline-end-effective);
113
108
  display: grid;
114
109
  }
115
110
 
116
- .v74_Gq_title {
111
+ ._4OfG0a_title {
117
112
  color: var(--command-palette-title-color, var(--command-palette-color, var(--color-popover-foreground)));
118
113
  font-size: var(--command-palette-title-font-size, var(--text-md));
119
114
  font-weight: var(--command-palette-title-font-weight, var(--weight-semibold));
@@ -121,80 +116,39 @@
121
116
  margin: 0;
122
117
  }
123
118
 
124
- .v74_Gq_description {
119
+ ._4OfG0a_description {
125
120
  color: var(--command-palette-description-color, var(--color-muted-foreground));
126
121
  font-size: var(--command-palette-description-font-size, var(--text-sm));
127
122
  line-height: var(--command-palette-description-line-height, var(--line-height-text-sm));
128
123
  margin: 0;
129
124
  }
130
125
 
131
- .v74_Gq_closeTrigger, .v74_Gq_clearTrigger {
132
- box-sizing: border-box;
133
- width: var(--command-palette-clear-size, var(--size-sm));
134
- height: var(--command-palette-clear-size, var(--size-sm));
135
- border-radius: var(--command-palette-clear-radius, var(--radius-md));
136
- color: var(--command-palette-muted-color, var(--color-muted-foreground));
137
- cursor: pointer;
138
- transition: background-color var(--transition-default),
139
- color var(--transition-default);
140
- background: none;
141
- border: 0;
142
- flex-shrink: 0;
143
- justify-content: center;
144
- align-items: center;
145
- margin: 0;
146
- padding: 0;
147
- display: inline-flex;
148
-
149
- @media (hover: hover) {
150
- &:hover {
151
- background-color: var(--command-palette-clear-bg-hover, var(--color-accent));
152
- color: var(--command-palette-color, var(--color-popover-foreground));
153
- }
154
- }
155
-
156
- &:focus-visible {
157
- outline: var(--command-palette-focus-ring-width, var(--border-width-sm)) solid
158
- var(--command-palette-focus-ring-color, var(--color-ring));
159
- outline-offset: var(--command-palette-focus-ring-offset, var(--border-width-sm));
160
- }
161
- }
162
-
163
- .v74_Gq_closeTrigger {
164
- top: var(--command-palette-close-offset-effective);
165
- right: var(--command-palette-close-offset-effective);
166
- z-index: 1;
167
- position: absolute;
168
- }
169
-
170
- .v74_Gq_closeIcon {
171
- --close-button-size: var(--command-palette-close-icon-size-effective);
172
- --close-button-radius: var(--command-palette-close-icon-radius, var(--command-palette-clear-radius, var(--radius-md)));
173
- --close-button-icon-size: var(--command-palette-close-icon-glyph-size, var(--command-palette-icon-size, 1rem));
174
- --close-button-bg: var(--command-palette-close-icon-bg, transparent);
126
+ ._4OfG0a_clearTrigger {
127
+ --close-button-size: var(--command-palette-clear-size, var(--size-sm));
128
+ --close-button-radius: var(--command-palette-clear-radius, var(--radius-md));
129
+ --close-button-icon-size: var(--command-palette-icon-size, 1rem);
130
+ --close-button-bg: transparent;
175
131
  --close-button-bg-hover: var(--command-palette-clear-bg-hover, var(--color-accent));
176
- --close-button-color: var(--command-palette-close-icon-color, var(--command-palette-muted-color, var(--color-muted-foreground)));
132
+ --close-button-color: var(--command-palette-muted-color, var(--color-muted-foreground));
177
133
  --close-button-color-hover: var(--command-palette-color, var(--color-popover-foreground));
134
+ --close-button-focus-ring-width: var(--command-palette-focus-ring-width, var(--border-width-sm));
178
135
  --close-button-focus-ring-color: var(--command-palette-focus-ring-color, var(--color-ring));
179
- top: var(--command-palette-close-offset-effective);
180
- right: var(--command-palette-close-offset-effective);
181
- z-index: 1;
182
- position: absolute;
136
+ --close-button-focus-ring-offset: var(--command-palette-focus-ring-offset, var(--border-width-sm));
183
137
  }
184
138
 
185
- .v74_Gq_body {
139
+ ._4OfG0a_body {
186
140
  flex-direction: column;
187
141
  flex: auto;
188
142
  min-height: 0;
189
143
  display: flex;
190
144
  }
191
145
 
192
- .v74_Gq_iconSvg {
146
+ ._4OfG0a_iconSvg {
193
147
  width: var(--command-palette-icon-size, 1rem);
194
148
  height: var(--command-palette-icon-size, 1rem);
195
149
  }
196
150
 
197
- .v74_Gq_combobox {
151
+ ._4OfG0a_combobox {
198
152
  flex-direction: column;
199
153
  flex: auto;
200
154
  min-height: 0;
@@ -202,29 +156,41 @@
202
156
  overflow: hidden;
203
157
  }
204
158
 
205
- .v74_Gq_control {
159
+ ._4OfG0a_control {
206
160
  box-sizing: border-box;
207
161
  align-items: center;
208
162
  gap: var(--command-palette-input-gap, var(--spacing-2));
209
- min-height: var(--command-palette-input-height, 4rem);
210
- padding: var(--command-palette-control-padding-y, var(--spacing-3))
211
- var(--command-palette-control-padding-x, var(--spacing-4));
212
- border-bottom: var(--command-palette-divider-width, var(--border-width-sm)) solid
213
- var(--command-palette-divider-color, var(--color-border));
163
+ min-height: var(--command-palette-input-height, var(--size-md));
164
+ margin: var(--command-palette-control-margin-y, var(--spacing-2))
165
+ var(--command-palette-control-margin-x, var(--spacing-4))
166
+ var(--command-palette-control-margin-bottom, var(--spacing-2));
167
+ border: var(--command-palette-input-border-width, var(--border-width-sm)) solid
168
+ var(--command-palette-input-border-color, var(--color-border));
169
+ border-radius: var(--command-palette-input-radius, var(--radius-md));
170
+ padding: var(--command-palette-control-padding-y, var(--spacing-1))
171
+ var(--command-palette-control-padding-x, var(--spacing-3));
172
+ background-color: var(--command-palette-input-bg, var(--color-background));
173
+ color: var(--command-palette-input-color, var(--color-foreground));
174
+ transition: background-color var(--transition-default),
175
+ border-color var(--transition-default);
214
176
  flex: none;
215
177
  display: flex;
216
178
  position: relative;
179
+
180
+ &:has(._4OfG0a_input:is([data-invalid], [aria-invalid="true"])) {
181
+ border-color: var(--command-palette-input-border-color-invalid, var(--color-destructive));
182
+ }
217
183
  }
218
184
 
219
- .v74_Gq_input {
185
+ ._4OfG0a_input {
220
186
  box-sizing: border-box;
221
187
  width: 100%;
222
188
  min-width: 0;
223
- height: var(--command-palette-input-control-height, var(--size-md));
189
+ height: var(--command-palette-input-control-height, var(--size-sm));
224
190
  color: inherit;
225
191
  font: inherit;
226
- font-size: var(--command-palette-input-font-size, var(--text-lg));
227
- line-height: var(--command-palette-input-line-height, var(--line-height-text-lg));
192
+ font-size: var(--command-palette-input-font-size, var(--text-sm));
193
+ line-height: var(--command-palette-input-line-height, var(--line-height-text-sm));
228
194
  background: none;
229
195
  border: 0;
230
196
  outline: 0;
@@ -240,7 +206,7 @@
240
206
  }
241
207
  }
242
208
 
243
- .v74_Gq_empty {
209
+ ._4OfG0a_empty {
244
210
  margin: 0;
245
211
  padding: 0;
246
212
 
@@ -253,7 +219,7 @@
253
219
  }
254
220
  }
255
221
 
256
- .v74_Gq_list {
222
+ ._4OfG0a_list {
257
223
  box-sizing: border-box;
258
224
  outline: 0;
259
225
  flex: auto;
@@ -262,7 +228,7 @@
262
228
  overflow: hidden;
263
229
  }
264
230
 
265
- .v74_Gq_scrollArea {
231
+ ._4OfG0a_scrollArea {
266
232
  --scroll-area-radius: 0;
267
233
  --scroll-area-scrollbar-margin: var(--command-palette-scrollbar-margin, var(--spacing-1));
268
234
  --scroll-area-scrollbar-size: var(--command-palette-scrollbar-size, .375rem);
@@ -279,23 +245,23 @@
279
245
  flex: auto;
280
246
  }
281
247
 
282
- .v74_Gq_scrollViewport {
248
+ ._4OfG0a_scrollViewport {
283
249
  scroll-padding-block: var(--command-palette-list-scroll-padding-y, var(--spacing-2));
284
250
  }
285
251
 
286
- .v74_Gq_scrollContent {
252
+ ._4OfG0a_scrollContent {
287
253
  min-height: 100%;
288
254
 
289
- .v74_Gq_list[data-empty] & {
255
+ ._4OfG0a_list[data-empty] & {
290
256
  padding: 0;
291
257
  }
292
258
  }
293
259
 
294
- .v74_Gq_scrollbar {
260
+ ._4OfG0a_scrollbar {
295
261
  --scroll-area-scrollbar-bg: transparent;
296
262
  }
297
263
 
298
- .v74_Gq_itemGroup {
264
+ ._4OfG0a_itemGroup {
299
265
  gap: var(--command-palette-group-gap, var(--spacing-1));
300
266
  display: grid;
301
267
 
@@ -304,7 +270,7 @@
304
270
  }
305
271
  }
306
272
 
307
- .v74_Gq_itemGroupLabel {
273
+ ._4OfG0a_itemGroupLabel {
308
274
  z-index: 1;
309
275
  padding: var(--command-palette-group-label-padding-y, var(--spacing-1))
310
276
  var(--command-palette-group-label-padding-x, var(--spacing-3));
@@ -319,7 +285,7 @@
319
285
  top: 0;
320
286
  }
321
287
 
322
- .v74_Gq_item {
288
+ ._4OfG0a_item {
323
289
  box-sizing: border-box;
324
290
  z-index: 0;
325
291
  align-items: center;
@@ -362,7 +328,7 @@
362
328
  }
363
329
  }
364
330
 
365
- .v74_Gq_itemIcon, .v74_Gq_itemIndicator {
331
+ ._4OfG0a_itemIcon, ._4OfG0a_itemIndicator {
366
332
  width: var(--command-palette-item-icon-box-size, 2rem);
367
333
  height: var(--command-palette-item-icon-box-size, 2rem);
368
334
  border: var(--command-palette-item-icon-border-width, var(--border-width-sm)) solid
@@ -380,7 +346,7 @@
380
346
  }
381
347
  }
382
348
 
383
- .v74_Gq_itemIndicator {
349
+ ._4OfG0a_itemIndicator {
384
350
  background-color: #0000;
385
351
  border-color: #0000;
386
352
  justify-self: end;
@@ -391,12 +357,12 @@
391
357
  }
392
358
  }
393
359
 
394
- .v74_Gq_itemText {
360
+ ._4OfG0a_itemText {
395
361
  gap: var(--command-palette-item-text-gap, var(--spacing-1));
396
362
  min-width: 0;
397
363
  display: grid;
398
364
 
399
- & > .v74_Gq_itemLabel, & > .v74_Gq_itemDescription {
365
+ & > ._4OfG0a_itemLabel, & > ._4OfG0a_itemDescription {
400
366
  text-overflow: ellipsis;
401
367
  white-space: nowrap;
402
368
  min-width: 0;
@@ -404,17 +370,17 @@
404
370
  }
405
371
  }
406
372
 
407
- .v74_Gq_itemLabel {
373
+ ._4OfG0a_itemLabel {
408
374
  font-weight: var(--command-palette-item-label-font-weight, var(--weight-medium));
409
375
  }
410
376
 
411
- .v74_Gq_itemDescription {
377
+ ._4OfG0a_itemDescription {
412
378
  color: var(--command-palette-muted-color, var(--color-muted-foreground));
413
379
  font-size: var(--command-palette-item-description-font-size, var(--text-xs));
414
380
  line-height: var(--command-palette-item-description-line-height, var(--line-height-text-xs));
415
381
  }
416
382
 
417
- .v74_Gq_itemMeta {
383
+ ._4OfG0a_itemMeta {
418
384
  color: var(--command-palette-muted-color, var(--color-muted-foreground));
419
385
  font-size: var(--command-palette-item-meta-font-size, var(--text-xs));
420
386
  line-height: var(--command-palette-item-meta-line-height, var(--line-height-text-xs));
@@ -422,14 +388,14 @@
422
388
  justify-self: end;
423
389
  }
424
390
 
425
- .v74_Gq_separator {
391
+ ._4OfG0a_separator {
426
392
  height: var(--command-palette-divider-width, var(--border-width-sm));
427
393
  margin: var(--command-palette-separator-margin-y, var(--spacing-2))
428
394
  var(--command-palette-separator-margin-x, var(--spacing-2));
429
395
  background-color: var(--command-palette-divider-color, var(--color-border));
430
396
  }
431
397
 
432
- .v74_Gq_footer {
398
+ ._4OfG0a_footer {
433
399
  justify-content: space-between;
434
400
  align-items: center;
435
401
  gap: var(--command-palette-footer-gap, var(--spacing-3));
@@ -444,7 +410,7 @@
444
410
  display: flex;
445
411
  }
446
412
 
447
- .v74_Gq_kbd {
413
+ ._4OfG0a_kbd {
448
414
  --kbd-bg: var(--command-palette-kbd-bg, var(--color-muted));
449
415
  --kbd-border-color: var(--command-palette-kbd-border-color, var(--color-border));
450
416
  --kbd-border-width: var(--command-palette-kbd-border-width, var(--border-width-sm));
@@ -458,35 +424,35 @@
458
424
  --kbd-radius: var(--command-palette-kbd-radius, var(--radius-sm));
459
425
  }
460
426
 
461
- @keyframes v74_Gq_command-palette-backdrop-in {
427
+ @keyframes _4OfG0a_command-palette-backdrop-in {
462
428
  from {
463
429
  opacity: var(--command-palette-backdrop-starting-opacity, 0);
464
430
  backdrop-filter: var(--command-palette-backdrop-starting-blur, none);
465
431
  }
466
432
  }
467
433
 
468
- @keyframes v74_Gq_command-palette-backdrop-out {
434
+ @keyframes _4OfG0a_command-palette-backdrop-out {
469
435
  to {
470
436
  opacity: var(--command-palette-backdrop-ending-opacity, 0);
471
437
  backdrop-filter: var(--command-palette-backdrop-ending-blur, none);
472
438
  }
473
439
  }
474
440
 
475
- @keyframes v74_Gq_command-palette-content-in {
441
+ @keyframes _4OfG0a_command-palette-content-in {
476
442
  from {
477
- opacity: var(--command-palette-content-starting-opacity, 0);
478
- translate: var(--command-palette-content-starting-translate-x, 0)
479
- var(--command-palette-content-starting-translate-y, -.75rem);
480
- scale: var(--command-palette-content-starting-scale, var(--scale-popup));
443
+ opacity: var(--command-palette-content-starting-opacity, var(--popup-motion-starting-opacity, 0));
444
+ translate: var(--command-palette-content-starting-translate-x, var(--popup-motion-starting-translate-x, 0))
445
+ var(--command-palette-content-starting-translate-y, var(--popup-motion-starting-translate-y, -.75rem));
446
+ scale: var(--command-palette-content-starting-scale, var(--popup-motion-starting-scale, var(--scale-popup)));
481
447
  }
482
448
  }
483
449
 
484
- @keyframes v74_Gq_command-palette-content-out {
450
+ @keyframes _4OfG0a_command-palette-content-out {
485
451
  to {
486
- opacity: var(--command-palette-content-ending-opacity, 0);
487
- translate: var(--command-palette-content-ending-translate-x, 0)
488
- var(--command-palette-content-ending-translate-y, -.75rem);
489
- scale: var(--command-palette-content-ending-scale, var(--scale-popup));
452
+ opacity: var(--command-palette-content-ending-opacity, var(--popup-motion-ending-opacity, 0));
453
+ translate: var(--command-palette-content-ending-translate-x, var(--popup-motion-ending-translate-x, 0))
454
+ var(--command-palette-content-ending-translate-y, var(--popup-motion-ending-translate-y, -.75rem));
455
+ scale: var(--command-palette-content-ending-scale, var(--popup-motion-ending-scale, var(--scale-popup)));
490
456
  }
491
457
  }
492
458
  }
@@ -1,3 +1,4 @@
1
+ import { CloseButton } from "../close-button/CloseButton.js";
1
2
  import { OverlayPortalProps } from "../../lib/moduix/overlayPortal.js";
2
3
  import { Kbd } from "../kbd/Kbd.js";
3
4
  import { ComponentProps } from "react";
@@ -10,6 +11,10 @@ type CommandPaletteRootProps = ComponentProps<typeof Dialog.Root> & {
10
11
  shortcutTarget?: Document | HTMLElement | null;
11
12
  } & OverlayPortalProps;
12
13
  type CommandPaletteRootProviderProps = ComponentProps<typeof Dialog.RootProvider> & OverlayPortalProps;
14
+ type CommandPaletteSearchProps = ComponentProps<typeof Combobox.Input> & {
15
+ controlProps?: ComponentProps<typeof Combobox.Control>;
16
+ clearTriggerProps?: ComponentProps<typeof CloseButton.Root>;
17
+ };
13
18
  declare function CommandPaletteRoot({
14
19
  shortcut,
15
20
  shortcutTarget,
@@ -42,16 +47,21 @@ declare const CommandPalette: typeof CommandPaletteRoot & {
42
47
  Backdrop: import("react").ForwardRefExoticComponent<Omit<Dialog.BackdropProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
43
48
  Positioner: import("react").ForwardRefExoticComponent<Omit<Dialog.PositionerProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
44
49
  Content: import("react").ForwardRefExoticComponent<Omit<Dialog.ContentProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
50
+ Panel: import("react").ForwardRefExoticComponent<Omit<Dialog.ContentProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
45
51
  Title: import("react").ForwardRefExoticComponent<Omit<Dialog.TitleProps & import("react").RefAttributes<HTMLHeadingElement>, "ref"> & import("react").RefAttributes<HTMLHeadingElement>>;
46
52
  Description: import("react").ForwardRefExoticComponent<Omit<Dialog.DescriptionProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
47
- CloseTrigger: import("react").ForwardRefExoticComponent<Omit<Dialog.CloseTriggerProps & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
48
- CloseIcon: import("react").ForwardRefExoticComponent<Omit<Omit<Dialog.CloseTriggerProps & import("react").RefAttributes<HTMLButtonElement>, "asChild">, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
49
53
  Header: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLDivElement>>;
50
54
  Body: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLDivElement>>;
51
55
  Combobox: Combobox.RootComponent;
52
56
  Control: import("react").ForwardRefExoticComponent<Omit<Combobox.ControlProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
53
57
  Input: import("react").ForwardRefExoticComponent<Omit<Combobox.InputProps & import("react").RefAttributes<HTMLInputElement>, "ref"> & import("react").RefAttributes<HTMLInputElement>>;
54
- ClearTrigger: import("react").ForwardRefExoticComponent<Omit<Combobox.ClearTriggerProps & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
58
+ Search: import("react").ForwardRefExoticComponent<Omit<CommandPaletteSearchProps, "ref"> & import("react").RefAttributes<HTMLInputElement>>;
59
+ ClearTrigger: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & {
60
+ 'data-disabled'?: string;
61
+ 'data-part'?: string;
62
+ 'data-scope'?: string;
63
+ 'data-slot'?: string;
64
+ } & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
55
65
  List: import("react").ForwardRefExoticComponent<Omit<Combobox.ContentProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
56
66
  Empty: import("react").ForwardRefExoticComponent<Omit<Combobox.EmptyProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
57
67
  ItemGroup: import("react").ForwardRefExoticComponent<Omit<Combobox.ItemGroupProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
@@ -1,20 +1,19 @@
1
- import { CheckIcon, CloseIcon } from "../../lib/moduix/icons/ui/Icons.js";
2
1
  import { normalizeClassName } from "../../lib/moduix/normalizeClassName.js";
2
+ import { CheckIcon } from "../../lib/moduix/icons/ui/Icons.js";
3
3
  import { CloseButton } from "../close-button/CloseButton.js";
4
4
  import { OverlayPortal, OverlayPortalProvider } from "../../lib/moduix/overlayPortal.js";
5
5
  import { Kbd } from "../kbd/Kbd.js";
6
6
  import { ScrollArea } from "../scroll-area/ScrollArea.js";
7
7
  import CommandPalette_module_default from "./CommandPalette.module.js";
8
- import { jsx, jsxs } from "react/jsx-runtime";
9
8
  import { ark } from "@ark-ui/react/factory";
10
9
  import { clsx } from "clsx";
11
10
  import { forwardRef, useEffect } from "react";
11
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
12
12
  import { Combobox } from "@ark-ui/react/combobox";
13
13
  import { Dialog, useDialog, useDialogContext } from "@ark-ui/react/dialog";
14
14
  //#region src/components/command-palette/CommandPalette.tsx
15
- const DEFAULT_CLOSE_TRIGGER_LABEL = "Close command palette";
16
- const DEFAULT_CLOSE_ICON_LABEL = "Close command palette";
17
15
  const DEFAULT_CLEAR_TRIGGER_LABEL = "Clear search";
16
+ const DEFAULT_SEARCH_INPUT_LABEL = "Search commands";
18
17
  function isShortcutMatch(event, shortcut) {
19
18
  const parts = shortcut.toLowerCase().split("+").map((part) => part.trim()).filter(Boolean);
20
19
  const [modifier, key] = parts;
@@ -38,9 +37,9 @@ function CommandPaletteRoot({ shortcut = false, shortcutTarget, lazyMount = true
38
37
  if (!shortcut || shortcutTarget === null) return;
39
38
  const target = shortcutTarget ?? document;
40
39
  const handleKeyDown = (event) => {
41
- if (event.defaultPrevented || event.isComposing || isEditableTarget(event.target) || !isShortcutMatch(event, shortcut)) return;
40
+ if (event.defaultPrevented || event.isComposing || !isShortcutMatch(event, shortcut) || !dialog.open && isEditableTarget(event.target)) return;
42
41
  event.preventDefault();
43
- dialog.setOpen(true);
42
+ dialog.setOpen(!dialog.open);
44
43
  };
45
44
  const eventListener = handleKeyDown;
46
45
  target.addEventListener("keydown", eventListener);
@@ -109,6 +108,13 @@ const CommandPaletteContent = forwardRef(function CommandPaletteContent({ classN
109
108
  ...props
110
109
  });
111
110
  });
111
+ const CommandPalettePanel = forwardRef(function CommandPalettePanel({ children, ...props }, ref) {
112
+ return /* @__PURE__ */ jsxs(Fragment$1, { children: [/* @__PURE__ */ jsx(CommandPaletteBackdrop, {}), /* @__PURE__ */ jsx(CommandPalettePositioner, { children: /* @__PURE__ */ jsx(CommandPaletteContent, {
113
+ ref,
114
+ ...props,
115
+ children: /* @__PURE__ */ jsx(CommandPaletteBody, { children })
116
+ }) })] });
117
+ });
112
118
  const CommandPaletteTitle = forwardRef(function CommandPaletteTitle({ className, ...props }, ref) {
113
119
  return /* @__PURE__ */ jsx(Dialog.Title, {
114
120
  ref,
@@ -125,31 +131,6 @@ const CommandPaletteDescription = forwardRef(function CommandPaletteDescription(
125
131
  ...props
126
132
  });
127
133
  });
128
- const CommandPaletteCloseTrigger = forwardRef(function CommandPaletteCloseTrigger({ asChild, className, children, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, ...props }, ref) {
129
- return /* @__PURE__ */ jsx(Dialog.CloseTrigger, {
130
- ref,
131
- asChild,
132
- "data-slot": "command-palette-close-trigger",
133
- "aria-label": ariaLabel ?? (!asChild && children == null && ariaLabelledBy == null ? DEFAULT_CLOSE_TRIGGER_LABEL : void 0),
134
- "aria-labelledby": ariaLabelledBy,
135
- className: clsx(!asChild && CommandPalette_module_default.closeTrigger, normalizeClassName(className)),
136
- ...props,
137
- children: children ?? (!asChild ? /* @__PURE__ */ jsx(CloseIcon, { className: CommandPalette_module_default.iconSvg }) : void 0)
138
- });
139
- });
140
- const CommandPaletteCloseIcon = forwardRef(function CommandPaletteCloseIcon({ className, children, "aria-label": ariaLabel = DEFAULT_CLOSE_ICON_LABEL, ...props }, ref) {
141
- return /* @__PURE__ */ jsx(Dialog.CloseTrigger, {
142
- asChild: true,
143
- ...props,
144
- children: /* @__PURE__ */ jsx(CloseButton.Root, {
145
- ref,
146
- "data-slot": "command-palette-close-icon",
147
- "aria-label": ariaLabel,
148
- className: clsx(CommandPalette_module_default.closeIcon, normalizeClassName(className)),
149
- children
150
- })
151
- });
152
- });
153
134
  const CommandPaletteHeader = forwardRef(function CommandPaletteHeader({ className, ...props }, ref) {
154
135
  return /* @__PURE__ */ jsx(ark.div, {
155
136
  ref,
@@ -201,18 +182,48 @@ const CommandPaletteInput = forwardRef(function CommandPaletteInput({ className,
201
182
  ...props
202
183
  });
203
184
  });
204
- const CommandPaletteClearTrigger = forwardRef(function CommandPaletteClearTrigger({ asChild, className, children, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, ...props }, ref) {
205
- return /* @__PURE__ */ jsx(Combobox.ClearTrigger, {
206
- ref,
207
- asChild,
208
- "data-slot": "command-palette-clear-trigger",
209
- "aria-label": ariaLabel ?? (!asChild && children == null && ariaLabelledBy == null ? DEFAULT_CLEAR_TRIGGER_LABEL : void 0),
210
- "aria-labelledby": ariaLabelledBy,
211
- className: clsx(!asChild && CommandPalette_module_default.clearTrigger, normalizeClassName(className)),
212
- ...props,
213
- children: children ?? (!asChild ? /* @__PURE__ */ jsx(CloseIcon, { className: CommandPalette_module_default.iconSvg }) : void 0)
185
+ const CommandPaletteSearch = forwardRef(function CommandPaletteSearch({ "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, clearTriggerProps, controlProps, ...props }, ref) {
186
+ return /* @__PURE__ */ jsxs(CommandPaletteControl, {
187
+ ...controlProps,
188
+ children: [/* @__PURE__ */ jsx(CommandPaletteInput, {
189
+ ref,
190
+ "aria-label": ariaLabel ?? (ariaLabelledBy == null ? DEFAULT_SEARCH_INPUT_LABEL : void 0),
191
+ "aria-labelledby": ariaLabelledBy,
192
+ ...props
193
+ }), /* @__PURE__ */ jsx(CommandPaletteClearTrigger, { ...clearTriggerProps })]
214
194
  });
215
195
  });
196
+ const CommandPaletteClearTrigger = forwardRef(function CommandPaletteClearTrigger({ asChild, className, children, disabled, onClick, onPointerDown, tabIndex, "aria-controls": ariaControls, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, ...props }, ref) {
197
+ return /* @__PURE__ */ jsx(Combobox.Context, { children: (combobox) => {
198
+ const inputProps = combobox.getInputProps();
199
+ const isInvalid = inputProps["aria-invalid"] === true || inputProps["aria-invalid"] === "true";
200
+ return /* @__PURE__ */ jsx(CloseButton.Root, {
201
+ ref,
202
+ asChild,
203
+ ...props,
204
+ disabled: disabled ?? combobox.disabled,
205
+ "data-scope": "combobox",
206
+ "data-part": "clear-trigger",
207
+ "data-slot": "command-palette-clear-trigger",
208
+ "data-invalid": isInvalid ? "" : void 0,
209
+ hidden: combobox.inputValue.length === 0,
210
+ tabIndex: tabIndex ?? -1,
211
+ "aria-controls": ariaControls ?? inputProps.id,
212
+ "aria-label": ariaLabel ?? (!asChild && children == null && ariaLabelledBy == null ? DEFAULT_CLEAR_TRIGGER_LABEL : void 0),
213
+ "aria-labelledby": ariaLabelledBy,
214
+ className: clsx(CommandPalette_module_default.clearTrigger, normalizeClassName(className)),
215
+ onPointerDown: (event) => {
216
+ onPointerDown?.(event);
217
+ if (event.button === 0) event.preventDefault();
218
+ },
219
+ onClick: (event) => {
220
+ onClick?.(event);
221
+ if (!event.defaultPrevented) combobox.setInputValue("");
222
+ },
223
+ children
224
+ });
225
+ } });
226
+ });
216
227
  const CommandPaletteList = forwardRef(function CommandPaletteList({ className, children, ...props }, ref) {
217
228
  return /* @__PURE__ */ jsx(Combobox.Content, {
218
229
  ref,
@@ -354,15 +365,15 @@ const CommandPalette = Object.assign(CommandPaletteRoot, {
354
365
  Backdrop: CommandPaletteBackdrop,
355
366
  Positioner: CommandPalettePositioner,
356
367
  Content: CommandPaletteContent,
368
+ Panel: CommandPalettePanel,
357
369
  Title: CommandPaletteTitle,
358
370
  Description: CommandPaletteDescription,
359
- CloseTrigger: CommandPaletteCloseTrigger,
360
- CloseIcon: CommandPaletteCloseIcon,
361
371
  Header: CommandPaletteHeader,
362
372
  Body: CommandPaletteBody,
363
373
  Combobox: CommandPaletteCombobox,
364
374
  Control: CommandPaletteControl,
365
375
  Input: CommandPaletteInput,
376
+ Search: CommandPaletteSearch,
366
377
  ClearTrigger: CommandPaletteClearTrigger,
367
378
  List: CommandPaletteList,
368
379
  Empty: CommandPaletteEmpty,