@algolia/satellite 1.0.0-beta.147 → 1.0.0-beta.148
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.js +7 -24
- package/cjs/AnnouncementBadge/index.js +0 -5
- package/cjs/AutoComplete/AutoComplete.js +68 -163
- package/cjs/AutoComplete/AutoComplete.tailwind.js +2 -5
- package/cjs/AutoComplete/components/AutoCompleteEmptyState.js +5 -14
- package/cjs/AutoComplete/components/DefaultOptionItem.js +2 -11
- package/cjs/AutoComplete/index.js +0 -11
- package/cjs/AutoComplete/utils.js +0 -8
- package/cjs/Avatars/ApplicationAvatar.js +3 -13
- package/cjs/Avatars/UserAvatar.js +6 -20
- package/cjs/Avatars/index.js +0 -7
- package/cjs/Avatars/utils.js +6 -37
- package/cjs/Badge/Badge.js +13 -36
- package/cjs/Badge/index.js +0 -5
- package/cjs/Banners/Alert/Alert.js +18 -28
- package/cjs/Banners/Alert/index.js +0 -5
- package/cjs/Banners/BigBertha/BigBertha.js +1 -9
- package/cjs/Banners/BigBertha/index.js +0 -5
- package/cjs/Banners/Promote/Promote.js +8 -19
- package/cjs/Banners/Promote/index.js +0 -5
- package/cjs/Banners/index.js +0 -6
- package/cjs/Button/Button.js +13 -33
- package/cjs/Button/Button.tailwind.js +3 -5
- package/cjs/Button/ButtonGroup.js +3 -11
- package/cjs/Button/IconButton.js +12 -35
- package/cjs/Button/index.js +0 -11
- package/cjs/Button/styles.js +1 -10
- package/cjs/Button/types.js +0 -1
- package/cjs/Card/Card.js +6 -21
- package/cjs/Card/Card.tailwind.js +1 -2
- package/cjs/Card/components/CardHeader.js +1 -14
- package/cjs/Card/components/CardTitle.js +2 -15
- package/cjs/Card/index.js +0 -9
- package/cjs/Checkbox/Checkbox.js +14 -38
- package/cjs/Checkbox/Checkbox.tailwind.js +1 -3
- package/cjs/Checkbox/index.js +0 -5
- package/cjs/ClickAwayContainer/ClickAwayContainer.js +11 -23
- package/cjs/ClickAwayContainer/index.js +0 -2
- package/cjs/DatePicker/DatePicker/DatePicker.js +13 -46
- package/cjs/DatePicker/DatePicker/datePickerReducer.js +0 -15
- package/cjs/DatePicker/DatePicker/index.js +0 -7
- package/cjs/DatePicker/DatePicker.tailwind.js +2 -12
- package/cjs/DatePicker/DateRangePicker/DateRangePicker.js +29 -72
- package/cjs/DatePicker/DateRangePicker/DateRangePickerDisplay.js +4 -14
- package/cjs/DatePicker/DateRangePicker/dateRangePickerReducer.js +2 -28
- package/cjs/DatePicker/DateRangePicker/dateRangePickerTimeRange.js +0 -6
- package/cjs/DatePicker/DateRangePicker/index.js +0 -9
- package/cjs/DatePicker/components/Calendar.js +5 -16
- package/cjs/DatePicker/components/Display.js +3 -9
- package/cjs/DatePicker/components/Footer.js +0 -7
- package/cjs/DatePicker/components/FooterActions.js +3 -11
- package/cjs/DatePicker/components/Modal.js +17 -39
- package/cjs/DatePicker/components/NavBar.js +12 -34
- package/cjs/DatePicker/components/SidePanel.js +0 -7
- package/cjs/DatePicker/components/index.js +0 -7
- package/cjs/DatePicker/index.js +0 -9
- package/cjs/DatePicker/utils.js +0 -4
- package/cjs/Dropdown/Dropdown.js +23 -58
- package/cjs/Dropdown/DropdownButton.js +3 -20
- package/cjs/Dropdown/DropdownContext.js +0 -6
- package/cjs/Dropdown/components/DropdownButtonItem.js +5 -21
- package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItem.js +10 -25
- package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroup.js +2 -6
- package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroupContext.js +0 -6
- package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsMultiGroup.js +6 -16
- package/cjs/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsSingleGroup.js +6 -15
- package/cjs/Dropdown/components/DropdownCollapsibleItem/index.js +0 -9
- package/cjs/Dropdown/components/DropdownDivider.js +0 -7
- package/cjs/Dropdown/components/DropdownFooterItem.js +2 -15
- package/cjs/Dropdown/components/DropdownLinkItem.js +6 -23
- package/cjs/Dropdown/components/DropdownRadioItem.js +4 -20
- package/cjs/Dropdown/components/DropdownTitle.js +1 -14
- package/cjs/Dropdown/components/DropdownToggleItem.js +5 -22
- package/cjs/Dropdown/index.js +0 -27
- package/cjs/Dropdown/useDropdownItemProps.js +1 -14
- package/cjs/Dropzone/Dropzone.js +27 -62
- package/cjs/Dropzone/index.js +0 -5
- package/cjs/EmptyState/EmptyState.js +12 -23
- package/cjs/EmptyState/EmptyState.tailwind.js +0 -1
- package/cjs/EmptyState/index.js +0 -7
- package/cjs/Field/Field.js +8 -21
- package/cjs/Field/FieldStateContext.js +0 -2
- package/cjs/Field/index.js +0 -9
- package/cjs/Field/useFieldState.js +0 -7
- package/cjs/Flag/Flag.js +17 -40
- package/cjs/Flag/Flag.tailwind.js +0 -1
- package/cjs/Flag/Flags.js +4 -19
- package/cjs/Flag/index.js +0 -9
- package/cjs/FlexGrid/FlexGrid.js +13 -24
- package/cjs/FlexGrid/FlexGrid.tailwind.js +4 -11
- package/cjs/FlexGrid/index.js +0 -5
- package/cjs/HelpUnderline/HelpUnderline.js +5 -14
- package/cjs/HelpUnderline/HelpUnderline.tailwind.js +1 -2
- package/cjs/HelpUnderline/index.js +0 -5
- package/cjs/Input/Input.js +26 -70
- package/cjs/Input/Input.tailwind.js +1 -4
- package/cjs/Input/index.js +0 -5
- package/cjs/Insert/Insert.js +7 -17
- package/cjs/Insert/index.js +0 -5
- package/cjs/InstantSearch/InstantSearch.tailwind.js +4 -10
- package/cjs/KeyboardKey/KeyboardKey.js +1 -12
- package/cjs/KeyboardKey/KeyboardKey.tailwind.js +1 -2
- package/cjs/KeyboardKey/index.js +0 -2
- package/cjs/Link/BaseLink.js +2 -12
- package/cjs/Link/ButtonLink.js +3 -17
- package/cjs/Link/IconButtonLink.js +2 -13
- package/cjs/Link/Link.js +6 -23
- package/cjs/Link/index.js +0 -11
- package/cjs/Medallion/Medallion.js +5 -14
- package/cjs/Medallion/Medallion.tailwind.js +3 -6
- package/cjs/Medallion/index.js +0 -7
- package/cjs/Modal/Modal.js +21 -57
- package/cjs/Modal/Modal.tailwind.js +3 -3
- package/cjs/Modal/components/ModalFooter.js +2 -16
- package/cjs/Modal/components/ModalSection.js +3 -11
- package/cjs/Modal/index.js +0 -9
- package/cjs/Pagination/CompactPagination/CompactPagination.js +1 -22
- package/cjs/Pagination/CompactPagination/index.js +0 -5
- package/cjs/Pagination/DotPagination/DotPagination.js +5 -19
- package/cjs/Pagination/DotPagination/index.js +0 -5
- package/cjs/Pagination/Pagination/Pagination.js +9 -34
- package/cjs/Pagination/Pagination/index.js +0 -5
- package/cjs/Pagination/index.js +0 -9
- package/cjs/ProgressBar/ProgressBar.js +3 -16
- package/cjs/ProgressBar/ProgressBar.tailwind.js +1 -3
- package/cjs/ProgressBar/index.js +0 -5
- package/cjs/ProgressSpinner/ProgressSpinner.js +8 -20
- package/cjs/ProgressSpinner/ProgressSpinner.tailwind.js +2 -3
- package/cjs/ProgressSpinner/index.js +0 -5
- package/cjs/RadioGroup/RadioButton.js +1 -14
- package/cjs/RadioGroup/RadioButton.tailwind.js +1 -4
- package/cjs/RadioGroup/RadioGroup.js +19 -38
- package/cjs/RadioGroup/RadiogroupContext.js +0 -6
- package/cjs/RadioGroup/index.js +0 -9
- package/cjs/RangeSlider/RangeSlider.js +26 -43
- package/cjs/RangeSlider/RangeSlider.tailwind.js +1 -3
- package/cjs/RangeSlider/index.js +0 -5
- package/cjs/Satellite/Satellite.js +4 -10
- package/cjs/Satellite/SatelliteContext.js +0 -9
- package/cjs/Satellite/SatelliteRouter.js +2 -9
- package/cjs/Satellite/index.js +0 -13
- package/cjs/Satellite/locale.js +1 -7
- package/cjs/Satellite/useCreatePortal.js +2 -8
- package/cjs/ScrollIndicator/ScrollIndicator.js +18 -41
- package/cjs/ScrollIndicator/ScrollIndicator.tailwind.js +1 -3
- package/cjs/ScrollIndicator/index.js +0 -5
- package/cjs/Select/Select.js +4 -17
- package/cjs/Select/Select.tailwind.js +2 -5
- package/cjs/Select/index.js +0 -5
- package/cjs/Sidebar/Sidebar.js +11 -30
- package/cjs/Sidebar/SidebarButtonLink.js +10 -30
- package/cjs/Sidebar/SidebarContext.js +0 -6
- package/cjs/Sidebar/SidebarHeader.js +1 -9
- package/cjs/Sidebar/SidebarHeading.js +3 -14
- package/cjs/Sidebar/SidebarLink.js +5 -20
- package/cjs/Sidebar/SidebarLinksGroup/ActiveLinkIndicator.js +2 -11
- package/cjs/Sidebar/SidebarLinksGroup/SidebarGroupLink.js +3 -14
- package/cjs/Sidebar/SidebarLinksGroup/SidebarLinksGroup.js +8 -31
- package/cjs/Sidebar/SidebarLinksGroup/index.js +0 -2
- package/cjs/Sidebar/SidebarNav.js +5 -16
- package/cjs/Sidebar/index.js +0 -17
- package/cjs/Switch/Switch.js +15 -36
- package/cjs/Switch/Switch.tailwind.js +1 -2
- package/cjs/Switch/SwitchOption.js +2 -15
- package/cjs/Switch/index.js +0 -7
- package/cjs/Switch/utils.js +0 -9
- package/cjs/Tables/DataTable/DataTable.js +28 -70
- package/cjs/Tables/DataTable/DataTable.tailwind.js +2 -2
- package/cjs/Tables/DataTable/components/Body.js +14 -33
- package/cjs/Tables/DataTable/components/Footer.js +1 -17
- package/cjs/Tables/DataTable/components/Header.js +5 -12
- package/cjs/Tables/DataTable/components/HeaderCell.js +10 -27
- package/cjs/Tables/DataTable/components/Loader.js +4 -17
- package/cjs/Tables/DataTable/components/index.js +0 -10
- package/cjs/Tables/DataTable/index.js +0 -7
- package/cjs/Tables/DataTable/utils.js +0 -9
- package/cjs/Tables/Table/Table.js +7 -21
- package/cjs/Tables/Table/Table.tailwind.js +1 -2
- package/cjs/Tables/Table/components/TableFooter.js +2 -10
- package/cjs/Tables/Table/index.js +0 -7
- package/cjs/Tables/index.js +0 -7
- package/cjs/Tabs/ContentTabs.js +10 -21
- package/cjs/Tabs/LinkTabs.js +5 -18
- package/cjs/Tabs/Tabs.tailwind.js +1 -2
- package/cjs/Tabs/components/LinkTab.js +2 -27
- package/cjs/Tabs/index.js +0 -9
- package/cjs/Tabs/utils.js +0 -5
- package/cjs/Tag/Tag.js +7 -26
- package/cjs/Tag/Tag.tailwind.js +1 -2
- package/cjs/Tag/index.js +0 -5
- package/cjs/TextArea/TextArea.js +1 -14
- package/cjs/TextArea/TextArea.tailwind.js +1 -4
- package/cjs/TextArea/index.js +0 -5
- package/cjs/TextWrap/TextWrap.js +3 -18
- package/cjs/TextWrap/index.js +0 -5
- package/cjs/Toggle/Toggle.js +6 -27
- package/cjs/Toggle/Toggle.tailwind.js +1 -3
- package/cjs/Toggle/index.js +0 -5
- package/cjs/Tooltip/OverflowTooltipWrapper.js +33 -62
- package/cjs/Tooltip/Tooltip.js +4 -17
- package/cjs/Tooltip/Tooltip.tailwind.js +3 -5
- package/cjs/Tooltip/TooltipWrapper.js +43 -71
- package/cjs/Tooltip/index.js +0 -9
- package/cjs/Typography/Typography.tailwind.js +12 -18
- package/cjs/UserContent/UserContent.js +3 -11
- package/cjs/UserContent/UserContent.tailwind.js +2 -11
- package/cjs/index.js +0 -89
- package/cjs/styles/base.tailwind.js +7 -7
- package/cjs/styles/colors.js +7 -7
- package/cjs/styles/disabledColor.js +1 -4
- package/cjs/styles/helpers/icons.js +5 -11
- package/cjs/styles/helpers/makePurgeCssExtractor.js +3 -15
- package/cjs/styles/helpers/makeTailwindPrefixer.js +1 -9
- package/cjs/styles/helpers/prefixTailwindClassName.js +6 -6
- package/cjs/styles/helpers/satellitePrefixer.js +1 -2
- package/cjs/styles/rgba.js +1 -3
- package/cjs/styles/tailwind.config.js +4 -11
- package/cjs/styles/zIndexes.js +1 -0
- package/cjs/utilities/utilities.tailwind.js +0 -3
- package/cjs/utils/event-polyfill.js +0 -2
- package/cjs/utils/formatters.js +12 -19
- package/cjs/utils/genericChangeHandler.js +0 -6
- package/cjs/utils/hashCode.js +0 -5
- package/cjs/utils/index.js +0 -7
- package/cjs/utils/isCssPropertySupported.js +0 -3
- package/cjs/utils/isNil.js +0 -2
- package/cjs/utils/isRenderedChild.js +0 -2
- package/cjs/utils/matchLocation.js +0 -4
- package/cjs/utils/onlyText.js +3 -12
- package/cjs/utils/parseUrl.js +2 -4
- package/cjs/utils/pluralize.js +2 -7
- package/cjs/utils/range.js +0 -2
- package/cjs/utils/toSentenceCase.js +0 -4
- package/cjs/utils/uniqBy.js +0 -4
- package/cjs/utils/uniqueId.js +0 -2
- package/cjs/utils/useForwardedRef.js +0 -6
- package/cjs/utils/useLinkProps.js +1 -13
- package/cjs/utils/useTriggerInputChange.js +2 -4
- package/esm/AnnouncementBadge/AnnouncementBadge.js +7 -14
- package/esm/AutoComplete/AutoComplete.js +68 -158
- package/esm/AutoComplete/AutoComplete.tailwind.js +2 -2
- package/esm/AutoComplete/components/AutoCompleteEmptyState.js +5 -7
- package/esm/AutoComplete/components/DefaultOptionItem.js +2 -8
- package/esm/AutoComplete/utils.js +0 -2
- package/esm/Avatars/ApplicationAvatar.js +3 -6
- package/esm/Avatars/UserAvatar.js +6 -12
- package/esm/Avatars/utils.js +7 -23
- package/esm/Badge/Badge.js +13 -28
- package/esm/Banners/Alert/Alert.js +18 -20
- package/esm/Banners/BigBertha/BigBertha.js +1 -4
- package/esm/Banners/Promote/Promote.js +8 -10
- package/esm/Button/Button.js +13 -21
- package/esm/Button/Button.tailwind.js +3 -2
- package/esm/Button/ButtonGroup.js +3 -6
- package/esm/Button/IconButton.js +12 -22
- package/esm/Button/styles.js +1 -5
- package/esm/Card/Card.js +6 -12
- package/esm/Card/Card.tailwind.js +1 -1
- package/esm/Card/components/CardHeader.js +1 -7
- package/esm/Card/components/CardTitle.js +2 -8
- package/esm/Checkbox/Checkbox.js +14 -28
- package/esm/Checkbox/Checkbox.tailwind.js +1 -1
- package/esm/ClickAwayContainer/ClickAwayContainer.js +11 -13
- package/esm/DatePicker/DatePicker/DatePicker.js +13 -31
- package/esm/DatePicker/DatePicker/datePickerReducer.js +0 -9
- package/esm/DatePicker/DatePicker.tailwind.js +2 -9
- package/esm/DatePicker/DateRangePicker/DateRangePicker.js +29 -55
- package/esm/DatePicker/DateRangePicker/DateRangePickerDisplay.js +4 -8
- package/esm/DatePicker/DateRangePicker/dateRangePickerReducer.js +2 -16
- package/esm/DatePicker/components/Calendar.js +5 -10
- package/esm/DatePicker/components/Display.js +3 -5
- package/esm/DatePicker/components/Footer.js +0 -4
- package/esm/DatePicker/components/FooterActions.js +3 -7
- package/esm/DatePicker/components/Modal.js +17 -27
- package/esm/DatePicker/components/NavBar.js +12 -22
- package/esm/DatePicker/components/SidePanel.js +0 -4
- package/esm/Dropdown/Dropdown.js +23 -34
- package/esm/Dropdown/DropdownButton.js +3 -11
- package/esm/Dropdown/DropdownContext.js +0 -2
- package/esm/Dropdown/components/DropdownButtonItem.js +5 -12
- package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItem.js +10 -15
- package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroup.js +2 -2
- package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsGroupContext.js +0 -2
- package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsMultiGroup.js +6 -9
- package/esm/Dropdown/components/DropdownCollapsibleItem/DropdownCollapsibleItemsSingleGroup.js +6 -9
- package/esm/Dropdown/components/DropdownDivider.js +0 -2
- package/esm/Dropdown/components/DropdownFooterItem.js +2 -8
- package/esm/Dropdown/components/DropdownLinkItem.js +6 -13
- package/esm/Dropdown/components/DropdownRadioItem.js +4 -11
- package/esm/Dropdown/components/DropdownTitle.js +1 -7
- package/esm/Dropdown/components/DropdownToggleItem.js +5 -12
- package/esm/Dropdown/useDropdownItemProps.js +1 -7
- package/esm/Dropzone/Dropzone.js +27 -45
- package/esm/EmptyState/EmptyState.js +12 -16
- package/esm/Field/Field.js +8 -11
- package/esm/Flag/Flag.js +17 -25
- package/esm/Flag/Flags.js +4 -9
- package/esm/FlexGrid/FlexGrid.js +13 -15
- package/esm/FlexGrid/FlexGrid.tailwind.js +4 -9
- package/esm/HelpUnderline/HelpUnderline.js +5 -7
- package/esm/HelpUnderline/HelpUnderline.tailwind.js +1 -1
- package/esm/Input/Input.js +26 -54
- package/esm/Input/Input.tailwind.js +1 -1
- package/esm/Insert/Insert.js +7 -11
- package/esm/InstantSearch/InstantSearch.tailwind.js +4 -4
- package/esm/KeyboardKey/KeyboardKey.js +1 -3
- package/esm/KeyboardKey/KeyboardKey.tailwind.js +1 -1
- package/esm/Link/BaseLink.js +2 -6
- package/esm/Link/ButtonLink.js +3 -9
- package/esm/Link/IconButtonLink.js +2 -6
- package/esm/Link/Link.js +6 -14
- package/esm/Medallion/Medallion.js +5 -7
- package/esm/Medallion/Medallion.tailwind.js +3 -2
- package/esm/Modal/Modal.js +21 -38
- package/esm/Modal/Modal.tailwind.js +3 -2
- package/esm/Modal/components/ModalFooter.js +2 -8
- package/esm/Modal/components/ModalSection.js +3 -5
- package/esm/Pagination/CompactPagination/CompactPagination.js +1 -9
- package/esm/Pagination/DotPagination/DotPagination.js +5 -11
- package/esm/Pagination/Pagination/Pagination.js +9 -21
- package/esm/ProgressBar/ProgressBar.js +3 -10
- package/esm/ProgressBar/ProgressBar.tailwind.js +1 -1
- package/esm/ProgressSpinner/ProgressSpinner.js +8 -12
- package/esm/ProgressSpinner/ProgressSpinner.tailwind.js +2 -2
- package/esm/RadioGroup/RadioButton.js +1 -7
- package/esm/RadioGroup/RadioButton.tailwind.js +1 -1
- package/esm/RadioGroup/RadioGroup.js +19 -25
- package/esm/RadioGroup/RadiogroupContext.js +0 -2
- package/esm/RangeSlider/RangeSlider.js +26 -35
- package/esm/RangeSlider/RangeSlider.tailwind.js +1 -1
- package/esm/Satellite/Satellite.js +4 -4
- package/esm/Satellite/SatelliteContext.js +0 -3
- package/esm/Satellite/SatelliteRouter.js +2 -4
- package/esm/Satellite/locale.js +1 -2
- package/esm/Satellite/useCreatePortal.js +2 -2
- package/esm/ScrollIndicator/ScrollIndicator.js +18 -31
- package/esm/ScrollIndicator/ScrollIndicator.tailwind.js +1 -1
- package/esm/Select/Select.js +4 -9
- package/esm/Select/Select.tailwind.js +2 -2
- package/esm/Sidebar/Sidebar.js +11 -17
- package/esm/Sidebar/SidebarButtonLink.js +10 -20
- package/esm/Sidebar/SidebarContext.js +0 -2
- package/esm/Sidebar/SidebarHeader.js +1 -3
- package/esm/Sidebar/SidebarHeading.js +3 -7
- package/esm/Sidebar/SidebarLink.js +5 -11
- package/esm/Sidebar/SidebarLinksGroup/ActiveLinkIndicator.js +2 -4
- package/esm/Sidebar/SidebarLinksGroup/SidebarGroupLink.js +3 -7
- package/esm/Sidebar/SidebarLinksGroup/SidebarLinksGroup.js +8 -18
- package/esm/Sidebar/SidebarNav.js +5 -9
- package/esm/Switch/Switch.js +15 -24
- package/esm/Switch/Switch.tailwind.js +1 -1
- package/esm/Switch/SwitchOption.js +2 -6
- package/esm/Tables/DataTable/DataTable.js +28 -49
- package/esm/Tables/DataTable/DataTable.tailwind.js +2 -1
- package/esm/Tables/DataTable/components/Body.js +14 -23
- package/esm/Tables/DataTable/components/Footer.js +1 -8
- package/esm/Tables/DataTable/components/Header.js +5 -6
- package/esm/Tables/DataTable/components/HeaderCell.js +10 -17
- package/esm/Tables/DataTable/components/Loader.js +4 -8
- package/esm/Tables/DataTable/utils.js +0 -1
- package/esm/Tables/Table/Table.js +7 -14
- package/esm/Tables/Table/Table.tailwind.js +1 -1
- package/esm/Tables/Table/components/TableFooter.js +2 -4
- package/esm/Tabs/ContentTabs.js +10 -12
- package/esm/Tabs/LinkTabs.js +5 -7
- package/esm/Tabs/Tabs.tailwind.js +1 -1
- package/esm/Tabs/components/LinkTab.js +2 -18
- package/esm/Tabs/utils.js +0 -2
- package/esm/Tag/Tag.js +7 -16
- package/esm/Tag/Tag.tailwind.js +1 -1
- package/esm/TextArea/TextArea.js +1 -7
- package/esm/TextArea/TextArea.tailwind.js +1 -1
- package/esm/TextWrap/TextWrap.js +3 -11
- package/esm/Toggle/Toggle.js +6 -19
- package/esm/Toggle/Toggle.tailwind.js +1 -1
- package/esm/Tooltip/OverflowTooltipWrapper.js +33 -46
- package/esm/Tooltip/Tooltip.js +4 -9
- package/esm/Tooltip/Tooltip.tailwind.js +3 -4
- package/esm/Tooltip/TooltipWrapper.js +43 -56
- package/esm/Typography/Typography.tailwind.js +12 -15
- package/esm/UserContent/UserContent.js +3 -5
- package/esm/UserContent/UserContent.tailwind.js +2 -7
- package/esm/styles/base.tailwind.js +7 -6
- package/esm/styles/colors.js +7 -7
- package/esm/styles/disabledColor.js +1 -2
- package/esm/styles/helpers/icons.js +5 -8
- package/esm/styles/helpers/makePurgeCssExtractor.js +3 -14
- package/esm/styles/helpers/makeTailwindPrefixer.js +1 -6
- package/esm/styles/helpers/prefixTailwindClassName.js +6 -6
- package/esm/styles/helpers/satellitePrefixer.js +1 -1
- package/esm/styles/rgba.js +1 -2
- package/esm/styles/tailwind.config.js +4 -6
- package/esm/styles/zIndexes.js +1 -0
- package/esm/utils/event-polyfill.js +0 -2
- package/esm/utils/formatters.js +12 -16
- package/esm/utils/genericChangeHandler.js +0 -2
- package/esm/utils/hashCode.js +0 -3
- package/esm/utils/isCssPropertySupported.js +0 -2
- package/esm/utils/isRenderedChild.js +0 -1
- package/esm/utils/matchLocation.js +0 -2
- package/esm/utils/onlyText.js +3 -11
- package/esm/utils/parseUrl.js +2 -2
- package/esm/utils/pluralize.js +2 -5
- package/esm/utils/toSentenceCase.js +1 -1
- package/esm/utils/uniqBy.js +0 -2
- package/esm/utils/useForwardedRef.js +0 -3
- package/esm/utils/useLinkProps.js +1 -7
- package/esm/utils/useTriggerInputChange.js +2 -3
- package/package.json +1 -1
- package/satellite.min.css +1 -1
- package/scss/colors.scss +16 -16
package/cjs/Input/Input.js
CHANGED
@@ -1,50 +1,29 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
4
|
-
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
8
7
|
exports["default"] = exports.Input = void 0;
|
9
|
-
|
10
8
|
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
|
11
|
-
|
12
9
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
13
|
-
|
14
10
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
15
|
-
|
16
11
|
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
17
|
-
|
18
12
|
var _clsx = _interopRequireDefault(require("clsx"));
|
19
|
-
|
20
13
|
var _react = require("react");
|
21
|
-
|
22
14
|
var _reactFeather = require("react-feather");
|
23
|
-
|
24
15
|
var _Button = require("../Button");
|
25
|
-
|
26
16
|
var _useFieldState2 = _interopRequireDefault(require("../Field/useFieldState"));
|
27
|
-
|
28
17
|
var _Satellite = require("../Satellite");
|
29
|
-
|
30
18
|
var _satellitePrefixer = _interopRequireDefault(require("../styles/helpers/satellitePrefixer"));
|
31
|
-
|
32
19
|
var _isNil = _interopRequireDefault(require("../utils/isNil"));
|
33
|
-
|
34
20
|
var _useForwardedRef3 = _interopRequireDefault(require("../utils/useForwardedRef"));
|
35
|
-
|
36
21
|
var _useTriggerInputChange = _interopRequireDefault(require("../utils/useTriggerInputChange"));
|
37
|
-
|
38
22
|
var _jsxRuntime = require("react/jsx-runtime");
|
39
|
-
|
40
23
|
var _excluded = ["className", "style", "startIcon", "endItem", "disabled", "readOnly", "clearable", "type", "variant", "locale"];
|
41
|
-
|
42
24
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14;
|
43
|
-
|
44
25
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
45
|
-
|
46
26
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2["default"])(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
47
|
-
|
48
27
|
var DEFAULT_INPUT_LOCALE = {
|
49
28
|
clearInput: "Clear input",
|
50
29
|
increment: "Increment",
|
@@ -60,25 +39,23 @@ var VARIANT_CLASSNAMES = {
|
|
60
39
|
medium: (0, _satellitePrefixer["default"])(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2["default"])(["input-medium"]))),
|
61
40
|
large: (0, _satellitePrefixer["default"])(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2["default"])(["input-large"])))
|
62
41
|
};
|
63
|
-
|
64
42
|
var SearchIcon = function SearchIcon(props) {
|
65
43
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactFeather.Search, _objectSpread(_objectSpread({}, props), {}, {
|
66
44
|
role: "img",
|
67
45
|
"aria-label": "Search Icon"
|
68
46
|
}));
|
69
47
|
};
|
70
|
-
|
71
48
|
var InvalidIcon = function InvalidIcon() {
|
72
49
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactFeather.X, {
|
73
50
|
className: (0, _satellitePrefixer["default"])(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2["default"])(["mr-4 h-4 w-4 text-white bg-red-700 p-px rounded-full"])))
|
74
51
|
});
|
75
52
|
};
|
76
|
-
|
77
53
|
var ValidatedIcon = function ValidatedIcon() {
|
78
54
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactFeather.Check, {
|
79
|
-
className: (0, _satellitePrefixer["default"])(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2["default"])(["mr-4 h-4 w-4 text-white bg-accent-
|
55
|
+
className: (0, _satellitePrefixer["default"])(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2["default"])(["mr-4 h-4 w-4 text-white bg-accent-600 p-px rounded-full"])))
|
80
56
|
});
|
81
57
|
};
|
58
|
+
|
82
59
|
/**
|
83
60
|
* Use text fields to help users enter, select, and search for text. Text fields are normally found within a form but can also be part of a modal, search, or card
|
84
61
|
*
|
@@ -86,50 +63,40 @@ var ValidatedIcon = function ValidatedIcon() {
|
|
86
63
|
* #### Number input
|
87
64
|
* - **Stepper (optional)**: consider using a stepper (number control) to let users increase or decrease the value of the input. This is an optional part of the number field so only use based on what you think will help the user
|
88
65
|
*/
|
89
|
-
|
90
|
-
|
91
66
|
var Input = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, externalRef) {
|
92
67
|
var className = _ref.className,
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
68
|
+
style = _ref.style,
|
69
|
+
startIcon = _ref.startIcon,
|
70
|
+
endItem = _ref.endItem,
|
71
|
+
disabled = _ref.disabled,
|
72
|
+
readOnly = _ref.readOnly,
|
73
|
+
clearableProp = _ref.clearable,
|
74
|
+
_ref$type = _ref.type,
|
75
|
+
type = _ref$type === void 0 ? "text" : _ref$type,
|
76
|
+
_ref$variant = _ref.variant,
|
77
|
+
variant = _ref$variant === void 0 ? "medium" : _ref$variant,
|
78
|
+
propsLocale = _ref.locale,
|
79
|
+
inputProps = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
|
105
80
|
var contextLocale = (0, _Satellite.useLocale)("input");
|
106
|
-
|
107
81
|
var locale = _objectSpread(_objectSpread(_objectSpread({}, DEFAULT_INPUT_LOCALE), contextLocale), propsLocale);
|
108
|
-
|
109
82
|
var _useState = (0, _react.useState)(false),
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
83
|
+
_useState2 = (0, _slicedToArray2["default"])(_useState, 2),
|
84
|
+
focused = _useState2[0],
|
85
|
+
setFocused = _useState2[1];
|
114
86
|
var _useForwardedRef = (0, _useForwardedRef3["default"])(externalRef),
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
87
|
+
_useForwardedRef2 = (0, _slicedToArray2["default"])(_useForwardedRef, 2),
|
88
|
+
inputRefCallback = _useForwardedRef2[0],
|
89
|
+
inputRef = _useForwardedRef2[1];
|
119
90
|
var triggerInputChange = (0, _useTriggerInputChange["default"])(inputRef);
|
120
|
-
|
121
91
|
var _useFieldState = (0, _useFieldState2["default"])(),
|
122
|
-
|
123
|
-
|
92
|
+
status = _useFieldState.status;
|
124
93
|
var isControlled = ("value" in inputProps);
|
125
|
-
|
126
94
|
var _useState3 = (0, _react.useState)(function () {
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
95
|
+
return isControlled ? inputProps.value : inputProps.defaultValue;
|
96
|
+
}),
|
97
|
+
_useState4 = (0, _slicedToArray2["default"])(_useState3, 2),
|
98
|
+
internalValue = _useState4[0],
|
99
|
+
setInternalValue = _useState4[1];
|
133
100
|
var isValueEmpty = typeof internalValue !== "number" && !(internalValue !== null && internalValue !== void 0 && internalValue.length);
|
134
101
|
(0, _react.useEffect)(function () {
|
135
102
|
if (isControlled) {
|
@@ -144,7 +111,6 @@ var Input = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, externalRef) {
|
|
144
111
|
style: style,
|
145
112
|
onClick: function onClick() {
|
146
113
|
var _inputRef$current;
|
147
|
-
|
148
114
|
(_inputRef$current = inputRef.current) === null || _inputRef$current === void 0 ? void 0 : _inputRef$current.focus();
|
149
115
|
},
|
150
116
|
children: [Icon && /*#__PURE__*/(0, _jsxRuntime.jsx)(Icon, {
|
@@ -159,22 +125,18 @@ var Input = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, externalRef) {
|
|
159
125
|
disabled: disabled,
|
160
126
|
onChange: function onChange(evt) {
|
161
127
|
var _inputProps$onChange;
|
162
|
-
|
163
128
|
(_inputProps$onChange = inputProps.onChange) === null || _inputProps$onChange === void 0 ? void 0 : _inputProps$onChange.call(inputProps, evt);
|
164
|
-
|
165
129
|
if (!isControlled) {
|
166
130
|
setInternalValue(evt.target.value);
|
167
131
|
}
|
168
132
|
},
|
169
133
|
onFocus: function onFocus(evt) {
|
170
134
|
var _inputProps$onFocus;
|
171
|
-
|
172
135
|
setFocused(true);
|
173
136
|
(_inputProps$onFocus = inputProps.onFocus) === null || _inputProps$onFocus === void 0 ? void 0 : _inputProps$onFocus.call(inputProps, evt);
|
174
137
|
},
|
175
138
|
onBlur: function onBlur(evt) {
|
176
139
|
var _inputProps$onBlur;
|
177
|
-
|
178
140
|
setFocused(false);
|
179
141
|
(_inputProps$onBlur = inputProps.onBlur) === null || _inputProps$onBlur === void 0 ? void 0 : _inputProps$onBlur.call(inputProps, evt);
|
180
142
|
}
|
@@ -203,15 +165,12 @@ var Input = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, externalRef) {
|
|
203
165
|
"aria-label": locale.increment,
|
204
166
|
onClick: function onClick() {
|
205
167
|
var _inputRef$current$val, _inputRef$current2;
|
206
|
-
|
207
168
|
var step = inputProps.step ? parseFloat(String(inputProps.step)) : 1;
|
208
169
|
var max = (0, _isNil["default"])(inputProps.max) ? Number.MAX_SAFE_INTEGER : parseFloat(String(inputProps.max));
|
209
170
|
var currentValue = parseFloat((_inputRef$current$val = (_inputRef$current2 = inputRef.current) === null || _inputRef$current2 === void 0 ? void 0 : _inputRef$current2.value) !== null && _inputRef$current$val !== void 0 ? _inputRef$current$val : "0");
|
210
|
-
|
211
171
|
if (Number.isNaN(currentValue)) {
|
212
172
|
currentValue = 0;
|
213
173
|
}
|
214
|
-
|
215
174
|
if (currentValue + step <= max) {
|
216
175
|
triggerInputChange(String(currentValue + step));
|
217
176
|
} else {
|
@@ -229,15 +188,12 @@ var Input = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, externalRef) {
|
|
229
188
|
"aria-label": locale.decrement,
|
230
189
|
onClick: function onClick() {
|
231
190
|
var _inputRef$current$val2, _inputRef$current3;
|
232
|
-
|
233
191
|
var step = inputProps.step ? parseFloat(String(inputProps.step)) : 1;
|
234
192
|
var min = (0, _isNil["default"])(inputProps.min) ? Number.MIN_SAFE_INTEGER : parseFloat(String(inputProps.min));
|
235
193
|
var currentValue = parseFloat((_inputRef$current$val2 = (_inputRef$current3 = inputRef.current) === null || _inputRef$current3 === void 0 ? void 0 : _inputRef$current3.value) !== null && _inputRef$current$val2 !== void 0 ? _inputRef$current$val2 : "0");
|
236
|
-
|
237
194
|
if (Number.isNaN(currentValue)) {
|
238
195
|
currentValue = 0;
|
239
196
|
}
|
240
|
-
|
241
197
|
if (currentValue - step >= min) {
|
242
198
|
triggerInputChange(String(currentValue - step));
|
243
199
|
} else {
|
@@ -2,14 +2,11 @@
|
|
2
2
|
|
3
3
|
// @ts-check
|
4
4
|
var plugin = require("tailwindcss/plugin");
|
5
|
-
|
6
5
|
var disabledColor = require("../styles/disabledColor");
|
7
|
-
|
8
6
|
var rgba = require("../styles/rgba");
|
9
|
-
|
10
7
|
var inputPlugin = plugin(function (_ref) {
|
11
8
|
var addComponents = _ref.addComponents,
|
12
|
-
|
9
|
+
theme = _ref.theme;
|
13
10
|
addComponents({
|
14
11
|
".input": {
|
15
12
|
position: "relative",
|
package/cjs/Input/index.js
CHANGED
@@ -1,7 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _typeof = require("@babel/runtime/helpers/typeof");
|
4
|
-
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
@@ -12,9 +11,7 @@ Object.defineProperty(exports, "default", {
|
|
12
11
|
return _Input["default"];
|
13
12
|
}
|
14
13
|
});
|
15
|
-
|
16
14
|
var _Input = _interopRequireWildcard(require("./Input"));
|
17
|
-
|
18
15
|
Object.keys(_Input).forEach(function (key) {
|
19
16
|
if (key === "default" || key === "__esModule") return;
|
20
17
|
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
@@ -26,7 +23,5 @@ Object.keys(_Input).forEach(function (key) {
|
|
26
23
|
}
|
27
24
|
});
|
28
25
|
});
|
29
|
-
|
30
26
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
31
|
-
|
32
27
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
package/cjs/Insert/Insert.js
CHANGED
@@ -1,24 +1,16 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
4
|
-
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
8
7
|
exports["default"] = exports.Insert = void 0;
|
9
|
-
|
10
8
|
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
11
|
-
|
12
9
|
var _Badge = _interopRequireDefault(require("../Badge"));
|
13
|
-
|
14
10
|
var _satellitePrefixer = _interopRequireDefault(require("../styles/helpers/satellitePrefixer"));
|
15
|
-
|
16
11
|
var _onlyText = _interopRequireDefault(require("../utils/onlyText"));
|
17
|
-
|
18
12
|
var _jsxRuntime = require("react/jsx-runtime");
|
19
|
-
|
20
13
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
21
|
-
|
22
14
|
/**
|
23
15
|
* Put more emphasis on side content.
|
24
16
|
|
@@ -52,8 +44,8 @@ var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
52
44
|
*/
|
53
45
|
var Insert = function Insert(_ref) {
|
54
46
|
var title = _ref.title,
|
55
|
-
|
56
|
-
|
47
|
+
contexts = _ref.contexts,
|
48
|
+
children = _ref.children;
|
57
49
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("aside", {
|
58
50
|
"aria-label": (0, _onlyText["default"])(title),
|
59
51
|
className: (0, _satellitePrefixer["default"])(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["inline-flex flex-col self-start p-4 bg-grey-100 rounded"]))),
|
@@ -61,12 +53,11 @@ var Insert = function Insert(_ref) {
|
|
61
53
|
className: (0, _satellitePrefixer["default"])(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["block space-x-2 mb-4"]))),
|
62
54
|
children: contexts.map(function (context, idx) {
|
63
55
|
var _ref2 = typeof context === "string" ? {
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
56
|
+
label: context
|
57
|
+
} : context,
|
58
|
+
label = _ref2.label,
|
59
|
+
_ref2$variant = _ref2.variant,
|
60
|
+
variant = _ref2$variant === void 0 ? "grey" : _ref2$variant;
|
70
61
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Badge["default"], {
|
71
62
|
variant: variant,
|
72
63
|
children: label
|
@@ -83,7 +74,6 @@ var Insert = function Insert(_ref) {
|
|
83
74
|
})]
|
84
75
|
});
|
85
76
|
};
|
86
|
-
|
87
77
|
exports.Insert = Insert;
|
88
78
|
var _default = Insert;
|
89
79
|
exports["default"] = _default;
|
package/cjs/Insert/index.js
CHANGED
@@ -1,7 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _typeof = require("@babel/runtime/helpers/typeof");
|
4
|
-
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
@@ -12,9 +11,7 @@ Object.defineProperty(exports, "default", {
|
|
12
11
|
return _Insert["default"];
|
13
12
|
}
|
14
13
|
});
|
15
|
-
|
16
14
|
var _Insert = _interopRequireWildcard(require("./Insert"));
|
17
|
-
|
18
15
|
Object.keys(_Insert).forEach(function (key) {
|
19
16
|
if (key === "default" || key === "__esModule") return;
|
20
17
|
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
@@ -26,7 +23,5 @@ Object.keys(_Insert).forEach(function (key) {
|
|
26
23
|
}
|
27
24
|
});
|
28
25
|
});
|
29
|
-
|
30
26
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
31
|
-
|
32
27
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
@@ -1,24 +1,18 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
4
|
-
|
5
4
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
6
|
-
|
7
5
|
// @ts-check
|
8
6
|
var plugin = require("tailwindcss/plugin");
|
9
|
-
|
10
7
|
var disabledColor = require("../styles/disabledColor");
|
11
|
-
|
12
8
|
var _require = require("../styles/helpers/icons"),
|
13
|
-
|
14
|
-
|
15
|
-
|
9
|
+
toBG = _require.toBG,
|
10
|
+
selectIconBG = _require.selectIconBG;
|
16
11
|
var rgba = require("../styles/rgba");
|
17
|
-
|
18
12
|
module.exports = plugin(function (_ref) {
|
19
13
|
var addComponents = _ref.addComponents,
|
20
|
-
|
21
|
-
|
14
|
+
prefix = _ref.prefix,
|
15
|
+
theme = _ref.theme;
|
22
16
|
addComponents((0, _defineProperty2["default"])({}, prefix(".instantsearch"), {
|
23
17
|
// SearchBox widget
|
24
18
|
// ----------------------------------------
|
@@ -1,26 +1,17 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
4
|
-
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
8
7
|
exports.KeyboardKey = void 0;
|
9
|
-
|
10
8
|
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
11
|
-
|
12
9
|
var _clsx = _interopRequireDefault(require("clsx"));
|
13
|
-
|
14
10
|
var _react = require("react");
|
15
|
-
|
16
11
|
var _reactFeather = require("react-feather");
|
17
|
-
|
18
12
|
var _satellitePrefixer = _interopRequireDefault(require("../styles/helpers/satellitePrefixer"));
|
19
|
-
|
20
13
|
var _jsxRuntime = require("react/jsx-runtime");
|
21
|
-
|
22
14
|
var _templateObject;
|
23
|
-
|
24
15
|
var KEY_MAPPINGS = {
|
25
16
|
up: _reactFeather.ArrowUp,
|
26
17
|
down: _reactFeather.ArrowDown,
|
@@ -29,10 +20,9 @@ var KEY_MAPPINGS = {
|
|
29
20
|
enter: _reactFeather.CornerDownLeft,
|
30
21
|
escape: "esc"
|
31
22
|
};
|
32
|
-
|
33
23
|
var KeyboardKey = function KeyboardKey(_ref) {
|
34
24
|
var className = _ref.className,
|
35
|
-
|
25
|
+
value = _ref.value;
|
36
26
|
var mappedValue = KEY_MAPPINGS[value];
|
37
27
|
var displayed = !mappedValue ? value : typeof mappedValue === "string" ? mappedValue : /*#__PURE__*/(0, _react.createElement)(mappedValue, {
|
38
28
|
"aria-label": value,
|
@@ -44,5 +34,4 @@ var KeyboardKey = function KeyboardKey(_ref) {
|
|
44
34
|
children: displayed
|
45
35
|
});
|
46
36
|
};
|
47
|
-
|
48
37
|
exports.KeyboardKey = KeyboardKey;
|
@@ -2,10 +2,9 @@
|
|
2
2
|
|
3
3
|
// @ts-check
|
4
4
|
var plugin = require("tailwindcss/plugin");
|
5
|
-
|
6
5
|
var keyboardKeyPlugin = plugin(function (_ref) {
|
7
6
|
var addComponents = _ref.addComponents,
|
8
|
-
|
7
|
+
theme = _ref.theme;
|
9
8
|
addComponents({
|
10
9
|
".keyboard-key": {
|
11
10
|
borderRadius: theme("borderRadius.DEFAULT"),
|
package/cjs/KeyboardKey/index.js
CHANGED
@@ -10,9 +10,7 @@ Object.defineProperty(exports, "default", {
|
|
10
10
|
return _KeyboardKey.KeyboardKey;
|
11
11
|
}
|
12
12
|
});
|
13
|
-
|
14
13
|
var _KeyboardKey = require("./KeyboardKey");
|
15
|
-
|
16
14
|
Object.keys(_KeyboardKey).forEach(function (key) {
|
17
15
|
if (key === "default" || key === "__esModule") return;
|
18
16
|
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
package/cjs/Link/BaseLink.js
CHANGED
@@ -1,32 +1,22 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
4
|
-
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
8
7
|
exports["default"] = exports.BaseLink = void 0;
|
9
|
-
|
10
8
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
11
|
-
|
12
9
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
13
|
-
|
14
10
|
var _react = require("react");
|
15
|
-
|
16
11
|
var _useLinkProps = _interopRequireDefault(require("../utils/useLinkProps"));
|
17
|
-
|
18
12
|
var _jsxRuntime = require("react/jsx-runtime");
|
19
|
-
|
20
13
|
var _excluded = ["href", "onClick"];
|
21
|
-
|
22
14
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
23
|
-
|
24
15
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2["default"])(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
25
|
-
|
26
16
|
var BaseLink = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
27
17
|
var href = _ref.href,
|
28
|
-
|
29
|
-
|
18
|
+
onClick = _ref.onClick,
|
19
|
+
anchorProps = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
|
30
20
|
var linkProps = (0, _useLinkProps["default"])(_objectSpread(_objectSpread({}, anchorProps), {}, {
|
31
21
|
href: href,
|
32
22
|
onClick: onClick
|
package/cjs/Link/ButtonLink.js
CHANGED
@@ -1,50 +1,36 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
4
|
-
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
8
7
|
exports["default"] = exports.ButtonLink = void 0;
|
9
|
-
|
10
8
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
11
|
-
|
12
9
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
13
|
-
|
14
10
|
var _reactFeather = require("react-feather");
|
15
|
-
|
16
11
|
var _Button = _interopRequireDefault(require("../Button/Button"));
|
17
|
-
|
18
12
|
var _useLinkProps = _interopRequireDefault(require("../utils/useLinkProps"));
|
19
|
-
|
20
13
|
var _jsxRuntime = require("react/jsx-runtime");
|
21
|
-
|
22
14
|
var _excluded = ["endIcon", "href", "onClick"];
|
23
|
-
|
24
15
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
25
|
-
|
26
16
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2["default"])(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
27
|
-
|
28
17
|
var ButtonLink = function ButtonLink(_ref) {
|
29
18
|
var EndIcon = _ref.endIcon,
|
30
|
-
|
31
|
-
|
32
|
-
|
19
|
+
href = _ref.href,
|
20
|
+
onClick = _ref.onClick,
|
21
|
+
props = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
|
33
22
|
var linkProps = (0, _useLinkProps["default"])(_objectSpread(_objectSpread({}, props), {}, {
|
34
23
|
href: href,
|
35
24
|
onClick: onClick
|
36
25
|
}));
|
37
|
-
|
38
26
|
if (linkProps.target === "_blank" && EndIcon === undefined) {
|
39
27
|
EndIcon = _reactFeather.ExternalLink;
|
40
28
|
}
|
41
|
-
|
42
29
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Button["default"], _objectSpread(_objectSpread(_objectSpread({}, props), linkProps), {}, {
|
43
30
|
endIcon: EndIcon,
|
44
31
|
as: "a"
|
45
32
|
}));
|
46
33
|
};
|
47
|
-
|
48
34
|
exports.ButtonLink = ButtonLink;
|
49
35
|
var _default = ButtonLink;
|
50
36
|
exports["default"] = _default;
|
@@ -1,32 +1,22 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
4
|
-
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
8
7
|
exports["default"] = exports.IconButtonLink = void 0;
|
9
|
-
|
10
8
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
11
|
-
|
12
9
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
13
|
-
|
14
10
|
var _IconButton = _interopRequireDefault(require("../Button/IconButton"));
|
15
|
-
|
16
11
|
var _useLinkProps = _interopRequireDefault(require("../utils/useLinkProps"));
|
17
|
-
|
18
12
|
var _jsxRuntime = require("react/jsx-runtime");
|
19
|
-
|
20
13
|
var _excluded = ["href", "onClick"];
|
21
|
-
|
22
14
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
23
|
-
|
24
15
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2["default"])(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
25
|
-
|
26
16
|
var IconButtonLink = function IconButtonLink(_ref) {
|
27
17
|
var href = _ref.href,
|
28
|
-
|
29
|
-
|
18
|
+
onClick = _ref.onClick,
|
19
|
+
props = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
|
30
20
|
var linkProps = (0, _useLinkProps["default"])(_objectSpread(_objectSpread({}, props), {}, {
|
31
21
|
href: href,
|
32
22
|
onClick: onClick
|
@@ -35,7 +25,6 @@ var IconButtonLink = function IconButtonLink(_ref) {
|
|
35
25
|
as: "a"
|
36
26
|
}));
|
37
27
|
};
|
38
|
-
|
39
28
|
exports.IconButtonLink = IconButtonLink;
|
40
29
|
var _default = IconButtonLink;
|
41
30
|
exports["default"] = _default;
|
package/cjs/Link/Link.js
CHANGED
@@ -1,56 +1,39 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
4
|
-
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
8
7
|
exports["default"] = exports.Link = void 0;
|
9
|
-
|
10
8
|
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
11
|
-
|
12
9
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
13
|
-
|
14
10
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
15
|
-
|
16
11
|
var _clsx = _interopRequireDefault(require("clsx"));
|
17
|
-
|
18
12
|
var _react = require("react");
|
19
|
-
|
20
13
|
var _reactFeather = require("react-feather");
|
21
|
-
|
22
14
|
var _satellitePrefixer = _interopRequireDefault(require("../styles/helpers/satellitePrefixer"));
|
23
|
-
|
24
15
|
var _useLinkProps = _interopRequireDefault(require("../utils/useLinkProps"));
|
25
|
-
|
26
16
|
var _jsxRuntime = require("react/jsx-runtime");
|
27
|
-
|
28
17
|
var _templateObject, _templateObject2, _templateObject3;
|
29
|
-
|
30
18
|
var _excluded = ["className", "children", "startIcon", "endIcon", "href", "onClick"];
|
31
|
-
|
32
19
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
33
|
-
|
34
20
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2["default"])(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
35
|
-
|
36
21
|
var Link = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
37
22
|
var className = _ref.className,
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
23
|
+
children = _ref.children,
|
24
|
+
StartIcon = _ref.startIcon,
|
25
|
+
EndIcon = _ref.endIcon,
|
26
|
+
href = _ref.href,
|
27
|
+
onClick = _ref.onClick,
|
28
|
+
anchorProps = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
|
44
29
|
var linkProps = (0, _useLinkProps["default"])(_objectSpread(_objectSpread({}, anchorProps), {}, {
|
45
30
|
href: href,
|
46
31
|
onClick: onClick
|
47
32
|
}));
|
48
33
|
var isExternalLink = linkProps.target === "_blank" && EndIcon === undefined;
|
49
|
-
|
50
34
|
if (isExternalLink) {
|
51
35
|
EndIcon = _reactFeather.ExternalLink;
|
52
36
|
}
|
53
|
-
|
54
37
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("a", _objectSpread(_objectSpread(_objectSpread({}, anchorProps), linkProps), {}, {
|
55
38
|
ref: ref,
|
56
39
|
className: (0, _clsx["default"])((0, _satellitePrefixer["default"])(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["typo-link inline-flex items-center"]))), className),
|