haze-ui 1.32.0 → 1.34.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.
- package/LICENSE +21 -0
- package/README.md +111 -1210
- package/dist/THIRD-PARTY-NOTICES.md +152 -0
- package/dist/coi-serviceworker.LICENSE +21 -0
- package/dist/coi-serviceworker.js +118 -0
- package/dist/components/Accordion/Accordion.js +40 -8
- package/dist/components/Accordion/AccordionContext.js +9 -0
- package/dist/components/Accordion/AccordionItem.js +30 -15
- package/dist/components/Accordion/index.js +3 -3
- package/dist/components/ActivityRail/ActivityRail.js +46 -37
- package/dist/components/Affix/Affix.js +0 -1
- package/dist/components/Affix/index.js +0 -1
- package/dist/components/Alert/Alert.js +17 -23
- package/dist/components/Alert/alert-styles.js +14 -0
- package/dist/components/Alert/index.js +3 -2
- package/dist/components/ApprovalCard/ApprovalCard.js +70 -43
- package/dist/components/Avatar/Avatar.js +5 -4
- package/dist/components/AvatarGroup/AvatarGroup.js +15 -18
- package/dist/components/AvatarGroup/index.js +0 -1
- package/dist/components/Badge/Badge.js +5 -4
- package/dist/components/Badge/badge-styles.js +2 -1
- package/dist/components/Badge/index.js +2 -2
- package/dist/components/Banner/Banner.js +17 -23
- package/dist/components/Banner/banner-styles.js +14 -0
- package/dist/components/Banner/index.js +3 -2
- package/dist/components/Breadcrumb/Breadcrumb.js +16 -17
- package/dist/components/Breadcrumb/BreadcrumbItem.js +7 -10
- package/dist/components/Breadcrumb/index.js +0 -1
- package/dist/components/Button/ButtonLink.js +11 -9
- package/dist/components/ButtonGroup/ButtonGroup.js +48 -0
- package/dist/components/ButtonGroup/ButtonGroupContext.js +9 -0
- package/dist/components/ButtonGroup/ButtonGroupSeparator.js +30 -0
- package/dist/components/ButtonGroup/button-group-styles.js +7 -0
- package/dist/components/ButtonGroup/index.js +5 -0
- package/dist/components/Calendar/Calendar.js +355 -305
- package/dist/components/Card/Card.js +9 -7
- package/dist/components/Card/index.js +2 -2
- package/dist/components/Carousel/Carousel.js +108 -91
- package/dist/components/Carousel/CarouselSlide.js +15 -9
- package/dist/components/Cascader/Cascader.js +190 -173
- package/dist/components/Chart/Chart.js +122 -24
- package/dist/components/Chart/chart-elements.js +271 -114
- package/dist/components/ChatInput/ChatInput.js +32 -28
- package/dist/components/ChatMessage/ChatMessage.js +79 -72
- package/dist/components/Checkbox/Checkbox.js +17 -14
- package/dist/components/Checkbox/CheckboxCore.js +28 -17
- package/dist/components/Chip/Chip.js +18 -33
- package/dist/components/Chip/chip-styles.js +23 -0
- package/dist/components/Chip/index.js +3 -3
- package/dist/components/CodeBlock/CodeBlock.js +1 -0
- package/dist/components/CodeBlock/index.js +1 -0
- package/dist/components/Collapsible/Collapsible.js +53 -44
- package/dist/components/ColorPicker/ColorPicker.js +84 -73
- package/dist/components/ColorPicker/ColorPickerCore.js +60 -39
- package/dist/components/ColorPicker/ColorPickerPanel.js +312 -109
- package/dist/components/ColorPicker/color-picker-styles.js +2 -2
- package/dist/components/ColorPicker/gradient.js +114 -0
- package/dist/components/Combobox/Combobox.js +125 -123
- package/dist/components/Combobox/ComboboxGroup.js +23 -16
- package/dist/components/Combobox/ComboboxOption.js +12 -8
- package/dist/components/Combobox/combobox-options.js +26 -0
- package/dist/components/Command/Command.js +182 -97
- package/dist/components/Command/CommandDialog.js +49 -34
- package/dist/components/Command/command-filter.js +80 -10
- package/dist/components/ConfigProvider/ConfigContext.js +7 -38
- package/dist/components/ConfigProvider/ConfigProvider.js +15 -7
- package/dist/components/ConfigProvider/useConfigDefaults.js +5 -2
- package/dist/components/ContextMenu/ContextMenu.js +52 -34
- package/dist/components/ContextMenu/ContextMenuContent.js +40 -26
- package/dist/components/ContextMenu/ContextMenuItem.js +22 -13
- package/dist/components/ContextMenu/ContextMenuSeparator.js +14 -7
- package/dist/components/ContextMenu/ContextMenuTrigger.js +21 -12
- package/dist/components/ConversationList/ConversationItem.js +45 -29
- package/dist/components/ConversationList/ConversationList.js +22 -15
- package/dist/components/CopyButton/CopyButton.js +83 -0
- package/dist/components/CopyButton/Snippet.js +50 -0
- package/dist/components/CopyButton/copy-button-styles.js +11 -0
- package/dist/components/CopyButton/index.js +5 -0
- package/dist/components/CopyButton/snippet-styles.js +7 -0
- package/dist/components/Countdown/Countdown.js +63 -0
- package/dist/components/Countdown/index.js +3 -0
- package/dist/components/DataTable/CellEditor.js +34 -24
- package/dist/components/DataTable/DataTable.js +591 -321
- package/dist/components/DataTable/column-filter.js +106 -0
- package/dist/components/DataTable/column-reorder.js +17 -0
- package/dist/components/DataTable/csv.js +15 -14
- package/dist/components/DataTable/features.js +19 -18
- package/dist/components/DataTable/filters.js +26 -0
- package/dist/components/DateField/DateField.js +28 -0
- package/dist/components/DateField/DateFieldCore.js +94 -0
- package/dist/components/DateField/index.js +4 -0
- package/dist/components/DateField/segmented-field.js +121 -0
- package/dist/components/DateRangePicker/DateRangePicker.js +35 -28
- package/dist/components/Datepicker/Datepicker.js +31 -27
- package/dist/components/Descriptions/Descriptions.js +0 -1
- package/dist/components/Descriptions/index.js +0 -1
- package/dist/components/Dialog/Dialog.js +47 -41
- package/dist/components/DiffViewer/DiffViewer.js +65 -48
- package/dist/components/Disclosure/Disclosure.js +31 -22
- package/dist/components/Drawer/Drawer.js +50 -39
- package/dist/components/DropdownMenu/DropdownMenu.js +61 -45
- package/dist/components/DropdownMenu/DropdownMenuCheckboxItem.js +24 -22
- package/dist/components/DropdownMenu/DropdownMenuContent.js +5 -5
- package/dist/components/DropdownMenu/DropdownMenuGroup.js +26 -16
- package/dist/components/DropdownMenu/DropdownMenuItem.js +2 -1
- package/dist/components/DropdownMenu/DropdownMenuRadioGroup.js +33 -21
- package/dist/components/DropdownMenu/DropdownMenuRadioItem.js +22 -20
- package/dist/components/DropdownMenu/DropdownMenuSeparator.js +14 -7
- package/dist/components/DropdownMenu/DropdownMenuSub.js +28 -16
- package/dist/components/DropdownMenu/DropdownMenuSubContent.js +14 -13
- package/dist/components/DropdownMenu/DropdownMenuSubTrigger.js +22 -17
- package/dist/components/DropdownMenu/DropdownMenuTrigger.js +33 -22
- package/dist/components/Empty/Empty.js +41 -28
- package/dist/components/ErrorBoundary/ErrorBoundary.js +88 -0
- package/dist/components/ErrorBoundary/index.js +3 -0
- package/dist/components/FileInput/FileInput.js +23 -16
- package/dist/components/FilePreview/FilePreview.js +104 -91
- package/dist/components/FloatButton/float-button-glyphs.js +9 -7
- package/dist/components/Fullscreen/Fullscreen.js +35 -27
- package/dist/components/Heatmap/Heatmap.js +124 -0
- package/dist/components/Heatmap/heatmap-styles.js +6 -0
- package/dist/components/Heatmap/index.js +2 -0
- package/dist/components/HoverCard/HoverCard.js +63 -43
- package/dist/components/Image/Image.js +56 -32
- package/dist/components/Image/ImageGalleryContext.js +9 -0
- package/dist/components/Image/ImagePreview.js +297 -200
- package/dist/components/Image/ImagePreviewGroup.js +46 -0
- package/dist/components/Image/index.js +2 -1
- package/dist/components/ImageCrop/ImageCrop.js +188 -0
- package/dist/components/ImageCrop/image-crop-geometry.js +81 -0
- package/dist/components/ImageCrop/index.js +3 -0
- package/dist/components/InlineCitation/InlineCitation.js +78 -0
- package/dist/components/InlineCitation/index.js +3 -0
- package/dist/components/InlineEdit/InlineEdit.js +62 -40
- package/dist/components/Input/Input.js +21 -17
- package/dist/components/Input/InputCore.js +9 -12
- package/dist/components/Input/input-styles.js +11 -0
- package/dist/components/InputGroup/InputGroup.js +33 -0
- package/dist/components/InputGroup/InputGroupAddon.js +27 -0
- package/dist/components/InputGroup/InputGroupContext.js +9 -0
- package/dist/components/InputGroup/index.js +5 -0
- package/dist/components/InputGroup/input-group-styles.js +11 -0
- package/dist/components/JsonView/JsonView.js +277 -179
- package/dist/components/Kbd/Kbd.js +3 -2
- package/dist/components/List/List.js +0 -1
- package/dist/components/List/ListItem.js +0 -1
- package/dist/components/List/index.js +0 -1
- package/dist/components/LocaleProvider/LocaleProvider.js +17 -17
- package/dist/components/LocaleProvider/ar-sa.js +28 -2
- package/dist/components/LocaleProvider/de-de.js +28 -2
- package/dist/components/LocaleProvider/es-es.js +28 -2
- package/dist/components/LocaleProvider/fr-fr.js +28 -2
- package/dist/components/LocaleProvider/it-it.js +28 -2
- package/dist/components/LocaleProvider/ja-jp.js +28 -2
- package/dist/components/LocaleProvider/ko-kr.js +28 -2
- package/dist/components/LocaleProvider/locale.js +28 -2
- package/dist/components/LocaleProvider/pt-br.js +28 -2
- package/dist/components/LocaleProvider/ru-ru.js +28 -2
- package/dist/components/LocaleProvider/useStrings.js +20 -9
- package/dist/components/LocaleProvider/zh-cn.js +28 -2
- package/dist/components/LogViewer/LogViewer.js +89 -59
- package/dist/components/Mark/Mark.js +3 -1
- package/dist/components/MaskedInput/MaskedInput.js +25 -0
- package/dist/components/MaskedInput/MaskedInputCore.js +47 -0
- package/dist/components/MaskedInput/index.js +5 -0
- package/dist/components/MaskedInput/mask.js +154 -0
- package/dist/components/Mentions/Mentions.js +18 -13
- package/dist/components/Menu/Menu.js +202 -55
- package/dist/components/Menu/MenuCheckboxItem.js +24 -22
- package/dist/components/Menu/MenuContext.js +9 -0
- package/dist/components/Menu/MenuDivider.js +12 -8
- package/dist/components/Menu/MenuGroup.js +26 -16
- package/dist/components/Menu/MenuItem.js +20 -18
- package/dist/components/Menu/MenuRadioGroup.js +34 -22
- package/dist/components/Menu/MenuRadioItem.js +23 -21
- package/dist/components/Menu/MenuSub.js +29 -17
- package/dist/components/Menu/MenuSubContent.js +15 -14
- package/dist/components/Menu/MenuSubTrigger.js +23 -18
- package/dist/components/Meter/Meter.js +63 -0
- package/dist/components/Meter/index.js +4 -0
- package/dist/components/Meter/meter-styles.js +11 -0
- package/dist/components/ModelPicker/ModelPicker.js +38 -24
- package/dist/components/NavigationBar/NavLink.js +0 -1
- package/dist/components/NavigationBar/NavigationBar.js +0 -1
- package/dist/components/NavigationBar/index.js +0 -1
- package/dist/components/NavigationMenu/NavigationMenu.js +73 -0
- package/dist/components/NavigationMenu/NavigationMenuContent.js +53 -0
- package/dist/components/NavigationMenu/NavigationMenuContext.js +17 -0
- package/dist/components/NavigationMenu/NavigationMenuItem.js +72 -0
- package/dist/components/NavigationMenu/NavigationMenuList.js +59 -0
- package/dist/components/NavigationMenu/NavigationMenuTrigger.js +82 -0
- package/dist/components/NavigationMenu/index.js +7 -0
- package/dist/components/NumberInput/NumberInput.js +22 -18
- package/dist/components/NumberInput/NumberInputCore.js +23 -30
- package/dist/components/NumberInput/index.js +4 -3
- package/dist/components/NumberInput/number-input-styles.js +15 -0
- package/dist/components/OTPInput/OTPInput.js +28 -15
- package/dist/components/Pagination/Pagination.js +81 -83
- package/dist/components/Pagination/pagination-styles.js +11 -0
- package/dist/components/PasswordInput/PasswordInput.js +18 -15
- package/dist/components/PasswordInput/PasswordInputCore.js +39 -28
- package/dist/components/PhoneInput/PhoneInput.js +144 -0
- package/dist/components/PhoneInput/index.js +4 -0
- package/dist/components/PhoneInput/phone-input-styles.js +7 -0
- package/dist/components/PhoneInput/phone-number.js +8 -0
- package/dist/components/Plan/Plan.js +115 -0
- package/dist/components/Plan/index.js +3 -0
- package/dist/components/Popconfirm/Popconfirm.js +152 -0
- package/dist/components/Popconfirm/index.js +3 -0
- package/dist/components/Popover/Popover.js +55 -40
- package/dist/components/Progress/Progress.js +40 -57
- package/dist/components/Progress/index.js +3 -3
- package/dist/components/Progress/progress-styles.js +28 -0
- package/dist/components/PullToRefresh/PullToRefresh.js +121 -0
- package/dist/components/PullToRefresh/index.js +3 -0
- package/dist/components/Queue/Queue.js +68 -0
- package/dist/components/Queue/index.js +3 -0
- package/dist/components/Radio/Radio.js +28 -19
- package/dist/components/Radio/RadioGroup.js +14 -13
- package/dist/components/Radio/RadioGroupCore.js +34 -19
- package/dist/components/Rating/Rating.js +29 -16
- package/dist/components/Resizable/index.js +1 -1
- package/dist/components/Result/Result.js +0 -1
- package/dist/components/Result/index.js +0 -1
- package/dist/components/RichTextEditor/RichTextEditor.js +257 -0
- package/dist/components/RichTextEditor/index.js +3 -0
- package/dist/components/Schedule/Schedule.js +566 -0
- package/dist/components/Schedule/index.js +3 -0
- package/dist/components/ScrollArea/ScrollArea.js +28 -9
- package/dist/components/ScrollArea/ScrollAreaContext.js +11 -0
- package/dist/components/ScrollArea/ScrollThumb.js +114 -0
- package/dist/components/ScrollArea/ScrollViewport.js +52 -0
- package/dist/components/ScrollArea/Scrollbar.js +49 -0
- package/dist/components/ScrollArea/index.js +5 -2
- package/dist/components/ScrollArea/scroll-math.js +58 -0
- package/dist/components/Segmented/Segmented.js +29 -16
- package/dist/components/Select/Option.js +12 -8
- package/dist/components/Select/OptionGroup.js +12 -8
- package/dist/components/Select/Select.js +52 -30
- package/dist/components/Select/SelectCore.js +62 -57
- package/dist/components/Select/SelectFloating.js +256 -172
- package/dist/components/Select/index.js +5 -5
- package/dist/components/Select/select-options.js +8 -6
- package/dist/components/Sidebar/Sidebar.js +102 -76
- package/dist/components/Sources/Sources.js +54 -50
- package/dist/components/Sparkline/Sparkline.js +2 -2
- package/dist/components/Sparkline/index.js +1 -1
- package/dist/components/Sparkline/sparkline-styles.js +3 -1
- package/dist/components/Spinner/Spinner.js +4 -3
- package/dist/components/Splitter/Splitter.js +209 -0
- package/dist/components/Splitter/index.js +3 -0
- package/dist/components/StatusBar/StatusBar.js +0 -1
- package/dist/components/StatusBar/index.js +0 -1
- package/dist/components/StepTimeline/StepTimeline.js +95 -29
- package/dist/components/Stepper/Stepper.js +34 -20
- package/dist/components/StreamingText/StreamingText.js +33 -31
- package/dist/components/Switch/Switch.js +27 -15
- package/dist/components/Switch/SwitchCore.js +18 -29
- package/dist/components/Switch/index.js +4 -3
- package/dist/components/Switch/switch-styles.js +19 -0
- package/dist/components/TabBar/TabBar.js +0 -1
- package/dist/components/TabBar/index.js +0 -1
- package/dist/components/Table/Table.js +38 -17
- package/dist/components/Table/TableBody.js +17 -8
- package/dist/components/Table/TableCell.js +9 -7
- package/dist/components/Table/TableContext.js +9 -0
- package/dist/components/Table/TableHead.js +17 -8
- package/dist/components/Table/TableRow.js +12 -7
- package/dist/components/Table/table-styles.js +7 -0
- package/dist/components/Tabs/SortableTabList.js +70 -51
- package/dist/components/Tabs/Tab.js +70 -53
- package/dist/components/Tabs/TabList.js +96 -75
- package/dist/components/Tabs/TabPanel.js +20 -15
- package/dist/components/Tabs/Tabs.js +37 -15
- package/dist/components/Tabs/index.js +7 -6
- package/dist/components/Tabs/tab-metas.js +20 -10
- package/dist/components/Tabs/tabs-styles.js +23 -0
- package/dist/components/Tag/Tag.js +14 -26
- package/dist/components/Tag/index.js +3 -3
- package/dist/components/Tag/tag-styles.js +16 -0
- package/dist/components/TagGroup/SortableTagGroup.js +50 -30
- package/dist/components/TagGroup/TagGroup.js +29 -22
- package/dist/components/TagGroup/TagGroupItem.js +32 -25
- package/dist/components/TagInput/SortableTagInput.js +24 -19
- package/dist/components/TagInput/SortableTagInputCore.js +69 -42
- package/dist/components/TagInput/TagInput.js +33 -20
- package/dist/components/Textarea/Textarea.js +19 -15
- package/dist/components/Textarea/TextareaCore.js +6 -9
- package/dist/components/Textarea/textarea-styles.js +11 -0
- package/dist/components/ThinkingIndicator/ThinkingIndicator.js +42 -29
- package/dist/components/TimeField/TimeField.js +29 -0
- package/dist/components/TimeField/TimeFieldCore.js +69 -0
- package/dist/components/TimeField/index.js +4 -0
- package/dist/components/TimeGrid/TimeGrid.js +89 -0
- package/dist/components/TimeGrid/index.js +3 -0
- package/dist/components/TimeGrid/time-grid-styles.js +7 -0
- package/dist/components/TimePicker/TimePicker.js +31 -30
- package/dist/components/TimePicker/TimePickerCore.js +20 -12
- package/dist/components/Timeline/Timeline.js +0 -1
- package/dist/components/Timeline/index.js +0 -1
- package/dist/components/Toast/ToastContainer.js +99 -69
- package/dist/components/Toggle/Toggle.js +16 -13
- package/dist/components/TokenCounter/TokenCounter.js +56 -31
- package/dist/components/Toolbar/Toolbar.js +5 -3
- package/dist/components/Toolbar/ToolbarSeparator.js +19 -14
- package/dist/components/Tooltip/Tooltip.js +37 -30
- package/dist/components/Trace/Trace.js +132 -0
- package/dist/components/Trace/index.js +3 -0
- package/dist/components/Transfer/Transfer.js +18 -13
- package/dist/components/Transfer/TransferCore.js +144 -88
- package/dist/components/Tree/SortableTree.js +115 -96
- package/dist/components/Tree/Tree.js +81 -80
- package/dist/components/Tree/TreeItem.js +198 -143
- package/dist/components/TreeSelect/TreeSelect.js +59 -55
- package/dist/components/Upload/Upload.js +28 -24
- package/dist/components/Upload/UploadCore.js +241 -184
- package/dist/components/Upload/UploadList.js +349 -298
- package/dist/components/Workbench/Workbench.js +165 -126
- package/dist/css/accordion.css +1 -1
- package/dist/css/affix.css +1 -1
- package/dist/css/alert.css +1 -1
- package/dist/css/app-shell.css +1 -1
- package/dist/css/badge.css +1 -1
- package/dist/css/banner.css +1 -1
- package/dist/css/bottom-sheet.css +1 -1
- package/dist/css/button-group.css +4 -0
- package/dist/css/card.css +1 -1
- package/dist/css/carousel.css +1 -1
- package/dist/css/chart.css +2 -1
- package/dist/css/chat-container.css +1 -1
- package/dist/css/chip.css +1 -1
- package/dist/css/color-picker.css +2 -1
- package/dist/css/combobox.css +3 -3
- package/dist/css/command.css +1 -1
- package/dist/css/confirm-dialog.css +1 -1
- package/dist/css/context-menu.css +2 -2
- package/dist/css/copy-button.css +5 -0
- package/dist/css/countdown.css +4 -0
- package/dist/css/data-table.css +2 -1
- package/dist/css/date-field.css +4 -0
- package/dist/css/datepicker.css +1 -1
- package/dist/css/drawer.css +1 -1
- package/dist/css/dropdown-menu.css +1 -1
- package/dist/css/error-boundary.css +4 -0
- package/dist/css/heatmap.css +4 -0
- package/dist/css/image-crop.css +4 -0
- package/dist/css/image.css +1 -1
- package/dist/css/inline-citation.css +4 -0
- package/dist/css/input-group.css +4 -0
- package/dist/css/input.css +2 -1
- package/dist/css/loading-overlay.css +1 -1
- package/dist/css/mark.css +1 -1
- package/dist/css/menu.css +2 -2
- package/dist/css/meter.css +4 -0
- package/dist/css/navigation-menu.css +9 -0
- package/dist/css/number-input.css +2 -1
- package/dist/css/otp-input.css +1 -0
- package/dist/css/pagination.css +2 -1
- package/dist/css/phone-input.css +4 -0
- package/dist/css/plan.css +4 -0
- package/dist/css/popconfirm.css +5 -0
- package/dist/css/popover.css +1 -1
- package/dist/css/progress.css +1 -1
- package/dist/css/pull-to-refresh.css +4 -0
- package/dist/css/queue.css +4 -0
- package/dist/css/rating.css +1 -0
- package/dist/css/rich-text-editor.css +5 -0
- package/dist/css/schedule.css +4 -0
- package/dist/css/scroll-area.css +4 -1
- package/dist/css/segmented.css +1 -0
- package/dist/css/select.css +4 -3
- package/dist/css/sparkline.css +1 -1
- package/dist/css/splitter.css +4 -0
- package/dist/css/step-timeline.css +1 -1
- package/dist/css/switch.css +3 -1
- package/dist/css/table.css +2 -1
- package/dist/css/tabs.css +4 -3
- package/dist/css/tag-group.css +1 -1
- package/dist/css/tag-input.css +2 -1
- package/dist/css/tag.css +1 -1
- package/dist/css/textarea.css +2 -1
- package/dist/css/time-grid.css +4 -0
- package/dist/css/time-picker.css +1 -1
- package/dist/css/timeline.css +1 -1
- package/dist/css/toast.css +1 -1
- package/dist/css/tokens.css +2 -2
- package/dist/css/tooltip.css +1 -1
- package/dist/css/tour.css +1 -1
- package/dist/css/trace.css +4 -0
- package/dist/css/tree-select.css +1 -1
- package/dist/css/tree.css +1 -1
- package/dist/css/upload.css +1 -1
- package/dist/css/virtual-list.css +1 -1
- package/dist/css/workbench.css +1 -1
- package/dist/css-manifest.json +162 -12
- package/dist/design-tokens/cyan-dark.json +32 -0
- package/dist/design-tokens/cyan-light.json +32 -0
- package/dist/design-tokens/dark.json +32 -0
- package/dist/design-tokens/light.json +32 -0
- package/dist/design-tokens/orange-dark.json +32 -0
- package/dist/design-tokens/orange-light.json +32 -0
- package/dist/design-tokens/rose-dark.json +32 -0
- package/dist/design-tokens/rose-light.json +32 -0
- package/dist/design-tokens/teal-dark.json +32 -0
- package/dist/design-tokens/teal-light.json +32 -0
- package/dist/design-tokens/violet-dark.json +32 -0
- package/dist/design-tokens/violet-light.json +32 -0
- package/dist/form/FormItem.js +71 -52
- package/dist/form/index.js +3 -3
- package/dist/haze-ui.css +172 -61
- package/dist/hooks/useClipboard.js +22 -14
- package/dist/hooks/useDebouncedCallback.js +17 -11
- package/dist/hooks/useDebouncedValue.js +8 -7
- package/dist/hooks/useFullscreen.js +40 -36
- package/dist/hooks/useHotkeys.js +78 -24
- package/dist/hooks/useMediaQuery.js +9 -5
- package/dist/hooks/useStorageState.js +43 -34
- package/dist/hooks/useTitle.js +12 -9
- package/dist/index.js +325 -274
- package/dist/locales/index.js +14 -0
- package/dist/mcp-docs.json +3279 -364
- package/dist/registry.json +655 -64
- package/dist/robots.txt +4 -0
- package/dist/sitemap.xml +185 -0
- package/dist/tokens/colors.js +2 -2
- package/dist/tokens/index.js +8 -8
- package/dist/tokens/registry.js +47 -13
- package/dist/tokens/z-index.js +35 -0
- package/dist/types/components/Accordion/Accordion.d.ts +33 -4
- package/dist/types/components/Accordion/AccordionContext.d.ts +41 -0
- package/dist/types/components/Accordion/AccordionItem.d.ts +18 -3
- package/dist/types/components/Accordion/index.d.ts +4 -4
- package/dist/types/components/ActivityRail/index.d.ts +4 -4
- package/dist/types/components/Affix/index.d.ts +2 -2
- package/dist/types/components/Alert/Alert.d.ts +6 -3
- package/dist/types/components/Alert/alert-styles.d.ts +20 -0
- package/dist/types/components/Alert/index.d.ts +3 -2
- package/dist/types/components/Anchor/index.d.ts +2 -2
- package/dist/types/components/AppShell/index.d.ts +2 -2
- package/dist/types/components/ApprovalCard/index.d.ts +2 -2
- package/dist/types/components/AspectRatio/index.d.ts +2 -2
- package/dist/types/components/AsyncSection/index.d.ts +2 -2
- package/dist/types/components/Avatar/Avatar.d.ts +4 -2
- package/dist/types/components/Avatar/index.d.ts +2 -2
- package/dist/types/components/AvatarGroup/AvatarGroup.d.ts +8 -2
- package/dist/types/components/AvatarGroup/index.d.ts +2 -2
- package/dist/types/components/BackToTop/index.d.ts +2 -2
- package/dist/types/components/Badge/Badge.d.ts +6 -3
- package/dist/types/components/Badge/badge-styles.d.ts +4 -3
- package/dist/types/components/Badge/index.d.ts +3 -3
- package/dist/types/components/Banner/Banner.d.ts +6 -3
- package/dist/types/components/Banner/banner-styles.d.ts +20 -0
- package/dist/types/components/Banner/index.d.ts +3 -2
- package/dist/types/components/BottomSheet/index.d.ts +2 -2
- package/dist/types/components/Breadcrumb/Breadcrumb.d.ts +3 -3
- package/dist/types/components/Breadcrumb/BreadcrumbItem.d.ts +23 -5
- package/dist/types/components/Breadcrumb/index.d.ts +4 -4
- package/dist/types/components/Button/ButtonLink.d.ts +4 -12
- package/dist/types/components/Button/index.d.ts +5 -5
- package/dist/types/components/ButtonGroup/ButtonGroup.d.ts +52 -0
- package/dist/types/components/ButtonGroup/ButtonGroupContext.d.ts +28 -0
- package/dist/types/components/ButtonGroup/ButtonGroupSeparator.d.ts +18 -0
- package/dist/types/components/ButtonGroup/button-group-styles.d.ts +45 -0
- package/dist/types/components/ButtonGroup/index.d.ts +6 -0
- package/dist/types/components/Calendar/Calendar.d.ts +74 -3
- package/dist/types/components/Calendar/index.d.ts +2 -2
- package/dist/types/components/Card/Card.d.ts +32 -5
- package/dist/types/components/Card/index.d.ts +3 -2
- package/dist/types/components/Carousel/Carousel.d.ts +27 -3
- package/dist/types/components/Carousel/index.d.ts +4 -4
- package/dist/types/components/Cascader/Cascader.d.ts +44 -2
- package/dist/types/components/Cascader/index.d.ts +2 -2
- package/dist/types/components/Chart/Chart.d.ts +111 -18
- package/dist/types/components/Chart/chart-elements.d.ts +73 -7
- package/dist/types/components/Chart/index.d.ts +2 -2
- package/dist/types/components/ChatContainer/index.d.ts +2 -2
- package/dist/types/components/ChatInput/index.d.ts +2 -2
- package/dist/types/components/ChatMessage/index.d.ts +2 -2
- package/dist/types/components/Checkbox/index.d.ts +4 -4
- package/dist/types/components/Chip/Chip.d.ts +12 -3
- package/dist/types/components/Chip/chip-styles.d.ts +51 -0
- package/dist/types/components/Chip/index.d.ts +3 -2
- package/dist/types/components/CodeBlock/index.d.ts +2 -2
- package/dist/types/components/Collapsible/index.d.ts +2 -2
- package/dist/types/components/ColorPicker/ColorPicker.d.ts +37 -4
- package/dist/types/components/ColorPicker/ColorPickerPanel.d.ts +28 -9
- package/dist/types/components/ColorPicker/color-picker-styles.d.ts +27 -0
- package/dist/types/components/ColorPicker/gradient.d.ts +64 -0
- package/dist/types/components/ColorPicker/index.d.ts +5 -4
- package/dist/types/components/Combobox/Combobox.d.ts +24 -23
- package/dist/types/components/Combobox/ComboboxOption.d.ts +11 -4
- package/dist/types/components/Combobox/combobox-options.d.ts +24 -0
- package/dist/types/components/Combobox/index.d.ts +6 -6
- package/dist/types/components/Command/Command.d.ts +36 -5
- package/dist/types/components/Command/command-filter.d.ts +57 -5
- package/dist/types/components/Command/index.d.ts +4 -4
- package/dist/types/components/ConfigProvider/ConfigContext.d.ts +104 -24
- package/dist/types/components/ConfigProvider/ConfigProvider.d.ts +16 -6
- package/dist/types/components/ConfigProvider/index.d.ts +4 -4
- package/dist/types/components/ConfigProvider/useConfigDefaults.d.ts +17 -4
- package/dist/types/components/ConfirmDialog/confirm.d.ts +1 -1
- package/dist/types/components/ConfirmDialog/index.d.ts +4 -4
- package/dist/types/components/Container/index.d.ts +2 -2
- package/dist/types/components/ContextMenu/ContextMenu.d.ts +20 -2
- package/dist/types/components/ContextMenu/ContextMenuContext.d.ts +25 -1
- package/dist/types/components/ContextMenu/index.d.ts +11 -10
- package/dist/types/components/ConversationList/index.d.ts +4 -4
- package/dist/types/components/CopyButton/CopyButton.d.ts +56 -0
- package/dist/types/components/CopyButton/Snippet.d.ts +48 -0
- package/dist/types/components/CopyButton/copy-button-styles.d.ts +21 -0
- package/dist/types/components/CopyButton/index.d.ts +5 -0
- package/dist/types/components/CopyButton/snippet-styles.d.ts +10 -0
- package/dist/types/components/CountUp/index.d.ts +2 -2
- package/dist/types/components/Countdown/Countdown.d.ts +30 -0
- package/dist/types/components/Countdown/index.d.ts +2 -0
- package/dist/types/components/DataTable/DataTable.d.ts +169 -10
- package/dist/types/components/DataTable/column-filter.d.ts +27 -0
- package/dist/types/components/DataTable/column-reorder.d.ts +32 -0
- package/dist/types/components/DataTable/csv.d.ts +13 -3
- package/dist/types/components/DataTable/features.d.ts +18 -1
- package/dist/types/components/DataTable/filters.d.ts +25 -0
- package/dist/types/components/DataTable/index.d.ts +6 -5
- package/dist/types/components/DataTable/summary.d.ts +1 -1
- package/dist/types/components/DateField/DateField.d.ts +21 -0
- package/dist/types/components/DateField/DateFieldCore.d.ts +30 -0
- package/dist/types/components/DateField/index.d.ts +4 -0
- package/dist/types/components/DateField/segmented-field.d.ts +70 -0
- package/dist/types/components/DateRangePicker/DateRangePicker.d.ts +1 -1
- package/dist/types/components/DateRangePicker/index.d.ts +4 -4
- package/dist/types/components/DateRangePicker/presets.d.ts +1 -1
- package/dist/types/components/DateTimePicker/DateTimePicker.d.ts +2 -2
- package/dist/types/components/DateTimePicker/index.d.ts +2 -2
- package/dist/types/components/Datepicker/Datepicker.d.ts +2 -2
- package/dist/types/components/Datepicker/DatepickerCore.d.ts +1 -1
- package/dist/types/components/Datepicker/index.d.ts +4 -4
- package/dist/types/components/Descriptions/index.d.ts +2 -2
- package/dist/types/components/Dialog/Dialog.d.ts +12 -1
- package/dist/types/components/Dialog/index.d.ts +2 -2
- package/dist/types/components/DiffViewer/index.d.ts +2 -2
- package/dist/types/components/Disclosure/index.d.ts +2 -2
- package/dist/types/components/Divider/index.d.ts +2 -2
- package/dist/types/components/Drawer/Drawer.d.ts +23 -1
- package/dist/types/components/Drawer/index.d.ts +2 -2
- package/dist/types/components/DropdownMenu/DropdownMenu.d.ts +16 -3
- package/dist/types/components/DropdownMenu/DropdownMenuContext.d.ts +39 -1
- package/dist/types/components/DropdownMenu/index.d.ts +25 -24
- package/dist/types/components/Ellipsis/index.d.ts +2 -2
- package/dist/types/components/Empty/index.d.ts +2 -2
- package/dist/types/components/ErrorBoundary/ErrorBoundary.d.ts +45 -0
- package/dist/types/components/ErrorBoundary/index.d.ts +2 -0
- package/dist/types/components/Fieldset/index.d.ts +2 -2
- package/dist/types/components/FileInput/index.d.ts +2 -2
- package/dist/types/components/FilePreview/index.d.ts +2 -2
- package/dist/types/components/Flex/index.d.ts +2 -2
- package/dist/types/components/FloatButton/index.d.ts +4 -4
- package/dist/types/components/Fullscreen/Fullscreen.d.ts +1 -1
- package/dist/types/components/Fullscreen/index.d.ts +3 -3
- package/dist/types/components/Grid/index.d.ts +4 -4
- package/dist/types/components/Heatmap/Heatmap.d.ts +69 -0
- package/dist/types/components/Heatmap/heatmap-styles.d.ts +25 -0
- package/dist/types/components/Heatmap/index.d.ts +2 -0
- package/dist/types/components/Highlight/index.d.ts +2 -2
- package/dist/types/components/HoverCard/HoverCard.d.ts +20 -3
- package/dist/types/components/HoverCard/index.d.ts +2 -2
- package/dist/types/components/Icon/index.d.ts +2 -2
- package/dist/types/components/Image/Image.d.ts +4 -0
- package/dist/types/components/Image/ImageGalleryContext.d.ts +29 -0
- package/dist/types/components/Image/ImagePreview.d.ts +15 -1
- package/dist/types/components/Image/ImagePreviewGroup.d.ts +23 -0
- package/dist/types/components/Image/index.d.ts +4 -2
- package/dist/types/components/ImageCrop/ImageCrop.d.ts +67 -0
- package/dist/types/components/ImageCrop/image-crop-geometry.d.ts +65 -0
- package/dist/types/components/ImageCrop/index.d.ts +3 -0
- package/dist/types/components/Indicator/index.d.ts +2 -2
- package/dist/types/components/InlineCitation/InlineCitation.d.ts +17 -0
- package/dist/types/components/InlineCitation/index.d.ts +2 -0
- package/dist/types/components/InlineCompletion/index.d.ts +2 -2
- package/dist/types/components/InlineEdit/index.d.ts +2 -2
- package/dist/types/components/Input/index.d.ts +4 -4
- package/dist/types/components/Input/input-styles.d.ts +15 -0
- package/dist/types/components/InputGroup/InputGroup.d.ts +47 -0
- package/dist/types/components/InputGroup/InputGroupAddon.d.ts +22 -0
- package/dist/types/components/InputGroup/InputGroupContext.d.ts +21 -0
- package/dist/types/components/InputGroup/index.d.ts +6 -0
- package/dist/types/components/InputGroup/input-group-styles.d.ts +34 -0
- package/dist/types/components/JsonView/index.d.ts +2 -2
- package/dist/types/components/Kbd/Kbd.d.ts +4 -2
- package/dist/types/components/Kbd/index.d.ts +2 -2
- package/dist/types/components/List/index.d.ts +4 -4
- package/dist/types/components/LoadingOverlay/index.d.ts +2 -2
- package/dist/types/components/LocaleProvider/LocaleContext.d.ts +2 -2
- package/dist/types/components/LocaleProvider/LocaleProvider.d.ts +1 -1
- package/dist/types/components/LocaleProvider/ar-sa.d.ts +1 -1
- package/dist/types/components/LocaleProvider/de-de.d.ts +1 -1
- package/dist/types/components/LocaleProvider/es-es.d.ts +1 -1
- package/dist/types/components/LocaleProvider/fr-fr.d.ts +1 -1
- package/dist/types/components/LocaleProvider/index.d.ts +18 -18
- package/dist/types/components/LocaleProvider/it-it.d.ts +1 -1
- package/dist/types/components/LocaleProvider/ja-jp.d.ts +1 -1
- package/dist/types/components/LocaleProvider/ko-kr.d.ts +1 -1
- package/dist/types/components/LocaleProvider/locale.d.ts +26 -0
- package/dist/types/components/LocaleProvider/pt-br.d.ts +1 -1
- package/dist/types/components/LocaleProvider/ru-ru.d.ts +1 -1
- package/dist/types/components/LocaleProvider/strings.d.ts +1 -1
- package/dist/types/components/LocaleProvider/useStrings.d.ts +1 -1
- package/dist/types/components/LocaleProvider/zh-cn.d.ts +1 -1
- package/dist/types/components/LogViewer/index.d.ts +2 -2
- package/dist/types/components/Mark/Mark.d.ts +2 -2
- package/dist/types/components/Mark/index.d.ts +2 -2
- package/dist/types/components/MarkdownRenderer/index.d.ts +2 -2
- package/dist/types/components/MaskedInput/MaskedInput.d.ts +20 -0
- package/dist/types/components/MaskedInput/MaskedInputCore.d.ts +33 -0
- package/dist/types/components/MaskedInput/index.d.ts +6 -0
- package/dist/types/components/MaskedInput/mask.d.ts +77 -0
- package/dist/types/components/Masonry/index.d.ts +2 -2
- package/dist/types/components/Mentions/Mentions.d.ts +1 -1
- package/dist/types/components/Mentions/index.d.ts +4 -4
- package/dist/types/components/Menu/Menu.d.ts +42 -3
- package/dist/types/components/Menu/MenuContext.d.ts +39 -0
- package/dist/types/components/Menu/index.d.ts +20 -19
- package/dist/types/components/Meter/Meter.d.ts +72 -0
- package/dist/types/components/Meter/index.d.ts +3 -0
- package/dist/types/components/Meter/meter-styles.d.ts +25 -0
- package/dist/types/components/ModelPicker/index.d.ts +2 -2
- package/dist/types/components/NavigationBar/index.d.ts +4 -4
- package/dist/types/components/NavigationMenu/NavigationMenu.d.ts +47 -0
- package/dist/types/components/NavigationMenu/NavigationMenuContent.d.ts +16 -0
- package/dist/types/components/NavigationMenu/NavigationMenuContext.d.ts +77 -0
- package/dist/types/components/NavigationMenu/NavigationMenuItem.d.ts +13 -0
- package/dist/types/components/NavigationMenu/NavigationMenuList.d.ts +15 -0
- package/dist/types/components/NavigationMenu/NavigationMenuTrigger.d.ts +15 -0
- package/dist/types/components/NavigationMenu/index.d.ts +11 -0
- package/dist/types/components/NumberFormatter/index.d.ts +2 -2
- package/dist/types/components/NumberInput/index.d.ts +5 -4
- package/dist/types/components/NumberInput/number-input-styles.d.ts +10 -0
- package/dist/types/components/OTPInput/OTPInput.d.ts +9 -1
- package/dist/types/components/OTPInput/index.d.ts +4 -4
- package/dist/types/components/Pagination/index.d.ts +2 -2
- package/dist/types/components/Pagination/pagination-styles.d.ts +13 -0
- package/dist/types/components/PasswordInput/index.d.ts +4 -4
- package/dist/types/components/PhoneInput/PhoneInput.d.ts +35 -0
- package/dist/types/components/PhoneInput/index.d.ts +3 -0
- package/dist/types/components/PhoneInput/phone-input-styles.d.ts +11 -0
- package/dist/types/components/PhoneInput/phone-number.d.ts +9 -0
- package/dist/types/components/Plan/Plan.d.ts +26 -0
- package/dist/types/components/Plan/index.d.ts +2 -0
- package/dist/types/components/Popconfirm/Popconfirm.d.ts +57 -0
- package/dist/types/components/Popconfirm/index.d.ts +2 -0
- package/dist/types/components/Popover/Popover.d.ts +1 -1
- package/dist/types/components/Popover/index.d.ts +2 -2
- package/dist/types/components/Progress/Progress.d.ts +7 -3
- package/dist/types/components/Progress/index.d.ts +3 -2
- package/dist/types/components/Progress/progress-styles.d.ts +41 -0
- package/dist/types/components/PromptInput/index.d.ts +2 -2
- package/dist/types/components/PullToRefresh/PullToRefresh.d.ts +61 -0
- package/dist/types/components/PullToRefresh/index.d.ts +2 -0
- package/dist/types/components/QRCode/index.d.ts +2 -2
- package/dist/types/components/Queue/Queue.d.ts +25 -0
- package/dist/types/components/Queue/index.d.ts +2 -0
- package/dist/types/components/Radio/index.d.ts +6 -6
- package/dist/types/components/Rating/Rating.d.ts +8 -1
- package/dist/types/components/Rating/index.d.ts +4 -4
- package/dist/types/components/Resizable/index.d.ts +2 -4
- package/dist/types/components/Result/index.d.ts +2 -2
- package/dist/types/components/RichTextEditor/RichTextEditor.d.ts +56 -0
- package/dist/types/components/RichTextEditor/index.d.ts +2 -0
- package/dist/types/components/Schedule/Schedule.d.ts +113 -0
- package/dist/types/components/Schedule/index.d.ts +2 -0
- package/dist/types/components/ScrollArea/ScrollArea.d.ts +27 -3
- package/dist/types/components/ScrollArea/ScrollAreaContext.d.ts +24 -0
- package/dist/types/components/ScrollArea/ScrollThumb.d.ts +9 -0
- package/dist/types/components/ScrollArea/ScrollViewport.d.ts +8 -0
- package/dist/types/components/ScrollArea/Scrollbar.d.ts +19 -0
- package/dist/types/components/ScrollArea/index.d.ts +9 -2
- package/dist/types/components/ScrollArea/scroll-math.d.ts +121 -0
- package/dist/types/components/Segmented/Segmented.d.ts +10 -2
- package/dist/types/components/Segmented/index.d.ts +4 -4
- package/dist/types/components/Select/Option.d.ts +4 -1
- package/dist/types/components/Select/Select.d.ts +87 -15
- package/dist/types/components/Select/SelectCore.d.ts +32 -14
- package/dist/types/components/Select/SelectFloating.d.ts +33 -14
- package/dist/types/components/Select/index.d.ts +8 -8
- package/dist/types/components/Select/select-options.d.ts +16 -10
- package/dist/types/components/Sidebar/index.d.ts +4 -4
- package/dist/types/components/Signature/index.d.ts +2 -2
- package/dist/types/components/Skeleton/index.d.ts +2 -2
- package/dist/types/components/Slider/index.d.ts +4 -4
- package/dist/types/components/Sources/index.d.ts +2 -2
- package/dist/types/components/Sparkline/Sparkline.d.ts +3 -3
- package/dist/types/components/Sparkline/index.d.ts +3 -3
- package/dist/types/components/Sparkline/sparkline-styles.d.ts +7 -5
- package/dist/types/components/Spinner/Spinner.d.ts +4 -1
- package/dist/types/components/Spinner/index.d.ts +2 -2
- package/dist/types/components/Splitter/Splitter.d.ts +33 -0
- package/dist/types/components/Splitter/index.d.ts +2 -0
- package/dist/types/components/Spoiler/index.d.ts +2 -2
- package/dist/types/components/Stat/index.d.ts +2 -2
- package/dist/types/components/StatusBar/index.d.ts +3 -3
- package/dist/types/components/StepTimeline/StepTimeline.d.ts +17 -2
- package/dist/types/components/StepTimeline/index.d.ts +2 -2
- package/dist/types/components/Stepper/index.d.ts +4 -4
- package/dist/types/components/StreamingText/index.d.ts +2 -2
- package/dist/types/components/SwipeAction/index.d.ts +2 -2
- package/dist/types/components/Switch/Switch.d.ts +12 -2
- package/dist/types/components/Switch/index.d.ts +5 -4
- package/dist/types/components/Switch/switch-styles.d.ts +15 -0
- package/dist/types/components/TabBar/index.d.ts +4 -4
- package/dist/types/components/Table/Table.d.ts +17 -2
- package/dist/types/components/Table/TableContext.d.ts +27 -0
- package/dist/types/components/Table/index.d.ts +11 -10
- package/dist/types/components/Table/table-styles.d.ts +9 -0
- package/dist/types/components/Tabs/Tab.d.ts +9 -1
- package/dist/types/components/Tabs/TabList.d.ts +1 -1
- package/dist/types/components/Tabs/TabPanel.d.ts +1 -1
- package/dist/types/components/Tabs/Tabs.d.ts +76 -5
- package/dist/types/components/Tabs/TabsContext.d.ts +35 -0
- package/dist/types/components/Tabs/index.d.ts +12 -11
- package/dist/types/components/Tabs/tab-metas.d.ts +15 -1
- package/dist/types/components/Tabs/tabs-styles.d.ts +10 -0
- package/dist/types/components/Tag/Tag.d.ts +34 -6
- package/dist/types/components/Tag/index.d.ts +3 -2
- package/dist/types/components/Tag/tag-styles.d.ts +28 -0
- package/dist/types/components/TagGroup/SortableTagGroup.d.ts +1 -1
- package/dist/types/components/TagGroup/index.d.ts +6 -6
- package/dist/types/components/TagInput/SortableTagInputCore.d.ts +1 -1
- package/dist/types/components/TagInput/TagInput.d.ts +10 -1
- package/dist/types/components/TagInput/index.d.ts +8 -8
- package/dist/types/components/Textarea/index.d.ts +4 -4
- package/dist/types/components/Textarea/textarea-styles.d.ts +12 -0
- package/dist/types/components/ThinkingIndicator/index.d.ts +2 -2
- package/dist/types/components/TimeField/TimeField.d.ts +26 -0
- package/dist/types/components/TimeField/TimeFieldCore.d.ts +36 -0
- package/dist/types/components/TimeField/index.d.ts +4 -0
- package/dist/types/components/TimeGrid/TimeGrid.d.ts +58 -0
- package/dist/types/components/TimeGrid/index.d.ts +2 -0
- package/dist/types/components/TimeGrid/time-grid-styles.d.ts +13 -0
- package/dist/types/components/TimePicker/TimePicker.d.ts +1 -1
- package/dist/types/components/TimePicker/TimePickerPanel.d.ts +1 -1
- package/dist/types/components/TimePicker/index.d.ts +5 -5
- package/dist/types/components/Timeline/index.d.ts +2 -2
- package/dist/types/components/Toast/Toast.d.ts +1 -1
- package/dist/types/components/Toast/ToastContainer.d.ts +1 -1
- package/dist/types/components/Toast/index.d.ts +7 -7
- package/dist/types/components/Toast/toast-channel.d.ts +1 -1
- package/dist/types/components/Toast/useToast.d.ts +1 -1
- package/dist/types/components/Toggle/index.d.ts +4 -4
- package/dist/types/components/TokenCounter/index.d.ts +2 -2
- package/dist/types/components/ToolCallCard/index.d.ts +2 -2
- package/dist/types/components/Toolbar/index.d.ts +8 -8
- package/dist/types/components/Tooltip/Tooltip.d.ts +26 -4
- package/dist/types/components/Tooltip/index.d.ts +2 -2
- package/dist/types/components/Tour/Tour.d.ts +1 -1
- package/dist/types/components/Tour/index.d.ts +2 -2
- package/dist/types/components/Trace/Trace.d.ts +37 -0
- package/dist/types/components/Trace/index.d.ts +2 -0
- package/dist/types/components/Transfer/Transfer.d.ts +1 -1
- package/dist/types/components/Transfer/index.d.ts +4 -4
- package/dist/types/components/Tree/SortableTree.d.ts +2 -2
- package/dist/types/components/Tree/Tree.d.ts +2 -2
- package/dist/types/components/Tree/TreeItem.d.ts +1 -1
- package/dist/types/components/Tree/index.d.ts +4 -4
- package/dist/types/components/Tree/sortable-tree-utils.d.ts +1 -1
- package/dist/types/components/Tree/types.d.ts +9 -1
- package/dist/types/components/Tree/utils.d.ts +1 -1
- package/dist/types/components/TreeSelect/TreeSelect.d.ts +1 -1
- package/dist/types/components/TreeSelect/index.d.ts +2 -2
- package/dist/types/components/Typography/index.d.ts +2 -2
- package/dist/types/components/Upload/Upload.d.ts +25 -2
- package/dist/types/components/Upload/UploadCore.d.ts +44 -3
- package/dist/types/components/Upload/UploadList.d.ts +16 -2
- package/dist/types/components/Upload/index.d.ts +5 -5
- package/dist/types/components/Upload/types.d.ts +28 -1
- package/dist/types/components/Upload/xhr-upload.d.ts +1 -1
- package/dist/types/components/VirtualList/index.d.ts +2 -2
- package/dist/types/components/VisuallyHidden/index.d.ts +2 -2
- package/dist/types/components/Watermark/index.d.ts +2 -2
- package/dist/types/components/Workbench/index.d.ts +2 -2
- package/dist/types/dates/buddhist.d.ts +1 -1
- package/dist/types/dates/ethiopic.d.ts +1 -1
- package/dist/types/dates/gregory.d.ts +1 -1
- package/dist/types/dates/hebrew.d.ts +1 -1
- package/dist/types/dates/index.d.ts +11 -11
- package/dist/types/dates/islamic.d.ts +1 -1
- package/dist/types/dates/japanese.d.ts +1 -1
- package/dist/types/dates/persian.d.ts +1 -1
- package/dist/types/dates/registry.d.ts +1 -1
- package/dist/types/form/FormItem.d.ts +38 -1
- package/dist/types/form/index.d.ts +17 -7
- package/dist/types/headless/index.d.ts +45 -40
- package/dist/types/hooks/index.d.ts +33 -33
- package/dist/types/hooks/useHotkeys.d.ts +16 -4
- package/dist/types/index.d.ts +351 -303
- package/dist/types/locales/index.d.ts +32 -0
- package/dist/types/tokens/colors.d.ts +15 -0
- package/dist/types/tokens/density.d.ts +1 -1
- package/dist/types/tokens/index.d.ts +11 -11
- package/dist/types/tokens/palette.d.ts +1 -1
- package/dist/types/tokens/registry.d.ts +1 -1
- package/dist/types/tokens/z-index.d.ts +33 -0
- package/dist/types/utils/floating.d.ts +1 -1
- package/dist/types/utils/native-form.d.ts +32 -0
- package/dist/types/utils/presence.d.ts +21 -2
- package/dist/types/utils/sortable-shared.d.ts +6 -0
- package/dist/types/utils/submenu.d.ts +1 -1
- package/dist/utils/direction.js +10 -8
- package/dist/utils/floating.js +227 -185
- package/dist/utils/focus-scope.js +27 -24
- package/dist/utils/menuRadio.js +23 -21
- package/dist/utils/native-form.js +42 -0
- package/dist/utils/presence.js +16 -12
- package/dist/utils/sortable-shared.js +12 -8
- package/dist/utils/sortable.js +55 -39
- package/dist/utils/submenu.js +94 -82
- package/dist/utils/view-transition.js +11 -13
- package/dist/utils/viewport.js +9 -8
- package/package.json +160 -11
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import type { ComponentPropsWithoutRef, Ref } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Heatmap — a GitHub-style activity calendar: week columns × weekday
|
|
4
|
+
* rows of squares, intensity-binned by value. Pure rendering from
|
|
5
|
+
* props (no hooks, RSC-safe): all i18n surface is label props
|
|
6
|
+
* (`getLabel` / `getMonthLabel` / `getWeekdayLabel` / `summary`)
|
|
7
|
+
* instead of LocaleProvider keys.
|
|
8
|
+
*
|
|
9
|
+
* Layout is one CSS grid: row 1 carries month labels (each spanning
|
|
10
|
+
* the week columns whose Saturday opens that month), column 1 the
|
|
11
|
+
* weekday labels, and every day square is placed by explicit
|
|
12
|
+
* gridRow/gridColumn — no nested wrappers, so labels and cells cannot
|
|
13
|
+
* drift apart. The date range aligns outward to full Sunday..Saturday
|
|
14
|
+
* weeks and defaults to the data's own extent.
|
|
15
|
+
*
|
|
16
|
+
* Accessibility: the calendar renders `role="img"` named by `summary`
|
|
17
|
+
* (one announcement for the whole graphic — screen readers would
|
|
18
|
+
* otherwise drown in hundreds of squares). Inside an image every child
|
|
19
|
+
* is presentational, so cells carry their `getLabel` text as a native
|
|
20
|
+
* `title` tooltip (and `data-date`/`data-level` for custom tooltip
|
|
21
|
+
* wiring) — an `aria-label` there would be swallowed by the img role
|
|
22
|
+
* and is prohibited on role-less elements besides.
|
|
23
|
+
*/
|
|
24
|
+
type HeatmapDatum = {
|
|
25
|
+
date: string;
|
|
26
|
+
value: number;
|
|
27
|
+
};
|
|
28
|
+
/**
|
|
29
|
+
* Semantic slot classes (AntD v6 `classNames` shape): keys mirror the
|
|
30
|
+
* data-slot values each part carries, appended after the component
|
|
31
|
+
* defaults so consumer classes can override them.
|
|
32
|
+
*/
|
|
33
|
+
type HeatmapClassNames = {
|
|
34
|
+
/** The grid root (`data-slot='heatmap'`). */
|
|
35
|
+
root?: string;
|
|
36
|
+
/** Every month label (`data-slot='month'`). */
|
|
37
|
+
month?: string;
|
|
38
|
+
/** Every weekday label (`data-slot='weekday'`). */
|
|
39
|
+
weekday?: string;
|
|
40
|
+
/** Every day square (`data-slot='cell'`). */
|
|
41
|
+
cell?: string;
|
|
42
|
+
};
|
|
43
|
+
type HeatmapProps = {
|
|
44
|
+
/** Activity data, one entry per `'YYYY-MM-DD'` date (later duplicates win). */
|
|
45
|
+
data?: HeatmapDatum[] | Record<string, number>;
|
|
46
|
+
/** Intensity bins above the empty level; default 4 (GitHub's scale). */
|
|
47
|
+
levels?: number;
|
|
48
|
+
/** First date of the range; defaults to the earliest datum. */
|
|
49
|
+
startDate?: string;
|
|
50
|
+
/** Last date of the range; defaults to the latest datum. */
|
|
51
|
+
endDate?: string;
|
|
52
|
+
/** Tooltip text of one day square (`title`, via `getLabel`). */
|
|
53
|
+
getLabel?: (datum: {
|
|
54
|
+
date: string;
|
|
55
|
+
value: number;
|
|
56
|
+
}) => string;
|
|
57
|
+
/** Month label for the week-group headers; defaults to English short names. */
|
|
58
|
+
getMonthLabel?: (month: number, year: number) => string;
|
|
59
|
+
/** Weekday label for row `weekday` (0 = Sunday); return '' to hide one. */
|
|
60
|
+
getWeekdayLabel?: (weekday: number) => string;
|
|
61
|
+
/** Accessible name of the whole calendar; default 'Activity heatmap'. */
|
|
62
|
+
summary?: string;
|
|
63
|
+
classNames?: HeatmapClassNames;
|
|
64
|
+
className?: string;
|
|
65
|
+
/** Forwarded to the grid root. */
|
|
66
|
+
ref?: Ref<HTMLDivElement>;
|
|
67
|
+
} & Omit<ComponentPropsWithoutRef<'div'>, 'children'>;
|
|
68
|
+
export default function Heatmap({ data, levels: levelsProp, startDate, endDate, getLabel, getMonthLabel, getWeekdayLabel, summary, classNames, className, style, ref, ...rest }: HeatmapProps): import("react").JSX.Element;
|
|
69
|
+
export type { HeatmapProps, HeatmapClassNames, HeatmapDatum };
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared Heatmap skin — the GitHub-style activity calendar chrome the
|
|
3
|
+
* `Heatmap` component wears. Living in its own module keeps the
|
|
4
|
+
* component file free of style internals (react-refresh boundary) and
|
|
5
|
+
* lets it register as RSC-safe (the module is hook-free and only
|
|
6
|
+
* re-exports Linaria constants). split-css groups the emitted CSS into
|
|
7
|
+
* `haze-ui/css/heatmap.css`.
|
|
8
|
+
*
|
|
9
|
+
* Intensity bins are a single class, not one class per level: every
|
|
10
|
+
* cell carries its own `--haze-heatmap-mix` percentage (inline style,
|
|
11
|
+
* level / levels · 100%) and the `color-mix()` background recomputes
|
|
12
|
+
* against whatever `--haze-color-primary` / `--haze-color-bg-subtle`
|
|
13
|
+
* resolve to — light, dark and brand-preset themes all follow for
|
|
14
|
+
* free, at any `levels` count, with zero per-level classes.
|
|
15
|
+
*/
|
|
16
|
+
/** The calendar grid: row 1 = month labels, rows 2-8 = Sun..Sat. */
|
|
17
|
+
export declare const heatmapBase: import("@linaria/core").LinariaClassName;
|
|
18
|
+
/** A month label spanning its week columns along the top row. */
|
|
19
|
+
export declare const heatmapMonth: import("@linaria/core").LinariaClassName;
|
|
20
|
+
/** The Sun..Sat gutter labels down the first column. */
|
|
21
|
+
export declare const heatmapWeekday: import("@linaria/core").LinariaClassName;
|
|
22
|
+
/** One day square; `data-level` carries the bin, the mix % the tint. */
|
|
23
|
+
export declare const heatmapCell: import("@linaria/core").LinariaClassName;
|
|
24
|
+
/** Dates with no activity (or value 0) — the flat faint square. */
|
|
25
|
+
export declare const heatmapCellEmpty: import("@linaria/core").LinariaClassName;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { default as Highlight } from './Highlight';
|
|
2
|
-
export type { HighlightProps } from './Highlight';
|
|
1
|
+
export { default as Highlight } from './Highlight.js';
|
|
2
|
+
export type { HighlightProps } from './Highlight.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
2
|
import type { ControlOrValue } from 'react-use-control';
|
|
3
|
-
import type { CollisionPadding } from '../../utils/collision';
|
|
4
|
-
import type { FloatingPlacement } from '../../utils/floating';
|
|
3
|
+
import type { CollisionPadding } from '../../utils/collision.js';
|
|
4
|
+
import type { FloatingPlacement } from '../../utils/floating.js';
|
|
5
5
|
/**
|
|
6
6
|
* HoverCard — a non-modal floating preview (avatar card, link summary)
|
|
7
7
|
* anchored to its trigger.
|
|
@@ -20,6 +20,10 @@ import type { FloatingPlacement } from '../../utils/floating';
|
|
|
20
20
|
* the panel cancels the pending close (the "resting zone"). Escape
|
|
21
21
|
* closes at once (native popover light dismiss / the fallback path's
|
|
22
22
|
* document keydown, both owned by useFloating).
|
|
23
|
+
*
|
|
24
|
+
* `interactive` upgrades the card to React Aria's PreviewTrigger
|
|
25
|
+
* semantics: focusable content, focus handoff trigger ↔ card, Escape
|
|
26
|
+
* returning focus to the trigger — see the prop for the contract.
|
|
23
27
|
*/
|
|
24
28
|
type HoverCardProps = {
|
|
25
29
|
/** Card content, rendered inside the floating panel. */
|
|
@@ -31,6 +35,19 @@ type HoverCardProps = {
|
|
|
31
35
|
* before the card closes — long enough to travel into the panel.
|
|
32
36
|
*/
|
|
33
37
|
closeDelay?: number;
|
|
38
|
+
/**
|
|
39
|
+
* Interactive card contents (React Aria PreviewTrigger semantics):
|
|
40
|
+
* focusable elements inside `content` join the Tab order and focus
|
|
41
|
+
* may travel between the trigger and the card without closing it.
|
|
42
|
+
* The pointer grace after leaving the trigger/panel defaults to
|
|
43
|
+
* 300 ms in this mode (vs 120 ms otherwise; an explicit `closeDelay`
|
|
44
|
+
* or a ConfigProvider default still overrides). While focus rests
|
|
45
|
+
* inside the card, pointer leaves alone no longer close it — Escape
|
|
46
|
+
* or tabbing out does, and Escape hands focus back to the trigger.
|
|
47
|
+
* Focus is deliberately NOT trapped: a hover card is a preview, not
|
|
48
|
+
* a modal, so Tab must keep reaching the rest of the page.
|
|
49
|
+
*/
|
|
50
|
+
interactive?: boolean;
|
|
34
51
|
/**
|
|
35
52
|
* Panel placement relative to the trigger, in the floating utils'
|
|
36
53
|
* physical convention ('bottom-span' aligns the panel's inline-start
|
|
@@ -45,5 +62,5 @@ type HoverCardProps = {
|
|
|
45
62
|
/** The trigger — render a focusable element for keyboard access. */
|
|
46
63
|
children: ReactNode;
|
|
47
64
|
};
|
|
48
|
-
export default function HoverCard({ content, openDelay: openDelayProp, closeDelay: closeDelayProp, placement, open: openControl, collisionPadding, className, children, }: HoverCardProps): import("react").JSX.Element;
|
|
65
|
+
export default function HoverCard({ content, openDelay: openDelayProp, closeDelay: closeDelayProp, interactive, placement, open: openControl, collisionPadding, className, children, }: HoverCardProps): import("react").JSX.Element;
|
|
49
66
|
export type { HoverCardProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { default as HoverCard } from './HoverCard';
|
|
2
|
-
export type { HoverCardProps } from './HoverCard';
|
|
1
|
+
export { default as HoverCard } from './HoverCard.js';
|
|
2
|
+
export type { HoverCardProps } from './HoverCard.js';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { default as Icon } from './Icon';
|
|
2
|
-
export type { IconProps } from './Icon';
|
|
1
|
+
export { default as Icon } from './Icon.js';
|
|
2
|
+
export type { IconProps } from './Icon.js';
|
|
@@ -19,6 +19,10 @@ type ImageProps = {
|
|
|
19
19
|
* rendering and behavior are unchanged). `true` turns on every control;
|
|
20
20
|
* an object opts out per control: `zoom: false` drops the zoom
|
|
21
21
|
* buttons, wheel zoom and drag pan, `rotate: false` the rotate button.
|
|
22
|
+
*
|
|
23
|
+
* Inside an `ImagePreviewGroup` this prop only opts the image in or
|
|
24
|
+
* out of the shared gallery: clicking delegates to the group's single
|
|
25
|
+
* overlay, and the group's own `preview` config governs its controls.
|
|
22
26
|
*/
|
|
23
27
|
preview?: boolean | ImagePreviewConfig;
|
|
24
28
|
} & Omit<ComponentPropsWithoutRef<'img'>, 'src' | 'alt'>;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Registration protocol between `ImagePreviewGroup` and the `Image`
|
|
3
|
+
* children rendered inside it (AntD `Image.PreviewGroup` shape): each
|
|
4
|
+
* child with `preview` enabled contributes its `src`/`alt` to the
|
|
5
|
+
* shared gallery and delegates its click to the group's single overlay
|
|
6
|
+
* instead of opening one of its own.
|
|
7
|
+
*/
|
|
8
|
+
/** What a child `<Image preview>` contributes to the shared gallery. */
|
|
9
|
+
export type GalleryImage = {
|
|
10
|
+
src: string;
|
|
11
|
+
alt: string;
|
|
12
|
+
};
|
|
13
|
+
type ImageGalleryContextValue = {
|
|
14
|
+
/**
|
|
15
|
+
* False while the group runs `preview={false}` — children stay inert
|
|
16
|
+
* (no registration, no click behavior) instead of falling back to
|
|
17
|
+
* their own single-image overlays.
|
|
18
|
+
*/
|
|
19
|
+
enabled: boolean;
|
|
20
|
+
/** Adds an entry, returns the id used to unregister/activate it. */
|
|
21
|
+
register: (image: GalleryImage) => number;
|
|
22
|
+
unregister: (id: number) => void;
|
|
23
|
+
/** Opens the shared overlay on the entry with this id. */
|
|
24
|
+
activate: (id: number) => void;
|
|
25
|
+
};
|
|
26
|
+
export declare const ImageGalleryProvider: import("react").Provider<ImageGalleryContextValue | null>;
|
|
27
|
+
/** The enclosing gallery, or null outside an `ImagePreviewGroup`. */
|
|
28
|
+
export declare function useImageGallery(): ImageGalleryContextValue | null;
|
|
29
|
+
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { ControlOrValue } from 'react-use-control';
|
|
2
|
+
import type { GalleryImage } from './ImageGalleryContext.js';
|
|
2
3
|
type ImagePreviewProps = {
|
|
3
4
|
src: string;
|
|
4
5
|
alt: string;
|
|
@@ -8,6 +9,19 @@ type ImagePreviewProps = {
|
|
|
8
9
|
zoom?: boolean;
|
|
9
10
|
/** The rotate control is available (default true). */
|
|
10
11
|
rotate?: boolean;
|
|
12
|
+
/**
|
|
13
|
+
* Gallery entries, handed over by ImagePreviewGroup. Two or more
|
|
14
|
+
* switch the overlay into gallery mode: prev/next arrows flanking the
|
|
15
|
+
* image, an `n / total` counter in the toolbar, ArrowLeft/ArrowRight
|
|
16
|
+
* keys (wrap-around at both ends) and — unless `showThumbnails` is
|
|
17
|
+
* false — a keyboard-focusable thumbnail strip that stays in sync
|
|
18
|
+
* with the active entry.
|
|
19
|
+
*/
|
|
20
|
+
images?: readonly GalleryImage[];
|
|
21
|
+
/** Active gallery entry, shared with the group (defaults to 0). */
|
|
22
|
+
index?: ControlOrValue<number>;
|
|
23
|
+
/** The thumbnail strip is rendered in gallery mode (default true). */
|
|
24
|
+
showThumbnails?: boolean;
|
|
11
25
|
};
|
|
12
|
-
export default function ImagePreview({ src, alt, open: openControl, zoom, rotate, }: ImagePreviewProps): import("react").JSX.Element;
|
|
26
|
+
export default function ImagePreview({ src, alt, open: openControl, zoom, rotate, images, index: indexControl, showThumbnails, }: ImagePreviewProps): import("react").JSX.Element;
|
|
13
27
|
export type { ImagePreviewProps };
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { ControlOrValue } from 'react-use-control';
|
|
3
|
+
import type { ImagePreviewConfig } from './Image.js';
|
|
4
|
+
type ImagePreviewGroupProps = {
|
|
5
|
+
children: ReactNode;
|
|
6
|
+
/**
|
|
7
|
+
* The gallery's active image. A plain number is the uncontrolled
|
|
8
|
+
* starting position; pass a control to drive navigation from the
|
|
9
|
+
* outside (thumbnail clicks, arrows and keys all commit through it).
|
|
10
|
+
*/
|
|
11
|
+
index?: ControlOrValue<number>;
|
|
12
|
+
/**
|
|
13
|
+
* Shared overlay configuration, same shape as Image's `preview` prop:
|
|
14
|
+
* `true` (default) turns on every control, an object opts out per
|
|
15
|
+
* control (`zoom: false`, `rotate: false`), `false` disables the
|
|
16
|
+
* overlay for every child.
|
|
17
|
+
*/
|
|
18
|
+
preview?: boolean | ImagePreviewConfig;
|
|
19
|
+
/** The thumbnail strip is rendered (default true). */
|
|
20
|
+
showThumbnails?: boolean;
|
|
21
|
+
};
|
|
22
|
+
export default function ImagePreviewGroup({ children, index: indexControl, preview, showThumbnails, }: ImagePreviewGroupProps): import("react").JSX.Element;
|
|
23
|
+
export type { ImagePreviewGroupProps };
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export { default as Image } from './Image';
|
|
2
|
-
export
|
|
1
|
+
export { default as Image } from './Image.js';
|
|
2
|
+
export { default as ImagePreviewGroup } from './ImagePreviewGroup.js';
|
|
3
|
+
export type { ImageProps, ImagePreviewConfig } from './Image.js';
|
|
4
|
+
export type { ImagePreviewGroupProps } from './ImagePreviewGroup.js';
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import type { ComponentPropsWithoutRef, Ref } from 'react';
|
|
2
|
+
import type { ControlOrValue } from 'react-use-control';
|
|
3
|
+
import type { CropRect } from './image-crop-geometry.js';
|
|
4
|
+
/**
|
|
5
|
+
* Interactive image cropper — the avatar/photo companion to Upload.
|
|
6
|
+
*
|
|
7
|
+
* The source image is painted onto a `<canvas>` sized to its natural
|
|
8
|
+
* pixels (max detail; CSS scales it down), and the crop box is a DOM
|
|
9
|
+
* overlay positioned in percentages of the same box, so `value` needs no
|
|
10
|
+
* pixel measurement to render. `value` is the crop rectangle normalized
|
|
11
|
+
* to the image (every field 0..1) and fully controllable; every commit
|
|
12
|
+
* path (drag, handle resize, keyboard) runs through the same clamp
|
|
13
|
+
* pipeline, so an illegal rect can never display.
|
|
14
|
+
*
|
|
15
|
+
* Keyboard (the part competitors skip): the crop box is focusable and
|
|
16
|
+
* labeled. Arrow keys move it (1% of the image per press), Shift + arrow
|
|
17
|
+
* keys resize it — the Resizable handle's pointer-free contract in
|
|
18
|
+
* normalized space. A `visually-hidden` description announces the live
|
|
19
|
+
* geometry so screen readers track drags too.
|
|
20
|
+
*
|
|
21
|
+
* `ref.getCroppedCanvas()` rasterizes the current crop into a fresh
|
|
22
|
+
* `HTMLCanvasElement` (`null` when the image has not loaded or the 2d
|
|
23
|
+
* context is unavailable — jsdom without a mock). When the 2d context is
|
|
24
|
+
* unavailable the whole cropper degrades to a notice (Signature
|
|
25
|
+
* precedent): without paint there is no image to crop.
|
|
26
|
+
*/
|
|
27
|
+
type ImageCropProps = {
|
|
28
|
+
/** Image source URL. */
|
|
29
|
+
src: string;
|
|
30
|
+
/** Accessible name of the rendered image (carried by the canvas). */
|
|
31
|
+
alt: string;
|
|
32
|
+
/** Crop rectangle normalized to the image (every field 0..1); a
|
|
33
|
+
* Control receives every commit live, a plain object seeds it. */
|
|
34
|
+
value?: ControlOrValue<CropRect>;
|
|
35
|
+
/** Fires with the new normalized rect on every pointer frame and
|
|
36
|
+
* keyboard step. */
|
|
37
|
+
onChange?: (rect: CropRect) => void;
|
|
38
|
+
/** Locks the crop's pixel-space aspect ratio (width / height, e.g. `1`
|
|
39
|
+
* for avatars). Height derives from width; a rect that cannot fit
|
|
40
|
+
* refits from its height budget. */
|
|
41
|
+
aspect?: number;
|
|
42
|
+
/** Overlay mask of the crop box: rectangular frame or a full-radius
|
|
43
|
+
* circle for avatars (pair with `aspect={1}` for a true circle). */
|
|
44
|
+
shape?: 'rect' | 'circle';
|
|
45
|
+
/** Accessible label of the focusable crop region. */
|
|
46
|
+
cropLabel?: string;
|
|
47
|
+
/** Notice rendered when the canvas 2d context is unavailable. */
|
|
48
|
+
unsupportedLabel?: string;
|
|
49
|
+
/** Notice rendered when `src` fails to load. */
|
|
50
|
+
errorLabel?: string;
|
|
51
|
+
/** Locks dragging, handle resizing and keyboard operation. */
|
|
52
|
+
disabled?: boolean;
|
|
53
|
+
/** Passed to the loader `<img>`; `anonymous` is required for
|
|
54
|
+
* CORS-clean hosts or `getCroppedCanvas` output stays tainted. */
|
|
55
|
+
crossOrigin?: 'anonymous' | 'use-credentials';
|
|
56
|
+
className?: string;
|
|
57
|
+
ref?: Ref<ImageCropHandle>;
|
|
58
|
+
} & Omit<ComponentPropsWithoutRef<'div'>, 'onChange'>;
|
|
59
|
+
/** Imperative surface exposed through the component `ref`. */
|
|
60
|
+
type ImageCropHandle = {
|
|
61
|
+
/** Fresh canvas holding the current crop at native pixel resolution,
|
|
62
|
+
* or `null` when the image has not loaded / 2d context is missing. */
|
|
63
|
+
getCroppedCanvas: () => HTMLCanvasElement | null;
|
|
64
|
+
};
|
|
65
|
+
export default function ImageCrop({ src, alt, value: valueControl, onChange, aspect, shape, cropLabel, unsupportedLabel, errorLabel, disabled, crossOrigin, className, ref, ...rest }: ImageCropProps): import("react").JSX.Element;
|
|
66
|
+
export type { ImageCropProps, ImageCropHandle };
|
|
67
|
+
export type { CropRect } from './image-crop-geometry.js';
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Pure geometry for ImageCrop — every exported helper works in normalized
|
|
3
|
+
* space (0..1 relative to the image's own pixel box) so pointer, keyboard
|
|
4
|
+
* and aspect math share one clamp story. Unit tests exercise these
|
|
5
|
+
* directly (the signature-points precedent).
|
|
6
|
+
*/
|
|
7
|
+
/** Normalized crop rectangle: top-left corner (x, y) and size, every
|
|
8
|
+
* field 0..1 relative to the image's own pixel box. */
|
|
9
|
+
export type CropRect = {
|
|
10
|
+
x: number;
|
|
11
|
+
y: number;
|
|
12
|
+
width: number;
|
|
13
|
+
height: number;
|
|
14
|
+
};
|
|
15
|
+
/** Natural pixel size of the loaded source image. */
|
|
16
|
+
export type NaturalSize = {
|
|
17
|
+
width: number;
|
|
18
|
+
height: number;
|
|
19
|
+
};
|
|
20
|
+
/** Corner handles of the crop box. */
|
|
21
|
+
export type CropCorner = 'nw' | 'ne' | 'sw' | 'se';
|
|
22
|
+
/** Size floor for the crop box on both axes — a box smaller than this is
|
|
23
|
+
* no longer grabbable and crops to a degenerate image. */
|
|
24
|
+
export declare const MIN_CROP = 0.05;
|
|
25
|
+
/** Keyboard step for arrow keys: 1% of the image per press (the Resizable
|
|
26
|
+
* handle's fully-pointer-free contract, scaled to normalized space). */
|
|
27
|
+
export declare const KEYBOARD_STEP = 0.01;
|
|
28
|
+
/** Fit a rect to a locked pixel-space aspect ratio. Width drives; when
|
|
29
|
+
* the derived height overflows the unit square the height clamps to 1
|
|
30
|
+
* and the width re-derives from it. Position keeps x/y, clamped so the
|
|
31
|
+
* box stays inside the image. */
|
|
32
|
+
export declare function fitAspect(rect: CropRect, aspect: number, natural: NaturalSize): CropRect;
|
|
33
|
+
/** Clamp any rect into a legal crop: sizes into [MIN_CROP, 1] — with an
|
|
34
|
+
* aspect refit when the ratio is locked — and the position so the box
|
|
35
|
+
* stays inside the unit square. Display and every commit path run
|
|
36
|
+
* through this, so a stale or consumer-supplied value can never paint an
|
|
37
|
+
* illegal box. */
|
|
38
|
+
export declare function normalizeRect(rect: CropRect, aspect: number | undefined, natural: NaturalSize): CropRect;
|
|
39
|
+
/** Centered default crop covering 80% of the image (aspect-refit first —
|
|
40
|
+
* a square crop of a wide image saturates height before width, then the
|
|
41
|
+
* smaller box recenters). */
|
|
42
|
+
export declare function defaultRect(aspect: number | undefined, natural: NaturalSize): CropRect;
|
|
43
|
+
/** Translate by (dx, dy) — position clamps inside the image, size is
|
|
44
|
+
* frozen (the keyboard move contract). */
|
|
45
|
+
export declare function moveRect(rect: CropRect, dx: number, dy: number): CropRect;
|
|
46
|
+
/** Keyboard resize anchored at the top-left corner: dw/dh grow the box
|
|
47
|
+
* towards the right/bottom. With a locked aspect both axes drive the
|
|
48
|
+
* shared width (dh is translated through the aspect factor), so all four
|
|
49
|
+
* Shift+arrow keys stay functional. */
|
|
50
|
+
export declare function resizeRect(rect: CropRect, dw: number, dh: number, aspect: number | undefined, natural: NaturalSize): CropRect;
|
|
51
|
+
/** Corner-handle resize: the opposite corner stays anchored and the
|
|
52
|
+
* dragged corner follows the normalized pointer. Dragging across the
|
|
53
|
+
* anchor floors at MIN_CROP instead of inverting; a locked aspect fits
|
|
54
|
+
* width-first, clamped to the space the anchor leaves. */
|
|
55
|
+
export declare function resizeFromAnchor(start: CropRect, corner: CropCorner, pointer: {
|
|
56
|
+
x: number;
|
|
57
|
+
y: number;
|
|
58
|
+
}, aspect: number | undefined, natural: NaturalSize): CropRect;
|
|
59
|
+
/** Frame-relative normalized pointer position from client coordinates.
|
|
60
|
+
* The width/height guards keep a zero-sized rect (jsdom, not-yet-laid-out
|
|
61
|
+
* frames) from producing NaN instead of merely useless numbers. */
|
|
62
|
+
export declare function pointerToNormalized(clientX: number, clientY: number, frame: DOMRect): {
|
|
63
|
+
x: number;
|
|
64
|
+
y: number;
|
|
65
|
+
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { default as Indicator } from './Indicator';
|
|
2
|
-
export type { IndicatorProps } from './Indicator';
|
|
1
|
+
export { default as Indicator } from './Indicator.js';
|
|
2
|
+
export type { IndicatorProps } from './Indicator.js';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
2
|
+
import type { ControlOrValue } from 'react-use-control';
|
|
3
|
+
type InlineCitationProps = {
|
|
4
|
+
/** Citation number shown in the badge and card header. */
|
|
5
|
+
index?: number;
|
|
6
|
+
/** When present the card title becomes an external link (new tab). */
|
|
7
|
+
href?: string;
|
|
8
|
+
/** Source title rendered in the card; links out when `href` is set. */
|
|
9
|
+
title?: ReactNode;
|
|
10
|
+
/** Excerpt quoted from the source, rendered under the title. */
|
|
11
|
+
snippet?: ReactNode;
|
|
12
|
+
/** Controllable open state of the source card. */
|
|
13
|
+
open?: ControlOrValue<boolean>;
|
|
14
|
+
className?: string;
|
|
15
|
+
} & Omit<ComponentPropsWithoutRef<'span'>, 'title' | 'children'>;
|
|
16
|
+
export default function InlineCitation({ index, href, title, snippet, open: openControl, className, ...rest }: InlineCitationProps): import("react").JSX.Element;
|
|
17
|
+
export type { InlineCitationProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { default as InlineCompletion } from './InlineCompletion';
|
|
2
|
-
export type { InlineCompletionProps } from './InlineCompletion';
|
|
1
|
+
export { default as InlineCompletion } from './InlineCompletion.js';
|
|
2
|
+
export type { InlineCompletionProps } from './InlineCompletion.js';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { default as InlineEdit } from './InlineEdit';
|
|
2
|
-
export type { InlineEditProps } from './InlineEdit';
|
|
1
|
+
export { default as InlineEdit } from './InlineEdit.js';
|
|
2
|
+
export type { InlineEditProps } from './InlineEdit.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { default as Input } from './Input';
|
|
2
|
-
export type { InputProps } from './Input';
|
|
3
|
-
export { default as InputCore } from './InputCore';
|
|
4
|
-
export type { InputCoreProps } from './InputCore';
|
|
1
|
+
export { default as Input } from './Input.js';
|
|
2
|
+
export type { InputProps } from './Input.js';
|
|
3
|
+
export { default as InputCore } from './InputCore.js';
|
|
4
|
+
export type { InputCoreProps } from './InputCore.js';
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared Input size skin — the per-size padding/typography classes the
|
|
3
|
+
* `InputCore` component wears (the `Input` sugar delegates to it).
|
|
4
|
+
* Living in their own module keeps the component file free of style
|
|
5
|
+
* internals (react-refresh boundary) and lets the size map ship as a
|
|
6
|
+
* public constant for consumers and tests asserting the ConfigProvider
|
|
7
|
+
* `Input.size` tier (the shadcn `buttonVariants` / NumberInput
|
|
8
|
+
* `inputSizes` precedent); split-css groups the module with the Input
|
|
9
|
+
* family's css.
|
|
10
|
+
*/
|
|
11
|
+
export declare const sizes: {
|
|
12
|
+
readonly sm: import("@linaria/core").LinariaClassName;
|
|
13
|
+
readonly md: import("@linaria/core").LinariaClassName;
|
|
14
|
+
readonly lg: import("@linaria/core").LinariaClassName;
|
|
15
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import type { ComponentPropsWithoutRef, ReactNode, Ref } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Semantic slot classes for InputGroup (AntD v6 `classNames` shape;
|
|
4
|
+
* keys follow the data-slot names). The `addon` slot is inherited by
|
|
5
|
+
* every InputGroupAddon child through context, so addons are re-skinned
|
|
6
|
+
* once on the group.
|
|
7
|
+
*/
|
|
8
|
+
type InputGroupClassNames = {
|
|
9
|
+
/** The wrapper (data-slot='input-group'). */
|
|
10
|
+
root?: string;
|
|
11
|
+
/** Every addon (data-slot='addon'). */
|
|
12
|
+
addon?: string;
|
|
13
|
+
};
|
|
14
|
+
type InputGroupOwnProps = {
|
|
15
|
+
/** Group-wide size: the size every child field that accepts one
|
|
16
|
+
* wears unless it sets its own, and the size the addons take —
|
|
17
|
+
* mirrors Input's steps so row edges align. */
|
|
18
|
+
size?: 'sm' | 'md' | 'lg';
|
|
19
|
+
/** Slot classes (see {@link InputGroupClassNames}); `addon` is
|
|
20
|
+
* inherited by InputGroupAddon children. */
|
|
21
|
+
classNames?: InputGroupClassNames;
|
|
22
|
+
};
|
|
23
|
+
type InputGroupProps = InputGroupOwnProps & {
|
|
24
|
+
/** The cluster's fields and addons — `Input`/`Select` children with
|
|
25
|
+
* `InputGroupAddon` (and optionally a trailing `Button`) around
|
|
26
|
+
* them. The group fills in `size` where a child leaves it unset;
|
|
27
|
+
* non-element nodes pass through untouched. */
|
|
28
|
+
children: ReactNode;
|
|
29
|
+
className?: string;
|
|
30
|
+
/** Forwarded to the wrapper `<div>` (data-slot='input-group'). */
|
|
31
|
+
ref?: Ref<HTMLDivElement>;
|
|
32
|
+
} & Omit<ComponentPropsWithoutRef<'div'>, keyof InputGroupOwnProps | 'className' | 'children'>;
|
|
33
|
+
/**
|
|
34
|
+
* A field cluster: prefix/suffix addons (`InputGroupAddon` — icon,
|
|
35
|
+
* text) hugging an `Input`, `Select` or textarea-based field, all
|
|
36
|
+
* merged into one attached control via CSS on the wrapper (corner
|
|
37
|
+
* radii and seam borders collapse positionally — children render
|
|
38
|
+
* as-authored). A trailing `Button` child attaches the same way, which
|
|
39
|
+
* is the classic search-box shape.
|
|
40
|
+
*
|
|
41
|
+
* The composition layer keeps zero state: the field's value stays
|
|
42
|
+
* controlled/uncontrolled exactly as the field itself defines it, and
|
|
43
|
+
* every part stays individually focusable with its own accessible
|
|
44
|
+
* name — label the field, not the wrapper.
|
|
45
|
+
*/
|
|
46
|
+
export default function InputGroup({ size, classNames, className, children, ref, ...rest }: InputGroupProps): import("react").JSX.Element;
|
|
47
|
+
export type { InputGroupClassNames, InputGroupProps };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
2
|
+
type InputGroupAddonProps = {
|
|
3
|
+
/** Addon content — an icon, a text prefix/suffix ("https://", a
|
|
4
|
+
* currency glyph), any inline node. Text stays in the accessibility
|
|
5
|
+
* tree: it is often the field's semantic prefix, so the addon is
|
|
6
|
+
* never aria-hidden as a whole; wrap purely decorative icons in
|
|
7
|
+
* aria-hidden yourself. */
|
|
8
|
+
children?: ReactNode;
|
|
9
|
+
/** Own size — defaults to the enclosing InputGroup's size. */
|
|
10
|
+
size?: 'sm' | 'md' | 'lg';
|
|
11
|
+
className?: string;
|
|
12
|
+
} & Omit<ComponentPropsWithoutRef<'span'>, 'children' | 'size' | 'className'>;
|
|
13
|
+
/**
|
|
14
|
+
* The tinted cell attached to a field's leading or trailing edge —
|
|
15
|
+
* placement is positional (render it before or after the field), and
|
|
16
|
+
* the group's merging rules round the outer corner and suppress the
|
|
17
|
+
* inner one on whichever side it lands. Non-interactive by design: it
|
|
18
|
+
* is a label surface, not a control; a clickable tail belongs in the
|
|
19
|
+
* group as a `Button` child.
|
|
20
|
+
*/
|
|
21
|
+
export default function InputGroupAddon({ children, size, className, ...rest }: InputGroupAddonProps): import("react").JSX.Element;
|
|
22
|
+
export type { InputGroupAddonProps };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What an InputGroup hands down to its subtree: the group's resolved
|
|
3
|
+
* `size` and the inherited `classNames.addon` slot. `InputGroupAddon`
|
|
4
|
+
* consumes it; field children (`Input`, `Select`, …) pick the size up
|
|
5
|
+
* through prop injection instead — they are not wired to this context.
|
|
6
|
+
*/
|
|
7
|
+
type InputGroupValue = {
|
|
8
|
+
size: 'sm' | 'md' | 'lg';
|
|
9
|
+
/** The group's `classNames.addon` slot, inherited by every
|
|
10
|
+
* InputGroupAddon child (TagGroup's item-slot precedent). */
|
|
11
|
+
addonClass?: string;
|
|
12
|
+
};
|
|
13
|
+
declare const InputGroupContext: import("react").Context<InputGroupValue | undefined>;
|
|
14
|
+
declare const InputGroupProvider: import("react").Provider<InputGroupValue | undefined>;
|
|
15
|
+
/**
|
|
16
|
+
* Reads the enclosing InputGroup's resolved size. Returns `undefined`
|
|
17
|
+
* outside a group (a standalone InputGroupAddon falls back to `md`).
|
|
18
|
+
*/
|
|
19
|
+
declare function useInputGroup(): InputGroupValue | undefined;
|
|
20
|
+
export { InputGroupContext, InputGroupProvider, useInputGroup };
|
|
21
|
+
export type { InputGroupValue };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { default as InputGroup } from './InputGroup.js';
|
|
2
|
+
export type { InputGroupProps, InputGroupClassNames } from './InputGroup.js';
|
|
3
|
+
export { default as InputGroupAddon } from './InputGroupAddon.js';
|
|
4
|
+
export type { InputGroupAddonProps } from './InputGroupAddon.js';
|
|
5
|
+
export { useInputGroup } from './InputGroupContext.js';
|
|
6
|
+
export type { InputGroupValue } from './InputGroupContext.js';
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared InputGroup skin — the attached-field merging rules the group
|
|
3
|
+
* wrapper wears, plus the addon classes `InputGroupAddon` applies.
|
|
4
|
+
* Living in its own module keeps the component files free of style
|
|
5
|
+
* internals (react-refresh boundary); split-css groups the emitted CSS
|
|
6
|
+
* into `haze-ui/css/input-group.css`.
|
|
7
|
+
*
|
|
8
|
+
* ## Merging model
|
|
9
|
+
*
|
|
10
|
+
* Same recipe as ButtonGroup, applied to a field row: every child
|
|
11
|
+
* except the first loses its leading edge (a -1px margin pulls it over
|
|
12
|
+
* the previous child's trailing border and its leading border turns
|
|
13
|
+
* transparent, so exactly one 1px seam paints) and every child except
|
|
14
|
+
* the last loses its trailing corner radii. Addons therefore attach to
|
|
15
|
+
* `Input`/`Select`/`Button` children without either side knowing about
|
|
16
|
+
* the other — the children render as-authored.
|
|
17
|
+
*
|
|
18
|
+
* Sizing mirrors `InputCore`'s per-size paddings (see addonSizes), so
|
|
19
|
+
* an addon and the field it hugs are the same height at every step.
|
|
20
|
+
*/
|
|
21
|
+
export declare const group: import("@linaria/core").LinariaClassName;
|
|
22
|
+
/**
|
|
23
|
+
* The addon surface: a tinted, bordered cell distinct from the field,
|
|
24
|
+
* sized by its own paddings (addonSizes) so text/icons align with the
|
|
25
|
+
* field's content box. Corner rounding is positional — the group's
|
|
26
|
+
* merging rules keep the outer edges rounded and suppress the inner
|
|
27
|
+
* ones, whatever side the addon sits on.
|
|
28
|
+
*/
|
|
29
|
+
export declare const addon: import("@linaria/core").LinariaClassName;
|
|
30
|
+
export declare const addonSizes: {
|
|
31
|
+
readonly sm: import("@linaria/core").LinariaClassName;
|
|
32
|
+
readonly md: import("@linaria/core").LinariaClassName;
|
|
33
|
+
readonly lg: import("@linaria/core").LinariaClassName;
|
|
34
|
+
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { default as JsonView } from './JsonView';
|
|
2
|
-
export type { JsonViewProps, MoreLabelFn } from './JsonView';
|
|
1
|
+
export { default as JsonView } from './JsonView.js';
|
|
2
|
+
export type { JsonViewProps, MoreLabelFn } from './JsonView.js';
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
import type { ComponentPropsWithoutRef } from 'react';
|
|
1
|
+
import type { ComponentPropsWithoutRef, Ref } from 'react';
|
|
2
2
|
type KbdProps = {
|
|
3
3
|
size?: 'sm' | 'md';
|
|
4
|
+
/** Forwarded to the root kbd element (data-slot='kbd'). */
|
|
5
|
+
ref?: Ref<HTMLElement>;
|
|
4
6
|
} & Omit<ComponentPropsWithoutRef<'kbd'>, 'size'>;
|
|
5
|
-
export default function Kbd({ size, className, ...rest }: KbdProps): import("react").JSX.Element;
|
|
7
|
+
export default function Kbd({ size, className, ref, ...rest }: KbdProps): import("react").JSX.Element;
|
|
6
8
|
export type { KbdProps };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { default as Kbd } from './Kbd';
|
|
2
|
-
export type { KbdProps } from './Kbd';
|
|
1
|
+
export { default as Kbd } from './Kbd.js';
|
|
2
|
+
export type { KbdProps } from './Kbd.js';
|