haze-ui 1.29.0 → 1.30.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 (386) hide show
  1. package/README.md +58 -0
  2. package/cli/theme.mjs +446 -0
  3. package/dist/components/Accordion/Accordion.js +1 -0
  4. package/dist/components/Accordion/AccordionItem.js +3 -0
  5. package/dist/components/Affix/Affix.js +1 -0
  6. package/dist/components/Alert/Alert.js +3 -0
  7. package/dist/components/Anchor/Anchor.js +21 -15
  8. package/dist/components/AppShell/AppShell.js +5 -0
  9. package/dist/components/ApprovalCard/ApprovalCard.js +8 -0
  10. package/dist/components/AspectRatio/AspectRatio.js +2 -0
  11. package/dist/components/AsyncSection/AsyncSection.js +8 -0
  12. package/dist/components/Avatar/Avatar.js +11 -6
  13. package/dist/components/AvatarGroup/AvatarGroup.js +9 -6
  14. package/dist/components/BackToTop/BackToTop.js +5 -4
  15. package/dist/components/Badge/Badge.js +1 -0
  16. package/dist/components/Banner/Banner.js +3 -0
  17. package/dist/components/BottomSheet/BottomSheet.js +21 -16
  18. package/dist/components/Breadcrumb/Breadcrumb.js +11 -7
  19. package/dist/components/Breadcrumb/BreadcrumbItem.js +2 -0
  20. package/dist/components/Button/Button.js +13 -11
  21. package/dist/components/Button/ButtonLink.js +15 -13
  22. package/dist/components/Calendar/Calendar.js +523 -368
  23. package/dist/components/Calendar/date.js +35 -10
  24. package/dist/components/Card/Card.js +1 -0
  25. package/dist/components/Carousel/Carousel.js +157 -60
  26. package/dist/components/Carousel/CarouselSlide.js +3 -1
  27. package/dist/components/Cascader/Cascader.js +48 -35
  28. package/dist/components/Chart/Chart.js +5 -4
  29. package/dist/components/Chart/chart-elements.js +14 -10
  30. package/dist/components/ChatContainer/ChatContainer.js +9 -7
  31. package/dist/components/ChatInput/ChatInput.js +12 -9
  32. package/dist/components/ChatMessage/ChatMessage.js +83 -44
  33. package/dist/components/Checkbox/CheckboxCore.js +2 -0
  34. package/dist/components/Chip/Chip.js +3 -0
  35. package/dist/components/CodeBlock/CodeBlock.js +18 -9
  36. package/dist/components/Collapsible/Collapsible.js +24 -21
  37. package/dist/components/ColorPicker/ColorPicker.js +85 -14
  38. package/dist/components/ColorPicker/ColorPickerCore.js +6 -0
  39. package/dist/components/ColorPicker/ColorPickerPanel.js +277 -0
  40. package/dist/components/ColorPicker/color-math.js +168 -0
  41. package/dist/components/ColorPicker/color-picker-styles.js +7 -0
  42. package/dist/components/ColorPicker/index.js +3 -3
  43. package/dist/components/Combobox/Combobox.js +31 -24
  44. package/dist/components/Combobox/ComboboxGroup.js +7 -5
  45. package/dist/components/Combobox/ComboboxOption.js +1 -0
  46. package/dist/components/Command/Command.js +44 -37
  47. package/dist/components/Command/CommandDialog.js +8 -8
  48. package/dist/components/ConfigProvider/ConfigContext.js +30 -0
  49. package/dist/components/ConfigProvider/ConfigProvider.js +14 -0
  50. package/dist/components/ConfigProvider/index.js +4 -0
  51. package/dist/components/ConfigProvider/useConfigDefaults.js +10 -0
  52. package/dist/components/ConfirmDialog/ConfirmDialog.js +18 -11
  53. package/dist/components/Container/Container.js +1 -0
  54. package/dist/components/ContextMenu/ContextMenu.js +7 -6
  55. package/dist/components/ContextMenu/ContextMenuContent.js +4 -4
  56. package/dist/components/ContextMenu/ContextMenuItem.js +1 -0
  57. package/dist/components/ContextMenu/ContextMenuSeparator.js +1 -0
  58. package/dist/components/ContextMenu/ContextMenuTrigger.js +1 -0
  59. package/dist/components/ConversationList/ConversationItem.js +4 -0
  60. package/dist/components/ConversationList/ConversationList.js +1 -0
  61. package/dist/components/CountUp/CountUp.js +6 -5
  62. package/dist/components/DataTable/CellEditor.js +4 -4
  63. package/dist/components/DataTable/DataTable.js +236 -168
  64. package/dist/components/DateRangePicker/DateRangePickerCore.js +9 -0
  65. package/dist/components/Datepicker/Datepicker.js +14 -11
  66. package/dist/components/Datepicker/DatepickerCore.js +75 -60
  67. package/dist/components/Datepicker/datetime.js +14 -3
  68. package/dist/components/Descriptions/Descriptions.js +6 -0
  69. package/dist/components/Dialog/Dialog.js +13 -11
  70. package/dist/components/DiffViewer/DiffViewer.js +22 -13
  71. package/dist/components/Disclosure/Disclosure.js +10 -7
  72. package/dist/components/Divider/Divider.js +2 -0
  73. package/dist/components/Drawer/Drawer.js +10 -9
  74. package/dist/components/DropdownMenu/DropdownMenu.js +58 -35
  75. package/dist/components/DropdownMenu/DropdownMenuCheckboxItem.js +63 -0
  76. package/dist/components/DropdownMenu/DropdownMenuContent.js +5 -5
  77. package/dist/components/DropdownMenu/DropdownMenuGroup.js +26 -0
  78. package/dist/components/DropdownMenu/DropdownMenuItem.js +29 -10
  79. package/dist/components/DropdownMenu/DropdownMenuRadioGroup.js +30 -0
  80. package/dist/components/DropdownMenu/DropdownMenuRadioItem.js +59 -0
  81. package/dist/components/DropdownMenu/DropdownMenuSeparator.js +1 -0
  82. package/dist/components/DropdownMenu/DropdownMenuSub.js +1 -0
  83. package/dist/components/DropdownMenu/DropdownMenuSubTrigger.js +1 -0
  84. package/dist/components/DropdownMenu/DropdownMenuTrigger.js +1 -0
  85. package/dist/components/DropdownMenu/dropdown-menu-item-styles.js +7 -0
  86. package/dist/components/DropdownMenu/index.js +12 -8
  87. package/dist/components/Ellipsis/Ellipsis.js +11 -8
  88. package/dist/components/Empty/Empty.js +4 -0
  89. package/dist/components/FileInput/FileInput.js +7 -5
  90. package/dist/components/FilePreview/FilePreview.js +19 -1
  91. package/dist/components/Flex/Flex.js +1 -0
  92. package/dist/components/FloatButton/FloatButton.js +4 -0
  93. package/dist/components/FloatButton/FloatButtonGroup.js +18 -13
  94. package/dist/components/Fullscreen/Fullscreen.js +6 -3
  95. package/dist/components/Grid/Grid.js +12 -7
  96. package/dist/components/Grid/GridItem.js +17 -7
  97. package/dist/components/Grid/grid-item-styles.js +58 -0
  98. package/dist/components/HoverCard/HoverCard.js +46 -43
  99. package/dist/components/Icon/Icon.js +1 -0
  100. package/dist/components/Image/Image.js +10 -7
  101. package/dist/components/Image/ImagePreview.js +42 -34
  102. package/dist/components/InlineCompletion/InlineCompletion.js +15 -11
  103. package/dist/components/InlineEdit/InlineEdit.js +8 -6
  104. package/dist/components/Input/InputCore.js +1 -0
  105. package/dist/components/JsonView/JsonView.js +104 -79
  106. package/dist/components/Kbd/Kbd.js +1 -0
  107. package/dist/components/List/List.js +1 -0
  108. package/dist/components/List/ListItem.js +1 -0
  109. package/dist/components/LocaleProvider/LocaleProvider.js +4 -4
  110. package/dist/components/LocaleProvider/ar-sa.js +24 -2
  111. package/dist/components/LocaleProvider/de-de.js +24 -2
  112. package/dist/components/LocaleProvider/es-es.js +24 -2
  113. package/dist/components/LocaleProvider/fr-fr.js +24 -2
  114. package/dist/components/LocaleProvider/it-it.js +24 -2
  115. package/dist/components/LocaleProvider/ja-jp.js +24 -2
  116. package/dist/components/LocaleProvider/ko-kr.js +24 -2
  117. package/dist/components/LocaleProvider/locale.js +24 -2
  118. package/dist/components/LocaleProvider/pt-br.js +24 -2
  119. package/dist/components/LocaleProvider/ru-ru.js +24 -2
  120. package/dist/components/LocaleProvider/zh-cn.js +24 -2
  121. package/dist/components/LogViewer/LogViewer.js +25 -14
  122. package/dist/components/MarkdownRenderer/MarkdownRenderer.js +6 -5
  123. package/dist/components/MarkdownRenderer/markdown-blocks.js +1 -1
  124. package/dist/components/Masonry/Masonry.js +13 -10
  125. package/dist/components/Mentions/MentionsCore.js +15 -11
  126. package/dist/components/Menu/Menu.js +58 -36
  127. package/dist/components/Menu/MenuCheckboxItem.js +63 -0
  128. package/dist/components/Menu/MenuDivider.js +1 -0
  129. package/dist/components/Menu/MenuGroup.js +26 -0
  130. package/dist/components/Menu/MenuItem.js +28 -9
  131. package/dist/components/Menu/MenuRadioGroup.js +30 -0
  132. package/dist/components/Menu/MenuRadioItem.js +59 -0
  133. package/dist/components/Menu/MenuSub.js +1 -0
  134. package/dist/components/Menu/MenuSubTrigger.js +1 -0
  135. package/dist/components/Menu/index.js +11 -7
  136. package/dist/components/Menu/menu-item-styles.js +7 -0
  137. package/dist/components/ModelPicker/ModelPicker.js +3 -0
  138. package/dist/components/NavigationBar/NavLink.js +7 -6
  139. package/dist/components/NavigationBar/NavigationBar.js +4 -0
  140. package/dist/components/NumberInput/NumberInputCore.js +4 -0
  141. package/dist/components/OTPInput/OTPInputCore.js +9 -7
  142. package/dist/components/Pagination/Pagination.js +125 -33
  143. package/dist/components/PasswordInput/PasswordInputCore.js +9 -6
  144. package/dist/components/Popover/Popover.js +9 -7
  145. package/dist/components/Progress/Progress.js +5 -0
  146. package/dist/components/PromptInput/PromptInput.js +49 -41
  147. package/dist/components/QRCode/QRCode.js +9 -7
  148. package/dist/components/Radio/Radio.js +2 -0
  149. package/dist/components/Radio/RadioGroupCore.js +7 -6
  150. package/dist/components/Rating/RatingCore.js +18 -15
  151. package/dist/components/Resizable/Resizable.js +25 -22
  152. package/dist/components/Result/Result.js +5 -0
  153. package/dist/components/ScrollArea/ScrollArea.js +1 -0
  154. package/dist/components/Segmented/SegmentedCore.js +9 -7
  155. package/dist/components/Select/Option.js +1 -0
  156. package/dist/components/Select/OptionGroup.js +1 -0
  157. package/dist/components/Select/SelectCore.js +11 -8
  158. package/dist/components/Select/SelectFloating.js +54 -36
  159. package/dist/components/Sidebar/Sidebar.js +52 -42
  160. package/dist/components/Signature/Signature.js +101 -91
  161. package/dist/components/Skeleton/Skeleton.js +1 -0
  162. package/dist/components/Slider/SliderCore.js +149 -43
  163. package/dist/components/Sources/Sources.js +31 -21
  164. package/dist/components/Spinner/Spinner.js +1 -0
  165. package/dist/components/Stat/Stat.js +7 -0
  166. package/dist/components/StepTimeline/StepTimeline.js +6 -0
  167. package/dist/components/Stepper/Step.js +8 -1
  168. package/dist/components/Stepper/Stepper.js +7 -6
  169. package/dist/components/StreamingText/StreamingText.js +62 -29
  170. package/dist/components/SwipeAction/SwipeAction.js +11 -9
  171. package/dist/components/Switch/SwitchCore.js +9 -5
  172. package/dist/components/Table/Table.js +2 -0
  173. package/dist/components/Table/TableBody.js +1 -0
  174. package/dist/components/Table/TableCell.js +1 -0
  175. package/dist/components/Table/TableHead.js +1 -0
  176. package/dist/components/Table/TableRow.js +1 -0
  177. package/dist/components/Tabs/Tab.js +1 -0
  178. package/dist/components/Tabs/TabList.js +5 -4
  179. package/dist/components/Tabs/TabPanel.js +1 -0
  180. package/dist/components/Tabs/Tabs.js +1 -0
  181. package/dist/components/Tag/Tag.js +2 -0
  182. package/dist/components/TagGroup/SortableTagGroup.js +7 -6
  183. package/dist/components/TagGroup/TagGroup.js +1 -0
  184. package/dist/components/TagGroup/TagGroupItem.js +3 -0
  185. package/dist/components/TagInput/SortableTagInputCore.js +13 -10
  186. package/dist/components/TagInput/TagInputCore.js +17 -12
  187. package/dist/components/Textarea/TextareaCore.js +1 -0
  188. package/dist/components/ThinkingIndicator/ThinkingIndicator.js +18 -4
  189. package/dist/components/TimePicker/TimePicker.js +30 -14
  190. package/dist/components/TimePicker/TimePickerCore.js +1 -0
  191. package/dist/components/TimePicker/TimePickerPanel.js +260 -0
  192. package/dist/components/TimePicker/time-picker-styles.js +7 -0
  193. package/dist/components/TimePicker/time.js +51 -0
  194. package/dist/components/Timeline/Timeline.js +14 -1
  195. package/dist/components/Toast/Toast.js +94 -48
  196. package/dist/components/Toast/ToastContainer.js +60 -56
  197. package/dist/components/Toast/ToastContext.js +3 -1
  198. package/dist/components/Toast/toast2.js +20 -14
  199. package/dist/components/Toast/useToast.js +36 -11
  200. package/dist/components/Toggle/ToggleCore.js +1 -0
  201. package/dist/components/TokenCounter/TokenCounter.js +8 -1
  202. package/dist/components/ToolCallCard/ToolCallCard.js +18 -2
  203. package/dist/components/Toolbar/Toolbar.js +9 -8
  204. package/dist/components/Toolbar/ToolbarButton.js +1 -0
  205. package/dist/components/Toolbar/ToolbarSeparator.js +1 -0
  206. package/dist/components/Toolbar/ToolbarToggle.js +1 -0
  207. package/dist/components/Tooltip/Tooltip.js +46 -42
  208. package/dist/components/Tour/Tour.js +76 -65
  209. package/dist/components/Transfer/TransferCore.js +31 -17
  210. package/dist/components/Tree/SortableTree.js +151 -0
  211. package/dist/components/Tree/Tree.js +163 -154
  212. package/dist/components/Tree/TreeItem.js +52 -39
  213. package/dist/components/Tree/index.js +2 -1
  214. package/dist/components/Tree/sortable-tree-styles.js +7 -0
  215. package/dist/components/Tree/sortable-tree-utils.js +36 -0
  216. package/dist/components/TreeSelect/TreeSelect.js +44 -34
  217. package/dist/components/Typography/Typography.js +3 -0
  218. package/dist/components/Upload/Upload.js +12 -11
  219. package/dist/components/Upload/UploadCore.js +92 -65
  220. package/dist/components/Upload/UploadList.js +177 -105
  221. package/dist/components/VirtualList/VirtualList.js +229 -124
  222. package/dist/components/Watermark/Watermark.js +8 -6
  223. package/dist/css/accordion.css +1 -1
  224. package/dist/css/alert.css +1 -1
  225. package/dist/css/async-section.css +1 -1
  226. package/dist/css/banner.css +1 -1
  227. package/dist/css/bottom-sheet.css +1 -1
  228. package/dist/css/button.css +2 -2
  229. package/dist/css/calendar.css +1 -1
  230. package/dist/css/carousel.css +1 -1
  231. package/dist/css/chat-message.css +1 -1
  232. package/dist/css/checkbox.css +1 -1
  233. package/dist/css/color-picker.css +2 -0
  234. package/dist/css/combobox.css +2 -2
  235. package/dist/css/context-menu.css +1 -1
  236. package/dist/css/dialog.css +1 -1
  237. package/dist/css/drawer.css +1 -1
  238. package/dist/css/dropdown-menu.css +7 -2
  239. package/dist/css/form.css +1 -1
  240. package/dist/css/grid.css +2 -1
  241. package/dist/css/hover-card.css +1 -1
  242. package/dist/css/input.css +1 -1
  243. package/dist/css/menu.css +9 -4
  244. package/dist/css/pagination.css +1 -1
  245. package/dist/css/popover.css +1 -1
  246. package/dist/css/progress.css +1 -1
  247. package/dist/css/radio.css +1 -1
  248. package/dist/css/rating.css +1 -1
  249. package/dist/css/segmented.css +1 -1
  250. package/dist/css/skeleton.css +1 -1
  251. package/dist/css/slider.css +1 -1
  252. package/dist/css/spinner.css +1 -1
  253. package/dist/css/stepper.css +1 -1
  254. package/dist/css/streaming-text.css +1 -1
  255. package/dist/css/switch.css +1 -1
  256. package/dist/css/tabs.css +1 -1
  257. package/dist/css/textarea.css +1 -1
  258. package/dist/css/thinking-indicator.css +1 -1
  259. package/dist/css/time-picker.css +1 -0
  260. package/dist/css/toast.css +1 -1
  261. package/dist/css/toggle.css +1 -1
  262. package/dist/css/tokens.css +1 -1
  263. package/dist/css/tooltip.css +1 -1
  264. package/dist/css/tree.css +2 -1
  265. package/dist/css/upload.css +1 -1
  266. package/dist/css/virtual-list.css +1 -1
  267. package/dist/css-manifest.json +22 -0
  268. package/dist/dates/adapter.js +13 -0
  269. package/dist/dates/gregory.js +44 -0
  270. package/dist/dates/islamic.js +87 -0
  271. package/dist/dates/registry.js +13 -0
  272. package/dist/dates/timezone.js +29 -0
  273. package/dist/design-tokens/cyan-dark.json +355 -0
  274. package/dist/design-tokens/cyan-light.json +355 -0
  275. package/dist/design-tokens/orange-dark.json +355 -0
  276. package/dist/design-tokens/orange-light.json +355 -0
  277. package/dist/design-tokens/rose-dark.json +355 -0
  278. package/dist/design-tokens/rose-light.json +355 -0
  279. package/dist/design-tokens/teal-dark.json +355 -0
  280. package/dist/design-tokens/teal-light.json +355 -0
  281. package/dist/design-tokens/violet-dark.json +355 -0
  282. package/dist/design-tokens/violet-light.json +355 -0
  283. package/dist/form/FormItem.js +71 -63
  284. package/dist/form/FormList.js +6 -6
  285. package/dist/form/form-item-styles.js +7 -0
  286. package/dist/haze-ui.css +63 -48
  287. package/dist/index.js +249 -232
  288. package/dist/mcp-docs.json +1011 -82
  289. package/dist/registry.json +17 -17
  290. package/dist/tokens/index.js +7 -7
  291. package/dist/tokens/motion.js +9 -2
  292. package/dist/tokens/palette.js +244 -84
  293. package/dist/tokens/registry.js +18 -22
  294. package/dist/types/components/Button/Button.d.ts +1 -1
  295. package/dist/types/components/Calendar/Calendar.d.ts +39 -14
  296. package/dist/types/components/Calendar/date.d.ts +51 -0
  297. package/dist/types/components/Calendar/index.d.ts +1 -1
  298. package/dist/types/components/Carousel/Carousel.d.ts +5 -1
  299. package/dist/types/components/Carousel/CarouselSlide.d.ts +3 -3
  300. package/dist/types/components/Chart/Chart.d.ts +13 -6
  301. package/dist/types/components/Chart/chart-elements.d.ts +27 -6
  302. package/dist/types/components/ChatMessage/ChatMessage.d.ts +10 -1
  303. package/dist/types/components/ColorPicker/ColorPicker.d.ts +44 -5
  304. package/dist/types/components/ColorPicker/ColorPickerPanel.d.ts +28 -0
  305. package/dist/types/components/ColorPicker/color-math.d.ts +63 -0
  306. package/dist/types/components/ColorPicker/color-picker-styles.d.ts +50 -0
  307. package/dist/types/components/ConfigProvider/ConfigContext.d.ts +67 -0
  308. package/dist/types/components/ConfigProvider/ConfigProvider.d.ts +25 -0
  309. package/dist/types/components/ConfigProvider/index.d.ts +4 -0
  310. package/dist/types/components/ConfigProvider/useConfigDefaults.d.ts +28 -0
  311. package/dist/types/components/Datepicker/Datepicker.d.ts +23 -10
  312. package/dist/types/components/Datepicker/DatepickerCore.d.ts +40 -10
  313. package/dist/types/components/Datepicker/datetime.d.ts +33 -11
  314. package/dist/types/components/DropdownMenu/DropdownMenu.d.ts +12 -2
  315. package/dist/types/components/DropdownMenu/DropdownMenuCheckboxItem.d.ts +26 -0
  316. package/dist/types/components/DropdownMenu/DropdownMenuGroup.d.ts +16 -0
  317. package/dist/types/components/DropdownMenu/DropdownMenuItem.d.ts +7 -1
  318. package/dist/types/components/DropdownMenu/DropdownMenuRadioGroup.d.ts +21 -0
  319. package/dist/types/components/DropdownMenu/DropdownMenuRadioItem.d.ts +22 -0
  320. package/dist/types/components/DropdownMenu/dropdown-menu-item-styles.d.ts +29 -0
  321. package/dist/types/components/DropdownMenu/index.d.ts +9 -1
  322. package/dist/types/components/Fullscreen/Fullscreen.d.ts +1 -0
  323. package/dist/types/components/Grid/Grid.d.ts +8 -1
  324. package/dist/types/components/Grid/GridItem.d.ts +24 -1
  325. package/dist/types/components/Grid/grid-item-styles.d.ts +57 -0
  326. package/dist/types/components/HoverCard/HoverCard.d.ts +1 -1
  327. package/dist/types/components/LocaleProvider/locale.d.ts +24 -0
  328. package/dist/types/components/Menu/Menu.d.ts +11 -2
  329. package/dist/types/components/Menu/MenuCheckboxItem.d.ts +25 -0
  330. package/dist/types/components/Menu/MenuGroup.d.ts +16 -0
  331. package/dist/types/components/Menu/MenuItem.d.ts +7 -1
  332. package/dist/types/components/Menu/MenuRadioGroup.d.ts +20 -0
  333. package/dist/types/components/Menu/MenuRadioItem.d.ts +22 -0
  334. package/dist/types/components/Menu/index.d.ts +9 -1
  335. package/dist/types/components/Menu/menu-item-styles.d.ts +28 -0
  336. package/dist/types/components/NavigationBar/NavLink.d.ts +1 -1
  337. package/dist/types/components/Pagination/Pagination.d.ts +17 -3
  338. package/dist/types/components/Sidebar/Sidebar.d.ts +1 -1
  339. package/dist/types/components/Slider/Slider.d.ts +24 -2
  340. package/dist/types/components/Slider/SliderCore.d.ts +41 -3
  341. package/dist/types/components/StreamingText/StreamingText.d.ts +8 -1
  342. package/dist/types/components/TimePicker/TimePicker.d.ts +36 -4
  343. package/dist/types/components/TimePicker/TimePickerPanel.d.ts +26 -0
  344. package/dist/types/components/TimePicker/index.d.ts +1 -0
  345. package/dist/types/components/TimePicker/time-picker-styles.d.ts +30 -0
  346. package/dist/types/components/TimePicker/time.d.ts +49 -0
  347. package/dist/types/components/Toast/Toast.d.ts +19 -6
  348. package/dist/types/components/Toast/ToastContainer.d.ts +1 -1
  349. package/dist/types/components/Toast/ToastContext.d.ts +22 -2
  350. package/dist/types/components/Toast/index.d.ts +1 -1
  351. package/dist/types/components/Toast/toast.d.ts +20 -14
  352. package/dist/types/components/Toast/useToast.d.ts +14 -4
  353. package/dist/types/components/Tooltip/Tooltip.d.ts +1 -1
  354. package/dist/types/components/Tree/SortableTree.d.ts +38 -0
  355. package/dist/types/components/Tree/Tree.d.ts +1 -1
  356. package/dist/types/components/Tree/index.d.ts +2 -0
  357. package/dist/types/components/Tree/sortable-tree-styles.d.ts +36 -0
  358. package/dist/types/components/Tree/sortable-tree-utils.d.ts +40 -0
  359. package/dist/types/components/Upload/Upload.d.ts +17 -10
  360. package/dist/types/components/Upload/UploadCore.d.ts +26 -12
  361. package/dist/types/components/Upload/UploadList.d.ts +10 -7
  362. package/dist/types/components/Upload/index.d.ts +1 -1
  363. package/dist/types/components/Upload/types.d.ts +33 -7
  364. package/dist/types/components/VirtualList/VirtualList.d.ts +79 -26
  365. package/dist/types/components/VirtualList/index.d.ts +1 -1
  366. package/dist/types/dates/adapter.d.ts +74 -0
  367. package/dist/types/dates/gregory.d.ts +10 -0
  368. package/dist/types/dates/index.d.ts +6 -0
  369. package/dist/types/dates/islamic.d.ts +17 -0
  370. package/dist/types/dates/registry.d.ts +13 -0
  371. package/dist/types/dates/timezone.d.ts +36 -0
  372. package/dist/types/form/FormItem.d.ts +31 -1
  373. package/dist/types/form/form-item-styles.d.ts +24 -0
  374. package/dist/types/index.d.ts +19 -11
  375. package/dist/types/tokens/index.d.ts +4 -2
  376. package/dist/types/tokens/motion.d.ts +16 -0
  377. package/dist/types/tokens/palette.d.ts +59 -2
  378. package/dist/types/utils/menuItems.d.ts +126 -0
  379. package/dist/types/utils/menuRadio.d.ts +21 -0
  380. package/dist/utils/floating.js +45 -44
  381. package/dist/utils/menuItems.js +55 -0
  382. package/dist/utils/menuKeyboard.js +31 -31
  383. package/dist/utils/menuRadio.js +28 -0
  384. package/dist/utils/sortable-shared.js +3 -3
  385. package/dist/utils/sortable.js +12 -11
  386. package/package.json +18 -9
@@ -56,6 +56,57 @@ var i = {
56
56
  red: { 8: "#ef4444" }
57
57
  }
58
58
  }, c = {
59
+ violet: {
60
+ light: {
61
+ 9: "#7c3aed",
62
+ 10: "#6d28d9"
63
+ },
64
+ dark: {
65
+ 8: "#9b76fa",
66
+ 9: "#a78bfa"
67
+ }
68
+ },
69
+ teal: {
70
+ light: {
71
+ 9: "#0f766e",
72
+ 10: "#134e4a"
73
+ },
74
+ dark: {
75
+ 8: "#14b8a6",
76
+ 9: "#2dd4bf"
77
+ }
78
+ },
79
+ cyan: {
80
+ light: {
81
+ 9: "#0e7490",
82
+ 10: "#155e75"
83
+ },
84
+ dark: {
85
+ 8: "#06b6d4",
86
+ 9: "#22d3ee"
87
+ }
88
+ },
89
+ orange: {
90
+ light: {
91
+ 9: "#c2410c",
92
+ 10: "#9a3412"
93
+ },
94
+ dark: {
95
+ 8: "#f97316",
96
+ 9: "#fb923c"
97
+ }
98
+ },
99
+ rose: {
100
+ light: {
101
+ 9: "#dd1645",
102
+ 10: "#be123c"
103
+ },
104
+ dark: {
105
+ 8: "#f43f5e",
106
+ 9: "#fb7185"
107
+ }
108
+ }
109
+ }, l = {
59
110
  light: {
60
111
  l1: .982,
61
112
  l12: .16,
@@ -69,7 +120,7 @@ var i = {
69
120
  c12: .012
70
121
  }
71
122
  };
72
- function l(e, t) {
123
+ function u(e, t) {
73
124
  let n = e[0];
74
125
  if (t <= n.x) return n.y;
75
126
  for (let n = 1; n < e.length; n++) {
@@ -81,7 +132,7 @@ function l(e, t) {
81
132
  }
82
133
  return e[e.length - 1].y;
83
134
  }
84
- function u(e, t, r) {
135
+ function d(e, t, r) {
85
136
  return Object.entries(e).map(([e, i]) => {
86
137
  let a = n(i), s = r && Number(e) === 9 ? a.l + o[t] : a.l;
87
138
  return {
@@ -94,92 +145,95 @@ function u(e, t, r) {
94
145
  };
95
146
  }).sort((e, t) => e.step - t.step);
96
147
  }
97
- function d(n, r, i) {
148
+ function f(n, r, i) {
98
149
  let a = [];
99
150
  for (let o = 1; o <= 12; o++) a.push(t(e({
100
- l: l(n, o),
151
+ l: u(n, o),
101
152
  c: r(o),
102
153
  h: i(o)
103
154
  })));
104
155
  return a;
105
156
  }
106
- function f(e, t) {
107
- return d(u(e, t, !0).map((e) => ({
157
+ function p(e, t) {
158
+ return f(d(e, t, !0).map((e) => ({
108
159
  x: e.step,
109
160
  y: e.color.l
110
161
  })), () => 0, () => 0);
111
162
  }
112
- function p(e, t) {
113
- let n = u(e, t, !1), r = c[t], i = [
163
+ function m(e, t) {
164
+ return h(d(e, t, !1), t);
165
+ }
166
+ function h(e, t) {
167
+ let n = l[t], r = [
114
168
  {
115
169
  x: 1,
116
- y: r.l1
170
+ y: n.l1
117
171
  },
118
- ...n.map((e) => ({
172
+ ...e.map((e) => ({
119
173
  x: e.step,
120
174
  y: e.color.l
121
175
  })),
122
176
  {
123
177
  x: 12,
124
- y: r.l12
178
+ y: n.l12
125
179
  }
126
- ], a = [
180
+ ], i = [
127
181
  {
128
182
  x: 1,
129
- y: r.c1
183
+ y: n.c1
130
184
  },
131
- ...n.map((e) => ({
185
+ ...e.map((e) => ({
132
186
  x: e.step,
133
187
  y: e.color.c
134
188
  })),
135
189
  {
136
190
  x: 12,
137
- y: r.c12
191
+ y: n.c12
138
192
  }
139
- ], o = [
193
+ ], a = [
140
194
  {
141
195
  x: 1,
142
- y: n[0].color.h
196
+ y: e[0].color.h
143
197
  },
144
- ...n.map((e) => ({
198
+ ...e.map((e) => ({
145
199
  x: e.step,
146
200
  y: e.color.h
147
201
  })),
148
202
  {
149
203
  x: 12,
150
- y: n[n.length - 1].color.h
204
+ y: e[e.length - 1].color.h
151
205
  }
152
206
  ];
153
- return d(i, (e) => l(a, e), (e) => l(o, e));
207
+ return f(r, (e) => u(i, e), (e) => u(a, e));
154
208
  }
155
- var m = {
209
+ var g = {
156
210
  light: {
157
- gray: f(s.light.gray, "light"),
158
- blue: p(s.light.blue, "light"),
159
- green: p(s.light.green, "light"),
160
- amber: p(s.light.amber, "light"),
161
- red: p(s.light.red, "light")
211
+ gray: p(s.light.gray, "light"),
212
+ blue: m(s.light.blue, "light"),
213
+ green: m(s.light.green, "light"),
214
+ amber: m(s.light.amber, "light"),
215
+ red: m(s.light.red, "light")
162
216
  },
163
217
  dark: {
164
- gray: f(s.dark.gray, "dark"),
165
- blue: p(s.dark.blue, "dark"),
166
- green: p(s.dark.green, "dark"),
167
- amber: p(s.dark.amber, "dark"),
168
- red: p(s.dark.red, "dark")
218
+ gray: p(s.dark.gray, "dark"),
219
+ blue: m(s.dark.blue, "dark"),
220
+ green: m(s.dark.green, "dark"),
221
+ amber: m(s.dark.amber, "dark"),
222
+ red: m(s.dark.red, "dark")
169
223
  }
170
224
  };
171
- function h(e, t, n, r) {
225
+ function _(e, t, n, r) {
172
226
  let i = e[t][n]?.[r - 1];
173
227
  if (i === void 0) throw Error(`Missing primitive ${n}-${r} in ${t} mode`);
174
228
  return i;
175
229
  }
176
- var g = {
230
+ var v = {
177
231
  primary: "blue",
178
232
  success: "green",
179
233
  warning: "amber",
180
234
  danger: "red",
181
235
  info: "blue"
182
- }, _ = {
236
+ }, y = {
183
237
  light: {
184
238
  primary: 9,
185
239
  success: 9,
@@ -194,7 +248,7 @@ var g = {
194
248
  danger: 8,
195
249
  info: 8
196
250
  }
197
- }, v = {
251
+ }, b = {
198
252
  bg: 1,
199
253
  "bg-subtle": 2,
200
254
  "bg-muted": 3,
@@ -202,18 +256,18 @@ var g = {
202
256
  "text-secondary": 11,
203
257
  "text-muted": 9,
204
258
  border: 4
205
- }, y = (e, t) => `var(--haze-${e}-${t})`, b = (e) => `calc(l ${e < 0 ? "-" : "+"} ${Math.abs(e)})`;
206
- function x(e, t, n) {
259
+ }, x = (e, t) => `var(--haze-${e}-${t})`, S = (e) => `calc(l ${e < 0 ? "-" : "+"} ${Math.abs(e)})`;
260
+ function C(e, t, n) {
207
261
  let r = i[e];
208
262
  switch (n) {
209
- case "hover": return `oklch(from ${t} ${b(r.hover)} c h)`;
210
- case "active": return `oklch(from ${t} ${b(r.active)} c h)`;
263
+ case "hover": return `oklch(from ${t} ${S(r.hover)} c h)`;
264
+ case "active": return `oklch(from ${t} ${S(r.active)} c h)`;
211
265
  case "subtle": return `oklch(from ${t} ${r.subtleL} calc(c * ${r.subtleC}) h)`;
212
- case "border-hover": return `oklch(from ${t} ${b(r.borderHover)} c h)`;
266
+ case "border-hover": return `oklch(from ${t} ${S(r.borderHover)} c h)`;
213
267
  case "focus-ring": return `oklch(from ${t} l c h / ${a})`;
214
268
  }
215
269
  }
216
- function S(t, n, r) {
270
+ function w(t, n, r) {
217
271
  let o = i[t];
218
272
  switch (r) {
219
273
  case "hover": return e({
@@ -244,59 +298,59 @@ function S(t, n, r) {
244
298
  };
245
299
  }
246
300
  }
247
- function C(e, t, n, i, a) {
301
+ function T(e, t, n, i, a) {
248
302
  return {
249
303
  name: t,
250
304
  label: n,
251
305
  css: {
252
- light: y(i, a.light),
253
- dark: y(i, a.dark)
306
+ light: x(i, a.light),
307
+ dark: x(i, a.dark)
254
308
  },
255
309
  resolved: {
256
- light: r(h(e.scales, "light", i, a.light)),
257
- dark: r(h(e.scales, "dark", i, a.dark))
310
+ light: r(_(e.scales, "light", i, a.light)),
311
+ dark: r(_(e.scales, "dark", i, a.dark))
258
312
  }
259
313
  };
260
314
  }
261
- function w(e, t, n, r, i) {
315
+ function E(e, t, n, r, i) {
262
316
  let a = `var(${n})`;
263
317
  return {
264
318
  name: e,
265
319
  label: t,
266
320
  css: {
267
- light: x("light", a, i),
268
- dark: x("dark", a, i)
321
+ light: C("light", a, i),
322
+ dark: C("dark", a, i)
269
323
  },
270
324
  resolved: {
271
- light: S("light", r.light, i),
272
- dark: S("dark", r.dark, i)
325
+ light: w("light", r.light, i),
326
+ dark: w("dark", r.dark, i)
273
327
  }
274
328
  };
275
329
  }
276
- function T(e, t) {
277
- let n = C(e, `--haze-color-${t}`, t[0].toUpperCase() + t.slice(1), e.statusFamily[t], {
278
- light: _.light[t],
279
- dark: _.dark[t]
330
+ function D(e, t) {
331
+ let n = T(e, `--haze-color-${t}`, t[0].toUpperCase() + t.slice(1), e.statusFamily[t], {
332
+ light: y.light[t],
333
+ dark: y.dark[t]
280
334
  });
281
335
  return [
282
336
  n,
283
- w(`${n.name}-hover`, `${n.label} Hover`, n.name, n.resolved, "hover"),
284
- w(`${n.name}-active`, `${n.label} Active`, n.name, n.resolved, "active"),
285
- w(`${n.name}-subtle`, `${n.label} Subtle`, n.name, n.resolved, "subtle")
337
+ E(`${n.name}-hover`, `${n.label} Hover`, n.name, n.resolved, "hover"),
338
+ E(`${n.name}-active`, `${n.label} Active`, n.name, n.resolved, "active"),
339
+ E(`${n.name}-subtle`, `${n.label} Subtle`, n.name, n.resolved, "subtle")
286
340
  ];
287
341
  }
288
- function E(e, t, n) {
289
- return C(e, `--haze-color-${t}`, n, "gray", {
290
- light: v[t],
291
- dark: v[t]
342
+ function O(e, t, n) {
343
+ return T(e, `--haze-color-${t}`, n, "gray", {
344
+ light: b[t],
345
+ dark: b[t]
292
346
  });
293
347
  }
294
- var D = (e) => ({
348
+ var k = (e) => ({
295
349
  name: "--haze-color-text-inverse",
296
350
  label: "Text Inverse",
297
351
  css: {
298
352
  light: "oklch(1 0 0)",
299
- dark: h(e.scales, "light", "gray", 12)
353
+ dark: _(e.scales, "light", "gray", 12)
300
354
  },
301
355
  resolved: {
302
356
  light: {
@@ -304,32 +358,138 @@ var D = (e) => ({
304
358
  c: 0,
305
359
  h: 0
306
360
  },
307
- dark: r(h(e.scales, "light", "gray", 12))
361
+ dark: r(_(e.scales, "light", "gray", 12))
308
362
  }
309
363
  });
310
- function O(e) {
311
- let t = T(e, "primary"), n = t[0], r = E(e, "border", "Border");
364
+ function A(e) {
365
+ let t = D(e, "primary"), n = t[0], r = O(e, "border", "Border");
312
366
  return [
313
367
  ...t,
314
- E(e, "bg", "Background"),
315
- E(e, "bg-subtle", "Background Subtle"),
316
- E(e, "bg-muted", "Background Muted"),
317
- E(e, "text", "Text"),
318
- E(e, "text-secondary", "Text Secondary"),
319
- E(e, "text-muted", "Text Muted"),
320
- D(e),
368
+ O(e, "bg", "Background"),
369
+ O(e, "bg-subtle", "Background Subtle"),
370
+ O(e, "bg-muted", "Background Muted"),
371
+ O(e, "text", "Text"),
372
+ O(e, "text-secondary", "Text Secondary"),
373
+ O(e, "text-muted", "Text Muted"),
374
+ k(e),
321
375
  r,
322
- w("--haze-color-border-hover", "Border Hover", r.name, r.resolved, "border-hover"),
323
- ...T(e, "success"),
324
- ...T(e, "warning"),
325
- ...T(e, "danger"),
326
- ...T(e, "info"),
327
- w("--haze-color-focus-ring", "Focus Ring", n.name, n.resolved, "focus-ring")
376
+ E("--haze-color-border-hover", "Border Hover", r.name, r.resolved, "border-hover"),
377
+ ...D(e, "success"),
378
+ ...D(e, "warning"),
379
+ ...D(e, "danger"),
380
+ ...D(e, "info"),
381
+ E("--haze-color-focus-ring", "Focus Ring", n.name, n.resolved, "focus-ring")
328
382
  ];
329
383
  }
330
- var k = O({
331
- scales: m,
332
- statusFamily: g
384
+ var j = A({
385
+ scales: g,
386
+ statusFamily: v
387
+ }), M = [
388
+ "violet",
389
+ "teal",
390
+ "cyan",
391
+ "orange",
392
+ "rose"
393
+ ];
394
+ function N(e) {
395
+ let t = (t) => Object.fromEntries([
396
+ ["gray", g[t].gray],
397
+ [e, m(c[e][t], t)],
398
+ ["green", g[t].green],
399
+ ["amber", g[t].amber],
400
+ ["red", g[t].red]
401
+ ]);
402
+ return {
403
+ light: t("light"),
404
+ dark: t("dark")
405
+ };
406
+ }
407
+ function P(e) {
408
+ let t = N(e), n = A({
409
+ scales: t,
410
+ statusFamily: {
411
+ ...v,
412
+ primary: e,
413
+ info: e
414
+ }
415
+ });
416
+ return {
417
+ family: e,
418
+ primitives: t,
419
+ semanticTokens: n,
420
+ declarations: {
421
+ light: F("light", t, n),
422
+ dark: F("dark", t, n)
423
+ }
424
+ };
425
+ }
426
+ function F(e, t, n) {
427
+ return `${Object.entries(t[e]).flatMap(([e, t]) => t.map((t, n) => `--haze-${e}-${n + 1}: ${t};`)).join("\n")}\n\n${n.map((t) => `${t.name}: ${t.css[e]};`).join("\n")}`;
428
+ }
429
+ var I = /* @__PURE__ */ new Set([
430
+ "gray",
431
+ "green",
432
+ "amber",
433
+ "red"
434
+ ]), L = /^[a-z][a-z0-9-]*$/, R = {
435
+ infoStep: -.07,
436
+ darkPrimary: .2
437
+ }, z = (e) => Math.min(1, Math.max(0, e)), B = (t, n) => e({
438
+ l: z(t.l + n),
439
+ c: t.c,
440
+ h: t.h
333
441
  });
442
+ function V(e, t) {
443
+ let r = new Map(e.map((e) => [e.step, e.color]));
444
+ for (let [e, i] of Object.entries(t ?? {})) {
445
+ if (Number(e) < 1 || Number(e) > 12) throw Error(`Seed anchor step ${e} is outside the 1–12 scale`);
446
+ r.set(Number(e), n(i));
447
+ }
448
+ return [...r.entries()].map(([e, t]) => ({
449
+ step: e,
450
+ color: t
451
+ })).sort((e, t) => e.step - t.step);
452
+ }
453
+ function H({ name: e, light: t, dark: r, overrides: i }) {
454
+ if (!L.test(e)) throw Error(`Invalid brand name "${e}" — use a lowercase kebab identifier (letters, digits, hyphens)`);
455
+ if (I.has(e)) throw Error(`Brand name "${e}" collides with a fixed neutral family (gray/green/amber/red)`);
456
+ let a = n(t), o = r === void 0 ? B(a, R.darkPrimary) : n(r), s = {
457
+ light: V([{
458
+ step: 9,
459
+ color: a
460
+ }, {
461
+ step: 10,
462
+ color: B(a, R.infoStep)
463
+ }], i?.light),
464
+ dark: V([{
465
+ step: 9,
466
+ color: o
467
+ }, {
468
+ step: 8,
469
+ color: B(o, R.infoStep)
470
+ }], i?.dark)
471
+ }, c = (t) => Object.fromEntries([
472
+ ["gray", g[t].gray],
473
+ [e, h(s[t], t)],
474
+ ["green", g[t].green],
475
+ ["amber", g[t].amber],
476
+ ["red", g[t].red]
477
+ ]), l = {
478
+ light: c("light"),
479
+ dark: c("dark")
480
+ }, u = A({
481
+ scales: l,
482
+ statusFamily: {
483
+ ...v,
484
+ primary: e,
485
+ info: e
486
+ }
487
+ });
488
+ return {
489
+ name: e,
490
+ light: F("light", l, u),
491
+ dark: F("dark", l, u)
492
+ };
493
+ }
334
494
  //#endregion
335
- export { m as PRIMITIVES, k as SEMANTIC_COLOR_TOKENS };
495
+ export { M as BRAND_FAMILIES, c as BRAND_SEEDS, g as PRIMITIVES, j as SEMANTIC_COLOR_TOKENS, P as buildBrandTheme, H as createBrandTheme, F as themeDeclarations };
@@ -747,10 +747,25 @@ var n = [
747
747
  slider: [
748
748
  "--haze-color-bg",
749
749
  "--haze-color-bg-muted",
750
- "--haze-color-primary",
751
750
  "--haze-color-focus-ring",
751
+ "--haze-color-primary",
752
+ "--haze-color-text",
753
+ "--haze-color-text-inverse",
754
+ "--haze-color-text-muted",
755
+ "--haze-color-text-secondary",
756
+ "--haze-duration-fast",
757
+ "--haze-ease",
758
+ "--haze-font-sans",
759
+ "--haze-leading-normal",
752
760
  "--haze-radius-full",
753
- "--haze-shadow-sm"
761
+ "--haze-radius-md",
762
+ "--haze-shadow-sm",
763
+ "--haze-space-1",
764
+ "--haze-space-12",
765
+ "--haze-space-16",
766
+ "--haze-space-2",
767
+ "--haze-space-6",
768
+ "--haze-text-xs"
754
769
  ],
755
770
  steptimeline: [
756
771
  "--haze-color-bg",
@@ -842,26 +857,7 @@ var n = [
842
857
  "--haze-text-sm",
843
858
  "--haze-text-base"
844
859
  ],
845
- toast: [
846
- "--haze-color-bg",
847
- "--haze-color-border",
848
- "--haze-color-text",
849
- "--haze-color-success",
850
- "--haze-color-success-subtle",
851
- "--haze-color-warning",
852
- "--haze-color-warning-subtle",
853
- "--haze-color-danger",
854
- "--haze-color-danger-subtle",
855
- "--haze-font-sans",
856
- "--haze-leading-normal",
857
- "--haze-radius-md",
858
- "--haze-shadow-lg",
859
- "--haze-space-2",
860
- "--haze-space-3",
861
- "--haze-space-4",
862
- "--haze-text-sm",
863
- "--haze-text-lg"
864
- ],
860
+ toast: /* @__PURE__ */ "--haze-color-bg.--haze-color-border.--haze-color-danger.--haze-color-danger-subtle.--haze-color-focus-ring.--haze-color-primary.--haze-color-primary-active.--haze-color-primary-hover.--haze-color-success.--haze-color-success-subtle.--haze-color-text.--haze-color-text-secondary.--haze-color-warning.--haze-color-warning-subtle.--haze-font-sans.--haze-leading-normal.--haze-radius-md.--haze-shadow-lg.--haze-space-1.--haze-space-2.--haze-space-3.--haze-space-4.--haze-text-base.--haze-text-lg.--haze-text-sm.--haze-weight-medium".split("."),
865
861
  tooltip: [
866
862
  "--haze-color-text",
867
863
  "--haze-color-text-inverse",
@@ -11,5 +11,5 @@ type ButtonProps = {
11
11
  size?: 'sm' | 'md' | 'lg';
12
12
  square?: boolean;
13
13
  } & Omit<ComponentPropsWithoutRef<'button'>, 'type'>;
14
- export default function Button({ variant, size, square, className, ...rest }: ButtonProps): import("react").JSX.Element;
14
+ export default function Button({ variant, size: sizeProp, square, className, ...rest }: ButtonProps): import("react").JSX.Element;
15
15
  export type { ButtonProps };
@@ -1,14 +1,30 @@
1
- import type { ComponentPropsWithoutRef } from 'react';
1
+ import type { ComponentPropsWithoutRef, ReactNode } from 'react';
2
2
  import type { ControlOrValue } from 'react-use-control';
3
3
  /** Granularity Calendar picks at. Each mode serializes its `value` and
4
- * `onSelect` payload to a plain string: `"YYYY-MM-DD"` (date),
5
- * `"YYYY-MM"` (month), `"YYYY-Qn"` with n 1–4 (quarter) or `"YYYY"`
6
- * (year). */
7
- type CalendarPickerMode = 'date' | 'month' | 'quarter' | 'year';
4
+ * `onSelect` payload to a plain string: `"YYYY-MM-DD"` (date), an ISO
5
+ * 8601 week `"YYYY-Www"` (week), `"YYYY-MM"` (month), `"YYYY-Qn"` with
6
+ * n 1–4 (quarter) or `"YYYY"` (year). */
7
+ type CalendarPickerMode = 'date' | 'week' | 'month' | 'quarter' | 'year';
8
+ /**
9
+ * Extra render position appended inside picker cells (day numbers, month
10
+ * / quarter / year labels) — schedule dots, badges, custom chrome. Called
11
+ * with the cell's representative civil date (`day` 1 for the
12
+ * month/quarter/year cells) and the picker mode the cell renders in, so
13
+ * one callback can decorate a date grid and the header drill-down grids
14
+ * differently.
15
+ */
16
+ type CalendarCellRender = (date: {
17
+ year: number;
18
+ month: number;
19
+ day: number;
20
+ }, mode: CalendarPickerMode) => ReactNode;
8
21
  type CalendarProps = {
9
22
  /**
10
23
  * Granularity the calendar picks at. `"date"` (default) renders the
11
- * day grid; `"month"` a 3×4 month grid over one year; `"quarter"`
24
+ * day grid; `"week"` the same day grid with whole-ISO-week row
25
+ * selection (rows run Monday–Sunday, the week-number column is always
26
+ * shown and `weekStartsOn` is ignored — ISO weeks are Monday-first by
27
+ * definition); `"month"` a 3×4 month grid over one year; `"quarter"`
12
28
  * a 4-quarter grid over one year; `"year"` a 12-year grid stepped a
13
29
  * decade at a time. Values follow each mode's serialization (see
14
30
  * {@link CalendarPickerMode}); `months`, `showWeekNumbers`,
@@ -18,8 +34,9 @@ type CalendarProps = {
18
34
  picker?: CalendarPickerMode;
19
35
  /**
20
36
  * Selected value as a plain string whose format follows `picker`:
21
- * "YYYY-MM-DD" (date, the default), "YYYY-MM" (month), "YYYY-Qn"
22
- * (quarter) or "YYYY" (year). Empty string means nothing selected.
37
+ * "YYYY-MM-DD" (date, the default), an ISO week "YYYY-Www" (week),
38
+ * "YYYY-MM" (month), "YYYY-Qn" (quarter) or "YYYY" (year). Empty
39
+ * string means nothing selected.
23
40
  */
24
41
  value?: ControlOrValue<string>;
25
42
  /**
@@ -74,12 +91,20 @@ type CalendarProps = {
74
91
  */
75
92
  rangeEnd?: string;
76
93
  /**
77
- * Called with the picked value — "YYYY-MM-DD" (date), "YYYY-MM"
78
- * (month), "YYYY-Qn" (quarter) or "YYYY" (year), matching `picker`.
79
- * Still fires alongside the controllable `value` for callers that
80
- * prefer event-style wiring.
94
+ * Called with the picked value — "YYYY-MM-DD" (date), an ISO week
95
+ * "YYYY-Www" (week), "YYYY-MM" (month), "YYYY-Qn" (quarter) or "YYYY"
96
+ * (year), matching `picker`. Still fires alongside the controllable
97
+ * `value` for callers that prefer event-style wiring.
81
98
  */
82
99
  onSelect?: (date: string) => void;
100
+ /**
101
+ * Appends a custom render inside every picker cell — day numbers,
102
+ * month/quarter/year labels and the header drill-down grids alike
103
+ * (schedule dots, badges). Receives the cell's representative civil
104
+ * date (`day` 1 for month/quarter/year cells) and the mode the cell
105
+ * renders in. Opt-in: without it the cells render exactly as before.
106
+ */
107
+ cellRender?: CalendarCellRender;
83
108
  } & Omit<ComponentPropsWithoutRef<'div'>, 'onSelect'>;
84
- export default function Calendar({ picker, value: valueControl, min, max, disabledDate, locale, weekStartsOn, showWeekNumbers, months, rangeStart, rangeEnd, onSelect, className, ...rest }: CalendarProps): import("react").JSX.Element;
85
- export type { CalendarProps, CalendarPickerMode };
109
+ export default function Calendar({ picker, value: valueControl, min, max, disabledDate, locale, weekStartsOn, showWeekNumbers, months, rangeStart, rangeEnd, onSelect, cellRender, className, ...rest }: CalendarProps): import("react").JSX.Element;
110
+ export type { CalendarProps, CalendarPickerMode, CalendarCellRender };
@@ -59,6 +59,15 @@ export declare function getLeadingDays(year: number, month: number, weekStart: n
59
59
  * added. The result length is always a multiple of 7.
60
60
  */
61
61
  export declare function buildMonthCells(year: number, month: number, weekStart: number): CalendarCell[];
62
+ /** ISO 8601 week identity of a civil date: the week number together with
63
+ * the ISO week-numbering **year** it belongs to. Days at the calendar
64
+ * year's edges borrow the neighbor year's numbering, so `year` here is
65
+ * not necessarily the civil date's own year (2025-12-31 is week 1 of
66
+ * 2026; 2027-01-01 is week 53 of 2026). */
67
+ export type ISOWeek = {
68
+ year: number;
69
+ week: number;
70
+ };
62
71
  /**
63
72
  * ISO 8601 week number of a civil date. ISO weeks run Monday–Sunday and
64
73
  * week 1 is the week containing the year's first Thursday, so days at the
@@ -71,6 +80,30 @@ export declare function buildMonthCells(year: number, month: number, weekStart:
71
80
  * spans from that ISO year's January 1.
72
81
  */
73
82
  export declare function getISOWeekNumber(year: number, month: number, day: number): number;
83
+ /**
84
+ * Full ISO 8601 week identity of a civil date (`{@link getISOWeekNumber}`
85
+ * plus the ISO week-numbering year the week belongs to). Same Thursday
86
+ * anchoring: the Thursday of a date's Monday–Sunday week carries the ISO
87
+ * year, which is what `"YYYY-Www"` values (see
88
+ * {@link formatWeekValue}) number weeks against.
89
+ */
90
+ export declare function getISOWeek(year: number, month: number, day: number): ISOWeek;
91
+ /**
92
+ * Monday of an ISO week as a civil date — the anchor
93
+ * `picker="week"` derives its month view and row highlight from. January
94
+ * 4 always sits in week 1 (the first-Thursday rule), so Monday of week 1
95
+ * is `Jan 4 − (Jan 4's ISO weekday − 1)`; every later week adds whole
96
+ * seven-day spans. All arithmetic rides UTC milliseconds (whole days, no
97
+ * DST drift); the result is read back as a civil triple. Weeks beyond the
98
+ * year's last (52 or 53 per the ISO calendar) resolve into the neighbor
99
+ * year — callers validate with a `getISOWeek` round-trip (see
100
+ * {@link parseWeekValue}).
101
+ */
102
+ export declare function getISOWeekStartDate(isoYear: number, week: number): {
103
+ year: number;
104
+ month: number;
105
+ day: number;
106
+ };
74
107
  /**
75
108
  * Format a civil date as the `"YYYY-MM-DD"` string Calendar uses as its
76
109
  * value. Value semantics: the string denotes the **local** civil date — it
@@ -119,6 +152,24 @@ export declare function formatYearValue(year: number): string;
119
152
  export declare function parseYearValue(value: string): {
120
153
  year: number;
121
154
  } | null;
155
+ /**
156
+ * Format an ISO week as the `"YYYY-Www"` string Calendar's
157
+ * `picker="week"` mode uses as its value (`isoYear` is the ISO
158
+ * week-numbering year — not necessarily the civil year of every day in
159
+ * the week — and `week` is 1-based, zero-padded: 2026 week 37 →
160
+ * `"2026-W37"`). Pure string math; no Date construction.
161
+ */
162
+ export declare function formatWeekValue(isoYear: number, week: number): string;
163
+ /**
164
+ * Parse a `"YYYY-Www"` week-picker value (`{@link formatWeekValue}`'s
165
+ * inverse). Accepts weeks `01`…`53` shape-wise, then rejects the ones
166
+ * that do not exist in the given ISO year via a round-trip: 2025 is a
167
+ * 52-week year, so `"2025-W53"` resolves to a Monday that belongs to
168
+ * 2026 week 1 and is rejected. Anything with another shape
169
+ * (`"2026-W1"`, `"2026-w05"`, a date/month/quarter serialization) is
170
+ * rejected outright.
171
+ */
172
+ export declare function parseWeekValue(value: string): ISOWeek | null;
122
173
  /**
123
174
  * Parse a `"YYYY-MM-DD"` value string into a local-midnight Date — the
124
175
  * inverse of {@link formatDate} and the only safe way to turn a value into