@adgytec/adgytec-web-ui-components 2.3.0 → 2.4.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 +27 -16
- package/dist/App.d.ts +1 -2
- package/dist/assets/BottomSheetModal.css +1 -1
- package/dist/assets/CalendarCell.css +1 -1
- package/dist/assets/CalendarMenuItem.css +1 -1
- package/dist/assets/Card.css +1 -1
- package/dist/assets/Input.css +1 -1
- package/dist/assets/ListItem.css +1 -1
- package/dist/assets/ListTrailingText.css +1 -0
- package/dist/assets/Radio.css +1 -1
- package/dist/assets/SideSheet.css +1 -1
- package/dist/assets/SideSheetModal.css +1 -1
- package/dist/assets/Switch.css +1 -1
- package/dist/assets/ThemeSelector.css +1 -1
- package/dist/assets/core7.css +1 -1
- package/dist/chunks/ActionDialog +0 -1
- package/dist/chunks/ActionDialog.map +1 -1
- package/dist/chunks/AppBar +42 -43
- package/dist/chunks/AppBar.map +1 -1
- package/dist/chunks/AppBarAction +0 -1
- package/dist/chunks/AppBarAction.map +1 -1
- package/dist/chunks/AppBarAvatar +1 -2
- package/dist/chunks/AppBarAvatar.map +1 -1
- package/dist/chunks/AppBarHeadline +1 -2
- package/dist/chunks/AppBarHeadline.map +1 -1
- package/dist/chunks/BaseCalendar +65 -68
- package/dist/chunks/BaseCalendar.map +1 -1
- package/dist/chunks/BottomSheet +1 -2
- package/dist/chunks/BottomSheet.map +1 -1
- package/dist/chunks/BottomSheetModal +1 -2
- package/dist/chunks/BottomSheetModal.map +1 -1
- package/dist/chunks/ButtonGroup +1 -2
- package/dist/chunks/ButtonGroup.map +1 -1
- package/dist/chunks/CalendarCell +25 -40
- package/dist/chunks/CalendarCell.map +1 -1
- package/dist/chunks/CalendarGrid +1 -2
- package/dist/chunks/CalendarGrid.map +1 -1
- package/dist/chunks/CalendarMenuItem +2 -3
- package/dist/chunks/CalendarMenuItem.map +1 -1
- package/dist/chunks/Card +4 -5
- package/dist/chunks/Card.map +1 -1
- package/dist/chunks/CardIcon +1 -2
- package/dist/chunks/CardIcon.map +1 -1
- package/dist/chunks/CenteredSlider +1 -2
- package/dist/chunks/CenteredSlider.map +1 -1
- package/dist/chunks/ComboBox +1 -2
- package/dist/chunks/ComboBox.map +1 -1
- package/dist/chunks/ComboBoxPopover +0 -1
- package/dist/chunks/ComboBoxPopover.map +1 -1
- package/dist/chunks/ComboBoxTrigger +575 -63
- package/dist/chunks/ComboBoxTrigger.map +1 -1
- package/dist/chunks/ConnectedButtonGroup +13 -11
- package/dist/chunks/ConnectedButtonGroup.map +1 -1
- package/dist/chunks/Dialog +1 -2
- package/dist/chunks/Dialog.map +1 -1
- package/dist/chunks/Disclosure +1 -2
- package/dist/chunks/Disclosure.map +1 -1
- package/dist/chunks/DisclosureGroup +1 -2
- package/dist/chunks/DisclosureGroup.map +1 -1
- package/dist/chunks/DisclosureHeader +1 -2
- package/dist/chunks/DisclosureHeader.map +1 -1
- package/dist/chunks/DisclosurePanel +1 -2
- package/dist/chunks/DisclosurePanel.map +1 -1
- package/dist/chunks/Divider +1 -2
- package/dist/chunks/Divider.map +1 -1
- package/dist/chunks/FieldError +1 -2
- package/dist/chunks/FieldError.map +1 -1
- package/dist/chunks/GridBackgroundDecorator +0 -1
- package/dist/chunks/GridBackgroundDecorator.map +1 -1
- package/dist/chunks/Icon +1 -2
- package/dist/chunks/Icon.map +1 -1
- package/dist/chunks/Input +67 -78
- package/dist/chunks/Input.map +1 -1
- package/dist/chunks/Input2 +6 -9
- package/dist/chunks/Input2.map +1 -1
- package/dist/chunks/ListAction +12 -0
- package/dist/chunks/ListAction.map +1 -0
- package/dist/chunks/ListAvatar +1 -2
- package/dist/chunks/ListAvatar.map +1 -1
- package/dist/chunks/ListBox +12 -9
- package/dist/chunks/ListBox.map +1 -1
- package/dist/chunks/ListIcon +1 -2
- package/dist/chunks/ListIcon.map +1 -1
- package/dist/chunks/ListItem +62 -49
- package/dist/chunks/ListItem.map +1 -1
- package/dist/chunks/ListLabelText +1 -2
- package/dist/chunks/ListLabelText.map +1 -1
- package/dist/chunks/ListMedia +0 -1
- package/dist/chunks/ListMedia.map +1 -1
- package/dist/chunks/ListOverlineText +1 -2
- package/dist/chunks/ListOverlineText.map +1 -1
- package/dist/chunks/ListSupportingText +1 -2
- package/dist/chunks/ListSupportingText.map +1 -1
- package/dist/chunks/ListTrailingText +20 -0
- package/dist/chunks/ListTrailingText.map +1 -0
- package/dist/chunks/Loader +1 -2
- package/dist/chunks/Loader.map +1 -1
- package/dist/chunks/MenuPopover +1 -2
- package/dist/chunks/MenuPopover.map +1 -1
- package/dist/chunks/Modal +1 -2
- package/dist/chunks/Modal.map +1 -1
- package/dist/chunks/ModalOverlay +1 -2
- package/dist/chunks/ModalOverlay.map +1 -1
- package/dist/chunks/Navigation +2 -4
- package/dist/chunks/Navigation.map +1 -1
- package/dist/chunks/NavigationScrollContainer +7 -6
- package/dist/chunks/NavigationScrollContainer.map +1 -1
- package/dist/chunks/NavigationSection +1 -2
- package/dist/chunks/NavigationSection.map +1 -1
- package/dist/chunks/NavigationSectionLabel +1 -2
- package/dist/chunks/NavigationSectionLabel.map +1 -1
- package/dist/chunks/Popover +1 -2
- package/dist/chunks/Popover.map +1 -1
- package/dist/chunks/RadialGlowDecorator +0 -1
- package/dist/chunks/RadialGlowDecorator.map +1 -1
- package/dist/chunks/Radio +57 -70
- package/dist/chunks/Radio.map +1 -1
- package/dist/chunks/RichTooltip +1 -2
- package/dist/chunks/RichTooltip.map +1 -1
- package/dist/chunks/RichTooltipActions +1 -2
- package/dist/chunks/RichTooltipActions.map +1 -1
- package/dist/chunks/RichTooltipInfo +1 -2
- package/dist/chunks/RichTooltipInfo.map +1 -1
- package/dist/chunks/SearchField +0 -1
- package/dist/chunks/SearchField.map +1 -1
- package/dist/chunks/SelectPopover +1 -2
- package/dist/chunks/SelectPopover.map +1 -1
- package/dist/chunks/SelectTrigger +1 -2
- package/dist/chunks/SelectTrigger.map +1 -1
- package/dist/chunks/SideSheet +8 -9
- package/dist/chunks/SideSheet.map +1 -1
- package/dist/chunks/SideSheetModal +2 -3
- package/dist/chunks/SideSheetModal.map +1 -1
- package/dist/chunks/Slider +0 -1
- package/dist/chunks/Slider.map +1 -1
- package/dist/chunks/SliderOutput +1 -2
- package/dist/chunks/SliderOutput.map +1 -1
- package/dist/chunks/SliderStops +4 -5
- package/dist/chunks/SliderStops.map +1 -1
- package/dist/chunks/SliderThumb +0 -1
- package/dist/chunks/SliderThumb.map +1 -1
- package/dist/chunks/Snackbar +1 -2
- package/dist/chunks/Snackbar.map +1 -1
- package/dist/chunks/SplitButton +14 -12
- package/dist/chunks/SplitButton.map +1 -1
- package/dist/chunks/SplitButtonTrigger +9 -9
- package/dist/chunks/SplitButtonTrigger.map +1 -1
- package/dist/chunks/SubmenuPopover +0 -1
- package/dist/chunks/SubmenuPopover.map +1 -1
- package/dist/chunks/Switch +47 -48
- package/dist/chunks/Switch.map +1 -1
- package/dist/chunks/Tab +1 -2
- package/dist/chunks/Tab.map +1 -1
- package/dist/chunks/TabList +1 -2
- package/dist/chunks/TabList.map +1 -1
- package/dist/chunks/TabPanel +1 -2
- package/dist/chunks/TabPanel.map +1 -1
- package/dist/chunks/TabPanels +1 -2
- package/dist/chunks/TabPanels.map +1 -1
- package/dist/chunks/Tabs +1 -2
- package/dist/chunks/Tabs.map +1 -1
- package/dist/chunks/Tag +1 -2
- package/dist/chunks/Tag.map +1 -1
- package/dist/chunks/ThemeSelector +117 -89
- package/dist/chunks/ThemeSelector.map +1 -1
- package/dist/chunks/Toolbar +0 -1
- package/dist/chunks/Toolbar.map +1 -1
- package/dist/chunks/Tooltip +0 -1
- package/dist/chunks/Tooltip.map +1 -1
- package/dist/chunks/base +1 -2
- package/dist/chunks/base.map +1 -1
- package/dist/chunks/compiler-runtime +4 -5
- package/dist/chunks/compiler-runtime.map +1 -1
- package/dist/chunks/context +1 -2
- package/dist/chunks/context.map +1 -1
- package/dist/chunks/core +30 -31
- package/dist/chunks/core.map +1 -1
- package/dist/chunks/core2 +0 -1
- package/dist/chunks/core2.map +1 -1
- package/dist/chunks/core3 +2 -5
- package/dist/chunks/core3.map +1 -1
- package/dist/chunks/core4 +0 -1
- package/dist/chunks/core4.map +1 -1
- package/dist/chunks/core5 +0 -1
- package/dist/chunks/core5.map +1 -1
- package/dist/chunks/core6 +14 -15
- package/dist/chunks/core6.map +1 -1
- package/dist/chunks/core7 +2 -5
- package/dist/chunks/core7.map +1 -1
- package/dist/chunks/core8 +1 -3
- package/dist/chunks/core8.map +1 -1
- package/dist/chunks/core9 +0 -1
- package/dist/chunks/core9.map +1 -1
- package/dist/chunks/navContext +1 -2
- package/dist/chunks/navContext.map +1 -1
- package/dist/chunks/tapTarget +0 -1
- package/dist/chunks/tapTarget.map +1 -1
- package/dist/chunks/types +1 -2
- package/dist/chunks/types.map +1 -1
- package/dist/chunks/useHover +430 -161
- package/dist/chunks/useHover.map +1 -1
- package/dist/chunks/useSplash +18 -21
- package/dist/chunks/useSplash.map +1 -1
- package/dist/components/AppBar/AppBar/AppBar.d.ts +29 -0
- package/dist/components/AppBar/AppBar/index.js +1 -2
- package/dist/components/AppBar/AppBar/types.d.ts +29 -4
- package/dist/components/AppBar/AppBarAction/AppBarAction.d.ts +19 -1
- package/dist/components/AppBar/AppBarAction/index.js +1 -2
- package/dist/components/AppBar/AppBarAvatar/AppBarAvatar.d.ts +20 -1
- package/dist/components/AppBar/AppBarAvatar/index.js +1 -2
- package/dist/components/AppBar/AppBarHeadline/AppBarHeadline.d.ts +19 -1
- package/dist/components/AppBar/AppBarHeadline/index.js +1 -2
- package/dist/components/AppBar/AppBarState/AppBarState.d.ts +28 -2
- package/dist/components/AppBar/AppBarState/context.d.ts +37 -0
- package/dist/components/AppBar/AppBarState/index.js +16 -12
- package/dist/components/AppBar/AppBarState/index.js.map +1 -1
- package/dist/components/AppBar/core/alignment.d.ts +6 -0
- package/dist/components/AppBar/core/context.d.ts +16 -0
- package/dist/components/AppBar/core/index.js +2 -4
- package/dist/components/AppBar/core/index.js.map +1 -1
- package/dist/components/AppBar/core/size.d.ts +13 -0
- package/dist/components/AppBar/index.js +7 -7
- package/dist/components/Button/Button/Button.d.ts +17 -0
- package/dist/components/Button/Button/index.js +1 -2
- package/dist/components/Button/Button/index.js.map +1 -1
- package/dist/components/Button/Button/types.d.ts +4 -0
- package/dist/components/Button/ButtonGroups/ButtonGroup/ButtonGroup.d.ts +17 -0
- package/dist/components/Button/ButtonGroups/ButtonGroup/index.js +1 -2
- package/dist/components/Button/ButtonGroups/ButtonGroup/types.d.ts +24 -0
- package/dist/components/Button/ButtonGroups/ButtonGroupContext/context.d.ts +22 -0
- package/dist/components/Button/ButtonGroups/ButtonGroupContext/index.js +3 -6
- package/dist/components/Button/ButtonGroups/ButtonGroupContext/index.js.map +1 -1
- package/dist/components/Button/ButtonGroups/ButtonGroupContext/useButtonGroupContext.d.ts +5 -0
- package/dist/components/Button/ButtonGroups/ButtonGroupContext/useConnectedButtonGroupContext.d.ts +5 -0
- package/dist/components/Button/ButtonGroups/ConnectedButton/ConnectedButton.d.ts +13 -0
- package/dist/components/Button/ButtonGroups/ConnectedButton/index.js +1 -2
- package/dist/components/Button/ButtonGroups/ConnectedButton/types.d.ts +19 -1
- package/dist/components/Button/ButtonGroups/ConnectedButtonGroup/ConnectedButtonGroup.d.ts +18 -0
- package/dist/components/Button/ButtonGroups/ConnectedButtonGroup/index.js +1 -2
- package/dist/components/Button/ButtonGroups/ConnectedButtonGroup/types.d.ts +24 -0
- package/dist/components/Button/IconButton/IconButton.d.ts +21 -0
- package/dist/components/Button/IconButton/index.js +1 -2
- package/dist/components/Button/IconButton/index.js.map +1 -1
- package/dist/components/Button/IconButton/types.d.ts +4 -0
- package/dist/components/Button/LinkButton/LinkButton.d.ts +15 -0
- package/dist/components/Button/LinkButton/index.js +1 -2
- package/dist/components/Button/LinkButton/index.js.map +1 -1
- package/dist/components/Button/LinkButton/types.d.ts +4 -0
- package/dist/components/Button/LinkIconButton/LinkIconButton.d.ts +19 -0
- package/dist/components/Button/LinkIconButton/index.js +1 -2
- package/dist/components/Button/LinkIconButton/index.js.map +1 -1
- package/dist/components/Button/LinkIconButton/types.d.ts +4 -0
- package/dist/components/Button/SplitButton/SplitButton/SplitButton.d.ts +24 -0
- package/dist/components/Button/SplitButton/SplitButton/index.js +1 -2
- package/dist/components/Button/SplitButton/SplitButton/types.d.ts +23 -0
- package/dist/components/Button/SplitButton/SplitButtonContext/context.d.ts +11 -0
- package/dist/components/Button/SplitButton/SplitButtonContext/index.js +2 -4
- package/dist/components/Button/SplitButton/SplitButtonContext/index.js.map +1 -1
- package/dist/components/Button/SplitButton/SplitButtonContext/useSplitButtonContext.d.ts +5 -0
- package/dist/components/Button/SplitButton/SplitButtonPrimary/SplitButtonPrimary.d.ts +15 -0
- package/dist/components/Button/SplitButton/SplitButtonPrimary/index.js +3 -4
- package/dist/components/Button/SplitButton/SplitButtonPrimary/index.js.map +1 -1
- package/dist/components/Button/SplitButton/SplitButtonPrimary/types.d.ts +11 -0
- package/dist/components/Button/SplitButton/SplitButtonTrigger/SplitButtonTrigger.d.ts +19 -0
- package/dist/components/Button/SplitButton/SplitButtonTrigger/index.js +1 -2
- package/dist/components/Button/SplitButton/SplitButtonTrigger/types.d.ts +5 -0
- package/dist/components/Button/SplitButton/core/index.js +1 -2
- package/dist/components/Button/SplitButton/core/size.d.ts +13 -0
- package/dist/components/Button/ToggleButton/ToggleButton.d.ts +21 -0
- package/dist/components/Button/ToggleButton/index.js +1 -2
- package/dist/components/Button/ToggleButton/index.js.map +1 -1
- package/dist/components/Button/ToggleButton/types.d.ts +14 -0
- package/dist/components/Button/ToggleIconButton/ToggleIconButton.d.ts +21 -0
- package/dist/components/Button/ToggleIconButton/index.js +1 -2
- package/dist/components/Button/ToggleIconButton/index.js.map +1 -1
- package/dist/components/Button/ToggleIconButton/types.d.ts +9 -0
- package/dist/components/Button/core/button.d.ts +33 -0
- package/dist/components/Button/core/color.d.ts +38 -0
- package/dist/components/Button/core/index.js +1 -2
- package/dist/components/Button/core/shape.d.ts +6 -0
- package/dist/components/Button/core/sizes.d.ts +26 -0
- package/dist/components/Button/core/useButtonConfig.d.ts +25 -0
- package/dist/components/Button/core/variant.d.ts +6 -0
- package/dist/components/Button/core/width.d.ts +7 -0
- package/dist/components/Button/core/withTooltip.d.ts +9 -2
- package/dist/components/Calendar/BaseCalendar/BaseCalendar.d.ts +23 -2
- package/dist/components/Calendar/BaseCalendar/index.js +1 -2
- package/dist/components/Calendar/Calendar/Calendar.d.ts +39 -2
- package/dist/components/Calendar/Calendar/index.js +19 -14
- package/dist/components/Calendar/Calendar/index.js.map +1 -1
- package/dist/components/Calendar/CalendarCell/CalendarCell.d.ts +14 -2
- package/dist/components/Calendar/CalendarCell/index.js +1 -2
- package/dist/components/Calendar/CalendarGrid/CalendarGrid.d.ts +12 -2
- package/dist/components/Calendar/CalendarGrid/index.js +1 -2
- package/dist/components/Calendar/CalendarMenuItem/CalendarMenuItem.d.ts +12 -1
- package/dist/components/Calendar/CalendarMenuItem/index.js +1 -2
- package/dist/components/Calendar/CalendarMonthMenu/CalendarMonthMenu.d.ts +14 -2
- package/dist/components/Calendar/CalendarMonthMenu/index.js +3 -4
- package/dist/components/Calendar/CalendarMonthMenu/index.js.map +1 -1
- package/dist/components/Calendar/CalendarYearMenu/CalendarYearMenu.d.ts +14 -2
- package/dist/components/Calendar/CalendarYearMenu/index.js +1 -2
- package/dist/components/Calendar/CalendarYearMenu/index.js.map +1 -1
- package/dist/components/Calendar/RangeCalendar/RangeCalendar.d.ts +40 -2
- package/dist/components/Calendar/RangeCalendar/index.js +20 -17
- package/dist/components/Calendar/RangeCalendar/index.js.map +1 -1
- package/dist/components/Calendar/core/calendar.d.ts +26 -0
- package/dist/components/Calendar/core/index.js +1 -2
- package/dist/components/Calendar/core/useCalendarState.d.ts +15 -0
- package/dist/components/Calendar/index.d.ts +1 -0
- package/dist/components/Calendar/index.js +4 -3
- package/dist/components/Card/Card/Card.d.ts +20 -0
- package/dist/components/Card/Card/types.d.ts +23 -0
- package/dist/components/Card/CardIcon/CardIcon.d.ts +25 -1
- package/dist/components/Card/CardIcon/index.js +1 -2
- package/dist/components/Decorators/GridBackgroundDecorator/GridBackgroundDecorator.d.ts +46 -7
- package/dist/components/Decorators/GridBackgroundDecorator/index.js +1 -2
- package/dist/components/Decorators/RadialGlowDecorator/RadialGlowDecorator.d.ts +53 -6
- package/dist/components/Decorators/RadialGlowDecorator/index.js +1 -2
- package/dist/components/Dialog/ActionDialog/ActionDialog.d.ts +33 -0
- package/dist/components/Dialog/ActionDialog/index.js +1 -2
- package/dist/components/Dialog/ActionDialog/types.d.ts +28 -2
- package/dist/components/Dialog/Dialog/Dialog.d.ts +32 -1
- package/dist/components/Dialog/Dialog/index.js +1 -2
- package/dist/components/Dialog/Modal/Modal.d.ts +24 -1
- package/dist/components/Dialog/Modal/index.js +1 -2
- package/dist/components/Dialog/ModalOverlay/ModalOverlay.d.ts +25 -1
- package/dist/components/Dialog/ModalOverlay/index.js +1 -2
- package/dist/components/Dialog/core/context.d.ts +8 -0
- package/dist/components/Dialog/core/index.js +2 -4
- package/dist/components/Dialog/core/index.js.map +1 -1
- package/dist/components/Dialog/core/typography.d.ts +9 -0
- package/dist/components/Disclosure/Disclosure/Disclosure.d.ts +25 -1
- package/dist/components/Disclosure/Disclosure/index.js +1 -2
- package/dist/components/Disclosure/DisclosureGroup/DisclosureGroup.d.ts +50 -2
- package/dist/components/Disclosure/DisclosureGroup/index.js +1 -2
- package/dist/components/Disclosure/DisclosureHeader/DisclosureHeader.d.ts +31 -2
- package/dist/components/Disclosure/DisclosureHeader/index.js +1 -2
- package/dist/components/Disclosure/DisclosurePanel/DisclosurePanel.d.ts +31 -2
- package/dist/components/Disclosure/DisclosurePanel/index.js +1 -2
- package/dist/components/Disclosure/context/context.d.ts +11 -2
- package/dist/components/Disclosure/context/index.js +1 -2
- package/dist/components/Disclosure/context/index.js.map +1 -1
- package/dist/components/Disclosure/context/useDisclosureTypographyContext.d.ts +18 -2
- package/dist/components/Divider/Divider.d.ts +30 -1
- package/dist/components/Divider/index.js +1 -2
- package/dist/components/Icon/Icon.d.ts +29 -0
- package/dist/components/Icon/index.js +1 -2
- package/dist/components/Icon/types.d.ts +28 -0
- package/dist/components/Input/CharacterCount/CharacterCount.d.ts +11 -2
- package/dist/components/Input/CharacterCount/index.js +1 -2
- package/dist/components/Input/CharacterCount/index.js.map +1 -1
- package/dist/components/Input/Checkbox/Checkbox.d.ts +26 -0
- package/dist/components/Input/Checkbox/CheckboxGroup.d.ts +17 -0
- package/dist/components/Input/Checkbox/context.d.ts +9 -3
- package/dist/components/Input/Checkbox/types.d.ts +32 -5
- package/dist/components/Input/DateField/DateField.d.ts +17 -1
- package/dist/components/Input/DateField/index.js +1 -2
- package/dist/components/Input/DateField/index.js.map +1 -1
- package/dist/components/Input/DateField/types.d.ts +4 -0
- package/dist/components/Input/DatePicker/DatePicker/DatePicker.d.ts +17 -1
- package/dist/components/Input/DatePicker/DatePicker/index.js +1 -2
- package/dist/components/Input/DatePicker/DatePicker/index.js.map +1 -1
- package/dist/components/Input/DatePicker/DatePicker/types.d.ts +10 -0
- package/dist/components/Input/DatePicker/DateRangePicker/DateRangePicker.d.ts +17 -1
- package/dist/components/Input/DatePicker/DateRangePicker/index.js +1 -2
- package/dist/components/Input/DatePicker/DateRangePicker/index.js.map +1 -1
- package/dist/components/Input/DatePicker/DateRangePicker/types.d.ts +10 -0
- package/dist/components/Input/DatePicker/core/datePicker.d.ts +3 -0
- package/dist/components/Input/DatePicker/core/index.js +1 -2
- package/dist/components/Input/Description/Description.d.ts +12 -1
- package/dist/components/Input/Description/index.js +1 -2
- package/dist/components/Input/Description/index.js.map +1 -1
- package/dist/components/Input/FieldError/FieldError.d.ts +12 -1
- package/dist/components/Input/FieldError/index.js +1 -2
- package/dist/components/Input/Input/Input.d.ts +27 -0
- package/dist/components/Input/Input/InputButton.d.ts +10 -1
- package/dist/components/Input/Input/handleInputButton.d.ts +6 -0
- package/dist/components/Input/Input/index.js +1 -2
- package/dist/components/Input/Input/types.d.ts +20 -0
- package/dist/components/Input/Label/Label.d.ts +12 -1
- package/dist/components/Input/Label/index.js +1 -2
- package/dist/components/Input/Label/index.js.map +1 -1
- package/dist/components/Input/Radio/Radio.d.ts +17 -0
- package/dist/components/Input/Radio/RadioGroup.d.ts +17 -0
- package/dist/components/Input/Radio/context.d.ts +9 -3
- package/dist/components/Input/Radio/index.js +1 -2
- package/dist/components/Input/Radio/types.d.ts +32 -6
- package/dist/components/Input/SearchField/SearchField.d.ts +16 -0
- package/dist/components/Input/SearchField/index.js +1 -2
- package/dist/components/Input/SearchField/types.d.ts +9 -0
- package/dist/components/Input/Select/ComboBox/ComboBox.d.ts +29 -1
- package/dist/components/Input/Select/ComboBox/context.d.ts +3 -0
- package/dist/components/Input/Select/ComboBox/index.js +1 -2
- package/dist/components/Input/Select/ComboBox/types.d.ts +9 -0
- package/dist/components/Input/Select/ComboBoxPopover/ComboBoxPopover.d.ts +10 -1
- package/dist/components/Input/Select/ComboBoxPopover/index.js +1 -2
- package/dist/components/Input/Select/ComboBoxTrigger/ComboBoxTrigger.d.ts +10 -2
- package/dist/components/Input/Select/ComboBoxTrigger/index.js +1 -2
- package/dist/components/Input/Select/Select/Select.d.ts +29 -1
- package/dist/components/Input/Select/Select/index.js +1 -2
- package/dist/components/Input/Select/Select/index.js.map +1 -1
- package/dist/components/Input/Select/Select/types.d.ts +4 -0
- package/dist/components/Input/Select/SelectItem/SelectItem.d.ts +19 -0
- package/dist/components/Input/Select/SelectItem/index.js +1 -2
- package/dist/components/Input/Select/SelectItem/index.js.map +1 -1
- package/dist/components/Input/Select/SelectItem/types.d.ts +9 -0
- package/dist/components/Input/Select/SelectList/SelectList.d.ts +14 -2
- package/dist/components/Input/Select/SelectList/index.js +1 -2
- package/dist/components/Input/Select/SelectList/index.js.map +1 -1
- package/dist/components/Input/Select/SelectListSection/SelectListSection.d.ts +4 -1
- package/dist/components/Input/Select/SelectListSection/index.js +1 -2
- package/dist/components/Input/Select/SelectListSection/index.js.map +1 -1
- package/dist/components/Input/Select/SelectListSectionHeader/SelectListSectionHeader.d.ts +3 -0
- package/dist/components/Input/Select/SelectListSectionHeader/index.js +1 -2
- package/dist/components/Input/Select/SelectListSectionHeader/index.js.map +1 -1
- package/dist/components/Input/Select/SelectPopover/SelectPopover.d.ts +10 -1
- package/dist/components/Input/Select/SelectPopover/index.js +1 -2
- package/dist/components/Input/Select/SelectTrigger/SelectTrigger.d.ts +10 -1
- package/dist/components/Input/Select/SelectTrigger/index.js +1 -2
- package/dist/components/Input/Slider/CenteredSlider/CenteredSlider.d.ts +23 -1
- package/dist/components/Input/Slider/CenteredSlider/index.js +1 -2
- package/dist/components/Input/Slider/CenteredSlider/types.d.ts +6 -0
- package/dist/components/Input/Slider/RangeSlider/RangeSlider.d.ts +24 -1
- package/dist/components/Input/Slider/RangeSlider/index.js +1 -2
- package/dist/components/Input/Slider/RangeSlider/index.js.map +1 -1
- package/dist/components/Input/Slider/RangeSlider/types.d.ts +9 -0
- package/dist/components/Input/Slider/Slider/Slider.d.ts +24 -1
- package/dist/components/Input/Slider/Slider/index.js +1 -2
- package/dist/components/Input/Slider/Slider/types.d.ts +13 -0
- package/dist/components/Input/Slider/SliderOutput/SliderOutput.d.ts +19 -1
- package/dist/components/Input/Slider/SliderOutput/index.js +1 -2
- package/dist/components/Input/Slider/SliderStops/SliderStops.d.ts +18 -0
- package/dist/components/Input/Slider/SliderStops/core.d.ts +54 -10
- package/dist/components/Input/Slider/SliderStops/index.js +1 -2
- package/dist/components/Input/Slider/SliderStops/types.d.ts +38 -0
- package/dist/components/Input/Slider/SliderThumb/SliderThumb.d.ts +32 -2
- package/dist/components/Input/Slider/SliderThumb/context.d.ts +20 -0
- package/dist/components/Input/Slider/SliderThumb/index.js +1 -2
- package/dist/components/Input/Slider/core/color.d.ts +1 -0
- package/dist/components/Input/Slider/core/index.js +1 -2
- package/dist/components/Input/Slider/core/size.d.ts +12 -0
- package/dist/components/Input/Slider/core/slider.d.ts +44 -0
- package/dist/components/Input/Slider/core/variant.d.ts +10 -0
- package/dist/components/Input/Switch/Switch.d.ts +32 -0
- package/dist/components/Input/Switch/index.js +1 -2
- package/dist/components/Input/Switch/types.d.ts +35 -3
- package/dist/components/Input/TextArea/TextArea.d.ts +19 -0
- package/dist/components/Input/TextArea/index.js +1 -2
- package/dist/components/Input/TextArea/index.js.map +1 -1
- package/dist/components/Input/TextArea/types.d.ts +11 -0
- package/dist/components/Input/TimeField/TimeField.d.ts +17 -1
- package/dist/components/Input/TimeField/index.js +1 -2
- package/dist/components/Input/TimeField/index.js.map +1 -1
- package/dist/components/Input/TimeField/types.d.ts +4 -0
- package/dist/components/Input/core/index.js +1 -2
- package/dist/components/Input/core/input.d.ts +15 -0
- package/dist/components/Input/core/textField.d.ts +13 -0
- package/dist/components/Input/hooks/index.js +1 -2
- package/dist/components/Input/hooks/index.js.map +1 -1
- package/dist/components/Input/hooks/useControllableState.d.ts +17 -2
- package/dist/components/List/ListAction/ListAction.d.ts +23 -1
- package/dist/components/List/ListAction/index.d.ts +1 -1
- package/dist/components/List/ListAction/index.js +1 -0
- package/dist/components/List/ListAvatar/ListAvatar.d.ts +23 -1
- package/dist/components/List/ListAvatar/index.js +1 -2
- package/dist/components/List/ListBox/ListBox.d.ts +28 -1
- package/dist/components/List/ListBox/index.js +1 -2
- package/dist/components/List/ListBox/types.d.ts +27 -0
- package/dist/components/List/ListIcon/ListIcon.d.ts +19 -1
- package/dist/components/List/ListIcon/index.js +1 -2
- package/dist/components/List/ListItem/ListItem.d.ts +35 -0
- package/dist/components/List/ListItem/index.js +1 -2
- package/dist/components/List/ListItem/types.d.ts +34 -0
- package/dist/components/List/ListLabelText/ListLabelText.d.ts +16 -1
- package/dist/components/List/ListLabelText/index.js +1 -2
- package/dist/components/List/ListMedia/ListMedia.d.ts +20 -0
- package/dist/components/List/ListMedia/index.js +1 -2
- package/dist/components/List/ListMedia/types.d.ts +32 -0
- package/dist/components/List/ListOverlineText/ListOverlineText.d.ts +16 -1
- package/dist/components/List/ListOverlineText/index.js +1 -2
- package/dist/components/List/ListSupportingText/ListSupportingText.d.ts +16 -1
- package/dist/components/List/ListSupportingText/index.js +1 -2
- package/dist/components/List/ListTrailingText/ListTrailingText.d.ts +16 -1
- package/dist/components/List/ListTrailingText/index.d.ts +1 -1
- package/dist/components/List/ListTrailingText/index.js +1 -0
- package/dist/components/List/core/context.d.ts +18 -0
- package/dist/components/List/core/index.d.ts +2 -0
- package/dist/components/List/core/index.js +9 -0
- package/dist/components/List/core/index.js.map +1 -0
- package/dist/components/List/core/selectionIndicator.d.ts +8 -0
- package/dist/components/List/index.d.ts +1 -0
- package/dist/components/List/index.js +12 -9
- package/dist/components/Loader/Loader.d.ts +26 -1
- package/dist/components/Loader/index.js +1 -2
- package/dist/components/Menu/Menu/Menu.d.ts +31 -1
- package/dist/components/Menu/Menu/index.js +1 -2
- package/dist/components/Menu/Menu/index.js.map +1 -1
- package/dist/components/Menu/Menu/types.d.ts +18 -0
- package/dist/components/Menu/MenuItem/MenuItem.d.ts +22 -0
- package/dist/components/Menu/MenuItem/index.js +1 -2
- package/dist/components/Menu/MenuItem/index.js.map +1 -1
- package/dist/components/Menu/MenuItem/types.d.ts +24 -0
- package/dist/components/Menu/MenuPopover/MenuPopover.d.ts +21 -1
- package/dist/components/Menu/MenuPopover/index.js +1 -2
- package/dist/components/Menu/MenuSection/MenuSection.d.ts +23 -1
- package/dist/components/Menu/MenuSection/index.js +1 -2
- package/dist/components/Menu/MenuSection/index.js.map +1 -1
- package/dist/components/Menu/MenuSectionHeader/MenuSectionHeader.d.ts +16 -1
- package/dist/components/Menu/MenuSectionHeader/index.js +1 -2
- package/dist/components/Menu/MenuSectionHeader/index.js.map +1 -1
- package/dist/components/Menu/MenuShortcut/MenuShortcut.d.ts +16 -1
- package/dist/components/Menu/MenuShortcut/index.js +1 -2
- package/dist/components/Menu/MenuShortcut/index.js.map +1 -1
- package/dist/components/Menu/MenuTrailingText/MenuTrailingText.d.ts +16 -1
- package/dist/components/Menu/MenuTrailingText/index.js +1 -2
- package/dist/components/Menu/MenuTrailingText/index.js.map +1 -1
- package/dist/components/Menu/MenuTrigger/MenuTrigger.d.ts +43 -2
- package/dist/components/Menu/MenuTrigger/index.js +1 -2
- package/dist/components/Menu/MenuTrigger/index.js.map +1 -1
- package/dist/components/Menu/SubmenuPopover/SubmenuPopover.d.ts +22 -1
- package/dist/components/Menu/SubmenuPopover/index.js +1 -2
- package/dist/components/Menu/context/context.d.ts +13 -0
- package/dist/components/Menu/context/index.js +2 -4
- package/dist/components/Menu/context/index.js.map +1 -1
- package/dist/components/Menu/context/useMenuConfigContext.d.ts +6 -0
- package/dist/components/Menu/core/color.d.ts +20 -0
- package/dist/components/Menu/core/index.js +1 -2
- package/dist/components/Menu/core/layout.d.ts +17 -0
- package/dist/components/Menu/core/menu.d.ts +18 -0
- package/dist/components/Navigation/Navigation/Navigation.d.ts +28 -0
- package/dist/components/Navigation/Navigation/navContext.d.ts +19 -0
- package/dist/components/Navigation/Navigation/navRenderingContext.d.ts +16 -0
- package/dist/components/Navigation/Navigation/types.d.ts +28 -0
- package/dist/components/Navigation/NavigationItem/NavigationButton/NavigationButton.d.ts +15 -0
- package/dist/components/Navigation/NavigationItem/NavigationButton/index.js +1 -2
- package/dist/components/Navigation/NavigationItem/NavigationButton/index.js.map +1 -1
- package/dist/components/Navigation/NavigationItem/NavigationButton/types.d.ts +9 -0
- package/dist/components/Navigation/NavigationItem/NavigationItemIconRenderer/NavigationItemIconRenderer.d.ts +21 -2
- package/dist/components/Navigation/NavigationItem/NavigationItemIconRenderer/index.js +1 -2
- package/dist/components/Navigation/NavigationItem/NavigationItemIconRenderer/index.js.map +1 -1
- package/dist/components/Navigation/NavigationItem/NavigationLink/NavigationLink.d.ts +15 -0
- package/dist/components/Navigation/NavigationItem/NavigationLink/index.js +1 -2
- package/dist/components/Navigation/NavigationItem/NavigationLink/index.js.map +1 -1
- package/dist/components/Navigation/NavigationItem/NavigationLink/types.d.ts +5 -0
- package/dist/components/Navigation/NavigationItem/core/index.js +1 -2
- package/dist/components/Navigation/NavigationItem/core/navigationItem.d.ts +22 -0
- package/dist/components/Navigation/NavigationScrollContainer/NavigationScrollContainer.d.ts +22 -1
- package/dist/components/Navigation/NavigationScrollContainer/index.js +1 -2
- package/dist/components/Navigation/NavigationSection/NavigationSection/NavigationSection.d.ts +24 -1
- package/dist/components/Navigation/NavigationSection/NavigationSection/index.js +1 -2
- package/dist/components/Navigation/NavigationSection/NavigationSectionLabel/NavigationSectionLabel.d.ts +16 -1
- package/dist/components/Navigation/NavigationSection/NavigationSectionLabel/index.js +1 -2
- package/dist/components/Navigation/NavigationState/NavigationState.d.ts +27 -2
- package/dist/components/Navigation/NavigationState/context.d.ts +31 -0
- package/dist/components/Navigation/NavigationState/index.d.ts +1 -0
- package/dist/components/Navigation/NavigationState/index.js +2 -4
- package/dist/components/Navigation/NavigationState/index.js.map +1 -1
- package/dist/components/Navigation/NavigationState/types.d.ts +12 -0
- package/dist/components/Navigation/SubNavigation/SubNavigation/SubNavigation.d.ts +35 -2
- package/dist/components/Navigation/SubNavigation/SubNavigation/index.js +1 -2
- package/dist/components/Navigation/SubNavigation/SubNavigation/index.js.map +1 -1
- package/dist/components/Navigation/SubNavigation/SubNavigationTrigger/SubNavigationTrigger.d.ts +40 -2
- package/dist/components/Navigation/SubNavigation/SubNavigationTrigger/index.js +1 -2
- package/dist/components/Navigation/SubNavigation/SubNavigationTrigger/index.js.map +1 -1
- package/dist/components/Navigation/core/index.js +1 -2
- package/dist/components/Navigation/core/navLabelContext.d.ts +6 -0
- package/dist/components/Navigation/core/navigation.d.ts +9 -0
- package/dist/components/Navigation/core/navigationInfo.d.ts +19 -0
- package/dist/components/Popover/Popover.d.ts +34 -1
- package/dist/components/Popover/index.js +1 -2
- package/dist/components/Sheets/BottomSheet/BottomSheet/BottomSheet.d.ts +40 -0
- package/dist/components/Sheets/BottomSheet/BottomSheet/index.d.ts +2 -0
- package/dist/components/Sheets/BottomSheet/BottomSheet/index.js +1 -0
- package/dist/components/Sheets/BottomSheet/BottomSheet/types.d.ts +37 -0
- package/dist/components/Sheets/BottomSheet/BottomSheetModal/BottomSheetModal.d.ts +36 -0
- package/dist/components/Sheets/BottomSheet/BottomSheetModal/context.d.ts +15 -0
- package/dist/components/Sheets/BottomSheet/BottomSheetModal/index.js +1 -0
- package/dist/components/Sheets/BottomSheet/BottomSheetModal/types.d.ts +43 -0
- package/dist/components/Sheets/BottomSheet/index.d.ts +1 -0
- package/dist/components/Sheets/BottomSheet/index.js +3 -2
- package/dist/components/Sheets/SideSheet/SideSheet/SideSheet.d.ts +48 -0
- package/dist/components/Sheets/SideSheet/SideSheet/SideSheetDialog.d.ts +45 -0
- package/dist/components/Sheets/SideSheet/SideSheet/index.d.ts +3 -0
- package/dist/components/Sheets/SideSheet/SideSheet/index.js +1 -0
- package/dist/components/Sheets/SideSheet/SideSheet/types.d.ts +102 -0
- package/dist/components/Sheets/SideSheet/SideSheetModal/SideSheetModal.d.ts +36 -0
- package/dist/components/Sheets/SideSheet/SideSheetModal/context.d.ts +20 -0
- package/dist/components/Sheets/SideSheet/SideSheetModal/index.js +1 -0
- package/dist/components/Sheets/SideSheet/SideSheetModal/types.d.ts +56 -0
- package/dist/components/Sheets/SideSheet/index.d.ts +1 -2
- package/dist/components/Sheets/SideSheet/index.js +3 -2
- package/dist/components/Sheets/core/layout.d.ts +11 -0
- package/dist/components/Sheets/index.d.ts +0 -2
- package/dist/components/Snackbar/SnackbarRegion.d.ts +50 -0
- package/dist/components/Snackbar/context.d.ts +38 -0
- package/dist/components/Snackbar/index.js +1 -2
- package/dist/components/Snackbar/types.d.ts +69 -0
- package/dist/components/Splash/Splash.d.ts +6 -0
- package/dist/components/Splash/index.js +1 -2
- package/dist/components/Splash/types.d.ts +10 -0
- package/dist/components/Splash/useSplash.d.ts +21 -0
- package/dist/components/Tabs/Tab/Tab.d.ts +33 -2
- package/dist/components/Tabs/Tab/index.js +1 -2
- package/dist/components/Tabs/TabList/TabList.d.ts +42 -1
- package/dist/components/Tabs/TabList/index.js +1 -2
- package/dist/components/Tabs/TabPanel/TabPanel.d.ts +28 -1
- package/dist/components/Tabs/TabPanel/index.js +1 -2
- package/dist/components/Tabs/TabPanels/TabPanels.d.ts +28 -1
- package/dist/components/Tabs/TabPanels/index.js +1 -2
- package/dist/components/Tabs/Tabs/Tabs.d.ts +43 -1
- package/dist/components/Tabs/Tabs/index.js +1 -2
- package/dist/components/Tag/Tag.d.ts +37 -0
- package/dist/components/Tag/core.d.ts +6 -0
- package/dist/components/Tag/index.js +1 -2
- package/dist/components/Tag/types.d.ts +48 -2
- package/dist/components/ThemeSelector/ThemeItem.d.ts +52 -2
- package/dist/components/ThemeSelector/ThemeProvider.d.ts +29 -2
- package/dist/components/ThemeSelector/ThemeSelector.d.ts +24 -0
- package/dist/components/ThemeSelector/core.d.ts +72 -4
- package/dist/components/ThemeSelector/index.d.ts +2 -0
- package/dist/components/ThemeSelector/index.js +1 -2
- package/dist/components/ThemeSelector/types.d.ts +110 -2
- package/dist/components/Toolbar/Toolbar.d.ts +47 -0
- package/dist/components/Toolbar/ToolbarToggleButtonGroup.d.ts +35 -1
- package/dist/components/Toolbar/index.js +1 -2
- package/dist/components/Toolbar/types.d.ts +60 -0
- package/dist/components/Tooltip/RichTooltip/RichTooltip/RichTooltip.d.ts +56 -1
- package/dist/components/Tooltip/RichTooltip/RichTooltip/index.js +1 -2
- package/dist/components/Tooltip/RichTooltip/RichTooltipActions/RichTooltipActions.d.ts +27 -1
- package/dist/components/Tooltip/RichTooltip/RichTooltipActions/index.js +1 -2
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipInfo/RichTooltipInfo.d.ts +31 -1
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipInfo/index.js +1 -2
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipSubhead/RichTooltipSubhead.d.ts +22 -1
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipSubhead/index.js +1 -2
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipSubhead/index.js.map +1 -1
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipText/RichTooltipText.d.ts +26 -1
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipText/index.js +1 -2
- package/dist/components/Tooltip/RichTooltip/RichTooltipInfo/RichTooltipText/index.js.map +1 -1
- package/dist/components/Tooltip/RichTooltip/RichTooltipTrigger/RichTooltipTrigger.d.ts +53 -0
- package/dist/components/Tooltip/RichTooltip/RichTooltipTrigger/index.d.ts +1 -0
- package/dist/components/Tooltip/RichTooltip/RichTooltipTrigger/index.js +11 -0
- package/dist/components/Tooltip/RichTooltip/RichTooltipTrigger/index.js.map +1 -0
- package/dist/components/Tooltip/RichTooltip/index.d.ts +1 -0
- package/dist/components/Tooltip/RichTooltip/index.js +2 -1
- package/dist/components/Tooltip/Tooltip/Tooltip.d.ts +35 -1
- package/dist/components/Tooltip/Tooltip/index.js +1 -2
- package/dist/components/Tooltip/TooltipTrigger/TooltipTrigger.d.ts +29 -1
- package/dist/components/Tooltip/TooltipTrigger/index.js +1 -2
- package/dist/components/Tooltip/TooltipTrigger/index.js.map +1 -1
- package/dist/components/Tooltip/index.js +4 -3
- package/dist/index.d.ts +0 -1
- package/dist/index.js +131 -139
- package/dist/index.js.map +1 -1
- package/dist/preview/AppBar/AppBar.d.ts +2 -0
- package/dist/preview/AppBar/index.d.ts +1 -0
- package/dist/preview/BottomSheet/BottomSheet.d.ts +6 -0
- package/dist/preview/BottomSheet/index.d.ts +1 -0
- package/dist/preview/Button/Button.d.ts +2 -0
- package/dist/preview/Button/index.d.ts +1 -0
- package/dist/preview/ButtonGroup/ButtonGroup.d.ts +2 -0
- package/dist/preview/ButtonGroup/index.d.ts +1 -0
- package/dist/preview/Calendar/Calendar.d.ts +2 -0
- package/dist/preview/Calendar/index.d.ts +1 -0
- package/dist/preview/Card/Card.d.ts +2 -0
- package/dist/preview/Card/index.d.ts +1 -0
- package/dist/preview/CenteredSlider/CenteredSlider.d.ts +2 -0
- package/dist/preview/CenteredSlider/index.d.ts +1 -0
- package/dist/preview/Checkbox/Checkbox.d.ts +2 -0
- package/dist/preview/Checkbox/index.d.ts +1 -0
- package/dist/preview/Config/Config.d.ts +8 -0
- package/dist/preview/Config/index.d.ts +1 -0
- package/dist/preview/ConnectedButtonGroup/ConnectedButtonGroup.d.ts +2 -0
- package/dist/preview/ConnectedButtonGroup/index.d.ts +1 -0
- package/dist/preview/DateField/DateField.d.ts +6 -0
- package/dist/preview/DateField/index.d.ts +1 -0
- package/dist/preview/DatePicker/DatePicker.d.ts +2 -0
- package/dist/preview/DatePicker/index.d.ts +1 -0
- package/dist/preview/DateRangePicker/DateRangePicker.d.ts +2 -0
- package/dist/preview/DateRangePicker/index.d.ts +1 -0
- package/dist/preview/Decorators/Decorators.d.ts +2 -0
- package/dist/preview/Decorators/index.d.ts +1 -0
- package/dist/preview/Dialog/Dialog.d.ts +2 -0
- package/dist/preview/Dialog/index.d.ts +1 -0
- package/dist/preview/Disclosure/Disclosure.d.ts +2 -0
- package/dist/preview/Disclosure/index.d.ts +1 -0
- package/dist/preview/Gradients/Gradients.d.ts +6 -0
- package/dist/preview/Gradients/index.d.ts +1 -0
- package/dist/preview/Icon/Icon.d.ts +2 -0
- package/dist/preview/Icon/index.d.ts +1 -0
- package/dist/preview/IconButton/IconButton.d.ts +2 -0
- package/dist/preview/IconButton/index.d.ts +1 -0
- package/dist/preview/Input/Input.d.ts +6 -0
- package/dist/preview/Input/index.d.ts +1 -0
- package/dist/preview/Link/Link.d.ts +2 -0
- package/dist/preview/Link/index.d.ts +1 -0
- package/dist/preview/List/List.d.ts +2 -0
- package/dist/preview/List/index.d.ts +1 -0
- package/dist/preview/Menu/Menu.d.ts +3 -0
- package/dist/preview/Menu/index.d.ts +1 -0
- package/dist/preview/Navigation/Navigation.d.ts +3 -0
- package/dist/preview/Navigation/index.d.ts +1 -0
- package/dist/preview/Radio/Radio.d.ts +2 -0
- package/dist/preview/Radio/index.d.ts +1 -0
- package/dist/preview/RangeCalendar/RangeCalendar.d.ts +2 -0
- package/dist/preview/RangeCalendar/index.d.ts +1 -0
- package/dist/preview/RangeSlider/RangeSlider.d.ts +2 -0
- package/dist/preview/RangeSlider/index.d.ts +1 -0
- package/dist/preview/SearchField/SearchField.d.ts +2 -0
- package/dist/preview/SearchField/index.d.ts +1 -0
- package/dist/preview/Select/Select.d.ts +2 -0
- package/dist/preview/Select/index.d.ts +1 -0
- package/dist/preview/SideSheet/SideSheet.d.ts +7 -0
- package/dist/preview/SideSheet/index.d.ts +1 -0
- package/dist/preview/Slider/Slider.d.ts +2 -0
- package/dist/preview/Slider/index.d.ts +1 -0
- package/dist/preview/Snackbar/Snackbar.d.ts +2 -0
- package/dist/preview/Snackbar/index.d.ts +1 -0
- package/dist/preview/SplitButton/SplitButton.d.ts +10 -0
- package/dist/preview/SplitButton/index.d.ts +1 -0
- package/dist/preview/Switch/Switch.d.ts +2 -0
- package/dist/preview/Switch/index.d.ts +1 -0
- package/dist/preview/Tabs/Tabs.d.ts +7 -0
- package/dist/preview/Tabs/index.d.ts +1 -0
- package/dist/preview/Tags/Tags.d.ts +2 -0
- package/dist/preview/Tags/index.d.ts +1 -0
- package/dist/preview/TextArea/TextArea.d.ts +6 -0
- package/dist/preview/TextArea/index.d.ts +1 -0
- package/dist/preview/ThemeSelector/ThemeSelector.d.ts +2 -0
- package/dist/preview/ThemeSelector/index.d.ts +1 -0
- package/dist/preview/TimeField/TimeField.d.ts +6 -0
- package/dist/preview/TimeField/index.d.ts +1 -0
- package/dist/preview/Toolbar/Toolbar.d.ts +10 -0
- package/dist/preview/Toolbar/index.d.ts +1 -0
- package/dist/preview/Tooltip/Tooltip.d.ts +2 -0
- package/dist/preview/Tooltip/index.d.ts +1 -0
- package/dist/utils/gradients/gradients.d.ts +97 -0
- package/dist/utils/index.d.ts +0 -1
- package/dist/utils/ref/ref.d.ts +35 -2
- package/dist/utils/scroll/scroll.d.ts +67 -4
- package/dist/utils/tapTarget/tapTarget.d.ts +57 -0
- package/dist/utils/theme/build.d.ts +24 -0
- package/dist/utils/theme/types.d.ts +70 -0
- package/dist/utils/theme/useTheme.d.ts +40 -0
- package/dist/utils/typography/base.d.ts +68 -0
- package/dist/utils/typography/core.d.ts +16 -0
- package/dist/utils/typography/fluid.d.ts +36 -0
- package/package.json +24 -26
- package/dist/chunks/useGlobalListeners +0 -294
- package/dist/chunks/useGlobalListeners.map +0 -1
- package/dist/chunks/usePress +0 -535
- package/dist/chunks/usePress.map +0 -1
- package/dist/components/Image/Image.d.ts +0 -2
- package/dist/components/Image/index.d.ts +0 -2
- package/dist/components/Image/index.js +0 -29
- package/dist/components/Image/index.js.map +0 -1
- package/dist/components/Image/types.d.ts +0 -9
- package/dist/components/Sheets/BottomSheet/BottomSheet.d.ts +0 -2
- package/dist/components/Sheets/BottomSheetModal/BottomSheetModal.d.ts +0 -2
- package/dist/components/Sheets/BottomSheetModal/context.d.ts +0 -5
- package/dist/components/Sheets/BottomSheetModal/index.js +0 -2
- package/dist/components/Sheets/BottomSheetModal/types.d.ts +0 -5
- package/dist/components/Sheets/SideSheet/SideSheet.d.ts +0 -2
- package/dist/components/Sheets/SideSheet/SideSheetDialog.d.ts +0 -2
- package/dist/components/Sheets/SideSheet/types.d.ts +0 -8
- package/dist/components/Sheets/SideSheetModal/SideSheetModal.d.ts +0 -2
- package/dist/components/Sheets/SideSheetModal/context.d.ts +0 -7
- package/dist/components/Sheets/SideSheetModal/index.js +0 -2
- package/dist/components/Sheets/SideSheetModal/types.d.ts +0 -7
- package/dist/utils/form/form.d.ts +0 -13
- package/dist/utils/form/index.d.ts +0 -1
- /package/dist/components/Sheets/{BottomSheetModal → BottomSheet/BottomSheetModal}/index.d.ts +0 -0
- /package/dist/components/Sheets/{SideSheetModal → SideSheet/SideSheetModal}/index.d.ts +0 -0
|
@@ -6,7 +6,7 @@ import { a, c as o, d as s, f as c, i as l, l as u, n as d, o as f, p, t as m, u
|
|
|
6
6
|
import { clsx as g } from "clsx";
|
|
7
7
|
import { jsx as _, jsxs as v } from "react/jsx-runtime";
|
|
8
8
|
import { ToggleButton as y } from "react-aria-components";
|
|
9
|
-
|
|
9
|
+
// src/components/Button/ToggleButton/ToggleButton.tsx
|
|
10
10
|
var b = e(), x = (e) => {
|
|
11
11
|
let x = (0, b.c)(45), S, C, w, T, E, D, O, k, A, j, M;
|
|
12
12
|
x[0] === e ? (S = x[1], C = x[2], w = x[3], T = x[4], E = x[5], D = x[6], O = x[7], k = x[8], A = x[9], j = x[10], M = x[11]) : ({size: j, shape: A, color: w, tooltip: M, selectedIcon: k, icon: T, children: S, onPress: D, className: C, iconPlacement: E, ...O} = e, x[0] = e, x[1] = S, x[2] = C, x[3] = w, x[4] = T, x[5] = E, x[6] = D, x[7] = O, x[8] = k, x[9] = A, x[10] = j, x[11] = M);
|
|
@@ -70,7 +70,6 @@ var b = e(), x = (e) => {
|
|
|
70
70
|
let J;
|
|
71
71
|
return x[42] !== q || x[43] !== M ? (J = m(q, M), x[42] = q, x[43] = M, x[44] = J) : J = x[44], J;
|
|
72
72
|
};
|
|
73
|
-
//#endregion
|
|
74
73
|
export { x as ToggleButton };
|
|
75
74
|
|
|
76
75
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["renderProps","iconToRender","iconSize","handlePress"],"sources":["../../../../src/components/Button/ToggleButton/ToggleButton.tsx"],"sourcesContent":["import { clsx } from \"clsx\";\nimport { ToggleButton as AriaToggleButton } from \"react-aria-components\";\nimport { Icon } from \"@/components/Icon\";\nimport { Splash } from \"@/components/Splash/Splash\";\nimport { useSplash } from \"@/components/Splash/useSplash\";\nimport { TapTarget } from \"@/utils/tapTarget\";\nimport {\n ButtonCore,\n ButtonIconSizeMapping,\n ButtonLabelTextMapping,\n ButtonReset,\n ButtonSizeBase,\n buttonColorBase,\n buttonColorConfig,\n buttonSizeConfig,\n newButtonBaseDataAttrs,\n useButtonConfig,\n withTooltip,\n} from \"../core\";\nimport type { ToggleButtonProps } from \"./types\";\n\nexport const ToggleButton: React.FC<ToggleButtonProps> = ({\n size,\n shape,\n color,\n tooltip,\n selectedIcon,\n icon,\n children,\n onPress,\n className,\n iconPlacement,\n ...props\n}) => {\n const { buttonColor, buttonShape, buttonSize, buttonIconPlacement } =\n useButtonConfig({\n size,\n shape,\n color,\n iconPlacement,\n });\n\n const { splashInfo, handlePress } = useSplash(onPress);\n const isChildFunc = typeof children === \"function\";\n\n const baseButtonDataAttrs = newButtonBaseDataAttrs({\n shape: buttonShape,\n size: buttonSize,\n color: buttonColor,\n });\n\n const toggleButtonDataAttrs = {\n ...baseButtonDataAttrs,\n \"data-toggle-button\": true,\n };\n\n return withTooltip(\n <AriaToggleButton\n onPress={handlePress}\n className={(renderProps) =>\n clsx(\n ButtonReset,\n TapTarget,\n buttonSizeConfig(buttonSize),\n buttonColorConfig(buttonColor),\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n {...toggleButtonDataAttrs}\n data-button\n >\n {(renderProps) => {\n const {\n isSelected,\n isDisabled,\n isFocusVisible,\n isFocused,\n isPressed,\n isHovered,\n } = renderProps;\n\n const dataAttrs = {\n ...toggleButtonDataAttrs,\n \"data-hovered\": isHovered || undefined,\n \"data-disabled\": isDisabled || undefined,\n \"data-focused\": isFocused || undefined,\n \"data-focus-visible\": isFocusVisible || undefined,\n \"data-pressed\": isPressed || undefined,\n \"data-selected\": isSelected || undefined,\n \"data-visual-button\": true,\n };\n\n let iconToRender = icon;\n if (isSelected && selectedIcon) iconToRender = selectedIcon;\n\n const iconSize = ButtonIconSizeMapping[buttonSize];\n\n const iconComp = iconToRender && (\n <Icon icon={iconToRender} size={iconSize} />\n );\n\n return (\n <span\n className={clsx(\n ButtonCore,\n buttonColorBase,\n ButtonSizeBase,\n ButtonLabelTextMapping[buttonSize]\n )}\n {...dataAttrs}\n >\n {splashInfo && <Splash {...splashInfo} />}\n\n {buttonIconPlacement === \"start\" && iconComp}\n\n {isChildFunc ? children(renderProps) : children}\n\n {buttonIconPlacement === \"end\" && iconComp}\n </span>\n );\n }}\n </AriaToggleButton>,\n tooltip\n );\n};\n"],"mappings":";;;;;;;;;
|
|
1
|
+
{"version":3,"file":"index.js","names":["renderProps","iconToRender","iconSize","handlePress","_c","AriaToggleButton","require_compiler_runtime","Icon","Splash","useSplash","buttonSizeConfig","ButtonCore","ButtonReset","ButtonIconSizeMapping","buttonColorBase","useButtonConfig","ButtonSizeBase","withTooltip","buttonColorConfig","ToggleButton$1","import_compiler_runtime","ToggleButton","$","children","className","color","icon","iconPlacement","onPress","props","selectedIcon","shape","size","tooltip","t0","t1","isChildFunc","t2","buttonColor","buttonShape","buttonSize","newButtonBaseDataAttrs","baseButtonDataAttrs","t3","toggleButtonDataAttrs","t4","clsx","TapTarget","renderProps","t5","buttonIconPlacement","splashInfo","renderProps_0","dataAttrs","isHovered","isDisabled","isFocused","isFocusVisible","isPressed","isSelected","iconToRender","iconSize","iconComp","ButtonLabelTextMapping","t6","handlePress","t7"],"sources":["../../../../src/components/Button/ToggleButton/ToggleButton.tsx"],"sourcesContent":["import { clsx } from \"clsx\";\nimport { ToggleButton as AriaToggleButton } from \"react-aria-components\";\nimport { Icon } from \"@/components/Icon\";\nimport { Splash } from \"@/components/Splash/Splash\";\nimport { useSplash } from \"@/components/Splash/useSplash\";\nimport { TapTarget } from \"@/utils/tapTarget\";\nimport {\n ButtonCore,\n ButtonIconSizeMapping,\n ButtonLabelTextMapping,\n ButtonReset,\n ButtonSizeBase,\n buttonColorBase,\n buttonColorConfig,\n buttonSizeConfig,\n newButtonBaseDataAttrs,\n useButtonConfig,\n withTooltip,\n} from \"../core\";\nimport type { ToggleButtonProps } from \"./types\";\n\n/**\n * A two-state toggle button implementing Material Design 3 Toggle Button guidelines.\n *\n * Allows users to toggle between active/selected and inactive/unselected states.\n * Supports swapping between `icon` and `selectedIcon` based on current selection state,\n * flexible sizing, shapes, and Material 3 toggle button color variants.\n *\n * Built on top of React Aria's `ToggleButton`.\n *\n * @example\n * ```tsx\n * <ToggleButton\n * icon={Bookmark}\n * selectedIcon={BookmarkCheck}\n * isSelected={isBookmarked}\n * onChange={setIsBookmarked}\n * >\n * Bookmark\n * </ToggleButton>\n * ```\n */\nexport const ToggleButton: React.FC<ToggleButtonProps> = ({\n size,\n shape,\n color,\n tooltip,\n selectedIcon,\n icon,\n children,\n onPress,\n className,\n iconPlacement,\n ...props\n}) => {\n const { buttonColor, buttonShape, buttonSize, buttonIconPlacement } =\n useButtonConfig({\n size,\n shape,\n color,\n iconPlacement,\n });\n\n const { splashInfo, handlePress } = useSplash(onPress);\n const isChildFunc = typeof children === \"function\";\n\n const baseButtonDataAttrs = newButtonBaseDataAttrs({\n shape: buttonShape,\n size: buttonSize,\n color: buttonColor,\n });\n\n const toggleButtonDataAttrs = {\n ...baseButtonDataAttrs,\n \"data-toggle-button\": true,\n };\n\n return withTooltip(\n <AriaToggleButton\n onPress={handlePress}\n className={(renderProps) =>\n clsx(\n ButtonReset,\n TapTarget,\n buttonSizeConfig(buttonSize),\n buttonColorConfig(buttonColor),\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n {...toggleButtonDataAttrs}\n data-button\n >\n {(renderProps) => {\n const {\n isSelected,\n isDisabled,\n isFocusVisible,\n isFocused,\n isPressed,\n isHovered,\n } = renderProps;\n\n const dataAttrs = {\n ...toggleButtonDataAttrs,\n \"data-hovered\": isHovered || undefined,\n \"data-disabled\": isDisabled || undefined,\n \"data-focused\": isFocused || undefined,\n \"data-focus-visible\": isFocusVisible || undefined,\n \"data-pressed\": isPressed || undefined,\n \"data-selected\": isSelected || undefined,\n \"data-visual-button\": true,\n };\n\n let iconToRender = icon;\n if (isSelected && selectedIcon) iconToRender = selectedIcon;\n\n const iconSize = ButtonIconSizeMapping[buttonSize];\n\n const iconComp = iconToRender && (\n <Icon icon={iconToRender} size={iconSize} />\n );\n\n return (\n <span\n className={clsx(\n ButtonCore,\n buttonColorBase,\n ButtonSizeBase,\n ButtonLabelTextMapping[buttonSize]\n )}\n {...dataAttrs}\n >\n {splashInfo && <Splash {...splashInfo} />}\n\n {buttonIconPlacement === \"start\" && iconComp}\n\n {isChildFunc ? children(renderProps) : children}\n\n {buttonIconPlacement === \"end\" && iconComp}\n </span>\n );\n }}\n </AriaToggleButton>,\n tooltip\n );\n};\n"],"mappings":";;;;;;;;;A,aA0CaqB,KAA4C,MAAA;CAAA,IAAAC,KAAA,GAAAlB,EAAAA,EAAAA,CAAA,EAAA,GAAAmB,GAAAC,GAAAC,GAAAC,GAAAC,GAAAC,GAAAC,GAAAC,GAAAC,GAAAC,GAAAC;CAAA,AAAAX,EAAA,OAAAY,KAYxD,IAAAZ,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,KAAA,IAAAA,EAAA,QAZyD,6HAAA,GAAAO,KAAAK,GAYzD,EAAA,KAAAA,GAAA,EAAA,KAAAX,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,MAAAC,GAAA,EAAA,MAAAC;CAAA,IAAAE;CAAA,AAAAb,EAAA,QAAAG,KAAAH,EAAA,QAAAK,KAAAL,EAAA,QAAAS,KAAAT,EAAA,QAAAU,KAEuB,IAAA;EAAA;EAAA;EAAA;EAAA;CAKhB,GAAC,EAAA,MAAAP,GAAA,EAAA,MAAAE,GAAA,EAAA,MAAAI,GAAA,EAAA,MAAAC,GAAA,EAAA,MAAAG,KAAA,IAAAb,EAAA;CANL,IAAA,EAAA,gBAAA,gBAAA,eAAA,2BACIP,EAAgBoB,CAKf,GAEL,EAAA,eAAA,mBAAoC1B,EAAUmB,CAAO,GACrDQ,IAAoB,OAAOb,KAAa,YAAWc;CAAA,AAAAf,EAAA,QAAAgB,KAAAhB,EAAA,QAAAiB,KAAAjB,EAAA,QAAAkB,KAEvB,IAAAC,EAAuB;EAAA,OACxCF;EAAW,MACZC;EAAU,OACTF;CACX,CAAC,GAAC,EAAA,MAAAA,GAAA,EAAA,MAAAC,GAAA,EAAA,MAAAC,GAAA,EAAA,MAAAH,KAAA,IAAAf,EAAA;CAJF,IAAAoB,IAA4BL,GAIzBM;CAAA,AAAArB,EAAA,QAAAoB,IAKF,IAAApB,EAAA,OAH6B,IAAA;EAAA,GACvBoB;EAAmB,sBACA;CAC1B,GAAC,EAAA,MAAAA,GAAA,EAAA,MAAAC;CAHD,IAAAC,IAA8BD,GAG5BE;CAAA,AAAAvB,EAAA,QAAAgB,KAAAhB,EAAA,QAAAkB,KAAAlB,EAAA,QAAAE,KAKiB,KAAA,MACPsB,EACIlC,GACAmC,GACArC,EAAiB8B,CAAU,GAC3BtB,EAAkBoB,CAAW,GAC7B,OAAOd,KAAc,aACfA,EAAUwB,CACF,IAFdxB,CAGJ,GAAC,EAAA,MAAAc,GAAA,EAAA,MAAAE,GAAA,EAAA,MAAAhB,GAAA,EAAA,MAAAqB,KAAA,IAAAvB,EAAA;CAAA,IAAA2B;CAAA,AAAA3B,EAAA,QAAA4B,KAAA5B,EAAA,QAAAkB,KAAAlB,EAAA,QAAAC,KAAAD,EAAA,QAAAI,KAAAJ,EAAA,QAAAc,KAAAd,EAAA,QAAAQ,KAAAR,EAAA,QAAA6B,KAAA7B,EAAA,QAAAsB,KAMJ,KAAA,MAAA;EACG,IAAA,EAAA,eAAA,eAAA,mBAAA,cAAA,cAAA,iBAOI5C,GAEJqD,IAAkB;GAAA,GACXT;GAAqB,gBACRU,KAAA,KAAA;GAAsB,iBACrBC,KAAA,KAAA;GAAuB,gBACxBC,KAAA,KAAA;GAAsB,sBAChBC,KAAA,KAAA;GAA2B,gBACjCC,KAAA,KAAA;GAAsB,iBACrBC,KAAA,KAAA;GAAuB,sBAClB;EAC1B,GAEAC,IAAmBlC;EACnB,AAAIiC,KAAA7B,MAA4B,IAAeA;EAE/C,IAAA+B,IAAiBhD,EAAsB2B,IAEvCsB,IAAiBF,KACb,kBAACrD,GAAD;GAAYN,MAAA2D;GAAoB1D,MAAA2D;EAAQ,CAAA;EAC1C,OAGE,kBAAA,QAAA;GACe,WAAAf,EACPnC,GACAG,GACAE,GACA+C,EAAuBvB,EAC3B;GAAC,GACGa;GAPR,UAAA;IASKF,KAAc,kBAAC3C,GAAD,EAAO,GAAK2C,EAAU,CAAA;IAEpCD,MAAwB,WAAxBY;IAEA1B,IAAcb,EAASvB,CAAsB,IAA7CuB;IAEA2B,MAAwB,SAAxBY;GACE;;CAAA,GAEd,EAAA,MAAAZ,GAAA,EAAA,MAAAV,GAAA,EAAA,MAAAjB,GAAA,EAAA,MAAAG,GAAA,EAAA,MAAAU,GAAA,EAAA,MAAAN,GAAA,EAAA,MAAAqB,GAAA,EAAA,MAAAP,GAAA,EAAA,MAAAK,KAAA,IAAA3B,EAAA;CAAA,IAAA0C;CAAA,AAAA1C,EAAA,QAAA2C,KAAA3C,EAAA,QAAAO,KAAAP,EAAA,QAAAuB,KAAAvB,EAAA,QAAA2B,KAAA3B,EAAA,QAAAsB,KAlEL,IAAA,kBAACvC,GAAD;EACaF,SAAA8D;EACE,WAAApB;EASN,GAEDhB;EAAK,GACLe;EACJ,eAAA;EAEC,UAAAK;CAjBY,CAAA,GAmEE,EAAA,MAAAgB,GAAA,EAAA,MAAApC,GAAA,EAAA,MAAAgB,GAAA,EAAA,MAAAI,GAAA,EAAA,MAAAL,GAAA,EAAA,MAAAoB,KAAA,IAAA1C,EAAA;CAAA,IAAA4C;CAEtB,OAFsB5C,EAAA,QAAA0C,KAAA1C,EAAA,QAAAW,KApEhB,IAAAhB,EACH+C,GAoEA/B,CACJ,GAAC,EAAA,MAAA+B,GAAA,EAAA,MAAA/B,GAAA,EAAA,MAAAiC,KAAA,IAAA5C,EAAA,KAtEM4C;AAsEN"}
|
|
@@ -1,7 +1,21 @@
|
|
|
1
1
|
import { LucideIcon } from 'lucide-react';
|
|
2
2
|
import { ToggleButton } from 'react-aria-components';
|
|
3
3
|
import { ButtonBaseProps, ToggleButtonColor } from '../core';
|
|
4
|
+
/**
|
|
5
|
+
* Props for the {@link ToggleButton} component.
|
|
6
|
+
* Extends React Aria's {@link ToggleButton} props with customized color options and toggle state icon support.
|
|
7
|
+
*/
|
|
4
8
|
export interface ToggleButtonProps extends React.ComponentPropsWithRef<typeof ToggleButton>, Omit<ButtonBaseProps, "color"> {
|
|
9
|
+
/**
|
|
10
|
+
* Optional icon to render when the toggle button is in the selected (`isSelected = true`) state.
|
|
11
|
+
* If omitted, {@link ButtonBaseProps.icon} is used for both selected and unselected states.
|
|
12
|
+
*/
|
|
5
13
|
selectedIcon?: LucideIcon;
|
|
14
|
+
/**
|
|
15
|
+
* Visual color style variant for the toggle button.
|
|
16
|
+
* Note: Does not include `"text"` since toggle buttons require visual container state changes.
|
|
17
|
+
*
|
|
18
|
+
* @default "filled"
|
|
19
|
+
*/
|
|
6
20
|
color?: ToggleButtonColor;
|
|
7
21
|
}
|
|
@@ -1,2 +1,23 @@
|
|
|
1
1
|
import { ToggleIconButtonProps } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* A compact, icon-only toggle button implementing Material Design 3 Toggle Icon Buttons.
|
|
4
|
+
*
|
|
5
|
+
* Allows users to toggle between two states using a single icon button (e.g. mute/unmute, bookmark/unbookmark).
|
|
6
|
+
* Switches between `icon` and `selectedIcon` based on the current selection state.
|
|
7
|
+
*
|
|
8
|
+
* Built on top of React Aria's `ToggleButton`. Always provide an accessible `aria-label`
|
|
9
|
+
* or `aria-labelledby` attribute for screen reader accessibility.
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```tsx
|
|
13
|
+
* <ToggleIconButton
|
|
14
|
+
* icon={Volume2}
|
|
15
|
+
* selectedIcon={VolumeX}
|
|
16
|
+
* isSelected={isMuted}
|
|
17
|
+
* onChange={setIsMuted}
|
|
18
|
+
* tooltip={isMuted ? "Unmute" : "Mute"}
|
|
19
|
+
* aria-label={isMuted ? "Unmute" : "Mute"}
|
|
20
|
+
* />
|
|
21
|
+
* ```
|
|
22
|
+
*/
|
|
2
23
|
export declare const ToggleIconButton: React.FC<ToggleIconButtonProps>;
|
|
@@ -5,7 +5,7 @@ import { c as i, d as a, f as o, l as s, n as c, o as l, p as u, s as d, t as f,
|
|
|
5
5
|
import { clsx as m } from "clsx";
|
|
6
6
|
import { jsx as h, jsxs as g } from "react/jsx-runtime";
|
|
7
7
|
import { ToggleButton as _ } from "react-aria-components";
|
|
8
|
-
|
|
8
|
+
// src/components/Button/ToggleIconButton/ToggleIconButton.tsx
|
|
9
9
|
var v = ({ size: v, shape: y, color: b, width: x = "default", tooltip: S, selectedIcon: C, icon: w, onPress: T, className: E, ...D }) => {
|
|
10
10
|
let { buttonColor: O, buttonShape: k, buttonSize: A } = c({
|
|
11
11
|
size: v,
|
|
@@ -51,7 +51,6 @@ var v = ({ size: v, shape: y, color: b, width: x = "default", tooltip: S, select
|
|
|
51
51
|
}
|
|
52
52
|
}), S);
|
|
53
53
|
};
|
|
54
|
-
//#endregion
|
|
55
54
|
export { v as ToggleIconButton };
|
|
56
55
|
|
|
57
56
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/Button/ToggleIconButton/ToggleIconButton.tsx"],"sourcesContent":["import { clsx } from \"clsx\";\nimport { ToggleButton as AriaToggleButton } from \"react-aria-components\";\nimport { Icon } from \"@/components/Icon\";\nimport { Splash } from \"@/components/Splash/Splash\";\nimport { useSplash } from \"@/components/Splash/useSplash\";\nimport { TapTarget } from \"@/utils/tapTarget\";\nimport {\n ButtonCore,\n ButtonReset,\n ButtonSizeBase,\n buttonColorBase,\n buttonColorConfig,\n buttonSizeConfig,\n IconButtonIconSizeMapping,\n newButtonBaseDataAttrs,\n useButtonConfig,\n withTooltip,\n} from \"../core\";\nimport type { ToggleIconButtonProps } from \"./types\";\n\nexport const ToggleIconButton: React.FC<ToggleIconButtonProps> = ({\n size,\n shape,\n color,\n width = \"default\",\n tooltip,\n selectedIcon,\n icon,\n onPress,\n className,\n ...props\n}) => {\n const { buttonColor, buttonShape, buttonSize } = useButtonConfig({\n size,\n shape,\n color,\n });\n\n const { splashInfo, handlePress } = useSplash(onPress);\n\n const baseButtonDataAttrs = newButtonBaseDataAttrs({\n shape: buttonShape,\n size: buttonSize,\n color: buttonColor,\n });\n\n const iconButtonDataAttrs = {\n ...baseButtonDataAttrs,\n \"data-width\": width,\n \"data-icon-button\": true,\n \"data-toggle-button\": true,\n };\n\n return withTooltip(\n <AriaToggleButton\n onPress={handlePress}\n className={(renderProps) =>\n clsx(\n ButtonReset,\n TapTarget,\n buttonSizeConfig(buttonSize),\n buttonColorConfig(buttonColor),\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n {...iconButtonDataAttrs}\n data-button\n >\n {({\n isSelected,\n isDisabled,\n isFocusVisible,\n isFocused,\n isPressed,\n isHovered,\n }) => {\n const dataAttrs = {\n ...iconButtonDataAttrs,\n \"data-hovered\": isHovered || undefined,\n \"data-disabled\": isDisabled || undefined,\n \"data-focused\": isFocused || undefined,\n \"data-focus-visible\": isFocusVisible || undefined,\n \"data-pressed\": isPressed || undefined,\n \"data-selected\": isSelected || undefined,\n \"data-visual-button\": true,\n };\n\n let iconToRender = icon;\n if (isSelected && selectedIcon) iconToRender = selectedIcon;\n\n const iconSize = IconButtonIconSizeMapping[buttonSize];\n return (\n <span\n className={clsx(\n ButtonCore,\n buttonColorBase,\n ButtonSizeBase\n )}\n {...dataAttrs}\n >\n {splashInfo && <Splash {...splashInfo} />}\n\n {iconToRender && (\n <Icon icon={iconToRender} size={iconSize} />\n )}\n </span>\n );\n }}\n </AriaToggleButton>,\n tooltip\n );\n};\n"],"mappings":";;;;;;;;
|
|
1
|
+
{"version":3,"file":"index.js","names":["AriaToggleButton","TapTarget","useSplash","buttonSizeConfig","ButtonCore","ButtonReset","buttonColorBase","useButtonConfig","ButtonSizeBase","newButtonBaseDataAttrs","IconButtonIconSizeMapping","withTooltip","buttonColorConfig","ToggleIconButton","props","onPress","iconButtonDataAttrs","buttonShape","buttonSize","buttonColor","width","ToggleButton","handlePress","clsx","className","renderProps","dataAttrs","isHovered","isDisabled","isFocused","isFocusVisible","isPressed","isSelected","iconToRender","icon","selectedIcon","iconSize","splashInfo","Splash","Icon","tooltip"],"sources":["../../../../src/components/Button/ToggleIconButton/ToggleIconButton.tsx"],"sourcesContent":["import { clsx } from \"clsx\";\nimport { ToggleButton as AriaToggleButton } from \"react-aria-components\";\nimport { Icon } from \"@/components/Icon\";\nimport { Splash } from \"@/components/Splash/Splash\";\nimport { useSplash } from \"@/components/Splash/useSplash\";\nimport { TapTarget } from \"@/utils/tapTarget\";\nimport {\n ButtonCore,\n ButtonReset,\n ButtonSizeBase,\n buttonColorBase,\n buttonColorConfig,\n buttonSizeConfig,\n IconButtonIconSizeMapping,\n newButtonBaseDataAttrs,\n useButtonConfig,\n withTooltip,\n} from \"../core\";\nimport type { ToggleIconButtonProps } from \"./types\";\n\n/**\n * A compact, icon-only toggle button implementing Material Design 3 Toggle Icon Buttons.\n *\n * Allows users to toggle between two states using a single icon button (e.g. mute/unmute, bookmark/unbookmark).\n * Switches between `icon` and `selectedIcon` based on the current selection state.\n *\n * Built on top of React Aria's `ToggleButton`. Always provide an accessible `aria-label`\n * or `aria-labelledby` attribute for screen reader accessibility.\n *\n * @example\n * ```tsx\n * <ToggleIconButton\n * icon={Volume2}\n * selectedIcon={VolumeX}\n * isSelected={isMuted}\n * onChange={setIsMuted}\n * tooltip={isMuted ? \"Unmute\" : \"Mute\"}\n * aria-label={isMuted ? \"Unmute\" : \"Mute\"}\n * />\n * ```\n */\nexport const ToggleIconButton: React.FC<ToggleIconButtonProps> = ({\n size,\n shape,\n color,\n width = \"default\",\n tooltip,\n selectedIcon,\n icon,\n onPress,\n className,\n ...props\n}) => {\n const { buttonColor, buttonShape, buttonSize } = useButtonConfig({\n size,\n shape,\n color,\n });\n\n const { splashInfo, handlePress } = useSplash(onPress);\n\n const baseButtonDataAttrs = newButtonBaseDataAttrs({\n shape: buttonShape,\n size: buttonSize,\n color: buttonColor,\n });\n\n const iconButtonDataAttrs = {\n ...baseButtonDataAttrs,\n \"data-width\": width,\n \"data-icon-button\": true,\n \"data-toggle-button\": true,\n };\n\n return withTooltip(\n <AriaToggleButton\n onPress={handlePress}\n className={(renderProps) =>\n clsx(\n ButtonReset,\n TapTarget,\n buttonSizeConfig(buttonSize),\n buttonColorConfig(buttonColor),\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n {...iconButtonDataAttrs}\n data-button\n >\n {({\n isSelected,\n isDisabled,\n isFocusVisible,\n isFocused,\n isPressed,\n isHovered,\n }) => {\n const dataAttrs = {\n ...iconButtonDataAttrs,\n \"data-hovered\": isHovered || undefined,\n \"data-disabled\": isDisabled || undefined,\n \"data-focused\": isFocused || undefined,\n \"data-focus-visible\": isFocusVisible || undefined,\n \"data-pressed\": isPressed || undefined,\n \"data-selected\": isSelected || undefined,\n \"data-visual-button\": true,\n };\n\n let iconToRender = icon;\n if (isSelected && selectedIcon) iconToRender = selectedIcon;\n\n const iconSize = IconButtonIconSizeMapping[buttonSize];\n return (\n <span\n className={clsx(\n ButtonCore,\n buttonColorBase,\n ButtonSizeBase\n )}\n {...dataAttrs}\n >\n {splashInfo && <Splash {...splashInfo} />}\n\n {iconToRender && (\n <Icon icon={iconToRender} size={iconSize} />\n )}\n </span>\n );\n }}\n </AriaToggleButton>,\n tooltip\n );\n};\n"],"mappings":";;;;;;;;AAyCA,IAAaa,KAAqD,EAC9D,SACA,UACA,UACA,WAAQ,WACR,YACA,iBACA,SACA,YACA,cACA,GAAGC,QACD;CACF,IAAM,EAAE,gBAAa,gBAAa,kBAAeP,EAAgB;EAC7D;EACA;EACA;CACJ,CAAC,GAEK,EAAE,eAAY,mBAAgBL,EAAUa,CAAO,GAQ/CC,IAAsB;EACxB,GAPwBP,EAAuB;GAC/C,OAAOQ;GACP,MAAMC;GACN,OAAOC;EACX,CAGO;EACH,cAAcC;EACd,oBAAoB;EACpB,sBAAsB;CAC1B;CAEA,OAAOT,EACH,kBAACX,GAAD;EACI,SAASsB;EACT,YAAY,MACRC,EACIlB,GACAJ,GACAE,EAAiBe,CAAU,GAC3BN,EAAkBO,CAAW,GAC7B,OAAOK,KAAc,aACfA,EAAUC,CAAW,IACrBD,CACV;EAEJ,GAAIV;EACJ,GAAIE;EACJ,eAAA;EAEE,WAAA,EACE,eACA,eACA,mBACA,cACA,cACA,mBACE;GACF,IAAMU,IAAY;IACd,GAAGV;IACH,gBAAgBW,KAAa,KAAA;IAC7B,iBAAiBC,KAAc,KAAA;IAC/B,gBAAgBC,KAAa,KAAA;IAC7B,sBAAsBC,KAAkB,KAAA;IACxC,gBAAgBC,KAAa,KAAA;IAC7B,iBAAiBC,KAAc,KAAA;IAC/B,sBAAsB;GAC1B,GAEIC,IAAeC;GACnB,AAAIF,KAAcG,MAAc,IAAeA;GAE/C,IAAMC,IAAW1B,EAA0BQ;GAC3C,OACI,kBAAC,QAAD;IACI,WAAWK,EACPnB,GACAE,GACAE,CACJ;IACA,GAAIkB;IANR,UAAA,CAQKW,KAAc,kBAACC,GAAD,EAAQ,GAAID,EAAW,CAAA,GAErCJ,KACG,kBAACM,GAAD;KAAM,MAAMN;KAAc,MAAMG;IAAS,CAAA,CAE3C;;EAEd;CACc,CAAA,GAClBI,CACJ;AACJ"}
|
|
@@ -1,6 +1,15 @@
|
|
|
1
1
|
import { LucideIcon } from 'lucide-react';
|
|
2
2
|
import { ToggleButton } from 'react-aria-components';
|
|
3
3
|
import { IconButtonBaseProps } from '../core';
|
|
4
|
+
/**
|
|
5
|
+
* Props for the {@link ToggleIconButton} component.
|
|
6
|
+
* Extends React Aria's {@link ToggleButton} props (omitting `children`) with {@link IconButtonBaseProps}
|
|
7
|
+
* and support for a distinct icon in the selected state.
|
|
8
|
+
*/
|
|
4
9
|
export interface ToggleIconButtonProps extends Omit<React.ComponentPropsWithRef<typeof ToggleButton>, "children">, IconButtonBaseProps {
|
|
10
|
+
/**
|
|
11
|
+
* Optional icon to render when the toggle button is in the selected (`isSelected = true`) state.
|
|
12
|
+
* If omitted, {@link IconButtonBaseProps.icon} is used for both selected and unselected states.
|
|
13
|
+
*/
|
|
5
14
|
selectedIcon?: LucideIcon;
|
|
6
15
|
}
|
|
@@ -3,25 +3,58 @@ import { AllButtonColor, ButtonColor, IconButtonColor } from './color';
|
|
|
3
3
|
import { ButtonShape } from './shape';
|
|
4
4
|
import { ButtonSize } from './sizes';
|
|
5
5
|
import { IconButtonWidth } from './width';
|
|
6
|
+
/**
|
|
7
|
+
* Determines whether an icon inside a button is rendered before or after the text label.
|
|
8
|
+
*
|
|
9
|
+
* - `"start"`: Renders icon at the leading edge (before text).
|
|
10
|
+
* - `"end"`: Renders icon at the trailing edge (after text).
|
|
11
|
+
*/
|
|
6
12
|
export type ButtonIconPlacement = "start" | "end";
|
|
13
|
+
/**
|
|
14
|
+
* Core props shared across standard text/label button components (e.g. `Button`, `LinkButton`).
|
|
15
|
+
*/
|
|
7
16
|
export interface ButtonBaseProps {
|
|
17
|
+
/** Visual style and color scheme of the button. Defaults to `"filled"`. */
|
|
8
18
|
color?: ButtonColor;
|
|
19
|
+
/** Size scale of the button. Defaults to `"small"`. */
|
|
9
20
|
size?: ButtonSize;
|
|
21
|
+
/** Corner rounding style (`"round"` or `"square"`). Defaults to `"round"`. */
|
|
10
22
|
shape?: ButtonShape;
|
|
23
|
+
/** Optional tooltip text displayed on hover/focus. */
|
|
11
24
|
tooltip?: string;
|
|
25
|
+
/** Optional Lucide icon component displayed alongside label text. */
|
|
12
26
|
icon?: LucideIcon;
|
|
27
|
+
/** Icon placement relative to label text (`"start"` or `"end"`). Defaults to `"start"`. */
|
|
13
28
|
iconPlacement?: ButtonIconPlacement;
|
|
14
29
|
}
|
|
30
|
+
/**
|
|
31
|
+
* Core props shared across icon-only button components (e.g. `IconButton`, `LinkIconButton`).
|
|
32
|
+
*/
|
|
15
33
|
export interface IconButtonBaseProps {
|
|
34
|
+
/** Visual style and color scheme of the icon button. Defaults to `"standard"`. */
|
|
16
35
|
color?: IconButtonColor;
|
|
36
|
+
/** Size scale of the icon button. Defaults to `"small"`. */
|
|
17
37
|
size?: ButtonSize;
|
|
38
|
+
/** Corner rounding style (`"round"` or `"square"`). Defaults to `"round"`. */
|
|
18
39
|
shape?: ButtonShape;
|
|
40
|
+
/** Width variation (`"narrow"`, `"default"`, or `"wide"`). Defaults to `"default"`. */
|
|
19
41
|
width?: IconButtonWidth;
|
|
42
|
+
/** Optional tooltip text displayed on hover/focus. */
|
|
20
43
|
tooltip?: string;
|
|
44
|
+
/** Required Lucide icon component rendered inside the button. */
|
|
21
45
|
icon: LucideIcon;
|
|
22
46
|
}
|
|
47
|
+
/** CSS class resetting default button/link styling (outlines, borders, backgrounds). */
|
|
23
48
|
export declare const ButtonReset: string;
|
|
49
|
+
/** CSS class providing the core layout and flex alignment for button internals. */
|
|
24
50
|
export declare const ButtonCore: string;
|
|
51
|
+
/**
|
|
52
|
+
* Generates standard data attributes (`data-shape`, `data-size`, `data-color`)
|
|
53
|
+
* applied to button DOM nodes for CSS attribute styling.
|
|
54
|
+
*
|
|
55
|
+
* @param options - Shape, size, and color configuration.
|
|
56
|
+
* @returns Object with data attributes for spreading onto elements.
|
|
57
|
+
*/
|
|
25
58
|
export declare function newButtonBaseDataAttrs({ shape, size, color, }: {
|
|
26
59
|
shape: ButtonShape;
|
|
27
60
|
color: AllButtonColor;
|
|
@@ -1,9 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Fundamental Material 3 button color styles shared across all button variants:
|
|
3
|
+
* - `"filled"`: High-emphasis solid surface with inverted text.
|
|
4
|
+
* - `"tonal"`: Medium-high emphasis filled container with primary-tonal background.
|
|
5
|
+
* - `"outlined"`: Medium-emphasis button with container outline and transparent background.
|
|
6
|
+
*/
|
|
1
7
|
export type CoreButtonColor = "filled" | "tonal" | "outlined";
|
|
8
|
+
/**
|
|
9
|
+
* Color variants supported by standard buttons (`Button`, `LinkButton`):
|
|
10
|
+
* - Includes {@link CoreButtonColor} (`"filled"`, `"tonal"`, `"outlined"`).
|
|
11
|
+
* - `"elevated"`: Low-emphasis surface container with shadow elevation.
|
|
12
|
+
* - `"text"`: Lowest-emphasis flat text button with transparent background.
|
|
13
|
+
*/
|
|
2
14
|
export type ButtonColor = CoreButtonColor | "elevated" | "text";
|
|
15
|
+
/**
|
|
16
|
+
* Color variants supported by toggle buttons (`ToggleButton`):
|
|
17
|
+
* - Includes {@link CoreButtonColor} plus `"elevated"`.
|
|
18
|
+
*/
|
|
3
19
|
export type ToggleButtonColor = CoreButtonColor | "elevated";
|
|
20
|
+
/**
|
|
21
|
+
* Color variants supported by icon buttons (`IconButton`, `LinkIconButton`):
|
|
22
|
+
* - Includes {@link CoreButtonColor} plus `"standard"` (unfilled, frameless icon).
|
|
23
|
+
*/
|
|
4
24
|
export type IconButtonColor = CoreButtonColor | "standard";
|
|
25
|
+
/**
|
|
26
|
+
* Color variants supported by split buttons (`SplitButton`):
|
|
27
|
+
* - Includes {@link CoreButtonColor} plus `"elevated"`.
|
|
28
|
+
*/
|
|
5
29
|
export type SplitButtonColor = CoreButtonColor | "elevated";
|
|
30
|
+
/**
|
|
31
|
+
* Color variants supported by connected button groups (`ConnectedButtonGroup`):
|
|
32
|
+
* - Includes {@link CoreButtonColor} plus `"elevated"`.
|
|
33
|
+
*/
|
|
6
34
|
export type ConnectedButtonGroupColor = CoreButtonColor | "elevated";
|
|
35
|
+
/**
|
|
36
|
+
* Union of all valid button color style names across all button components.
|
|
37
|
+
*/
|
|
7
38
|
export type AllButtonColor = ButtonColor | IconButtonColor | SplitButtonColor | ConnectedButtonGroupColor;
|
|
39
|
+
/**
|
|
40
|
+
* Resolves a button color style name to its CSS module class name.
|
|
41
|
+
*
|
|
42
|
+
* @param color - The button color identifier.
|
|
43
|
+
* @returns CSS class name applying the color styling rules.
|
|
44
|
+
*/
|
|
8
45
|
export declare const buttonColorConfig: (color: AllButtonColor) => string;
|
|
46
|
+
/** CSS class providing base color custom properties and transition states. */
|
|
9
47
|
export declare const buttonColorBase: string;
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export { n as ButtonCore, i as ButtonIconSizeMapping, e as ButtonLabelTextMapping, r as ButtonReset, s as ButtonSizeBase, l as IconButtonIconSizeMapping, a as buttonColorBase, d as buttonColorConfig, t as buttonSizeConfig, c as newButtonBaseDataAttrs, o as useButtonConfig, u as withTooltip };
|
|
1
|
+
export { d as ButtonCore, i as ButtonIconSizeMapping, a as ButtonLabelTextMapping, f as ButtonReset, o as ButtonSizeBase, s as IconButtonIconSizeMapping, l as buttonColorBase, u as buttonColorConfig, c as buttonSizeConfig, p as newButtonBaseDataAttrs, n as useButtonConfig, t as withTooltip } from "../../../chunks/core";
|
|
@@ -1 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Supported corner rounding styles for button components.
|
|
3
|
+
*
|
|
4
|
+
* - `"round"`: Full border-radius (pill shape for labeled buttons, circular for icon buttons).
|
|
5
|
+
* - `"square"`: Slightly rounded rectangular corners.
|
|
6
|
+
*/
|
|
1
7
|
export type ButtonShape = "round" | "square";
|
|
@@ -1,6 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Supported size presets for button and button group components.
|
|
3
|
+
* Controls dimensions, typography, icon scale, and internal padding.
|
|
4
|
+
*/
|
|
1
5
|
export type ButtonSize = "extra-small" | "small" | "medium" | "large" | "extra-large";
|
|
6
|
+
/**
|
|
7
|
+
* Maps each {@link ButtonSize} preset to its recommended icon size in pixels
|
|
8
|
+
* for standard labeled buttons (with leading or trailing icons).
|
|
9
|
+
*/
|
|
2
10
|
export declare const ButtonIconSizeMapping: Record<ButtonSize, number>;
|
|
11
|
+
/**
|
|
12
|
+
* Maps each {@link ButtonSize} preset to its recommended icon size in pixels
|
|
13
|
+
* for icon-only buttons (e.g. `IconButton`, `ToggleIconButton`, `LinkIconButton`).
|
|
14
|
+
* Note that the `"small"` preset uses 24px for icon buttons compared to 20px in labeled buttons.
|
|
15
|
+
*/
|
|
3
16
|
export declare const IconButtonIconSizeMapping: Record<ButtonSize, number>;
|
|
17
|
+
/**
|
|
18
|
+
* Maps each {@link ButtonSize} preset to its typography token class name
|
|
19
|
+
* for button label text.
|
|
20
|
+
*/
|
|
4
21
|
export declare const ButtonLabelTextMapping: Record<ButtonSize, string>;
|
|
22
|
+
/**
|
|
23
|
+
* Resolves the CSS module class name for a given button size preset.
|
|
24
|
+
*
|
|
25
|
+
* @param size - The button size preset to retrieve styling for.
|
|
26
|
+
* @returns The CSS module class name corresponding to the specified size.
|
|
27
|
+
*/
|
|
5
28
|
export declare const buttonSizeConfig: (size: ButtonSize) => string;
|
|
29
|
+
/**
|
|
30
|
+
* Base CSS module class name applying common layout and sizing structure across buttons.
|
|
31
|
+
*/
|
|
6
32
|
export declare const ButtonSizeBase: string;
|
|
@@ -1,12 +1,37 @@
|
|
|
1
1
|
import { ButtonIconPlacement } from './button';
|
|
2
2
|
import { ButtonShape } from './shape';
|
|
3
3
|
import { ButtonSize } from './sizes';
|
|
4
|
+
/**
|
|
5
|
+
* Configuration options passed to {@link useButtonConfig} to resolve button styles.
|
|
6
|
+
*/
|
|
4
7
|
type ButtonConfigOptions<C extends string> = {
|
|
8
|
+
/** Explicit button size preset override. */
|
|
5
9
|
size?: ButtonSize;
|
|
10
|
+
/** Explicit button corner shape override. */
|
|
6
11
|
shape?: ButtonShape;
|
|
12
|
+
/** Explicit button color style override. */
|
|
7
13
|
color?: C;
|
|
14
|
+
/** Explicit icon placement override relative to label. */
|
|
8
15
|
iconPlacement?: ButtonIconPlacement;
|
|
9
16
|
};
|
|
17
|
+
/**
|
|
18
|
+
* Resolves button configuration by prioritizing component-level props and falling back
|
|
19
|
+
* to contextual values from an ancestor `ButtonGroupContext` (or system defaults).
|
|
20
|
+
*
|
|
21
|
+
* @template C - String union of allowed color variant values for the button type.
|
|
22
|
+
* @param options - Component-level prop overrides.
|
|
23
|
+
* @returns Resolved visual configuration: `buttonSize`, `buttonShape`, `buttonColor`, and `buttonIconPlacement`.
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* ```tsx
|
|
27
|
+
* const { buttonSize, buttonShape, buttonColor, buttonIconPlacement } = useButtonConfig({
|
|
28
|
+
* size,
|
|
29
|
+
* shape,
|
|
30
|
+
* color,
|
|
31
|
+
* iconPlacement,
|
|
32
|
+
* });
|
|
33
|
+
* ```
|
|
34
|
+
*/
|
|
10
35
|
export declare function useButtonConfig<C extends string>({ size, shape, color, iconPlacement, }: ButtonConfigOptions<C>): {
|
|
11
36
|
buttonSize: ButtonSize;
|
|
12
37
|
buttonShape: ButtonShape;
|
|
@@ -1 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Base button style variant distinguishing standard push buttons from toggle state buttons.
|
|
3
|
+
*
|
|
4
|
+
* - `"default"`: Standard interactive push button styling.
|
|
5
|
+
* - `"toggle"`: Stateful button styling supporting active/pressed selection states.
|
|
6
|
+
*/
|
|
1
7
|
export type ButtonVariant = "default" | "toggle";
|
|
@@ -1 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Width sizing options for icon buttons.
|
|
3
|
+
*
|
|
4
|
+
* - `"narrow"`: Compact width variant for tighter layouts.
|
|
5
|
+
* - `"default"`: Standard square/circular aspect ratio matching button height.
|
|
6
|
+
* - `"wide"`: Expanded horizontal padding for larger tap targets or elongated pill buttons.
|
|
7
|
+
*/
|
|
1
8
|
export type IconButtonWidth = "narrow" | "default" | "wide";
|
|
@@ -1,2 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Conditionally wraps a React node in a tooltip trigger when tooltip text is provided.
|
|
4
|
+
*
|
|
5
|
+
* @param node - The React element to display (e.g. button or icon button).
|
|
6
|
+
* @param tooltip - The optional tooltip text to show on hover/focus. If omitted or empty, `node` is returned unwrapped.
|
|
7
|
+
* @returns The wrapped element with tooltip, or the original node if no tooltip was supplied.
|
|
8
|
+
*/
|
|
9
|
+
export declare const withTooltip: (node: ReactNode, tooltip?: string) => string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import('react').ReactPortal | import('react').ReactElement<unknown, string | import('react').JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import('react').JSX.Element | null | undefined;
|
|
@@ -1,5 +1,26 @@
|
|
|
1
1
|
import { WeekdayStyle } from '../core';
|
|
2
|
-
|
|
2
|
+
/**
|
|
3
|
+
* Props for the {@link BaseCalendar} component.
|
|
4
|
+
*/
|
|
5
|
+
export interface BaseCalendarProps {
|
|
6
|
+
/** Whether the calendar is operating in range selection mode. */
|
|
3
7
|
isRangeCalendar?: boolean;
|
|
8
|
+
/** Formatting style for weekday column headers. */
|
|
4
9
|
weekdayStyle?: WeekdayStyle;
|
|
5
|
-
|
|
10
|
+
/** Accessible label for the previous month button. */
|
|
11
|
+
previousMonthAriaLabel?: string;
|
|
12
|
+
/** Accessible label for the next month button. */
|
|
13
|
+
nextMonthAriaLabel?: string;
|
|
14
|
+
/** Accessible label for the previous year button. */
|
|
15
|
+
previousYearAriaLabel?: string;
|
|
16
|
+
/** Accessible label for the next year button. */
|
|
17
|
+
nextYearAriaLabel?: string;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Core calendar layout and view orchestrator.
|
|
21
|
+
*
|
|
22
|
+
* Manages the calendar header with navigation controls (prev/next month, prev/next year,
|
|
23
|
+
* month/year dropdown buttons), animated transitions between grid, month, and year views,
|
|
24
|
+
* and maintains anchor date state during view changes in range selection mode.
|
|
25
|
+
*/
|
|
26
|
+
export declare const BaseCalendar: React.FC<BaseCalendarProps>;
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export { e as BaseCalendar };
|
|
1
|
+
export { t as BaseCalendar } from "../../../chunks/BaseCalendar";
|
|
@@ -1,5 +1,42 @@
|
|
|
1
1
|
import { Calendar as AriaCalendar } from 'react-aria-components';
|
|
2
2
|
import { WeekdayStyle } from '../core';
|
|
3
|
-
|
|
3
|
+
/**
|
|
4
|
+
* Props for the {@link Calendar} component.
|
|
5
|
+
* Extends React Aria's `Calendar` props (excluding `children`, `visibleDuration`, and `pageBehavior`).
|
|
6
|
+
*/
|
|
7
|
+
export interface CalendarProps extends Omit<React.ComponentPropsWithRef<typeof AriaCalendar>, "children" | "visibleDuration" | "pageBehavior"> {
|
|
8
|
+
/**
|
|
9
|
+
* Formatting style for weekday column headers in the calendar grid.
|
|
10
|
+
*
|
|
11
|
+
* - `"narrow"`: Typically a single character (e.g. "S", "M", "T").
|
|
12
|
+
* - `"short"`: Abbreviated weekday name (e.g. "Sun", "Mon", "Tue").
|
|
13
|
+
*/
|
|
4
14
|
weekdayStyle?: WeekdayStyle;
|
|
5
|
-
|
|
15
|
+
/** Accessible label for the previous month button. */
|
|
16
|
+
previousMonthAriaLabel?: string;
|
|
17
|
+
/** Accessible label for the next month button. */
|
|
18
|
+
nextMonthAriaLabel?: string;
|
|
19
|
+
/** Accessible label for the previous year button. */
|
|
20
|
+
previousYearAriaLabel?: string;
|
|
21
|
+
/** Accessible label for the next year button. */
|
|
22
|
+
nextYearAriaLabel?: string;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* A single date selection calendar component implementing Material Design 3 Date Picker guidelines.
|
|
26
|
+
*
|
|
27
|
+
* Features an interactive date grid, fast month and year selector menus, localized date formatting,
|
|
28
|
+
* keyboard accessibility, and touch-responsive ripple effects. Built on top of React Aria's `Calendar`.
|
|
29
|
+
*
|
|
30
|
+
* @example
|
|
31
|
+
* ```tsx
|
|
32
|
+
* import { Calendar } from '@adgytec/web-ui-components';
|
|
33
|
+
* import { today, getLocalTimeZone } from '@internationalized/date';
|
|
34
|
+
*
|
|
35
|
+
* <Calendar
|
|
36
|
+
* aria-label="Appointment date"
|
|
37
|
+
* minValue={today(getLocalTimeZone())}
|
|
38
|
+
* onChange={(date) => console.log('Selected date:', date)}
|
|
39
|
+
* />
|
|
40
|
+
* ```
|
|
41
|
+
*/
|
|
42
|
+
export declare const Calendar: React.FC<CalendarProps>;
|
|
@@ -4,23 +4,28 @@ import { t as n } from "../../../chunks/BaseCalendar";
|
|
|
4
4
|
import r from "clsx";
|
|
5
5
|
import { jsx as i } from "react/jsx-runtime";
|
|
6
6
|
import { Calendar as a } from "react-aria-components";
|
|
7
|
-
|
|
7
|
+
// src/components/Calendar/Calendar/Calendar.tsx
|
|
8
8
|
var o = e(), s = (e) => {
|
|
9
|
-
let s = (0, o.c)(
|
|
10
|
-
s[0] === e ? (c = s[1], l = s[2], u = s[3]) : ({weekdayStyle:
|
|
11
|
-
let
|
|
12
|
-
s[
|
|
13
|
-
let
|
|
14
|
-
s[
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
9
|
+
let s = (0, o.c)(20), c, l, u, d, f, p, m;
|
|
10
|
+
s[0] === e ? (c = s[1], l = s[2], u = s[3], d = s[4], f = s[5], p = s[6], m = s[7]) : ({weekdayStyle: m, className: c, previousMonthAriaLabel: d, nextMonthAriaLabel: l, previousYearAriaLabel: f, nextYearAriaLabel: u, ...p} = e, s[0] = e, s[1] = c, s[2] = l, s[3] = u, s[4] = d, s[5] = f, s[6] = p, s[7] = m);
|
|
11
|
+
let h;
|
|
12
|
+
s[8] === c ? h = s[9] : (h = (e) => r(t, typeof c == "function" ? c(e) : c), s[8] = c, s[9] = h);
|
|
13
|
+
let g;
|
|
14
|
+
s[10] !== l || s[11] !== u || s[12] !== d || s[13] !== f || s[14] !== m ? (g = /* @__PURE__ */ i(n, {
|
|
15
|
+
weekdayStyle: m,
|
|
16
|
+
previousMonthAriaLabel: d,
|
|
17
|
+
nextMonthAriaLabel: l,
|
|
18
|
+
previousYearAriaLabel: f,
|
|
19
|
+
nextYearAriaLabel: u
|
|
20
|
+
}), s[10] = l, s[11] = u, s[12] = d, s[13] = f, s[14] = m, s[15] = g) : g = s[15];
|
|
21
|
+
let _;
|
|
22
|
+
return s[16] !== p || s[17] !== h || s[18] !== g ? (_ = /* @__PURE__ */ i(a, {
|
|
23
|
+
className: h,
|
|
24
|
+
...p,
|
|
19
25
|
"data-calendar": !0,
|
|
20
|
-
children:
|
|
21
|
-
}), s[
|
|
26
|
+
children: g
|
|
27
|
+
}), s[16] = p, s[17] = h, s[18] = g, s[19] = _) : _ = s[19], _;
|
|
22
28
|
};
|
|
23
|
-
//#endregion
|
|
24
29
|
export { s as Calendar };
|
|
25
30
|
|
|
26
31
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["weekdayStyle"],"sources":["../../../../src/components/Calendar/Calendar/Calendar.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { Calendar as AriaCalendar } from \"react-aria-components\";\nimport { BaseCalendar } from \"../BaseCalendar\";\nimport { CalendarBaseStyles, type WeekdayStyle } from \"../core\";\n\
|
|
1
|
+
{"version":3,"file":"index.js","names":["weekdayStyle","previousMonthAriaLabel","nextMonthAriaLabel","previousYearAriaLabel","nextYearAriaLabel","_c","clsx","AriaCalendar","require_compiler_runtime","CalendarBaseStyles","BaseCalendar","clsx$1","Calendar$1","import_compiler_runtime","Calendar","$","className","nextMonthAriaLabel","nextYearAriaLabel","previousMonthAriaLabel","previousYearAriaLabel","props","weekdayStyle","t0","t1","renderProps","t2","t3"],"sources":["../../../../src/components/Calendar/Calendar/Calendar.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { Calendar as AriaCalendar } from \"react-aria-components\";\nimport { BaseCalendar } from \"../BaseCalendar\";\nimport { CalendarBaseStyles, type WeekdayStyle } from \"../core\";\n\n/**\n * Props for the {@link Calendar} component.\n * Extends React Aria's `Calendar` props (excluding `children`, `visibleDuration`, and `pageBehavior`).\n */\nexport interface CalendarProps\n extends Omit<\n React.ComponentPropsWithRef<typeof AriaCalendar>,\n \"children\" | \"visibleDuration\" | \"pageBehavior\"\n > {\n /**\n * Formatting style for weekday column headers in the calendar grid.\n *\n * - `\"narrow\"`: Typically a single character (e.g. \"S\", \"M\", \"T\").\n * - `\"short\"`: Abbreviated weekday name (e.g. \"Sun\", \"Mon\", \"Tue\").\n */\n weekdayStyle?: WeekdayStyle;\n\n /** Accessible label for the previous month button. */\n previousMonthAriaLabel?: string;\n\n /** Accessible label for the next month button. */\n nextMonthAriaLabel?: string;\n\n /** Accessible label for the previous year button. */\n previousYearAriaLabel?: string;\n\n /** Accessible label for the next year button. */\n nextYearAriaLabel?: string;\n}\n\n/**\n * A single date selection calendar component implementing Material Design 3 Date Picker guidelines.\n *\n * Features an interactive date grid, fast month and year selector menus, localized date formatting,\n * keyboard accessibility, and touch-responsive ripple effects. Built on top of React Aria's `Calendar`.\n *\n * @example\n * ```tsx\n * import { Calendar } from '@adgytec/web-ui-components';\n * import { today, getLocalTimeZone } from '@internationalized/date';\n *\n * <Calendar\n * aria-label=\"Appointment date\"\n * minValue={today(getLocalTimeZone())}\n * onChange={(date) => console.log('Selected date:', date)}\n * />\n * ```\n */\nexport const Calendar: React.FC<CalendarProps> = ({\n weekdayStyle,\n className,\n previousMonthAriaLabel,\n nextMonthAriaLabel,\n previousYearAriaLabel,\n nextYearAriaLabel,\n ...props\n}) => {\n return (\n <AriaCalendar\n className={(renderProps) =>\n clsx(\n CalendarBaseStyles,\n typeof className === \"function\"\n ? className(renderProps)\n : className\n )\n }\n {...props}\n data-calendar\n >\n <BaseCalendar\n weekdayStyle={weekdayStyle}\n previousMonthAriaLabel={previousMonthAriaLabel}\n nextMonthAriaLabel={nextMonthAriaLabel}\n previousYearAriaLabel={previousYearAriaLabel}\n nextYearAriaLabel={nextYearAriaLabel}\n />\n </AriaCalendar>\n );\n};\n"],"mappings":";;;;;;;A,aAqDac,KAAoC,MAAA;CAAA,IAAAC,KAAA,GAAAV,EAAAA,EAAAA,CAAA,EAAA,GAAAW,GAAAC,GAAAC,GAAAC,GAAAC,GAAAC,GAAAC;CAAA,AAAAP,EAAA,OAAAQ,KAQhD,IAAAR,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,IAAA,IAAAA,EAAA,OARiD,kIAAA,GAAAM,KAAAE,GAQjD,EAAA,KAAAA,GAAA,EAAA,KAAAP,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC,GAAA,EAAA,KAAAC;CAAA,IAAAE;CAAA,AAAAT,EAAA,OAAAC,IASgB,IAAAD,EAAA,MANM,KAAA,MACPT,EACIG,GACA,OAAOO,KAAc,aACfA,EAAUS,CACF,IAFdT,CAGJ,GAAC,EAAA,KAAAA,GAAA,EAAA,KAAAQ;CAAA,IAAAE;CAAA,AAAAX,EAAA,QAAAE,KAAAF,EAAA,QAAAG,KAAAH,EAAA,QAAAI,KAAAJ,EAAA,QAAAK,KAAAL,EAAA,QAAAO,KAKL,IAAA,kBAACZ,GAAD;EACkB;EACU;EACJ;EACG;EACJ;CAAiB,CAAA,GACtC,EAAA,MAAAO,GAAA,EAAA,MAAAC,GAAA,EAAA,MAAAC,GAAA,EAAA,MAAAC,GAAA,EAAA,MAAAE,GAAA,EAAA,MAAAI,KAAA,IAAAX,EAAA;CAAA,IAAAY;CACS,OADTZ,EAAA,QAAAM,KAAAN,EAAA,QAAAS,KAAAT,EAAA,QAAAW,KAlBN,IAAA,kBAACnB,GAAD;EACe,WAAAiB;EAMN,GAEDH;EACJ,iBAAA;EAEA,UAAAK;CAZS,CAAA,GAmBE,EAAA,MAAAL,GAAA,EAAA,MAAAG,GAAA,EAAA,MAAAE,GAAA,EAAA,MAAAC,KAAA,IAAAZ,EAAA,KAnBfY;AAmBe"}
|
|
@@ -1,4 +1,16 @@
|
|
|
1
1
|
import { CalendarCell as AriaCalendarCell } from 'react-aria-components';
|
|
2
|
-
|
|
2
|
+
/**
|
|
3
|
+
* Props for the {@link CalendarCell} component.
|
|
4
|
+
* Extends React Aria's `CalendarCell` props (excluding `children`).
|
|
5
|
+
*/
|
|
6
|
+
export interface CalendarCellProps extends Omit<React.ComponentPropsWithRef<typeof AriaCalendarCell>, "children"> {
|
|
7
|
+
/** Whether the cell is being rendered within a range calendar. */
|
|
3
8
|
isRangeCalendar?: boolean;
|
|
4
|
-
}
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* An individual date cell within the calendar grid.
|
|
12
|
+
*
|
|
13
|
+
* Handles day number rendering, selection indicators, range highlight backgrounds
|
|
14
|
+
* (selection start, in-between range, selection end), and disabled and outside-month styling.
|
|
15
|
+
*/
|
|
16
|
+
export declare const CalendarCell: React.FC<CalendarCellProps>;
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export { e as CalendarCell };
|
|
1
|
+
export { t as CalendarCell } from "../../../chunks/CalendarCell";
|
|
@@ -1,4 +1,14 @@
|
|
|
1
1
|
import { CalendarGrid as AriaCalendarGrid } from 'react-aria-components';
|
|
2
|
-
|
|
2
|
+
/**
|
|
3
|
+
* Props for the {@link CalendarGrid} component.
|
|
4
|
+
* Extends React Aria's `CalendarGrid` props (excluding `children` and `className`).
|
|
5
|
+
*/
|
|
6
|
+
export interface CalendarGridProps extends Omit<React.ComponentPropsWithRef<typeof AriaCalendarGrid>, "children" | "className"> {
|
|
7
|
+
/** Whether the calendar is operating in range selection mode. */
|
|
3
8
|
isRangeCalendar?: boolean;
|
|
4
|
-
}
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Renders the 7-column calendar date grid, including weekday column headers
|
|
12
|
+
* and day date cells.
|
|
13
|
+
*/
|
|
14
|
+
export declare const CalendarGrid: React.FC<CalendarGridProps>;
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export { e as CalendarGrid };
|
|
1
|
+
export { t as CalendarGrid } from "../../../chunks/CalendarGrid";
|
|
@@ -1,2 +1,13 @@
|
|
|
1
1
|
import { ListBoxItem } from 'react-aria-components';
|
|
2
|
-
|
|
2
|
+
/**
|
|
3
|
+
* Props for the {@link CalendarMenuItem} component.
|
|
4
|
+
* Extends React Aria's {@link ListBoxItem} props.
|
|
5
|
+
*/
|
|
6
|
+
export interface CalendarMenuItemProps extends React.ComponentPropsWithRef<typeof ListBoxItem> {
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* An individual selectable item within the calendar month and year picker menus.
|
|
10
|
+
*
|
|
11
|
+
* Implements Material Design 3 selection styles, focus outlines, and typography.
|
|
12
|
+
*/
|
|
13
|
+
export declare const CalendarMenuItem: React.FC<CalendarMenuItemProps>;
|