@baseline-ui/core 0.58.0 → 0.60.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Acknowledgements.md +6165 -13146
- package/dist/components/Accordion/Accordion.css.d.ts +44 -0
- package/dist/components/Accordion/Accordion.d.ts +11 -0
- package/dist/components/Accordion/Accordion.types.d.ts +70 -0
- package/dist/components/Accordion/AccordionBase.d.ts +5 -0
- package/dist/components/Accordion/AccordionHeader.d.ts +6 -0
- package/dist/components/Accordion/AccordionItem.d.ts +3 -0
- package/dist/components/Accordion/index.d.ts +3 -0
- package/dist/components/ActionButton/ActionButton.css.d.ts +216 -0
- package/dist/components/ActionButton/ActionButton.d.ts +4 -0
- package/dist/components/ActionButton/ActionButton.types.d.ts +44 -0
- package/dist/components/ActionButton/index.d.ts +2 -0
- package/dist/components/ActionGroup/ActionGroup.css.d.ts +2 -0
- package/dist/components/ActionGroup/ActionGroup.d.ts +11 -0
- package/dist/components/ActionGroup/ActionGroup.types.d.ts +43 -0
- package/dist/components/ActionGroup/index.d.ts +3 -0
- package/dist/components/ActionIconButton/ActionIconButton.css.d.ts +116 -0
- package/dist/components/ActionIconButton/ActionIconButton.d.ts +3 -0
- package/dist/components/ActionIconButton/ActionIconButton.types.d.ts +56 -0
- package/dist/components/ActionIconButton/index.d.ts +2 -0
- package/dist/components/Actionable/Actionable.css.d.ts +2 -0
- package/dist/components/Actionable/Actionable.d.ts +3 -0
- package/dist/components/Actionable/Actionable.types.d.ts +15 -0
- package/dist/components/Actionable/index.d.ts +3 -0
- package/dist/components/AlertDialog/AlertDialog.css.d.ts +26 -0
- package/dist/components/AlertDialog/AlertDialog.d.ts +3 -0
- package/dist/components/AlertDialog/AlertDialog.types.d.ts +77 -0
- package/dist/components/AlertDialog/index.d.ts +3 -0
- package/dist/components/AudioPlayer/AudioPlayer.css.d.ts +3 -0
- package/dist/components/AudioPlayer/AudioPlayer.d.ts +3 -0
- package/dist/components/AudioPlayer/AudioPlayer.types.d.ts +27 -0
- package/dist/components/AudioPlayer/index.d.ts +3 -0
- package/dist/components/Avatar/Avatar.css.d.ts +19 -0
- package/dist/components/Avatar/Avatar.d.ts +3 -0
- package/dist/components/Avatar/Avatar.types.d.ts +31 -0
- package/dist/components/Avatar/index.d.ts +2 -0
- package/dist/components/Box/Box.d.ts +3 -0
- package/dist/components/Box/Box.types.d.ts +12 -0
- package/dist/components/Box/index.d.ts +3 -0
- package/dist/components/ButtonSelect/ButtonSelect.css.d.ts +3 -0
- package/dist/components/ButtonSelect/ButtonSelect.d.ts +3 -0
- package/dist/components/ButtonSelect/ButtonSelect.types.d.ts +56 -0
- package/dist/components/ButtonSelect/index.d.ts +3 -0
- package/dist/components/Calendar/Calendar.css.d.ts +135 -0
- package/dist/components/Calendar/Calendar.d.ts +4 -0
- package/dist/components/Calendar/Calendar.types.d.ts +22 -0
- package/dist/components/Calendar/CalendarCell.d.ts +9 -0
- package/dist/components/Calendar/CalendarHeader.d.ts +6 -0
- package/dist/components/Calendar/RangeCalendar.d.ts +4 -0
- package/dist/components/Calendar/index.d.ts +3 -0
- package/dist/components/Calendar/intl/index.d.ts +267 -0
- package/dist/components/Checkbox/Checkbox.css.d.ts +103 -0
- package/dist/components/Checkbox/Checkbox.d.ts +3 -0
- package/dist/components/Checkbox/Checkbox.types.d.ts +17 -0
- package/dist/components/Checkbox/index.d.ts +2 -0
- package/dist/components/Code/Code.css.d.ts +2 -0
- package/dist/components/Code/Code.d.ts +3 -0
- package/dist/components/Code/Code.types.d.ts +6 -0
- package/dist/components/Code/index.d.ts +3 -0
- package/dist/components/ColorInput/ColorArea.d.ts +4 -0
- package/dist/components/ColorInput/ColorFieldInput.d.ts +13 -0
- package/dist/components/ColorInput/ColorInput.css.d.ts +165 -0
- package/dist/components/ColorInput/ColorInput.d.ts +3 -0
- package/dist/components/ColorInput/ColorInput.types.d.ts +137 -0
- package/dist/components/ColorInput/ColorInputButton.d.ts +21 -0
- package/dist/components/ColorInput/ColorPresetList.d.ts +16 -0
- package/dist/components/ColorInput/ColorSlider.d.ts +3 -0
- package/dist/components/ColorInput/CustomColors.d.ts +15 -0
- package/dist/components/ColorInput/IconColorInput.d.ts +3 -0
- package/dist/components/ColorInput/Picker.d.ts +8 -0
- package/dist/components/ColorInput/__tests__/data.d.ts +8 -0
- package/dist/components/ColorInput/hooks/useColorTrigger.d.ts +13 -0
- package/dist/components/ColorInput/index.d.ts +4 -0
- package/dist/components/ColorInput/intl/index.d.ts +399 -0
- package/dist/components/ColorInput/utils.d.ts +44 -0
- package/dist/components/ColorSwatch/ColorSwatch.css.d.ts +39 -0
- package/dist/components/ColorSwatch/ColorSwatch.d.ts +3 -0
- package/dist/components/ColorSwatch/ColorSwatch.types.d.ts +44 -0
- package/dist/components/ColorSwatch/index.d.ts +2 -0
- package/dist/components/ColorSwatchPicker/ColorSwatchPicker.css.d.ts +2 -0
- package/dist/components/ColorSwatchPicker/ColorSwatchPicker.d.ts +3 -0
- package/dist/components/ColorSwatchPicker/ColorSwatchPicker.types.d.ts +46 -0
- package/dist/components/ColorSwatchPicker/index.d.ts +3 -0
- package/dist/components/ComboBox/ComboBox.css.d.ts +203 -0
- package/dist/components/ComboBox/ComboBox.d.ts +3 -0
- package/dist/components/ComboBox/ComboBox.types.d.ts +96 -0
- package/dist/components/ComboBox/index.d.ts +3 -0
- package/dist/components/ComboBox/useOnValueChange.d.ts +6 -0
- package/dist/components/DateField/DateField.d.ts +6 -0
- package/dist/components/DateField/DateField.types.d.ts +17 -0
- package/dist/components/DateField/index.d.ts +3 -0
- package/dist/components/DateField/intl/index.d.ts +102 -0
- package/dist/components/DateFormat/DateFormat.d.ts +3 -0
- package/dist/components/DateFormat/DateFormat.types.d.ts +5 -0
- package/dist/components/DateFormat/index.d.ts +2 -0
- package/dist/components/DeviceProvider/DeviceProvider.d.ts +6 -0
- package/dist/components/DeviceProvider/DeviceProvider.types.d.ts +12 -0
- package/dist/components/DeviceProvider/index.d.ts +2 -0
- package/dist/components/Dialog/Dialog.css.d.ts +53 -0
- package/dist/components/Dialog/Dialog.d.ts +6 -0
- package/dist/components/Dialog/Dialog.types.d.ts +37 -0
- package/dist/components/Dialog/DialogTitle.d.ts +3 -0
- package/dist/components/Dialog/index.d.ts +3 -0
- package/dist/components/Dialog/useDeferredLabel.d.ts +7 -0
- package/dist/components/Disclosure/Disclosure.css.d.ts +116 -0
- package/dist/components/Disclosure/Disclosure.d.ts +3 -0
- package/dist/components/Disclosure/Disclosure.types.d.ts +30 -0
- package/dist/components/Disclosure/index.d.ts +3 -0
- package/dist/components/DomNodeRenderer/DomNodeRenderer.d.ts +3 -0
- package/dist/components/DomNodeRenderer/DomNodeRenderer.types.d.ts +11 -0
- package/dist/components/DomNodeRenderer/index.d.ts +2 -0
- package/dist/components/Drawer/Drawer.css.d.ts +31 -0
- package/dist/components/Drawer/Drawer.d.ts +3 -0
- package/dist/components/Drawer/Drawer.types.d.ts +24 -0
- package/dist/components/Drawer/index.d.ts +3 -0
- package/dist/components/Editor/Editor.css.d.ts +131 -0
- package/dist/components/Editor/Editor.d.ts +3 -0
- package/dist/components/Editor/Editor.types.d.ts +159 -0
- package/dist/components/Editor/EditorToolbar.d.ts +15 -0
- package/dist/components/Editor/HelpDialog.d.ts +5 -0
- package/dist/components/Editor/RichEditor.d.ts +24 -0
- package/dist/components/Editor/elements/AddLink.d.ts +10 -0
- package/dist/components/Editor/elements/Mention.d.ts +46 -0
- package/dist/components/Editor/elements/Paragraph.d.ts +2 -0
- package/dist/components/Editor/elements/PlainEditor.d.ts +11 -0
- package/dist/components/Editor/index.d.ts +2 -0
- package/dist/components/Editor/utils.d.ts +93 -0
- package/dist/components/FileUpload/FileUpload.css.d.ts +69 -0
- package/dist/components/FileUpload/FileUpload.d.ts +3 -0
- package/dist/components/FileUpload/FileUpload.types.d.ts +38 -0
- package/dist/components/FileUpload/hooks/useFileUpload.d.ts +22 -0
- package/dist/components/FileUpload/index.d.ts +2 -0
- package/dist/components/FrameProvider/FrameProvider.d.ts +20 -0
- package/dist/components/FrameProvider/FrameProvider.types.d.ts +40 -0
- package/dist/components/FrameProvider/index.d.ts +2 -0
- package/dist/components/FreehandCanvas/FreehandCanvas.css.d.ts +78 -0
- package/dist/components/FreehandCanvas/FreehandCanvas.d.ts +4 -0
- package/dist/components/FreehandCanvas/FreehandCanvas.types.d.ts +116 -0
- package/dist/components/FreehandCanvas/hooks/usePathsData.d.ts +27 -0
- package/dist/components/FreehandCanvas/index.d.ts +2 -0
- package/dist/components/FreehandCanvas/intl/index.d.ts +135 -0
- package/dist/components/GridList/GridList.css.d.ts +22 -0
- package/dist/components/GridList/GridList.d.ts +3 -0
- package/dist/components/GridList/GridList.types.d.ts +84 -0
- package/dist/components/GridList/GridListItem.d.ts +20 -0
- package/dist/components/GridList/index.d.ts +3 -0
- package/dist/components/Group/Group.d.ts +3 -0
- package/dist/components/Group/Group.types.d.ts +19 -0
- package/dist/components/Group/index.d.ts +2 -0
- package/dist/components/I18nProvider/I18Provider.types.d.ts +11 -0
- package/dist/components/I18nProvider/I18nProvider.css.d.ts +1 -0
- package/dist/components/I18nProvider/I18nProvider.d.ts +10 -0
- package/dist/components/I18nProvider/index.d.ts +4 -0
- package/dist/components/Icon/Icon.d.ts +4 -0
- package/dist/components/Icon/Icon.types.d.ts +36 -0
- package/dist/components/Icon/index.d.ts +2 -0
- package/dist/components/ImageDropZone/ImageDropZone.css.d.ts +76 -0
- package/dist/components/ImageDropZone/ImageDropZone.d.ts +3 -0
- package/dist/components/ImageDropZone/ImageDropZone.types.d.ts +50 -0
- package/dist/components/ImageDropZone/index.d.ts +2 -0
- package/dist/components/ImageDropZone/intl/index.d.ts +135 -0
- package/dist/components/ImageGallery/AdaptiveText.d.ts +13 -0
- package/dist/components/ImageGallery/ImageGallery.css.d.ts +86 -0
- package/dist/components/ImageGallery/ImageGallery.d.ts +18 -0
- package/dist/components/ImageGallery/ImageGallery.types.d.ts +130 -0
- package/dist/components/ImageGallery/ImageGalleryDragPreview.d.ts +22 -0
- package/dist/components/ImageGallery/ImageGalleryItem.d.ts +3 -0
- package/dist/components/ImageGallery/index.d.ts +2 -0
- package/dist/components/ImageGallery/utils.d.ts +10 -0
- package/dist/components/InlineAlert/InlineAlert.css.d.ts +214 -0
- package/dist/components/InlineAlert/InlineAlert.d.ts +3 -0
- package/dist/components/InlineAlert/InlineAlert.types.d.ts +38 -0
- package/dist/components/InlineAlert/index.d.ts +2 -0
- package/dist/components/InlineAlert/intl/index.d.ts +102 -0
- package/dist/components/InlineToolbar/InlineToolbar.css.d.ts +50 -0
- package/dist/components/InlineToolbar/InlineToolbar.d.ts +3 -0
- package/dist/components/InlineToolbar/InlineToolbar.types.d.ts +63 -0
- package/dist/components/InlineToolbar/InlineToolbarButton.d.ts +3 -0
- package/dist/components/InlineToolbar/index.d.ts +2 -0
- package/dist/components/Kbd/Kbd.css.d.ts +1 -0
- package/dist/components/Kbd/Kbd.d.ts +3 -0
- package/dist/components/Kbd/Kbd.types.d.ts +21 -0
- package/dist/components/Kbd/index.d.ts +2 -0
- package/dist/components/Link/Link.css.d.ts +41 -0
- package/dist/components/Link/Link.d.ts +3 -0
- package/dist/components/Link/Link.types.d.ts +26 -0
- package/dist/components/Link/index.d.ts +2 -0
- package/dist/components/ListBox/DefaultListOption.d.ts +22 -0
- package/dist/components/ListBox/DropIndicator.d.ts +11 -0
- package/dist/components/ListBox/ListBox.css.d.ts +91 -0
- package/dist/components/ListBox/ListBox.d.ts +6 -0
- package/dist/components/ListBox/ListBox.types.d.ts +104 -0
- package/dist/components/ListBox/ListBoxSection.d.ts +14 -0
- package/dist/components/ListBox/ListOption.d.ts +17 -0
- package/dist/components/ListBox/hooks/useDragAndDrop.d.ts +3 -0
- package/dist/components/ListBox/hooks/useDragAutoScroll.d.ts +5 -0
- package/dist/components/ListBox/hooks/useDragDrop.d.ts +33 -0
- package/dist/components/ListBox/hooks/useSharedList.d.ts +8 -0
- package/dist/components/ListBox/index.d.ts +4 -0
- package/dist/components/Markdown/Markdown.css.d.ts +3 -0
- package/dist/components/Markdown/Markdown.d.ts +3 -0
- package/dist/components/Markdown/Markdown.types.d.ts +7 -0
- package/dist/components/Markdown/index.d.ts +3 -0
- package/dist/components/Menu/Menu.css.d.ts +2 -0
- package/dist/components/Menu/Menu.d.ts +3 -0
- package/dist/components/Menu/Menu.types.d.ts +63 -0
- package/dist/components/Menu/index.d.ts +2 -0
- package/dist/components/MessageFormat/MessageFormat.d.ts +3 -0
- package/dist/components/MessageFormat/MessageFormat.types.d.ts +14 -0
- package/dist/components/MessageFormat/index.d.ts +2 -0
- package/dist/components/Modal/Modal.css.d.ts +39 -0
- package/dist/components/Modal/Modal.d.ts +11 -0
- package/dist/components/Modal/Modal.types.d.ts +70 -0
- package/dist/components/Modal/ModalClose.d.ts +4 -0
- package/dist/components/Modal/ModalContent.d.ts +13 -0
- package/dist/components/Modal/ModalContentCore.d.ts +3 -0
- package/dist/components/Modal/ModalTrigger.d.ts +4 -0
- package/dist/components/Modal/hooks/useDialogPosition.d.ts +13 -0
- package/dist/components/Modal/index.d.ts +5 -0
- package/dist/components/NumberFormat/NumberFormat.d.ts +3 -0
- package/dist/components/NumberFormat/NumberFormat.types.d.ts +5 -0
- package/dist/components/NumberFormat/index.d.ts +2 -0
- package/dist/components/NumberInput/NumberInput.css.d.ts +9 -0
- package/dist/components/NumberInput/NumberInput.d.ts +3 -0
- package/dist/components/NumberInput/NumberInput.types.d.ts +26 -0
- package/dist/components/NumberInput/index.d.ts +2 -0
- package/dist/components/Pagination/Pagination.css.d.ts +84 -0
- package/dist/components/Pagination/Pagination.d.ts +3 -0
- package/dist/components/Pagination/Pagination.types.d.ts +25 -0
- package/dist/components/Pagination/index.d.ts +2 -0
- package/dist/components/Pagination/intl/index.d.ts +201 -0
- package/dist/components/Panel/Panel.css.d.ts +1 -0
- package/dist/components/Panel/Panel.d.ts +2 -0
- package/dist/components/Panel/Panel.types.d.ts +72 -0
- package/dist/components/Panel/PanelContext.d.ts +6 -0
- package/dist/components/Panel/PanelGroup.d.ts +2 -0
- package/dist/components/Panel/PanelResizeHandle.d.ts +5 -0
- package/dist/components/Panel/index.d.ts +4 -0
- package/dist/components/PointPicker/Grid.d.ts +7 -0
- package/dist/components/PointPicker/PointPicker.css.d.ts +37 -0
- package/dist/components/PointPicker/PointPicker.d.ts +22 -0
- package/dist/components/PointPicker/PointPicker.types.d.ts +116 -0
- package/dist/components/PointPicker/PointPickerContent/PointPickerContent.d.ts +3 -0
- package/dist/components/PointPicker/PointPickerContent/PointPickerIndicator.d.ts +8 -0
- package/dist/components/PointPicker/PointPickerContent/hooks/useCoordinatesRelativeToWindow.d.ts +4 -0
- package/dist/components/PointPicker/PointPickerContent/hooks/usePointPickerKeyboard.d.ts +3 -0
- package/dist/components/PointPicker/PointPickerContent/index.d.ts +1 -0
- package/dist/components/PointPicker/PointPickerDisplay/Floater.d.ts +7 -0
- package/dist/components/PointPicker/PointPickerDisplay/MagnifierContent.d.ts +8 -0
- package/dist/components/PointPicker/PointPickerDisplay/PointPickerDisplay.d.ts +3 -0
- package/dist/components/PointPicker/PointPickerDisplay/hooks/useIndicatorWidthObserver.d.ts +1 -0
- package/dist/components/PointPicker/PointPickerDisplay/index.d.ts +1 -0
- package/dist/components/PointPicker/PointsVisualiser/PointsVisualiser.d.ts +11 -0
- package/dist/components/PointPicker/PointsVisualiser/canvasUtils.d.ts +20 -0
- package/dist/components/PointPicker/PointsVisualiser/hooks/usePointProximity.d.ts +12 -0
- package/dist/components/PointPicker/hooks/usePointPicker.d.ts +4 -0
- package/dist/components/PointPicker/index.d.ts +5 -0
- package/dist/components/PointPicker/workers/canvas.worker.d.ts +1 -0
- package/dist/components/PointPicker/workers/pointProximity.worker.d.ts +1 -0
- package/dist/components/Popover/Arrow.d.ts +7 -0
- package/dist/components/Popover/Popover.css.d.ts +55 -0
- package/dist/components/Popover/Popover.d.ts +10 -0
- package/dist/components/Popover/Popover.types.d.ts +133 -0
- package/dist/components/Popover/PopoverContent.d.ts +3 -0
- package/dist/components/Popover/PopoverContentCore.d.ts +7 -0
- package/dist/components/Popover/PopoverTrigger.d.ts +8 -0
- package/dist/components/Popover/hooks/usePopoverScrollReposition.d.ts +22 -0
- package/dist/components/Popover/hooks/usePopoverTransition.d.ts +23 -0
- package/dist/components/Popover/index.d.ts +4 -0
- package/dist/components/Portal/Portal.d.ts +3 -0
- package/dist/components/Portal/Portal.types.d.ts +4 -0
- package/dist/components/Portal/index.d.ts +2 -0
- package/dist/components/PortalContainerProvider/PortalContainerProvider.d.ts +4 -0
- package/dist/components/PortalContainerProvider/PortalContainerProvider.types.d.ts +12 -0
- package/dist/components/PortalContainerProvider/index.d.ts +1 -0
- package/dist/components/Preview/Preview.css.d.ts +50 -0
- package/dist/components/Preview/Preview.d.ts +3 -0
- package/dist/components/Preview/Preview.types.d.ts +59 -0
- package/dist/components/Preview/index.d.ts +2 -0
- package/dist/components/ProgressBar/ProgressBar.css.d.ts +48 -0
- package/dist/components/ProgressBar/ProgressBar.d.ts +3 -0
- package/dist/components/ProgressBar/ProgressBar.types.d.ts +20 -0
- package/dist/components/ProgressBar/index.d.ts +2 -0
- package/dist/components/ProgressSpinner/ProgressSpinner.css.d.ts +9 -0
- package/dist/components/ProgressSpinner/ProgressSpinner.d.ts +3 -0
- package/dist/components/ProgressSpinner/ProgressSpinner.types.d.ts +16 -0
- package/dist/components/ProgressSpinner/index.d.ts +2 -0
- package/dist/components/RadioGroup/RadioGroup.css.d.ts +26 -0
- package/dist/components/RadioGroup/RadioGroup.d.ts +3 -0
- package/dist/components/RadioGroup/RadioGroup.types.d.ts +67 -0
- package/dist/components/RadioGroup/RadioItem.d.ts +11 -0
- package/dist/components/RadioGroup/index.d.ts +2 -0
- package/dist/components/Reaction/Reaction.css.d.ts +74 -0
- package/dist/components/Reaction/Reaction.d.ts +3 -0
- package/dist/components/Reaction/Reaction.types.d.ts +13 -0
- package/dist/components/Reaction/index.d.ts +2 -0
- package/dist/components/ScrollControlButton/ScrollControlButton.css.d.ts +1 -0
- package/dist/components/ScrollControlButton/ScrollControlButton.d.ts +3 -0
- package/dist/components/ScrollControlButton/ScrollControlButton.types.d.ts +31 -0
- package/dist/components/ScrollControlButton/index.d.ts +3 -0
- package/dist/components/SearchInput/SearchInput.css.d.ts +64 -0
- package/dist/components/SearchInput/SearchInput.d.ts +3 -0
- package/dist/components/SearchInput/SearchInput.types.d.ts +27 -0
- package/dist/components/SearchInput/index.d.ts +2 -0
- package/dist/components/Select/IconSelect.d.ts +3 -0
- package/dist/components/Select/Select.css.d.ts +58 -0
- package/dist/components/Select/Select.d.ts +9 -0
- package/dist/components/Select/Select.types.d.ts +87 -0
- package/dist/components/Select/SelectButton.d.ts +3 -0
- package/dist/components/Select/index.d.ts +3 -0
- package/dist/components/Separator/Separator.css.d.ts +19 -0
- package/dist/components/Separator/Separator.d.ts +3 -0
- package/dist/components/Separator/Separator.types.d.ts +12 -0
- package/dist/components/Separator/index.d.ts +2 -0
- package/dist/components/Skeleton/Skeleton.css.d.ts +1 -0
- package/dist/components/Skeleton/Skeleton.d.ts +3 -0
- package/dist/components/Skeleton/Skeleton.types.d.ts +7 -0
- package/dist/components/Skeleton/index.d.ts +2 -0
- package/dist/components/Slider/IconSlider.d.ts +3 -0
- package/dist/components/Slider/Slider.css.d.ts +133 -0
- package/dist/components/Slider/Slider.d.ts +3 -0
- package/dist/components/Slider/Slider.types.d.ts +42 -0
- package/dist/components/Slider/index.d.ts +3 -0
- package/dist/components/StatusCard/StatusCard.css.d.ts +87 -0
- package/dist/components/StatusCard/StatusCard.d.ts +10 -0
- package/dist/components/StatusCard/StatusCard.types.d.ts +34 -0
- package/dist/components/StatusCard/index.d.ts +3 -0
- package/dist/components/Switch/Switch.css.d.ts +67 -0
- package/dist/components/Switch/Switch.d.ts +3 -0
- package/dist/components/Switch/Switch.types.d.ts +15 -0
- package/dist/components/Switch/index.d.ts +2 -0
- package/dist/components/Table/Table.css.d.ts +111 -0
- package/dist/components/Table/Table.d.ts +8 -0
- package/dist/components/Table/Table.types.d.ts +26 -0
- package/dist/components/Table/hooks/useTableDragAndDrop.d.ts +8 -0
- package/dist/components/Table/index.d.ts +3 -0
- package/dist/components/Tabs/TabItem.d.ts +3 -0
- package/dist/components/Tabs/TabPanel.d.ts +9 -0
- package/dist/components/Tabs/Tabs.css.d.ts +122 -0
- package/dist/components/Tabs/Tabs.d.ts +3 -0
- package/dist/components/Tabs/Tabs.types.d.ts +66 -0
- package/dist/components/Tabs/TabsBase.d.ts +7 -0
- package/dist/components/Tabs/index.d.ts +3 -0
- package/dist/components/Tag/Tag.css.d.ts +215 -0
- package/dist/components/Tag/Tag.d.ts +3 -0
- package/dist/components/Tag/Tag.types.d.ts +43 -0
- package/dist/components/Tag/TagContext.d.ts +15 -0
- package/dist/components/Tag/index.d.ts +2 -0
- package/dist/components/TagGroup/TagGroup.css.d.ts +1 -0
- package/dist/components/TagGroup/TagGroup.d.ts +3 -0
- package/dist/components/TagGroup/TagGroup.types.d.ts +38 -0
- package/dist/components/TagGroup/index.d.ts +2 -0
- package/dist/components/TaggedPagination/TaggedPagination.css.d.ts +70 -0
- package/dist/components/TaggedPagination/TaggedPagination.d.ts +3 -0
- package/dist/components/TaggedPagination/TaggedPagination.types.d.ts +50 -0
- package/dist/components/TaggedPagination/index.d.ts +2 -0
- package/dist/components/Text/Text.css.d.ts +51 -0
- package/dist/components/Text/Text.d.ts +3 -0
- package/dist/components/Text/Text.types.d.ts +24 -0
- package/dist/components/Text/index.d.ts +2 -0
- package/dist/components/TextInput/TextInput.css.d.ts +183 -0
- package/dist/components/TextInput/TextInput.d.ts +3 -0
- package/dist/components/TextInput/TextInput.types.d.ts +18 -0
- package/dist/components/TextInput/index.d.ts +2 -0
- package/dist/components/TextInput/utils/getMessage.d.ts +12 -0
- package/dist/components/TextInput/utils/getStatusIcon.d.ts +6 -0
- package/dist/components/ThemeProvider/ThemeProvider.context.d.ts +6 -0
- package/dist/components/ThemeProvider/ThemeProvider.css.d.ts +1 -0
- package/dist/components/ThemeProvider/ThemeProvider.d.ts +3 -0
- package/dist/components/ThemeProvider/ThemeProvider.types.d.ts +29 -0
- package/dist/components/ThemeProvider/hooks/useUserPreferences.d.ts +19 -0
- package/dist/components/ThemeProvider/index.d.ts +6 -0
- package/dist/components/TimeField/DateTimeSegment.d.ts +5 -0
- package/dist/components/TimeField/TimeField.css.d.ts +16 -0
- package/dist/components/TimeField/TimeField.d.ts +3 -0
- package/dist/components/TimeField/TimeField.types.d.ts +6 -0
- package/dist/components/TimeField/index.d.ts +3 -0
- package/dist/components/Toast/Toast.css.d.ts +34 -0
- package/dist/components/Toast/Toast.d.ts +3 -0
- package/dist/components/Toast/Toast.types.d.ts +14 -0
- package/dist/components/Toast/index.d.ts +4 -0
- package/dist/components/ToggleButton/ToggleButton.css.d.ts +74 -0
- package/dist/components/ToggleButton/ToggleButton.d.ts +3 -0
- package/dist/components/ToggleButton/ToggleButton.types.d.ts +27 -0
- package/dist/components/ToggleButton/index.d.ts +2 -0
- package/dist/components/ToggleIconButton/ToggleIconButton.css.d.ts +149 -0
- package/dist/components/ToggleIconButton/ToggleIconButton.d.ts +3 -0
- package/dist/components/ToggleIconButton/ToggleIconButton.types.d.ts +30 -0
- package/dist/components/ToggleIconButton/index.d.ts +2 -0
- package/dist/components/Toolbar/CollapsibleToolbar.d.ts +3 -0
- package/dist/components/Toolbar/Toolbar.css.d.ts +2 -0
- package/dist/components/Toolbar/Toolbar.d.ts +3 -0
- package/dist/components/Toolbar/Toolbar.types.d.ts +47 -0
- package/dist/components/Toolbar/WrappedToolbar.d.ts +3 -0
- package/dist/components/Toolbar/hooks/useFormattedList.d.ts +3 -0
- package/dist/components/Toolbar/hooks/useInputAwareToolbar.d.ts +6 -0
- package/dist/components/Toolbar/index.d.ts +3 -0
- package/dist/components/Tooltip/Tooltip.css.d.ts +44 -0
- package/dist/components/Tooltip/Tooltip.d.ts +3 -0
- package/dist/components/Tooltip/Tooltip.types.d.ts +55 -0
- package/dist/components/Tooltip/TooltipContent.d.ts +15 -0
- package/dist/components/Tooltip/index.d.ts +3 -0
- package/dist/components/TreeView/TreeItem.d.ts +7 -0
- package/dist/components/TreeView/TreeView.css.d.ts +34 -0
- package/dist/components/TreeView/TreeView.d.ts +8 -0
- package/dist/components/TreeView/TreeView.types.d.ts +95 -0
- package/dist/components/TreeView/index.d.ts +2 -0
- package/dist/components/UNSAFE_ListBox/ListBox.css.d.ts +92 -0
- package/dist/components/UNSAFE_ListBox/ListBox.d.ts +13 -0
- package/dist/components/UNSAFE_ListBox/ListBox.types.d.ts +84 -0
- package/dist/components/UNSAFE_ListBox/ListBoxUI.d.ts +19 -0
- package/dist/components/UNSAFE_ListBox/hooks/useDragAndDrop.d.ts +3 -0
- package/dist/components/UNSAFE_ListBox/index.d.ts +3 -0
- package/dist/components/Virtualizer/LocaleAwareGridLayout.d.ts +17 -0
- package/dist/components/Virtualizer/Virtualizer.types.d.ts +6 -0
- package/dist/components/Virtualizer/index.d.ts +36 -0
- package/dist/components/index.d.ts +81 -0
- package/dist/components/shared/buttons.d.ts +30 -0
- package/dist/components/shared/collection.d.ts +3 -0
- package/dist/components/shared/components/DragPreviewContent.d.ts +12 -0
- package/dist/components/shared/components/IconWithTooltip.d.ts +8 -0
- package/dist/components/shared/components/ListCollectionBuilder.d.ts +9 -0
- package/dist/components/shared/components/OverlayEventLeakPreventionLayer.d.ts +8 -0
- package/dist/components/shared/components/SharedInput/SharedInput.d.ts +3 -0
- package/dist/components/shared/components/SharedInput/SharedInput.types.d.ts +34 -0
- package/dist/components/shared/components/SharedInput/index.d.ts +1 -0
- package/dist/components/shared/tooltips.d.ts +11 -0
- package/dist/components/shared/types/IconComponent.d.ts +21 -0
- package/dist/components/shared/types/List.d.ts +17 -0
- package/dist/hooks/index.d.ts +13 -0
- package/dist/hooks/useDevice.d.ts +20 -0
- package/dist/hooks/useI18n.d.ts +59 -0
- package/dist/hooks/useImage.d.ts +23 -0
- package/dist/hooks/useIntersectionObserver.d.ts +44 -0
- package/dist/hooks/useIsFirstRender.d.ts +21 -0
- package/dist/hooks/useIsTouchDevice.d.ts +7 -0
- package/dist/hooks/useLiveInteractionModality.d.ts +13 -0
- package/dist/hooks/useLocalStorage.d.ts +20 -0
- package/dist/hooks/useMedia.d.ts +13 -0
- package/dist/hooks/useMutationObserver.d.ts +20 -0
- package/dist/hooks/usePortalContainer.d.ts +11 -0
- package/dist/hooks/usePreventFocus.d.ts +23 -0
- package/dist/hooks/useResizeObserver.d.ts +38 -0
- package/dist/hooks/useTextSelection.d.ts +29 -0
- package/dist/hooks/useUndoRedo.d.ts +44 -0
- package/dist/index.d.ts +11 -10074
- package/dist/index.js +12 -12
- package/dist/index.mjs +12 -12
- package/dist/react-aria.d.ts +2 -0
- package/dist/react-stately.d.ts +2 -0
- package/dist/utils/a11y.d.ts +1 -0
- package/dist/utils/classNames.d.ts +17 -0
- package/dist/utils/colors.d.ts +11 -0
- package/dist/utils/constants.d.ts +1 -0
- package/dist/utils/devWarn.d.ts +1 -0
- package/dist/utils/dom.d.ts +130 -0
- package/dist/utils/index.d.ts +18 -0
- package/dist/utils/invariant.d.ts +18 -0
- package/dist/utils/isInIframe.d.ts +12 -0
- package/dist/utils/isInShadowDOM.d.ts +11 -0
- package/dist/utils/isRect.d.ts +7 -0
- package/dist/utils/keyboards.d.ts +13 -0
- package/dist/utils/math.d.ts +1 -0
- package/dist/utils/objects.d.ts +20 -0
- package/dist/utils/overlays.d.ts +6 -0
- package/dist/utils/reactAriaCompat.d.ts +22 -0
- package/dist/utils/reactAriaComponentsCompat.d.ts +4 -0
- package/dist/utils/resolveAriaLabelAttrs.d.ts +22 -0
- package/dist/utils/resolvePublicUrl.d.ts +1 -0
- package/dist/utils/strings.d.ts +6 -0
- package/dist/utils/style.d.ts +5 -0
- package/dist/utils/styleMixins.css.d.ts +16 -0
- package/dist/utils/svgs.d.ts +15 -0
- package/dist/utils/types/Shared.d.ts +34 -0
- package/dist/utils/validations.d.ts +13 -0
- package/package.json +7 -7
- package/sbom.json +1 -1
- package/dist/index.d.mts +0 -10074
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function cleanKeyFromGlobImport(modules: Record<string, Record<string, string>>): Record<string, Record<string, string>>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This utility function is used to create a class name string from the given
|
|
3
|
+
* arguments. It supports strings, undefined, null, boolean and objects. If an
|
|
4
|
+
* object is passed, the keys will be used as class names and the values will be
|
|
5
|
+
* used as a boolean to determine if the class name should be included.
|
|
6
|
+
*
|
|
7
|
+
* Example:
|
|
8
|
+
*
|
|
9
|
+
* ```js
|
|
10
|
+
* classNames("foo", "bar", { baz: true, qux: false }); // "foo bar baz"
|
|
11
|
+
* classNames(null, undefined, false, "foo", { bar: true }); // "foo bar"
|
|
12
|
+
* classNames(["foo", { bar: true }]); // "foo bar"
|
|
13
|
+
* ```
|
|
14
|
+
*
|
|
15
|
+
* @param args
|
|
16
|
+
*/
|
|
17
|
+
export declare function classNames(...args: any[]): string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const MINIMUM_ACCESSIBLE_SIZE = 24;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function devWarnOnce(key: string, message: string): void;
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import type React from "react";
|
|
2
|
+
/**
|
|
3
|
+
* Returns the HTMLElement from a string selector, HTMLElement, or React
|
|
4
|
+
* RefObject.
|
|
5
|
+
*
|
|
6
|
+
* @param element - A string selector, HTMLElement, or React RefObject.
|
|
7
|
+
* @param ownerDocument - The document to use for the querySelector call.
|
|
8
|
+
* @returns The HTMLElement or null if not found.
|
|
9
|
+
*/
|
|
10
|
+
export declare function getHTMLElement(element: string | HTMLElement | React.RefObject<HTMLElement> | null | undefined, ownerDocument: Document): HTMLElement | null | undefined;
|
|
11
|
+
interface FontProperties {
|
|
12
|
+
fontSize?: number;
|
|
13
|
+
fontFamily?: string;
|
|
14
|
+
fontWeight?: string;
|
|
15
|
+
fontStyle?: string;
|
|
16
|
+
font?: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Returns the width and height of the text with the given font properties.
|
|
20
|
+
*
|
|
21
|
+
* ```ts
|
|
22
|
+
* const { width, height } = getTextDimensions({
|
|
23
|
+
* text: "Hello world!",
|
|
24
|
+
* fontSize: 16,
|
|
25
|
+
* fontFamily: "Arial",
|
|
26
|
+
* fontWeight: "normal",
|
|
27
|
+
* fontStyle: "normal",
|
|
28
|
+
* });
|
|
29
|
+
* ```
|
|
30
|
+
*
|
|
31
|
+
* @param options - The options for calculating the text dimensions.
|
|
32
|
+
* @param options.text - The text to measure.
|
|
33
|
+
* @param options.fontSize - The font size in pixels. Defaults to 16.
|
|
34
|
+
* @param options.fontFamily - The font family. Defaults to 'Arial'.
|
|
35
|
+
* @param options.fontWeight - The font weight. Defaults to 'normal'.
|
|
36
|
+
* @param options.fontStyle - The font style. Defaults to 'normal'.
|
|
37
|
+
* @param options.font - The full font string. Overrides fontSize, fontFamily,
|
|
38
|
+
* fontWeight, and fontStyle.
|
|
39
|
+
*/
|
|
40
|
+
export declare function getTextDimensions({ text, fontSize, fontFamily, fontWeight, fontStyle, font, }: {
|
|
41
|
+
text: string;
|
|
42
|
+
} & FontProperties): {
|
|
43
|
+
width: number;
|
|
44
|
+
height: number;
|
|
45
|
+
};
|
|
46
|
+
/**
|
|
47
|
+
* Returns the font size that will fit the given text within the given width.
|
|
48
|
+
* The font size is calculated by starting with the initial font size and
|
|
49
|
+
* decreasing it until the text fits within the desired width.
|
|
50
|
+
*
|
|
51
|
+
* @example
|
|
52
|
+
* const fontSize = calculateFontSizeToFitWidth({
|
|
53
|
+
* text: "Hello world!",
|
|
54
|
+
* maxWidth: 100,
|
|
55
|
+
* initialFontSize: 16,
|
|
56
|
+
* fontFamily: "Arial",
|
|
57
|
+
* fontWeight: "normal",
|
|
58
|
+
* fontStyle: "normal",
|
|
59
|
+
* });
|
|
60
|
+
*
|
|
61
|
+
* @param options - The options for calculating the font size.
|
|
62
|
+
* @param options.text - The text to fit within the width.
|
|
63
|
+
* @param options.maxWidth - The maximum width the text should fit within.
|
|
64
|
+
* @param options.initialFontSize - The starting font size to use for
|
|
65
|
+
* calculations. Defaults to 50.
|
|
66
|
+
* @param options.fontFamily - The font family to use. Defaults to 'Arial'.
|
|
67
|
+
* @param options.fontWeight - The font weight to use. Defaults to 'normal'.
|
|
68
|
+
* @param options.fontStyle - The font style to use. Defaults to 'normal'.
|
|
69
|
+
* @returns The calculated font size that fits the text within the given width.
|
|
70
|
+
*/
|
|
71
|
+
export declare function calculateFontSizeToFitWidth({ text, maxWidth, initialFontSize, fontFamily, fontWeight, fontStyle, }: {
|
|
72
|
+
text: string;
|
|
73
|
+
maxWidth: number;
|
|
74
|
+
initialFontSize: number;
|
|
75
|
+
} & Omit<FontProperties, "fontSize">): number;
|
|
76
|
+
/**
|
|
77
|
+
* Returns true if the element is focusable.
|
|
78
|
+
*
|
|
79
|
+
* @param element - The element to check.
|
|
80
|
+
*/
|
|
81
|
+
export declare function isFocusableElement(element: HTMLElement): boolean;
|
|
82
|
+
export declare function findFocusableElements(element: HTMLElement): NodeListOf<Element>;
|
|
83
|
+
/**
|
|
84
|
+
* Returns the active element of the given node. If the node is within a shadow
|
|
85
|
+
* root, the active element of the shadow root will be returned, otherwise the
|
|
86
|
+
* active element of the document will be returned.
|
|
87
|
+
*
|
|
88
|
+
* @param node - The node to get the active element from.
|
|
89
|
+
* @returns The active element of the given node.
|
|
90
|
+
*/
|
|
91
|
+
export declare function getActiveElement(node?: Node): Element | null;
|
|
92
|
+
/**
|
|
93
|
+
* Returns true if the target is an input that will cause the software keyboard
|
|
94
|
+
* to appear.
|
|
95
|
+
*
|
|
96
|
+
* @param target Element - The element to check.
|
|
97
|
+
*/
|
|
98
|
+
export declare function isInputThatOpensKeyboard(target: Element): boolean;
|
|
99
|
+
/**
|
|
100
|
+
* Returns the absolute bounds of the element. If the element is within a shadow
|
|
101
|
+
* root, the bounds will be relative to the host element. If the element is not
|
|
102
|
+
* within a shadow root, the bounds will be relative to the document.
|
|
103
|
+
*
|
|
104
|
+
* @param element - The element to get the absolute bounds of.
|
|
105
|
+
* @returns The absolute bounds of the element.
|
|
106
|
+
*/
|
|
107
|
+
export declare function getAbsoluteBounds(element: HTMLElement): {
|
|
108
|
+
x: number;
|
|
109
|
+
y: number;
|
|
110
|
+
width: number;
|
|
111
|
+
height: number;
|
|
112
|
+
};
|
|
113
|
+
/**
|
|
114
|
+
* Returns the absolute position of the element that can go correctly with
|
|
115
|
+
* position: fixed. If the element is within a shadow root, the position will be
|
|
116
|
+
* relative to the host element so that the element can be positioned correctly
|
|
117
|
+
* within the shadow root.
|
|
118
|
+
*
|
|
119
|
+
* @param element - The element to get the absolute position of.
|
|
120
|
+
* @param coordinates - The coordinates of the element.
|
|
121
|
+
* @returns The absolute position of the element.
|
|
122
|
+
*/
|
|
123
|
+
export declare function getAbsolutePosition(element: HTMLElement, coordinates?: {
|
|
124
|
+
x: number;
|
|
125
|
+
y: number;
|
|
126
|
+
}): {
|
|
127
|
+
x: number;
|
|
128
|
+
y: number;
|
|
129
|
+
};
|
|
130
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export * from "./types/Shared";
|
|
2
|
+
export * from "./overlays";
|
|
3
|
+
export * from "./isRect";
|
|
4
|
+
export * from "./invariant";
|
|
5
|
+
export * from "./classNames";
|
|
6
|
+
export * from "./dom";
|
|
7
|
+
export * from "./svgs";
|
|
8
|
+
export * from "./a11y";
|
|
9
|
+
export * from "./objects";
|
|
10
|
+
export * from "./colors";
|
|
11
|
+
export * from "./validations";
|
|
12
|
+
export * from "./keyboards";
|
|
13
|
+
export * from "./math";
|
|
14
|
+
export * from "./strings";
|
|
15
|
+
export * from "./isInIframe";
|
|
16
|
+
export * from "./isInShadowDOM";
|
|
17
|
+
export * from "./reactAriaCompat";
|
|
18
|
+
export * from "./devWarn";
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Throws an error if the condition is falsy. This is used to check for
|
|
3
|
+
* impossible conditions, such as unreachable code or invalid inputs. This is
|
|
4
|
+
* also used to narrow types in TypeScript. For example:
|
|
5
|
+
*
|
|
6
|
+
* ```ts
|
|
7
|
+
* function example(value: string | number) {
|
|
8
|
+
* invariant(typeof value === "string");
|
|
9
|
+
* // value is now a string
|
|
10
|
+
* value.split("");
|
|
11
|
+
* // ...
|
|
12
|
+
* }
|
|
13
|
+
* ```
|
|
14
|
+
*
|
|
15
|
+
* @param condition The condition to check
|
|
16
|
+
* @param message The message to throw if the condition is falsy
|
|
17
|
+
*/
|
|
18
|
+
export declare function invariant(condition: unknown, message?: string): asserts condition;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Checks whether a given DOM node is inside an iframe.
|
|
3
|
+
*
|
|
4
|
+
* This function compares the node's owning document's `defaultView` to
|
|
5
|
+
* `window.top`. If they're different, the node is inside an iframe. Handles
|
|
6
|
+
* cross-origin iframes safely using try/catch.
|
|
7
|
+
*
|
|
8
|
+
* @param {Node} node - The DOM node to check.
|
|
9
|
+
* @returns {boolean} `true` if the node is inside an iframe, `false` otherwise.
|
|
10
|
+
* @see https://stackoverflow.com/a/326076
|
|
11
|
+
*/
|
|
12
|
+
export declare function isInIframe(el: Node): boolean;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Checks whether a given node is inside a Shadow DOM.
|
|
3
|
+
*
|
|
4
|
+
* This function uses `getRootNode()` to determine if the node's root is a
|
|
5
|
+
* `ShadowRoot`, which indicates that the node is part of a shadow tree.
|
|
6
|
+
*
|
|
7
|
+
* @param {Node} node - The DOM node to check.
|
|
8
|
+
* @returns {boolean} `true` if the node is inside a Shadow DOM, `false`
|
|
9
|
+
* otherwise.
|
|
10
|
+
*/
|
|
11
|
+
export declare function isInShadowDOM(element: Node | null | undefined): boolean;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Returns the keyboard shortcut label with the correct symbols for the current
|
|
3
|
+
* OS.
|
|
4
|
+
*
|
|
5
|
+
* ```tsx
|
|
6
|
+
* getOsSpecificKeyboardShortcutLabel("Ctrl+Alt+Shift+Enter", true); // "⌘⌥⇧↩"
|
|
7
|
+
* getOsSpecificKeyboardShortcutLabel("Ctrl+Alt+Shift+Enter"); // "Cmd+Option+Shift+Enter"
|
|
8
|
+
* ```
|
|
9
|
+
*
|
|
10
|
+
* @param keyboardShortcut - The Windows keyboard shortcut to format.
|
|
11
|
+
* @param useSymbol - Whether to use symbols for the modifier keys.
|
|
12
|
+
*/
|
|
13
|
+
export declare function getOsSpecificKeyboardShortcutLabel(keyboardShortcut: string, useSymbol?: boolean): string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const clamp: (value: number, min: number, max: number) => number;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This function filters out falsy values from an object.
|
|
3
|
+
*
|
|
4
|
+
* @template T - A type that extends Record<string, unknown>.
|
|
5
|
+
* @param {T} obj - The object to filter.
|
|
6
|
+
* @returns {Partial<T>} - A new object that only includes the truthy values
|
|
7
|
+
* from the original object.
|
|
8
|
+
*/
|
|
9
|
+
export declare function filterTruthyValues<T extends Record<string, unknown>>(obj: T): Partial<T>;
|
|
10
|
+
/**
|
|
11
|
+
* This function converts a boolean or an object to a config object. If the
|
|
12
|
+
* value is a boolean, the defaults will be returned. If the value is an object,
|
|
13
|
+
* the defaults will be merged with the value.
|
|
14
|
+
*
|
|
15
|
+
* @template T - A type that extends Record<string, unknown>.
|
|
16
|
+
* @param {boolean | Partial<T>} value - The value to convert.
|
|
17
|
+
* @param {T} defaults - The defaults to use if the value is a boolean.
|
|
18
|
+
* @returns {T} - A new object that includes the defaults and the value.
|
|
19
|
+
*/
|
|
20
|
+
export declare function booleanOrObjectToConfig<T extends Record<string, unknown>>(value: boolean | Partial<T>, defaults: T): T | undefined;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { DOMAttributes } from "@react-types/shared";
|
|
2
|
+
import type { HTMLAttributes } from "react";
|
|
3
|
+
/**
|
|
4
|
+
* Keys whose types in `@react-types/shared`'s `DOMAttributes` are incompatible
|
|
5
|
+
* with React's `HTMLAttributes` after the React 18 → 19 typings shift
|
|
6
|
+
* (`onBeforeInput` event signature changed; `children` is structurally typed).
|
|
7
|
+
*
|
|
8
|
+
* Single source of truth — also referenced by `BoxProps` so the omit list
|
|
9
|
+
* cannot drift between the type and the runtime helper.
|
|
10
|
+
*/
|
|
11
|
+
export declare const REACT_ARIA_INCOMPATIBLE_KEYS: readonly ["onBeforeInput", "children"];
|
|
12
|
+
export type ReactAriaIncompatibleKey = (typeof REACT_ARIA_INCOMPATIBLE_KEYS)[number];
|
|
13
|
+
export type SafeDOMAttributes<T> = Omit<DOMAttributes<T>, ReactAriaIncompatibleKey>;
|
|
14
|
+
/**
|
|
15
|
+
* Strips keys whose React Aria types are incompatible with React's
|
|
16
|
+
* `HTMLAttributes` so the result can be spread onto a DOM element.
|
|
17
|
+
*
|
|
18
|
+
* If React Aria ever returns a real `onBeforeInput` handler we drop it here.
|
|
19
|
+
* Logged via `console.error` (deduped per call site) so a regression is
|
|
20
|
+
* visible in production telemetry, not just in dev.
|
|
21
|
+
*/
|
|
22
|
+
export declare function safeSpreadProps<T extends HTMLElement>(ariaProps: DOMAttributes<T>): HTMLAttributes<T>;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { AriaLabelingProps } from "@react-types/shared";
|
|
2
|
+
/**
|
|
3
|
+
* Utility function to resolve aria-labeling attributes for a component. It also
|
|
4
|
+
* handles the fallback of aria-labelledby and aria-describedby attributes based
|
|
5
|
+
* on provided IDs. This function makes sure that if `aria-label` is passed by
|
|
6
|
+
* the user, it is prioritised over using `aria-labelledby` with fallback
|
|
7
|
+
* value.
|
|
8
|
+
*
|
|
9
|
+
* **Note**: If both `aria-label` and `aria-describedby` are passed, the
|
|
10
|
+
* VoiceOver (on OSX) is going to read only `aria-label` and ignore
|
|
11
|
+
* `aria-describedby`.
|
|
12
|
+
*/
|
|
13
|
+
export declare function resolveAriaLabelAttrs({ ariaProps, fallbackLabelId, fallbackDescriptionId, }: {
|
|
14
|
+
ariaProps: AriaLabelingProps;
|
|
15
|
+
fallbackLabelId?: string;
|
|
16
|
+
fallbackDescriptionId?: string;
|
|
17
|
+
}): {
|
|
18
|
+
'aria-label'?: string;
|
|
19
|
+
'aria-labelledby'?: string;
|
|
20
|
+
'aria-describedby'?: string;
|
|
21
|
+
'aria-details'?: string;
|
|
22
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function resolvePublicUrl(path: string): string;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type React from "react";
|
|
2
|
+
export declare function getDynamicClassNameForCollectionItem<U, V, T extends (item: U, options: V) => string | undefined>(className: string | T | undefined, item: U, options: V): string | undefined;
|
|
3
|
+
export declare function getDynamicStyleForCollectionItem<U, V, T extends (item: U, options: V) => React.CSSProperties | undefined>(style: React.CSSProperties | T | undefined, item: U, options: V): React.CSSProperties | undefined;
|
|
4
|
+
export declare function getDynamicClassName<U, T extends (state: U) => string | undefined>(className: string | T | undefined, state: U): string | undefined;
|
|
5
|
+
export declare function getDynamicStyle<U, T extends (state: U) => React.CSSProperties | undefined>(style: React.CSSProperties | T | undefined, state: U): React.CSSProperties | undefined;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export declare const contentsCn: string;
|
|
2
|
+
export declare const rowCn: string;
|
|
3
|
+
export declare const disabledCn: string;
|
|
4
|
+
export declare const checkeredCn: import("@vanilla-extract/recipes").RuntimeFn<{
|
|
5
|
+
size: {
|
|
6
|
+
xs: {
|
|
7
|
+
backgroundSize: "4px 4px";
|
|
8
|
+
};
|
|
9
|
+
sm: {
|
|
10
|
+
backgroundSize: "6px 6px";
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
}>;
|
|
14
|
+
export declare const ellipsisCn: string;
|
|
15
|
+
export declare const fullWidthTouchTargetCn: Record<"always" | "touch", string>;
|
|
16
|
+
export declare const touchTargetCn: Record<"always" | "touch", string>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This function takes a list of [x, y] coordinates representing a stroke and
|
|
3
|
+
* returns a SVG path string.
|
|
4
|
+
*
|
|
5
|
+
* @example
|
|
6
|
+
* ```ts
|
|
7
|
+
* const stroke = [[0, 0], [1, 1], [2, 2]];
|
|
8
|
+
* const path = getSvgPathFromStroke(stroke);
|
|
9
|
+
* // path === "M0,0Q0.5,0.5,1,1Q1.5,1.5,2,2Z"
|
|
10
|
+
* ```;
|
|
11
|
+
*
|
|
12
|
+
* @param stroke The stroke to convert to an SVG path
|
|
13
|
+
* @param closed Wether to close the path
|
|
14
|
+
*/
|
|
15
|
+
export declare function getSvgPathFromStroke(stroke: number[][], closed?: boolean): string;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type React from "react";
|
|
2
|
+
export interface BlockProps {
|
|
3
|
+
/**
|
|
4
|
+
* The unique identifier for the block. This is used to identify the block in
|
|
5
|
+
* the DOM and in the block map. It is added as a data attribute
|
|
6
|
+
* `data-block-id` to the root element of the block if a DOM node is
|
|
7
|
+
* rendered.
|
|
8
|
+
*/
|
|
9
|
+
"data-block-id"?: string;
|
|
10
|
+
/**
|
|
11
|
+
* Represents a data block group. This is similar to `data-block-id` but it
|
|
12
|
+
* doesn't have to be unique just like `class`. This is used to group blocks
|
|
13
|
+
* together in the DOM and in the block map. It is added as a data attribute
|
|
14
|
+
* `data-block-class` to the root element of the block if a DOM node is
|
|
15
|
+
* rendered.
|
|
16
|
+
*/
|
|
17
|
+
"data-block-class"?: string;
|
|
18
|
+
}
|
|
19
|
+
export interface StylingProps extends BlockProps {
|
|
20
|
+
/** The className applied to the root element of the component. */
|
|
21
|
+
className?: string;
|
|
22
|
+
/** The style applied to the root element of the component. */
|
|
23
|
+
style?: React.CSSProperties;
|
|
24
|
+
}
|
|
25
|
+
export interface Rect {
|
|
26
|
+
/** The left position of the rectangle. */
|
|
27
|
+
left: number;
|
|
28
|
+
/** The top position of the rectangle. */
|
|
29
|
+
top: number;
|
|
30
|
+
/** The width of the rectangle. */
|
|
31
|
+
width?: number;
|
|
32
|
+
/** The height of the rectangle. */
|
|
33
|
+
height?: number;
|
|
34
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Checks whether the given value is a valid URL.
|
|
3
|
+
*
|
|
4
|
+
* ```ts
|
|
5
|
+
* isUrl("https://example.com"); // true
|
|
6
|
+
* isUrl("example.com"); // false
|
|
7
|
+
* ```
|
|
8
|
+
*
|
|
9
|
+
* @param {string} value - The value to be checked.
|
|
10
|
+
* @param {boolean} lenient - Whether to be lenient when checking the URL.
|
|
11
|
+
* @returns {boolean} - True if the value is a valid URL, false otherwise.
|
|
12
|
+
*/
|
|
13
|
+
export declare function isUrl(value: string, lenient?: boolean): boolean;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@baseline-ui/core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.60.0",
|
|
4
4
|
"description": "Baseline UI is a set of accessible components and tools for building accessible, customizable, production-ready user interfaces",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -36,9 +36,9 @@
|
|
|
36
36
|
"slate-hyperscript": "^0.100.0",
|
|
37
37
|
"tailwind-merge": "^3.5.0",
|
|
38
38
|
"use-sync-external-store": "1.6.0",
|
|
39
|
-
"@baseline-ui/css": "0.
|
|
40
|
-
"@baseline-ui/icons": "0.
|
|
41
|
-
"@baseline-ui/tokens": "0.
|
|
39
|
+
"@baseline-ui/css": "0.60.0",
|
|
40
|
+
"@baseline-ui/icons": "0.60.0",
|
|
41
|
+
"@baseline-ui/tokens": "0.60.0"
|
|
42
42
|
},
|
|
43
43
|
"peerDependencies": {
|
|
44
44
|
"react": "^18.0.0",
|
|
@@ -49,15 +49,15 @@
|
|
|
49
49
|
"@types/dompurify": "3.2.0",
|
|
50
50
|
"@types/markdown-it": "^14.1.2",
|
|
51
51
|
"@vanilla-extract/recipes": "0.5.7",
|
|
52
|
-
"@baseline-ui/translations": "0.
|
|
52
|
+
"@baseline-ui/translations": "0.60.0"
|
|
53
53
|
},
|
|
54
54
|
"license": "SEE LICENSE IN https://pspdfkit.com/legal/License.pdf",
|
|
55
55
|
"publishConfig": {
|
|
56
56
|
"access": "public"
|
|
57
57
|
},
|
|
58
58
|
"scripts": {
|
|
59
|
-
"build": "tsup src/index.ts --format cjs,esm --clean --
|
|
60
|
-
"build:dts": "
|
|
59
|
+
"build": "tsup src/index.ts --format cjs,esm --clean --minify --treeshake --no-dts && pnpm run build:dts",
|
|
60
|
+
"build:dts": "tsc -p tsconfig.dts.json",
|
|
61
61
|
"build:docs": "typedoc --useCodeBlocks --enumMembersFormat table --hidePageTitle --parametersFormat table --propertiesFormat table --hidePageHeader --indexFormat table --typeDeclarationFormat table --hideBreadcrumbs --outputFileStrategy modules",
|
|
62
62
|
"acknowledgements": "pnpm-licenses generate-disclaimer --prod --output-file=Acknowledgements.md"
|
|
63
63
|
}
|