@knitui/components 0.14.0 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/lib/commonjs/Accordion/Accordion.js +78 -96
- package/lib/commonjs/Accordion/Accordion.js.map +1 -1
- package/lib/commonjs/ActionIcon/ActionIcon.js +128 -62
- package/lib/commonjs/ActionIcon/ActionIcon.js.map +1 -1
- package/lib/commonjs/Affix/Affix.js +17 -21
- package/lib/commonjs/Affix/Affix.js.map +1 -1
- package/lib/commonjs/Alert/Alert.js +54 -54
- package/lib/commonjs/Alert/Alert.js.map +1 -1
- package/lib/commonjs/Anchor/Anchor.js +12 -15
- package/lib/commonjs/Anchor/Anchor.js.map +1 -1
- package/lib/commonjs/AngleSlider/AngleSlider.js +65 -37
- package/lib/commonjs/AngleSlider/AngleSlider.js.map +1 -1
- package/lib/commonjs/AspectRatio/AspectRatio.js +12 -15
- package/lib/commonjs/AspectRatio/AspectRatio.js.map +1 -1
- package/lib/commonjs/Autocomplete/Autocomplete.js +7 -3
- package/lib/commonjs/Autocomplete/Autocomplete.js.map +1 -1
- package/lib/commonjs/Avatar/Avatar.js +28 -25
- package/lib/commonjs/Avatar/Avatar.js.map +1 -1
- package/lib/commonjs/BackgroundImage/BackgroundImage.js +15 -6
- package/lib/commonjs/BackgroundImage/BackgroundImage.js.map +1 -1
- package/lib/commonjs/Badge/Badge.js +60 -49
- package/lib/commonjs/Badge/Badge.js.map +1 -1
- package/lib/commonjs/Blockquote/Blockquote.js +80 -79
- package/lib/commonjs/Blockquote/Blockquote.js.map +1 -1
- package/lib/commonjs/Box/Box.js +2 -2
- package/lib/commonjs/Box/Box.js.map +1 -1
- package/lib/commonjs/Breadcrumbs/Breadcrumbs.js +9 -9
- package/lib/commonjs/Breadcrumbs/Breadcrumbs.js.map +1 -1
- package/lib/commonjs/Burger/Burger.js +31 -20
- package/lib/commonjs/Burger/Burger.js.map +1 -1
- package/lib/commonjs/Button/Button.js +105 -63
- package/lib/commonjs/Button/Button.js.map +1 -1
- package/lib/commonjs/Card/Card.js +49 -37
- package/lib/commonjs/Card/Card.js.map +1 -1
- package/lib/commonjs/Center/Center.js +2 -2
- package/lib/commonjs/Center/Center.js.map +1 -1
- package/lib/commonjs/Checkbox/CheckIcon.js +5 -4
- package/lib/commonjs/Checkbox/CheckIcon.js.map +1 -1
- package/lib/commonjs/Checkbox/Checkbox.js +98 -68
- package/lib/commonjs/Checkbox/Checkbox.js.map +1 -1
- package/lib/commonjs/Chip/Chip.js +34 -67
- package/lib/commonjs/Chip/Chip.js.map +1 -1
- package/lib/commonjs/CloseButton/CloseButton.js +12 -5
- package/lib/commonjs/CloseButton/CloseButton.js.map +1 -1
- package/lib/commonjs/Code/Code.js +14 -10
- package/lib/commonjs/Code/Code.js.map +1 -1
- package/lib/commonjs/Collapse/Collapse.js +10 -4
- package/lib/commonjs/Collapse/Collapse.js.map +1 -1
- package/lib/commonjs/ColorInput/ColorInput.js +25 -20
- package/lib/commonjs/ColorInput/ColorInput.js.map +1 -1
- package/lib/commonjs/ColorPicker/ColorPicker.js +95 -83
- package/lib/commonjs/ColorPicker/ColorPicker.js.map +1 -1
- package/lib/commonjs/ColorSwatch/ColorSwatch.js +12 -14
- package/lib/commonjs/ColorSwatch/ColorSwatch.js.map +1 -1
- package/lib/commonjs/Combobox/Combobox.js +194 -187
- package/lib/commonjs/Combobox/Combobox.js.map +1 -1
- package/lib/commonjs/Combobox/OptionsDropdown.js +12 -6
- package/lib/commonjs/Combobox/OptionsDropdown.js.map +1 -1
- package/lib/commonjs/Combobox/index.js +6 -0
- package/lib/commonjs/Combobox/index.js.map +1 -1
- package/lib/commonjs/Container/Container.js +12 -19
- package/lib/commonjs/Container/Container.js.map +1 -1
- package/lib/commonjs/Dialog/Dialog.js +15 -14
- package/lib/commonjs/Dialog/Dialog.js.map +1 -1
- package/lib/commonjs/Drawer/Drawer.js +51 -32
- package/lib/commonjs/Drawer/Drawer.js.map +1 -1
- package/lib/commonjs/Fieldset/Fieldset.js +26 -18
- package/lib/commonjs/Fieldset/Fieldset.js.map +1 -1
- package/lib/commonjs/FileButton/FileButton.js +5 -3
- package/lib/commonjs/FileButton/FileButton.js.map +1 -1
- package/lib/commonjs/Flex/Flex.js +24 -27
- package/lib/commonjs/Flex/Flex.js.map +1 -1
- package/lib/commonjs/FocusTrap/FocusTrap.js +4 -3
- package/lib/commonjs/FocusTrap/FocusTrap.js.map +1 -1
- package/lib/commonjs/Grid/Grid.js +21 -18
- package/lib/commonjs/Grid/Grid.js.map +1 -1
- package/lib/commonjs/Group/Group.js +3 -3
- package/lib/commonjs/Group/Group.js.map +1 -1
- package/lib/commonjs/Highlight/Highlight.js +2 -1
- package/lib/commonjs/Highlight/Highlight.js.map +1 -1
- package/lib/commonjs/HoverCard/HoverCard.js +6 -23
- package/lib/commonjs/HoverCard/HoverCard.js.map +1 -1
- package/lib/commonjs/Image/Image.native.js +1 -1
- package/lib/commonjs/Image/createImage.js +88 -56
- package/lib/commonjs/Image/createImage.js.map +1 -1
- package/lib/commonjs/Indicator/Indicator.js +36 -29
- package/lib/commonjs/Indicator/Indicator.js.map +1 -1
- package/lib/commonjs/Input/Input.js +87 -119
- package/lib/commonjs/Input/Input.js.map +1 -1
- package/lib/commonjs/Input/Input.native.js +54 -35
- package/lib/commonjs/Input/Input.native.js.map +1 -1
- package/lib/commonjs/Input/shared.js +148 -225
- package/lib/commonjs/Input/shared.js.map +1 -1
- package/lib/commonjs/InputBase/InputBase.js +2 -1
- package/lib/commonjs/InputBase/InputBase.js.map +1 -1
- package/lib/commonjs/Kbd/Kbd.js +12 -18
- package/lib/commonjs/Kbd/Kbd.js.map +1 -1
- package/lib/commonjs/KeyboardAvoidingView/KeyboardAvoidingView.native.js +2 -2
- package/lib/commonjs/KeyboardAvoidingView/KeyboardAvoidingView.native.js.map +1 -1
- package/lib/commonjs/KeyboardAwareScrollView/KeyboardAwareScrollView.native.js +1 -1
- package/lib/commonjs/KeyboardAwareScrollView/KeyboardAwareScrollView.native.js.map +1 -1
- package/lib/commonjs/List/List.js +10 -10
- package/lib/commonjs/List/List.js.map +1 -1
- package/lib/commonjs/Loader/Loader.js +31 -37
- package/lib/commonjs/Loader/Loader.js.map +1 -1
- package/lib/commonjs/LoadingOverlay/LoadingOverlay.js +2 -1
- package/lib/commonjs/LoadingOverlay/LoadingOverlay.js.map +1 -1
- package/lib/commonjs/Mark/Mark.js +12 -15
- package/lib/commonjs/Mark/Mark.js.map +1 -1
- package/lib/commonjs/Marquee/Marquee.js +66 -48
- package/lib/commonjs/Marquee/Marquee.js.map +1 -1
- package/lib/commonjs/MaskInput/MaskInput.js +2 -1
- package/lib/commonjs/MaskInput/MaskInput.js.map +1 -1
- package/lib/commonjs/Menu/Menu.js +84 -48
- package/lib/commonjs/Menu/Menu.js.map +1 -1
- package/lib/commonjs/Modal/Modal.js +34 -30
- package/lib/commonjs/Modal/Modal.js.map +1 -1
- package/lib/commonjs/Modal/drag/DragDismissHost.js +4 -1
- package/lib/commonjs/Modal/drag/DragDismissHost.js.map +1 -1
- package/lib/commonjs/Modal/drag/DragDismissHost.web.js +10 -6
- package/lib/commonjs/Modal/drag/DragDismissHost.web.js.map +1 -1
- package/lib/commonjs/Modal/drag/DragDismissOverlay.js +4 -1
- package/lib/commonjs/Modal/drag/DragDismissOverlay.js.map +1 -1
- package/lib/commonjs/Modal/drag/DragDismissOverlay.web.js +6 -8
- package/lib/commonjs/Modal/drag/DragDismissOverlay.web.js.map +1 -1
- package/lib/commonjs/Modal/drag/index.js.map +1 -1
- package/lib/commonjs/Modal/drag/useDragDismiss.js +83 -67
- package/lib/commonjs/Modal/drag/useDragDismiss.js.map +1 -1
- package/lib/commonjs/Modal/modal-base-inner.js +1 -1
- package/lib/commonjs/Modal/modal-base-inner.js.map +1 -1
- package/lib/commonjs/Modal/modal-base-inner.native.js +3 -2
- package/lib/commonjs/Modal/modal-base-inner.native.js.map +1 -1
- package/lib/commonjs/Modal/modal-base.js +24 -11
- package/lib/commonjs/Modal/modal-base.js.map +1 -1
- package/lib/commonjs/MultiSelect/MultiSelect.js +6 -2
- package/lib/commonjs/MultiSelect/MultiSelect.js.map +1 -1
- package/lib/commonjs/NativeSelect/NativeSelect.js +25 -30
- package/lib/commonjs/NativeSelect/NativeSelect.js.map +1 -1
- package/lib/commonjs/NavLink/NavLink.js +63 -58
- package/lib/commonjs/NavLink/NavLink.js.map +1 -1
- package/lib/commonjs/Notification/Notification.js +28 -28
- package/lib/commonjs/Notification/Notification.js.map +1 -1
- package/lib/commonjs/NumberFormatter/NumberFormatter.js +2 -2
- package/lib/commonjs/NumberFormatter/NumberFormatter.js.map +1 -1
- package/lib/commonjs/NumberInput/NumberInput.js +46 -43
- package/lib/commonjs/NumberInput/NumberInput.js.map +1 -1
- package/lib/commonjs/Overlay/Overlay.js +18 -11
- package/lib/commonjs/Overlay/Overlay.js.map +1 -1
- package/lib/commonjs/Pagination/Pagination.js +125 -120
- package/lib/commonjs/Pagination/Pagination.js.map +1 -1
- package/lib/commonjs/Paper/Paper.js +7 -8
- package/lib/commonjs/Paper/Paper.js.map +1 -1
- package/lib/commonjs/Paragraph/Paragraph.js +7 -10
- package/lib/commonjs/Paragraph/Paragraph.js.map +1 -1
- package/lib/commonjs/PasswordInput/PasswordInput.js +3 -3
- package/lib/commonjs/PasswordInput/PasswordInput.js.map +1 -1
- package/lib/commonjs/Pill/Pill.js +40 -34
- package/lib/commonjs/Pill/Pill.js.map +1 -1
- package/lib/commonjs/PillsInput/PillsInput.js +58 -31
- package/lib/commonjs/PillsInput/PillsInput.js.map +1 -1
- package/lib/commonjs/PinInput/PinInput.js +26 -20
- package/lib/commonjs/PinInput/PinInput.js.map +1 -1
- package/lib/commonjs/Popover/Popover.native.js +6 -2
- package/lib/commonjs/Popover/Popover.native.js.map +1 -1
- package/lib/commonjs/Popover/Popover.shared.js +34 -23
- package/lib/commonjs/Popover/Popover.shared.js.map +1 -1
- package/lib/commonjs/Portal/OverlayHost.js.map +1 -1
- package/lib/commonjs/Portal/OverlayPortal.js +33 -0
- package/lib/commonjs/Portal/OverlayPortal.js.map +1 -0
- package/lib/commonjs/Portal/index.js +7 -0
- package/lib/commonjs/Portal/index.js.map +1 -1
- package/lib/commonjs/Progress/Progress.js +37 -26
- package/lib/commonjs/Progress/Progress.js.map +1 -1
- package/lib/commonjs/Radio/Radio.js +81 -93
- package/lib/commonjs/Radio/Radio.js.map +1 -1
- package/lib/commonjs/Radio/RadioIcon.js +4 -6
- package/lib/commonjs/Radio/RadioIcon.js.map +1 -1
- package/lib/commonjs/Rating/Rating.js +48 -38
- package/lib/commonjs/Rating/Rating.js.map +1 -1
- package/lib/commonjs/RollingNumber/RollingNumber.js +48 -24
- package/lib/commonjs/RollingNumber/RollingNumber.js.map +1 -1
- package/lib/commonjs/ScrollArea/ScrollArea.js +40 -37
- package/lib/commonjs/ScrollArea/ScrollArea.js.map +1 -1
- package/lib/commonjs/ScrollArea/ScrollArea.native.js +46 -41
- package/lib/commonjs/ScrollArea/ScrollArea.native.js.map +1 -1
- package/lib/commonjs/SegmentedControl/SegmentedControl.js +106 -55
- package/lib/commonjs/SegmentedControl/SegmentedControl.js.map +1 -1
- package/lib/commonjs/Select/Select.js +7 -3
- package/lib/commonjs/Select/Select.js.map +1 -1
- package/lib/commonjs/Separator/Separator.js +47 -39
- package/lib/commonjs/Separator/Separator.js.map +1 -1
- package/lib/commonjs/SimpleGrid/SimpleGrid.js +12 -14
- package/lib/commonjs/SimpleGrid/SimpleGrid.js.map +1 -1
- package/lib/commonjs/Skeleton/Skeleton.js +39 -24
- package/lib/commonjs/Skeleton/Skeleton.js.map +1 -1
- package/lib/commonjs/Slider/Slider.js +308 -257
- package/lib/commonjs/Slider/Slider.js.map +1 -1
- package/lib/commonjs/Spacer/Spacer.js +15 -29
- package/lib/commonjs/Spacer/Spacer.js.map +1 -1
- package/lib/commonjs/Spoiler/Spoiler.js +16 -16
- package/lib/commonjs/Spoiler/Spoiler.js.map +1 -1
- package/lib/commonjs/Stack/Stack.js +3 -3
- package/lib/commonjs/Stack/Stack.js.map +1 -1
- package/lib/commonjs/Stepper/Stepper.js +96 -71
- package/lib/commonjs/Stepper/Stepper.js.map +1 -1
- package/lib/commonjs/Switch/Switch.js +71 -67
- package/lib/commonjs/Switch/Switch.js.map +1 -1
- package/lib/commonjs/Table/Table.js +96 -82
- package/lib/commonjs/Table/Table.js.map +1 -1
- package/lib/commonjs/TableOfContents/TableOfContents.js +94 -95
- package/lib/commonjs/TableOfContents/TableOfContents.js.map +1 -1
- package/lib/commonjs/Tabs/Tabs.js +71 -73
- package/lib/commonjs/Tabs/Tabs.js.map +1 -1
- package/lib/commonjs/TagsInput/TagsInput.js +19 -3
- package/lib/commonjs/TagsInput/TagsInput.js.map +1 -1
- package/lib/commonjs/Text/Text.js +29 -14
- package/lib/commonjs/Text/Text.js.map +1 -1
- package/lib/commonjs/TextInput/TextInput.js +2 -1
- package/lib/commonjs/TextInput/TextInput.js.map +1 -1
- package/lib/commonjs/Textarea/Textarea.js +1 -1
- package/lib/commonjs/Textarea/Textarea.js.map +1 -1
- package/lib/commonjs/ThemeIcon/ThemeIcon.js +10 -6
- package/lib/commonjs/ThemeIcon/ThemeIcon.js.map +1 -1
- package/lib/commonjs/Title/Title.js +49 -32
- package/lib/commonjs/Title/Title.js.map +1 -1
- package/lib/commonjs/Tooltip/Tooltip.js +44 -28
- package/lib/commonjs/Tooltip/Tooltip.js.map +1 -1
- package/lib/commonjs/Transition/Transition.native.js +11 -10
- package/lib/commonjs/Transition/Transition.native.js.map +1 -1
- package/lib/commonjs/Transition/use-overlay-transition.native.js +2 -5
- package/lib/commonjs/Transition/use-overlay-transition.native.js.map +1 -1
- package/lib/commonjs/Tree/Tree.js +30 -34
- package/lib/commonjs/Tree/Tree.js.map +1 -1
- package/lib/commonjs/TreeSelect/TreeSelect.js +50 -26
- package/lib/commonjs/TreeSelect/TreeSelect.js.map +1 -1
- package/lib/commonjs/Typography/Typography.js +5 -7
- package/lib/commonjs/Typography/Typography.js.map +1 -1
- package/lib/commonjs/UnstyledButton/UnstyledButton.js +4 -4
- package/lib/commonjs/UnstyledButton/UnstyledButton.js.map +1 -1
- package/lib/commonjs/VirtualList/VirtualList.js +23 -7
- package/lib/commonjs/VirtualList/VirtualList.js.map +1 -1
- package/lib/commonjs/VisuallyHidden/VisuallyHidden.js +7 -10
- package/lib/commonjs/VisuallyHidden/VisuallyHidden.js.map +1 -1
- package/lib/commonjs/control-system.js +7 -0
- package/lib/commonjs/control-system.js.map +1 -1
- package/lib/commonjs/index.js +12 -0
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/internal/ControlIconProvider.js +1 -1
- package/lib/commonjs/internal/ControlIconProvider.js.map +1 -1
- package/lib/commonjs/internal/InlineControl.js +24 -29
- package/lib/commonjs/internal/InlineControl.js.map +1 -1
- package/lib/commonjs/internal/collapse-box.js +12 -10
- package/lib/commonjs/internal/collapse-box.js.map +1 -1
- package/lib/commonjs/internal/control-icon-size.js +5 -8
- package/lib/commonjs/internal/control-icon-size.js.map +1 -1
- package/lib/commonjs/internal/control-metrics.js +51 -51
- package/lib/commonjs/internal/control-metrics.js.map +1 -1
- package/lib/commonjs/internal/floating-arrow.js +43 -29
- package/lib/commonjs/internal/floating-arrow.js.map +1 -1
- package/lib/commonjs/internal/focus-ring.js +99 -0
- package/lib/commonjs/internal/focus-ring.js.map +1 -0
- package/lib/commonjs/internal/gradient-shared.js +18 -8
- package/lib/commonjs/internal/gradient-shared.js.map +1 -1
- package/lib/commonjs/internal/gradient.js +6 -0
- package/lib/commonjs/internal/gradient.js.map +1 -1
- package/lib/commonjs/internal/gradient.native.js +7 -1
- package/lib/commonjs/internal/gradient.native.js.map +1 -1
- package/lib/commonjs/internal/motion.js +247 -359
- package/lib/commonjs/internal/motion.js.map +1 -1
- package/lib/commonjs/internal/resolve-theme-color.js +10 -10
- package/lib/commonjs/internal/resolve-theme-color.js.map +1 -1
- package/lib/commonjs/internal/style-props.js +510 -464
- package/lib/commonjs/internal/style-props.js.map +1 -1
- package/lib/commonjs/internal/theme-color-web.js +44 -26
- package/lib/commonjs/internal/theme-color-web.js.map +1 -1
- package/lib/commonjs/internal/use-icon-color.js +1 -1
- package/lib/commonjs/internal/use-icon-color.native.js +1 -1
- package/lib/commonjs/internal/use-looping-animation.native.js +1 -1
- package/lib/commonjs/internal/use-looping-animation.native.js.map +1 -1
- package/lib/commonjs/internal/use-slot-text-wrapper.js +1 -1
- package/lib/commonjs/internal/variant-colors.js +163 -229
- package/lib/commonjs/internal/variant-colors.js.map +1 -1
- package/lib/module/Accordion/Accordion.js +80 -98
- package/lib/module/Accordion/Accordion.js.map +1 -1
- package/lib/module/ActionIcon/ActionIcon.js +130 -64
- package/lib/module/ActionIcon/ActionIcon.js.map +1 -1
- package/lib/module/Affix/Affix.js +19 -23
- package/lib/module/Affix/Affix.js.map +1 -1
- package/lib/module/Alert/Alert.js +56 -56
- package/lib/module/Alert/Alert.js.map +1 -1
- package/lib/module/Anchor/Anchor.js +13 -16
- package/lib/module/Anchor/Anchor.js.map +1 -1
- package/lib/module/AngleSlider/AngleSlider.js +66 -38
- package/lib/module/AngleSlider/AngleSlider.js.map +1 -1
- package/lib/module/AspectRatio/AspectRatio.js +10 -14
- package/lib/module/AspectRatio/AspectRatio.js.map +1 -1
- package/lib/module/Autocomplete/Autocomplete.js +8 -4
- package/lib/module/Autocomplete/Autocomplete.js.map +1 -1
- package/lib/module/Avatar/Avatar.js +31 -28
- package/lib/module/Avatar/Avatar.js.map +1 -1
- package/lib/module/BackgroundImage/BackgroundImage.js +16 -7
- package/lib/module/BackgroundImage/BackgroundImage.js.map +1 -1
- package/lib/module/Badge/Badge.js +63 -52
- package/lib/module/Badge/Badge.js.map +1 -1
- package/lib/module/Blockquote/Blockquote.js +82 -81
- package/lib/module/Blockquote/Blockquote.js.map +1 -1
- package/lib/module/Box/Box.js +2 -2
- package/lib/module/Box/Box.js.map +1 -1
- package/lib/module/Breadcrumbs/Breadcrumbs.js +10 -10
- package/lib/module/Breadcrumbs/Breadcrumbs.js.map +1 -1
- package/lib/module/Burger/Burger.js +32 -21
- package/lib/module/Burger/Burger.js.map +1 -1
- package/lib/module/Button/Button.js +107 -65
- package/lib/module/Button/Button.js.map +1 -1
- package/lib/module/Card/Card.js +51 -39
- package/lib/module/Card/Card.js.map +1 -1
- package/lib/module/Center/Center.js +3 -3
- package/lib/module/Center/Center.js.map +1 -1
- package/lib/module/Checkbox/CheckIcon.js +5 -4
- package/lib/module/Checkbox/CheckIcon.js.map +1 -1
- package/lib/module/Checkbox/Checkbox.js +100 -70
- package/lib/module/Checkbox/Checkbox.js.map +1 -1
- package/lib/module/Chip/Chip.js +35 -68
- package/lib/module/Chip/Chip.js.map +1 -1
- package/lib/module/CloseButton/CloseButton.js +14 -7
- package/lib/module/CloseButton/CloseButton.js.map +1 -1
- package/lib/module/Code/Code.js +15 -11
- package/lib/module/Code/Code.js.map +1 -1
- package/lib/module/Collapse/Collapse.js +11 -5
- package/lib/module/Collapse/Collapse.js.map +1 -1
- package/lib/module/ColorInput/ColorInput.js +26 -21
- package/lib/module/ColorInput/ColorInput.js.map +1 -1
- package/lib/module/ColorPicker/ColorPicker.js +96 -84
- package/lib/module/ColorPicker/ColorPicker.js.map +1 -1
- package/lib/module/ColorSwatch/ColorSwatch.js +13 -15
- package/lib/module/ColorSwatch/ColorSwatch.js.map +1 -1
- package/lib/module/Combobox/Combobox.js +194 -188
- package/lib/module/Combobox/Combobox.js.map +1 -1
- package/lib/module/Combobox/OptionsDropdown.js +13 -7
- package/lib/module/Combobox/OptionsDropdown.js.map +1 -1
- package/lib/module/Combobox/index.js +1 -1
- package/lib/module/Combobox/index.js.map +1 -1
- package/lib/module/Container/Container.js +12 -19
- package/lib/module/Container/Container.js.map +1 -1
- package/lib/module/Dialog/Dialog.js +16 -15
- package/lib/module/Dialog/Dialog.js.map +1 -1
- package/lib/module/Drawer/Drawer.js +53 -34
- package/lib/module/Drawer/Drawer.js.map +1 -1
- package/lib/module/Fieldset/Fieldset.js +27 -19
- package/lib/module/Fieldset/Fieldset.js.map +1 -1
- package/lib/module/FileButton/FileButton.js +5 -3
- package/lib/module/FileButton/FileButton.js.map +1 -1
- package/lib/module/Flex/Flex.js +24 -28
- package/lib/module/Flex/Flex.js.map +1 -1
- package/lib/module/FocusTrap/FocusTrap.js +4 -3
- package/lib/module/FocusTrap/FocusTrap.js.map +1 -1
- package/lib/module/Grid/Grid.js +22 -19
- package/lib/module/Grid/Grid.js.map +1 -1
- package/lib/module/Group/Group.js +4 -4
- package/lib/module/Group/Group.js.map +1 -1
- package/lib/module/Highlight/Highlight.js +2 -1
- package/lib/module/Highlight/Highlight.js.map +1 -1
- package/lib/module/HoverCard/HoverCard.js +8 -25
- package/lib/module/HoverCard/HoverCard.js.map +1 -1
- package/lib/module/Image/Image.native.js +1 -1
- package/lib/module/Image/createImage.js +88 -56
- package/lib/module/Image/createImage.js.map +1 -1
- package/lib/module/Indicator/Indicator.js +37 -30
- package/lib/module/Indicator/Indicator.js.map +1 -1
- package/lib/module/Input/Input.js +89 -121
- package/lib/module/Input/Input.js.map +1 -1
- package/lib/module/Input/Input.native.js +56 -37
- package/lib/module/Input/Input.native.js.map +1 -1
- package/lib/module/Input/shared.js +148 -225
- package/lib/module/Input/shared.js.map +1 -1
- package/lib/module/InputBase/InputBase.js +2 -1
- package/lib/module/InputBase/InputBase.js.map +1 -1
- package/lib/module/Kbd/Kbd.js +12 -18
- package/lib/module/Kbd/Kbd.js.map +1 -1
- package/lib/module/KeyboardAvoidingView/KeyboardAvoidingView.native.js +2 -2
- package/lib/module/KeyboardAvoidingView/KeyboardAvoidingView.native.js.map +1 -1
- package/lib/module/KeyboardAwareScrollView/KeyboardAwareScrollView.native.js +1 -1
- package/lib/module/KeyboardAwareScrollView/KeyboardAwareScrollView.native.js.map +1 -1
- package/lib/module/List/List.js +11 -11
- package/lib/module/List/List.js.map +1 -1
- package/lib/module/Loader/Loader.js +33 -39
- package/lib/module/Loader/Loader.js.map +1 -1
- package/lib/module/LoadingOverlay/LoadingOverlay.js +2 -1
- package/lib/module/LoadingOverlay/LoadingOverlay.js.map +1 -1
- package/lib/module/Mark/Mark.js +11 -15
- package/lib/module/Mark/Mark.js.map +1 -1
- package/lib/module/Marquee/Marquee.js +66 -48
- package/lib/module/Marquee/Marquee.js.map +1 -1
- package/lib/module/MaskInput/MaskInput.js +2 -1
- package/lib/module/MaskInput/MaskInput.js.map +1 -1
- package/lib/module/Menu/Menu.js +86 -50
- package/lib/module/Menu/Menu.js.map +1 -1
- package/lib/module/Modal/Modal.js +35 -31
- package/lib/module/Modal/Modal.js.map +1 -1
- package/lib/module/Modal/drag/DragDismissHost.js +4 -1
- package/lib/module/Modal/drag/DragDismissHost.js.map +1 -1
- package/lib/module/Modal/drag/DragDismissHost.web.js +10 -6
- package/lib/module/Modal/drag/DragDismissHost.web.js.map +1 -1
- package/lib/module/Modal/drag/DragDismissOverlay.js +4 -1
- package/lib/module/Modal/drag/DragDismissOverlay.js.map +1 -1
- package/lib/module/Modal/drag/DragDismissOverlay.web.js +6 -8
- package/lib/module/Modal/drag/DragDismissOverlay.web.js.map +1 -1
- package/lib/module/Modal/drag/index.js +1 -1
- package/lib/module/Modal/drag/index.js.map +1 -1
- package/lib/module/Modal/drag/useDragDismiss.js +84 -68
- package/lib/module/Modal/drag/useDragDismiss.js.map +1 -1
- package/lib/module/Modal/modal-base-inner.js +1 -1
- package/lib/module/Modal/modal-base-inner.js.map +1 -1
- package/lib/module/Modal/modal-base-inner.native.js +3 -2
- package/lib/module/Modal/modal-base-inner.native.js.map +1 -1
- package/lib/module/Modal/modal-base.js +25 -12
- package/lib/module/Modal/modal-base.js.map +1 -1
- package/lib/module/MultiSelect/MultiSelect.js +7 -3
- package/lib/module/MultiSelect/MultiSelect.js.map +1 -1
- package/lib/module/NativeSelect/NativeSelect.js +26 -31
- package/lib/module/NativeSelect/NativeSelect.js.map +1 -1
- package/lib/module/NavLink/NavLink.js +64 -59
- package/lib/module/NavLink/NavLink.js.map +1 -1
- package/lib/module/Notification/Notification.js +29 -29
- package/lib/module/Notification/Notification.js.map +1 -1
- package/lib/module/NumberFormatter/NumberFormatter.js +3 -3
- package/lib/module/NumberFormatter/NumberFormatter.js.map +1 -1
- package/lib/module/NumberInput/NumberInput.js +49 -46
- package/lib/module/NumberInput/NumberInput.js.map +1 -1
- package/lib/module/Overlay/Overlay.js +19 -12
- package/lib/module/Overlay/Overlay.js.map +1 -1
- package/lib/module/Pagination/Pagination.js +127 -122
- package/lib/module/Pagination/Pagination.js.map +1 -1
- package/lib/module/Paper/Paper.js +8 -9
- package/lib/module/Paper/Paper.js.map +1 -1
- package/lib/module/Paragraph/Paragraph.js +6 -10
- package/lib/module/Paragraph/Paragraph.js.map +1 -1
- package/lib/module/PasswordInput/PasswordInput.js +4 -4
- package/lib/module/PasswordInput/PasswordInput.js.map +1 -1
- package/lib/module/Pill/Pill.js +42 -36
- package/lib/module/Pill/Pill.js.map +1 -1
- package/lib/module/PillsInput/PillsInput.js +59 -32
- package/lib/module/PillsInput/PillsInput.js.map +1 -1
- package/lib/module/PinInput/PinInput.js +27 -21
- package/lib/module/PinInput/PinInput.js.map +1 -1
- package/lib/module/Popover/Popover.native.js +6 -2
- package/lib/module/Popover/Popover.native.js.map +1 -1
- package/lib/module/Popover/Popover.shared.js +36 -25
- package/lib/module/Popover/Popover.shared.js.map +1 -1
- package/lib/module/Portal/OverlayHost.js.map +1 -1
- package/lib/module/Portal/OverlayPortal.js +28 -0
- package/lib/module/Portal/OverlayPortal.js.map +1 -0
- package/lib/module/Portal/index.js +4 -0
- package/lib/module/Portal/index.js.map +1 -1
- package/lib/module/Progress/Progress.js +39 -28
- package/lib/module/Progress/Progress.js.map +1 -1
- package/lib/module/Radio/Radio.js +83 -95
- package/lib/module/Radio/Radio.js.map +1 -1
- package/lib/module/Radio/RadioIcon.js +4 -6
- package/lib/module/Radio/RadioIcon.js.map +1 -1
- package/lib/module/Rating/Rating.js +50 -40
- package/lib/module/Rating/Rating.js.map +1 -1
- package/lib/module/RollingNumber/RollingNumber.js +49 -25
- package/lib/module/RollingNumber/RollingNumber.js.map +1 -1
- package/lib/module/ScrollArea/ScrollArea.js +41 -38
- package/lib/module/ScrollArea/ScrollArea.js.map +1 -1
- package/lib/module/ScrollArea/ScrollArea.native.js +48 -43
- package/lib/module/ScrollArea/ScrollArea.native.js.map +1 -1
- package/lib/module/SegmentedControl/SegmentedControl.js +108 -57
- package/lib/module/SegmentedControl/SegmentedControl.js.map +1 -1
- package/lib/module/Select/Select.js +8 -4
- package/lib/module/Select/Select.js.map +1 -1
- package/lib/module/Separator/Separator.js +49 -41
- package/lib/module/Separator/Separator.js.map +1 -1
- package/lib/module/SimpleGrid/SimpleGrid.js +14 -16
- package/lib/module/SimpleGrid/SimpleGrid.js.map +1 -1
- package/lib/module/Skeleton/Skeleton.js +40 -25
- package/lib/module/Skeleton/Skeleton.js.map +1 -1
- package/lib/module/Slider/Slider.js +309 -258
- package/lib/module/Slider/Slider.js.map +1 -1
- package/lib/module/Spacer/Spacer.js +16 -29
- package/lib/module/Spacer/Spacer.js.map +1 -1
- package/lib/module/Spoiler/Spoiler.js +17 -17
- package/lib/module/Spoiler/Spoiler.js.map +1 -1
- package/lib/module/Stack/Stack.js +3 -3
- package/lib/module/Stack/Stack.js.map +1 -1
- package/lib/module/Stepper/Stepper.js +97 -72
- package/lib/module/Stepper/Stepper.js.map +1 -1
- package/lib/module/Switch/Switch.js +73 -69
- package/lib/module/Switch/Switch.js.map +1 -1
- package/lib/module/Table/Table.js +99 -85
- package/lib/module/Table/Table.js.map +1 -1
- package/lib/module/TableOfContents/TableOfContents.js +96 -97
- package/lib/module/TableOfContents/TableOfContents.js.map +1 -1
- package/lib/module/Tabs/Tabs.js +72 -74
- package/lib/module/Tabs/Tabs.js.map +1 -1
- package/lib/module/TagsInput/TagsInput.js +21 -5
- package/lib/module/TagsInput/TagsInput.js.map +1 -1
- package/lib/module/Text/Text.js +29 -14
- package/lib/module/Text/Text.js.map +1 -1
- package/lib/module/TextInput/TextInput.js +2 -1
- package/lib/module/TextInput/TextInput.js.map +1 -1
- package/lib/module/Textarea/Textarea.js +2 -2
- package/lib/module/Textarea/Textarea.js.map +1 -1
- package/lib/module/ThemeIcon/ThemeIcon.js +12 -8
- package/lib/module/ThemeIcon/ThemeIcon.js.map +1 -1
- package/lib/module/Title/Title.js +51 -34
- package/lib/module/Title/Title.js.map +1 -1
- package/lib/module/Tooltip/Tooltip.js +46 -30
- package/lib/module/Tooltip/Tooltip.js.map +1 -1
- package/lib/module/Transition/Transition.native.js +12 -11
- package/lib/module/Transition/Transition.native.js.map +1 -1
- package/lib/module/Transition/use-overlay-transition.native.js +3 -6
- package/lib/module/Transition/use-overlay-transition.native.js.map +1 -1
- package/lib/module/Tree/Tree.js +31 -35
- package/lib/module/Tree/Tree.js.map +1 -1
- package/lib/module/TreeSelect/TreeSelect.js +52 -28
- package/lib/module/TreeSelect/TreeSelect.js.map +1 -1
- package/lib/module/Typography/Typography.js +5 -7
- package/lib/module/Typography/Typography.js.map +1 -1
- package/lib/module/UnstyledButton/UnstyledButton.js +5 -5
- package/lib/module/UnstyledButton/UnstyledButton.js.map +1 -1
- package/lib/module/VirtualList/VirtualList.js +23 -7
- package/lib/module/VirtualList/VirtualList.js.map +1 -1
- package/lib/module/VisuallyHidden/VisuallyHidden.js +6 -10
- package/lib/module/VisuallyHidden/VisuallyHidden.js.map +1 -1
- package/lib/module/control-system.js +5 -0
- package/lib/module/control-system.js.map +1 -1
- package/lib/module/index.js +9 -5
- package/lib/module/index.js.map +1 -1
- package/lib/module/internal/ControlIconProvider.js +1 -1
- package/lib/module/internal/ControlIconProvider.js.map +1 -1
- package/lib/module/internal/InlineControl.js +25 -30
- package/lib/module/internal/InlineControl.js.map +1 -1
- package/lib/module/internal/collapse-box.js +13 -11
- package/lib/module/internal/collapse-box.js.map +1 -1
- package/lib/module/internal/control-icon-size.js +5 -8
- package/lib/module/internal/control-icon-size.js.map +1 -1
- package/lib/module/internal/control-metrics.js +52 -52
- package/lib/module/internal/control-metrics.js.map +1 -1
- package/lib/module/internal/floating-arrow.js +44 -30
- package/lib/module/internal/floating-arrow.js.map +1 -1
- package/lib/module/internal/focus-ring.js +95 -0
- package/lib/module/internal/focus-ring.js.map +1 -0
- package/lib/module/internal/gradient-shared.js +16 -7
- package/lib/module/internal/gradient-shared.js.map +1 -1
- package/lib/module/internal/gradient.js +2 -0
- package/lib/module/internal/gradient.js.map +1 -1
- package/lib/module/internal/gradient.native.js +3 -1
- package/lib/module/internal/gradient.native.js.map +1 -1
- package/lib/module/internal/motion.js +245 -359
- package/lib/module/internal/motion.js.map +1 -1
- package/lib/module/internal/resolve-theme-color.js +10 -10
- package/lib/module/internal/resolve-theme-color.js.map +1 -1
- package/lib/module/internal/style-props.js +471 -459
- package/lib/module/internal/style-props.js.map +1 -1
- package/lib/module/internal/theme-color-web.js +45 -27
- package/lib/module/internal/theme-color-web.js.map +1 -1
- package/lib/module/internal/use-icon-color.js +1 -1
- package/lib/module/internal/use-icon-color.native.js +1 -1
- package/lib/module/internal/use-looping-animation.native.js +1 -1
- package/lib/module/internal/use-looping-animation.native.js.map +1 -1
- package/lib/module/internal/use-slot-text-wrapper.js +1 -1
- package/lib/module/internal/variant-colors.js +150 -228
- package/lib/module/internal/variant-colors.js.map +1 -1
- package/lib/typescript/Accordion/Accordion.d.ts +120 -74
- package/lib/typescript/Accordion/Accordion.d.ts.map +1 -1
- package/lib/typescript/ActionIcon/ActionIcon.d.ts +236 -94
- package/lib/typescript/ActionIcon/ActionIcon.d.ts.map +1 -1
- package/lib/typescript/Affix/Affix.d.ts +12 -7
- package/lib/typescript/Affix/Affix.d.ts.map +1 -1
- package/lib/typescript/Alert/Alert.d.ts +228 -68
- package/lib/typescript/Alert/Alert.d.ts.map +1 -1
- package/lib/typescript/Anchor/Anchor.d.ts +33 -24
- package/lib/typescript/Anchor/Anchor.d.ts.map +1 -1
- package/lib/typescript/AngleSlider/AngleSlider.d.ts +224 -66
- package/lib/typescript/AngleSlider/AngleSlider.d.ts.map +1 -1
- package/lib/typescript/AspectRatio/AspectRatio.d.ts +34 -14
- package/lib/typescript/AspectRatio/AspectRatio.d.ts.map +1 -1
- package/lib/typescript/Autocomplete/Autocomplete.d.ts +30 -42
- package/lib/typescript/Autocomplete/Autocomplete.d.ts.map +1 -1
- package/lib/typescript/Avatar/Avatar.d.ts +174 -198
- package/lib/typescript/Avatar/Avatar.d.ts.map +1 -1
- package/lib/typescript/BackgroundImage/BackgroundImage.d.ts +15 -10
- package/lib/typescript/BackgroundImage/BackgroundImage.d.ts.map +1 -1
- package/lib/typescript/Badge/Badge.d.ts +138 -62
- package/lib/typescript/Badge/Badge.d.ts.map +1 -1
- package/lib/typescript/Blockquote/Blockquote.d.ts +148 -50
- package/lib/typescript/Blockquote/Blockquote.d.ts.map +1 -1
- package/lib/typescript/Box/Box.d.ts +11 -3
- package/lib/typescript/Box/Box.d.ts.map +1 -1
- package/lib/typescript/Breadcrumbs/Breadcrumbs.d.ts +115 -35
- package/lib/typescript/Breadcrumbs/Breadcrumbs.d.ts.map +1 -1
- package/lib/typescript/Burger/Burger.d.ts +124 -41
- package/lib/typescript/Burger/Burger.d.ts.map +1 -1
- package/lib/typescript/Button/Button.d.ts +236 -107
- package/lib/typescript/Button/Button.d.ts.map +1 -1
- package/lib/typescript/Card/Card.d.ts +79 -47
- package/lib/typescript/Card/Card.d.ts.map +1 -1
- package/lib/typescript/Center/Center.d.ts +13 -9
- package/lib/typescript/Center/Center.d.ts.map +1 -1
- package/lib/typescript/Checkbox/CheckIcon.d.ts +7 -3
- package/lib/typescript/Checkbox/CheckIcon.d.ts.map +1 -1
- package/lib/typescript/Checkbox/Checkbox.d.ts +79 -60
- package/lib/typescript/Checkbox/Checkbox.d.ts.map +1 -1
- package/lib/typescript/Chip/Chip.d.ts +140 -57
- package/lib/typescript/Chip/Chip.d.ts.map +1 -1
- package/lib/typescript/CloseButton/CloseButton.d.ts +85 -50
- package/lib/typescript/CloseButton/CloseButton.d.ts.map +1 -1
- package/lib/typescript/Code/Code.d.ts +31 -23
- package/lib/typescript/Code/Code.d.ts.map +1 -1
- package/lib/typescript/Collapse/Collapse.d.ts +44 -20
- package/lib/typescript/Collapse/Collapse.d.ts.map +1 -1
- package/lib/typescript/ColorInput/ColorInput.d.ts +15 -5
- package/lib/typescript/ColorInput/ColorInput.d.ts.map +1 -1
- package/lib/typescript/ColorPicker/ColorPicker.d.ts +72 -16
- package/lib/typescript/ColorPicker/ColorPicker.d.ts.map +1 -1
- package/lib/typescript/ColorSwatch/ColorSwatch.d.ts +59 -38
- package/lib/typescript/ColorSwatch/ColorSwatch.d.ts.map +1 -1
- package/lib/typescript/Combobox/Combobox.d.ts +183 -100
- package/lib/typescript/Combobox/Combobox.d.ts.map +1 -1
- package/lib/typescript/Combobox/OptionsDropdown.d.ts +6 -0
- package/lib/typescript/Combobox/OptionsDropdown.d.ts.map +1 -1
- package/lib/typescript/Combobox/index.d.ts +66 -86
- package/lib/typescript/Combobox/index.d.ts.map +1 -1
- package/lib/typescript/Container/Container.d.ts +3 -41
- package/lib/typescript/Container/Container.d.ts.map +1 -1
- package/lib/typescript/Dialog/Dialog.d.ts +79 -76
- package/lib/typescript/Dialog/Dialog.d.ts.map +1 -1
- package/lib/typescript/Drawer/Drawer.d.ts +115 -40
- package/lib/typescript/Drawer/Drawer.d.ts.map +1 -1
- package/lib/typescript/Fieldset/Fieldset.d.ts +91 -46
- package/lib/typescript/Fieldset/Fieldset.d.ts.map +1 -1
- package/lib/typescript/FileButton/FileButton.d.ts.map +1 -1
- package/lib/typescript/FileInput/FileInput.d.ts +1 -1
- package/lib/typescript/FileInput/FileInput.d.ts.map +1 -1
- package/lib/typescript/Flex/Flex.d.ts +28 -26
- package/lib/typescript/Flex/Flex.d.ts.map +1 -1
- package/lib/typescript/FocusTrap/FocusTrap.d.ts.map +1 -1
- package/lib/typescript/Grid/Grid.d.ts +56 -48
- package/lib/typescript/Grid/Grid.d.ts.map +1 -1
- package/lib/typescript/Group/Group.d.ts +21 -16
- package/lib/typescript/Group/Group.d.ts.map +1 -1
- package/lib/typescript/Highlight/Highlight.d.ts +1 -15
- package/lib/typescript/Highlight/Highlight.d.ts.map +1 -1
- package/lib/typescript/HoverCard/HoverCard.d.ts +9 -9
- package/lib/typescript/HoverCard/HoverCard.d.ts.map +1 -1
- package/lib/typescript/Image/Image.d.ts +53 -121
- package/lib/typescript/Image/Image.d.ts.map +1 -1
- package/lib/typescript/Image/Image.native.d.ts +54 -122
- package/lib/typescript/Image/Image.native.d.ts.map +1 -1
- package/lib/typescript/Image/createImage.d.ts +56 -364
- package/lib/typescript/Image/createImage.d.ts.map +1 -1
- package/lib/typescript/Image/types.d.ts +4 -1
- package/lib/typescript/Image/types.d.ts.map +1 -1
- package/lib/typescript/Indicator/Indicator.d.ts +122 -43
- package/lib/typescript/Indicator/Indicator.d.ts.map +1 -1
- package/lib/typescript/Input/Input.d.ts +131 -328
- package/lib/typescript/Input/Input.d.ts.map +1 -1
- package/lib/typescript/Input/Input.native.d.ts +150 -472
- package/lib/typescript/Input/Input.native.d.ts.map +1 -1
- package/lib/typescript/Input/shared.d.ts +290 -490
- package/lib/typescript/Input/shared.d.ts.map +1 -1
- package/lib/typescript/Input/types.d.ts +14 -1
- package/lib/typescript/Input/types.d.ts.map +1 -1
- package/lib/typescript/InputBase/InputBase.d.ts +1 -52
- package/lib/typescript/InputBase/InputBase.d.ts.map +1 -1
- package/lib/typescript/Kbd/Kbd.d.ts +21 -65
- package/lib/typescript/Kbd/Kbd.d.ts.map +1 -1
- package/lib/typescript/KeyboardAvoidingView/KeyboardAvoidingView.d.ts +2 -6
- package/lib/typescript/KeyboardAvoidingView/KeyboardAvoidingView.d.ts.map +1 -1
- package/lib/typescript/KeyboardAvoidingView/KeyboardAvoidingView.native.d.ts +7 -3
- package/lib/typescript/KeyboardAvoidingView/KeyboardAvoidingView.native.d.ts.map +1 -1
- package/lib/typescript/KeyboardAwareScrollView/KeyboardAwareScrollView.d.ts +2 -6
- package/lib/typescript/KeyboardAwareScrollView/KeyboardAwareScrollView.d.ts.map +1 -1
- package/lib/typescript/KeyboardAwareScrollView/KeyboardAwareScrollView.native.d.ts +13 -15
- package/lib/typescript/KeyboardAwareScrollView/KeyboardAwareScrollView.native.d.ts.map +1 -1
- package/lib/typescript/List/List.d.ts +165 -63
- package/lib/typescript/List/List.d.ts.map +1 -1
- package/lib/typescript/Loader/Loader.d.ts +58 -28
- package/lib/typescript/Loader/Loader.d.ts.map +1 -1
- package/lib/typescript/LoadingOverlay/LoadingOverlay.d.ts +1 -9
- package/lib/typescript/LoadingOverlay/LoadingOverlay.d.ts.map +1 -1
- package/lib/typescript/Mark/Mark.d.ts +21 -65
- package/lib/typescript/Mark/Mark.d.ts.map +1 -1
- package/lib/typescript/Marquee/Marquee.d.ts +127 -44
- package/lib/typescript/Marquee/Marquee.d.ts.map +1 -1
- package/lib/typescript/MaskInput/MaskInput.d.ts +1 -51
- package/lib/typescript/MaskInput/MaskInput.d.ts.map +1 -1
- package/lib/typescript/Menu/Menu.d.ts +93 -105
- package/lib/typescript/Menu/Menu.d.ts.map +1 -1
- package/lib/typescript/Modal/Modal.d.ts +166 -91
- package/lib/typescript/Modal/Modal.d.ts.map +1 -1
- package/lib/typescript/Modal/drag/DragDismissHost.d.ts.map +1 -1
- package/lib/typescript/Modal/drag/DragDismissHost.web.d.ts.map +1 -1
- package/lib/typescript/Modal/drag/DragDismissOverlay.d.ts.map +1 -1
- package/lib/typescript/Modal/drag/DragDismissOverlay.web.d.ts.map +1 -1
- package/lib/typescript/Modal/drag/index.d.ts +2 -2
- package/lib/typescript/Modal/drag/index.d.ts.map +1 -1
- package/lib/typescript/Modal/drag/types.d.ts +14 -2
- package/lib/typescript/Modal/drag/types.d.ts.map +1 -1
- package/lib/typescript/Modal/drag/useDragDismiss.d.ts +2 -2
- package/lib/typescript/Modal/drag/useDragDismiss.d.ts.map +1 -1
- package/lib/typescript/Modal/modal-base-inner.d.ts +6 -2
- package/lib/typescript/Modal/modal-base-inner.d.ts.map +1 -1
- package/lib/typescript/Modal/modal-base-inner.native.d.ts +7 -3
- package/lib/typescript/Modal/modal-base-inner.native.d.ts.map +1 -1
- package/lib/typescript/Modal/modal-base.d.ts +2 -2
- package/lib/typescript/Modal/modal-base.d.ts.map +1 -1
- package/lib/typescript/MultiSelect/MultiSelect.d.ts +30 -50
- package/lib/typescript/MultiSelect/MultiSelect.d.ts.map +1 -1
- package/lib/typescript/NativeSelect/NativeSelect.d.ts.map +1 -1
- package/lib/typescript/NativeSelect/NativeSelect.native.d.ts +1 -1
- package/lib/typescript/NativeSelect/NativeSelect.native.d.ts.map +1 -1
- package/lib/typescript/NavLink/NavLink.d.ts +245 -72
- package/lib/typescript/NavLink/NavLink.d.ts.map +1 -1
- package/lib/typescript/Notification/Notification.d.ts +230 -69
- package/lib/typescript/Notification/Notification.d.ts.map +1 -1
- package/lib/typescript/NumberFormatter/NumberFormatter.d.ts +24 -19
- package/lib/typescript/NumberFormatter/NumberFormatter.d.ts.map +1 -1
- package/lib/typescript/NumberInput/NumberInput.d.ts +91 -150
- package/lib/typescript/NumberInput/NumberInput.d.ts.map +1 -1
- package/lib/typescript/Overlay/Overlay.d.ts +17 -12
- package/lib/typescript/Overlay/Overlay.d.ts.map +1 -1
- package/lib/typescript/Pagination/Pagination.d.ts +43 -65
- package/lib/typescript/Pagination/Pagination.d.ts.map +1 -1
- package/lib/typescript/Paper/Paper.d.ts +19 -7
- package/lib/typescript/Paper/Paper.d.ts.map +1 -1
- package/lib/typescript/Paragraph/Paragraph.d.ts +23 -19
- package/lib/typescript/Paragraph/Paragraph.d.ts.map +1 -1
- package/lib/typescript/PasswordInput/PasswordInput.d.ts +110 -207
- package/lib/typescript/PasswordInput/PasswordInput.d.ts.map +1 -1
- package/lib/typescript/Pill/Pill.d.ts +133 -95
- package/lib/typescript/Pill/Pill.d.ts.map +1 -1
- package/lib/typescript/PillsInput/PillsInput.d.ts +2 -2
- package/lib/typescript/PillsInput/PillsInput.d.ts.map +1 -1
- package/lib/typescript/PinInput/PinInput.d.ts +148 -297
- package/lib/typescript/PinInput/PinInput.d.ts.map +1 -1
- package/lib/typescript/Popover/Popover.native.d.ts.map +1 -1
- package/lib/typescript/Popover/Popover.shared.d.ts +15 -11
- package/lib/typescript/Popover/Popover.shared.d.ts.map +1 -1
- package/lib/typescript/Portal/OverlayHost.d.ts +2 -2
- package/lib/typescript/Portal/OverlayHost.d.ts.map +1 -1
- package/lib/typescript/Portal/OverlayPortal.d.ts +19 -0
- package/lib/typescript/Portal/OverlayPortal.d.ts.map +1 -0
- package/lib/typescript/Portal/index.d.ts +4 -0
- package/lib/typescript/Portal/index.d.ts.map +1 -1
- package/lib/typescript/Progress/Progress.d.ts +114 -65
- package/lib/typescript/Progress/Progress.d.ts.map +1 -1
- package/lib/typescript/Radio/Radio.d.ts +69 -80
- package/lib/typescript/Radio/Radio.d.ts.map +1 -1
- package/lib/typescript/Radio/RadioIcon.d.ts +5 -0
- package/lib/typescript/Radio/RadioIcon.d.ts.map +1 -1
- package/lib/typescript/Rating/Rating.d.ts +94 -44
- package/lib/typescript/Rating/Rating.d.ts.map +1 -1
- package/lib/typescript/RollingNumber/RollingNumber.d.ts +112 -32
- package/lib/typescript/RollingNumber/RollingNumber.d.ts.map +1 -1
- package/lib/typescript/ScrollArea/ScrollArea.d.ts +50 -10
- package/lib/typescript/ScrollArea/ScrollArea.d.ts.map +1 -1
- package/lib/typescript/ScrollArea/ScrollArea.native.d.ts +40 -8
- package/lib/typescript/ScrollArea/ScrollArea.native.d.ts.map +1 -1
- package/lib/typescript/ScrollArea/ScrollArea.shared.d.ts +2 -2
- package/lib/typescript/SegmentedControl/SegmentedControl.d.ts +148 -56
- package/lib/typescript/SegmentedControl/SegmentedControl.d.ts.map +1 -1
- package/lib/typescript/Select/Select.d.ts +31 -51
- package/lib/typescript/Select/Select.d.ts.map +1 -1
- package/lib/typescript/Separator/Separator.d.ts +124 -61
- package/lib/typescript/Separator/Separator.d.ts.map +1 -1
- package/lib/typescript/SimpleGrid/SimpleGrid.d.ts +15 -13
- package/lib/typescript/SimpleGrid/SimpleGrid.d.ts.map +1 -1
- package/lib/typescript/Skeleton/Skeleton.d.ts +18 -14
- package/lib/typescript/Skeleton/Skeleton.d.ts.map +1 -1
- package/lib/typescript/Slider/Slider.d.ts +425 -129
- package/lib/typescript/Slider/Slider.d.ts.map +1 -1
- package/lib/typescript/Spacer/Spacer.d.ts +10 -17
- package/lib/typescript/Spacer/Spacer.d.ts.map +1 -1
- package/lib/typescript/Spoiler/Spoiler.d.ts +88 -28
- package/lib/typescript/Spoiler/Spoiler.d.ts.map +1 -1
- package/lib/typescript/Stack/Stack.d.ts +17 -5
- package/lib/typescript/Stack/Stack.d.ts.map +1 -1
- package/lib/typescript/Stepper/Stepper.d.ts +433 -101
- package/lib/typescript/Stepper/Stepper.d.ts.map +1 -1
- package/lib/typescript/Switch/Switch.d.ts +157 -69
- package/lib/typescript/Switch/Switch.d.ts.map +1 -1
- package/lib/typescript/Table/Table.d.ts +151 -201
- package/lib/typescript/Table/Table.d.ts.map +1 -1
- package/lib/typescript/TableOfContents/TableOfContents.d.ts +116 -46
- package/lib/typescript/TableOfContents/TableOfContents.d.ts.map +1 -1
- package/lib/typescript/Tabs/Tabs.d.ts +138 -88
- package/lib/typescript/Tabs/Tabs.d.ts.map +1 -1
- package/lib/typescript/TagsInput/TagsInput.d.ts +30 -42
- package/lib/typescript/TagsInput/TagsInput.d.ts.map +1 -1
- package/lib/typescript/Text/Text.d.ts +22 -4
- package/lib/typescript/Text/Text.d.ts.map +1 -1
- package/lib/typescript/TextInput/TextInput.d.ts +1 -51
- package/lib/typescript/TextInput/TextInput.d.ts.map +1 -1
- package/lib/typescript/Textarea/Textarea.d.ts +1 -51
- package/lib/typescript/Textarea/Textarea.d.ts.map +1 -1
- package/lib/typescript/ThemeIcon/ThemeIcon.d.ts +52 -39
- package/lib/typescript/ThemeIcon/ThemeIcon.d.ts.map +1 -1
- package/lib/typescript/Title/Title.d.ts +40 -25
- package/lib/typescript/Title/Title.d.ts.map +1 -1
- package/lib/typescript/Tooltip/Tooltip.d.ts +97 -41
- package/lib/typescript/Tooltip/Tooltip.d.ts.map +1 -1
- package/lib/typescript/Transition/Transition.native.d.ts.map +1 -1
- package/lib/typescript/Transition/use-overlay-transition.d.ts +1 -2
- package/lib/typescript/Transition/use-overlay-transition.d.ts.map +1 -1
- package/lib/typescript/Transition/use-overlay-transition.native.d.ts +3 -4
- package/lib/typescript/Transition/use-overlay-transition.native.d.ts.map +1 -1
- package/lib/typescript/Tree/Tree.d.ts +180 -50
- package/lib/typescript/Tree/Tree.d.ts.map +1 -1
- package/lib/typescript/TreeSelect/TreeSelect.d.ts +141 -182
- package/lib/typescript/TreeSelect/TreeSelect.d.ts.map +1 -1
- package/lib/typescript/Typography/Typography.d.ts +13 -7
- package/lib/typescript/Typography/Typography.d.ts.map +1 -1
- package/lib/typescript/UnstyledButton/UnstyledButton.d.ts +27 -20
- package/lib/typescript/UnstyledButton/UnstyledButton.d.ts.map +1 -1
- package/lib/typescript/VirtualList/VirtualList.d.ts.map +1 -1
- package/lib/typescript/VirtualList/VirtualList.shared.d.ts +1 -1
- package/lib/typescript/VirtualList/VirtualList.shared.d.ts.map +1 -1
- package/lib/typescript/VisuallyHidden/VisuallyHidden.d.ts +23 -19
- package/lib/typescript/VisuallyHidden/VisuallyHidden.d.ts.map +1 -1
- package/lib/typescript/control-system.d.ts +3 -0
- package/lib/typescript/control-system.d.ts.map +1 -1
- package/lib/typescript/index.d.ts +3 -2
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/internal/InlineControl.d.ts +80 -22
- package/lib/typescript/internal/InlineControl.d.ts.map +1 -1
- package/lib/typescript/internal/collapse-box.d.ts +3 -3
- package/lib/typescript/internal/collapse-box.d.ts.map +1 -1
- package/lib/typescript/internal/collapse-box.shared.d.ts +1 -1
- package/lib/typescript/internal/control-icon-size.d.ts +4 -3
- package/lib/typescript/internal/control-icon-size.d.ts.map +1 -1
- package/lib/typescript/internal/control-metrics.d.ts +50 -50
- package/lib/typescript/internal/floating-arrow.d.ts +6 -7
- package/lib/typescript/internal/floating-arrow.d.ts.map +1 -1
- package/lib/typescript/internal/focus-ring.d.ts +94 -0
- package/lib/typescript/internal/focus-ring.d.ts.map +1 -0
- package/lib/typescript/internal/gradient-shared.d.ts +9 -8
- package/lib/typescript/internal/gradient-shared.d.ts.map +1 -1
- package/lib/typescript/internal/gradient.d.ts +1 -0
- package/lib/typescript/internal/gradient.d.ts.map +1 -1
- package/lib/typescript/internal/gradient.native.d.ts +1 -0
- package/lib/typescript/internal/gradient.native.d.ts.map +1 -1
- package/lib/typescript/internal/motion.d.ts +77 -67
- package/lib/typescript/internal/motion.d.ts.map +1 -1
- package/lib/typescript/internal/resolve-theme-color.d.ts +9 -8
- package/lib/typescript/internal/resolve-theme-color.d.ts.map +1 -1
- package/lib/typescript/internal/style-props.d.ts +490 -664
- package/lib/typescript/internal/style-props.d.ts.map +1 -1
- package/lib/typescript/internal/theme-color-web.d.ts.map +1 -1
- package/lib/typescript/internal/use-icon-color.d.ts +1 -1
- package/lib/typescript/internal/use-icon-color.native.d.ts +1 -1
- package/lib/typescript/internal/use-looping-animation.d.ts +10 -2
- package/lib/typescript/internal/use-looping-animation.d.ts.map +1 -1
- package/lib/typescript/internal/use-looping-animation.native.d.ts +2 -2
- package/lib/typescript/internal/use-looping-animation.native.d.ts.map +1 -1
- package/lib/typescript/internal/variant-colors.d.ts +191 -199
- package/lib/typescript/internal/variant-colors.d.ts.map +1 -1
- package/package.json +14 -13
- package/src/Accordion/Accordion.tsx +55 -47
- package/src/ActionIcon/ActionIcon.tsx +116 -59
- package/src/Affix/Affix.tsx +16 -27
- package/src/Alert/Alert.tsx +57 -44
- package/src/Anchor/Anchor.tsx +13 -12
- package/src/AngleSlider/AngleSlider.tsx +87 -63
- package/src/AspectRatio/AspectRatio.tsx +9 -12
- package/src/Autocomplete/Autocomplete.tsx +7 -2
- package/src/Avatar/Avatar.tsx +44 -36
- package/src/BackgroundImage/BackgroundImage.tsx +9 -6
- package/src/Badge/Badge.tsx +55 -30
- package/src/Blockquote/Blockquote.tsx +55 -45
- package/src/Box/Box.tsx +2 -2
- package/src/Breadcrumbs/Breadcrumbs.tsx +13 -11
- package/src/Burger/Burger.tsx +33 -24
- package/src/Button/Button.tsx +106 -80
- package/src/Card/Card.tsx +52 -44
- package/src/Center/Center.tsx +3 -3
- package/src/Checkbox/CheckIcon.tsx +8 -5
- package/src/Checkbox/Checkbox.tsx +97 -62
- package/src/Chip/Chip.tsx +50 -45
- package/src/CloseButton/CloseButton.tsx +32 -13
- package/src/Code/Code.tsx +15 -11
- package/src/Collapse/Collapse.tsx +11 -6
- package/src/ColorInput/ColorInput.tsx +30 -24
- package/src/ColorPicker/ColorPicker.tsx +78 -79
- package/src/ColorSwatch/ColorSwatch.tsx +11 -14
- package/src/Combobox/Combobox.tsx +174 -153
- package/src/Combobox/OptionsDropdown.tsx +15 -2
- package/src/Combobox/index.ts +1 -0
- package/src/Container/Container.tsx +11 -15
- package/src/Dialog/Dialog.tsx +26 -16
- package/src/Drawer/Drawer.tsx +51 -33
- package/src/Fieldset/Fieldset.tsx +25 -17
- package/src/FileButton/FileButton.tsx +4 -1
- package/src/Flex/Flex.tsx +24 -21
- package/src/FocusTrap/FocusTrap.tsx +4 -3
- package/src/Grid/Grid.tsx +24 -27
- package/src/Group/Group.tsx +4 -4
- package/src/Highlight/Highlight.tsx +2 -2
- package/src/HoverCard/HoverCard.tsx +17 -32
- package/src/Image/Image.native.tsx +1 -1
- package/src/Image/createImage.tsx +96 -63
- package/src/Image/types.ts +5 -1
- package/src/Indicator/Indicator.tsx +41 -32
- package/src/Input/Input.native.tsx +536 -501
- package/src/Input/Input.tsx +110 -156
- package/src/Input/shared.tsx +198 -291
- package/src/Input/types.ts +15 -0
- package/src/InputBase/InputBase.tsx +3 -1
- package/src/Kbd/Kbd.tsx +13 -15
- package/src/KeyboardAvoidingView/KeyboardAvoidingView.native.tsx +2 -2
- package/src/KeyboardAwareScrollView/KeyboardAwareScrollView.native.tsx +34 -33
- package/src/List/List.tsx +17 -11
- package/src/Loader/Loader.tsx +33 -37
- package/src/LoadingOverlay/LoadingOverlay.tsx +3 -2
- package/src/Mark/Mark.tsx +12 -12
- package/src/Marquee/Marquee.tsx +58 -46
- package/src/MaskInput/MaskInput.tsx +2 -1
- package/src/Menu/Menu.tsx +110 -45
- package/src/Modal/Modal.tsx +38 -31
- package/src/Modal/drag/DragDismissHost.tsx +10 -5
- package/src/Modal/drag/DragDismissHost.web.tsx +2 -1
- package/src/Modal/drag/DragDismissOverlay.tsx +9 -5
- package/src/Modal/drag/DragDismissOverlay.web.tsx +6 -1
- package/src/Modal/drag/index.ts +7 -2
- package/src/Modal/drag/types.ts +15 -3
- package/src/Modal/drag/useDragDismiss.ts +29 -21
- package/src/Modal/modal-base-inner.native.tsx +3 -2
- package/src/Modal/modal-base-inner.tsx +1 -1
- package/src/Modal/modal-base.tsx +14 -12
- package/src/MultiSelect/MultiSelect.tsx +6 -1
- package/src/NativeSelect/NativeSelect.tsx +21 -32
- package/src/NavLink/NavLink.tsx +54 -47
- package/src/Notification/Notification.tsx +31 -30
- package/src/NumberFormatter/NumberFormatter.tsx +4 -3
- package/src/NumberInput/NumberInput.tsx +52 -42
- package/src/Overlay/Overlay.tsx +18 -14
- package/src/Pagination/Pagination.tsx +142 -123
- package/src/Paper/Paper.tsx +8 -9
- package/src/Paragraph/Paragraph.tsx +7 -7
- package/src/PasswordInput/PasswordInput.tsx +67 -67
- package/src/Pill/Pill.tsx +44 -32
- package/src/PillsInput/PillsInput.tsx +60 -31
- package/src/PinInput/PinInput.tsx +31 -23
- package/src/Popover/Popover.native.tsx +3 -4
- package/src/Popover/Popover.shared.tsx +32 -27
- package/src/Portal/OverlayHost.tsx +4 -4
- package/src/Portal/OverlayPortal.tsx +26 -0
- package/src/Portal/index.ts +4 -0
- package/src/Progress/Progress.tsx +77 -64
- package/src/Radio/Radio.tsx +128 -122
- package/src/Radio/RadioIcon.tsx +4 -10
- package/src/Rating/Rating.tsx +63 -42
- package/src/RollingNumber/RollingNumber.tsx +60 -28
- package/src/ScrollArea/ScrollArea.native.tsx +66 -59
- package/src/ScrollArea/ScrollArea.shared.ts +2 -2
- package/src/ScrollArea/ScrollArea.tsx +35 -33
- package/src/SegmentedControl/SegmentedControl.tsx +98 -53
- package/src/Select/Select.tsx +7 -2
- package/src/Separator/Separator.tsx +43 -36
- package/src/SimpleGrid/SimpleGrid.tsx +23 -24
- package/src/Skeleton/Skeleton.tsx +35 -16
- package/src/Slider/Slider.tsx +303 -227
- package/src/Spacer/Spacer.tsx +17 -41
- package/src/Spoiler/Spoiler.tsx +19 -13
- package/src/Stack/Stack.tsx +3 -3
- package/src/Stepper/Stepper.tsx +89 -73
- package/src/Switch/Switch.tsx +87 -73
- package/src/Table/Table.tsx +100 -77
- package/src/TableOfContents/TableOfContents.tsx +80 -74
- package/src/Tabs/Tabs.tsx +78 -66
- package/src/TagsInput/TagsInput.tsx +35 -4
- package/src/Text/Text.tsx +25 -10
- package/src/TextInput/TextInput.tsx +3 -1
- package/src/Textarea/Textarea.tsx +2 -2
- package/src/ThemeIcon/ThemeIcon.tsx +38 -23
- package/src/Title/Title.tsx +48 -23
- package/src/Tooltip/Tooltip.tsx +53 -32
- package/src/Transition/Transition.native.tsx +16 -19
- package/src/Transition/use-overlay-transition.native.ts +6 -12
- package/src/Transition/use-overlay-transition.ts +2 -2
- package/src/Tree/Tree.tsx +39 -44
- package/src/TreeSelect/TreeSelect.tsx +49 -24
- package/src/Typography/Typography.tsx +5 -7
- package/src/UnstyledButton/UnstyledButton.tsx +6 -5
- package/src/VirtualList/VirtualList.shared.ts +1 -1
- package/src/VirtualList/VirtualList.tsx +18 -6
- package/src/VisuallyHidden/VisuallyHidden.tsx +7 -9
- package/src/control-system.ts +5 -0
- package/src/index.ts +32 -12
- package/src/internal/ControlIconProvider.tsx +1 -1
- package/src/internal/InlineControl.tsx +23 -27
- package/src/internal/collapse-box.shared.ts +1 -1
- package/src/internal/collapse-box.tsx +15 -11
- package/src/internal/control-icon-size.ts +5 -8
- package/src/internal/control-metrics.ts +52 -52
- package/src/internal/floating-arrow.tsx +48 -40
- package/src/internal/focus-ring.ts +92 -0
- package/src/internal/gradient-shared.ts +23 -10
- package/src/internal/gradient.native.tsx +2 -1
- package/src/internal/gradient.tsx +1 -0
- package/src/internal/motion.ts +204 -244
- package/src/internal/resolve-theme-color.ts +10 -10
- package/src/internal/style-props.ts +545 -390
- package/src/internal/theme-color-web.ts +47 -27
- package/src/internal/use-icon-color.native.ts +1 -1
- package/src/internal/use-icon-color.ts +1 -1
- package/src/internal/use-looping-animation.native.tsx +2 -2
- package/src/internal/use-slot-text-wrapper.tsx +1 -1
- package/src/internal/variant-colors.ts +187 -151
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
|
|
3
3
|
import { withStaticProperties } from "@knitui/core";
|
|
4
|
-
import { useCallbackRef, useUncontrolled } from "@knitui/hooks";
|
|
4
|
+
import { useCallbackRef, useId, useUncontrolled } from "@knitui/hooks";
|
|
5
5
|
|
|
6
6
|
import {
|
|
7
7
|
Combobox,
|
|
@@ -20,6 +20,7 @@ import {
|
|
|
20
20
|
composeTriggerRightSection,
|
|
21
21
|
defaultOptionsFilter,
|
|
22
22
|
flattenComboboxOptions,
|
|
23
|
+
getComboboxOptionId,
|
|
23
24
|
getParsedComboboxData,
|
|
24
25
|
isComboboxGroup,
|
|
25
26
|
type OptionsDropdownProps,
|
|
@@ -47,7 +48,7 @@ type TagsInputFieldProps = Omit<
|
|
|
47
48
|
/**
|
|
48
49
|
* Named style slots (Pillar B / `internal/styles.ts`), keyed 1:1 with the
|
|
49
50
|
* TagsInput part surface. Each key maps to the props of the part it targets, so
|
|
50
|
-
* `styles={{ pill: { bg: "
|
|
51
|
+
* `styles={{ pill: { bg: "color3" } }}` is sugar for `<TagsInput.Pill bg="color3" />`.
|
|
51
52
|
*/
|
|
52
53
|
export interface TagsInputStyles {
|
|
53
54
|
/** Props for the state-machine root (`TagsInput.Root` → `<Combobox>`). */
|
|
@@ -121,6 +122,13 @@ function splitTags(value: string, splitChars: string[]): string[] {
|
|
|
121
122
|
interface TagsInputContextValue {
|
|
122
123
|
/** The shared combobox store (open state + keyboard target). */
|
|
123
124
|
combobox: ReturnType<typeof useCombobox>;
|
|
125
|
+
/** id wiring `aria-controls` (field) ↔ the suggestion dropdown. */
|
|
126
|
+
dropdownId: string;
|
|
127
|
+
/**
|
|
128
|
+
* Whether there is suggestion data at all. Only then is the field an ARIA
|
|
129
|
+
* `combobox` (a free-text tag field with no suggestions stays a plain textbox).
|
|
130
|
+
*/
|
|
131
|
+
hasSuggestions: boolean;
|
|
124
132
|
size: ComboboxSize;
|
|
125
133
|
/** Step-down pill size derived from the field size. */
|
|
126
134
|
pillSize: PillProps["size"];
|
|
@@ -435,6 +443,8 @@ function TagsInputRoot(props: TagsInputRootProps) {
|
|
|
435
443
|
});
|
|
436
444
|
|
|
437
445
|
const [activeValue, setActiveValue] = React.useState<string | null>(null);
|
|
446
|
+
// SSR-safe id linking the field's `aria-controls` to the suggestion dropdown.
|
|
447
|
+
const dropdownId = useId(__triggerProps?.id ? `${__triggerProps.id}-dropdown` : undefined);
|
|
438
448
|
// Set on a user-typed search change so the next `flatOptions` recompute highlights
|
|
439
449
|
// the first match (Mantine's `selectFirstOptionOnChange`); a ref avoids racing the
|
|
440
450
|
// filter memo and scopes the behaviour to actual input changes.
|
|
@@ -633,6 +643,8 @@ function TagsInputRoot(props: TagsInputRootProps) {
|
|
|
633
643
|
const ctx = React.useMemo<TagsInputContextValue>(
|
|
634
644
|
() => ({
|
|
635
645
|
combobox,
|
|
646
|
+
dropdownId,
|
|
647
|
+
hasSuggestions: parsed.length > 0,
|
|
636
648
|
size,
|
|
637
649
|
pillSize,
|
|
638
650
|
disabled,
|
|
@@ -664,6 +676,8 @@ function TagsInputRoot(props: TagsInputRootProps) {
|
|
|
664
676
|
// context (it is rebuilt every render and only the Trigger reads it).
|
|
665
677
|
[
|
|
666
678
|
combobox,
|
|
679
|
+
dropdownId,
|
|
680
|
+
parsed.length,
|
|
667
681
|
size,
|
|
668
682
|
pillSize,
|
|
669
683
|
disabled,
|
|
@@ -847,6 +861,22 @@ const TagsInputTrigger = React.forwardRef<TagsInputRef, TagsInputTriggerProps>(
|
|
|
847
861
|
<TagsInputPills>
|
|
848
862
|
{pills}
|
|
849
863
|
<PillsInput.Field
|
|
864
|
+
{...(ctx.hasSuggestions
|
|
865
|
+
? {
|
|
866
|
+
role: "combobox" as const,
|
|
867
|
+
"aria-autocomplete": "list" as const,
|
|
868
|
+
"aria-controls": ctx.dropdownId,
|
|
869
|
+
"aria-expanded": ctx.combobox.opened,
|
|
870
|
+
...(ctx.combobox.opened && ctx.activeValue != null
|
|
871
|
+
? {
|
|
872
|
+
"aria-activedescendant": getComboboxOptionId(
|
|
873
|
+
ctx.dropdownId,
|
|
874
|
+
ctx.activeValue,
|
|
875
|
+
),
|
|
876
|
+
}
|
|
877
|
+
: null),
|
|
878
|
+
}
|
|
879
|
+
: null)}
|
|
850
880
|
placeholder={placeholder}
|
|
851
881
|
value={ctx.search}
|
|
852
882
|
disabled={ctx.disabled}
|
|
@@ -877,9 +907,9 @@ const TagsInputDropdown = React.forwardRef<
|
|
|
877
907
|
>(function TagsInputDropdown(props, ref) {
|
|
878
908
|
const ctx = useTagsInputContext();
|
|
879
909
|
const s = slotStyles<TagsInputStyles>(ctx.styles, TAGS_INPUT_SLOT_KEYS, "TagsInput");
|
|
880
|
-
const { children, ...rest } = props;
|
|
910
|
+
const { id = ctx.dropdownId, children, ...rest } = props;
|
|
881
911
|
return (
|
|
882
|
-
<Combobox.Dropdown ref={ref} {...s.get("dropdown")} {...rest}>
|
|
912
|
+
<Combobox.Dropdown ref={ref} id={id} {...s.get("dropdown")} {...rest}>
|
|
883
913
|
{children ?? <TagsInputOptions />}
|
|
884
914
|
</Combobox.Dropdown>
|
|
885
915
|
);
|
|
@@ -919,6 +949,7 @@ function TagsInputOptions(props: TagsInputOptionsProps) {
|
|
|
919
949
|
withScrollArea={ctx.withScrollArea}
|
|
920
950
|
maxDropdownHeight={ctx.maxDropdownHeight}
|
|
921
951
|
renderOption={ctx.renderOption}
|
|
952
|
+
optionIdPrefix={ctx.dropdownId}
|
|
922
953
|
// The `option`/`group`/`empty` slots reach each rendered row through OptionsDropdown.
|
|
923
954
|
optionProps={s.get("option")}
|
|
924
955
|
groupProps={s.get("group")}
|
package/src/Text/Text.tsx
CHANGED
|
@@ -20,15 +20,26 @@ type TextStyleProps = GetProps<typeof TamaguiText>;
|
|
|
20
20
|
* deliberate divergence — use the `c` style prop / `theme`, not a `color` prop.
|
|
21
21
|
*/
|
|
22
22
|
export const Text = styled(TamaguiText, {
|
|
23
|
-
|
|
24
|
-
fontFamily: "
|
|
25
|
-
color: "
|
|
26
|
-
fontSize: "
|
|
23
|
+
displayName: "Text",
|
|
24
|
+
fontFamily: "body",
|
|
25
|
+
color: "color",
|
|
26
|
+
fontSize: "md",
|
|
27
|
+
// v2 parity: Tamagui v2's shared `font_*` rule gave every font-classed text the
|
|
28
|
+
// font's `$true` line height (the `md` step) whatever its `fontSize`. v3's rule
|
|
29
|
+
// only sets `font-family` (and fonts have no `true` key), so without this every
|
|
30
|
+
// Text fell back to `line-height: normal` and text rows shrank (26px → 15–33px).
|
|
31
|
+
// Components that pair line height with size set it explicitly and win. Web
|
|
32
|
+
// only (a static spread, not a `web:` clause, so a later bare value still
|
|
33
|
+
// replaces it): v2 never applied a default line height on native.
|
|
34
|
+
...(isWeb ? { lineHeight: "md" as const } : null),
|
|
27
35
|
variants: {
|
|
28
36
|
size: fontSizeVariant,
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
37
|
+
/**
|
|
38
|
+
* Multi-line clamp. Maps onto the host `numberOfLines`, which v3's own Text
|
|
39
|
+
* turns into `-webkit-line-clamp` on web (a variant of the base Text there)
|
|
40
|
+
* and passes to the native `<Text>` on iOS/Android.
|
|
41
|
+
*/
|
|
42
|
+
lineClamp: styled.dynamic<number>((lines) => ({ numberOfLines: lines })),
|
|
32
43
|
truncate: {
|
|
33
44
|
true: { ellipsis: true },
|
|
34
45
|
end: { ellipsis: true },
|
|
@@ -61,9 +72,13 @@ export const Text = styled(TamaguiText, {
|
|
|
61
72
|
fontFamily: "inherit" as TextStyleProps["fontFamily"],
|
|
62
73
|
},
|
|
63
74
|
},
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
75
|
+
/**
|
|
76
|
+
* Mantine parity: render an inline element. The kit's `Text` already renders
|
|
77
|
+
* a `<span>` on web (and an inline RN `<Text>` on native), so this is a
|
|
78
|
+
* declared, consumed prop with no style of its own — a variant body cannot
|
|
79
|
+
* carry `render` in v3. Use `render="p"` / `Paragraph` for a block.
|
|
80
|
+
*/
|
|
81
|
+
span: styled.dynamic<boolean>(),
|
|
67
82
|
} as const,
|
|
68
83
|
});
|
|
69
84
|
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
|
|
3
|
+
import { styleable } from "@knitui/core";
|
|
4
|
+
|
|
3
5
|
import { InputBase, type InputBaseProps } from "../InputBase";
|
|
4
6
|
|
|
5
7
|
/**
|
|
@@ -19,6 +21,6 @@ export type TextInputRef = React.ComponentRef<typeof InputBase>;
|
|
|
19
21
|
* React Native `TextInput` on native. Accent/theme comes from the Tamagui `theme`
|
|
20
22
|
* prop + palette ramp — never a Mantine `color` prop.
|
|
21
23
|
*/
|
|
22
|
-
export const TextInput =
|
|
24
|
+
export const TextInput = styleable<TextInputProps>(InputBase, function TextInput(props, ref) {
|
|
23
25
|
return <InputBase ref={ref} {...props} />;
|
|
24
26
|
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
|
|
3
|
-
import { isWeb } from "@knitui/core";
|
|
3
|
+
import { isWeb, styleable } from "@knitui/core";
|
|
4
4
|
import { useMergedRef } from "@knitui/hooks";
|
|
5
5
|
|
|
6
6
|
import { InputBase, type InputBaseProps } from "../InputBase";
|
|
@@ -56,7 +56,7 @@ const asTextarea = (node: TextareaRef | null): HTMLTextAreaElement | null =>
|
|
|
56
56
|
* `autosize` grows the field from `minRows` up to `maxRows` on both platforms; the
|
|
57
57
|
* CSS `resize` handle is web-only (a no-op on native).
|
|
58
58
|
*/
|
|
59
|
-
export const Textarea =
|
|
59
|
+
export const Textarea = styleable<TextareaProps>(InputBase, function Textarea(props, ref) {
|
|
60
60
|
const {
|
|
61
61
|
autosize = false,
|
|
62
62
|
// A Textarea always opens at two text lines unless the consumer narrows it.
|
|
@@ -1,10 +1,16 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import {
|
|
4
|
+
createStyledContext,
|
|
5
|
+
type GetProps,
|
|
6
|
+
styleable,
|
|
7
|
+
styled,
|
|
8
|
+
withStaticProperties,
|
|
9
|
+
} from "@knitui/core";
|
|
4
10
|
|
|
5
11
|
import { Box } from "../Box";
|
|
6
12
|
import { ControlIconProvider } from "../internal/ControlIconProvider";
|
|
7
|
-
import { type GradientValue, useGradient } from "../internal/gradient";
|
|
13
|
+
import { gradientForVariant, type GradientValue, useGradient } from "../internal/gradient";
|
|
8
14
|
import {
|
|
9
15
|
pickVariants,
|
|
10
16
|
radiusVariant,
|
|
@@ -36,7 +42,7 @@ const ThemeIconContext = createStyledContext<{
|
|
|
36
42
|
* never a `color` prop.
|
|
37
43
|
*/
|
|
38
44
|
const ThemeIconFrame = styled(Box, {
|
|
39
|
-
|
|
45
|
+
displayName: "ThemeIcon",
|
|
40
46
|
context: ThemeIconContext,
|
|
41
47
|
flexDirection: "row",
|
|
42
48
|
alignItems: "center",
|
|
@@ -59,9 +65,7 @@ const ThemeIconFrame = styled(Box, {
|
|
|
59
65
|
"gradient",
|
|
60
66
|
]),
|
|
61
67
|
},
|
|
62
|
-
size:
|
|
63
|
-
...squareSizeRoundedVariant,
|
|
64
|
-
},
|
|
68
|
+
size: squareSizeRoundedVariant,
|
|
65
69
|
radius: radiusVariant,
|
|
66
70
|
shadow: shadowVariant,
|
|
67
71
|
} as const,
|
|
@@ -69,34 +73,45 @@ const ThemeIconFrame = styled(Box, {
|
|
|
69
73
|
defaultVariants: { variant: "filled", size: "md" },
|
|
70
74
|
});
|
|
71
75
|
|
|
72
|
-
|
|
76
|
+
/**
|
|
77
|
+
* `size` / `variant` are narrowed to single values (no v3 clause programs): the
|
|
78
|
+
* render reads them as DATA (`ControlIconProvider`).
|
|
79
|
+
*/
|
|
80
|
+
export interface ThemeIconProps extends Omit<GetProps<typeof ThemeIconFrame>, "size" | "variant"> {
|
|
81
|
+
/** Size key, or a raw square edge (px number / CSS length). @default "md" */
|
|
82
|
+
size?: ThemeIconSize | number | (string & {});
|
|
83
|
+
/** @default "filled" */
|
|
84
|
+
variant?: ThemeIconVariant;
|
|
73
85
|
/** The icon to render. A bare `@knitui/icons` icon auto-sizes/colors to the chip. */
|
|
74
86
|
children?: React.ReactNode;
|
|
75
87
|
/**
|
|
76
88
|
* Gradient fill for `variant="gradient"` (ignored otherwise). Two-color
|
|
77
89
|
* shorthand `{ from, to, deg }` or multi-step `{ stops, deg }`; colors accept
|
|
78
|
-
*
|
|
90
|
+
* `colorN` ramp names or any CSS color. Defaults to the active theme ramp.
|
|
79
91
|
*/
|
|
80
92
|
gradient?: GradientValue;
|
|
81
93
|
}
|
|
82
94
|
|
|
83
|
-
const ThemeIconComponent =
|
|
84
|
-
|
|
95
|
+
const ThemeIconComponent = styleable<ThemeIconProps>(
|
|
96
|
+
ThemeIconFrame,
|
|
97
|
+
function ThemeIcon(props, ref) {
|
|
98
|
+
const { children, variant = "filled", size = "md", gradient, ...rest } = props;
|
|
85
99
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
100
|
+
// Gradient fill (only when `variant="gradient"`): web paints a CSS
|
|
101
|
+
// `backgroundImage`; native renders the `layer` (an SVG fill) behind the icon.
|
|
102
|
+
const grad = useGradient(gradientForVariant(variant, gradient));
|
|
89
103
|
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
}
|
|
104
|
+
return (
|
|
105
|
+
<ThemeIconFrame ref={ref} variant={variant} size={size} {...grad.frameProps} {...rest}>
|
|
106
|
+
{grad.layer}
|
|
107
|
+
{/* Publish icon context so a bare `@knitui/icons` icon auto-matches the chip. */}
|
|
108
|
+
<ControlIconProvider size={size} variant={variant}>
|
|
109
|
+
{children}
|
|
110
|
+
</ControlIconProvider>
|
|
111
|
+
</ThemeIconFrame>
|
|
112
|
+
);
|
|
113
|
+
},
|
|
114
|
+
);
|
|
100
115
|
|
|
101
116
|
export const ThemeIcon = withStaticProperties(ThemeIconComponent, {
|
|
102
117
|
Frame: ThemeIconFrame,
|
package/src/Title/Title.tsx
CHANGED
|
@@ -1,12 +1,31 @@
|
|
|
1
|
-
import { type GetProps, styled } from "@knitui/core";
|
|
1
|
+
import { type GetProps, styleable, styled } from "@knitui/core";
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import {
|
|
4
|
+
fontSizeOf,
|
|
5
|
+
fontSizeVariant,
|
|
6
|
+
tableVariant,
|
|
7
|
+
textWrapVariant,
|
|
8
|
+
} from "../internal/style-props";
|
|
4
9
|
import { Text } from "../Text";
|
|
5
10
|
|
|
6
11
|
export type TitleOrder = 1 | 2 | 3 | 4 | 5 | 6;
|
|
7
12
|
export type TitleSize =
|
|
8
13
|
"h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "xxs" | "xs" | "sm" | "md" | "lg" | "xl" | "xxl";
|
|
9
14
|
|
|
15
|
+
/** `h1`–`h6` + the seven-step font scale, with a raw / CSS `fontSize` fallthrough. */
|
|
16
|
+
const titleSizeVariant = tableVariant(
|
|
17
|
+
{
|
|
18
|
+
h1: { fontSize: "xxl" },
|
|
19
|
+
h2: { fontSize: "xl" },
|
|
20
|
+
h3: { fontSize: "lg" },
|
|
21
|
+
h4: { fontSize: "md" },
|
|
22
|
+
h5: { fontSize: "sm" },
|
|
23
|
+
h6: { fontSize: "xs" },
|
|
24
|
+
...fontSizeVariant,
|
|
25
|
+
},
|
|
26
|
+
fontSizeOf,
|
|
27
|
+
);
|
|
28
|
+
|
|
10
29
|
/**
|
|
11
30
|
* Heading — mirrors Mantine's `Title`. `order` (1–6) drives the semantic heading
|
|
12
31
|
* element (`h1`–`h6`) and its default size; `size` overrides that size (accepts
|
|
@@ -14,37 +33,43 @@ export type TitleSize =
|
|
|
14
33
|
* `lineClamp`, `truncate`, and `inline` are inherited from `Text`.
|
|
15
34
|
*/
|
|
16
35
|
const TitleFrame = styled(Text, {
|
|
17
|
-
|
|
18
|
-
fontFamily: "
|
|
36
|
+
displayName: "Title",
|
|
37
|
+
fontFamily: "heading",
|
|
19
38
|
fontWeight: "700",
|
|
20
39
|
variants: {
|
|
21
40
|
order: {
|
|
22
|
-
1: { fontSize: "
|
|
23
|
-
2: { fontSize: "
|
|
24
|
-
3: { fontSize: "
|
|
25
|
-
4: { fontSize: "
|
|
26
|
-
5: { fontSize: "
|
|
27
|
-
6: { fontSize: "
|
|
41
|
+
1: { fontSize: "xxl" },
|
|
42
|
+
2: { fontSize: "xl" },
|
|
43
|
+
3: { fontSize: "lg" },
|
|
44
|
+
4: { fontSize: "md" },
|
|
45
|
+
5: { fontSize: "sm" },
|
|
46
|
+
6: { fontSize: "xs" },
|
|
28
47
|
},
|
|
29
48
|
/** Override the order-driven size. `h1`–`h6` map to the heading scale;
|
|
30
49
|
* seven-step font-size tokens and arbitrary CSS values pass through to `fontSize`. */
|
|
31
|
-
size:
|
|
32
|
-
h1: { fontSize: "$xxl" },
|
|
33
|
-
h2: { fontSize: "$xl" },
|
|
34
|
-
h3: { fontSize: "$lg" },
|
|
35
|
-
h4: { fontSize: "$md" },
|
|
36
|
-
h5: { fontSize: "$sm" },
|
|
37
|
-
h6: { fontSize: "$xs" },
|
|
38
|
-
...fontSizePassthroughVariant,
|
|
39
|
-
},
|
|
50
|
+
size: titleSizeVariant,
|
|
40
51
|
textWrap: textWrapVariant,
|
|
41
52
|
} as const,
|
|
42
53
|
defaultVariants: { order: 1 },
|
|
43
54
|
});
|
|
44
55
|
|
|
45
|
-
export interface TitleProps extends GetProps<typeof TitleFrame> {
|
|
56
|
+
export interface TitleProps extends Omit<GetProps<typeof TitleFrame>, "order"> {
|
|
57
|
+
/**
|
|
58
|
+
* Heading level 1–6: picks the semantic `<h1>`–`<h6>` host and the default
|
|
59
|
+
* size. A single value (not a clause program), because the host element cannot
|
|
60
|
+
* change per breakpoint; use `size` for responsive sizing. @default 1
|
|
61
|
+
*/
|
|
62
|
+
order?: TitleOrder;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
const HEADING_HOSTS = { 1: "h1", 2: "h2", 3: "h3", 4: "h4", 5: "h5", 6: "h6" } as const;
|
|
46
66
|
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
67
|
+
/**
|
|
68
|
+
* Behaviour wrapper (stays `styleable`): the host element is DERIVED from
|
|
69
|
+
* `order`, and v3 variant bodies cannot carry `render`. Everything else is the
|
|
70
|
+
* flattenable `TitleFrame`.
|
|
71
|
+
*/
|
|
72
|
+
export const Title = styleable<TitleProps>(TitleFrame, function Title(props, ref) {
|
|
73
|
+
const host = HEADING_HOSTS[props.order ?? 1] ?? "h1";
|
|
74
|
+
return <TitleFrame ref={ref} {...props} render={host} />;
|
|
50
75
|
});
|
package/src/Tooltip/Tooltip.tsx
CHANGED
|
@@ -3,6 +3,8 @@ import * as React from "react";
|
|
|
3
3
|
import {
|
|
4
4
|
type GetProps,
|
|
5
5
|
isWeb,
|
|
6
|
+
type LayoutChangeEvent,
|
|
7
|
+
styleable,
|
|
6
8
|
styled,
|
|
7
9
|
type TamaguiElement,
|
|
8
10
|
Theme,
|
|
@@ -31,9 +33,9 @@ import {
|
|
|
31
33
|
import { type FloatingOffset } from "../internal/floating-offset";
|
|
32
34
|
import { type MotionPresetName } from "../internal/motion";
|
|
33
35
|
import { useOverlayChrome } from "../internal/overlay-chrome";
|
|
34
|
-
import { radiusVariant, shadowVariant } from "../internal/style-props";
|
|
36
|
+
import { type RadiusValue, radiusVariant, shadowVariant } from "../internal/style-props";
|
|
35
37
|
import { type SlotStyles } from "../internal/styles";
|
|
36
|
-
import {
|
|
38
|
+
import { OverlayPortal, useOverlayHost } from "../Portal";
|
|
37
39
|
import { Text } from "../Text";
|
|
38
40
|
import {
|
|
39
41
|
type OverlayTransitionConfig,
|
|
@@ -69,29 +71,29 @@ export interface TooltipEvents {
|
|
|
69
71
|
/* -------------------------------------------------------------------------- */
|
|
70
72
|
|
|
71
73
|
/*
|
|
72
|
-
* RAMP NOTE (
|
|
74
|
+
* RAMP NOTE (`colorN` steps below are MIRRORED, i.e. `13 - n`)
|
|
73
75
|
* ------------------------------------------------------------
|
|
74
|
-
* `name: "Tooltip"`
|
|
76
|
+
* The v2 `name: "Tooltip"` collided with an `inverse`-templated entry in Tamagui's
|
|
75
77
|
* (deprecated) `defaultComponentThemes`. Until `core/config/themes.ts` set
|
|
76
78
|
* `componentThemes: false`, this frame — and `TooltipText` inside it — resolved
|
|
77
|
-
* against a `<scheme>_Tooltip` theme whose whole
|
|
78
|
-
* reversed, so the authored
|
|
79
|
-
* authored
|
|
79
|
+
* against a `<scheme>_Tooltip` theme whose whole `color1…color12` ramp was
|
|
80
|
+
* reversed, so the authored `color9` fill actually painted step 4 and the
|
|
81
|
+
* authored `color1` label actually painted step 12. The steps are written
|
|
80
82
|
* pre-mirrored here so the tooltip keeps its shipped light-chip appearance now
|
|
81
83
|
* that nothing flips the ramp under it. Restoring the canonical filled pairing
|
|
82
|
-
* (
|
|
84
|
+
* (`color9` fill + `color1` label) is a deliberate design change — see the
|
|
83
85
|
* changeset.
|
|
84
86
|
*/
|
|
85
87
|
const TooltipLabelFrame = styled(Box, {
|
|
86
|
-
|
|
88
|
+
displayName: "Tooltip",
|
|
87
89
|
// `fixed` is web-only viewport positioning; React Native supports only
|
|
88
90
|
// `absolute`/`relative`/`static`. Pick the platform-correct value (mirrors
|
|
89
91
|
// Popover.Dropdown) so the label isn't laid out in normal flow on native.
|
|
90
92
|
position: isWeb ? ("fixed" as const) : ("absolute" as const),
|
|
91
|
-
backgroundColor: "
|
|
92
|
-
paddingVertical: "
|
|
93
|
-
paddingHorizontal: "
|
|
94
|
-
borderRadius: "
|
|
93
|
+
backgroundColor: "color4",
|
|
94
|
+
paddingVertical: "xxs",
|
|
95
|
+
paddingHorizontal: "xs",
|
|
96
|
+
borderRadius: "sm",
|
|
95
97
|
role: "tooltip",
|
|
96
98
|
|
|
97
99
|
variants: {
|
|
@@ -107,10 +109,10 @@ const TooltipLabelFrame = styled(Box, {
|
|
|
107
109
|
});
|
|
108
110
|
|
|
109
111
|
const TooltipText = styled(Text, {
|
|
110
|
-
|
|
112
|
+
displayName: "TooltipText",
|
|
111
113
|
// MIRRORED step — renders inside `TooltipLabelFrame`. See the RAMP NOTE above.
|
|
112
|
-
color: "
|
|
113
|
-
fontSize: "
|
|
114
|
+
color: "color12",
|
|
115
|
+
fontSize: "sm",
|
|
114
116
|
});
|
|
115
117
|
|
|
116
118
|
/* -------------------------------------------------------------------------- */
|
|
@@ -118,8 +120,14 @@ const TooltipText = styled(Text, {
|
|
|
118
120
|
/* -------------------------------------------------------------------------- */
|
|
119
121
|
|
|
120
122
|
// `position` is the Tooltip's floating Placement, which collides with Box's CSS
|
|
121
|
-
// `position` style keyword
|
|
122
|
-
|
|
123
|
+
// `position` style keyword, and `offset` is the floating gutter, which collides
|
|
124
|
+
// with v3's `offset` style prop — drop both inherited ones (same fix as
|
|
125
|
+
// Indicator/Dialog). `radius` is re-declared as a plain value (not the variant's
|
|
126
|
+
// flat clause program) because it also feeds the arrow middleware's px corner.
|
|
127
|
+
type LabelFrameProps = Omit<
|
|
128
|
+
GetProps<typeof TooltipLabelFrame>,
|
|
129
|
+
"children" | "position" | "offset" | "radius"
|
|
130
|
+
>;
|
|
123
131
|
|
|
124
132
|
/** Props the `label`/`text` slots may carry (the inner `Tooltip.Text` element). */
|
|
125
133
|
export type TooltipTextStyle = GetProps<typeof TooltipText>;
|
|
@@ -189,6 +197,8 @@ export interface TooltipProps extends LabelFrameProps {
|
|
|
189
197
|
inline?: boolean;
|
|
190
198
|
/** Allow the label to wrap onto multiple lines. @default false */
|
|
191
199
|
multiline?: boolean;
|
|
200
|
+
/** Label corner radius — a radius/size key, px number or CSS length. @default 'sm' */
|
|
201
|
+
radius?: RadiusValue;
|
|
192
202
|
/**
|
|
193
203
|
* Elevation — drop shadow for the label, from the shared `shadowVariant`
|
|
194
204
|
* ladder (`xxs`→`xxl`). Opt-in; no shadow by default.
|
|
@@ -357,7 +367,8 @@ function TooltipTarget({ children, refProp: refPropOverride }: TooltipTargetProp
|
|
|
357
367
|
const refProp = refPropOverride ?? ctx.refProp;
|
|
358
368
|
|
|
359
369
|
// Merge the floating reference setter with any ref the child already declares.
|
|
360
|
-
|
|
370
|
+
// React 19 carries `ref` as a regular prop; the removed `element.ref` getter warns.
|
|
371
|
+
const childRef = (children.props as { ref?: React.Ref<TamaguiElement> }).ref;
|
|
361
372
|
const mergedRef = useMergedRef<TamaguiElement>(ctx.setReferenceRef, childRef);
|
|
362
373
|
|
|
363
374
|
const child = children as React.ReactElement<InteractionProps>;
|
|
@@ -380,7 +391,7 @@ function TooltipTarget({ children, refProp: refPropOverride }: TooltipTargetProp
|
|
|
380
391
|
);
|
|
381
392
|
}
|
|
382
393
|
|
|
383
|
-
const TooltipBase =
|
|
394
|
+
const TooltipBase = styleable<TooltipProps>(TooltipLabelFrame, function Tooltip(props, ref) {
|
|
384
395
|
const {
|
|
385
396
|
label,
|
|
386
397
|
children,
|
|
@@ -452,7 +463,7 @@ const TooltipBase = TooltipLabelFrame.styleable<TooltipProps>(function Tooltip(p
|
|
|
452
463
|
position: arrowPosition,
|
|
453
464
|
offset: arrowOffset,
|
|
454
465
|
padding: arrowOffset,
|
|
455
|
-
// The label frame's default radius is
|
|
466
|
+
// The label frame's default radius is `sm` (see TooltipLabelFrame).
|
|
456
467
|
cornerRadius: resolveRadiusPx(radius),
|
|
457
468
|
}),
|
|
458
469
|
]
|
|
@@ -498,6 +509,11 @@ const TooltipBase = TooltipLabelFrame.styleable<TooltipProps>(function Tooltip(p
|
|
|
498
509
|
}
|
|
499
510
|
}, [placement, onPositionChange]);
|
|
500
511
|
|
|
512
|
+
const onNativeLayout = React.useCallback(
|
|
513
|
+
(e: LayoutChangeEvent) => update(e.nativeEvent.layout),
|
|
514
|
+
[update],
|
|
515
|
+
);
|
|
516
|
+
|
|
501
517
|
// Native re-measure: `autoUpdate` is a no-op on native (see `Floating.native`),
|
|
502
518
|
// so coords are only computed on demand. Recompute when the tooltip opens, once
|
|
503
519
|
// the target + label Views have laid out (mirrors Popover.Dropdown).
|
|
@@ -576,19 +592,19 @@ const TooltipBase = TooltipLabelFrame.styleable<TooltipProps>(function Tooltip(p
|
|
|
576
592
|
const dropdownSlot = s.get("dropdown");
|
|
577
593
|
|
|
578
594
|
const labelNode = !t.rendered ? null : (
|
|
579
|
-
<
|
|
595
|
+
<OverlayPortal hostName={withinPortal ? overlayHost : undefined}>
|
|
580
596
|
<Theme name={themeName}>
|
|
581
597
|
<TooltipLabelFrame
|
|
582
598
|
ref={floatingRef}
|
|
583
599
|
id={tooltipId}
|
|
584
|
-
top={y}
|
|
585
|
-
left={x}
|
|
586
600
|
radius={radius}
|
|
587
601
|
shadow={shadow}
|
|
588
602
|
multiline={multiline}
|
|
589
|
-
// `display:none` only once fully exited while kept mounted.
|
|
590
|
-
display={
|
|
591
|
-
|
|
603
|
+
// `display:none` only once fully exited while kept mounted. A
|
|
604
|
+
// conditional spread, never `display={undefined}` (v3 clears on it).
|
|
605
|
+
{...(t.hidden ? { display: "none" as const } : null)}
|
|
606
|
+
// Native re-measure on layout; web positions through `autoUpdate`.
|
|
607
|
+
{...(isWeb ? null : { onLayout: onNativeLayout })}
|
|
592
608
|
zIndex={zIndex}
|
|
593
609
|
pointerEvents="none"
|
|
594
610
|
{...t.animation}
|
|
@@ -596,7 +612,9 @@ const TooltipBase = TooltipLabelFrame.styleable<TooltipProps>(function Tooltip(p
|
|
|
596
612
|
{...labelRest}
|
|
597
613
|
// Engine style wins last (opacity/transform); slot/consumer styles merge
|
|
598
614
|
// underneath (slot < consumer < transition).
|
|
599
|
-
|
|
615
|
+
// `top`/`left` track the floating engine continuously: inline style (a
|
|
616
|
+
// style prop injects one CSS rule per value on v3 web).
|
|
617
|
+
style={[dropdownSlot?.style, labelRest.style, { top: y, left: x }, transitionStyle]}
|
|
600
618
|
>
|
|
601
619
|
{/* `label` is the conventional text slot; `text` is the specific
|
|
602
620
|
alias and layers OVER it ("explicit beats sugar"). */}
|
|
@@ -604,8 +622,11 @@ const TooltipBase = TooltipLabelFrame.styleable<TooltipProps>(function Tooltip(p
|
|
|
604
622
|
{label}
|
|
605
623
|
</TooltipText>
|
|
606
624
|
{withArrow ? (
|
|
607
|
-
// Shared cross-platform arrow; `background="
|
|
608
|
-
// fill
|
|
625
|
+
// Shared cross-platform arrow; `background="color4"` matches the label
|
|
626
|
+
// fill (the frame's MIRRORED `color4`, see the RAMP NOTE — it used to
|
|
627
|
+
// read `color9`, a leftover from the flipped component theme, which
|
|
628
|
+
// painted a darker arrow than the chip) and `borderWidth={0}` keeps it
|
|
629
|
+
// solid/borderless. `size` keeps the
|
|
609
630
|
// historical doubled convention so a default centered arrow is unchanged;
|
|
610
631
|
// FloatingArrow rounds only the OUTWARD corner (closer to Mantine than the
|
|
611
632
|
// old all-corners radius).
|
|
@@ -615,7 +636,7 @@ const TooltipBase = TooltipLabelFrame.styleable<TooltipProps>(function Tooltip(p
|
|
|
615
636
|
offset={arrowOffset}
|
|
616
637
|
position={arrowPosition}
|
|
617
638
|
radius={arrowRadius}
|
|
618
|
-
background="
|
|
639
|
+
background="color4"
|
|
619
640
|
borderWidth={0}
|
|
620
641
|
arrowX={middlewareData.arrow?.x}
|
|
621
642
|
arrowY={middlewareData.arrow?.y}
|
|
@@ -627,7 +648,7 @@ const TooltipBase = TooltipLabelFrame.styleable<TooltipProps>(function Tooltip(p
|
|
|
627
648
|
) : null}
|
|
628
649
|
</TooltipLabelFrame>
|
|
629
650
|
</Theme>
|
|
630
|
-
</
|
|
651
|
+
</OverlayPortal>
|
|
631
652
|
);
|
|
632
653
|
|
|
633
654
|
return (
|