@sprinklrjs/spaceweb 14.11.4 → 14.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ClientOnly.d.ts +1 -1
- package/asyncSelect/asyncSelect.d.ts +2 -2
- package/asyncSelect/asyncSelect.js +1 -1
- package/asyncSelect/groupedAsyncSelect.d.ts +1 -1
- package/asyncSelect/groupedAsyncSelect.js +1 -1
- package/asyncSelect/hooks/useAsyncOptions.d.ts +1 -1
- package/asyncSelect/hooks/useAsyncOptions.js +4 -5
- package/asyncSelect/hooks/useAsyncSelect.d.ts +1 -1
- package/asyncSelect/hooks/useAsyncSelectAdapter.d.ts +1 -1
- package/asyncSelect/hooks/useBaseAsyncSelect.js +1 -1
- package/asyncSelect/hooks/useCreateOption.d.ts +2 -2
- package/asyncSelect/hooks/useCreateOption.js +3 -6
- package/asyncSelect/hooks/useGroupAsyncSelectAdapter.d.ts +3 -3
- package/asyncSelect/hooks/useGroupedAsyncSelect.d.ts +1 -1
- package/asyncSelect/hooks/useInputChangeHandler.d.ts +2 -2
- package/asyncSelect/hooks/useResolveSelectedOptions.d.ts +3 -3
- package/asyncSelect/hooks/useResolveSelectedOptions.js +2 -4
- package/asyncSelect/types.d.ts +5 -6
- package/asyncSelect/utils/defaultCreateOption.d.ts +1 -1
- package/avatar/avatar.d.ts +2 -2
- package/avatar/components/grid-variant.d.ts +2 -2
- package/avatar/components/grid-variant.js +0 -1
- package/avatar/components/linear-variant.js +0 -2
- package/avatar/constants.d.ts +1 -1
- package/avatar/hooks/useAvatarGroupChildren.d.ts +2 -2
- package/avatar/hooks/useAvatarGroupChildren.js +0 -1
- package/avatar/styled-component.d.ts +1 -1
- package/avatar/styled-component.js +1 -3
- package/avatar/types.d.ts +2 -2
- package/avatar/useAvatarColor.js +0 -1
- package/avatar/utils/avatarGroupHelpers.d.ts +1 -1
- package/avatar/utils/cleanupDisplayName.js +2 -2
- package/badge/badge.d.ts +2 -2
- package/badge/types.d.ts +2 -2
- package/banner/banner.d.ts +1 -1
- package/banner/banner.js +2 -2
- package/banner/types.d.ts +3 -3
- package/base-button/styled-components.d.ts +1 -1
- package/base-button/types.d.ts +3 -3
- package/baseui/accordion/panel.js +1 -3
- package/baseui/accordion/stateful-panel-container.js +1 -2
- package/baseui/accordion/stateless-accordion.js +4 -6
- package/baseui/datepicker/calendar-header.js +2 -4
- package/baseui/datepicker/calendar.d.ts +1 -1
- package/baseui/datepicker/calendar.js +2 -3
- package/baseui/datepicker/day.d.ts +1 -1
- package/baseui/datepicker/day.js +1 -1
- package/baseui/datepicker/styled-components.js +1 -1
- package/baseui/datepicker/utils/date-helpers.js +4 -4
- package/baseui/datepicker/utils/index.js +7 -12
- package/baseui/helpers/overrides.d.ts +2 -2
- package/baseui/helpers/overrides.js +4 -7
- package/baseui/layer/layer.js +2 -1
- package/baseui/layer/layers-manager.js +2 -1
- package/baseui/layer/tether.js +1 -0
- package/baseui/layer/types.d.ts +1 -1
- package/baseui/modal/close-icon.js +9 -1
- package/baseui/modal/modal.d.ts +3 -3
- package/baseui/modal/modal.js +6 -8
- package/baseui/popover/popover.js +3 -4
- package/baseui/popover/stateful-container.js +1 -1
- package/baseui/popover/utils.js +1 -3
- package/baseui/select/autosize-input.d.ts +1 -1
- package/baseui/select/autosize-input.js +1 -1
- package/baseui/select/dropdown.js +1 -1
- package/baseui/select/select-component.d.ts +3 -4
- package/baseui/select/select-component.js +15 -10
- package/baseui/select/stateful-select-container.js +4 -8
- package/baseui/select/types.d.ts +4 -5
- package/baseui/select/utils/index.js +2 -6
- package/baseui/select/value.js +5 -1
- package/baseui/timepicker/timepicker.js +6 -7
- package/baseui/timepicker/types.d.ts +1 -1
- package/baseui/tree-view/index.d.ts +1 -1
- package/baseui/tree-view/tree-label-interactable.d.ts +1 -1
- package/baseui/tree-view/tree-label.js +1 -1
- package/baseui/tree-view/tree-node.js +1 -1
- package/baseui/tree-view/tree-view.js +1 -2
- package/baseui/tree-view/utils.js +3 -7
- package/baseui/utils/focusVisible.js +1 -1
- package/box/types.d.ts +2 -2
- package/breadcrumb/breadcrumb-ellipsis.d.ts +1 -1
- package/breadcrumb/breadcrumb-item.d.ts +1 -1
- package/breadcrumb/breadcrumb-item.js +0 -1
- package/breadcrumb/breadcrumb.d.ts +1 -1
- package/breadcrumb/breadcrumb.js +2 -1
- package/breadcrumb/types.d.ts +5 -4
- package/button/Button.js +2 -2
- package/button/CitationButton/CitationButton.d.ts +1 -1
- package/button/CitationButton/types.d.ts +1 -1
- package/button/DropdownEnhancer.d.ts +3 -3
- package/button/DropdownEnhancer.js +0 -1
- package/button/IconButton/IconButton.d.ts +1 -1
- package/button/IconButton/styled-components.d.ts +2 -2
- package/button/IconButton/types.d.ts +3 -3
- package/button/IconTextButton/styled-components.d.ts +1 -1
- package/button/IconTextButton/styled-components.js +2 -3
- package/button/IconTextButton/types.d.ts +3 -3
- package/button/button-enhancers.d.ts +1 -1
- package/button/helpers.d.ts +3 -3
- package/button/styled-components.d.ts +2 -2
- package/button/types.d.ts +6 -7
- package/button-group/ButtonGroup.d.ts +1 -1
- package/button-group/helpers.d.ts +2 -2
- package/button-group/styled-components.d.ts +3 -3
- package/button-group/types.d.ts +7 -8
- package/checkbox/checkbox.js +1 -3
- package/checkbox/hooks/useStatefulCheckbox.d.ts +1 -1
- package/checkbox/styled-components.d.ts +2 -2
- package/color-picker/ColorPalette.d.ts +1 -1
- package/color-picker/ColorPalette.js +1 -1
- package/color-picker/Swatch.d.ts +3 -3
- package/color-picker/types.d.ts +2 -2
- package/container/ContainerProps.d.ts +1 -1
- package/currency/Currency.d.ts +1 -1
- package/currency/constants.d.ts +1 -1
- package/currency/types.d.ts +1 -1
- package/currency/useCurrency.d.ts +1 -1
- package/currency/utils.d.ts +1 -1
- package/date-input/DateInput.d.ts +1 -1
- package/date-input/types.d.ts +5 -5
- package/date-picker/Calendar.d.ts +2 -2
- package/date-picker/DateInput.js +1 -1
- package/date-picker/DatePicker.d.ts +2 -2
- package/date-picker/StatelessDatePicker.js +1 -1
- package/date-picker/TimeInput.d.ts +3 -3
- package/date-picker/TimezoneDisplay.d.ts +1 -1
- package/date-picker/stateful-container.d.ts +2 -2
- package/date-picker/stateful-container.js +1 -1
- package/date-picker/styled-components.d.ts +2 -2
- package/date-picker/styled-components.js +1 -1
- package/date-picker/types.d.ts +6 -6
- package/date-picker/utils.js +0 -3
- package/date-time/DateTime.d.ts +1 -1
- package/date-time/types.d.ts +1 -1
- package/date-time/useDateTime.d.ts +1 -1
- package/esm/ClientOnly.d.ts +1 -1
- package/esm/asyncSelect/asyncSelect.d.ts +2 -2
- package/esm/asyncSelect/asyncSelect.js +1 -1
- package/esm/asyncSelect/groupedAsyncSelect.d.ts +1 -1
- package/esm/asyncSelect/groupedAsyncSelect.js +1 -1
- package/esm/asyncSelect/hooks/useAsyncOptions.d.ts +1 -1
- package/esm/asyncSelect/hooks/useAsyncOptions.js +4 -5
- package/esm/asyncSelect/hooks/useAsyncSelect.d.ts +1 -1
- package/esm/asyncSelect/hooks/useAsyncSelectAdapter.d.ts +1 -1
- package/esm/asyncSelect/hooks/useBaseAsyncSelect.js +1 -1
- package/esm/asyncSelect/hooks/useCreateOption.d.ts +2 -2
- package/esm/asyncSelect/hooks/useCreateOption.js +3 -6
- package/esm/asyncSelect/hooks/useGroupAsyncSelectAdapter.d.ts +3 -3
- package/esm/asyncSelect/hooks/useGroupedAsyncSelect.d.ts +1 -1
- package/esm/asyncSelect/hooks/useInputChangeHandler.d.ts +2 -2
- package/esm/asyncSelect/hooks/useResolveSelectedOptions.d.ts +3 -3
- package/esm/asyncSelect/hooks/useResolveSelectedOptions.js +2 -4
- package/esm/asyncSelect/types.d.ts +5 -6
- package/esm/asyncSelect/utils/defaultCreateOption.d.ts +1 -1
- package/esm/avatar/avatar.d.ts +2 -2
- package/esm/avatar/components/grid-variant.d.ts +2 -2
- package/esm/avatar/components/grid-variant.js +0 -1
- package/esm/avatar/components/linear-variant.js +0 -2
- package/esm/avatar/constants.d.ts +1 -1
- package/esm/avatar/hooks/useAvatarGroupChildren.d.ts +2 -2
- package/esm/avatar/hooks/useAvatarGroupChildren.js +0 -1
- package/esm/avatar/styled-component.d.ts +1 -1
- package/esm/avatar/styled-component.js +1 -3
- package/esm/avatar/types.d.ts +2 -2
- package/esm/avatar/useAvatarColor.js +0 -1
- package/esm/avatar/utils/avatarGroupHelpers.d.ts +1 -1
- package/esm/avatar/utils/cleanupDisplayName.js +2 -2
- package/esm/badge/badge.d.ts +2 -2
- package/esm/badge/types.d.ts +2 -2
- package/esm/banner/banner.d.ts +1 -1
- package/esm/banner/banner.js +2 -2
- package/esm/banner/types.d.ts +3 -3
- package/esm/base-button/styled-components.d.ts +1 -1
- package/esm/base-button/types.d.ts +3 -3
- package/esm/baseui/accordion/panel.js +1 -3
- package/esm/baseui/accordion/stateful-panel-container.js +1 -2
- package/esm/baseui/accordion/stateless-accordion.js +4 -6
- package/esm/baseui/datepicker/calendar-header.js +2 -4
- package/esm/baseui/datepicker/calendar.d.ts +1 -1
- package/esm/baseui/datepicker/calendar.js +2 -3
- package/esm/baseui/datepicker/day.d.ts +1 -1
- package/esm/baseui/datepicker/day.js +1 -1
- package/esm/baseui/datepicker/styled-components.js +1 -1
- package/esm/baseui/datepicker/utils/date-helpers.js +4 -4
- package/esm/baseui/datepicker/utils/index.js +7 -12
- package/esm/baseui/helpers/overrides.d.ts +2 -2
- package/esm/baseui/helpers/overrides.js +4 -7
- package/esm/baseui/layer/layer.js +2 -1
- package/esm/baseui/layer/layers-manager.js +2 -1
- package/esm/baseui/layer/tether.js +1 -0
- package/esm/baseui/layer/types.d.ts +1 -1
- package/esm/baseui/modal/close-icon.js +9 -1
- package/esm/baseui/modal/modal.d.ts +3 -3
- package/esm/baseui/modal/modal.js +6 -8
- package/esm/baseui/popover/popover.js +3 -4
- package/esm/baseui/popover/stateful-container.js +1 -1
- package/esm/baseui/popover/utils.js +1 -3
- package/esm/baseui/select/autosize-input.d.ts +1 -1
- package/esm/baseui/select/autosize-input.js +1 -1
- package/esm/baseui/select/dropdown.js +1 -1
- package/esm/baseui/select/select-component.d.ts +3 -4
- package/esm/baseui/select/select-component.js +15 -10
- package/esm/baseui/select/stateful-select-container.js +4 -8
- package/esm/baseui/select/types.d.ts +4 -5
- package/esm/baseui/select/utils/index.js +2 -6
- package/esm/baseui/select/value.js +5 -1
- package/esm/baseui/timepicker/timepicker.js +6 -7
- package/esm/baseui/timepicker/types.d.ts +1 -1
- package/esm/baseui/tree-view/index.d.ts +1 -1
- package/esm/baseui/tree-view/index.js +1 -1
- package/esm/baseui/tree-view/tree-label-interactable.d.ts +1 -1
- package/esm/baseui/tree-view/tree-label.js +1 -1
- package/esm/baseui/tree-view/tree-node.js +1 -1
- package/esm/baseui/tree-view/tree-view.js +1 -2
- package/esm/baseui/tree-view/utils.js +3 -7
- package/esm/baseui/utils/focusVisible.js +1 -1
- package/esm/box/types.d.ts +2 -2
- package/esm/breadcrumb/breadcrumb-ellipsis.d.ts +1 -1
- package/esm/breadcrumb/breadcrumb-item.d.ts +1 -1
- package/esm/breadcrumb/breadcrumb-item.js +0 -1
- package/esm/breadcrumb/breadcrumb.d.ts +1 -1
- package/esm/breadcrumb/breadcrumb.js +2 -1
- package/esm/breadcrumb/types.d.ts +5 -4
- package/esm/button/Button.js +2 -2
- package/esm/button/CitationButton/CitationButton.d.ts +1 -1
- package/esm/button/CitationButton/types.d.ts +1 -1
- package/esm/button/DropdownEnhancer.d.ts +3 -3
- package/esm/button/DropdownEnhancer.js +0 -1
- package/esm/button/IconButton/IconButton.d.ts +1 -1
- package/esm/button/IconButton/styled-components.d.ts +2 -2
- package/esm/button/IconButton/types.d.ts +3 -3
- package/esm/button/IconTextButton/styled-components.d.ts +1 -1
- package/esm/button/IconTextButton/styled-components.js +2 -3
- package/esm/button/IconTextButton/types.d.ts +3 -3
- package/esm/button/button-enhancers.d.ts +1 -1
- package/esm/button/helpers.d.ts +3 -3
- package/esm/button/styled-components.d.ts +2 -2
- package/esm/button/types.d.ts +6 -7
- package/esm/button-group/ButtonGroup.d.ts +1 -1
- package/esm/button-group/helpers.d.ts +2 -2
- package/esm/button-group/styled-components.d.ts +3 -3
- package/esm/button-group/types.d.ts +7 -8
- package/esm/checkbox/checkbox.js +1 -3
- package/esm/checkbox/hooks/useStatefulCheckbox.d.ts +1 -1
- package/esm/checkbox/styled-components.d.ts +2 -2
- package/esm/color-picker/ColorPalette.d.ts +1 -1
- package/esm/color-picker/ColorPalette.js +1 -1
- package/esm/color-picker/Swatch.d.ts +3 -3
- package/esm/color-picker/types.d.ts +2 -2
- package/esm/container/ContainerProps.d.ts +1 -1
- package/esm/currency/Currency.d.ts +1 -1
- package/esm/currency/constants.d.ts +1 -1
- package/esm/currency/types.d.ts +1 -1
- package/esm/currency/useCurrency.d.ts +1 -1
- package/esm/currency/utils.d.ts +1 -1
- package/esm/date-input/DateInput.d.ts +1 -1
- package/esm/date-input/types.d.ts +5 -5
- package/esm/date-picker/Calendar.d.ts +2 -2
- package/esm/date-picker/DateInput.js +1 -1
- package/esm/date-picker/DatePicker.d.ts +2 -2
- package/esm/date-picker/StatelessDatePicker.js +1 -1
- package/esm/date-picker/TimeInput.d.ts +3 -3
- package/esm/date-picker/TimezoneDisplay.d.ts +1 -1
- package/esm/date-picker/stateful-container.d.ts +2 -2
- package/esm/date-picker/stateful-container.js +1 -1
- package/esm/date-picker/styled-components.d.ts +2 -2
- package/esm/date-picker/styled-components.js +1 -1
- package/esm/date-picker/types.d.ts +6 -6
- package/esm/date-picker/utils.js +0 -3
- package/esm/date-time/DateTime.d.ts +1 -1
- package/esm/date-time/types.d.ts +1 -1
- package/esm/date-time/useDateTime.d.ts +1 -1
- package/esm/form-control/context.d.ts +1 -1
- package/esm/form-control/form-control.d.ts +1 -1
- package/esm/form-control/form-control.js +1 -1
- package/esm/form-control/info-icon.d.ts +6 -5
- package/esm/form-control/info-icon.js +0 -1
- package/esm/form-control/styled-component.js +2 -1
- package/esm/form-control/types.d.ts +3 -4
- package/esm/grid/Col.d.ts +2 -2
- package/esm/grid/Grid.d.ts +2 -2
- package/esm/grid/Grid.js +0 -3
- package/esm/grid/index.d.ts +1 -1
- package/esm/grid/types.d.ts +1 -1
- package/esm/helpers/ClearIconButton.d.ts +3 -3
- package/esm/helpers/ClearIconButton.js +1 -1
- package/esm/helpers/commonStyles.js +2 -3
- package/esm/helpers/intentHelper.d.ts +1 -1
- package/esm/helpers/longHandHelpers.d.ts +1 -1
- package/esm/helpers/themeHelpers.d.ts +2 -2
- package/esm/hooks/useAutoFocus.d.ts +2 -2
- package/esm/hooks/useAutoFocus.js +1 -0
- package/esm/hooks/useDebouncedEventHandler.d.ts +1 -1
- package/esm/hooks/useDebouncedEventHandler.js +0 -3
- package/esm/hooks/useHover.d.ts +1 -1
- package/esm/hooks/useMatchMedia.js +3 -2
- package/esm/hooks/useSVGAnimation.d.ts +2 -2
- package/esm/hooks/useTabsKeyboardNavigation.d.ts +1 -1
- package/esm/hooks/useTabsKeyboardNavigation.js +0 -1
- package/esm/hooks/useTransitionState.js +0 -1
- package/esm/icon/components/alert-solid.d.ts +1 -1
- package/esm/icon/components/alert-warning.d.ts +1 -1
- package/esm/icon/components/alert.d.ts +1 -1
- package/esm/icon/components/calendar-solid.d.ts +1 -1
- package/esm/icon/components/chevron-down-solid.d.ts +1 -1
- package/esm/icon/components/chevron-down.d.ts +1 -1
- package/esm/icon/components/chevron-left.d.ts +1 -1
- package/esm/icon/components/chevron-right.d.ts +1 -1
- package/esm/icon/components/clock-icon.d.ts +1 -1
- package/esm/icon/components/close.d.ts +1 -1
- package/esm/icon/components/delete-solid.d.ts +1 -1
- package/esm/icon/components/error-clr.d.ts +1 -1
- package/esm/icon/components/error.d.ts +1 -1
- package/esm/icon/components/form.d.ts +1 -1
- package/esm/icon/components/imagePreview.d.ts +1 -1
- package/esm/icon/components/info-circle.d.ts +1 -1
- package/esm/icon/components/info-solid.d.ts +2 -2
- package/esm/icon/components/info.d.ts +1 -1
- package/esm/icon/components/no-video.d.ts +1 -1
- package/esm/icon/components/noPreview.d.ts +1 -1
- package/esm/icon/components/options.d.ts +1 -1
- package/esm/icon/components/overview.d.ts +1 -1
- package/esm/icon/components/play-video.d.ts +1 -1
- package/esm/icon/components/reset-color.d.ts +1 -1
- package/esm/icon/components/search.d.ts +1 -1
- package/esm/icon/components/subtract.d.ts +1 -1
- package/esm/icon/components/tick.d.ts +1 -1
- package/esm/icon/components/tickCircle-solid.d.ts +1 -1
- package/esm/icon/components/timezone.d.ts +1 -1
- package/esm/icon/components/transparentBackground.d.ts +1 -1
- package/esm/icon/components/user.d.ts +1 -1
- package/esm/icon/components/video-non-playable.d.ts +1 -1
- package/esm/icon/components/warning-solid.d.ts +1 -1
- package/esm/icon/icon.d.ts +1 -1
- package/esm/icon/types.d.ts +3 -3
- package/esm/image/defaultFallbackImg.d.ts +2 -2
- package/esm/image/types.d.ts +3 -3
- package/esm/input/InputContainer.d.ts +1 -1
- package/esm/input/base-input.d.ts +2 -2
- package/esm/input/base-input.js +2 -2
- package/esm/input/masked-input.js +5 -5
- package/esm/input/neutral400Hex.d.ts +1 -1
- package/esm/input/number/NumberInput.d.ts +1 -1
- package/esm/input/number/StatefulNumberInput.d.ts +1 -1
- package/esm/input/number/base-input.d.ts +1 -1
- package/esm/input/useStatefulInput.d.ts +1 -2
- package/esm/layer/LayersManager.d.ts +1 -1
- package/esm/link/styled-components.d.ts +2 -2
- package/esm/link/types.d.ts +1 -1
- package/esm/list/avatar-list-item.d.ts +3 -3
- package/esm/list/list-item-text.d.ts +1 -1
- package/esm/list/list-item.d.ts +1 -1
- package/esm/list/styled-component.js +1 -1
- package/esm/loader/types.d.ts +3 -3
- package/esm/locale/context.d.ts +1 -1
- package/esm/locale/en_US.d.ts +1 -1
- package/esm/menu/nested-menu-context.d.ts +2 -2
- package/esm/menu/useItemContainerEventHandlers.d.ts +1 -1
- package/esm/modal/adapter.d.ts +3 -3
- package/esm/modal/modal-footer.d.ts +2 -2
- package/esm/modal/overrides.d.ts +3 -3
- package/esm/number/Number.d.ts +1 -1
- package/esm/number/constants.d.ts +1 -1
- package/esm/number/types.d.ts +1 -1
- package/esm/number/useNumber.d.ts +1 -1
- package/esm/overrides/mergeOverrides.d.ts +1 -1
- package/esm/overrides/types.d.ts +3 -3
- package/esm/overrides/useOverrides.d.ts +2 -2
- package/esm/payment-card/icons/amex.js +9 -1
- package/esm/payment-card/icons/dinersclub.js +9 -1
- package/esm/payment-card/icons/discover.js +9 -1
- package/esm/payment-card/icons/elo.js +9 -1
- package/esm/payment-card/icons/generic.js +9 -1
- package/esm/payment-card/icons/jcb.js +9 -1
- package/esm/payment-card/icons/maestro.js +9 -1
- package/esm/payment-card/icons/mastercard.js +9 -1
- package/esm/payment-card/icons/uatp.js +9 -1
- package/esm/payment-card/icons/unionpay.js +9 -1
- package/esm/payment-card/icons/visa.js +9 -1
- package/esm/payment-card/paymentCard.js +1 -1
- package/esm/payment-card/types.d.ts +4 -4
- package/esm/phone-input/country-select-container.d.ts +1 -1
- package/esm/phone-input/country-select.d.ts +1 -1
- package/esm/phone-input/default-props.d.ts +2 -2
- package/esm/phone-input/dial-code.d.ts +1 -1
- package/esm/phone-input/phone-input.d.ts +1 -1
- package/esm/phone-input/stateful-phone-input.d.ts +2 -2
- package/esm/phone-input/stateful-phone-input.js +2 -2
- package/esm/phone-input/types.d.ts +5 -5
- package/esm/phone-input/useStatefulPhoneInput.d.ts +1 -1
- package/esm/phone-input/utils.d.ts +2 -2
- package/esm/popover/PopoverEnhancer.d.ts +6 -6
- package/esm/popover/PopoverEnhancer.js +11 -9
- package/esm/popover/adapter.d.ts +2 -2
- package/esm/popover/hooks.d.ts +1 -1
- package/esm/popover/overrides.d.ts +2 -2
- package/esm/popover/stateful-popover.d.ts +1 -1
- package/esm/popover/utils.d.ts +1 -1
- package/esm/progress/circular/styled-component.d.ts +1 -1
- package/esm/progress/circular/types.d.ts +2 -2
- package/esm/progress/helper.d.ts +2 -2
- package/esm/progress/linear/ProgressSegment.js +1 -1
- package/esm/progress/linear/types.d.ts +2 -2
- package/esm/progress/types.d.ts +1 -1
- package/esm/progressSteps/progress-steps.d.ts +1 -1
- package/esm/progressSteps/step.d.ts +1 -1
- package/esm/progressSteps/styled-components.d.ts +1 -1
- package/esm/progressSteps/types.d.ts +1 -1
- package/esm/radio/radio.js +2 -1
- package/esm/radio/radiogroup.js +1 -1
- package/esm/radio/space-radio-context.d.ts +2 -2
- package/esm/radio/styled-components.d.ts +2 -2
- package/esm/radio/types.d.ts +5 -5
- package/esm/search/search.d.ts +3 -3
- package/esm/search/stateful-search.d.ts +2 -2
- package/esm/search/styled-components.d.ts +1 -1
- package/esm/search/types.d.ts +2 -2
- package/esm/select/SelectIdsContext.d.ts +1 -1
- package/esm/select/adaptor.d.ts +2 -2
- package/esm/select/base-select.js +4 -4
- package/esm/select/default-props.d.ts +1 -1
- package/esm/select/grouped-select.d.ts +2 -2
- package/esm/select/grouped-select.js +0 -1
- package/esm/select/mobileSelect/AdaptedCSSTransition/AdaptedCSSTransition.d.ts +1 -1
- package/esm/select/mobileSelect/AdaptedCSSTransition/types.d.ts +2 -2
- package/esm/select/mobileSelect/Backdrop.d.ts +1 -1
- package/esm/select/mobileSelect/MobileSelect.d.ts +1 -1
- package/esm/select/mobileSelect/MobileSheet.d.ts +1 -1
- package/esm/select/mobileSelect/hooks/usePauseBodyScrollEffect.d.ts +1 -1
- package/esm/select/mobileSelect/hooks/useSwipeableSheetStyles.d.ts +1 -1
- package/esm/select/mobileSelect/hooks/useSwipeableSheetStyles.js +2 -2
- package/esm/select/mobileSelect/hooks/useTransitionStyles.d.ts +1 -1
- package/esm/select/multi-value.d.ts +1 -1
- package/esm/select/multi-value.js +1 -1
- package/esm/select/no-results-message.d.ts +2 -2
- package/esm/select/overlaySelect/hooks/useControlRef.d.ts +1 -1
- package/esm/select/overlaySelect/hooks/usePopover.d.ts +1 -1
- package/esm/select/overrides.d.ts +3 -3
- package/esm/select/overrides.js +3 -2
- package/esm/select/select-variants.d.ts +1 -1
- package/esm/select/selectMenuAdapter/SelectMenuAdapter.js +2 -1
- package/esm/select/stateful-select.d.ts +1 -1
- package/esm/select/styled-component.js +1 -3
- package/esm/select/utils/adapt-select-value.d.ts +1 -1
- package/esm/select/utils/default-create-option.d.ts +1 -1
- package/esm/select/utils/hidden-element.d.ts +1 -1
- package/esm/select/utils/hidden-element.js +2 -1
- package/esm/select/utils/merge-options.d.ts +1 -1
- package/esm/slider/slider.js +13 -7
- package/esm/slider/stateful-slider-container.d.ts +1 -1
- package/esm/slider/stateful-slider-container.js +4 -4
- package/esm/slider/stateful-slider.d.ts +2 -2
- package/esm/slider/styled-components.d.ts +1 -1
- package/esm/slider/styled-components.js +27 -3
- package/esm/slider/types.d.ts +2 -2
- package/esm/snackbar/constants.d.ts +3 -3
- package/esm/snackbar/snackbarContext.d.ts +1 -1
- package/esm/snackbar/types.d.ts +1 -1
- package/esm/snackbar/useSnackbar.d.ts +2 -2
- package/esm/spaceConsumer/SpaceConsumer.d.ts +2 -2
- package/esm/spacewebProvider/AiIconLinearGradients.js +3 -1
- package/esm/spacewebProvider/CustomBaseProvider.d.ts +1 -1
- package/esm/spacewebProvider/DocumentProvider.d.ts +1 -1
- package/esm/spacewebProvider/SpacewebProvider.d.ts +4 -4
- package/esm/spacewebProvider/SpacewebProvider.js +1 -1
- package/esm/stack/context.d.ts +1 -1
- package/esm/stack/stack.d.ts +1 -1
- package/esm/stack/types.d.ts +2 -2
- package/esm/style/_buildUtils.d.ts +1 -1
- package/esm/style/_css.d.ts +1 -1
- package/esm/style/_cssParseStyle.d.ts +1 -1
- package/esm/style/_getStyle.d.ts +1 -1
- package/esm/style/_getStyleWithProps.d.ts +1 -1
- package/esm/style/_parseClassName.d.ts +1 -1
- package/esm/style/_parseStyleProp.d.ts +2 -2
- package/esm/style/_parseStyleProp.js +3 -2
- package/esm/style/_px2rem.d.ts +1 -1
- package/esm/style/styled-with-css-variables.d.ts +1 -1
- package/esm/style/styled.d.ts +2 -2
- package/esm/style/styled.js +1 -1
- package/esm/style/useMemoizedStyletron.js +2 -2
- package/esm/style/useStyle.d.ts +1 -1
- package/esm/styleEngine/styleEngine.d.ts +2 -2
- package/esm/styleEngine/styleEngine.js +0 -1
- package/esm/switch/switch.d.ts +3 -3
- package/esm/switch/switch.js +1 -1
- package/esm/tabs/contexts.d.ts +2 -2
- package/esm/tabs/helpers.d.ts +1 -1
- package/esm/tabs/scroll-button.d.ts +1 -1
- package/esm/tabs/stateful-tabs.d.ts +2 -2
- package/esm/tabs/styled-components.d.ts +2 -2
- package/esm/tabs/tab-list.d.ts +1 -1
- package/esm/tabs/tab.d.ts +2 -2
- package/esm/tabs/tabs-panel.d.ts +2 -2
- package/esm/tabs/types.d.ts +4 -4
- package/esm/tag/constants.d.ts +1 -1
- package/esm/tag/status-tag.d.ts +1 -1
- package/esm/tag/tag.js +6 -2
- package/esm/tag/utils.d.ts +1 -1
- package/esm/test-utils/test-provider/TestProvider.d.ts +1 -1
- package/esm/test-utils/test-provider/helpers.d.ts +2 -2
- package/esm/test-utils/test-provider/testableThemes.d.ts +1 -1
- package/esm/textarea/textarea.js +5 -5
- package/esm/textarea/types.d.ts +4 -5
- package/esm/textarea/useAutoSizeTextarea.d.ts +2 -2
- package/esm/theme/Provider.d.ts +2 -2
- package/esm/theme/context.d.ts +1 -1
- package/esm/theme/types.d.ts +1 -1
- package/esm/time-picker/TimePicker.d.ts +2 -2
- package/esm/time-picker/types.d.ts +5 -5
- package/esm/time-range-picker/RangeSelector.d.ts +2 -2
- package/esm/time-range-picker/TimeRangeList.d.ts +2 -2
- package/esm/time-range-picker/TimeRangePicker.d.ts +2 -2
- package/esm/time-range-picker/TimeRangePicker.js +2 -1
- package/esm/time-range-picker/TimezonePicker.d.ts +1 -1
- package/esm/time-range-picker/types.d.ts +1 -1
- package/esm/time-range-picker/utils.d.ts +2 -2
- package/esm/time-zone-picker/TimezonePicker.d.ts +2 -2
- package/esm/time-zone-picker/types.d.ts +1 -1
- package/esm/tooltip/disabled-tooltip-container.d.ts +1 -1
- package/esm/tooltip/overrides.d.ts +2 -2
- package/esm/tooltip/stateful-tooltip-container.d.ts +1 -1
- package/esm/tooltip/stateful-tooltip.d.ts +2 -2
- package/esm/tooltip/tooltip.d.ts +2 -2
- package/esm/tooltip/types.d.ts +5 -5
- package/esm/transitions/collapse/collapse.d.ts +2 -2
- package/esm/transitions/collapse/types.d.ts +2 -2
- package/esm/transitions/fade/fade.d.ts +2 -2
- package/esm/transitions/fade/types.d.ts +2 -2
- package/esm/transitions/grow/grow.d.ts +2 -2
- package/esm/transitions/grow/types.d.ts +2 -2
- package/esm/transitions/transition/SwitchTransition.d.ts +2 -2
- package/esm/transitions/transition/transition.d.ts +2 -2
- package/esm/transitions/transition/types.d.ts +5 -4
- package/esm/truncateWithTooltip/TruncateWithTooltip.d.ts +1 -1
- package/esm/truncateWithTooltip/TruncateWithTooltip.js +6 -5
- package/esm/truncateWithTooltip/hooks/useTruncateWithTooltip.d.ts +7 -2
- package/esm/truncateWithTooltip/hooks/useTruncateWithTooltip.js +9 -9
- package/esm/types.d.ts +5 -5
- package/esm/typography/Typography.d.ts +1 -1
- package/esm/typography/types.d.ts +4 -4
- package/esm/utils/intlNumberFormatUtils/index.d.ts +1 -1
- package/esm/utils/intlNumberFormatUtils/index.js +1 -1
- package/esm/video/DefaultFallbackImg.d.ts +2 -2
- package/esm/video/Video.js +0 -1
- package/esm/video/types.d.ts +4 -5
- package/form-control/context.d.ts +1 -1
- package/form-control/form-control.d.ts +1 -1
- package/form-control/form-control.js +1 -1
- package/form-control/info-icon.d.ts +6 -5
- package/form-control/info-icon.js +0 -1
- package/form-control/styled-component.js +2 -1
- package/form-control/types.d.ts +3 -4
- package/grid/Col.d.ts +2 -2
- package/grid/Grid.d.ts +2 -2
- package/grid/Grid.js +0 -3
- package/grid/index.d.ts +1 -1
- package/grid/types.d.ts +1 -1
- package/helpers/ClearIconButton.d.ts +3 -3
- package/helpers/ClearIconButton.js +1 -1
- package/helpers/commonStyles.js +2 -3
- package/helpers/intentHelper.d.ts +1 -1
- package/helpers/longHandHelpers.d.ts +1 -1
- package/helpers/themeHelpers.d.ts +2 -2
- package/hooks/useAutoFocus.d.ts +2 -2
- package/hooks/useAutoFocus.js +1 -0
- package/hooks/useDebouncedEventHandler.d.ts +1 -1
- package/hooks/useDebouncedEventHandler.js +0 -3
- package/hooks/useHover.d.ts +1 -1
- package/hooks/useMatchMedia.js +3 -2
- package/hooks/useSVGAnimation.d.ts +2 -2
- package/hooks/useTabsKeyboardNavigation.d.ts +1 -1
- package/hooks/useTabsKeyboardNavigation.js +0 -1
- package/hooks/useTransitionState.js +0 -1
- package/icon/components/alert-solid.d.ts +1 -1
- package/icon/components/alert-warning.d.ts +1 -1
- package/icon/components/alert.d.ts +1 -1
- package/icon/components/calendar-solid.d.ts +1 -1
- package/icon/components/chevron-down-solid.d.ts +1 -1
- package/icon/components/chevron-down.d.ts +1 -1
- package/icon/components/chevron-left.d.ts +1 -1
- package/icon/components/chevron-right.d.ts +1 -1
- package/icon/components/clock-icon.d.ts +1 -1
- package/icon/components/close.d.ts +1 -1
- package/icon/components/delete-solid.d.ts +1 -1
- package/icon/components/error-clr.d.ts +1 -1
- package/icon/components/error.d.ts +1 -1
- package/icon/components/form.d.ts +1 -1
- package/icon/components/imagePreview.d.ts +1 -1
- package/icon/components/info-circle.d.ts +1 -1
- package/icon/components/info-solid.d.ts +2 -2
- package/icon/components/info.d.ts +1 -1
- package/icon/components/no-video.d.ts +1 -1
- package/icon/components/noPreview.d.ts +1 -1
- package/icon/components/options.d.ts +1 -1
- package/icon/components/overview.d.ts +1 -1
- package/icon/components/play-video.d.ts +1 -1
- package/icon/components/reset-color.d.ts +1 -1
- package/icon/components/search.d.ts +1 -1
- package/icon/components/subtract.d.ts +1 -1
- package/icon/components/tick.d.ts +1 -1
- package/icon/components/tickCircle-solid.d.ts +1 -1
- package/icon/components/timezone.d.ts +1 -1
- package/icon/components/transparentBackground.d.ts +1 -1
- package/icon/components/user.d.ts +1 -1
- package/icon/components/video-non-playable.d.ts +1 -1
- package/icon/components/warning-solid.d.ts +1 -1
- package/icon/icon.d.ts +1 -1
- package/icon/types.d.ts +3 -3
- package/image/defaultFallbackImg.d.ts +2 -2
- package/image/types.d.ts +3 -3
- package/input/InputContainer.d.ts +1 -1
- package/input/base-input.d.ts +2 -2
- package/input/base-input.js +2 -2
- package/input/masked-input.js +5 -5
- package/input/neutral400Hex.d.ts +1 -1
- package/input/number/NumberInput.d.ts +1 -1
- package/input/number/StatefulNumberInput.d.ts +1 -1
- package/input/number/base-input.d.ts +1 -1
- package/input/useStatefulInput.d.ts +1 -2
- package/layer/LayersManager.d.ts +1 -1
- package/link/styled-components.d.ts +2 -2
- package/link/types.d.ts +1 -1
- package/list/avatar-list-item.d.ts +3 -3
- package/list/list-item-text.d.ts +1 -1
- package/list/list-item.d.ts +1 -1
- package/list/styled-component.js +1 -1
- package/loader/types.d.ts +3 -3
- package/locale/context.d.ts +1 -1
- package/locale/en_US.d.ts +1 -1
- package/menu/nested-menu-context.d.ts +2 -2
- package/menu/useItemContainerEventHandlers.d.ts +1 -1
- package/modal/adapter.d.ts +3 -3
- package/modal/modal-footer.d.ts +2 -2
- package/modal/overrides.d.ts +3 -3
- package/number/Number.d.ts +1 -1
- package/number/constants.d.ts +1 -1
- package/number/types.d.ts +1 -1
- package/number/useNumber.d.ts +1 -1
- package/overrides/mergeOverrides.d.ts +1 -1
- package/overrides/types.d.ts +3 -3
- package/overrides/useOverrides.d.ts +2 -2
- package/package.json +2 -2
- package/payment-card/icons/amex.js +9 -1
- package/payment-card/icons/dinersclub.js +9 -1
- package/payment-card/icons/discover.js +9 -1
- package/payment-card/icons/elo.js +9 -1
- package/payment-card/icons/generic.js +9 -1
- package/payment-card/icons/jcb.js +9 -1
- package/payment-card/icons/maestro.js +9 -1
- package/payment-card/icons/mastercard.js +9 -1
- package/payment-card/icons/uatp.js +9 -1
- package/payment-card/icons/unionpay.js +9 -1
- package/payment-card/icons/visa.js +9 -1
- package/payment-card/paymentCard.js +1 -1
- package/payment-card/types.d.ts +4 -4
- package/phone-input/country-select-container.d.ts +1 -1
- package/phone-input/country-select.d.ts +1 -1
- package/phone-input/default-props.d.ts +2 -2
- package/phone-input/dial-code.d.ts +1 -1
- package/phone-input/phone-input.d.ts +1 -1
- package/phone-input/stateful-phone-input.d.ts +2 -2
- package/phone-input/stateful-phone-input.js +1 -1
- package/phone-input/types.d.ts +5 -5
- package/phone-input/useStatefulPhoneInput.d.ts +1 -1
- package/phone-input/utils.d.ts +2 -2
- package/popover/PopoverEnhancer.d.ts +6 -6
- package/popover/PopoverEnhancer.js +10 -8
- package/popover/adapter.d.ts +2 -2
- package/popover/hooks.d.ts +1 -1
- package/popover/overrides.d.ts +2 -2
- package/popover/stateful-popover.d.ts +1 -1
- package/popover/utils.d.ts +1 -1
- package/progress/circular/styled-component.d.ts +1 -1
- package/progress/circular/types.d.ts +2 -2
- package/progress/helper.d.ts +2 -2
- package/progress/linear/ProgressSegment.js +1 -1
- package/progress/linear/types.d.ts +2 -2
- package/progress/types.d.ts +1 -1
- package/progressSteps/progress-steps.d.ts +1 -1
- package/progressSteps/step.d.ts +1 -1
- package/progressSteps/styled-components.d.ts +1 -1
- package/progressSteps/types.d.ts +1 -1
- package/radio/radio.js +2 -1
- package/radio/radiogroup.js +1 -1
- package/radio/space-radio-context.d.ts +2 -2
- package/radio/styled-components.d.ts +2 -2
- package/radio/types.d.ts +5 -5
- package/search/search.d.ts +3 -3
- package/search/stateful-search.d.ts +2 -2
- package/search/styled-components.d.ts +1 -1
- package/search/types.d.ts +2 -2
- package/select/SelectIdsContext.d.ts +1 -1
- package/select/adaptor.d.ts +2 -2
- package/select/base-select.js +4 -4
- package/select/default-props.d.ts +1 -1
- package/select/grouped-select.d.ts +2 -2
- package/select/grouped-select.js +0 -1
- package/select/mobileSelect/AdaptedCSSTransition/AdaptedCSSTransition.d.ts +1 -1
- package/select/mobileSelect/AdaptedCSSTransition/types.d.ts +2 -2
- package/select/mobileSelect/Backdrop.d.ts +1 -1
- package/select/mobileSelect/MobileSelect.d.ts +1 -1
- package/select/mobileSelect/MobileSheet.d.ts +1 -1
- package/select/mobileSelect/hooks/usePauseBodyScrollEffect.d.ts +1 -1
- package/select/mobileSelect/hooks/useSwipeableSheetStyles.d.ts +1 -1
- package/select/mobileSelect/hooks/useSwipeableSheetStyles.js +2 -2
- package/select/mobileSelect/hooks/useTransitionStyles.d.ts +1 -1
- package/select/multi-value.d.ts +1 -1
- package/select/multi-value.js +1 -1
- package/select/no-results-message.d.ts +2 -2
- package/select/overlaySelect/hooks/useControlRef.d.ts +1 -1
- package/select/overlaySelect/hooks/usePopover.d.ts +1 -1
- package/select/overrides.d.ts +3 -3
- package/select/overrides.js +3 -2
- package/select/select-variants.d.ts +1 -1
- package/select/selectMenuAdapter/SelectMenuAdapter.js +2 -1
- package/select/stateful-select.d.ts +1 -1
- package/select/styled-component.js +1 -3
- package/select/utils/adapt-select-value.d.ts +1 -1
- package/select/utils/default-create-option.d.ts +1 -1
- package/select/utils/hidden-element.d.ts +1 -1
- package/select/utils/hidden-element.js +2 -1
- package/select/utils/merge-options.d.ts +1 -1
- package/slider/slider.js +13 -7
- package/slider/stateful-slider-container.d.ts +1 -1
- package/slider/stateful-slider-container.js +4 -4
- package/slider/stateful-slider.d.ts +2 -2
- package/slider/styled-components.d.ts +1 -1
- package/slider/styled-components.js +27 -3
- package/slider/types.d.ts +2 -2
- package/snackbar/constants.d.ts +3 -3
- package/snackbar/snackbarContext.d.ts +1 -1
- package/snackbar/types.d.ts +1 -1
- package/snackbar/useSnackbar.d.ts +2 -2
- package/spaceConsumer/SpaceConsumer.d.ts +2 -2
- package/spacewebProvider/AiIconLinearGradients.js +3 -1
- package/spacewebProvider/CustomBaseProvider.d.ts +1 -1
- package/spacewebProvider/DocumentProvider.d.ts +1 -1
- package/spacewebProvider/SpacewebProvider.d.ts +4 -4
- package/spacewebProvider/SpacewebProvider.js +1 -1
- package/stack/context.d.ts +1 -1
- package/stack/stack.d.ts +1 -1
- package/stack/types.d.ts +2 -2
- package/style/_buildUtils.d.ts +1 -1
- package/style/_css.d.ts +1 -1
- package/style/_cssParseStyle.d.ts +1 -1
- package/style/_getStyle.d.ts +1 -1
- package/style/_getStyleWithProps.d.ts +1 -1
- package/style/_parseClassName.d.ts +1 -1
- package/style/_parseStyleProp.d.ts +2 -2
- package/style/_parseStyleProp.js +3 -2
- package/style/_px2rem.d.ts +1 -1
- package/style/styled-with-css-variables.d.ts +1 -1
- package/style/styled.d.ts +2 -2
- package/style/styled.js +1 -1
- package/style/useMemoizedStyletron.js +2 -2
- package/style/useStyle.d.ts +1 -1
- package/styleEngine/styleEngine.d.ts +2 -2
- package/styleEngine/styleEngine.js +0 -1
- package/switch/switch.d.ts +3 -3
- package/switch/switch.js +1 -1
- package/tabs/contexts.d.ts +2 -2
- package/tabs/helpers.d.ts +1 -1
- package/tabs/scroll-button.d.ts +1 -1
- package/tabs/stateful-tabs.d.ts +2 -2
- package/tabs/styled-components.d.ts +2 -2
- package/tabs/tab-list.d.ts +1 -1
- package/tabs/tab.d.ts +2 -2
- package/tabs/tabs-panel.d.ts +2 -2
- package/tabs/types.d.ts +4 -4
- package/tag/constants.d.ts +1 -1
- package/tag/status-tag.d.ts +1 -1
- package/tag/tag.js +6 -2
- package/tag/utils.d.ts +1 -1
- package/test-utils/test-provider/TestProvider.d.ts +1 -1
- package/test-utils/test-provider/helpers.d.ts +2 -2
- package/test-utils/test-provider/testableThemes.d.ts +1 -1
- package/textarea/textarea.js +5 -5
- package/textarea/types.d.ts +4 -5
- package/textarea/useAutoSizeTextarea.d.ts +2 -2
- package/theme/Provider.d.ts +2 -2
- package/theme/context.d.ts +1 -1
- package/theme/types.d.ts +1 -1
- package/time-picker/TimePicker.d.ts +2 -2
- package/time-picker/types.d.ts +5 -5
- package/time-range-picker/RangeSelector.d.ts +2 -2
- package/time-range-picker/TimeRangeList.d.ts +2 -2
- package/time-range-picker/TimeRangePicker.d.ts +2 -2
- package/time-range-picker/TimeRangePicker.js +2 -1
- package/time-range-picker/TimezonePicker.d.ts +1 -1
- package/time-range-picker/types.d.ts +1 -1
- package/time-range-picker/utils.d.ts +2 -2
- package/time-zone-picker/TimezonePicker.d.ts +2 -2
- package/time-zone-picker/types.d.ts +1 -1
- package/tooltip/disabled-tooltip-container.d.ts +1 -1
- package/tooltip/overrides.d.ts +2 -2
- package/tooltip/stateful-tooltip-container.d.ts +1 -1
- package/tooltip/stateful-tooltip.d.ts +2 -2
- package/tooltip/tooltip.d.ts +2 -2
- package/tooltip/types.d.ts +5 -5
- package/transitions/collapse/collapse.d.ts +2 -2
- package/transitions/collapse/types.d.ts +2 -2
- package/transitions/fade/fade.d.ts +2 -2
- package/transitions/fade/types.d.ts +2 -2
- package/transitions/grow/grow.d.ts +2 -2
- package/transitions/grow/types.d.ts +2 -2
- package/transitions/transition/SwitchTransition.d.ts +2 -2
- package/transitions/transition/transition.d.ts +2 -2
- package/transitions/transition/types.d.ts +5 -4
- package/truncateWithTooltip/TruncateWithTooltip.d.ts +1 -1
- package/truncateWithTooltip/TruncateWithTooltip.js +6 -5
- package/truncateWithTooltip/hooks/useTruncateWithTooltip.d.ts +7 -2
- package/truncateWithTooltip/hooks/useTruncateWithTooltip.js +9 -9
- package/tsconfig.build.tsbuildinfo +1 -1
- package/types.d.ts +5 -5
- package/typography/Typography.d.ts +1 -1
- package/typography/types.d.ts +4 -4
- package/utils/intlNumberFormatUtils/index.d.ts +1 -1
- package/utils/intlNumberFormatUtils/index.js +1 -1
- package/video/DefaultFallbackImg.d.ts +2 -2
- package/video/Video.js +0 -1
- package/video/types.d.ts +4 -5
|
@@ -181,10 +181,10 @@ var DateHelpers = /** @class */ (function () {
|
|
|
181
181
|
var minDates = includeDates.filter(function (includeDate) { return _this.isOnOrAfterDay(includeDate, minDate); });
|
|
182
182
|
return _this.min(minDates);
|
|
183
183
|
}
|
|
184
|
-
|
|
184
|
+
if (includeDates && includeDates.length) {
|
|
185
185
|
return _this.min(includeDates);
|
|
186
186
|
}
|
|
187
|
-
|
|
187
|
+
if (!(includeDates && includeDates.length) && minDate) {
|
|
188
188
|
return minDate;
|
|
189
189
|
}
|
|
190
190
|
// this condition can't ever be reached
|
|
@@ -197,10 +197,10 @@ var DateHelpers = /** @class */ (function () {
|
|
|
197
197
|
var maxDates = includeDates.filter(function (includeDate) { return _this.isOnOrBeforeDay(includeDate, maxDate); });
|
|
198
198
|
return _this.max(maxDates);
|
|
199
199
|
}
|
|
200
|
-
|
|
200
|
+
if (includeDates) {
|
|
201
201
|
return _this.max(includeDates);
|
|
202
202
|
}
|
|
203
|
-
|
|
203
|
+
if (!includeDates && maxDate) {
|
|
204
204
|
return maxDate;
|
|
205
205
|
}
|
|
206
206
|
// this condition can't ever be reached
|
|
@@ -5,7 +5,6 @@ Copyright (c) Uber Technologies, Inc.
|
|
|
5
5
|
This source code is licensed under the MIT license found in the
|
|
6
6
|
LICENSE file in the root directory of this source tree.
|
|
7
7
|
*/
|
|
8
|
-
/* eslint-disable import/extensions */
|
|
9
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
9
|
exports.format = exports.isAfter = exports.isBefore = exports.subYears = exports.subMonths = exports.subWeeks = exports.subDays = exports.addYears = exports.addMonths = exports.addWeeks = exports.addDays = exports.getYear = exports.getMonth = exports.getDate = exports.getHours = exports.getMinutes = exports.setYear = exports.setMonth = exports.setHours = exports.setMinutes = exports.setSeconds = exports.applyDateToTime = exports.applyTimeToDate = exports.getEffectiveMaxDate = exports.getEffectiveMinDate = exports.monthDisabledAfter = exports.monthDisabledBefore = exports.isOutOfBounds = exports.isDayDisabled = exports.getQuarterInLocale = exports.getMonthInLocale = exports.getWeekdayInLocale = exports.getWeekdayMinInLocale = exports.isEndOfMonth = exports.isStartOfMonth = exports.isDayInRange = exports.isSameDay = exports.isSameMonth = exports.isSameYear = exports.getEndOfMonth = exports.getStartOfMonth = exports.getEndOfWeek = exports.getStartOfWeek = exports.formatDate = void 0;
|
|
11
10
|
var tslib_1 = require("tslib");
|
|
@@ -36,17 +35,13 @@ exports.getEffectiveMinDate = defaultDateHelpers.getEffectiveMinDate;
|
|
|
36
35
|
exports.getEffectiveMaxDate = defaultDateHelpers.getEffectiveMaxDate;
|
|
37
36
|
exports.applyTimeToDate = defaultDateHelpers.applyTimeToDate;
|
|
38
37
|
exports.applyDateToTime = defaultDateHelpers.applyDateToTime;
|
|
39
|
-
var createDirtySetter = function (setter) {
|
|
40
|
-
return
|
|
41
|
-
};
|
|
42
|
-
var createDirtyGetter = function (getter) {
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
return function (fromDirty, toDirty) {
|
|
47
|
-
return compare(wrapDate(fromDirty), wrapDate(toDirty));
|
|
48
|
-
};
|
|
49
|
-
};
|
|
38
|
+
var createDirtySetter = function (setter) { return function (dirtyDate, number) {
|
|
39
|
+
return setter(wrapDate(dirtyDate), number);
|
|
40
|
+
}; };
|
|
41
|
+
var createDirtyGetter = function (getter) { return function (dirtyDate) { return getter(wrapDate(dirtyDate)); }; };
|
|
42
|
+
var createDirtyCompare = function (compare) { return function (fromDirty, toDirty) {
|
|
43
|
+
return compare(wrapDate(fromDirty), wrapDate(toDirty));
|
|
44
|
+
}; };
|
|
50
45
|
// ** Re-exported from date-fns **
|
|
51
46
|
// these need to be able to accept either number or date
|
|
52
47
|
// to maintain parity with the old exports
|
|
@@ -11,13 +11,13 @@ export type OverrideObject = {
|
|
|
11
11
|
style?: ConfigurationOverride | null;
|
|
12
12
|
className?: ConfigurationOverride | null;
|
|
13
13
|
};
|
|
14
|
-
export type Override<
|
|
14
|
+
export type Override<_T = any> = OverrideObject | (React.ComponentType<any> & {
|
|
15
15
|
component?: undefined;
|
|
16
16
|
props?: undefined;
|
|
17
17
|
style?: undefined;
|
|
18
18
|
className?: undefined;
|
|
19
19
|
});
|
|
20
|
-
export type Overrides<
|
|
20
|
+
export type Overrides<_T = any> = {
|
|
21
21
|
[x: string]: Override;
|
|
22
22
|
};
|
|
23
23
|
/**
|
|
@@ -43,10 +43,8 @@ function getOverrideProps(_override, defaultComponent) {
|
|
|
43
43
|
// @ts-expect-error
|
|
44
44
|
return tslib_1.__assign(tslib_1.__assign(tslib_1.__assign({}, defaultProps), _override.props), { $className: _override.className, $style: _override.style });
|
|
45
45
|
}
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
return tslib_1.__assign(tslib_1.__assign({}, defaultProps), { $className: _override.className, $style: _override.style });
|
|
49
|
-
}
|
|
46
|
+
// @ts-expect-error
|
|
47
|
+
return tslib_1.__assign(tslib_1.__assign({}, defaultProps), { $className: _override.className, $style: _override.style });
|
|
50
48
|
}
|
|
51
49
|
// @ts-expect-error
|
|
52
50
|
return defaultProps;
|
|
@@ -63,13 +61,12 @@ function getOverrides(
|
|
|
63
61
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any -- baseui migration
|
|
64
62
|
_override,
|
|
65
63
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any -- baseui migration
|
|
66
|
-
defaultComponent
|
|
67
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any -- baseui migration
|
|
68
|
-
) {
|
|
64
|
+
defaultComponent) {
|
|
69
65
|
var Component = getOverride(_override) || defaultComponent;
|
|
70
66
|
if (_override && typeof _override === 'object' && typeof _override.props === 'function') {
|
|
71
67
|
// TODO(v11)
|
|
72
68
|
if (__DEV__) {
|
|
69
|
+
// eslint-disable-next-line no-console -- debug logging
|
|
73
70
|
console.warn('baseui:Overrides Props as a function will be removed in the next major version. Override the whole component instead. ' +
|
|
74
71
|
'See https://baseweb.design/guides/understanding-overrides/#override-the-entire-subcomponent');
|
|
75
72
|
}
|
package/baseui/layer/layer.js
CHANGED
|
@@ -67,6 +67,7 @@ var LayerComponent = /** @class */ (function (_super) {
|
|
|
67
67
|
var hasLayersManager = layersManagerHost !== undefined;
|
|
68
68
|
if (process.env.NODE_ENV !== 'production') {
|
|
69
69
|
if (!hasLayersManager) {
|
|
70
|
+
// eslint-disable-next-line no-console -- debug logging
|
|
70
71
|
console.warn('`LayersManager` was not found. This occurs if you are attempting to use a component requiring `Layer` without using the `BaseProvider` at the root of your app. Please visit https://baseweb.design/components/base-provider/ for more information');
|
|
71
72
|
}
|
|
72
73
|
}
|
|
@@ -138,7 +139,7 @@ var LayerComponent = /** @class */ (function (_super) {
|
|
|
138
139
|
if (mountNode) {
|
|
139
140
|
return react_dom_1.default.createPortal(childrenToRender, mountNode);
|
|
140
141
|
}
|
|
141
|
-
|
|
142
|
+
if (container) {
|
|
142
143
|
return react_dom_1.default.createPortal(childrenToRender, container);
|
|
143
144
|
}
|
|
144
145
|
return null;
|
|
@@ -16,6 +16,7 @@ var StyledLayersContainer = (0, style_1.styled)('div', {});
|
|
|
16
16
|
var __DEV__ = process.env.NODE_ENV !== 'production';
|
|
17
17
|
function defaultEventHandlerFn() {
|
|
18
18
|
if (__DEV__) {
|
|
19
|
+
// eslint-disable-next-line no-console -- debug logging
|
|
19
20
|
console.warn('`LayersManager` was not found. This occurs if you are attempting to use a component requiring `Layer` without using the `BaseProvider` at the root of your app. Please visit https://baseweb.design/components/base-provider/ for more information');
|
|
20
21
|
}
|
|
21
22
|
}
|
|
@@ -149,7 +150,7 @@ var LayersManager = /** @class */ (function (_super) {
|
|
|
149
150
|
var host = _a.host;
|
|
150
151
|
if (__DEV__) {
|
|
151
152
|
if (host !== undefined) {
|
|
152
|
-
// eslint-disable-next-line no-console
|
|
153
|
+
// eslint-disable-next-line no-console -- debug logging
|
|
153
154
|
console.warn('There is a LayersManager already exists in your application. It is not recommended to have more than one LayersManager in an application.');
|
|
154
155
|
}
|
|
155
156
|
}
|
package/baseui/layer/tether.js
CHANGED
|
@@ -103,6 +103,7 @@ var Tether = /** @class */ (function (_super) {
|
|
|
103
103
|
(prevProps === null || prevProps === void 0 ? void 0 : prevProps.positionFixed) !== this.props.positionFixed)) {
|
|
104
104
|
if (!this.props.anchorRef) {
|
|
105
105
|
if (process.env.NODE_ENV !== 'production') {
|
|
106
|
+
// eslint-disable-next-line no-console -- debug logging
|
|
106
107
|
console.warn("[baseui][TetherBehavior] ref has not been passed to the Popper's anchor element.\n See how to pass the ref to an anchor element in the Popover example\n https://baseweb.design/components/popover/#anchor-ref-handling-example");
|
|
107
108
|
}
|
|
108
109
|
}
|
package/baseui/layer/types.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type * as React from 'react';
|
|
2
2
|
import type { TETHER_PLACEMENT } from './constants';
|
|
3
3
|
import type { Override } from '../../overrides';
|
|
4
|
-
import { ClassName } from '../../types';
|
|
4
|
+
import type { ClassName } from '../../types';
|
|
5
5
|
/** LayersManager */
|
|
6
6
|
export type LayersManagerProps = {
|
|
7
7
|
children: React.ReactNode;
|
|
@@ -3,8 +3,16 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.CloseIcon = void 0;
|
|
4
4
|
var tslib_1 = require("tslib");
|
|
5
5
|
var jsx_runtime_1 = require("react/jsx-runtime");
|
|
6
|
+
/*
|
|
7
|
+
Copyright (c) Uber Technologies, Inc.
|
|
8
|
+
|
|
9
|
+
This source code is licensed under the MIT license found in the
|
|
10
|
+
LICENSE file in the root directory of this source tree.
|
|
11
|
+
*/
|
|
6
12
|
// TODO Switch to using Icon component once it exists
|
|
7
13
|
function CloseIcon() {
|
|
8
|
-
return (
|
|
14
|
+
return (
|
|
15
|
+
// eslint-disable-next-line react/forbid-elements -- baseui close glyph must be raw svg
|
|
16
|
+
(0, jsx_runtime_1.jsx)("svg", tslib_1.__assign({ width: "10", height: "10", viewBox: "0 0 10 10", style: { stroke: 'currentColor' }, xmlns: "http://www.w3.org/2000/svg" }, { children: (0, jsx_runtime_1.jsx)("path", { d: "M9 1L5 5M1 9L5 5M5 5L1 1M5 5L9 9", strokeWidth: "2", strokeLinecap: "round" }) })));
|
|
9
17
|
}
|
|
10
18
|
exports.CloseIcon = CloseIcon;
|
package/baseui/modal/modal.d.ts
CHANGED
|
@@ -18,9 +18,9 @@ declare class Modal extends React.Component<ModalProps, ModalState> {
|
|
|
18
18
|
};
|
|
19
19
|
componentDidMount(): void;
|
|
20
20
|
componentWillUnmount(): void;
|
|
21
|
-
componentDidUpdate(prevProps: ModalProps,
|
|
21
|
+
componentDidUpdate(prevProps: ModalProps, _prevState: ModalState): void;
|
|
22
22
|
handleFocus: (event: SyntheticEvent) => void;
|
|
23
|
-
handleBlur: (
|
|
23
|
+
handleBlur: (_event: SyntheticEvent) => void;
|
|
24
24
|
disableMountNodeScroll(): void;
|
|
25
25
|
resetMountNodeScroll(): void;
|
|
26
26
|
onEscape: () => void;
|
|
@@ -33,7 +33,7 @@ declare class Modal extends React.Component<ModalProps, ModalState> {
|
|
|
33
33
|
triggerClose(source?: CloseSource): void;
|
|
34
34
|
animateOutComplete: () => void;
|
|
35
35
|
getSharedProps(): Omit<SharedStylePropsArg, 'children'>;
|
|
36
|
-
getMountNode(): HTMLElement;
|
|
36
|
+
getMountNode(): HTMLElement | null;
|
|
37
37
|
getChildren(): React.ReactNode;
|
|
38
38
|
renderModal(renderedContent: React.ReactNode): import("react/jsx-runtime").JSX.Element;
|
|
39
39
|
render(): import("react/jsx-runtime").JSX.Element | null;
|
package/baseui/modal/modal.js
CHANGED
|
@@ -38,7 +38,7 @@ var Modal = /** @class */ (function (_super) {
|
|
|
38
38
|
_this.setState({ isFocusVisible: true });
|
|
39
39
|
}
|
|
40
40
|
};
|
|
41
|
-
_this.handleBlur = function (
|
|
41
|
+
_this.handleBlur = function (_event) {
|
|
42
42
|
if (_this.state.isFocusVisible !== false) {
|
|
43
43
|
_this.setState({ isFocusVisible: false });
|
|
44
44
|
}
|
|
@@ -89,7 +89,7 @@ var Modal = /** @class */ (function (_super) {
|
|
|
89
89
|
this.prevMounted = this.mounted;
|
|
90
90
|
this.mounted = false;
|
|
91
91
|
};
|
|
92
|
-
Modal.prototype.componentDidUpdate = function (prevProps,
|
|
92
|
+
Modal.prototype.componentDidUpdate = function (prevProps, _prevState) {
|
|
93
93
|
var isOpen = this.props.isOpen;
|
|
94
94
|
if (
|
|
95
95
|
// If isOpen is changing *or* we just mounted and modal should be open
|
|
@@ -106,6 +106,8 @@ var Modal = /** @class */ (function (_super) {
|
|
|
106
106
|
};
|
|
107
107
|
Modal.prototype.disableMountNodeScroll = function () {
|
|
108
108
|
var mountNode = this.getMountNode();
|
|
109
|
+
if (!mountNode)
|
|
110
|
+
return;
|
|
109
111
|
this.lastMountNodeOverflowStyle = mountNode.style.overflow || '';
|
|
110
112
|
mountNode.style.overflow = 'hidden';
|
|
111
113
|
};
|
|
@@ -216,13 +218,9 @@ var Modal = /** @class */ (function (_super) {
|
|
|
216
218
|
if (mountedAndOpen) {
|
|
217
219
|
return ((0, jsx_runtime_1.jsx)(layer_1.Layer, tslib_1.__assign({ onEscape: this.onEscape, onDocumentClick: this.onDocumentClick, mountNode: this.props.mountNode }, { children: this.renderModal(renderedContent) })));
|
|
218
220
|
}
|
|
219
|
-
|
|
220
|
-
return (0, jsx_runtime_1.jsx)(styled_components_1.Hidden, { children: renderedContent });
|
|
221
|
-
}
|
|
222
|
-
}
|
|
223
|
-
else {
|
|
224
|
-
return null;
|
|
221
|
+
return (0, jsx_runtime_1.jsx)(styled_components_1.Hidden, { children: renderedContent });
|
|
225
222
|
}
|
|
223
|
+
return null;
|
|
226
224
|
};
|
|
227
225
|
Modal.defaultProps = {
|
|
228
226
|
animate: true,
|
|
@@ -19,6 +19,7 @@ var default_props_1 = tslib_1.__importDefault(require("./default-props"));
|
|
|
19
19
|
var react_uid_1 = require("react-uid");
|
|
20
20
|
var layer_2 = require("../../layer");
|
|
21
21
|
var useCombinedRef_1 = require("../../hooks/useCombinedRef");
|
|
22
|
+
var box_1 = require("../../box");
|
|
22
23
|
var __DEV__ = process.env.NODE_ENV !== 'production';
|
|
23
24
|
function getDefaultState(props) {
|
|
24
25
|
return {
|
|
@@ -41,7 +42,6 @@ var PopoverInner = /** @class */ (function (_super) {
|
|
|
41
42
|
_this.anchorRef = React.createRef();
|
|
42
43
|
_this.popperRef = React.createRef();
|
|
43
44
|
_this.arrowRef = React.createRef();
|
|
44
|
-
/* eslint-enable react/sort-comp */
|
|
45
45
|
/**
|
|
46
46
|
* Yes our "Stateless" popover still has state. This is private state that
|
|
47
47
|
* customers shouldn't have to manage themselves, such as positioning and
|
|
@@ -133,6 +133,7 @@ var PopoverInner = /** @class */ (function (_super) {
|
|
|
133
133
|
}
|
|
134
134
|
catch (err) {
|
|
135
135
|
if (__DEV__) {
|
|
136
|
+
// eslint-disable-next-line no-console -- debug logging
|
|
136
137
|
console.error(err);
|
|
137
138
|
}
|
|
138
139
|
}
|
|
@@ -153,13 +154,11 @@ var PopoverInner = /** @class */ (function (_super) {
|
|
|
153
154
|
!this.state.autoFocusAfterPositioning &&
|
|
154
155
|
this.popperRef.current !== null &&
|
|
155
156
|
this.popperRef.current.getBoundingClientRect().top > 0) {
|
|
156
|
-
// eslint-disable-next-line react/no-did-update-set-state -- conditional setState
|
|
157
157
|
this.setState({ autoFocusAfterPositioning: true });
|
|
158
158
|
}
|
|
159
159
|
// Update placement in state if a new placement value is received from props,
|
|
160
160
|
// since the initial placement from props was only used for state initialization.
|
|
161
161
|
if (prevProps.placement !== this.props.placement) {
|
|
162
|
-
// eslint-disable-next-line react/no-did-update-set-state -- conditional setState
|
|
163
162
|
this.setState({ placement: (_a = this.props.placement) !== null && _a !== void 0 ? _a : constants_1.PLACEMENT.auto });
|
|
164
163
|
}
|
|
165
164
|
if (__DEV__) {
|
|
@@ -328,7 +327,7 @@ var PopoverInner = /** @class */ (function (_super) {
|
|
|
328
327
|
}
|
|
329
328
|
return (
|
|
330
329
|
// @ts-ignore
|
|
331
|
-
(0, jsx_runtime_1.jsx)(
|
|
330
|
+
(0, jsx_runtime_1.jsx)(box_1.Box, tslib_1.__assign({ "$as": "span" }, anchorProps, { children: anchor }), "popover-anchor"));
|
|
332
331
|
};
|
|
333
332
|
PopoverInner.prototype.renderPopover = function (renderedContent) {
|
|
334
333
|
var _this = this;
|
|
@@ -119,7 +119,7 @@ var StatefulContainer = /** @class */ (function (_super) {
|
|
|
119
119
|
};
|
|
120
120
|
StatefulContainer.prototype.render = function () {
|
|
121
121
|
var _this = this;
|
|
122
|
-
var _a = this.props, accessibilityType = _a.accessibilityType, autoFocus = _a.autoFocus, animateOutTime = _a.animateOutTime, dismissOnClickOutside = _a.dismissOnClickOutside,
|
|
122
|
+
var _a = this.props, accessibilityType = _a.accessibilityType, autoFocus = _a.autoFocus, animateOutTime = _a.animateOutTime, dismissOnClickOutside = _a.dismissOnClickOutside, focusLock = _a.focusLock, ignoreBoundary = _a.ignoreBoundary, mountNode = _a.mountNode, onBlur = _a.onBlur, onClick = _a.onClick, onFocus = _a.onFocus, onMouseEnter = _a.onMouseEnter, onMouseLeave = _a.onMouseLeave, onMouseEnterDelay = _a.onMouseEnterDelay, onMouseLeaveDelay = _a.onMouseLeaveDelay, overrides = _a.overrides, placement = _a.placement, popperOptions = _a.popperOptions, renderAll = _a.renderAll, returnFocus = _a.returnFocus, showArrow = _a.showArrow, triggerType = _a.triggerType, popoverMargin = _a.popoverMargin, focusOptions = _a.focusOptions, repositionOnResize = _a.repositionOnResize, positionFixed = _a.positionFixed;
|
|
123
123
|
var popoverProps = {
|
|
124
124
|
accessibilityType: accessibilityType,
|
|
125
125
|
animateOutTime: animateOutTime,
|
package/baseui/popover/utils.js
CHANGED
|
@@ -122,8 +122,6 @@ var extractContent = function (content) {
|
|
|
122
122
|
if (Array.isArray(content) && !content.length) {
|
|
123
123
|
return null;
|
|
124
124
|
}
|
|
125
|
-
|
|
126
|
-
return typeof content === 'function' ? content() : content;
|
|
127
|
-
}
|
|
125
|
+
return typeof content === 'function' ? content() : content;
|
|
128
126
|
};
|
|
129
127
|
exports.extractContent = extractContent;
|
|
@@ -16,7 +16,7 @@ export default class AutosizeInput extends React.Component<AutosizeInputProps &
|
|
|
16
16
|
inputWidth: number;
|
|
17
17
|
};
|
|
18
18
|
componentDidMount(): void;
|
|
19
|
-
componentDidUpdate(
|
|
19
|
+
componentDidUpdate(_prevProps: AutosizeInputProps, _prevState: AutosizeInputState): void;
|
|
20
20
|
componentWillUnmount(): void;
|
|
21
21
|
sizerRef: (el?: HTMLElement | null) => void;
|
|
22
22
|
updateInputWidth(): void;
|
|
@@ -27,7 +27,7 @@ var AutosizeInput = /** @class */ (function (_super) {
|
|
|
27
27
|
this.mounted = true;
|
|
28
28
|
this.updateInputWidth();
|
|
29
29
|
};
|
|
30
|
-
AutosizeInput.prototype.componentDidUpdate = function (
|
|
30
|
+
AutosizeInput.prototype.componentDidUpdate = function (_prevProps, _prevState) {
|
|
31
31
|
this.updateInputWidth();
|
|
32
32
|
};
|
|
33
33
|
AutosizeInput.prototype.componentWillUnmount = function () {
|
|
@@ -32,7 +32,7 @@ var SelectDropdown = /** @class */ (function (_super) {
|
|
|
32
32
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
33
33
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any -- required any for option type
|
|
34
34
|
_this.getItemLabel = function (option) {
|
|
35
|
-
var _a = _this.props, getOptionLabel = _a.getOptionLabel, _b = _a.overrides, overrides = _b === void 0 ? {} : _b, value = _a.value, valueKey = _a.valueKey,
|
|
35
|
+
var _a = _this.props, getOptionLabel = _a.getOptionLabel, _b = _a.overrides, overrides = _b === void 0 ? {} : _b, value = _a.value, valueKey = _a.valueKey, _selectAllChecked = _a.selectAllChecked;
|
|
36
36
|
var _c = tslib_1.__read((0, overrides_1.getOverrides)(overrides.OptionContent, styled_components_1.StyledOptionContent), 2), OptionContent = _c[0], optionContentProps = _c[1];
|
|
37
37
|
var $selected;
|
|
38
38
|
if (Array.isArray(value)) {
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { Component
|
|
2
|
-
import type { SelectProps, SelectState, Value, Option, ChangeAction } from './types';
|
|
3
|
-
import type { SyntheticEvent, ChangeEvent } from 'react';
|
|
4
|
-
import { Options } from './types';
|
|
1
|
+
import { Component } from 'react';
|
|
2
|
+
import type { SelectProps, SelectState, Value, Option, ChangeAction, Options } from './types';
|
|
3
|
+
import type { SyntheticEvent, ChangeEvent, ReactNode, FocusEvent } from 'react';
|
|
5
4
|
type GetOptionLabel = NonNullable<SelectProps['getOptionLabel']>;
|
|
6
5
|
export declare function getOptionLabel({ option }: Parameters<GetOptionLabel>[0], { selectLocale, labelKey }: SelectProps): ReactNode;
|
|
7
6
|
type GetValueLabel = NonNullable<SelectProps['getValueLabel']>;
|
|
@@ -12,6 +12,7 @@ LICENSE file in the root directory of this source tree.
|
|
|
12
12
|
var react_1 = require("react");
|
|
13
13
|
var memoize_one_1 = tslib_1.__importDefault(require("memoize-one"));
|
|
14
14
|
var overrides_1 = require("../../overrides");
|
|
15
|
+
var box_1 = require("../../box");
|
|
15
16
|
var popover_1 = require("../popover");
|
|
16
17
|
var autosize_input_1 = tslib_1.__importDefault(require("./autosize-input"));
|
|
17
18
|
var constants_1 = require("./constants");
|
|
@@ -254,7 +255,7 @@ var Select = /** @class */ (function (_super) {
|
|
|
254
255
|
event.preventDefault();
|
|
255
256
|
_this.closeMenu();
|
|
256
257
|
if (_this.state.currentValueTagIdx === -1 && _this.state.isFocused) {
|
|
257
|
-
_this.setState(function (
|
|
258
|
+
_this.setState(function (_preState) { return ({
|
|
258
259
|
currentValueTagIdx: _this.getRenderedTagsCount() - 1,
|
|
259
260
|
}); });
|
|
260
261
|
}
|
|
@@ -299,7 +300,7 @@ var Select = /** @class */ (function (_super) {
|
|
|
299
300
|
case 'Tab': {
|
|
300
301
|
//9
|
|
301
302
|
if (_this.state.currentValueTagIdx !== -1) {
|
|
302
|
-
_this.setState(function (
|
|
303
|
+
_this.setState(function (_prevState) { return ({
|
|
303
304
|
currentValueTagIdx: -1,
|
|
304
305
|
}); });
|
|
305
306
|
}
|
|
@@ -401,7 +402,9 @@ var Select = /** @class */ (function (_super) {
|
|
|
401
402
|
break;
|
|
402
403
|
}
|
|
403
404
|
};
|
|
405
|
+
// eslint-disable-next-line class-methods-use-this -- delegates to module-level helper
|
|
404
406
|
_this.getOptionLabel = function (optionData, props) { return getOptionLabel(optionData, props); };
|
|
407
|
+
// eslint-disable-next-line class-methods-use-this -- delegates to module-level helper
|
|
405
408
|
_this.getValueLabel = function (optionData, props) { return getValueLabel(optionData, props); };
|
|
406
409
|
_this.getMemoizedOptionsMap = (0, memoize_one_1.default)(function (options, valueKey) {
|
|
407
410
|
var normalizedOptions = _this.getMemoizedNormalizedOptions(options);
|
|
@@ -753,7 +756,7 @@ var Select = /** @class */ (function (_super) {
|
|
|
753
756
|
return undefined;
|
|
754
757
|
var _a = this.props.overrides, overrides = _a === void 0 ? {} : _a;
|
|
755
758
|
var _b = tslib_1.__read((0, overrides_1.getOverrides)(overrides.LoadingIndicator, function () { return null; }), 2), LoadingIndicator = _b[0], loadingIndicatorProps = _b[1];
|
|
756
|
-
return ((0, jsx_runtime_1.jsx)(LoadingIndicator, tslib_1.__assign({ role: "status" }, loadingIndicatorProps, { children: (0, jsx_runtime_1.jsx)(
|
|
759
|
+
return ((0, jsx_runtime_1.jsx)(LoadingIndicator, tslib_1.__assign({ role: "status" }, loadingIndicatorProps, { children: (0, jsx_runtime_1.jsx)(box_1.Box, tslib_1.__assign({ "$as": "span", style: {
|
|
757
760
|
position: 'absolute',
|
|
758
761
|
width: '1px',
|
|
759
762
|
height: '1px',
|
|
@@ -853,7 +856,7 @@ var Select = /** @class */ (function (_super) {
|
|
|
853
856
|
var label = "".concat(selectedLabel).concat(this.props['aria-label'] || '');
|
|
854
857
|
var ariaDescribedBy = "".concat((_a = this.props['aria-describedby']) !== null && _a !== void 0 ? _a : '', " ").concat(ariaDescribedByIDs !== null && ariaDescribedByIDs !== void 0 ? ariaDescribedByIDs : '');
|
|
855
858
|
if (!this.props.searchable) {
|
|
856
|
-
return ((0, jsx_runtime_1.jsx)(InputContainer, tslib_1.__assign({ onFocus: this.handleInputFocus, tabIndex: this.props.disabled ? null : 0 }, sharedProps, inputContainerProps, { children: (0, jsx_runtime_1.jsx)(
|
|
859
|
+
return ((0, jsx_runtime_1.jsx)(InputContainer, tslib_1.__assign({ onFocus: this.handleInputFocus, tabIndex: this.props.disabled ? null : 0 }, sharedProps, inputContainerProps, { children: (0, jsx_runtime_1.jsx)(box_1.Box, tslib_1.__assign({ "$as": "input", "aria-hidden": true, id: this.props.id || undefined, ref: this.handleInputRef, style: {
|
|
857
860
|
opacity: 0,
|
|
858
861
|
width: '0px',
|
|
859
862
|
overflow: 'hidden',
|
|
@@ -871,7 +874,7 @@ var Select = /** @class */ (function (_super) {
|
|
|
871
874
|
if (!this.props.clearable || this.props.disabled || this.props.isLoading || !isValueEntered) {
|
|
872
875
|
return null;
|
|
873
876
|
}
|
|
874
|
-
var _b = this.getSharedProps(), $size = _b.$size, sharedProps = tslib_1.__rest(_b, ["$size"]);
|
|
877
|
+
var _b = this.getSharedProps(), _$size = _b.$size, sharedProps = tslib_1.__rest(_b, ["$size"]);
|
|
875
878
|
var _c = this.props.overrides, overrides = _c === void 0 ? {} : _c;
|
|
876
879
|
var _d = tslib_1.__read((0, overrides_1.getOverrides)(overrides.ClearIcon, function () { return null; }), 2), ClearIcon = _d[0], clearIconProps = _d[1];
|
|
877
880
|
var ariaLabel = this.props.multi ? 'Clear all' : 'Clear value';
|
|
@@ -888,7 +891,7 @@ var Select = /** @class */ (function (_super) {
|
|
|
888
891
|
if (this.props.type !== constants_1.TYPE.select) {
|
|
889
892
|
return null;
|
|
890
893
|
}
|
|
891
|
-
var _b = this.getSharedProps(), $size = _b.$size, sharedProps = tslib_1.__rest(_b, ["$size"]);
|
|
894
|
+
var _b = this.getSharedProps(), _$size = _b.$size, sharedProps = tslib_1.__rest(_b, ["$size"]);
|
|
892
895
|
var _c = this.props.overrides, overrides = _c === void 0 ? {} : _c;
|
|
893
896
|
var _d = tslib_1.__read((0, overrides_1.getOverrides)(overrides.SelectArrow, function () { return null; }), 2), SelectArrow = _d[0], selectArrowProps = _d[1];
|
|
894
897
|
var sizes = (_a = {},
|
|
@@ -939,11 +942,11 @@ var Select = /** @class */ (function (_super) {
|
|
|
939
942
|
}
|
|
940
943
|
// can user create a new option + there's no exact match already
|
|
941
944
|
var filterDoesNotMatchOption = this.props.ignoreCase
|
|
942
|
-
? // @ts-ignore
|
|
943
|
-
function (// @ts-ignore
|
|
945
|
+
? // @ts-ignore -- option label key is dynamic string index
|
|
946
|
+
function (// @ts-ignore -- option label key is dynamic string index
|
|
944
947
|
opt) { return opt[_this.props.labelKey].toLowerCase() !== filterValue.toLowerCase().trim(); }
|
|
945
|
-
: // @ts-ignore
|
|
946
|
-
function (// @ts-ignore
|
|
948
|
+
: // @ts-ignore -- option label key is dynamic string index
|
|
949
|
+
function (// @ts-ignore -- option label key is dynamic string index
|
|
947
950
|
opt) { return opt[_this.props.labelKey] !== filterValue.trim(); };
|
|
948
951
|
if (filterValue &&
|
|
949
952
|
this.props.creatable &&
|
|
@@ -988,6 +991,7 @@ var Select = /** @class */ (function (_super) {
|
|
|
988
991
|
if (__DEV__) {
|
|
989
992
|
// value may be nullish, only warn if value is defined
|
|
990
993
|
if (value && !Array.isArray(value)) {
|
|
994
|
+
// eslint-disable-next-line no-console -- debug logging
|
|
991
995
|
console.warn('The Select component expects an array as the value prop. For more information, please visit the docs at https://baseweb.design/components/select/');
|
|
992
996
|
}
|
|
993
997
|
}
|
|
@@ -1022,6 +1026,7 @@ var Select = /** @class */ (function (_super) {
|
|
|
1022
1026
|
sharedProps.$isOpen = isOpen;
|
|
1023
1027
|
if (__DEV__) {
|
|
1024
1028
|
if (this.props.error && this.props.positive) {
|
|
1029
|
+
// eslint-disable-next-line no-console -- debug logging
|
|
1025
1030
|
console.warn('[Select] `error` and `positive` are both set to `true`. `error` will take precedence but this may not be what you want.');
|
|
1026
1031
|
}
|
|
1027
1032
|
}
|
|
@@ -21,24 +21,20 @@ var StatefulSelectContainer = /** @class */ (function (_super) {
|
|
|
21
21
|
_this.internalSetState = function (params) {
|
|
22
22
|
var stateReducer = _this.props.stateReducer;
|
|
23
23
|
var nextState = { value: params.value };
|
|
24
|
-
_this.setState(stateReducer(params.type, nextState,
|
|
24
|
+
_this.setState(function (prevState) { return stateReducer(params.type, nextState, prevState); });
|
|
25
25
|
};
|
|
26
26
|
return _this;
|
|
27
27
|
}
|
|
28
28
|
StatefulSelectContainer.prototype.render = function () {
|
|
29
|
-
var _a = this.props, children = _a.children,
|
|
30
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
31
|
-
initialState = _a.initialState, // eslint-disable-line no-unused-vars
|
|
32
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
33
|
-
stateReducer = _a.stateReducer, // eslint-disable-line no-unused-vars
|
|
34
|
-
restProps = tslib_1.__rest(_a, ["children", "initialState", "stateReducer"]);
|
|
29
|
+
var _a = this.props, children = _a.children, _initialState = _a.initialState, _stateReducer = _a.stateReducer, restProps = tslib_1.__rest(_a, ["children", "initialState", "stateReducer"]);
|
|
35
30
|
return children(tslib_1.__assign(tslib_1.__assign(tslib_1.__assign({}, restProps), this.state), { onChange: this.onChange }));
|
|
36
31
|
};
|
|
37
32
|
StatefulSelectContainer.defaultProps = {
|
|
38
33
|
initialState: {
|
|
39
|
-
// @ts-ignore
|
|
34
|
+
// @ts-ignore -- empty Value[] is valid uncontrolled initial state
|
|
40
35
|
value: [],
|
|
41
36
|
},
|
|
37
|
+
// eslint-disable-next-line @typescript-eslint/no-empty-function -- default no-op onChange
|
|
42
38
|
onChange: function () { },
|
|
43
39
|
overrides: {},
|
|
44
40
|
stateReducer: defaultStateReducer,
|
package/baseui/select/types.d.ts
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import type * as React from 'react';
|
|
2
|
-
import { Override } from '../../overrides';
|
|
2
|
+
import type { Override } from '../../overrides';
|
|
3
3
|
import type { STATE_CHANGE_TYPE, SIZE, TYPE } from './constants';
|
|
4
4
|
import type { OnItemSelectFn } from '../menu';
|
|
5
5
|
export type ChangeAction = keyof typeof STATE_CHANGE_TYPE;
|
|
6
6
|
export type Size = keyof typeof SIZE;
|
|
7
7
|
export type Type = keyof typeof TYPE;
|
|
8
|
-
import { SelectLocale } from '../../select/locale';
|
|
8
|
+
import type { SelectLocale } from '../../select/locale';
|
|
9
9
|
import type { ActionableTooltipProps, TooltipProps } from '../../tooltip';
|
|
10
|
-
import { ReactElement } from 'react';
|
|
11
10
|
import type { Intent } from '../../types';
|
|
12
11
|
export type Id = string | number;
|
|
13
12
|
export type Option = Readonly<{
|
|
@@ -227,7 +226,7 @@ export type SelectProps = {
|
|
|
227
226
|
/** expand all the extra tags in case of limit tag */
|
|
228
227
|
expandLimitTagsOnFocus?: boolean;
|
|
229
228
|
/** render Footer for dropdown */
|
|
230
|
-
dropdownFooter?: (props: DropdownFooterProps) => ReactElement;
|
|
229
|
+
dropdownFooter?: (props: DropdownFooterProps) => React.ReactElement;
|
|
231
230
|
ownerDocument?: Document;
|
|
232
231
|
listboxId?: string;
|
|
233
232
|
menuDescriptionId?: string;
|
|
@@ -293,7 +292,7 @@ export type DropdownProps = {
|
|
|
293
292
|
width: number | undefined | null;
|
|
294
293
|
keyboardControlNode?: React.Ref<HTMLElement>;
|
|
295
294
|
closeMenu: () => void;
|
|
296
|
-
dropdownFooter?: (props: DropdownFooterProps) => ReactElement;
|
|
295
|
+
dropdownFooter?: (props: DropdownFooterProps) => React.ReactElement;
|
|
297
296
|
menuDescriptionId?: string;
|
|
298
297
|
};
|
|
299
298
|
export type DropdownFooterProps = Pick<DropdownProps, 'isLoading' | 'width' | 'closeMenu'>;
|
|
@@ -7,9 +7,7 @@ function groupedOptionsToArray(groupedOptions) {
|
|
|
7
7
|
var optgroupOptions = groupedOptions[optgroup];
|
|
8
8
|
return arr.concat(
|
|
9
9
|
// @ts-ignore
|
|
10
|
-
optgroupOptions.map(function (option) {
|
|
11
|
-
return tslib_1.__assign(tslib_1.__assign({}, option), { __optgroup: optgroup });
|
|
12
|
-
}));
|
|
10
|
+
optgroupOptions.map(function (option) { return (tslib_1.__assign(tslib_1.__assign({}, option), { __optgroup: optgroup })); }));
|
|
13
11
|
}, []);
|
|
14
12
|
}
|
|
15
13
|
function normalizeOptions(options) {
|
|
@@ -17,9 +15,7 @@ function normalizeOptions(options) {
|
|
|
17
15
|
if (Array.isArray(options)) {
|
|
18
16
|
return options;
|
|
19
17
|
}
|
|
20
|
-
|
|
21
|
-
return groupedOptionsToArray(options);
|
|
22
|
-
}
|
|
18
|
+
return groupedOptionsToArray(options);
|
|
23
19
|
}
|
|
24
20
|
return [];
|
|
25
21
|
}
|
package/baseui/select/value.js
CHANGED
|
@@ -11,7 +11,11 @@ var TruncateWithTooltip_1 = require("../../truncateWithTooltip/TruncateWithToolt
|
|
|
11
11
|
var Value = function (props) {
|
|
12
12
|
var _a = props.overrides, overrides = _a === void 0 ? {} : _a, noTooltipOnTruncation = props.noTooltipOnTruncation, restProps = tslib_1.__rest(props, ["overrides", "noTooltipOnTruncation"]);
|
|
13
13
|
var _b = tslib_1.__read((0, overrides_1.useOverrides)(overrides.SingleValue, styled_components_1.StyledSingleValue), 2), SingleValue = _b[0], _c = _b[1], onMouseEnter = _c.onMouseEnter, onMouseLeave = _c.onMouseLeave, singleValueProps = tslib_1.__rest(_c, ["onMouseEnter", "onMouseLeave"]);
|
|
14
|
-
var _d = (0, useTruncateWithTooltip_1.useTruncateWithTooltip)(
|
|
14
|
+
var _d = (0, useTruncateWithTooltip_1.useTruncateWithTooltip)({
|
|
15
|
+
noTooltipOnTruncation: noTooltipOnTruncation,
|
|
16
|
+
onMouseEnter: onMouseEnter,
|
|
17
|
+
onMouseLeave: onMouseLeave,
|
|
18
|
+
}), mouseEventProps = _d.mouseEventProps, renderTooltip = _d.renderTooltip, elementRef = _d.elementRef;
|
|
15
19
|
var el = ((0, jsx_runtime_1.jsx)(SingleValue, tslib_1.__assign({ ref: elementRef }, mouseEventProps, restProps, singleValueProps, { children: props.children })));
|
|
16
20
|
return renderTooltip ? ((0, jsx_runtime_1.jsx)(tooltip_1.StatefulTooltip, tslib_1.__assign({ initialState: TruncateWithTooltip_1.INITIAL_STATE, content: (0, jsx_runtime_1.jsx)(box_1.Box, tslib_1.__assign({ "data-testid": "tooltip", className: "max-w-2xl break-words" }, { children: props.children })), placement: "bottom", accessibilityType: "tooltip" }, mouseEventProps, { children: el }))) : (el);
|
|
17
21
|
};
|
|
@@ -63,7 +63,9 @@ var TimePicker = /** @class */ (function (_super) {
|
|
|
63
63
|
_this.handleChange(seconds);
|
|
64
64
|
};
|
|
65
65
|
_this.secondsToLabel = function (seconds, format, langCode) {
|
|
66
|
-
var
|
|
66
|
+
var hourMinute = _this.dateHelpers.secondsToHourMinute(seconds);
|
|
67
|
+
var hours = hourMinute[0];
|
|
68
|
+
var minutes = hourMinute[1];
|
|
67
69
|
var zeroPrefix = function (n) { return (n < 10 ? "0".concat(n) : n); };
|
|
68
70
|
if (format === '12') {
|
|
69
71
|
var isAfterNoon = seconds >= NOON;
|
|
@@ -91,7 +93,6 @@ var TimePicker = /** @class */ (function (_super) {
|
|
|
91
93
|
* Converts a time string, e.g. 10:00, to one or more possible TimePicker
|
|
92
94
|
* options representing that time.
|
|
93
95
|
*/
|
|
94
|
-
// eslint-disable-next-line max-statements -- function is required
|
|
95
96
|
_this.stringToOptions = function (str, format) {
|
|
96
97
|
if (format === void 0) { format = '12'; }
|
|
97
98
|
// leading zero is optional, AM/PM is optional
|
|
@@ -147,7 +148,8 @@ var TimePicker = /** @class */ (function (_super) {
|
|
|
147
148
|
return setSeconds(setMinutes(setHours(date, hours), minutes), seconds);
|
|
148
149
|
};
|
|
149
150
|
_this.getTimeWindowInSeconds = function () {
|
|
150
|
-
var _a = _this.props, min = _a.minTime, max = _a.maxTime
|
|
151
|
+
var _a = _this.props, min = _a.minTime, max = _a.maxTime;
|
|
152
|
+
var ignoreMinMaxDateComponent = _this.props.ignoreMinMaxDateComponent;
|
|
151
153
|
var dayStart = _this.setTime(_this.props.value, 0, 0, 0);
|
|
152
154
|
var dayEnd = _this.setTime(_this.props.value, 24, 0, 0);
|
|
153
155
|
if (!min || (_this.props.adapter.isBefore(min, dayStart) && !ignoreMinMaxDateComponent)) {
|
|
@@ -174,9 +176,8 @@ var TimePicker = /** @class */ (function (_super) {
|
|
|
174
176
|
end: (maxDate - midnightDate) / 1000,
|
|
175
177
|
};
|
|
176
178
|
};
|
|
177
|
-
// eslint-disable-next-line max-statements -- required for performing validation
|
|
178
179
|
_this.buildSteps = function () {
|
|
179
|
-
var _a = _this.props, _b = _a.step, step = _b === void 0 ? 900 : _b, timeRanges = _a.timeRanges,
|
|
180
|
+
var _a = _this.props, _b = _a.step, step = _b === void 0 ? 900 : _b, timeRanges = _a.timeRanges, _value = _a.value;
|
|
180
181
|
var timeWindow = _this.getTimeWindowInSeconds();
|
|
181
182
|
var stepCount = (timeWindow.end - timeWindow.start) / step;
|
|
182
183
|
if (process.env.NODE_ENV !== 'production' && stepCount > 500) {
|
|
@@ -267,11 +268,9 @@ var TimePicker = /** @class */ (function (_super) {
|
|
|
267
268
|
}
|
|
268
269
|
if (formatChanged || stepChanged || minTimeChange || maxTimeChange || timeRangesChanged) {
|
|
269
270
|
var steps = this.buildSteps();
|
|
270
|
-
// eslint-disable-next-line react/no-did-update-set-state -- baseui migration
|
|
271
271
|
this.setState({ steps: steps });
|
|
272
272
|
}
|
|
273
273
|
if (prevProps.value && !this.props.value) {
|
|
274
|
-
// eslint-disable-next-line react/no-did-update-set-state -- baseui migration
|
|
275
274
|
this.setState({ value: null });
|
|
276
275
|
}
|
|
277
276
|
};
|
|
@@ -2,7 +2,7 @@ import type { Override } from '../../overrides';
|
|
|
2
2
|
import type { Option } from '../select';
|
|
3
3
|
import type { Size } from '../input';
|
|
4
4
|
import type { DateIOAdapter } from '../datepicker/utils/types';
|
|
5
|
-
import { TimeRange } from '../datepicker/types';
|
|
5
|
+
import type { TimeRange } from '../datepicker/types';
|
|
6
6
|
export type TimePickerOverrides = {
|
|
7
7
|
Select?: Override<Record<string, any>>;
|
|
8
8
|
};
|