@algolia/satellite 1.0.0-beta.164 → 1.0.0-beta.165
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/cjs/AnnouncementBadge/AnnouncementBadge.d.ts +3 -3
- package/cjs/AnnouncementBadge/AnnouncementBadge.js +4 -6
- package/cjs/AnnouncementBadge/index.js +2 -2
- package/cjs/AutoComplete/AutoComplete.d.ts +3 -49
- package/cjs/AutoComplete/AutoComplete.js +347 -516
- package/cjs/AutoComplete/AutoComplete.tailwind.d.ts +1 -1
- package/cjs/AutoComplete/components/AutoCompleteEmptyState.js +2 -4
- package/cjs/AutoComplete/components/AutocompleteContext.d.ts +5 -0
- package/cjs/AutoComplete/components/AutocompleteContext.js +19 -0
- package/cjs/AutoComplete/components/DefaultOptionItem.d.ts +2 -2
- package/cjs/AutoComplete/components/DefaultOptionItem.js +4 -5
- package/cjs/AutoComplete/index.d.ts +1 -0
- package/cjs/AutoComplete/index.js +14 -2
- package/cjs/AutoComplete/types.d.ts +1 -1
- package/cjs/AutoComplete/utils.d.ts +3 -0
- package/cjs/AutoComplete/utils.js +36 -6
- package/cjs/Avatars/ApplicationAvatar.js +2 -4
- package/cjs/Avatars/UserAvatar.js +4 -6
- package/cjs/Avatars/index.js +2 -2
- package/cjs/Avatars/utils.js +9 -13
- package/cjs/Badge/Badge.d.ts +0 -2
- package/cjs/Badge/Badge.js +4 -6
- package/cjs/Badge/index.js +2 -2
- package/cjs/Banners/Alert/Alert.d.ts +2 -2
- package/cjs/Banners/Alert/Alert.js +2 -4
- package/cjs/Banners/Alert/index.js +2 -2
- package/cjs/Banners/BigBertha/BigBertha.js +2 -4
- package/cjs/Banners/BigBertha/index.js +2 -2
- package/cjs/Banners/Promote/Promote.d.ts +0 -6
- package/cjs/Banners/Promote/Promote.js +2 -10
- package/cjs/Banners/Promote/index.js +2 -2
- package/cjs/Button/Button.js +4 -6
- package/cjs/Button/Button.tailwind.d.ts +1 -1
- package/cjs/Button/Button.tailwind.js +1 -1
- package/cjs/Button/ButtonGroup.d.ts +1 -1
- package/cjs/Button/ButtonGroup.js +2 -4
- package/cjs/Button/IconButton.d.ts +5 -0
- package/cjs/Button/IconButton.js +9 -6
- package/cjs/Button/PolymorphicButton.js +5 -6
- package/cjs/Button/PolymorphicIconButton.d.ts +5 -1
- package/cjs/Button/PolymorphicIconButton.js +12 -12
- package/cjs/Button/index.js +2 -2
- package/cjs/Button/styles.d.ts +1 -1
- package/cjs/Button/styles.js +8 -9
- package/cjs/Button/types.d.ts +3 -2
- package/cjs/Card/Card.d.ts +1 -1
- package/cjs/Card/Card.js +4 -6
- package/cjs/Card/Card.tailwind.d.ts +1 -1
- package/cjs/Card/components/CardHeader.js +4 -6
- package/cjs/Card/components/CardTitle.js +4 -6
- package/cjs/Card/index.js +2 -2
- package/cjs/Checkbox/Checkbox.d.ts +3 -3
- package/cjs/Checkbox/Checkbox.js +6 -8
- package/cjs/Checkbox/Checkbox.tailwind.d.ts +1 -1
- package/cjs/Checkbox/Checkbox.tailwind.js +5 -0
- package/cjs/Checkbox/index.js +2 -2
- package/cjs/ClickAwayContainer/ClickAwayContainer.js +5 -9
- package/cjs/DatePicker/DatePicker/DatePicker.d.ts +1 -1
- package/cjs/DatePicker/DatePicker/DatePicker.js +11 -12
- package/cjs/DatePicker/DatePicker/datePickerReducer.js +8 -11
- package/cjs/DatePicker/DatePicker/index.js +2 -2
- package/cjs/DatePicker/DatePicker.tailwind.d.ts +1 -1
- package/cjs/DatePicker/DateRangePicker/DateRangePicker.js +5 -7
- package/cjs/DatePicker/DateRangePicker/DateRangePickerDisplay.js +1 -2
- package/cjs/DatePicker/DateRangePicker/dateRangePickerReducer.js +8 -11
- package/cjs/DatePicker/DateRangePicker/dateRangePickerTimeRange.js +4 -7
- package/cjs/DatePicker/DateRangePicker/index.js +2 -2
- package/cjs/DatePicker/components/Calendar.js +3 -4
- package/cjs/DatePicker/components/Display.js +1 -2
- package/cjs/DatePicker/components/Footer.js +1 -2
- package/cjs/DatePicker/components/FooterActions.js +1 -2
- package/cjs/DatePicker/components/Modal.js +4 -6
- package/cjs/DatePicker/components/NavBar.js +3 -4
- package/cjs/DatePicker/components/SidePanel.js +1 -2
- package/cjs/DatePicker/index.d.ts +0 -1
- package/cjs/DatePicker/index.js +2 -17
- package/cjs/DatePicker/utils.js +3 -5
- package/cjs/Dropdown/Dropdown.js +5 -8
- package/cjs/Dropdown/DropdownButton.js +4 -6
- package/cjs/Dropdown/DropdownContext.js +3 -6
- package/cjs/Dropdown/components/DropdownButtonItem.d.ts +1 -1
- package/cjs/Dropdown/components/DropdownButtonItem.js +4 -6
- package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItem.js +3 -5
- package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroup.js +2 -3
- package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroupContext.js +3 -5
- package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsMultiGroup.js +2 -3
- package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsSingleGroup.js +2 -3
- package/cjs/Dropdown/components/DropdownDivider.js +2 -4
- package/cjs/Dropdown/components/DropdownFooterItem.d.ts +1 -0
- package/cjs/Dropdown/components/DropdownFooterItem.js +4 -6
- package/cjs/Dropdown/components/DropdownLinkItem.js +4 -6
- package/cjs/Dropdown/components/DropdownRadioItem.js +4 -6
- package/cjs/Dropdown/components/DropdownTitle.js +4 -6
- package/cjs/Dropdown/components/DropdownToggleItem.js +4 -6
- package/cjs/Dropdown/index.js +2 -2
- package/cjs/Dropdown/useDropdownItemProps.js +4 -6
- package/cjs/Dropzone/Dropzone.js +6 -8
- package/cjs/Dropzone/index.js +2 -2
- package/cjs/EmptyState/EmptyState.js +26 -28
- package/cjs/EmptyState/EmptyState.tailwind.d.ts +1 -1
- package/cjs/EmptyState/index.js +2 -2
- package/cjs/EmptyState/types.d.ts +8 -23
- package/cjs/Field/Field.d.ts +0 -1
- package/cjs/Field/Field.js +4 -6
- package/cjs/Field/FieldStateContext.js +3 -6
- package/cjs/Field/index.js +2 -2
- package/cjs/Field/useFieldState.js +4 -6
- package/cjs/Flag/Flag.js +5 -7
- package/cjs/Flag/Flag.tailwind.d.ts +1 -1
- package/cjs/Flag/Flags.js +8 -9
- package/cjs/Flag/index.js +2 -2
- package/cjs/FlexGrid/FlexGrid.d.ts +1 -12
- package/cjs/FlexGrid/FlexGrid.js +2 -4
- package/cjs/FlexGrid/FlexGrid.tailwind.d.ts +1 -1
- package/cjs/FlexGrid/FlexGrid.tailwind.js +2 -2
- package/cjs/FlexGrid/index.js +2 -2
- package/cjs/HelpUnderline/HelpUnderline.js +4 -6
- package/cjs/HelpUnderline/HelpUnderline.tailwind.d.ts +1 -1
- package/cjs/HelpUnderline/index.js +2 -2
- package/cjs/Input/Input.d.ts +4 -1
- package/cjs/Input/Input.js +8 -10
- package/cjs/Input/Input.tailwind.d.ts +1 -1
- package/cjs/Input/index.js +2 -2
- package/cjs/Insert/Insert.js +2 -4
- package/cjs/Insert/index.js +2 -2
- package/cjs/InstantSearch/InstantSearch.tailwind.d.ts +1 -1
- package/cjs/KeyboardKey/KeyboardKey.js +2 -3
- package/cjs/KeyboardKey/KeyboardKey.tailwind.d.ts +1 -1
- package/cjs/Link/BaseLink.js +4 -6
- package/cjs/Link/ButtonLink.js +4 -6
- package/cjs/Link/IconButtonLink.js +4 -6
- package/cjs/Link/Link.d.ts +2 -2
- package/cjs/Link/Link.js +4 -6
- package/cjs/Link/index.js +2 -2
- package/cjs/Medallion/Medallion.d.ts +1 -0
- package/cjs/Medallion/Medallion.js +2 -4
- package/cjs/Medallion/Medallion.tailwind.d.ts +1 -1
- package/cjs/Medallion/index.js +2 -2
- package/cjs/Modal/Modal.js +12 -13
- package/cjs/Modal/Modal.tailwind.d.ts +1 -1
- package/cjs/Modal/components/ModalFooter.js +4 -6
- package/cjs/Modal/components/ModalSection.js +2 -4
- package/cjs/Modal/index.js +2 -2
- package/cjs/Pagination/CompactPagination/CompactPagination.js +6 -10
- package/cjs/Pagination/CompactPagination/index.js +2 -2
- package/cjs/Pagination/DotPagination/DotPagination.js +5 -7
- package/cjs/Pagination/DotPagination/index.js +2 -2
- package/cjs/Pagination/Pagination/Pagination.js +6 -8
- package/cjs/Pagination/Pagination/index.js +2 -2
- package/cjs/Pagination/index.js +2 -2
- package/cjs/Popover/Popover.d.ts +5 -0
- package/cjs/Popover/Popover.js +137 -0
- package/cjs/Popover/index.d.ts +3 -0
- package/cjs/Popover/index.js +36 -0
- package/cjs/Popover/types.d.ts +74 -0
- package/cjs/Popover/types.js +5 -0
- package/cjs/ProgressBar/ProgressBar.js +6 -7
- package/cjs/ProgressBar/ProgressBar.tailwind.d.ts +1 -1
- package/cjs/ProgressBar/index.js +2 -2
- package/cjs/ProgressSpinner/ProgressSpinner.js +4 -6
- package/cjs/ProgressSpinner/ProgressSpinner.tailwind.d.ts +1 -1
- package/cjs/ProgressSpinner/ProgressSpinner.tailwind.js +8 -0
- package/cjs/ProgressSpinner/index.js +2 -2
- package/cjs/RadioGroup/RadioButton.d.ts +1 -1
- package/cjs/RadioGroup/RadioButton.js +4 -6
- package/cjs/RadioGroup/RadioButton.tailwind.d.ts +1 -1
- package/cjs/RadioGroup/RadioButton.tailwind.js +3 -0
- package/cjs/RadioGroup/RadioGroup.d.ts +1 -0
- package/cjs/RadioGroup/RadioGroup.js +3 -6
- package/cjs/RadioGroup/RadiogroupContext.d.ts +1 -4
- package/cjs/RadioGroup/RadiogroupContext.js +3 -5
- package/cjs/RadioGroup/index.js +2 -2
- package/cjs/RangeSlider/RangeSlider.d.ts +2 -0
- package/cjs/RangeSlider/RangeSlider.js +4 -6
- package/cjs/RangeSlider/index.js +2 -2
- package/cjs/Satellite/Satellite.js +5 -7
- package/cjs/Satellite/SatelliteContext.js +5 -8
- package/cjs/Satellite/SatelliteRouter.js +2 -4
- package/cjs/Satellite/index.js +2 -2
- package/cjs/Satellite/locale.d.ts +2 -0
- package/cjs/Satellite/locale.js +2 -3
- package/cjs/Satellite/useCreatePortal.js +2 -3
- package/cjs/ScrollIndicator/ScrollIndicator.js +2 -4
- package/cjs/ScrollIndicator/ScrollIndicator.tailwind.d.ts +1 -1
- package/cjs/ScrollIndicator/index.js +2 -2
- package/cjs/Select/Select.js +4 -6
- package/cjs/Select/Select.tailwind.d.ts +1 -1
- package/cjs/Select/index.js +2 -2
- package/cjs/Separator/Separator.d.ts +1 -0
- package/cjs/Separator/Separator.js +21 -11
- package/cjs/Separator/Separator.tailwind.d.ts +1 -1
- package/cjs/Separator/Separator.tailwind.js +31 -2
- package/cjs/Separator/index.js +2 -2
- package/cjs/Sidebar/Sidebar.d.ts +1 -0
- package/cjs/Sidebar/Sidebar.js +4 -5
- package/cjs/Sidebar/SidebarButtonLink.js +4 -5
- package/cjs/Sidebar/SidebarContext.js +3 -5
- package/cjs/Sidebar/SidebarHeader.d.ts +1 -0
- package/cjs/Sidebar/SidebarHeader.js +2 -3
- package/cjs/Sidebar/SidebarHeading.d.ts +1 -0
- package/cjs/Sidebar/SidebarHeading.js +2 -3
- package/cjs/Sidebar/SidebarLink.js +4 -5
- package/cjs/Sidebar/SidebarLinksGroup/ActiveLinkIndicator.d.ts +1 -0
- package/cjs/Sidebar/SidebarLinksGroup/ActiveLinkIndicator.js +3 -4
- package/cjs/Sidebar/SidebarLinksGroup/SidebarGroupLink.js +4 -5
- package/cjs/Sidebar/SidebarLinksGroup/SidebarLinksGroup.d.ts +1 -0
- package/cjs/Sidebar/SidebarLinksGroup/SidebarLinksGroup.js +6 -7
- package/cjs/Sidebar/SidebarNav.d.ts +1 -0
- package/cjs/Sidebar/SidebarNav.js +2 -3
- package/cjs/Switch/Switch.d.ts +1 -0
- package/cjs/Switch/Switch.js +5 -5
- package/cjs/Switch/Switch.tailwind.d.ts +1 -1
- package/cjs/Switch/SwitchOption.js +5 -7
- package/cjs/Switch/index.js +2 -2
- package/cjs/Switch/utils.js +5 -9
- package/cjs/Tables/DataTable/DataTable.d.ts +8 -1
- package/cjs/Tables/DataTable/DataTable.js +6 -8
- package/cjs/Tables/DataTable/DataTable.tailwind.d.ts +1 -1
- package/cjs/Tables/DataTable/components/Body.js +4 -6
- package/cjs/Tables/DataTable/components/Footer.js +6 -8
- package/cjs/Tables/DataTable/components/Header.js +2 -4
- package/cjs/Tables/DataTable/components/HeaderCell.js +6 -8
- package/cjs/Tables/DataTable/components/Loader.d.ts +1 -0
- package/cjs/Tables/DataTable/components/Loader.js +3 -5
- package/cjs/Tables/DataTable/index.js +2 -2
- package/cjs/Tables/DataTable/types.d.ts +14 -0
- package/cjs/Tables/DataTable/utils.js +4 -7
- package/cjs/Tables/Table/Table.js +4 -6
- package/cjs/Tables/Table/Table.tailwind.d.ts +1 -1
- package/cjs/Tables/Table/components/TableFooter.js +2 -4
- package/cjs/Tables/Table/index.js +2 -2
- package/cjs/Tables/index.js +2 -2
- package/cjs/Tabs/ContentTabs.js +2 -4
- package/cjs/Tabs/LinkTabs.js +3 -6
- package/cjs/Tabs/Tabs.tailwind.d.ts +1 -1
- package/cjs/Tabs/Tabs.tailwind.js +20 -1
- package/cjs/Tabs/components/LinkTab.js +12 -14
- package/cjs/Tabs/index.js +2 -2
- package/cjs/Tabs/types.d.ts +0 -1
- package/cjs/Tabs/utils.js +2 -3
- package/cjs/Tag/Tag.d.ts +7 -17
- package/cjs/Tag/Tag.js +16 -12
- package/cjs/Tag/Tag.tailwind.d.ts +1 -1
- package/cjs/Tag/index.js +2 -2
- package/cjs/TextArea/TextArea.js +4 -6
- package/cjs/TextArea/TextArea.tailwind.d.ts +1 -1
- package/cjs/TextArea/index.js +2 -2
- package/cjs/TextWrap/TextWrap.js +4 -6
- package/cjs/TextWrap/index.js +2 -2
- package/cjs/Toggle/Toggle.d.ts +6 -2
- package/cjs/Toggle/Toggle.js +26 -13
- package/cjs/Toggle/Toggle.tailwind.d.ts +1 -1
- package/cjs/Toggle/Toggle.tailwind.js +18 -6
- package/cjs/Toggle/index.js +2 -2
- package/cjs/Tooltip/OverflowTooltipWrapper.js +4 -5
- package/cjs/Tooltip/Tooltip.d.ts +1 -1
- package/cjs/Tooltip/Tooltip.js +4 -6
- package/cjs/Tooltip/Tooltip.tailwind.d.ts +1 -1
- package/cjs/Tooltip/Tooltip.tailwind.js +1 -91
- package/cjs/Tooltip/TooltipWrapper.d.ts +2 -2
- package/cjs/Tooltip/TooltipWrapper.js +7 -8
- package/cjs/Tooltip/index.js +2 -2
- package/cjs/Tooltip/types.d.ts +15 -15
- package/cjs/Tooltip/utils.js +2 -3
- package/cjs/Typography/Typography.tailwind.d.ts +1 -1
- package/cjs/Typography/Typography.tailwind.js +2 -2
- package/cjs/UserContent/UserContent.d.ts +1 -0
- package/cjs/UserContent/UserContent.js +2 -4
- package/cjs/UserContent/UserContent.tailwind.d.ts +1 -1
- package/cjs/UserContent/UserContent.tailwind.js +2 -2
- package/cjs/styles/base.tailwind.d.ts +1 -1
- package/cjs/styles/helpers/makePurgeCssExtractor.js +1 -1
- package/cjs/styles/tailwind.config.js +3 -3
- package/cjs/styles/zIndexes.d.ts +1 -0
- package/cjs/styles/zIndexes.js +4 -3
- package/cjs/types.d.ts +2 -3
- package/cjs/utilities/overlay.tailwind.d.ts +5 -0
- package/cjs/utilities/overlay.tailwind.js +107 -0
- package/cjs/utilities/utilities.tailwind.d.ts +1 -1
- package/cjs/utils/genericChangeHandler.js +1 -2
- package/cjs/utils/hashCode.js +2 -4
- package/cjs/utils/isCssPropertySupported.d.ts +1 -1
- package/cjs/utils/isCssPropertySupported.js +1 -2
- package/cjs/utils/isNil.js +2 -4
- package/cjs/utils/isReactText.js +2 -3
- package/cjs/utils/isRenderedChild.js +1 -2
- package/cjs/utils/matchLocation.js +1 -2
- package/cjs/utils/onlyText.js +1 -2
- package/cjs/utils/parseUrl.js +2 -4
- package/cjs/utils/pluralize.js +1 -2
- package/cjs/utils/prefersReducedMotion.d.ts +6 -0
- package/cjs/utils/prefersReducedMotion.js +12 -0
- package/cjs/utils/range.js +1 -2
- package/cjs/utils/toSentenceCase.js +2 -4
- package/cjs/utils/uniqBy.js +1 -2
- package/cjs/utils/uniqueId.js +1 -2
- package/cjs/utils/useForwardedRef.js +1 -2
- package/cjs/utils/useLinkProps.js +2 -4
- package/cjs/utils/useTriggerInputChange.js +1 -2
- package/esm/AnnouncementBadge/AnnouncementBadge.d.ts +3 -3
- package/esm/AnnouncementBadge/AnnouncementBadge.js +2 -2
- package/esm/AutoComplete/AutoComplete.d.ts +3 -49
- package/esm/AutoComplete/AutoComplete.js +350 -517
- package/esm/AutoComplete/AutoComplete.tailwind.d.ts +1 -1
- package/esm/AutoComplete/components/AutocompleteContext.d.ts +5 -0
- package/esm/AutoComplete/components/AutocompleteContext.js +13 -0
- package/esm/AutoComplete/components/DefaultOptionItem.d.ts +2 -2
- package/esm/AutoComplete/components/DefaultOptionItem.js +2 -2
- package/esm/AutoComplete/index.d.ts +1 -0
- package/esm/AutoComplete/index.js +1 -0
- package/esm/AutoComplete/types.d.ts +1 -1
- package/esm/AutoComplete/utils.d.ts +3 -0
- package/esm/AutoComplete/utils.js +31 -1
- package/esm/Avatars/UserAvatar.js +2 -2
- package/esm/Avatars/utils.js +2 -2
- package/esm/Badge/Badge.d.ts +0 -2
- package/esm/Badge/Badge.js +2 -2
- package/esm/Banners/Alert/Alert.d.ts +2 -2
- package/esm/Banners/Promote/Promote.d.ts +0 -6
- package/esm/Banners/Promote/Promote.js +0 -6
- package/esm/Button/Button.js +2 -2
- package/esm/Button/Button.tailwind.d.ts +1 -1
- package/esm/Button/Button.tailwind.js +1 -1
- package/esm/Button/ButtonGroup.d.ts +1 -1
- package/esm/Button/IconButton.d.ts +5 -0
- package/esm/Button/IconButton.js +7 -2
- package/esm/Button/PolymorphicButton.js +2 -2
- package/esm/Button/PolymorphicIconButton.d.ts +5 -1
- package/esm/Button/PolymorphicIconButton.js +11 -10
- package/esm/Button/styles.d.ts +1 -1
- package/esm/Button/styles.js +3 -0
- package/esm/Button/types.d.ts +3 -2
- package/esm/Card/Card.d.ts +1 -1
- package/esm/Card/Card.js +2 -2
- package/esm/Card/Card.tailwind.d.ts +1 -1
- package/esm/Card/components/CardHeader.js +2 -2
- package/esm/Card/components/CardTitle.js +2 -2
- package/esm/Checkbox/Checkbox.d.ts +3 -3
- package/esm/Checkbox/Checkbox.js +4 -4
- package/esm/Checkbox/Checkbox.tailwind.d.ts +1 -1
- package/esm/Checkbox/Checkbox.tailwind.js +5 -0
- package/esm/ClickAwayContainer/ClickAwayContainer.js +1 -1
- package/esm/DatePicker/DatePicker/DatePicker.d.ts +1 -1
- package/esm/DatePicker/DatePicker/DatePicker.js +9 -9
- package/esm/DatePicker/DatePicker/datePickerReducer.js +5 -5
- package/esm/DatePicker/DatePicker.tailwind.d.ts +1 -1
- package/esm/DatePicker/DateRangePicker/DateRangePicker.js +3 -3
- package/esm/DatePicker/DateRangePicker/dateRangePickerReducer.js +5 -5
- package/esm/DatePicker/components/Calendar.js +2 -2
- package/esm/DatePicker/components/Modal.js +2 -2
- package/esm/DatePicker/components/NavBar.js +2 -2
- package/esm/DatePicker/index.d.ts +0 -1
- package/esm/DatePicker/index.js +0 -1
- package/esm/Dropdown/Dropdown.js +2 -2
- package/esm/Dropdown/DropdownButton.js +2 -2
- package/esm/Dropdown/components/DropdownButtonItem.d.ts +1 -1
- package/esm/Dropdown/components/DropdownButtonItem.js +2 -2
- package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItem.js +1 -1
- package/esm/Dropdown/components/DropdownFooterItem.d.ts +1 -0
- package/esm/Dropdown/components/DropdownFooterItem.js +2 -2
- package/esm/Dropdown/components/DropdownLinkItem.js +2 -2
- package/esm/Dropdown/components/DropdownRadioItem.js +2 -2
- package/esm/Dropdown/components/DropdownTitle.js +2 -2
- package/esm/Dropdown/components/DropdownToggleItem.js +2 -2
- package/esm/Dropdown/useDropdownItemProps.js +2 -2
- package/esm/Dropzone/Dropzone.js +4 -4
- package/esm/EmptyState/EmptyState.js +24 -24
- package/esm/EmptyState/EmptyState.tailwind.d.ts +1 -1
- package/esm/EmptyState/types.d.ts +8 -23
- package/esm/Field/Field.d.ts +0 -1
- package/esm/Flag/Flag.js +3 -3
- package/esm/Flag/Flag.tailwind.d.ts +1 -1
- package/esm/Flag/Flags.js +6 -5
- package/esm/FlexGrid/FlexGrid.d.ts +1 -12
- package/esm/FlexGrid/FlexGrid.tailwind.d.ts +1 -1
- package/esm/FlexGrid/FlexGrid.tailwind.js +2 -2
- package/esm/HelpUnderline/HelpUnderline.js +2 -2
- package/esm/HelpUnderline/HelpUnderline.tailwind.d.ts +1 -1
- package/esm/Input/Input.d.ts +4 -1
- package/esm/Input/Input.js +6 -6
- package/esm/Input/Input.tailwind.d.ts +1 -1
- package/esm/InstantSearch/InstantSearch.tailwind.d.ts +1 -1
- package/esm/KeyboardKey/KeyboardKey.tailwind.d.ts +1 -1
- package/esm/Link/BaseLink.js +2 -2
- package/esm/Link/ButtonLink.js +2 -2
- package/esm/Link/IconButtonLink.js +2 -2
- package/esm/Link/Link.d.ts +2 -2
- package/esm/Link/Link.js +2 -2
- package/esm/Medallion/Medallion.d.ts +1 -0
- package/esm/Medallion/Medallion.tailwind.d.ts +1 -1
- package/esm/Modal/Modal.js +8 -7
- package/esm/Modal/Modal.tailwind.d.ts +1 -1
- package/esm/Modal/components/ModalFooter.js +2 -2
- package/esm/Pagination/CompactPagination/CompactPagination.js +2 -2
- package/esm/Pagination/DotPagination/DotPagination.js +3 -3
- package/esm/Pagination/Pagination/Pagination.js +2 -2
- package/esm/Popover/Popover.d.ts +5 -0
- package/esm/Popover/Popover.js +129 -0
- package/esm/Popover/index.d.ts +3 -0
- package/esm/Popover/index.js +3 -0
- package/esm/Popover/types.d.ts +74 -0
- package/esm/Popover/types.js +1 -0
- package/esm/ProgressBar/ProgressBar.js +4 -3
- package/esm/ProgressBar/ProgressBar.tailwind.d.ts +1 -1
- package/esm/ProgressSpinner/ProgressSpinner.js +2 -2
- package/esm/ProgressSpinner/ProgressSpinner.tailwind.d.ts +1 -1
- package/esm/ProgressSpinner/ProgressSpinner.tailwind.js +8 -0
- package/esm/RadioGroup/RadioButton.d.ts +1 -1
- package/esm/RadioGroup/RadioButton.js +2 -2
- package/esm/RadioGroup/RadioButton.tailwind.d.ts +1 -1
- package/esm/RadioGroup/RadioButton.tailwind.js +3 -0
- package/esm/RadioGroup/RadioGroup.d.ts +1 -0
- package/esm/RadioGroup/RadiogroupContext.d.ts +1 -4
- package/esm/RangeSlider/RangeSlider.d.ts +2 -0
- package/esm/RangeSlider/RangeSlider.js +2 -2
- package/esm/Satellite/Satellite.js +4 -4
- package/esm/Satellite/SatelliteContext.js +2 -2
- package/esm/Satellite/locale.d.ts +2 -0
- package/esm/ScrollIndicator/ScrollIndicator.tailwind.d.ts +1 -1
- package/esm/Select/Select.js +2 -2
- package/esm/Select/Select.tailwind.d.ts +1 -1
- package/esm/Separator/Separator.d.ts +1 -0
- package/esm/Separator/Separator.js +17 -5
- package/esm/Separator/Separator.tailwind.d.ts +1 -1
- package/esm/Separator/Separator.tailwind.js +31 -2
- package/esm/Sidebar/Sidebar.d.ts +1 -0
- package/esm/Sidebar/Sidebar.js +2 -2
- package/esm/Sidebar/SidebarButtonLink.js +2 -2
- package/esm/Sidebar/SidebarHeader.d.ts +1 -0
- package/esm/Sidebar/SidebarHeading.d.ts +1 -0
- package/esm/Sidebar/SidebarLink.js +2 -2
- package/esm/Sidebar/SidebarLinksGroup/ActiveLinkIndicator.d.ts +1 -0
- package/esm/Sidebar/SidebarLinksGroup/ActiveLinkIndicator.js +1 -1
- package/esm/Sidebar/SidebarLinksGroup/SidebarGroupLink.js +2 -2
- package/esm/Sidebar/SidebarLinksGroup/SidebarLinksGroup.d.ts +1 -0
- package/esm/Sidebar/SidebarLinksGroup/SidebarLinksGroup.js +4 -4
- package/esm/Sidebar/SidebarNav.d.ts +1 -0
- package/esm/Switch/Switch.d.ts +1 -0
- package/esm/Switch/Switch.js +3 -1
- package/esm/Switch/Switch.tailwind.d.ts +1 -1
- package/esm/Switch/SwitchOption.js +3 -3
- package/esm/Tables/DataTable/DataTable.d.ts +8 -1
- package/esm/Tables/DataTable/DataTable.js +4 -4
- package/esm/Tables/DataTable/DataTable.tailwind.d.ts +1 -1
- package/esm/Tables/DataTable/components/Body.js +2 -2
- package/esm/Tables/DataTable/components/Footer.js +2 -2
- package/esm/Tables/DataTable/components/HeaderCell.js +4 -4
- package/esm/Tables/DataTable/components/Loader.d.ts +1 -0
- package/esm/Tables/DataTable/components/Loader.js +1 -1
- package/esm/Tables/DataTable/types.d.ts +14 -0
- package/esm/Tables/Table/Table.js +2 -2
- package/esm/Tables/Table/Table.tailwind.d.ts +1 -1
- package/esm/Tabs/Tabs.tailwind.d.ts +1 -1
- package/esm/Tabs/Tabs.tailwind.js +20 -1
- package/esm/Tabs/components/LinkTab.js +10 -10
- package/esm/Tabs/types.d.ts +0 -1
- package/esm/Tag/Tag.d.ts +7 -17
- package/esm/Tag/Tag.js +14 -8
- package/esm/Tag/Tag.tailwind.d.ts +1 -1
- package/esm/TextArea/TextArea.js +2 -2
- package/esm/TextArea/TextArea.tailwind.d.ts +1 -1
- package/esm/TextWrap/TextWrap.js +2 -2
- package/esm/Toggle/Toggle.d.ts +6 -2
- package/esm/Toggle/Toggle.js +24 -9
- package/esm/Toggle/Toggle.tailwind.d.ts +1 -1
- package/esm/Toggle/Toggle.tailwind.js +18 -6
- package/esm/Tooltip/OverflowTooltipWrapper.js +2 -2
- package/esm/Tooltip/Tooltip.d.ts +1 -1
- package/esm/Tooltip/Tooltip.js +2 -2
- package/esm/Tooltip/Tooltip.tailwind.d.ts +1 -1
- package/esm/Tooltip/Tooltip.tailwind.js +1 -90
- package/esm/Tooltip/TooltipWrapper.d.ts +2 -2
- package/esm/Tooltip/TooltipWrapper.js +3 -3
- package/esm/Tooltip/types.d.ts +15 -15
- package/esm/Typography/Typography.tailwind.d.ts +1 -1
- package/esm/Typography/Typography.tailwind.js +2 -2
- package/esm/UserContent/UserContent.d.ts +1 -0
- package/esm/UserContent/UserContent.tailwind.d.ts +1 -1
- package/esm/UserContent/UserContent.tailwind.js +2 -2
- package/esm/styles/base.tailwind.d.ts +1 -1
- package/esm/styles/helpers/makePurgeCssExtractor.js +1 -1
- package/esm/styles/tailwind.config.js +3 -3
- package/esm/styles/zIndexes.d.ts +1 -0
- package/esm/styles/zIndexes.js +4 -3
- package/esm/types.d.ts +2 -3
- package/esm/utilities/overlay.tailwind.d.ts +5 -0
- package/esm/utilities/overlay.tailwind.js +106 -0
- package/esm/utilities/utilities.tailwind.d.ts +1 -1
- package/esm/utils/isCssPropertySupported.d.ts +1 -1
- package/esm/utils/prefersReducedMotion.d.ts +6 -0
- package/esm/utils/prefersReducedMotion.js +6 -0
- package/package.json +9 -7
- package/satellite.min.css +1 -1
- package/scss/variables.scss +4 -3
@@ -0,0 +1,129 @@
|
|
1
|
+
import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
|
2
|
+
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
3
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
4
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8;
|
5
|
+
var _excluded = ["children", "title", "subtitle", "content", "footer", "open", "onDismiss", "side", "sideOffset", "align", "alignOffset", "noArrow", "avoidCollisions", "autoFocusOnOpenElement", "locale"];
|
6
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
7
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
8
|
+
import * as PopoverPrimitive from "@radix-ui/react-popover";
|
9
|
+
import cx from "clsx";
|
10
|
+
import { useMemo, useRef } from "react";
|
11
|
+
import { Fragment } from "react";
|
12
|
+
import { X } from "react-feather";
|
13
|
+
import { IconButton } from "../Button";
|
14
|
+
import { useCreatePortal, useLocale } from "../Satellite";
|
15
|
+
import stl from "../styles/helpers/satellitePrefixer";
|
16
|
+
import { uniqueId } from "../utils";
|
17
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
18
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
19
|
+
var DEFAULT_POPOVER_LOCALE = {
|
20
|
+
dismissText: "Dismiss"
|
21
|
+
};
|
22
|
+
export var POPOVER_ARROW_TEST_ID = "arrow";
|
23
|
+
export var Popover = function Popover(_ref) {
|
24
|
+
var children = _ref.children,
|
25
|
+
title = _ref.title,
|
26
|
+
subtitle = _ref.subtitle,
|
27
|
+
content = _ref.content,
|
28
|
+
footer = _ref.footer,
|
29
|
+
open = _ref.open,
|
30
|
+
onDismiss = _ref.onDismiss,
|
31
|
+
_ref$side = _ref.side,
|
32
|
+
side = _ref$side === void 0 ? "top" : _ref$side,
|
33
|
+
_ref$sideOffset = _ref.sideOffset,
|
34
|
+
sideOffset = _ref$sideOffset === void 0 ? 0 : _ref$sideOffset,
|
35
|
+
_ref$align = _ref.align,
|
36
|
+
align = _ref$align === void 0 ? "center" : _ref$align,
|
37
|
+
_ref$alignOffset = _ref.alignOffset,
|
38
|
+
alignOffset = _ref$alignOffset === void 0 ? 0 : _ref$alignOffset,
|
39
|
+
_ref$noArrow = _ref.noArrow,
|
40
|
+
noArrow = _ref$noArrow === void 0 ? false : _ref$noArrow,
|
41
|
+
_ref$avoidCollisions = _ref.avoidCollisions,
|
42
|
+
avoidCollisions = _ref$avoidCollisions === void 0 ? true : _ref$avoidCollisions,
|
43
|
+
autoFocusOnOpenElement = _ref.autoFocusOnOpenElement,
|
44
|
+
propsLocale = _ref.locale,
|
45
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
46
|
+
var contextLocale = useLocale("popover");
|
47
|
+
var locale = _objectSpread(_objectSpread(_objectSpread({}, DEFAULT_POPOVER_LOCALE), contextLocale), propsLocale);
|
48
|
+
var titleId = useMemo(function () {
|
49
|
+
return uniqueId("popover-title-");
|
50
|
+
}, []);
|
51
|
+
var isControlled = typeof open !== "undefined";
|
52
|
+
var triggerRef = useRef(null);
|
53
|
+
var createPortal = useCreatePortal();
|
54
|
+
if (children.type === Fragment) {
|
55
|
+
throw new Error("Popover component doesn't accept a Fragment as a child.");
|
56
|
+
}
|
57
|
+
return /*#__PURE__*/_jsxs(PopoverPrimitive.Root, {
|
58
|
+
open: open,
|
59
|
+
onOpenChange: function onOpenChange(open) {
|
60
|
+
if (!open) {
|
61
|
+
onDismiss === null || onDismiss === void 0 || onDismiss();
|
62
|
+
}
|
63
|
+
},
|
64
|
+
children: [/*#__PURE__*/_jsx(PopoverPrimitive.Trigger, {
|
65
|
+
ref: triggerRef,
|
66
|
+
asChild: true,
|
67
|
+
children: children
|
68
|
+
}), createPortal( /*#__PURE__*/_jsxs(PopoverPrimitive.Content, _objectSpread(_objectSpread({}, props), {}, {
|
69
|
+
"aria-labelledby": titleId,
|
70
|
+
className: cx(stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["text-grey-900 bg-white z-popover shadow-z200 min-w-48 max-w-128 rounded typo-display-body animate-slide"]))), props.className),
|
71
|
+
side: side,
|
72
|
+
sideOffset: 8 + sideOffset,
|
73
|
+
align: align,
|
74
|
+
alignOffset: alignOffset,
|
75
|
+
avoidCollisions: avoidCollisions,
|
76
|
+
onOpenAutoFocus: function onOpenAutoFocus(e) {
|
77
|
+
if (autoFocusOnOpenElement === false) {
|
78
|
+
e.preventDefault();
|
79
|
+
} else if (autoFocusOnOpenElement instanceof HTMLElement) {
|
80
|
+
e.preventDefault();
|
81
|
+
autoFocusOnOpenElement.focus();
|
82
|
+
}
|
83
|
+
},
|
84
|
+
onInteractOutside: function onInteractOutside(e) {
|
85
|
+
var _triggerRef$current;
|
86
|
+
if (isControlled && (e.target === triggerRef.current || (_triggerRef$current = triggerRef.current) !== null && _triggerRef$current !== void 0 && _triggerRef$current.contains(e.target))) {
|
87
|
+
e.preventDefault();
|
88
|
+
}
|
89
|
+
},
|
90
|
+
onEscapeKeyDown: function onEscapeKeyDown(e) {
|
91
|
+
if (isControlled) {
|
92
|
+
e.preventDefault();
|
93
|
+
onDismiss === null || onDismiss === void 0 || onDismiss();
|
94
|
+
}
|
95
|
+
},
|
96
|
+
children: [/*#__PURE__*/_jsxs("div", {
|
97
|
+
className: stl(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["relative p-4 flex flex-col gap-2 overflow-auto min-h-20 max-h-[calc(var(--radix-popover-content-available-height)-theme(spacing.4))]"]))),
|
98
|
+
children: [/*#__PURE__*/_jsx("div", {
|
99
|
+
id: titleId,
|
100
|
+
className: stl(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["font-semibold pr-8"]))),
|
101
|
+
children: title
|
102
|
+
}), !!subtitle && /*#__PURE__*/_jsx("div", {
|
103
|
+
className: stl(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["display-caption typo-subdued"]))),
|
104
|
+
children: subtitle
|
105
|
+
}), /*#__PURE__*/_jsx("div", {
|
106
|
+
className: stl(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["typo-display-body"]))),
|
107
|
+
children: content
|
108
|
+
}), !!footer && /*#__PURE__*/_jsx("div", {
|
109
|
+
className: stl(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["mt-2"]))),
|
110
|
+
children: footer
|
111
|
+
}), /*#__PURE__*/_jsx(PopoverPrimitive.Close, {
|
112
|
+
className: stl(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["absolute top-2 right-2"]))),
|
113
|
+
asChild: true,
|
114
|
+
children: /*#__PURE__*/_jsx(IconButton, {
|
115
|
+
icon: X,
|
116
|
+
title: locale.dismissText,
|
117
|
+
variant: "subtle",
|
118
|
+
showTooltip: false
|
119
|
+
})
|
120
|
+
})]
|
121
|
+
}), !noArrow && /*#__PURE__*/_jsx(PopoverPrimitive.Arrow, {
|
122
|
+
width: 16,
|
123
|
+
height: 8,
|
124
|
+
className: stl(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["arrow-light"])))
|
125
|
+
})]
|
126
|
+
})))]
|
127
|
+
});
|
128
|
+
};
|
129
|
+
export default Popover;
|
@@ -0,0 +1,74 @@
|
|
1
|
+
import type { PopoverContentProps } from "@radix-ui/react-popover";
|
2
|
+
import type { HTMLAttributes, ReactElement, ReactNode } from "react";
|
3
|
+
export declare type PopoverLocale = {
|
4
|
+
dismissText?: string;
|
5
|
+
};
|
6
|
+
export interface PopoverProps extends Omit<HTMLAttributes<HTMLDivElement>, "title"> {
|
7
|
+
/**
|
8
|
+
* Defines the trigger element of the `Popover`.
|
9
|
+
* It should be a button element.
|
10
|
+
*/
|
11
|
+
children: ReactElement;
|
12
|
+
/**
|
13
|
+
* Defines the title of the `Popover`.
|
14
|
+
*/
|
15
|
+
title: ReactNode;
|
16
|
+
/**
|
17
|
+
* Defines the subtitle of the `Popover`.
|
18
|
+
*/
|
19
|
+
subtitle?: ReactNode;
|
20
|
+
/**
|
21
|
+
* Defines the content of the `Popover`.
|
22
|
+
*/
|
23
|
+
content: ReactNode;
|
24
|
+
/**
|
25
|
+
* Defines the footer of the `Popover`.
|
26
|
+
*/
|
27
|
+
footer?: ReactNode;
|
28
|
+
/**
|
29
|
+
* Defines whether the `Popover` should be opened or not.
|
30
|
+
*/
|
31
|
+
open?: boolean;
|
32
|
+
/**
|
33
|
+
* Defines the event handler called when the `Popover` is dismissed.
|
34
|
+
*/
|
35
|
+
onDismiss?: () => void;
|
36
|
+
/**
|
37
|
+
* Defines the side of the trigger element where the `Popover` should be displayed.
|
38
|
+
* Will be reversed when collisions occur and `avoidCollisions` is enabled.
|
39
|
+
* @default "top"
|
40
|
+
*/
|
41
|
+
side?: PopoverContentProps["side"];
|
42
|
+
/**
|
43
|
+
* Defines the offset in pixels of the `Popover` from the trigger element.
|
44
|
+
*/
|
45
|
+
sideOffset?: PopoverContentProps["sideOffset"];
|
46
|
+
/**
|
47
|
+
* Defines the preferred alignment of the `Popover` against the trigger element.
|
48
|
+
* May change when collisions occur.
|
49
|
+
*/
|
50
|
+
align?: PopoverContentProps["align"];
|
51
|
+
/**
|
52
|
+
* Defines the offset in pixels of the `Popover` along the trigger element.
|
53
|
+
* It only works when the `align` option is set to "start" or "end".
|
54
|
+
*/
|
55
|
+
alignOffset?: PopoverContentProps["alignOffset"];
|
56
|
+
/**
|
57
|
+
* Defines whether the `Popover` arrow should be hidden.
|
58
|
+
*/
|
59
|
+
noArrow?: boolean;
|
60
|
+
/**
|
61
|
+
* Defines whether the `Popover` should avoid collisions with the viewport.
|
62
|
+
*/
|
63
|
+
avoidCollisions?: boolean;
|
64
|
+
/**
|
65
|
+
* The element that should receive focus once the `Popover` is opened.
|
66
|
+
* If `undefined` or `null` is passed, the first focusable element will be focused.
|
67
|
+
* If `false`, no element will be focused.
|
68
|
+
*/
|
69
|
+
autoFocusOnOpenElement?: HTMLElement | null | false;
|
70
|
+
/**
|
71
|
+
* Defines the locale of the `Popover`.
|
72
|
+
*/
|
73
|
+
locale?: PopoverLocale;
|
74
|
+
}
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
@@ -3,11 +3,12 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
4
4
|
var _templateObject, _templateObject2;
|
5
5
|
var _excluded = ["value", "className", "barClassName"];
|
6
|
-
function ownKeys(
|
7
|
-
function _objectSpread(
|
6
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
7
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
8
8
|
import cx from "clsx";
|
9
9
|
import { forwardRef } from "react";
|
10
10
|
import stl from "../styles/helpers/satellitePrefixer";
|
11
|
+
import { prefersReducedMotion } from "../utils/prefersReducedMotion";
|
11
12
|
import { jsx as _jsx } from "react/jsx-runtime";
|
12
13
|
/**
|
13
14
|
* Progress bars visually represent the completion of a task or operation.
|
@@ -32,7 +33,7 @@ export var ProgressBar = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
32
33
|
className: cx(stl(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["progress-bar-progress"]))), barClassName),
|
33
34
|
style: {
|
34
35
|
width: "".concat(value, "%"),
|
35
|
-
transition: "
|
36
|
+
transition: prefersReducedMotion ? "width 150ms ease-in-out" : "width 500ms ease-in-out"
|
36
37
|
}
|
37
38
|
})
|
38
39
|
}));
|
@@ -3,8 +3,8 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
3
3
|
import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
|
4
4
|
var _excluded = ["className", "size", "thickness", "align"];
|
5
5
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
6
|
-
function ownKeys(
|
7
|
-
function _objectSpread(
|
6
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
7
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
8
8
|
import cx from "clsx";
|
9
9
|
import stl from "../styles/helpers/satellitePrefixer";
|
10
10
|
import { jsx as _jsx } from "react/jsx-runtime";
|
@@ -1,5 +1,5 @@
|
|
1
1
|
export = progressSpinnerPlugin;
|
2
2
|
declare const progressSpinnerPlugin: {
|
3
3
|
handler: import("tailwindcss/types/config").PluginCreator;
|
4
|
-
config?: Partial<import("tailwindcss").Config> | undefined;
|
4
|
+
config?: Partial<import("tailwindcss/types/config").Config> | undefined;
|
5
5
|
};
|
@@ -12,8 +12,16 @@ var progressSpinnerPlugin = plugin(function (_ref) {
|
|
12
12
|
".progress-spinner": {
|
13
13
|
color: theme("colors.accent.600"),
|
14
14
|
stroke: "currentColor",
|
15
|
+
// eslint-disable-next-line @algolia/satellite/prefer-stl-helper
|
15
16
|
animation: "stl-spinner 1.4s linear infinite"
|
16
17
|
},
|
18
|
+
"@media (prefers-reduced-motion: reduce)": {
|
19
|
+
".progress-spinner": {
|
20
|
+
// eslint-disable-next-line @algolia/satellite/prefer-stl-helper
|
21
|
+
animation: "stl-spinner 2.8s linear infinite"
|
22
|
+
}
|
23
|
+
},
|
24
|
+
// eslint-disable-next-line @algolia/satellite/prefer-stl-helper
|
17
25
|
"@keyframes stl-spinner": {
|
18
26
|
"0%": {
|
19
27
|
transform: "rotate(0deg)",
|
@@ -1,4 +1,4 @@
|
|
1
1
|
import type { HTMLAttributes, InputHTMLAttributes } from "react";
|
2
2
|
export declare type RadioButtonProps = HTMLAttributes<HTMLInputElement> & Pick<InputHTMLAttributes<HTMLInputElement>, "value" | "name" | "checked" | "defaultChecked" | "onChange" | "required" | "autoFocus" | "disabled">;
|
3
|
-
export declare const RadioButton: import("react").ForwardRefExoticComponent<HTMLAttributes<HTMLInputElement> & Pick<InputHTMLAttributes<HTMLInputElement>, "
|
3
|
+
export declare const RadioButton: import("react").ForwardRefExoticComponent<HTMLAttributes<HTMLInputElement> & Pick<InputHTMLAttributes<HTMLInputElement>, "value" | "defaultChecked" | "onChange" | "autoFocus" | "disabled" | "name" | "checked" | "required"> & import("react").RefAttributes<HTMLInputElement>>;
|
4
4
|
export default RadioButton;
|
@@ -3,8 +3,8 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
4
4
|
var _templateObject;
|
5
5
|
var _excluded = ["className"];
|
6
|
-
function ownKeys(
|
7
|
-
function _objectSpread(
|
6
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
7
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
8
8
|
import cx from "clsx";
|
9
9
|
import { forwardRef } from "react";
|
10
10
|
import stl from "../styles/helpers/satellitePrefixer";
|
@@ -39,6 +39,9 @@ var radioButtonPlugin = plugin(function (_ref) {
|
|
39
39
|
background: theme("colors.accent.600"),
|
40
40
|
borderRadius: "50%"
|
41
41
|
},
|
42
|
+
"&:hover": {
|
43
|
+
borderColor: theme("colors.accent.700")
|
44
|
+
},
|
42
45
|
"&:focus": {
|
43
46
|
boxShadow: "\n 0 0 0 1px ".concat(theme("colors.accent.600"), ",\n 0 1px 0 0 ").concat(theme("colors.shadow.5"), "\n ")
|
44
47
|
}
|
@@ -3,10 +3,7 @@ export interface RadioGroupContextType {
|
|
3
3
|
name: string;
|
4
4
|
value: string;
|
5
5
|
disabled?: boolean;
|
6
|
-
/**
|
7
|
-
* `RadioGroupItem` text position
|
8
|
-
* @default left
|
9
|
-
*/
|
6
|
+
/** `RadioGroupItem` text position */
|
10
7
|
textPosition?: "left" | "right";
|
11
8
|
onChange: (newValue: string) => void;
|
12
9
|
}
|
@@ -10,7 +10,9 @@ export interface RangeSliderProps<Value extends RangeSliderValue = number> {
|
|
10
10
|
onCommit?: (value: WidenNumber<Value>) => void;
|
11
11
|
id?: string;
|
12
12
|
name?: string;
|
13
|
+
/** @ignore */
|
13
14
|
className?: string;
|
15
|
+
/** @ignore */
|
14
16
|
"aria-label"?: string;
|
15
17
|
disabled?: boolean;
|
16
18
|
min?: number;
|
@@ -3,8 +3,8 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
3
3
|
import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
|
4
4
|
var _excluded = ["className", "value", "defaultValue", "onChange", "onCommit", "disabled", "min", "max", "track1Color", "track2Color"];
|
5
5
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8;
|
6
|
-
function ownKeys(
|
7
|
-
function _objectSpread(
|
6
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
7
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
8
8
|
import { SliderRange, Root as SliderRoot, SliderThumb, SliderTrack } from "@radix-ui/react-slider";
|
9
9
|
import cx from "clsx";
|
10
10
|
import { forwardRef } from "react";
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import {
|
1
|
+
import { useLayoutEffect } from "react";
|
2
2
|
import SatelliteContext from "./SatelliteContext";
|
3
3
|
import { router as defaultRouter } from "./SatelliteRouter";
|
4
4
|
import { jsx as _jsx } from "react/jsx-runtime";
|
@@ -23,10 +23,10 @@ export var Satellite = function Satellite(_ref) {
|
|
23
23
|
_ref$portalTarget = _ref.portalTarget,
|
24
24
|
customPortalTarget = _ref$portalTarget === void 0 ? null : _ref$portalTarget,
|
25
25
|
children = _ref.children;
|
26
|
-
var portalTarget = (_ref2 = customPortalTarget !== null && customPortalTarget !== void 0 ? customPortalTarget : document.getElementById(DEFAULT_PORTAL_ID)) !== null && _ref2 !== void 0 ? _ref2 : createDefaultPortalTarget();
|
26
|
+
var portalTarget = typeof document === "undefined" ? null : (_ref2 = customPortalTarget !== null && customPortalTarget !== void 0 ? customPortalTarget : document.getElementById(DEFAULT_PORTAL_ID)) !== null && _ref2 !== void 0 ? _ref2 : createDefaultPortalTarget();
|
27
27
|
|
28
28
|
// Auto append / remove default target as necessary
|
29
|
-
|
29
|
+
useLayoutEffect(function () {
|
30
30
|
if (!portalTarget || !isDefaultPortalTarget(portalTarget)) return;
|
31
31
|
document.body.appendChild(portalTarget);
|
32
32
|
return function () {
|
@@ -35,7 +35,7 @@ export var Satellite = function Satellite(_ref) {
|
|
35
35
|
}, [portalTarget]);
|
36
36
|
|
37
37
|
// Radix adds pointer-events: none; on the body for its modal, so we need to reenable it for other portaled elements (tooltips, menus, autocomplete)
|
38
|
-
|
38
|
+
useLayoutEffect(function () {
|
39
39
|
if (!portalTarget || typeof document === "undefined") return;
|
40
40
|
if (portalTarget === document.body) {
|
41
41
|
console.warn("Avoid using the document body as a portal target.");
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
2
|
-
function ownKeys(
|
3
|
-
function _objectSpread(
|
2
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
3
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
4
4
|
import { createContext, useContext } from "react";
|
5
5
|
import { router } from "./SatelliteRouter";
|
6
6
|
var DEFAULT_CONTEXT = {
|
@@ -9,6 +9,7 @@ import type { ModalLocale } from "../Modal";
|
|
9
9
|
import type { PaginationLocale } from "../Pagination";
|
10
10
|
import type { CompactPaginationLocale } from "../Pagination/CompactPagination";
|
11
11
|
import type { DotPaginationLocale } from "../Pagination/DotPagination";
|
12
|
+
import type { PopoverLocale } from "../Popover/types";
|
12
13
|
import type { SidebarLocale } from "../Sidebar";
|
13
14
|
import type { DataTableLocale } from "../Tables/DataTable";
|
14
15
|
import type { TagLocale } from "../Tag";
|
@@ -24,6 +25,7 @@ export declare type ComponentsLocales = {
|
|
24
25
|
input?: InputPropsLocale;
|
25
26
|
modal?: ModalLocale;
|
26
27
|
pagination?: PaginationLocale;
|
28
|
+
popover?: PopoverLocale;
|
27
29
|
sidebar?: SidebarLocale;
|
28
30
|
tag?: TagLocale;
|
29
31
|
userAvatar?: UserAvatarLocale;
|
@@ -1,5 +1,5 @@
|
|
1
1
|
export = scrollIndicatorPlugin;
|
2
2
|
declare const scrollIndicatorPlugin: {
|
3
3
|
handler: import("tailwindcss/types/config").PluginCreator;
|
4
|
-
config?: Partial<import("tailwindcss").Config> | undefined;
|
4
|
+
config?: Partial<import("tailwindcss/types/config").Config> | undefined;
|
5
5
|
};
|
package/esm/Select/Select.js
CHANGED
@@ -3,8 +3,8 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
3
3
|
import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
|
4
4
|
var _excluded = ["variant", "className"];
|
5
5
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
6
|
-
function ownKeys(
|
7
|
-
function _objectSpread(
|
6
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
7
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
8
8
|
import cx from "clsx";
|
9
9
|
import { forwardRef } from "react";
|
10
10
|
import stl from "../styles/helpers/satellitePrefixer";
|
@@ -2,6 +2,7 @@ import * as RadixSeparator from "@radix-ui/react-separator";
|
|
2
2
|
import type { VFC } from "react";
|
3
3
|
export interface SeparatorProps {
|
4
4
|
className?: string;
|
5
|
+
interactive?: boolean;
|
5
6
|
orientation?: RadixSeparator.SeparatorProps["orientation"];
|
6
7
|
}
|
7
8
|
export declare const Separator: VFC<SeparatorProps>;
|
@@ -1,17 +1,29 @@
|
|
1
|
+
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
1
2
|
import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
|
2
|
-
var _templateObject;
|
3
|
+
var _templateObject, _templateObject2;
|
4
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
5
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
3
6
|
import * as RadixSeparator from "@radix-ui/react-separator";
|
4
7
|
import cx from "clsx";
|
5
8
|
import stl from "../styles/helpers/satellitePrefixer";
|
6
9
|
import { jsx as _jsx } from "react/jsx-runtime";
|
7
10
|
export var Separator = function Separator(_ref) {
|
8
11
|
var className = _ref.className,
|
12
|
+
interactive = _ref.interactive,
|
9
13
|
_ref$orientation = _ref.orientation,
|
10
14
|
orientation = _ref$orientation === void 0 ? "horizontal" : _ref$orientation;
|
11
|
-
|
12
|
-
decorative:
|
13
|
-
|
15
|
+
var interactiveProps = interactive ? {
|
16
|
+
decorative: false,
|
17
|
+
tabIndex: 0,
|
18
|
+
"aria-valuemax": 100,
|
19
|
+
"aria-valuemin": 0,
|
20
|
+
"aria-valuenow": 50
|
21
|
+
} : {
|
22
|
+
decorative: true
|
23
|
+
};
|
24
|
+
return /*#__PURE__*/_jsx(RadixSeparator.Root, _objectSpread({
|
25
|
+
className: cx(stl(_templateObject || (_templateObject = _taggedTemplateLiteral(["separator"]))), className, interactive && stl(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["interactive"])))),
|
14
26
|
orientation: orientation
|
15
|
-
});
|
27
|
+
}, interactiveProps));
|
16
28
|
};
|
17
29
|
export default Separator;
|
@@ -8,15 +8,44 @@ var separatorPlugin = plugin(function (_ref) {
|
|
8
8
|
addComponents({
|
9
9
|
".separator": {
|
10
10
|
backgroundColor: theme("colors.grey.200"),
|
11
|
+
"&.interactive:hover": {
|
12
|
+
backgroundColor: theme("colors.xenon.600")
|
13
|
+
},
|
14
|
+
"&.interactive:focus": {
|
15
|
+
backgroundColor: theme("colors.xenon.600"),
|
16
|
+
outline: "solid 1px ".concat(theme("colors.xenon.600"))
|
17
|
+
},
|
11
18
|
'&[data-orientation="horizontal"]': {
|
12
19
|
height: "1px",
|
13
20
|
width: "100%",
|
14
|
-
margin: "".concat(margin, " 0")
|
21
|
+
margin: "".concat(margin, " 0"),
|
22
|
+
"&.interactive": {
|
23
|
+
position: "relative",
|
24
|
+
"&::after": {
|
25
|
+
position: "absolute",
|
26
|
+
right: "0px",
|
27
|
+
left: "0px",
|
28
|
+
top: "-10px",
|
29
|
+
height: "20px",
|
30
|
+
content: '" "'
|
31
|
+
}
|
32
|
+
}
|
15
33
|
},
|
16
34
|
'&[data-orientation="vertical"]': {
|
17
35
|
height: "100%",
|
18
36
|
width: "1px",
|
19
|
-
margin: "0 ".concat(margin)
|
37
|
+
margin: "0 ".concat(margin),
|
38
|
+
"&.interactive": {
|
39
|
+
position: "relative",
|
40
|
+
"&::after": {
|
41
|
+
position: "absolute",
|
42
|
+
width: "20px",
|
43
|
+
left: "-10px",
|
44
|
+
top: "0px",
|
45
|
+
bottom: "0px",
|
46
|
+
content: '" "'
|
47
|
+
}
|
48
|
+
}
|
20
49
|
}
|
21
50
|
}
|
22
51
|
});
|
package/esm/Sidebar/Sidebar.d.ts
CHANGED
package/esm/Sidebar/Sidebar.js
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
3
3
|
var _templateObject, _templateObject2, _templateObject3;
|
4
|
-
function ownKeys(
|
5
|
-
function _objectSpread(
|
4
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
5
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
6
6
|
import cx from "clsx";
|
7
7
|
import { useCallback } from "react";
|
8
8
|
import { useLocale } from "../Satellite";
|
@@ -2,8 +2,8 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
2
|
import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
|
3
3
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
4
4
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
5
|
-
function ownKeys(
|
6
|
-
function _objectSpread(
|
5
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
6
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
7
7
|
import { useState } from "react";
|
8
8
|
import { ExternalLink } from "react-feather";
|
9
9
|
import stl from "../styles/helpers/satellitePrefixer";
|