@transferwise/components 0.0.0-experimental-010a0a4 → 0.0.0-experimental-666b489
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/build/accordion/Accordion.js.map +1 -1
- package/build/accordion/Accordion.mjs.map +1 -1
- package/build/accordion/AccordionItem/AccordionItem.js.map +1 -1
- package/build/accordion/AccordionItem/AccordionItem.mjs.map +1 -1
- package/build/actionButton/ActionButton.js.map +1 -1
- package/build/actionButton/ActionButton.mjs.map +1 -1
- package/build/actionOption/ActionOption.js.map +1 -1
- package/build/actionOption/ActionOption.mjs.map +1 -1
- package/build/alert/Alert.js.map +1 -1
- package/build/alert/Alert.mjs.map +1 -1
- package/build/alert/inlineMarkdown/InlineMarkdown.js.map +1 -1
- package/build/alert/inlineMarkdown/InlineMarkdown.mjs.map +1 -1
- package/build/avatar/Avatar.js.map +1 -1
- package/build/avatar/Avatar.mjs.map +1 -1
- package/build/avatar/avatarTypes.js.map +1 -1
- package/build/avatar/avatarTypes.mjs.map +1 -1
- package/build/avatarLayout/AvatarLayout.js.map +1 -1
- package/build/avatarLayout/AvatarLayout.mjs.map +1 -1
- package/build/avatarView/AvatarView.js.map +1 -1
- package/build/avatarView/AvatarView.mjs.map +1 -1
- package/build/avatarView/NotificationDot.js.map +1 -1
- package/build/avatarView/NotificationDot.mjs.map +1 -1
- package/build/avatarWrapper/AvatarWrapper.js.map +1 -1
- package/build/avatarWrapper/AvatarWrapper.mjs.map +1 -1
- package/build/badge/Badge.js.map +1 -1
- package/build/badge/Badge.mjs.map +1 -1
- package/build/badge/BadgeAssets.js.map +1 -1
- package/build/badge/BadgeAssets.mjs.map +1 -1
- package/build/body/Body.js.map +1 -1
- package/build/body/Body.mjs.map +1 -1
- package/build/button/Button.js.map +1 -1
- package/build/button/Button.mjs.map +1 -1
- package/build/button/Button.resolver.js.map +1 -1
- package/build/button/Button.resolver.mjs.map +1 -1
- package/build/button/LegacyButton.js.map +1 -1
- package/build/button/LegacyButton.mjs +1 -1
- package/build/button/LegacyButton.mjs.map +1 -1
- package/build/button/classMap.js.map +1 -1
- package/build/button/classMap.mjs.map +1 -1
- package/build/button/legacyUtils/legacyUtils.js.map +1 -1
- package/build/button/legacyUtils/legacyUtils.mjs.map +1 -1
- package/build/card/Card.js.map +1 -1
- package/build/card/Card.mjs.map +1 -1
- package/build/carousel/Carousel.js.map +1 -1
- package/build/carousel/Carousel.mjs.map +1 -1
- package/build/checkbox/Checkbox.js.map +1 -1
- package/build/checkbox/Checkbox.mjs.map +1 -1
- package/build/checkboxButton/CheckboxButton.js.map +1 -1
- package/build/checkboxButton/CheckboxButton.mjs.map +1 -1
- package/build/checkboxOption/CheckboxOption.js.map +1 -1
- package/build/checkboxOption/CheckboxOption.mjs.map +1 -1
- package/build/chevron/Chevron.js.map +1 -1
- package/build/chevron/Chevron.mjs.map +1 -1
- package/build/chips/Chip.js.map +1 -1
- package/build/chips/Chip.mjs.map +1 -1
- package/build/chips/Chips.js.map +1 -1
- package/build/chips/Chips.messages.js.map +1 -1
- package/build/chips/Chips.messages.mjs.map +1 -1
- package/build/chips/Chips.mjs.map +1 -1
- package/build/circularButton/CircularButton.js.map +1 -1
- package/build/circularButton/CircularButton.mjs.map +1 -1
- package/build/common/DOMOperations/DOMOperations.js.map +1 -1
- package/build/common/DOMOperations/DOMOperations.mjs.map +1 -1
- package/build/common/Option/Option.js.map +1 -1
- package/build/common/Option/Option.mjs.map +1 -1
- package/build/common/RadioButton/RadioButton.js.map +1 -1
- package/build/common/RadioButton/RadioButton.mjs.map +1 -1
- package/build/common/bottomSheet/BottomSheet.js.map +1 -1
- package/build/common/bottomSheet/BottomSheet.mjs.map +1 -1
- package/build/common/card/Card.js.map +1 -1
- package/build/common/card/Card.mjs.map +1 -1
- package/build/common/circle/Circle.js.map +1 -1
- package/build/common/circle/Circle.mjs.map +1 -1
- package/build/common/closeButton/CloseButton.js.map +1 -1
- package/build/common/closeButton/CloseButton.messages.js.map +1 -1
- package/build/common/closeButton/CloseButton.messages.mjs.map +1 -1
- package/build/common/closeButton/CloseButton.mjs.map +1 -1
- package/build/common/colors.js.map +1 -1
- package/build/common/colors.mjs.map +1 -1
- package/build/common/dateUtils/getDateView/getDateView.js.map +1 -1
- package/build/common/dateUtils/getDateView/getDateView.mjs.map +1 -1
- package/build/common/dateUtils/getDayNames/getDayNames.js.map +1 -1
- package/build/common/dateUtils/getDayNames/getDayNames.mjs.map +1 -1
- package/build/common/dateUtils/getFormatForLocale/getFormatForLocale.js.map +1 -1
- package/build/common/dateUtils/getFormatForLocale/getFormatForLocale.mjs.map +1 -1
- package/build/common/dateUtils/getMonthNames/getMonthNames.js.map +1 -1
- package/build/common/dateUtils/getMonthNames/getMonthNames.mjs.map +1 -1
- package/build/common/dateUtils/isDateValid/isDateValid.js.map +1 -1
- package/build/common/dateUtils/isDateValid/isDateValid.mjs.map +1 -1
- package/build/common/dateUtils/isWithinRange/isWithinRange.js.map +1 -1
- package/build/common/dateUtils/isWithinRange/isWithinRange.mjs.map +1 -1
- package/build/common/dateUtils/moveToWithinRange/moveToWithinRange.js.map +1 -1
- package/build/common/dateUtils/moveToWithinRange/moveToWithinRange.mjs.map +1 -1
- package/build/common/deviceDetection/deviceDetection.js.map +1 -1
- package/build/common/deviceDetection/deviceDetection.mjs.map +1 -1
- package/build/common/direction.js.map +1 -1
- package/build/common/direction.mjs.map +1 -1
- package/build/common/domHelpers/documentIosClick.js.map +1 -1
- package/build/common/domHelpers/documentIosClick.mjs.map +1 -1
- package/build/common/fileType.js.map +1 -1
- package/build/common/fileType.mjs.map +1 -1
- package/build/common/flowHeader/FlowHeader.js.map +1 -1
- package/build/common/flowHeader/FlowHeader.mjs.map +1 -1
- package/build/common/focusBoundary/FocusBoundary.js.map +1 -1
- package/build/common/focusBoundary/FocusBoundary.mjs.map +1 -1
- package/build/common/historyNavigator/historyNavigator.js.map +1 -1
- package/build/common/historyNavigator/historyNavigator.mjs.map +1 -1
- package/build/common/hooks/useConditionalListener/useConditionalListener.js.map +1 -1
- package/build/common/hooks/useConditionalListener/useConditionalListener.mjs.map +1 -1
- package/build/common/hooks/useDirection/useDirection.js.map +1 -1
- package/build/common/hooks/useDirection/useDirection.mjs.map +1 -1
- package/build/common/hooks/useEffectEvent.js.map +1 -1
- package/build/common/hooks/useEffectEvent.mjs.map +1 -1
- package/build/common/hooks/useHasIntersected/useHasIntersected.js.map +1 -1
- package/build/common/hooks/useHasIntersected/useHasIntersected.mjs.map +1 -1
- package/build/common/hooks/useLayout/useLayout.js.map +1 -1
- package/build/common/hooks/useLayout/useLayout.mjs.map +1 -1
- package/build/common/hooks/useMedia.js.map +1 -1
- package/build/common/hooks/useMedia.mjs.map +1 -1
- package/build/common/hooks/useResizeObserver.js.map +1 -1
- package/build/common/hooks/useResizeObserver.mjs.map +1 -1
- package/build/common/hooks/useScreenSize.js.map +1 -1
- package/build/common/hooks/useScreenSize.mjs.map +1 -1
- package/build/common/hooks/useVirtualKeyboard.js.map +1 -1
- package/build/common/hooks/useVirtualKeyboard.mjs.map +1 -1
- package/build/common/initials.js.map +1 -1
- package/build/common/initials.mjs.map +1 -1
- package/build/common/locale/index.js.map +1 -1
- package/build/common/locale/index.mjs.map +1 -1
- package/build/common/panel/Panel.js.map +1 -1
- package/build/common/panel/Panel.mjs.map +1 -1
- package/build/common/polymorphicWithOverrides/PolymorphicWithOverrides.js.map +1 -1
- package/build/common/polymorphicWithOverrides/PolymorphicWithOverrides.mjs.map +1 -1
- package/build/common/preventScroll/PreventScroll.js.map +1 -1
- package/build/common/preventScroll/PreventScroll.mjs.map +1 -1
- package/build/common/propsValues/breakpoint.js.map +1 -1
- package/build/common/propsValues/breakpoint.mjs.map +1 -1
- package/build/common/propsValues/control.js.map +1 -1
- package/build/common/propsValues/control.mjs.map +1 -1
- package/build/common/propsValues/dateMode.js.map +1 -1
- package/build/common/propsValues/dateMode.mjs.map +1 -1
- package/build/common/propsValues/layouts.js.map +1 -1
- package/build/common/propsValues/layouts.mjs.map +1 -1
- package/build/common/propsValues/markdownNodeType.js.map +1 -1
- package/build/common/propsValues/markdownNodeType.mjs.map +1 -1
- package/build/common/propsValues/monthFormat.js.map +1 -1
- package/build/common/propsValues/monthFormat.mjs.map +1 -1
- package/build/common/propsValues/position.js.map +1 -1
- package/build/common/propsValues/position.mjs.map +1 -1
- package/build/common/propsValues/profileType.js.map +1 -1
- package/build/common/propsValues/profileType.mjs.map +1 -1
- package/build/common/propsValues/scroll.js.map +1 -1
- package/build/common/propsValues/scroll.mjs.map +1 -1
- package/build/common/propsValues/sentiment.js.map +1 -1
- package/build/common/propsValues/sentiment.mjs.map +1 -1
- package/build/common/propsValues/size.js.map +1 -1
- package/build/common/propsValues/size.mjs.map +1 -1
- package/build/common/propsValues/status.js.map +1 -1
- package/build/common/propsValues/status.mjs.map +1 -1
- package/build/common/propsValues/type.js.map +1 -1
- package/build/common/propsValues/type.mjs.map +1 -1
- package/build/common/propsValues/typography.js.map +1 -1
- package/build/common/propsValues/typography.mjs.map +1 -1
- package/build/common/propsValues/variant.js.map +1 -1
- package/build/common/propsValues/variant.mjs.map +1 -1
- package/build/common/propsValues/width.js.map +1 -1
- package/build/common/propsValues/width.mjs.map +1 -1
- package/build/common/responsivePanel/ResponsivePanel.js.map +1 -1
- package/build/common/responsivePanel/ResponsivePanel.mjs.map +1 -1
- package/build/common/textFormat/formatWithPattern/formatWithPattern.js.map +1 -1
- package/build/common/textFormat/formatWithPattern/formatWithPattern.mjs.map +1 -1
- package/build/common/textFormat/getCursorPositionAfterKeystroke/getCursorPositionAfterKeystroke.js.map +1 -1
- package/build/common/textFormat/getCursorPositionAfterKeystroke/getCursorPositionAfterKeystroke.mjs.map +1 -1
- package/build/common/textFormat/getDistanceToSymbol/getDistanceToSymbol.js.map +1 -1
- package/build/common/textFormat/getDistanceToSymbol/getDistanceToSymbol.mjs.map +1 -1
- package/build/common/textFormat/getSymbolsInPatternWithPosition/getSymbolsInPatternWithPosition.js.map +1 -1
- package/build/common/textFormat/getSymbolsInPatternWithPosition/getSymbolsInPatternWithPosition.mjs.map +1 -1
- package/build/common/textFormat/unformatWithPattern/unformatWithPattern.js.map +1 -1
- package/build/common/textFormat/unformatWithPattern/unformatWithPattern.mjs.map +1 -1
- package/build/common/theme.js.map +1 -1
- package/build/common/theme.mjs.map +1 -1
- package/build/criticalBanner/CriticalCommsBanner.js.map +1 -1
- package/build/criticalBanner/CriticalCommsBanner.mjs.map +1 -1
- package/build/dateInput/DateInput.js.map +1 -1
- package/build/dateInput/DateInput.messages.js.map +1 -1
- package/build/dateInput/DateInput.messages.mjs.map +1 -1
- package/build/dateInput/DateInput.mjs.map +1 -1
- package/build/dateInput/utils/convertToLocalMidnight/convertToLocalMidnight.js.map +1 -1
- package/build/dateInput/utils/convertToLocalMidnight/convertToLocalMidnight.mjs.map +1 -1
- package/build/dateLookup/DateLookup.js +4 -4
- package/build/dateLookup/DateLookup.js.map +1 -1
- package/build/dateLookup/DateLookup.messages.js.map +1 -1
- package/build/dateLookup/DateLookup.messages.mjs.map +1 -1
- package/build/dateLookup/DateLookup.mjs +4 -4
- package/build/dateLookup/DateLookup.mjs.map +1 -1
- package/build/dateLookup/dateHeader/DateHeader.js.map +1 -1
- package/build/dateLookup/dateHeader/DateHeader.mjs.map +1 -1
- package/build/dateLookup/dateTrigger/DateTrigger.js.map +1 -1
- package/build/dateLookup/dateTrigger/DateTrigger.messages.js.map +1 -1
- package/build/dateLookup/dateTrigger/DateTrigger.messages.mjs.map +1 -1
- package/build/dateLookup/dateTrigger/DateTrigger.mjs.map +1 -1
- package/build/dateLookup/dayCalendar/DayCalendar.js.map +1 -1
- package/build/dateLookup/dayCalendar/DayCalendar.mjs.map +1 -1
- package/build/dateLookup/dayCalendar/table/DayCalendarTable.js +3 -3
- package/build/dateLookup/dayCalendar/table/DayCalendarTable.js.map +1 -1
- package/build/dateLookup/dayCalendar/table/DayCalendarTable.mjs +3 -3
- package/build/dateLookup/dayCalendar/table/DayCalendarTable.mjs.map +1 -1
- package/build/dateLookup/getFocusableTime/getFocusableTime.js.map +1 -1
- package/build/dateLookup/getFocusableTime/getFocusableTime.mjs.map +1 -1
- package/build/dateLookup/getStartOfDay/getStartOfDay.js.map +1 -1
- package/build/dateLookup/getStartOfDay/getStartOfDay.mjs.map +1 -1
- package/build/dateLookup/monthCalendar/MonthCalendar.js.map +1 -1
- package/build/dateLookup/monthCalendar/MonthCalendar.mjs.map +1 -1
- package/build/dateLookup/monthCalendar/table/MonthCalendarTable.js.map +1 -1
- package/build/dateLookup/monthCalendar/table/MonthCalendarTable.mjs.map +1 -1
- package/build/dateLookup/tableLink/TableLink.js.map +1 -1
- package/build/dateLookup/tableLink/TableLink.mjs.map +1 -1
- package/build/dateLookup/yearCalendar/YearCalendar.js.map +1 -1
- package/build/dateLookup/yearCalendar/YearCalendar.mjs.map +1 -1
- package/build/dateLookup/yearCalendar/table/YearCalendarTable.js.map +1 -1
- package/build/dateLookup/yearCalendar/table/YearCalendarTable.mjs.map +1 -1
- package/build/decision/Decision.js.map +1 -1
- package/build/decision/Decision.mjs.map +1 -1
- package/build/definitionList/DefinitionList.js.map +1 -1
- package/build/definitionList/DefinitionList.mjs.map +1 -1
- package/build/dimmer/Dimmer.js +67 -41
- package/build/dimmer/Dimmer.js.map +1 -1
- package/build/dimmer/Dimmer.mjs +69 -43
- package/build/dimmer/Dimmer.mjs.map +1 -1
- package/build/dimmer/dimmerManager/DimmerManager.js.map +1 -1
- package/build/dimmer/dimmerManager/DimmerManager.mjs.map +1 -1
- package/build/display/Display.js.map +1 -1
- package/build/display/Display.mjs.map +1 -1
- package/build/divider/Divider.js.map +1 -1
- package/build/divider/Divider.mjs.map +1 -1
- package/build/drawer/Drawer.js.map +1 -1
- package/build/drawer/Drawer.mjs.map +1 -1
- package/build/dropFade/DropFade.js.map +1 -1
- package/build/dropFade/DropFade.mjs.map +1 -1
- package/build/emphasis/Emphasis.js.map +1 -1
- package/build/emphasis/Emphasis.mjs.map +1 -1
- package/build/emphasis/EmphasisHtmlTransformer.js.map +1 -1
- package/build/emphasis/EmphasisHtmlTransformer.mjs.map +1 -1
- package/build/field/Field.js.map +1 -1
- package/build/field/Field.mjs.map +1 -1
- package/build/flowNavigation/FlowNavigation.js.map +1 -1
- package/build/flowNavigation/FlowNavigation.messages.js.map +1 -1
- package/build/flowNavigation/FlowNavigation.messages.mjs.map +1 -1
- package/build/flowNavigation/FlowNavigation.mjs.map +1 -1
- package/build/flowNavigation/animatedLabel/AnimatedLabel.js.map +1 -1
- package/build/flowNavigation/animatedLabel/AnimatedLabel.mjs.map +1 -1
- package/build/header/Header.js.map +1 -1
- package/build/header/Header.mjs.map +1 -1
- package/build/i18n/commonMessages/Button.messages.js.map +1 -1
- package/build/i18n/commonMessages/Button.messages.mjs.map +1 -1
- package/build/i18n/index.js.map +1 -1
- package/build/i18n/index.mjs.map +1 -1
- package/build/iconButton/IconButton.js.map +1 -1
- package/build/iconButton/IconButton.mjs.map +1 -1
- package/build/image/Image.js.map +1 -1
- package/build/image/Image.mjs.map +1 -1
- package/build/info/Info.js.map +1 -1
- package/build/info/Info.messages.js.map +1 -1
- package/build/info/Info.messages.mjs.map +1 -1
- package/build/info/Info.mjs.map +1 -1
- package/build/info/infoPresentations.js.map +1 -1
- package/build/info/infoPresentations.mjs.map +1 -1
- package/build/inlineAlert/InlineAlert.js.map +1 -1
- package/build/inlineAlert/InlineAlert.mjs.map +1 -1
- package/build/inputWithDisplayFormat/InputWithDisplayFormat.js.map +1 -1
- package/build/inputWithDisplayFormat/InputWithDisplayFormat.mjs.map +1 -1
- package/build/inputs/Input.js.map +1 -1
- package/build/inputs/Input.mjs.map +1 -1
- package/build/inputs/InputGroup.js +16 -20
- package/build/inputs/InputGroup.js.map +1 -1
- package/build/inputs/InputGroup.mjs +17 -21
- package/build/inputs/InputGroup.mjs.map +1 -1
- package/build/inputs/SearchInput.js.map +1 -1
- package/build/inputs/SearchInput.mjs.map +1 -1
- package/build/inputs/SelectInput.js +6 -1
- package/build/inputs/SelectInput.js.map +1 -1
- package/build/inputs/SelectInput.messages.js.map +1 -1
- package/build/inputs/SelectInput.messages.mjs.map +1 -1
- package/build/inputs/SelectInput.mjs +6 -1
- package/build/inputs/SelectInput.mjs.map +1 -1
- package/build/inputs/TextArea.js.map +1 -1
- package/build/inputs/TextArea.mjs.map +1 -1
- package/build/inputs/_BottomSheet.js +8 -1
- package/build/inputs/_BottomSheet.js.map +1 -1
- package/build/inputs/_BottomSheet.mjs +9 -2
- package/build/inputs/_BottomSheet.mjs.map +1 -1
- package/build/inputs/_ButtonInput.js.map +1 -1
- package/build/inputs/_ButtonInput.mjs.map +1 -1
- package/build/inputs/_Popover.js +8 -1
- package/build/inputs/_Popover.js.map +1 -1
- package/build/inputs/_Popover.mjs +10 -3
- package/build/inputs/_Popover.mjs.map +1 -1
- package/build/inputs/_common.js.map +1 -1
- package/build/inputs/_common.mjs.map +1 -1
- package/build/inputs/contexts.js.map +1 -1
- package/build/inputs/contexts.mjs.map +1 -1
- package/build/instructionsList/InstructionsList.js.map +1 -1
- package/build/instructionsList/InstructionsList.mjs.map +1 -1
- package/build/label/Label.js.map +1 -1
- package/build/label/Label.messages.js.map +1 -1
- package/build/label/Label.messages.mjs.map +1 -1
- package/build/label/Label.mjs.map +1 -1
- package/build/legacylistItem/LegacyListItem.js.map +1 -1
- package/build/legacylistItem/LegacyListItem.mjs.map +1 -1
- package/build/legacylistItem/List.js.map +1 -1
- package/build/legacylistItem/List.mjs.map +1 -1
- package/build/link/Link.js.map +1 -1
- package/build/link/Link.messages.js.map +1 -1
- package/build/link/Link.messages.mjs.map +1 -1
- package/build/link/Link.mjs.map +1 -1
- package/build/loader/Loader.js.map +1 -1
- package/build/loader/Loader.mjs.map +1 -1
- package/build/logo/Logo.js.map +1 -1
- package/build/logo/Logo.mjs +1 -1
- package/build/logo/Logo.mjs.map +1 -1
- package/build/logo/logo-assets.js.map +1 -1
- package/build/logo/logo-assets.mjs.map +1 -1
- package/build/markdown/Markdown.js +20 -4
- package/build/markdown/Markdown.js.map +1 -1
- package/build/markdown/Markdown.mjs +1 -1
- package/build/markdown/Markdown.mjs.map +1 -1
- package/build/mocks.js.map +1 -1
- package/build/mocks.mjs.map +1 -1
- package/build/modal/Modal.js.map +1 -1
- package/build/modal/Modal.mjs.map +1 -1
- package/build/money/Money.js.map +1 -1
- package/build/money/Money.mjs.map +1 -1
- package/build/moneyInput/MoneyInput.js +2 -2
- package/build/moneyInput/MoneyInput.js.map +1 -1
- package/build/moneyInput/MoneyInput.messages.js.map +1 -1
- package/build/moneyInput/MoneyInput.messages.mjs.map +1 -1
- package/build/moneyInput/MoneyInput.mjs +2 -2
- package/build/moneyInput/MoneyInput.mjs.map +1 -1
- package/build/moneyInput/currencyFormatting.js.map +1 -1
- package/build/moneyInput/currencyFormatting.mjs.map +1 -1
- package/build/navigationOption/NavigationOption.js.map +1 -1
- package/build/navigationOption/NavigationOption.mjs.map +1 -1
- package/build/navigationOptionsList/NavigationOptionsList.js.map +1 -1
- package/build/navigationOptionsList/NavigationOptionsList.mjs.map +1 -1
- package/build/nudge/Nudge.js.map +1 -1
- package/build/nudge/Nudge.mjs.map +1 -1
- package/build/overlayHeader/OverlayHeader.js.map +1 -1
- package/build/overlayHeader/OverlayHeader.mjs.map +1 -1
- package/build/phoneNumberInput/PhoneNumberInput.js.map +1 -1
- package/build/phoneNumberInput/PhoneNumberInput.messages.js.map +1 -1
- package/build/phoneNumberInput/PhoneNumberInput.messages.mjs.map +1 -1
- package/build/phoneNumberInput/PhoneNumberInput.mjs.map +1 -1
- package/build/phoneNumberInput/data/countries.js.map +1 -1
- package/build/phoneNumberInput/data/countries.mjs.map +1 -1
- package/build/phoneNumberInput/utils/cleanNumber/cleanNumber.js.map +1 -1
- package/build/phoneNumberInput/utils/cleanNumber/cleanNumber.mjs.map +1 -1
- package/build/phoneNumberInput/utils/excludeCountries/excludeCountries.js.map +1 -1
- package/build/phoneNumberInput/utils/excludeCountries/excludeCountries.mjs.map +1 -1
- package/build/phoneNumberInput/utils/explodeNumberModel/index.js.map +1 -1
- package/build/phoneNumberInput/utils/explodeNumberModel/index.mjs.map +1 -1
- package/build/phoneNumberInput/utils/findCountryByCode/index.js.map +1 -1
- package/build/phoneNumberInput/utils/findCountryByCode/index.mjs.map +1 -1
- package/build/phoneNumberInput/utils/findCountryByPrefix/index.js.map +1 -1
- package/build/phoneNumberInput/utils/findCountryByPrefix/index.mjs.map +1 -1
- package/build/phoneNumberInput/utils/groupCountriesByPrefix/groupCountriesByPrefix.js.map +1 -1
- package/build/phoneNumberInput/utils/groupCountriesByPrefix/groupCountriesByPrefix.mjs.map +1 -1
- package/build/phoneNumberInput/utils/setDefaultPrefix/index.js.map +1 -1
- package/build/phoneNumberInput/utils/setDefaultPrefix/index.mjs.map +1 -1
- package/build/phoneNumberInput/utils/sortArrayByProperty/sortArrayByProperty.js.map +1 -1
- package/build/phoneNumberInput/utils/sortArrayByProperty/sortArrayByProperty.mjs.map +1 -1
- package/build/popover/Popover.js.map +1 -1
- package/build/popover/Popover.mjs +1 -1
- package/build/popover/Popover.mjs.map +1 -1
- package/build/primitives/PrimitiveAnchor/PrimitiveAnchor.js.map +1 -1
- package/build/primitives/PrimitiveAnchor/PrimitiveAnchor.mjs.map +1 -1
- package/build/primitives/PrimitiveButton/PrimitiveButton.js.map +1 -1
- package/build/primitives/PrimitiveButton/PrimitiveButton.mjs.map +1 -1
- package/build/processIndicator/ProcessIndicator.js.map +1 -1
- package/build/processIndicator/ProcessIndicator.mjs.map +1 -1
- package/build/progress/Progress.js.map +1 -1
- package/build/progress/Progress.mjs.map +1 -1
- package/build/progressBar/ProgressBar.js.map +1 -1
- package/build/progressBar/ProgressBar.mjs.map +1 -1
- package/build/promoCard/PromoCard.js.map +1 -1
- package/build/promoCard/PromoCard.mjs.map +1 -1
- package/build/promoCard/PromoCardContext.js.map +1 -1
- package/build/promoCard/PromoCardContext.mjs.map +1 -1
- package/build/promoCard/PromoCardGroup.js +1 -1
- package/build/promoCard/PromoCardGroup.js.map +1 -1
- package/build/promoCard/PromoCardGroup.mjs +1 -1
- package/build/promoCard/PromoCardGroup.mjs.map +1 -1
- package/build/promoCard/PromoCardIndicator.js.map +1 -1
- package/build/promoCard/PromoCardIndicator.mjs +1 -1
- package/build/promoCard/PromoCardIndicator.mjs.map +1 -1
- package/build/provider/Provider.js.map +1 -1
- package/build/provider/Provider.mjs.map +1 -1
- package/build/provider/direction/DirectionProvider.js.map +1 -1
- package/build/provider/direction/DirectionProvider.mjs.map +1 -1
- package/build/provider/language/LanguageProvider.js.map +1 -1
- package/build/provider/language/LanguageProvider.mjs.map +1 -1
- package/build/provider/overlay/OverlayIdProvider.js.map +1 -1
- package/build/provider/overlay/OverlayIdProvider.mjs +1 -1
- package/build/provider/overlay/OverlayIdProvider.mjs.map +1 -1
- package/build/radio/Radio.js.map +1 -1
- package/build/radio/Radio.mjs.map +1 -1
- package/build/radioGroup/RadioGroup.js.map +1 -1
- package/build/radioGroup/RadioGroup.mjs.map +1 -1
- package/build/radioOption/RadioOption.js.map +1 -1
- package/build/radioOption/RadioOption.mjs.map +1 -1
- package/build/section/Section.js.map +1 -1
- package/build/section/Section.mjs.map +1 -1
- package/build/segmentedControl/SegmentedControl.js.map +1 -1
- package/build/segmentedControl/SegmentedControl.mjs.map +1 -1
- package/build/select/Select.js +14 -22
- package/build/select/Select.js.map +1 -1
- package/build/select/Select.messages.js.map +1 -1
- package/build/select/Select.messages.mjs.map +1 -1
- package/build/select/Select.mjs +14 -22
- package/build/select/Select.mjs.map +1 -1
- package/build/select/option/Option.js.map +1 -1
- package/build/select/option/Option.mjs.map +1 -1
- package/build/select/searchBox/SearchBox.js.map +1 -1
- package/build/select/searchBox/SearchBox.mjs.map +1 -1
- package/build/selectOption/SelectOption.js.map +1 -1
- package/build/selectOption/SelectOption.messages.js.map +1 -1
- package/build/selectOption/SelectOption.messages.mjs.map +1 -1
- package/build/selectOption/SelectOption.mjs +1 -1
- package/build/selectOption/SelectOption.mjs.map +1 -1
- package/build/slidingPanel/SlidingPanel.js.map +1 -1
- package/build/slidingPanel/SlidingPanel.mjs.map +1 -1
- package/build/snackbar/Snackbar.js +1 -1
- package/build/snackbar/Snackbar.js.map +1 -1
- package/build/snackbar/Snackbar.mjs +1 -1
- package/build/snackbar/Snackbar.mjs.map +1 -1
- package/build/snackbar/SnackbarContext.js.map +1 -1
- package/build/snackbar/SnackbarContext.mjs.map +1 -1
- package/build/snackbar/SnackbarProvider.js.map +1 -1
- package/build/snackbar/SnackbarProvider.mjs.map +1 -1
- package/build/snackbar/useSnackbar.js.map +1 -1
- package/build/snackbar/useSnackbar.mjs.map +1 -1
- package/build/statusIcon/StatusIcon.js.map +1 -1
- package/build/statusIcon/StatusIcon.messages.js.map +1 -1
- package/build/statusIcon/StatusIcon.messages.mjs.map +1 -1
- package/build/statusIcon/StatusIcon.mjs +1 -1
- package/build/statusIcon/StatusIcon.mjs.map +1 -1
- package/build/stepper/Stepper.js.map +1 -1
- package/build/stepper/Stepper.mjs.map +1 -1
- package/build/stepper/deviceDetection.js.map +1 -1
- package/build/stepper/deviceDetection.mjs.map +1 -1
- package/build/sticky/Sticky.js.map +1 -1
- package/build/sticky/Sticky.mjs.map +1 -1
- package/build/summary/Summary.js.map +1 -1
- package/build/summary/Summary.messages.js.map +1 -1
- package/build/summary/Summary.messages.mjs.map +1 -1
- package/build/summary/Summary.mjs +1 -1
- package/build/summary/Summary.mjs.map +1 -1
- package/build/switch/Switch.js.map +1 -1
- package/build/switch/Switch.mjs.map +1 -1
- package/build/switchOption/SwitchOption.js.map +1 -1
- package/build/switchOption/SwitchOption.mjs.map +1 -1
- package/build/table/Table.js.map +1 -1
- package/build/table/Table.messages.js.map +1 -1
- package/build/table/Table.messages.mjs.map +1 -1
- package/build/table/Table.mjs.map +1 -1
- package/build/table/TableCell.js.map +1 -1
- package/build/table/TableCell.mjs.map +1 -1
- package/build/table/TableHeader.js.map +1 -1
- package/build/table/TableHeader.mjs.map +1 -1
- package/build/table/TableRow.js.map +1 -1
- package/build/table/TableRow.mjs.map +1 -1
- package/build/table/TableStatusText.js.map +1 -1
- package/build/table/TableStatusText.mjs.map +1 -1
- package/build/tabs/Tab.js.map +1 -1
- package/build/tabs/Tab.mjs.map +1 -1
- package/build/tabs/TabList.js.map +1 -1
- package/build/tabs/TabList.mjs.map +1 -1
- package/build/tabs/TabPanel.js.map +1 -1
- package/build/tabs/TabPanel.mjs.map +1 -1
- package/build/tabs/Tabs.js +3 -3
- package/build/tabs/Tabs.js.map +1 -1
- package/build/tabs/Tabs.mjs +4 -4
- package/build/tabs/Tabs.mjs.map +1 -1
- package/build/tabs/utils.js +1 -1
- package/build/tabs/utils.js.map +1 -1
- package/build/tabs/utils.mjs +1 -1
- package/build/tabs/utils.mjs.map +1 -1
- package/build/textareaWithDisplayFormat/TextareaWithDisplayFormat.js.map +1 -1
- package/build/textareaWithDisplayFormat/TextareaWithDisplayFormat.mjs.map +1 -1
- package/build/tile/Tile.js.map +1 -1
- package/build/tile/Tile.mjs.map +1 -1
- package/build/title/Title.js.map +1 -1
- package/build/title/Title.mjs.map +1 -1
- package/build/tooltip/Tooltip.js.map +1 -1
- package/build/tooltip/Tooltip.mjs.map +1 -1
- package/build/typeahead/Typeahead.js +57 -61
- package/build/typeahead/Typeahead.js.map +1 -1
- package/build/typeahead/Typeahead.messages.js.map +1 -1
- package/build/typeahead/Typeahead.messages.mjs.map +1 -1
- package/build/typeahead/Typeahead.mjs +57 -61
- package/build/typeahead/Typeahead.mjs.map +1 -1
- package/build/typeahead/typeaheadInput/TypeaheadInput.js +2 -2
- package/build/typeahead/typeaheadInput/TypeaheadInput.js.map +1 -1
- package/build/typeahead/typeaheadInput/TypeaheadInput.mjs +2 -2
- package/build/typeahead/typeaheadInput/TypeaheadInput.mjs.map +1 -1
- package/build/typeahead/typeaheadOption/TypeaheadOption.js.map +1 -1
- package/build/typeahead/typeaheadOption/TypeaheadOption.mjs.map +1 -1
- package/build/typeahead/util/highlight.js.map +1 -1
- package/build/typeahead/util/highlight.mjs.map +1 -1
- package/build/types/actionOption/ActionOption.d.ts.map +1 -1
- package/build/types/avatarWrapper/AvatarWrapper.d.ts.map +1 -1
- package/build/types/badge/Badge.d.ts.map +1 -1
- package/build/types/chevron/Chevron.d.ts.map +1 -1
- package/build/types/chips/Chip.d.ts.map +1 -1
- package/build/types/chips/Chips.d.ts.map +1 -1
- package/build/types/circularButton/CircularButton.d.ts.map +1 -1
- package/build/types/common/bottomSheet/BottomSheet.d.ts.map +1 -1
- package/build/types/common/colors.d.ts.map +1 -1
- package/build/types/common/dateUtils/getDateView/getDateView.d.ts.map +1 -1
- package/build/types/common/dateUtils/getMonthNames/getMonthNames.d.ts.map +1 -1
- package/build/types/common/dateUtils/isDateValid/isDateValid.d.ts.map +1 -1
- package/build/types/common/dateUtils/isMonthAndYearFormat/isMonthAndYearFormat.d.ts.map +1 -1
- package/build/types/common/fakeEvents.d.ts.map +1 -1
- package/build/types/common/focusBoundary/FocusBoundary.d.ts.map +1 -1
- package/build/types/common/historyNavigator/historyNavigator.d.ts.map +1 -1
- package/build/types/common/hooks/useConditionalListener/useConditionalListener.d.ts.map +1 -1
- package/build/types/common/hooks/useHasIntersected/useHasIntersected.d.ts.map +1 -1
- package/build/types/common/textFormat/formatWithPattern/formatWithPattern.d.ts.map +1 -1
- package/build/types/common/textFormat/getCountOfSymbolsInSelection/getCountOfSymbolsInSelection.d.ts.map +1 -1
- package/build/types/common/textFormat/getCursorPositionAfterKeystroke/getCursorPositionAfterKeystroke.d.ts.map +1 -1
- package/build/types/common/textFormat/getDistanceToSymbol/getDistanceToSymbol.d.ts.map +1 -1
- package/build/types/common/textFormat/getSymbolsInPatternWithPosition/getSymbolsInPatternWithPosition.d.ts.map +1 -1
- package/build/types/common/textFormat/unformatWithPattern/unformatWithPattern.d.ts.map +1 -1
- package/build/types/common/theme.d.ts.map +1 -1
- package/build/types/dateInput/DateInput.d.ts.map +1 -1
- package/build/types/dateInput/utils/convertToLocalMidnight/convertToLocalMidnight.d.ts.map +1 -1
- package/build/types/dateLookup/DateLookup.d.ts.map +1 -1
- package/build/types/dateLookup/monthCalendar/table/MonthCalendarTable.d.ts.map +1 -1
- package/build/types/dateLookup/tableLink/TableLink.d.ts.map +1 -1
- package/build/types/dateLookup/yearCalendar/table/YearCalendarTable.d.ts.map +1 -1
- package/build/types/decision/Decision.d.ts.map +1 -1
- package/build/types/dimmer/Dimmer.d.ts.map +1 -1
- package/build/types/dropFade/DropFade.d.ts.map +1 -1
- package/build/types/emphasis/Emphasis.d.ts.map +1 -1
- package/build/types/field/Field.d.ts.map +1 -1
- package/build/types/flowNavigation/FlowNavigation.d.ts.map +1 -1
- package/build/types/flowNavigation/animatedLabel/AnimatedLabel.d.ts.map +1 -1
- package/build/types/header/Header.d.ts.map +1 -1
- package/build/types/image/Image.d.ts.map +1 -1
- package/build/types/info/Info.d.ts.map +1 -1
- package/build/types/inputWithDisplayFormat/InputWithDisplayFormat.d.ts.map +1 -1
- package/build/types/inputs/SelectInput.d.ts.map +1 -1
- package/build/types/inputs/_BottomSheet.d.ts.map +1 -1
- package/build/types/inputs/_Popover.d.ts.map +1 -1
- package/build/types/instructionsList/InstructionsList.d.ts.map +1 -1
- package/build/types/link/Link.d.ts.map +1 -1
- package/build/types/loader/Loader.d.ts.map +1 -1
- package/build/types/markdown/Markdown.d.ts.map +1 -1
- package/build/types/modal/Modal.d.ts.map +1 -1
- package/build/types/money/Money.d.ts.map +1 -1
- package/build/types/navigationOptionsList/NavigationOptionsList.d.ts.map +1 -1
- package/build/types/nudge/Nudge.d.ts.map +1 -1
- package/build/types/phoneNumberInput/PhoneNumberInput.d.ts.map +1 -1
- package/build/types/phoneNumberInput/utils/cleanNumber/cleanNumber.d.ts.map +1 -1
- package/build/types/phoneNumberInput/utils/excludeCountries/excludeCountries.d.ts.map +1 -1
- package/build/types/phoneNumberInput/utils/explodeNumberModel/index.d.ts.map +1 -1
- package/build/types/phoneNumberInput/utils/findCountryByCode/index.d.ts.map +1 -1
- package/build/types/phoneNumberInput/utils/findCountryByPrefix/index.d.ts.map +1 -1
- package/build/types/phoneNumberInput/utils/groupCountriesByPrefix/groupCountriesByPrefix.d.ts.map +1 -1
- package/build/types/phoneNumberInput/utils/isStringNumeric/isStringNumeric.d.ts.map +1 -1
- package/build/types/phoneNumberInput/utils/isValidPhoneNumber/isValidPhoneNumber.d.ts.map +1 -1
- package/build/types/phoneNumberInput/utils/longestMatchingPrefix/index.d.ts.map +1 -1
- package/build/types/phoneNumberInput/utils/setDefaultPrefix/index.d.ts.map +1 -1
- package/build/types/progress/Progress.d.ts.map +1 -1
- package/build/types/progressBar/ProgressBar.d.ts.map +1 -1
- package/build/types/provider/direction/DirectionProvider.d.ts.map +1 -1
- package/build/types/provider/language/LanguageProvider.d.ts.map +1 -1
- package/build/types/provider/overlay/OverlayIdProvider.d.ts.map +1 -1
- package/build/types/section/Section.d.ts.map +1 -1
- package/build/types/segmentedControl/SegmentedControl.d.ts.map +1 -1
- package/build/types/statusIcon/StatusIcon.d.ts.map +1 -1
- package/build/types/stepper/Stepper.d.ts.map +1 -1
- package/build/types/summary/Summary.d.ts.map +1 -1
- package/build/types/switch/Switch.d.ts.map +1 -1
- package/build/types/switchOption/SwitchOption.d.ts.map +1 -1
- package/build/types/table/Table.d.ts.map +1 -1
- package/build/types/table/TableCell.d.ts.map +1 -1
- package/build/types/table/TableHeader.d.ts.map +1 -1
- package/build/types/table/TableRow.d.ts.map +1 -1
- package/build/types/table/TableStatusText.d.ts.map +1 -1
- package/build/types/tabs/Tabs.d.ts.map +1 -1
- package/build/types/tabs/utils.d.ts.map +1 -1
- package/build/types/test-utils/story-config.d.ts.map +1 -1
- package/build/types/textareaWithDisplayFormat/TextareaWithDisplayFormat.d.ts.map +1 -1
- package/build/types/tooltip/Tooltip.d.ts.map +1 -1
- package/build/types/upload/Upload.d.ts.map +1 -1
- package/build/types/uploadInput/UploadInput.d.ts.map +1 -1
- package/build/types/uploadInput/uploadButton/getAllowedFileTypes.d.ts.map +1 -1
- package/build/types/utilities/deprecatedProperty/deprecatedProperty.d.ts.map +1 -1
- package/build/types/withDisplayFormat/WithDisplayFormat.d.ts.map +1 -1
- package/build/types/withNextPortal/withNextPortal.d.ts.map +1 -1
- package/build/upload/Upload.js +2 -2
- package/build/upload/Upload.js.map +1 -1
- package/build/upload/Upload.messages.js.map +1 -1
- package/build/upload/Upload.messages.mjs.map +1 -1
- package/build/upload/Upload.mjs +2 -2
- package/build/upload/Upload.mjs.map +1 -1
- package/build/upload/steps/completeStep/completeStep.js.map +1 -1
- package/build/upload/steps/completeStep/completeStep.mjs.map +1 -1
- package/build/upload/steps/processingStep/processingStep.js.map +1 -1
- package/build/upload/steps/processingStep/processingStep.mjs.map +1 -1
- package/build/upload/steps/uploadImageStep/uploadImageStep.js +1 -1
- package/build/upload/steps/uploadImageStep/uploadImageStep.js.map +1 -1
- package/build/upload/steps/uploadImageStep/uploadImageStep.mjs +1 -1
- package/build/upload/steps/uploadImageStep/uploadImageStep.mjs.map +1 -1
- package/build/upload/utils/asyncFileRead/asyncFileRead.js.map +1 -1
- package/build/upload/utils/asyncFileRead/asyncFileRead.mjs.map +1 -1
- package/build/upload/utils/getFileType/getFileType.js.map +1 -1
- package/build/upload/utils/getFileType/getFileType.mjs.map +1 -1
- package/build/upload/utils/isSizeValid/isSizeValid.js.map +1 -1
- package/build/upload/utils/isSizeValid/isSizeValid.mjs.map +1 -1
- package/build/upload/utils/isTypeValid/isTypeValid.js.map +1 -1
- package/build/upload/utils/isTypeValid/isTypeValid.mjs.map +1 -1
- package/build/upload/utils/postData/postData.js.map +1 -1
- package/build/upload/utils/postData/postData.mjs.map +1 -1
- package/build/uploadInput/UploadInput.js.map +1 -1
- package/build/uploadInput/UploadInput.messages.js.map +1 -1
- package/build/uploadInput/UploadInput.messages.mjs.map +1 -1
- package/build/uploadInput/UploadInput.mjs +2 -2
- package/build/uploadInput/UploadInput.mjs.map +1 -1
- package/build/uploadInput/uploadButton/UploadButton.js.map +1 -1
- package/build/uploadInput/uploadButton/UploadButton.messages.js.map +1 -1
- package/build/uploadInput/uploadButton/UploadButton.messages.mjs.map +1 -1
- package/build/uploadInput/uploadButton/UploadButton.mjs.map +1 -1
- package/build/uploadInput/uploadButton/defaults.js.map +1 -1
- package/build/uploadInput/uploadButton/defaults.mjs.map +1 -1
- package/build/uploadInput/uploadButton/getAllowedFileTypes.js.map +1 -1
- package/build/uploadInput/uploadButton/getAllowedFileTypes.mjs.map +1 -1
- package/build/uploadInput/uploadItem/UploadItem.js.map +1 -1
- package/build/uploadInput/uploadItem/UploadItem.messages.js.map +1 -1
- package/build/uploadInput/uploadItem/UploadItem.messages.mjs.map +1 -1
- package/build/uploadInput/uploadItem/UploadItem.mjs.map +1 -1
- package/build/uploadInput/uploadItem/UploadItemLink.js.map +1 -1
- package/build/uploadInput/uploadItem/UploadItemLink.mjs.map +1 -1
- package/build/utilities/cssValueWithUnit.js.map +1 -1
- package/build/utilities/cssValueWithUnit.mjs.map +1 -1
- package/build/utilities/logActionRequired.js.map +1 -1
- package/build/utilities/logActionRequired.mjs.map +1 -1
- package/build/withDisplayFormat/WithDisplayFormat.js.map +1 -1
- package/build/withDisplayFormat/WithDisplayFormat.mjs.map +1 -1
- package/build/withId/withId.js.map +1 -1
- package/build/withId/withId.mjs.map +1 -1
- package/build/withNextPortal/withNextPortal.js +2 -5
- package/build/withNextPortal/withNextPortal.js.map +1 -1
- package/build/withNextPortal/withNextPortal.mjs +2 -5
- package/build/withNextPortal/withNextPortal.mjs.map +1 -1
- package/package.json +55 -55
- package/src/alert/Alert.spec.tsx +2 -4
- package/src/card/Card.story.tsx +4 -2
- package/src/checkbox/Checkbox.story.tsx +3 -2
- package/src/common/bottomSheet/BottomSheet.spec.tsx +3 -6
- package/src/common/bottomSheet/__snapshots__/BottomSheet.spec.tsx.snap +1 -5
- package/src/dateInput/DateInput.story.tsx +2 -2
- package/src/dateInput/DateInput.tests.story.tsx +11 -10
- package/src/dimmer/Dimmer.tsx +72 -44
- package/src/inputWithDisplayFormat/InputWithDisplayFormat.story.tsx +1 -1
- package/src/inputs/SelectInput.tsx +11 -2
- package/src/inputs/_BottomSheet.tsx +9 -3
- package/src/inputs/_Popover.tsx +10 -4
- package/src/markdown/Markdown.tsx +2 -1
- package/src/primitives/PrimitiveAnchor/stories/PrimitiveAnchor.story.tsx +3 -2
- package/src/primitives/PrimitiveButton/stories/PrimitiveButton.story.tsx +3 -2
- package/src/radioGroup/RadioGroup.story.tsx +2 -2
- package/src/typeahead/Typeahead.story.tsx +3 -2
- package/src/upload/Upload.story.tsx +1 -1
- package/src/withNextPortal/withNextPortal.spec.tsx +1 -1
- package/src/withNextPortal/withNextPortal.tsx +1 -10
package/build/tabs/utils.mjs
CHANGED
|
@@ -35,7 +35,7 @@ function getVelocity(coords) {
|
|
|
35
35
|
`1 - Math.E ** (-0.005 * difference)` provides a % value of how far we want to translate (0.005 being the rate)
|
|
36
36
|
`Math.min(150, window.innerWidth / 3)` provides the maximum translate value
|
|
37
37
|
*/
|
|
38
|
-
const getElasticDragDifference = difference => Math.min(150, window.innerWidth / 3) * (1 - Math.E ** (-
|
|
38
|
+
const getElasticDragDifference = difference => Math.min(150, window.innerWidth / 3) * (1 - Math.E ** (-5e-3 * difference));
|
|
39
39
|
|
|
40
40
|
export { getElasticDragDifference, getSwipeDifference, getSwipeVelocity, getVelocity, swipeShouldChangeTab, swipedLeftToRight, swipedRightToLeft };
|
|
41
41
|
//# sourceMappingURL=utils.mjs.map
|
package/build/tabs/utils.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.mjs","sources":["../../src/tabs/utils.ts"],"sourcesContent":["const MIN_SWIPE_DISTANCE = 50;\nconst MIN_SWIPE_VELOCITY = 0.1;\n\nconst swipedSignificantDistance = (difference: number) => Math.abs(difference) > MIN_SWIPE_DISTANCE;\n\nconst swipedWithSignificantVelocity = (velocity: number) => velocity > MIN_SWIPE_VELOCITY;\n\nexport interface Swipe {\n x: number;\n y: number;\n time: number;\n}\n\nexport const getSwipeVelocity = (start: Swipe, end: Swipe) => {\n const timePassed = end.time - start.time;\n\n return getSwipeDifference(start, end) / timePassed;\n};\n\nexport const getSwipeDifference = (start: Swipe, end: Swipe, axis: 'x' | 'y' = 'x') => {\n return Math.abs(start[axis] - end[axis]);\n};\n\nexport const swipedLeftToRight = (start: Swipe, end: Swipe) => {\n return end.x > start.x;\n};\n\nexport const swipedRightToLeft = (start: Swipe, end: Swipe) => {\n return start.x > end.x;\n};\n\nexport const swipeShouldChangeTab = (start: Swipe, end: Swipe) => {\n const difference = getSwipeDifference(start, end);\n const velocity = getSwipeVelocity(start, end);\n\n return swipedSignificantDistance(difference) && swipedWithSignificantVelocity(velocity);\n};\n\nexport function getVelocity(coords: Swipe[]) {\n try {\n const relevant = coords.slice(Math.max(coords.length - 5, 1));\n const first = relevant[0];\n const last = relevant[relevant.length - 1];\n\n return Math.abs(first.x - last.x) / (last.time - first.time);\n } catch {\n return 0;\n }\n}\n\n/*\n `elasticDrag` is the translateX value, which slows down as the difference increases\n `1 - Math.E ** (-0.005 * difference)` provides a % value of how far we want to translate (0.005 being the rate)\n `Math.min(150, window.innerWidth / 3)` provides the maximum translate value\n*/\nexport const getElasticDragDifference = (difference: number) =>\n Math.min(150, window.innerWidth / 3) * (1 - Math.E ** (-0.005 * difference));\n"],"names":["MIN_SWIPE_DISTANCE","MIN_SWIPE_VELOCITY","swipedSignificantDistance","difference","Math","abs","swipedWithSignificantVelocity","velocity","getSwipeVelocity","start","end","timePassed","time","getSwipeDifference","axis","swipedLeftToRight","x","swipedRightToLeft","swipeShouldChangeTab","getVelocity","coords","relevant","slice","max","length","first","last","getElasticDragDifference","min","window","innerWidth","E"],"mappings":"AAAA,MAAMA,kBAAkB,GAAG,EAAE
|
|
1
|
+
{"version":3,"file":"utils.mjs","sources":["../../src/tabs/utils.ts"],"sourcesContent":["const MIN_SWIPE_DISTANCE = 50;\nconst MIN_SWIPE_VELOCITY = 0.1;\n\nconst swipedSignificantDistance = (difference: number) => Math.abs(difference) > MIN_SWIPE_DISTANCE;\n\nconst swipedWithSignificantVelocity = (velocity: number) => velocity > MIN_SWIPE_VELOCITY;\n\nexport interface Swipe {\n x: number;\n y: number;\n time: number;\n}\n\nexport const getSwipeVelocity = (start: Swipe, end: Swipe) => {\n const timePassed = end.time - start.time;\n\n return getSwipeDifference(start, end) / timePassed;\n};\n\nexport const getSwipeDifference = (start: Swipe, end: Swipe, axis: 'x' | 'y' = 'x') => {\n return Math.abs(start[axis] - end[axis]);\n};\n\nexport const swipedLeftToRight = (start: Swipe, end: Swipe) => {\n return end.x > start.x;\n};\n\nexport const swipedRightToLeft = (start: Swipe, end: Swipe) => {\n return start.x > end.x;\n};\n\nexport const swipeShouldChangeTab = (start: Swipe, end: Swipe) => {\n const difference = getSwipeDifference(start, end);\n const velocity = getSwipeVelocity(start, end);\n\n return swipedSignificantDistance(difference) && swipedWithSignificantVelocity(velocity);\n};\n\nexport function getVelocity(coords: Swipe[]) {\n try {\n const relevant = coords.slice(Math.max(coords.length - 5, 1));\n const first = relevant[0];\n const last = relevant[relevant.length - 1];\n\n return Math.abs(first.x - last.x) / (last.time - first.time);\n } catch {\n return 0;\n }\n}\n\n/*\n `elasticDrag` is the translateX value, which slows down as the difference increases\n `1 - Math.E ** (-0.005 * difference)` provides a % value of how far we want to translate (0.005 being the rate)\n `Math.min(150, window.innerWidth / 3)` provides the maximum translate value\n*/\nexport const getElasticDragDifference = (difference: number) =>\n Math.min(150, window.innerWidth / 3) * (1 - Math.E ** (-0.005 * difference));\n"],"names":["MIN_SWIPE_DISTANCE","MIN_SWIPE_VELOCITY","swipedSignificantDistance","difference","Math","abs","swipedWithSignificantVelocity","velocity","getSwipeVelocity","start","end","timePassed","time","getSwipeDifference","axis","swipedLeftToRight","x","swipedRightToLeft","swipeShouldChangeTab","getVelocity","coords","relevant","slice","max","length","first","last","getElasticDragDifference","min","window","innerWidth","E"],"mappings":"AAAA,MAAMA,kBAAkB,GAAG,EAAE;AA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AK,CAAClB,IAAI,CAACmB,GAAG,CAACH,MAAM,CAACI,MAAM,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC;AAC7D,IAAA,MAAMC,KAAK,GAAGJ,QAAQ,CAAC,CAAC,CAAC;IACzB,MAAMK,IAAI,GAAGL,QAAQ,CAACA,QAAQ,CAACG,MAAM,GAAG,CAAC,CAAC;IAE1C,OAAOpB,IAAI,CAACC,GAAG,CAACoB,KAAK,CAACT,CAAC,GAAGU,IAAI,CAACV,CAAC,CAAC,IAAIU,IAAI,CAACd,IAAI,GAAGa,KAAK,CAACb,IAAI,CAAC;AAC9D,GAAC,CAAC,MAAM;AACN,IAAA,OAAO,CAAC;AACV;AACF;AAEA;;;;AAIE;AACWe,MAAAA,wBAAwB,GAAIxB,UAAkB,IACzDC,IAAI,CAACwB,GAAG,CAAC,GAAG,EAAEC,MAAM,CAACC,UAAU,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG1B,IAAI,CAAC2B,CAAC,KAAK,KAAM,GAAG5B,UAAU,CAAC;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextareaWithDisplayFormat.js","sources":["../../src/textareaWithDisplayFormat/TextareaWithDisplayFormat.tsx"],"sourcesContent":["import { TextArea, type TextAreaProps } from '../inputs/TextArea';\nimport WithDisplayFormat, { type WithDisplayFormatProps } from '../withDisplayFormat';\n\nexport interface TextareaWithDisplayFormatProps extends Omit<WithDisplayFormatProps, 'render'> {}\n\nconst TextareaWithDisplayFormat = (props: TextareaWithDisplayFormatProps) => (\n <WithDisplayFormat<TextAreaProps>\n {...props}\n render={(renderProps) => <TextArea {...renderProps} />}\n />\n);\n\nexport default TextareaWithDisplayFormat;\n"],"names":["TextareaWithDisplayFormat","props","_jsx","WithDisplayFormat","render","renderProps","TextArea"],"mappings":";;;;;;;;AAKA,MAAMA,yBAAyB,GAAIC,KAAqC,iBACtEC,cAAA,CAACC,yBAAiB,EAAA;AAAA,EAAA,GACZF,KAAK;AACTG,EAAAA,MAAM,EAAGC,WAAW,iBAAKH,cAAA,CAACI,iBAAQ,EAAA;IAAA,GAAKD
|
|
1
|
+
{"version":3,"file":"TextareaWithDisplayFormat.js","sources":["../../src/textareaWithDisplayFormat/TextareaWithDisplayFormat.tsx"],"sourcesContent":["import { TextArea, type TextAreaProps } from '../inputs/TextArea';\nimport WithDisplayFormat, { type WithDisplayFormatProps } from '../withDisplayFormat';\n\nexport interface TextareaWithDisplayFormatProps extends Omit<WithDisplayFormatProps, 'render'> {}\n\nconst TextareaWithDisplayFormat = (props: TextareaWithDisplayFormatProps) => (\n <WithDisplayFormat<TextAreaProps>\n {...props}\n render={(renderProps) => <TextArea {...renderProps} />}\n />\n);\n\nexport default TextareaWithDisplayFormat;\n"],"names":["TextareaWithDisplayFormat","props","_jsx","WithDisplayFormat","render","renderProps","TextArea"],"mappings":";;;;;;;;AAKA,MAAMA,yBAAyB,GAAIC,KAAqC,iBACtEC,cAAA,CAACC,yBAAiB,EAAA;AAAA,EAAA,GACZF,KAAK;AACTG,EAAAA,MAAM,EAAGC,WAAW,iBAAKH,cAAA,CAACI,iBAAQ,EAAA;IAAA,GAAKD;GAAY;AAAI,CAAA;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextareaWithDisplayFormat.mjs","sources":["../../src/textareaWithDisplayFormat/TextareaWithDisplayFormat.tsx"],"sourcesContent":["import { TextArea, type TextAreaProps } from '../inputs/TextArea';\nimport WithDisplayFormat, { type WithDisplayFormatProps } from '../withDisplayFormat';\n\nexport interface TextareaWithDisplayFormatProps extends Omit<WithDisplayFormatProps, 'render'> {}\n\nconst TextareaWithDisplayFormat = (props: TextareaWithDisplayFormatProps) => (\n <WithDisplayFormat<TextAreaProps>\n {...props}\n render={(renderProps) => <TextArea {...renderProps} />}\n />\n);\n\nexport default TextareaWithDisplayFormat;\n"],"names":["TextareaWithDisplayFormat","props","_jsx","WithDisplayFormat","render","renderProps","TextArea"],"mappings":";;;;AAKA,MAAMA,yBAAyB,GAAIC,KAAqC,iBACtEC,GAAA,CAACC,iBAAiB,EAAA;AAAA,EAAA,GACZF,KAAK;AACTG,EAAAA,MAAM,EAAGC,WAAW,iBAAKH,GAAA,CAACI,QAAQ,EAAA;IAAA,GAAKD
|
|
1
|
+
{"version":3,"file":"TextareaWithDisplayFormat.mjs","sources":["../../src/textareaWithDisplayFormat/TextareaWithDisplayFormat.tsx"],"sourcesContent":["import { TextArea, type TextAreaProps } from '../inputs/TextArea';\nimport WithDisplayFormat, { type WithDisplayFormatProps } from '../withDisplayFormat';\n\nexport interface TextareaWithDisplayFormatProps extends Omit<WithDisplayFormatProps, 'render'> {}\n\nconst TextareaWithDisplayFormat = (props: TextareaWithDisplayFormatProps) => (\n <WithDisplayFormat<TextAreaProps>\n {...props}\n render={(renderProps) => <TextArea {...renderProps} />}\n />\n);\n\nexport default TextareaWithDisplayFormat;\n"],"names":["TextareaWithDisplayFormat","props","_jsx","WithDisplayFormat","render","renderProps","TextArea"],"mappings":";;;;AAKA,MAAMA,yBAAyB,GAAIC,KAAqC,iBACtEC,GAAA,CAACC,iBAAiB,EAAA;AAAA,EAAA,GACZF,KAAK;AACTG,EAAAA,MAAM,EAAGC,WAAW,iBAAKH,GAAA,CAACI,QAAQ,EAAA;IAAA,GAAKD;GAAY;AAAI,CAAA;;;;"}
|
package/build/tile/Tile.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tile.js","sources":["../../src/tile/Tile.tsx"],"sourcesContent":["import { clsx } from 'clsx';\n\nimport Body from '../body';\nimport { Size, Typography } from '../common';\nimport Title from '../title';\n\nexport interface TileProps {\n /** Classes to apply to the Tile container */\n /** A label for the accordion item, used for accessibility purposes. */\n 'aria-label'?: string;\n className?: string;\n description?: React.ReactNode;\n disabled?: boolean;\n href?: string;\n target?: React.HTMLAttributeAnchorTarget;\n /** Accepts only Avatar and images */\n media: React.ReactNode;\n /** Function called onClick or onKeyDown */\n onClick?: (event?: React.MouseEvent<HTMLButtonElement | HTMLAnchorElement>) => void;\n /** The size applied to Tile */\n size?: `${Size.SMALL | Size.MEDIUM}`;\n title: React.ReactNode;\n}\n\nexport default function Tile({\n 'aria-label': ariaLabel,\n className,\n description,\n disabled,\n href,\n target,\n media,\n onClick,\n size = 'md',\n title,\n}: TileProps) {\n const isSmall = size === 'sm';\n const Element = href ? 'a' : 'button';\n\n return (\n <Element\n className={clsx(\n 'decision',\n 'flex-column',\n 'np-tile',\n 'text-no-decoration',\n 'text-xs-center',\n className,\n {\n 'p-a-3': !isSmall,\n 'p-a-2 np-tile--small': isSmall,\n },\n disabled && 'disabled',\n )}\n href={href}\n target={target}\n aria-label={ariaLabel}\n onClick={disabled ? undefined : onClick}\n onKeyDown={\n disabled\n ? undefined\n : ({ key }) => {\n if (key === 'Enter' || key === ' ') {\n onClick?.();\n }\n }\n }\n >\n <div className=\"np-tile__media d-flex justify-content-center\">{media}</div>\n <Title type={Typography.TITLE_SUBSECTION} className={clsx(isSmall ? 'm-t-1' : 'm-t-2')}>\n {title}\n </Title>\n {description ? (\n <Body as=\"span\" type={Typography.BODY_DEFAULT} className=\"m-t-1\">\n {description}\n </Body>\n ) : null}\n </Element>\n );\n}\n"],"names":["Tile","ariaLabel","className","description","disabled","href","target","media","onClick","size","title","isSmall","Element","_jsxs","clsx","undefined","onKeyDown","key","children","_jsx","Title","type","Typography","TITLE_SUBSECTION","Body","as","BODY_DEFAULT"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwBwB,SAAAA,IAAIA,CAAC;AAC3B,EAAA,YAAY,EAAEC,SAAS;EACvBC,SAAS;EACTC,WAAW;EACXC,QAAQ;EACRC,IAAI;EACJC,MAAM;EACNC,KAAK;EACLC,OAAO;AACPC,EAAAA,IAAI,GAAG,IAAI;AACXC,EAAAA
|
|
1
|
+
{"version":3,"file":"Tile.js","sources":["../../src/tile/Tile.tsx"],"sourcesContent":["import { clsx } from 'clsx';\n\nimport Body from '../body';\nimport { Size, Typography } from '../common';\nimport Title from '../title';\n\nexport interface TileProps {\n /** Classes to apply to the Tile container */\n /** A label for the accordion item, used for accessibility purposes. */\n 'aria-label'?: string;\n className?: string;\n description?: React.ReactNode;\n disabled?: boolean;\n href?: string;\n target?: React.HTMLAttributeAnchorTarget;\n /** Accepts only Avatar and images */\n media: React.ReactNode;\n /** Function called onClick or onKeyDown */\n onClick?: (event?: React.MouseEvent<HTMLButtonElement | HTMLAnchorElement>) => void;\n /** The size applied to Tile */\n size?: `${Size.SMALL | Size.MEDIUM}`;\n title: React.ReactNode;\n}\n\nexport default function Tile({\n 'aria-label': ariaLabel,\n className,\n description,\n disabled,\n href,\n target,\n media,\n onClick,\n size = 'md',\n title,\n}: TileProps) {\n const isSmall = size === 'sm';\n const Element = href ? 'a' : 'button';\n\n return (\n <Element\n className={clsx(\n 'decision',\n 'flex-column',\n 'np-tile',\n 'text-no-decoration',\n 'text-xs-center',\n className,\n {\n 'p-a-3': !isSmall,\n 'p-a-2 np-tile--small': isSmall,\n },\n disabled && 'disabled',\n )}\n href={href}\n target={target}\n aria-label={ariaLabel}\n onClick={disabled ? undefined : onClick}\n onKeyDown={\n disabled\n ? undefined\n : ({ key }) => {\n if (key === 'Enter' || key === ' ') {\n onClick?.();\n }\n }\n }\n >\n <div className=\"np-tile__media d-flex justify-content-center\">{media}</div>\n <Title type={Typography.TITLE_SUBSECTION} className={clsx(isSmall ? 'm-t-1' : 'm-t-2')}>\n {title}\n </Title>\n {description ? (\n <Body as=\"span\" type={Typography.BODY_DEFAULT} className=\"m-t-1\">\n {description}\n </Body>\n ) : null}\n </Element>\n );\n}\n"],"names":["Tile","ariaLabel","className","description","disabled","href","target","media","onClick","size","title","isSmall","Element","_jsxs","clsx","undefined","onKeyDown","key","children","_jsx","Title","type","Typography","TITLE_SUBSECTION","Body","as","BODY_DEFAULT"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwBwB,SAAAA,IAAIA,CAAC;AAC3B,E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,cAAA,CAACK,YAAI,EAAA;AAACC,MAAAA,EAAE,EAAC,MAAM;MAACJ,IAAI,EAAEC,qBAAU,CAACI,YAAa;AAACxB,MAAAA,SAAS,EAAC,OAAO;AAAAgB,MAAAA,QAAA,EAC7Df;KACG,CAAC,GACL,IAAI;AAAA,GACD,CAAC;AAEd;;;;"}
|
package/build/tile/Tile.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tile.mjs","sources":["../../src/tile/Tile.tsx"],"sourcesContent":["import { clsx } from 'clsx';\n\nimport Body from '../body';\nimport { Size, Typography } from '../common';\nimport Title from '../title';\n\nexport interface TileProps {\n /** Classes to apply to the Tile container */\n /** A label for the accordion item, used for accessibility purposes. */\n 'aria-label'?: string;\n className?: string;\n description?: React.ReactNode;\n disabled?: boolean;\n href?: string;\n target?: React.HTMLAttributeAnchorTarget;\n /** Accepts only Avatar and images */\n media: React.ReactNode;\n /** Function called onClick or onKeyDown */\n onClick?: (event?: React.MouseEvent<HTMLButtonElement | HTMLAnchorElement>) => void;\n /** The size applied to Tile */\n size?: `${Size.SMALL | Size.MEDIUM}`;\n title: React.ReactNode;\n}\n\nexport default function Tile({\n 'aria-label': ariaLabel,\n className,\n description,\n disabled,\n href,\n target,\n media,\n onClick,\n size = 'md',\n title,\n}: TileProps) {\n const isSmall = size === 'sm';\n const Element = href ? 'a' : 'button';\n\n return (\n <Element\n className={clsx(\n 'decision',\n 'flex-column',\n 'np-tile',\n 'text-no-decoration',\n 'text-xs-center',\n className,\n {\n 'p-a-3': !isSmall,\n 'p-a-2 np-tile--small': isSmall,\n },\n disabled && 'disabled',\n )}\n href={href}\n target={target}\n aria-label={ariaLabel}\n onClick={disabled ? undefined : onClick}\n onKeyDown={\n disabled\n ? undefined\n : ({ key }) => {\n if (key === 'Enter' || key === ' ') {\n onClick?.();\n }\n }\n }\n >\n <div className=\"np-tile__media d-flex justify-content-center\">{media}</div>\n <Title type={Typography.TITLE_SUBSECTION} className={clsx(isSmall ? 'm-t-1' : 'm-t-2')}>\n {title}\n </Title>\n {description ? (\n <Body as=\"span\" type={Typography.BODY_DEFAULT} className=\"m-t-1\">\n {description}\n </Body>\n ) : null}\n </Element>\n );\n}\n"],"names":["Tile","ariaLabel","className","description","disabled","href","target","media","onClick","size","title","isSmall","Element","_jsxs","clsx","undefined","onKeyDown","key","children","_jsx","Title","type","Typography","TITLE_SUBSECTION","Body","as","BODY_DEFAULT"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwBwB,SAAAA,IAAIA,CAAC;AAC3B,EAAA,YAAY,EAAEC,SAAS;EACvBC,SAAS;EACTC,WAAW;EACXC,QAAQ;EACRC,IAAI;EACJC,MAAM;EACNC,KAAK;EACLC,OAAO;AACPC,EAAAA,IAAI,GAAG,IAAI;AACXC,EAAAA
|
|
1
|
+
{"version":3,"file":"Tile.mjs","sources":["../../src/tile/Tile.tsx"],"sourcesContent":["import { clsx } from 'clsx';\n\nimport Body from '../body';\nimport { Size, Typography } from '../common';\nimport Title from '../title';\n\nexport interface TileProps {\n /** Classes to apply to the Tile container */\n /** A label for the accordion item, used for accessibility purposes. */\n 'aria-label'?: string;\n className?: string;\n description?: React.ReactNode;\n disabled?: boolean;\n href?: string;\n target?: React.HTMLAttributeAnchorTarget;\n /** Accepts only Avatar and images */\n media: React.ReactNode;\n /** Function called onClick or onKeyDown */\n onClick?: (event?: React.MouseEvent<HTMLButtonElement | HTMLAnchorElement>) => void;\n /** The size applied to Tile */\n size?: `${Size.SMALL | Size.MEDIUM}`;\n title: React.ReactNode;\n}\n\nexport default function Tile({\n 'aria-label': ariaLabel,\n className,\n description,\n disabled,\n href,\n target,\n media,\n onClick,\n size = 'md',\n title,\n}: TileProps) {\n const isSmall = size === 'sm';\n const Element = href ? 'a' : 'button';\n\n return (\n <Element\n className={clsx(\n 'decision',\n 'flex-column',\n 'np-tile',\n 'text-no-decoration',\n 'text-xs-center',\n className,\n {\n 'p-a-3': !isSmall,\n 'p-a-2 np-tile--small': isSmall,\n },\n disabled && 'disabled',\n )}\n href={href}\n target={target}\n aria-label={ariaLabel}\n onClick={disabled ? undefined : onClick}\n onKeyDown={\n disabled\n ? undefined\n : ({ key }) => {\n if (key === 'Enter' || key === ' ') {\n onClick?.();\n }\n }\n }\n >\n <div className=\"np-tile__media d-flex justify-content-center\">{media}</div>\n <Title type={Typography.TITLE_SUBSECTION} className={clsx(isSmall ? 'm-t-1' : 'm-t-2')}>\n {title}\n </Title>\n {description ? (\n <Body as=\"span\" type={Typography.BODY_DEFAULT} className=\"m-t-1\">\n {description}\n </Body>\n ) : null}\n </Element>\n );\n}\n"],"names":["Tile","ariaLabel","className","description","disabled","href","target","media","onClick","size","title","isSmall","Element","_jsxs","clsx","undefined","onKeyDown","key","children","_jsx","Title","type","Typography","TITLE_SUBSECTION","Body","as","BODY_DEFAULT"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwBwB,SAAAA,IAAIA,CAAC;AAC3B,EAAA,YAAY,EAAEC,SAAS;EACvBC,SAAS;EACTC,WAAW;EACXC,QAAQ;EACRC,IAAI;EACJC,MAAM;EACNC,KAAK;EACLC,OAAO;AACPC,EAAAA,IAAI,GAAG,IAAI;AACXC,EAAAA;AACU,CAAA,EAAA;AACV,EAAA,MAAMC,OAAO,GAAGF,IAAI,KAAK,IAAI;AAC7B,EAAA,MAAMG,OAAO,GAAGP,IAAI,GAAG,GAAG,GAAG,QAAQ;EAErC,oBACEQ,IAAA,CAACD,OAAO,EAAA;AACNV,IAAAA,SAAS,EAAEY,IAAI,CACb,UAAU,EACV,aAAa,EACb,SAAS,EACT,oBAAoB,EACpB,gBAAgB,EAChBZ,SAAS,EACT;MACE,OAAO,EAAE,CAACS,OAAO;AACjB,MAAA,sBAAsB,EAAEA;AACzB,KAAA,EACDP,QAAQ,IAAI,UAAU,CACtB;AACFC,IAAAA,IAAI,EAAEA,IAAK;AACXC,IAAAA,MAAM,EAAEA,MAAO;AACf,IAAA,YAAA,EAAYL,SAAU;AACtBO,IAAAA,OAAO,EAAEJ,QAAQ,GAAGW,SAAS,GAAGP,OAAQ;AACxCQ,IAAAA,SAAS,EACPZ,QAAQ,GACJW,SAAS,GACT,CAAC;AAAEE,MAAAA;AAAG,KAAE,KAAI;AACV,MAAA,IAAIA,GAAG,KAAK,OAAO,IAAIA,GAAG,KAAK,GAAG,EAAE;AAClCT,QAAAA,OAAO,IAAI;AACb;KAEP;AAAAU,IAAAA,QAAA,gBAEDC,GAAA,CAAA,KAAA,EAAA;AAAKjB,MAAAA,SAAS,EAAC,8CAA8C;AAAAgB,MAAAA,QAAA,EAAEX;AAAK,KAAM,CAC1E,eAAAY,GAAA,CAACC,KAAK,EAAA;MAACC,IAAI,EAAEC,UAAU,CAACC,gBAAiB;MAACrB,SAAS,EAAEY,IAAI,CAACH,OAAO,GAAG,OAAO,GAAG,OAAO,CAAE;AAAAO,MAAAA,QAAA,EACpFR;AAAK,KACD,CACP,EAACP,WAAW,gBACVgB,GAAA,CAACK,IAAI,EAAA;AAACC,MAAAA,EAAE,EAAC,MAAM;MAACJ,IAAI,EAAEC,UAAU,CAACI,YAAa;AAACxB,MAAAA,SAAS,EAAC,OAAO;AAAAgB,MAAAA,QAAA,EAC7Df;KACG,CAAC,GACL,IAAI;AAAA,GACD,CAAC;AAEd;;;;"}
|
package/build/title/Title.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Title.js","sources":["../../src/title/Title.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { LabelHTMLAttributes, LiHTMLAttributes, ReactHTML } from 'react';\n\nimport { TitleTypes, Typography, Heading } from '../common';\n\nconst DEFAULT_TYPE = Typography.TITLE_GROUP;\n\nconst titleTypeMapping = {\n [Typography.TITLE_SCREEN]: 'h1',\n [Typography.TITLE_SECTION]: 'h2',\n [Typography.TITLE_SUBSECTION]: 'h3',\n [Typography.TITLE_BODY]: 'h4',\n [Typography.TITLE_GROUP]: 'h5',\n} as const;\n\ntype Props = LabelHTMLAttributes<HTMLHeadingElement | HTMLSpanElement | HTMLLabelElement> &\n LiHTMLAttributes<HTMLLIElement> & {\n /**\n * Default value will based one `type` prop\n */\n as?: 'span' | 'label' | 'li' | 'legend' | 'header' | Heading;\n /**\n * Default value: {@link DEFAULT_TYPE}\n */\n type?: TitleTypes;\n };\n\nfunction Title({ as, type = DEFAULT_TYPE, className, ...props }: Props) {\n const mapping = titleTypeMapping[type];\n const isTypeSupported = mapping !== undefined;\n\n if (isTypeSupported) {\n const HeaderTag = as ?? mapping;\n return <HeaderTag {...props} className={clsx(`np-text-${type}`, className)} />;\n }\n const HeaderTag = as ?? titleTypeMapping[DEFAULT_TYPE];\n return <HeaderTag {...props} className={clsx(`np-text-${DEFAULT_TYPE}`, className)} />;\n}\n\nexport default Title;\n"],"names":["DEFAULT_TYPE","Typography","TITLE_GROUP","titleTypeMapping","TITLE_SCREEN","TITLE_SECTION","TITLE_SUBSECTION","TITLE_BODY","Title","as","type","className","props","mapping","isTypeSupported","undefined","HeaderTag","_jsx","clsx"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,MAAMA,YAAY,GAAGC,qBAAU,CAACC,WAAW
|
|
1
|
+
{"version":3,"file":"Title.js","sources":["../../src/title/Title.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { LabelHTMLAttributes, LiHTMLAttributes, ReactHTML } from 'react';\n\nimport { TitleTypes, Typography, Heading } from '../common';\n\nconst DEFAULT_TYPE = Typography.TITLE_GROUP;\n\nconst titleTypeMapping = {\n [Typography.TITLE_SCREEN]: 'h1',\n [Typography.TITLE_SECTION]: 'h2',\n [Typography.TITLE_SUBSECTION]: 'h3',\n [Typography.TITLE_BODY]: 'h4',\n [Typography.TITLE_GROUP]: 'h5',\n} as const;\n\ntype Props = LabelHTMLAttributes<HTMLHeadingElement | HTMLSpanElement | HTMLLabelElement> &\n LiHTMLAttributes<HTMLLIElement> & {\n /**\n * Default value will based one `type` prop\n */\n as?: 'span' | 'label' | 'li' | 'legend' | 'header' | Heading;\n /**\n * Default value: {@link DEFAULT_TYPE}\n */\n type?: TitleTypes;\n };\n\nfunction Title({ as, type = DEFAULT_TYPE, className, ...props }: Props) {\n const mapping = titleTypeMapping[type];\n const isTypeSupported = mapping !== undefined;\n\n if (isTypeSupported) {\n const HeaderTag = as ?? mapping;\n return <HeaderTag {...props} className={clsx(`np-text-${type}`, className)} />;\n }\n const HeaderTag = as ?? titleTypeMapping[DEFAULT_TYPE];\n return <HeaderTag {...props} className={clsx(`np-text-${DEFAULT_TYPE}`, className)} />;\n}\n\nexport default Title;\n"],"names":["DEFAULT_TYPE","Typography","TITLE_GROUP","titleTypeMapping","TITLE_SCREEN","TITLE_SECTION","TITLE_SUBSECTION","TITLE_BODY","Title","as","type","className","props","mapping","isTypeSupported","undefined","HeaderTag","_jsx","clsx"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,MAAMA,YAAY,GAAGC,qBAAU,CAACC,WAAW;AAE3C,MAAMC,gBAAgB,GAAG;AACvB,EAAA,CAACF,qBAAU,CAACG,YAAY,GAAG,IAAI;AAC/B,EAAA,CAACH,qBAAU,CAACI,aAAa,GAAG,IAAI;AAChC,EAAA,CAACJ,qBAAU,CAACK,gBAAgB,GAAG,IAAI;AACnC,EAAA,CAACL,qBAAU,CAACM,UAAU,GAAG,IAAI;EAC7B,CAACN,qBAAU,CAACC,WAAW,GAAG;CAClB;AAcV,SAASM,KAAKA,CAAC;EAAEC,EAAE;AAAEC,EAAAA,IAAI,GAAGV,YAAY;EAAEW,SAAS;EAAE,GAAGC;AAAc,CAAA,EAAA;AACpE,EAAA,MAAMC,OAAO,GAAGV,gBAAgB,CAACO,IAAI,CAAC;AACtC,EAAA,MAAMI,eAAe,GAAGD,OAAO,KAAKE,SAAS;AAE7C,EAAA,IAAID,eAAe,EAAE;AACnB,IAAA,MAAME,SAAS,GAAGP,EAAE,IAAII,OAAO;IAC/B,oBAAOI,cAAA,CAACD,SAAS,EAAA;AAAA,MAAA,GAAKJ,KAAK;AAAED,MAAAA,SAAS,EAAEO,SAAI,CAAC,WAAWR,IAAI,CAAA,CAAE,EAAEC,SAAS;AAAE,MAAG;AAChF;AACA,EAAA,MAAMK,SAAS,GAAGP,EAAE,IAAIN,gBAAgB,CAACH,YAAY,CAAC;EACtD,oBAAOiB,cAAA,CAACD,SAAS,EAAA;AAAA,IAAA,GAAKJ,KAAK;AAAED,IAAAA,SAAS,EAAEO,SAAI,CAAC,WAAWlB,YAAY,CAAA,CAAE,EAAEW,SAAS;AAAE,IAAG;AACxF;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Title.mjs","sources":["../../src/title/Title.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { LabelHTMLAttributes, LiHTMLAttributes, ReactHTML } from 'react';\n\nimport { TitleTypes, Typography, Heading } from '../common';\n\nconst DEFAULT_TYPE = Typography.TITLE_GROUP;\n\nconst titleTypeMapping = {\n [Typography.TITLE_SCREEN]: 'h1',\n [Typography.TITLE_SECTION]: 'h2',\n [Typography.TITLE_SUBSECTION]: 'h3',\n [Typography.TITLE_BODY]: 'h4',\n [Typography.TITLE_GROUP]: 'h5',\n} as const;\n\ntype Props = LabelHTMLAttributes<HTMLHeadingElement | HTMLSpanElement | HTMLLabelElement> &\n LiHTMLAttributes<HTMLLIElement> & {\n /**\n * Default value will based one `type` prop\n */\n as?: 'span' | 'label' | 'li' | 'legend' | 'header' | Heading;\n /**\n * Default value: {@link DEFAULT_TYPE}\n */\n type?: TitleTypes;\n };\n\nfunction Title({ as, type = DEFAULT_TYPE, className, ...props }: Props) {\n const mapping = titleTypeMapping[type];\n const isTypeSupported = mapping !== undefined;\n\n if (isTypeSupported) {\n const HeaderTag = as ?? mapping;\n return <HeaderTag {...props} className={clsx(`np-text-${type}`, className)} />;\n }\n const HeaderTag = as ?? titleTypeMapping[DEFAULT_TYPE];\n return <HeaderTag {...props} className={clsx(`np-text-${DEFAULT_TYPE}`, className)} />;\n}\n\nexport default Title;\n"],"names":["DEFAULT_TYPE","Typography","TITLE_GROUP","titleTypeMapping","TITLE_SCREEN","TITLE_SECTION","TITLE_SUBSECTION","TITLE_BODY","Title","as","type","className","props","mapping","isTypeSupported","undefined","HeaderTag","_jsx","clsx"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,MAAMA,YAAY,GAAGC,UAAU,CAACC,WAAW
|
|
1
|
+
{"version":3,"file":"Title.mjs","sources":["../../src/title/Title.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { LabelHTMLAttributes, LiHTMLAttributes, ReactHTML } from 'react';\n\nimport { TitleTypes, Typography, Heading } from '../common';\n\nconst DEFAULT_TYPE = Typography.TITLE_GROUP;\n\nconst titleTypeMapping = {\n [Typography.TITLE_SCREEN]: 'h1',\n [Typography.TITLE_SECTION]: 'h2',\n [Typography.TITLE_SUBSECTION]: 'h3',\n [Typography.TITLE_BODY]: 'h4',\n [Typography.TITLE_GROUP]: 'h5',\n} as const;\n\ntype Props = LabelHTMLAttributes<HTMLHeadingElement | HTMLSpanElement | HTMLLabelElement> &\n LiHTMLAttributes<HTMLLIElement> & {\n /**\n * Default value will based one `type` prop\n */\n as?: 'span' | 'label' | 'li' | 'legend' | 'header' | Heading;\n /**\n * Default value: {@link DEFAULT_TYPE}\n */\n type?: TitleTypes;\n };\n\nfunction Title({ as, type = DEFAULT_TYPE, className, ...props }: Props) {\n const mapping = titleTypeMapping[type];\n const isTypeSupported = mapping !== undefined;\n\n if (isTypeSupported) {\n const HeaderTag = as ?? mapping;\n return <HeaderTag {...props} className={clsx(`np-text-${type}`, className)} />;\n }\n const HeaderTag = as ?? titleTypeMapping[DEFAULT_TYPE];\n return <HeaderTag {...props} className={clsx(`np-text-${DEFAULT_TYPE}`, className)} />;\n}\n\nexport default Title;\n"],"names":["DEFAULT_TYPE","Typography","TITLE_GROUP","titleTypeMapping","TITLE_SCREEN","TITLE_SECTION","TITLE_SUBSECTION","TITLE_BODY","Title","as","type","className","props","mapping","isTypeSupported","undefined","HeaderTag","_jsx","clsx"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,MAAMA,YAAY,GAAGC,UAAU,CAACC,WAAW;AAE3C,MAAMC,gBAAgB,GAAG;AACvB,EAAA,CAACF,UAAU,CAACG,YAAY,GAAG,IAAI;AAC/B,EAAA,CAACH,UAAU,CAACI,aAAa,GAAG,IAAI;AAChC,EAAA,CAACJ,UAAU,CAACK,gBAAgB,GAAG,IAAI;AACnC,EAAA,CAACL,UAAU,CAACM,UAAU,GAAG,IAAI;EAC7B,CAACN,UAAU,CAACC,WAAW,GAAG;CAClB;AAcV,SAASM,KAAKA,CAAC;EAAEC,EAAE;AAAEC,EAAAA,IAAI,GAAGV,YAAY;EAAEW,SAAS;EAAE,GAAGC;AAAc,CAAA,EAAA;AACpE,EAAA,MAAMC,OAAO,GAAGV,gBAAgB,CAACO,IAAI,CAAC;AACtC,EAAA,MAAMI,eAAe,GAAGD,OAAO,KAAKE,SAAS;AAE7C,EAAA,IAAID,eAAe,EAAE;AACnB,IAAA,MAAME,SAAS,GAAGP,EAAE,IAAII,OAAO;IAC/B,oBAAOI,GAAA,CAACD,SAAS,EAAA;AAAA,MAAA,GAAKJ,KAAK;AAAED,MAAAA,SAAS,EAAEO,IAAI,CAAC,WAAWR,IAAI,CAAA,CAAE,EAAEC,SAAS;AAAE,MAAG;AAChF;AACA,EAAA,MAAMK,SAAS,GAAGP,EAAE,IAAIN,gBAAgB,CAACH,YAAY,CAAC;EACtD,oBAAOiB,GAAA,CAACD,SAAS,EAAA;AAAA,IAAA,GAAKJ,KAAK;AAAED,IAAAA,SAAS,EAAEO,IAAI,CAAC,WAAWlB,YAAY,CAAA,CAAE,EAAEW,SAAS;AAAE,IAAG;AACxF;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tooltip.js","sources":["../../src/tooltip/Tooltip.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/ban-ts-comment */\nimport { clsx } from 'clsx';\nimport {\n AriaAttributes,\n PropsWithChildren,\n ReactElement,\n ReactNode,\n cloneElement,\n useEffect,\n useId,\n useRef,\n useState,\n} from 'react';\nimport { usePopper } from 'react-popper';\n\nimport { CommonProps, Position } from '../common';\nimport {\n PositionBottom,\n PositionLeft,\n PositionRight,\n PositionTop,\n} from '../common/propsValues/position';\n\nexport type TooltipProps = PropsWithChildren<{\n position?: PositionTop | PositionRight | PositionBottom | PositionLeft;\n label: ReactNode;\n id?: string;\n}> &\n CommonProps;\n\nconst Tooltip = ({\n position = Position.TOP,\n children = undefined,\n label,\n id,\n className,\n}: TooltipProps) => {\n const [open, setOpen] = useState(false);\n const anchorReference = useRef(null);\n const [arrowElement, setArrowElement] = useState(null);\n const [popperElement, setPopperElement] = useState(null);\n\n const fallbackId = useId();\n const tooltipId = id ?? fallbackId;\n const modifiers = [];\n\n modifiers.push({\n name: 'arrow',\n options: {\n element: arrowElement,\n options: {\n padding: 8, // 8px from the edges of the popper\n },\n },\n });\n // This lets you displace a popper element from its reference element.\n modifiers.push({ name: 'offset', options: { offset: [0, 16] } });\n modifiers.push({\n name: 'flip',\n options: {\n fallbackPlacements: Position.TOP,\n },\n });\n\n const { styles, attributes, forceUpdate } = usePopper(anchorReference.current, popperElement, {\n placement: position,\n modifiers,\n });\n\n // If the trigger is not visible when the position is calculated, it will be incorrect. Because this can happen repeatedly (on resize for example),\n // it is most simple just to always position before opening\n useEffect(() => {\n if (open && forceUpdate) {\n forceUpdate();\n }\n }, [open]);\n\n return (\n <span\n ref={anchorReference}\n className=\"tw-tooltip-container\"\n onMouseOver={() => setOpen(true)}\n onFocus={() => setOpen(true)}\n onMouseOut={() => setOpen(false)}\n onBlur={() => setOpen(false)}\n >\n {children\n ? cloneElement(children as ReactElement<Pick<AriaAttributes, 'aria-describedby'>>, {\n 'aria-describedby': `${tooltipId}-tooltip`,\n })\n : null}\n <div\n // @ts-expect-error\n ref={setPopperElement}\n className={clsx(\n 'np-tooltip',\n 'np-panel',\n open ? `np-panel--open np-tooltip--open` : null,\n className,\n )}\n style={{ ...styles.popper }}\n {...attributes.popper}\n aria-hidden={!open}\n role=\"tooltip\"\n id={`${tooltipId}-tooltip`}\n >\n <div className=\"np-panel__content tooltip-inner\">\n {label}\n <div\n // @ts-expect-error\n ref={setArrowElement}\n className={clsx('np-panel__arrow')}\n style={styles.arrow}\n />\n </div>\n </div>\n </span>\n );\n};\n\nexport default Tooltip;\n"],"names":["Tooltip","position","Position","TOP","children","undefined","label","id","className","open","setOpen","useState","anchorReference","useRef","arrowElement","setArrowElement","popperElement","setPopperElement","fallbackId","useId","tooltipId","modifiers","push","name","options","element","padding","offset","fallbackPlacements","styles","attributes","forceUpdate","usePopper","current","placement","useEffect","_jsxs","ref","onMouseOver","onFocus","onMouseOut","onBlur","cloneElement","_jsx","clsx","style","popper","role","arrow"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AA8BMA,MAAAA,OAAO,GAAGA,CAAC;YACfC,UAAQ,GAAGC,iBAAQ,CAACC,GAAG;AACvBC,EAAAA,QAAQ,GAAGC,SAAS;EACpBC,KAAK;EACLC,EAAE;AACFC,EAAAA
|
|
1
|
+
{"version":3,"file":"Tooltip.js","sources":["../../src/tooltip/Tooltip.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/ban-ts-comment */\nimport { clsx } from 'clsx';\nimport {\n AriaAttributes,\n PropsWithChildren,\n ReactElement,\n ReactNode,\n cloneElement,\n useEffect,\n useId,\n useRef,\n useState,\n} from 'react';\nimport { usePopper } from 'react-popper';\n\nimport { CommonProps, Position } from '../common';\nimport {\n PositionBottom,\n PositionLeft,\n PositionRight,\n PositionTop,\n} from '../common/propsValues/position';\n\nexport type TooltipProps = PropsWithChildren<{\n position?: PositionTop | PositionRight | PositionBottom | PositionLeft;\n label: ReactNode;\n id?: string;\n}> &\n CommonProps;\n\nconst Tooltip = ({\n position = Position.TOP,\n children = undefined,\n label,\n id,\n className,\n}: TooltipProps) => {\n const [open, setOpen] = useState(false);\n const anchorReference = useRef(null);\n const [arrowElement, setArrowElement] = useState(null);\n const [popperElement, setPopperElement] = useState(null);\n\n const fallbackId = useId();\n const tooltipId = id ?? fallbackId;\n const modifiers = [];\n\n modifiers.push({\n name: 'arrow',\n options: {\n element: arrowElement,\n options: {\n padding: 8, // 8px from the edges of the popper\n },\n },\n });\n // This lets you displace a popper element from its reference element.\n modifiers.push({ name: 'offset', options: { offset: [0, 16] } });\n modifiers.push({\n name: 'flip',\n options: {\n fallbackPlacements: Position.TOP,\n },\n });\n\n const { styles, attributes, forceUpdate } = usePopper(anchorReference.current, popperElement, {\n placement: position,\n modifiers,\n });\n\n // If the trigger is not visible when the position is calculated, it will be incorrect. Because this can happen repeatedly (on resize for example),\n // it is most simple just to always position before opening\n useEffect(() => {\n if (open && forceUpdate) {\n forceUpdate();\n }\n }, [open]);\n\n return (\n <span\n ref={anchorReference}\n className=\"tw-tooltip-container\"\n onMouseOver={() => setOpen(true)}\n onFocus={() => setOpen(true)}\n onMouseOut={() => setOpen(false)}\n onBlur={() => setOpen(false)}\n >\n {children\n ? cloneElement(children as ReactElement<Pick<AriaAttributes, 'aria-describedby'>>, {\n 'aria-describedby': `${tooltipId}-tooltip`,\n })\n : null}\n <div\n // @ts-expect-error\n ref={setPopperElement}\n className={clsx(\n 'np-tooltip',\n 'np-panel',\n open ? `np-panel--open np-tooltip--open` : null,\n className,\n )}\n style={{ ...styles.popper }}\n {...attributes.popper}\n aria-hidden={!open}\n role=\"tooltip\"\n id={`${tooltipId}-tooltip`}\n >\n <div className=\"np-panel__content tooltip-inner\">\n {label}\n <div\n // @ts-expect-error\n ref={setArrowElement}\n className={clsx('np-panel__arrow')}\n style={styles.arrow}\n />\n </div>\n </div>\n </span>\n );\n};\n\nexport default Tooltip;\n"],"names":["Tooltip","position","Position","TOP","children","undefined","label","id","className","open","setOpen","useState","anchorReference","useRef","arrowElement","setArrowElement","popperElement","setPopperElement","fallbackId","useId","tooltipId","modifiers","push","name","options","element","padding","offset","fallbackPlacements","styles","attributes","forceUpdate","usePopper","current","placement","useEffect","_jsxs","ref","onMouseOver","onFocus","onMouseOut","onBlur","cloneElement","_jsx","clsx","style","popper","role","arrow"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AA8BMA,MAAAA,OAAO,GAAGA,CAAC;YACfC,UAAQ,GAAGC,iBAAQ,CAACC,GAAG;AACvBC,EAAAA,QAAQ,GAAGC,SAAS;EACpBC,KAAK;EACLC,EAAE;AACFC,EAAAA;AACa,CAAA,KAAI;EACjB,MAAM,CAACC,IAAI,EAAEC,OAAO,CAAC,GAAGC,cAAQ,CAAC,KAAK,CAAC;AACvC,EAAA,MAAMC,eAAe,GAAGC,YAAM,CAAC,IAAI,CAAC;EACpC,MAAM,CAACC,YAAY,EAAEC,eAAe,CAAC,GAAGJ,cAAQ,CAAC,IAAI,CAAC;EACtD,MAAM,CAACK,aAAa,EAAEC,gBAAgB,CAAC,GAAGN,cAAQ,CAAC,IAAI,CAAC;AAExD,EAAA,MAAMO,UAAU,GAAGC,WAAK,EAAE;AAC1B,EAAA,MAAMC,SAAS,GAAGb,EAAE,IAAIW,UAAU;EAClC,MAAMG,SAAS,GAAG,EAAE;EAEpBA,SAAS,CAACC,IAAI,CAAC;AACbC,IAAAA,IAAI,EAAE,OAAO;AACbC,IAAAA,OAAO,EAAE;AACPC,MAAAA,OAAO,EAAEX,YAAY;AACrBU,MAAAA,OAAO,EAAE;QACPE,OAAO,EAAE,CAAC;AACX;AACF;AACF,GAAA,CAAC;AACF;EACAL,SAAS,CAACC,IAAI,CAAC;AAAEC,IAAAA,IAAI,EAAE,QAAQ;AAAEC,IAAAA,OAAO,EAAE;AAAEG,MAAAA,MAAM,EAAE,CAAC,CAAC,EAAE,EAAE;AAAC;AAAI,GAAA,CAAC;EAChEN,SAAS,CAACC,IAAI,CAAC;AACbC,IAAAA,IAAI,EAAE,MAAM;AAC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MAAM;AACrB,MAAA,aAAA,EAAa,CAACrC,IAAK;AACnBsC,MAAAA,IAAI,EAAC,SAAS;MACdxC,EAAE,EAAE,CAAGa,EAAAA,SAAS,CAAW,QAAA,CAAA;AAAAhB,MAAAA,QAAA,eAE3BgC,eAAA,CAAA,KAAA,EAAA;AAAK5B,QAAAA,SAAS,EAAC,iCAAiC;QAAAJ,QAAA,EAAA,CAC7CE,KAAK,eACNqC,cAAA,CAAA,KAAA,EAAA;AACE;AACAN,UAAAA,GAAG,EAAEtB,eAAgB;AACrBP,UAAAA,SAAS,EAAEoC,SAAI,CAAC,iBAAiB,CAAE;UACnCC,KAAK,EAAEhB,MAAM,CAACmB;AAAM,SAExB,CAAA;OAAK;AACP,KAAK,CACP;AAAA,GAAM,CAAC;AAEX;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tooltip.mjs","sources":["../../src/tooltip/Tooltip.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/ban-ts-comment */\nimport { clsx } from 'clsx';\nimport {\n AriaAttributes,\n PropsWithChildren,\n ReactElement,\n ReactNode,\n cloneElement,\n useEffect,\n useId,\n useRef,\n useState,\n} from 'react';\nimport { usePopper } from 'react-popper';\n\nimport { CommonProps, Position } from '../common';\nimport {\n PositionBottom,\n PositionLeft,\n PositionRight,\n PositionTop,\n} from '../common/propsValues/position';\n\nexport type TooltipProps = PropsWithChildren<{\n position?: PositionTop | PositionRight | PositionBottom | PositionLeft;\n label: ReactNode;\n id?: string;\n}> &\n CommonProps;\n\nconst Tooltip = ({\n position = Position.TOP,\n children = undefined,\n label,\n id,\n className,\n}: TooltipProps) => {\n const [open, setOpen] = useState(false);\n const anchorReference = useRef(null);\n const [arrowElement, setArrowElement] = useState(null);\n const [popperElement, setPopperElement] = useState(null);\n\n const fallbackId = useId();\n const tooltipId = id ?? fallbackId;\n const modifiers = [];\n\n modifiers.push({\n name: 'arrow',\n options: {\n element: arrowElement,\n options: {\n padding: 8, // 8px from the edges of the popper\n },\n },\n });\n // This lets you displace a popper element from its reference element.\n modifiers.push({ name: 'offset', options: { offset: [0, 16] } });\n modifiers.push({\n name: 'flip',\n options: {\n fallbackPlacements: Position.TOP,\n },\n });\n\n const { styles, attributes, forceUpdate } = usePopper(anchorReference.current, popperElement, {\n placement: position,\n modifiers,\n });\n\n // If the trigger is not visible when the position is calculated, it will be incorrect. Because this can happen repeatedly (on resize for example),\n // it is most simple just to always position before opening\n useEffect(() => {\n if (open && forceUpdate) {\n forceUpdate();\n }\n }, [open]);\n\n return (\n <span\n ref={anchorReference}\n className=\"tw-tooltip-container\"\n onMouseOver={() => setOpen(true)}\n onFocus={() => setOpen(true)}\n onMouseOut={() => setOpen(false)}\n onBlur={() => setOpen(false)}\n >\n {children\n ? cloneElement(children as ReactElement<Pick<AriaAttributes, 'aria-describedby'>>, {\n 'aria-describedby': `${tooltipId}-tooltip`,\n })\n : null}\n <div\n // @ts-expect-error\n ref={setPopperElement}\n className={clsx(\n 'np-tooltip',\n 'np-panel',\n open ? `np-panel--open np-tooltip--open` : null,\n className,\n )}\n style={{ ...styles.popper }}\n {...attributes.popper}\n aria-hidden={!open}\n role=\"tooltip\"\n id={`${tooltipId}-tooltip`}\n >\n <div className=\"np-panel__content tooltip-inner\">\n {label}\n <div\n // @ts-expect-error\n ref={setArrowElement}\n className={clsx('np-panel__arrow')}\n style={styles.arrow}\n />\n </div>\n </div>\n </span>\n );\n};\n\nexport default Tooltip;\n"],"names":["Tooltip","position","Position","TOP","children","undefined","label","id","className","open","setOpen","useState","anchorReference","useRef","arrowElement","setArrowElement","popperElement","setPopperElement","fallbackId","useId","tooltipId","modifiers","push","name","options","element","padding","offset","fallbackPlacements","styles","attributes","forceUpdate","usePopper","current","placement","useEffect","_jsxs","ref","onMouseOver","onFocus","onMouseOut","onBlur","cloneElement","_jsx","clsx","style","popper","role","arrow"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AA8BMA,MAAAA,OAAO,GAAGA,CAAC;EACfC,QAAQ,GAAGC,QAAQ,CAACC,GAAG;AACvBC,EAAAA,QAAQ,GAAGC,SAAS;EACpBC,KAAK;EACLC,EAAE;AACFC,EAAAA
|
|
1
|
+
{"version":3,"file":"Tooltip.mjs","sources":["../../src/tooltip/Tooltip.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/ban-ts-comment */\nimport { clsx } from 'clsx';\nimport {\n AriaAttributes,\n PropsWithChildren,\n ReactElement,\n ReactNode,\n cloneElement,\n useEffect,\n useId,\n useRef,\n useState,\n} from 'react';\nimport { usePopper } from 'react-popper';\n\nimport { CommonProps, Position } from '../common';\nimport {\n PositionBottom,\n PositionLeft,\n PositionRight,\n PositionTop,\n} from '../common/propsValues/position';\n\nexport type TooltipProps = PropsWithChildren<{\n position?: PositionTop | PositionRight | PositionBottom | PositionLeft;\n label: ReactNode;\n id?: string;\n}> &\n CommonProps;\n\nconst Tooltip = ({\n position = Position.TOP,\n children = undefined,\n label,\n id,\n className,\n}: TooltipProps) => {\n const [open, setOpen] = useState(false);\n const anchorReference = useRef(null);\n const [arrowElement, setArrowElement] = useState(null);\n const [popperElement, setPopperElement] = useState(null);\n\n const fallbackId = useId();\n const tooltipId = id ?? fallbackId;\n const modifiers = [];\n\n modifiers.push({\n name: 'arrow',\n options: {\n element: arrowElement,\n options: {\n padding: 8, // 8px from the edges of the popper\n },\n },\n });\n // This lets you displace a popper element from its reference element.\n modifiers.push({ name: 'offset', options: { offset: [0, 16] } });\n modifiers.push({\n name: 'flip',\n options: {\n fallbackPlacements: Position.TOP,\n },\n });\n\n const { styles, attributes, forceUpdate } = usePopper(anchorReference.current, popperElement, {\n placement: position,\n modifiers,\n });\n\n // If the trigger is not visible when the position is calculated, it will be incorrect. Because this can happen repeatedly (on resize for example),\n // it is most simple just to always position before opening\n useEffect(() => {\n if (open && forceUpdate) {\n forceUpdate();\n }\n }, [open]);\n\n return (\n <span\n ref={anchorReference}\n className=\"tw-tooltip-container\"\n onMouseOver={() => setOpen(true)}\n onFocus={() => setOpen(true)}\n onMouseOut={() => setOpen(false)}\n onBlur={() => setOpen(false)}\n >\n {children\n ? cloneElement(children as ReactElement<Pick<AriaAttributes, 'aria-describedby'>>, {\n 'aria-describedby': `${tooltipId}-tooltip`,\n })\n : null}\n <div\n // @ts-expect-error\n ref={setPopperElement}\n className={clsx(\n 'np-tooltip',\n 'np-panel',\n open ? `np-panel--open np-tooltip--open` : null,\n className,\n )}\n style={{ ...styles.popper }}\n {...attributes.popper}\n aria-hidden={!open}\n role=\"tooltip\"\n id={`${tooltipId}-tooltip`}\n >\n <div className=\"np-panel__content tooltip-inner\">\n {label}\n <div\n // @ts-expect-error\n ref={setArrowElement}\n className={clsx('np-panel__arrow')}\n style={styles.arrow}\n />\n </div>\n </div>\n </span>\n );\n};\n\nexport default Tooltip;\n"],"names":["Tooltip","position","Position","TOP","children","undefined","label","id","className","open","setOpen","useState","anchorReference","useRef","arrowElement","setArrowElement","popperElement","setPopperElement","fallbackId","useId","tooltipId","modifiers","push","name","options","element","padding","offset","fallbackPlacements","styles","attributes","forceUpdate","usePopper","current","placement","useEffect","_jsxs","ref","onMouseOver","onFocus","onMouseOut","onBlur","cloneElement","_jsx","clsx","style","popper","role","arrow"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AA8BMA,MAAAA,OAAO,GAAGA,CAAC;EACfC,QAAQ,GAAGC,QAAQ,CAACC,GAAG;AACvBC,EAAAA,QAAQ,GAAGC,SAAS;EACpBC,KAAK;EACLC,EAAE;AACFC,EAAAA;AACa,CAAA,KAAI;EACjB,MAAM,CAACC,IAAI,EAAEC,OAAO,CAAC,GAAGC,QAAQ,CAAC,KAAK,CAAC;AACvC,EAAA,MAAMC,eAAe,GAAGC,MAAM,CAAC,IAAI,CAAC;EACpC,MAAM,CAACC,YAAY,EAAEC,eAAe,CAAC,GAAGJ,QAAQ,CAAC,IAAI,CAAC;EACtD,MAAM,CAACK,aAAa,EAAEC,gBAAgB,CAAC,GAAG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ends React.Component {
|
|
49
|
-
static defaultProps = {
|
|
49
|
+
static defaultProps = (() => ({
|
|
50
50
|
allowNew: false,
|
|
51
51
|
autoFillOnBlur: true,
|
|
52
52
|
autoFocus: false,
|
|
@@ -61,7 +61,7 @@ class Typeahead extends React.Component {
|
|
|
61
61
|
showNewEntry: true,
|
|
62
62
|
size: size.Size.MEDIUM,
|
|
63
63
|
validateChip: () => true
|
|
64
|
-
};
|
|
64
|
+
}))();
|
|
65
65
|
optionRefs;
|
|
66
66
|
constructor(props) {
|
|
67
67
|
super(props);
|
|
@@ -432,68 +432,64 @@ class Typeahead extends React.Component {
|
|
|
432
432
|
const displayAlert = !errorState && alert || alert && alertType === sentiment.Sentiment.ERROR;
|
|
433
433
|
const hasWarning = displayAlert && alertType === sentiment.Sentiment.WARNING;
|
|
434
434
|
const hasInfo = displayAlert && alertType === sentiment.Sentiment.NEUTRAL;
|
|
435
|
-
return (
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
435
|
+
return /*#__PURE__*/ /* eslint-disable-next-line jsx-a11y/click-events-have-key-events */jsxRuntime.jsx("div", {
|
|
436
|
+
role: "group",
|
|
437
|
+
...inputAttributes,
|
|
438
|
+
id: id,
|
|
439
|
+
className: clsx.clsx('typeahead', `typeahead-${size}`, {
|
|
440
|
+
'typeahead--has-value': selected.length > 0,
|
|
441
|
+
'typeahead--empty': selected.length === 0,
|
|
442
|
+
'typeahead--multiple': multiple,
|
|
443
|
+
open: dropdownOpen
|
|
444
|
+
}),
|
|
445
|
+
onClick: documentIosClick.stopPropagation,
|
|
446
|
+
children: /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
447
|
+
className: clsx.clsx('form-group', {
|
|
448
|
+
'has-error': hasError,
|
|
449
|
+
'has-warning': hasWarning,
|
|
450
|
+
'has-info': hasInfo
|
|
447
451
|
}),
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
'has-error': hasError,
|
|
452
|
-
'has-warning': hasWarning,
|
|
453
|
-
'has-info': hasInfo
|
|
452
|
+
children: [/*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
453
|
+
className: clsx.clsx(`input-group input-group-${size}`, {
|
|
454
|
+
'input-group--has-error': hasError
|
|
454
455
|
}),
|
|
455
|
-
children: [/*#__PURE__*/jsxRuntime.
|
|
456
|
-
className:
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
}), displayAlert ? /*#__PURE__*/jsxRuntime.jsx(InlineAlert.default, {
|
|
491
|
-
type: alert.type,
|
|
492
|
-
children: alert.message
|
|
493
|
-
}) : menu]
|
|
494
|
-
})
|
|
456
|
+
children: [addon && /*#__PURE__*/jsxRuntime.jsx("span", {
|
|
457
|
+
className: "input-group-addon input-group-addon--search",
|
|
458
|
+
children: addon
|
|
459
|
+
}), /*#__PURE__*/jsxRuntime.jsx(TypeaheadInput.default, {
|
|
460
|
+
autoFocus,
|
|
461
|
+
multiple,
|
|
462
|
+
dropdownOpen,
|
|
463
|
+
placeholder,
|
|
464
|
+
selected,
|
|
465
|
+
maxHeight,
|
|
466
|
+
id: id,
|
|
467
|
+
name: name,
|
|
468
|
+
value: query,
|
|
469
|
+
typeaheadId: id,
|
|
470
|
+
renderChip: this.renderChip,
|
|
471
|
+
autoComplete: inputAutoComplete,
|
|
472
|
+
ariaActivedescendant: keyboardFocusedOptionIndex !== null && options[keyboardFocusedOptionIndex] ? `option-${options[keyboardFocusedOptionIndex].label.replace(/\s+/g, '-')}` : undefined,
|
|
473
|
+
onChange: this.handleOnChange,
|
|
474
|
+
onKeyDown: this.handleOnKeyDown,
|
|
475
|
+
onFocus: this.handleOnFocus,
|
|
476
|
+
onPaste: this.handleOnPaste
|
|
477
|
+
}), clearButton && /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
478
|
+
className: "input-group-addon",
|
|
479
|
+
children: /*#__PURE__*/jsxRuntime.jsx("button", {
|
|
480
|
+
type: "button",
|
|
481
|
+
className: "btn-unstyled",
|
|
482
|
+
"aria-label": this.props?.intl?.formatMessage(Typeahead_messages.default.clearLabel),
|
|
483
|
+
onClick: this.clear,
|
|
484
|
+
children: /*#__PURE__*/jsxRuntime.jsx(icons.Cross, {})
|
|
485
|
+
})
|
|
486
|
+
})]
|
|
487
|
+
}), displayAlert ? /*#__PURE__*/jsxRuntime.jsx(InlineAlert.default, {
|
|
488
|
+
type: alert.type,
|
|
489
|
+
children: alert.message
|
|
490
|
+
}) : menu]
|
|
495
491
|
})
|
|
496
|
-
);
|
|
492
|
+
});
|
|
497
493
|
}
|
|
498
494
|
}
|
|
499
495
|
var Typeahead$1 = reactIntl.injectIntl(contexts.withInputAttributes(Typeahead, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Typeahead.js","sources":["../../src/typeahead/Typeahead.tsx"],"sourcesContent":["import { Cross as CrossIcon } from '@transferwise/icons';\nimport { clsx } from 'clsx';\nimport { DebouncedFunc } from 'lodash';\nimport clamp from 'lodash.clamp';\nimport debounce from 'lodash.debounce';\nimport React, { Component, ReactNode } from 'react';\nimport { injectIntl, WrappedComponentProps } from 'react-intl';\n\nimport Chip from '../chips/Chip';\nimport {\n Size,\n Sentiment,\n SizeMedium,\n SizeLarge,\n addClickClassToDocumentOnIos,\n removeClickClassFromDocumentOnIos,\n stopPropagation,\n} from '../common';\nimport InlineAlert from '../inlineAlert';\nimport { InlineAlertProps } from '../inlineAlert/InlineAlert';\nimport { withInputAttributes, WithInputAttributesProps } from '../inputs/contexts';\n\nimport TypeaheadInput from './typeaheadInput/TypeaheadInput';\nimport TypeaheadOption from './typeaheadOption/TypeaheadOption';\nimport messages from './Typeahead.messages';\n\nconst DEFAULT_MIN_QUERY_LENGTH = 3;\nconst SEARCH_DELAY = 200;\n\nexport type TypeaheadOption<T = string> = {\n label: string;\n note?: string;\n secondary?: string;\n value?: T;\n clearQueryOnSelect?: boolean;\n keepFocusOnSelect?: boolean;\n};\n\nexport interface TypeaheadProps<T> extends Partial<WrappedComponentProps> {\n id: string;\n name: string;\n addon?: ReactNode;\n alert?: {\n message: InlineAlertProps['children'];\n type?: InlineAlertProps['type'];\n };\n allowNew?: boolean;\n autoFillOnBlur?: boolean;\n autoFocus?: boolean;\n chipSeparators?: readonly string[];\n clearable?: boolean;\n footer?: ReactNode;\n initialValue?: readonly TypeaheadOption<T>[];\n inputAutoComplete?: string;\n maxHeight?: number;\n minQueryLength?: number;\n placeholder?: string;\n multiple?: boolean;\n options: readonly TypeaheadOption<T>[];\n searchDelay?: number;\n showSuggestions?: boolean;\n showNewEntry?: boolean;\n size?: SizeMedium | SizeLarge;\n\n onBlur?: () => void;\n onChange: (options: TypeaheadOption<T>[]) => void;\n onFocus?: () => void;\n onInputChange?: (query: string) => void;\n onSearch?: (query: string) => void;\n validateChip?: (chip: TypeaheadOption<T>) => boolean;\n}\n\ntype TypeaheadPropsWithInputAttributes<T> = TypeaheadProps<T> &\n Partial<WithInputAttributesProps> &\n WrappedComponentProps;\n\ntype TypeaheadState<T> = {\n selected: readonly TypeaheadOption<T>[];\n keyboardFocusedOptionIndex: number | null;\n errorState: boolean;\n query: string;\n optionsShown: boolean;\n isFocused: boolean;\n};\n\nclass Typeahead<T> extends Component<TypeaheadPropsWithInputAttributes<T>, TypeaheadState<T>> {\n declare props: TypeaheadPropsWithInputAttributes<T> &\n Required<Pick<TypeaheadPropsWithInputAttributes<T>, keyof typeof Typeahead.defaultProps>>;\n\n static defaultProps = {\n allowNew: false,\n autoFillOnBlur: true,\n autoFocus: false,\n chipSeparators: [],\n clearable: true,\n initialValue: [],\n inputAutoComplete: 'new-password',\n minQueryLength: DEFAULT_MIN_QUERY_LENGTH,\n multiple: false,\n searchDelay: SEARCH_DELAY,\n showSuggestions: true,\n showNewEntry: true,\n size: Size.MEDIUM,\n validateChip: () => true,\n } satisfies Partial<TypeaheadProps<unknown>>;\n optionRefs: (React.RefObject<HTMLLIElement> | null)[];\n\n constructor(props: TypeaheadPropsWithInputAttributes<T>) {\n super(props);\n const { searchDelay, initialValue, multiple } = this.props;\n this.handleSearchDebounced = debounce(this.handleSearch, searchDelay);\n const initialQuery = !multiple && initialValue.length > 0 ? initialValue[0].label : '';\n this.state = {\n selected: initialValue,\n errorState: false,\n query: initialQuery,\n keyboardFocusedOptionIndex: null,\n optionsShown: false,\n isFocused: false,\n };\n this.optionRefs = [] as (React.RefObject<HTMLLIElement> | null)[];\n }\n\n handleSearchDebounced: DebouncedFunc<Typeahead<T>['handleSearch']>;\n\n UNSAFE_componentWillReceiveProps(nextProps: TypeaheadPropsWithInputAttributes<T>) {\n if (nextProps.multiple !== this.props.multiple) {\n this.setState((previousState) => {\n const { selected } = previousState;\n if (!nextProps.multiple && selected.length > 0) {\n return {\n query: selected[0].label,\n selected: [selected[0]],\n };\n }\n return {\n selected: previousState.selected,\n query: '',\n };\n });\n }\n }\n\n componentWillUnmount() {\n this.handleSearchDebounced.cancel();\n }\n\n handleOnFocus = () => {\n this.showMenu();\n this.props.onFocus?.();\n };\n\n onOptionSelected = (event: React.MouseEvent, item: TypeaheadOption<T>) => {\n event.preventDefault();\n this.selectItem(item);\n };\n\n handleOnChange: React.ChangeEventHandler<HTMLInputElement> = (event) => {\n const { optionsShown, selected } = this.state;\n const { multiple, onInputChange } = this.props;\n\n if (!optionsShown) {\n this.showMenu();\n }\n\n const query = event.target.value;\n\n if (!multiple && selected.length > 0) {\n this.updateSelectedValue([]);\n }\n\n this.setState({ query }, () => {\n this.handleSearchDebounced(query);\n if (onInputChange) {\n onInputChange(query);\n }\n });\n };\n\n handleOnPaste: React.ClipboardEventHandler<HTMLInputElement> = (event) => {\n const { allowNew, multiple, chipSeparators } = this.props;\n const { selected } = this.state;\n\n if (allowNew && multiple && chipSeparators.length > 0) {\n event.preventDefault();\n const value = event.clipboardData.getData('text');\n if (value) {\n const regex = new RegExp(chipSeparators.join('|'));\n const pastedChips = value\n .split(regex)\n .map((label) => ({ label: label.trim() }))\n .filter((chip) => chip.label);\n\n this.updateSelectedValue([...selected, ...pastedChips]);\n }\n }\n };\n\n handleOnKeyDown: React.KeyboardEventHandler<HTMLInputElement> = (event) => {\n const { showSuggestions, allowNew, multiple, chipSeparators, options } = this.props;\n const { keyboardFocusedOptionIndex, query, selected } = this.state;\n const chipsMode = !showSuggestions && allowNew && multiple;\n\n if (chipsMode && ['Enter', 'Tab', ...chipSeparators].includes(event.key) && query.trim()) {\n event.preventDefault();\n this.selectItem({ label: query });\n } else {\n switch (event.key) {\n case 'ArrowDown':\n event.preventDefault();\n this.moveFocusedOption(1);\n break;\n case 'ArrowUp':\n event.preventDefault();\n this.moveFocusedOption(-1);\n break;\n case 'Enter':\n event.preventDefault();\n if (keyboardFocusedOptionIndex != null && options[keyboardFocusedOptionIndex]) {\n this.selectItem(options[keyboardFocusedOptionIndex]);\n } else if (allowNew && query.trim()) {\n this.selectItem({ label: query });\n }\n break;\n case 'Backspace':\n if (multiple && !query && selected.length > 0) {\n this.updateSelectedValue(selected.slice(0, -1));\n }\n break;\n default:\n break;\n }\n }\n };\n moveFocusedOption(offset: number) {\n this.setState((previousState) => {\n const { keyboardFocusedOptionIndex } = previousState;\n const { options } = this.props;\n let index = 0;\n if (keyboardFocusedOptionIndex !== null) {\n index = clamp(keyboardFocusedOptionIndex + offset, 0, options.length - 1);\n }\n const optionRef = this.optionRefs[index];\n if (optionRef?.current) {\n optionRef.current.focus(); // Set focus on the option element\n }\n return {\n keyboardFocusedOptionIndex: index,\n };\n });\n }\n\n selectItem = (item: TypeaheadOption<T>) => {\n const { multiple } = this.props;\n let selected = [...this.state.selected];\n let query;\n if (multiple) {\n selected.push(item);\n query = '';\n } else {\n selected = [item];\n query = item.label;\n }\n\n this.updateSelectedValue(selected);\n\n if (!item.keepFocusOnSelect) {\n this.hideMenu();\n }\n\n if (item.clearQueryOnSelect) {\n query = '';\n }\n\n this.setState({\n query,\n });\n };\n\n handleSearch = (query: string) => {\n const { onSearch } = this.props;\n if (onSearch) {\n onSearch(query);\n }\n\n this.setState((previousState) => ({\n keyboardFocusedOptionIndex: previousState.keyboardFocusedOptionIndex === null ? null : 0,\n }));\n };\n\n handleDocumentClick = () => {\n if (this.state.optionsShown) {\n this.hideMenu();\n const { allowNew, onBlur, autoFillOnBlur } = this.props;\n const { query } = this.state;\n this.setState({\n isFocused: false,\n });\n if (allowNew && autoFillOnBlur && query.trim()) {\n this.selectItem({ label: query });\n }\n\n if (onBlur) {\n onBlur();\n }\n }\n };\n\n showMenu = () => {\n this.setState(\n {\n isFocused: true,\n optionsShown: true,\n },\n () => {\n addClickClassToDocumentOnIos();\n document.addEventListener('click', this.handleDocumentClick, false);\n },\n );\n };\n\n hideMenu = () => {\n this.setState(\n {\n optionsShown: false,\n keyboardFocusedOptionIndex: null,\n },\n () => {\n removeClickClassFromDocumentOnIos();\n document.removeEventListener('click', this.handleDocumentClick, false);\n },\n );\n };\n\n updateSelectedValue = (selected: readonly TypeaheadOption<T>[]) => {\n const { onChange, validateChip } = this.props;\n\n const errorState = selected.some((chip) => !validateChip(chip));\n this.setState({ selected, errorState }, () => {\n onChange([...selected]);\n });\n };\n\n clear = (event: React.MouseEvent<HTMLButtonElement>) => {\n event.preventDefault();\n if (this.state.selected.length > 0) {\n this.updateSelectedValue([]);\n }\n\n this.setState({\n query: '',\n });\n };\n\n removeChip = (option: TypeaheadOption<T>) => {\n const { selected } = this.state;\n\n if (selected.length > 0) {\n this.updateSelectedValue([...selected.filter((selectedOption) => selectedOption !== option)]);\n }\n };\n\n renderChip = (option: TypeaheadOption<T>, idx: number): ReactNode => {\n const valid = this.props.validateChip?.(option);\n\n return (\n <Chip\n key={idx}\n label={option.label}\n className={clsx('m-t-1', {\n 'has-error': !valid,\n 'np-chip--valid': valid,\n })}\n onRemove={() => this.removeChip(option)}\n />\n );\n };\n\n renderMenu = ({\n footer,\n options,\n id,\n keyboardFocusedOptionIndex,\n query,\n allowNew,\n showNewEntry,\n dropdownOpen,\n }: Pick<\n TypeaheadPropsWithInputAttributes<T>,\n 'footer' | 'options' | 'id' | 'allowNew' | 'showNewEntry'\n > &\n Pick<TypeaheadState<T>, 'keyboardFocusedOptionIndex' | 'query'> & {\n dropdownOpen: boolean;\n }) => {\n const optionsToRender = [...options];\n if (\n allowNew &&\n query.trim() &&\n options.every((option) => option.label.trim().toUpperCase() !== query.trim().toUpperCase()) &&\n showNewEntry\n ) {\n optionsToRender.push({\n label: query,\n });\n }\n return (\n <div\n className={clsx('dropdown btn-group btn-block', { open: dropdownOpen })}\n id={`menu-${id}`}\n >\n {(!!optionsToRender.length || footer) && (\n <ul className=\"dropdown-menu\" role=\"menu\">\n {optionsToRender.map((option, idx) => {\n const ref = React.createRef<HTMLLIElement>();\n this.optionRefs[idx] = ref;\n return (\n <TypeaheadOption\n key={`${option.label}${idx.toString()}`}\n ref={ref}\n query={query}\n option={option}\n selected={keyboardFocusedOptionIndex === idx}\n id={String(option.label.replace(/\\s+/g, '-'))}\n onClick={(event) => {\n this.onOptionSelected(event, option);\n }}\n />\n );\n })}\n {footer}\n </ul>\n )}\n </div>\n );\n };\n\n render() {\n const {\n inputAttributes,\n id: idProp,\n placeholder,\n multiple,\n size,\n addon,\n name,\n clearable,\n allowNew,\n footer,\n showSuggestions,\n showNewEntry,\n options,\n minQueryLength,\n autoFocus,\n maxHeight,\n alert,\n inputAutoComplete,\n } = this.props;\n const id = idProp ?? inputAttributes?.id;\n\n const { errorState, query, selected, optionsShown, keyboardFocusedOptionIndex } = this.state;\n\n const clearButton = clearable && (query || selected.length > 0);\n\n const dropdownOpen = optionsShown && showSuggestions && query.length >= minQueryLength;\n\n const menu = this.renderMenu({\n footer,\n options,\n id,\n keyboardFocusedOptionIndex,\n query,\n allowNew,\n showNewEntry,\n dropdownOpen,\n });\n\n const alertType = alert?.type ?? Sentiment.NEUTRAL;\n const hasError = errorState || (alert && alertType === Sentiment.ERROR);\n const displayAlert = (!errorState && alert) || (alert && alertType === Sentiment.ERROR);\n const hasWarning = displayAlert && alertType === Sentiment.WARNING;\n const hasInfo = displayAlert && alertType === Sentiment.NEUTRAL;\n return (\n /* eslint-disable-next-line jsx-a11y/click-events-have-key-events */\n <div\n role=\"group\"\n {...inputAttributes}\n id={id}\n className={clsx('typeahead', `typeahead-${size}`, {\n 'typeahead--has-value': selected.length > 0,\n 'typeahead--empty': selected.length === 0,\n 'typeahead--multiple': multiple,\n open: dropdownOpen,\n })}\n onClick={stopPropagation}\n >\n <div\n className={clsx('form-group', {\n 'has-error': hasError,\n 'has-warning': hasWarning,\n 'has-info': hasInfo,\n })}\n >\n <div\n className={clsx(`input-group input-group-${size}`, {\n 'input-group--has-error': hasError,\n })}\n >\n {addon && <span className=\"input-group-addon input-group-addon--search\">{addon}</span>}\n\n <TypeaheadInput\n {...{\n autoFocus,\n multiple,\n dropdownOpen,\n placeholder,\n selected,\n maxHeight,\n }}\n id={id}\n name={name}\n value={query}\n typeaheadId={id}\n renderChip={this.renderChip}\n autoComplete={inputAutoComplete}\n ariaActivedescendant={\n keyboardFocusedOptionIndex !== null && options[keyboardFocusedOptionIndex]\n ? `option-${options[keyboardFocusedOptionIndex].label.replace(/\\s+/g, '-')}`\n : undefined\n }\n onChange={this.handleOnChange}\n onKeyDown={this.handleOnKeyDown}\n onFocus={this.handleOnFocus}\n onPaste={this.handleOnPaste}\n />\n\n {clearButton && (\n <div className=\"input-group-addon\">\n <button\n type=\"button\"\n className=\"btn-unstyled\"\n aria-label={this.props?.intl?.formatMessage(messages.clearLabel)}\n onClick={this.clear}\n >\n <CrossIcon />\n </button>\n </div>\n )}\n </div>\n {displayAlert ? <InlineAlert type={alert.type}>{alert.message}</InlineAlert> : menu}\n </div>\n </div>\n );\n }\n}\n\nexport default injectIntl(withInputAttributes(Typeahead, { nonLabelable: true })) as <T>(\n props: TypeaheadProps<T>,\n) => React.ReactElement;\n"],"names":["DEFAULT_MIN_QUERY_LENGTH","SEARCH_DELAY","Typeahead","Component","defaultProps","allowNew","autoFillOnBlur","autoFocus","chipSeparators","clearable","initialValue","inputAutoComplete","minQueryLength","multiple","searchDelay","showSuggestions","showNewEntry","size","Size","MEDIUM","validateChip","optionRefs","constructor","props","handleSearchDebounced","debounce","handleSearch","initialQuery","length","label","state","selected","errorState","query","keyboardFocusedOptionIndex","optionsShown","isFocused","UNSAFE_componentWillReceiveProps","nextProps","setState","previousState","componentWillUnmount","cancel","handleOnFocus","showMenu","onFocus","onOptionSelected","event","item","preventDefault","selectItem","handleOnChange","onInputChange","target","value","updateSelectedValue","handleOnPaste","clipboardData","getData","regex","RegExp","join","pastedChips","split","map","trim","filter","chip","handleOnKeyDown","options","chipsMode","includes","key","moveFocusedOption","slice","offset","index","clamp","optionRef","current","focus","push","keepFocusOnSelect","hideMenu","clearQueryOnSelect","onSearch","handleDocumentClick","onBlur","addClickClassToDocumentOnIos","document","addEventListener","removeClickClassFromDocumentOnIos","removeEventListener","onChange","some","clear","removeChip","option","selectedOption","renderChip","idx","valid","_jsx","Chip","className","clsx","onRemove","renderMenu","footer","id","dropdownOpen","optionsToRender","every","toUpperCase","open","children","_jsxs","role","ref","React","createRef","TypeaheadOption","String","replace","onClick","toString","render","inputAttributes","idProp","placeholder","addon","name","maxHeight","alert","clearButton","menu","alertType","type","Sentiment","NEUTRAL","hasError","ERROR","displayAlert","hasWarning","WARNING","hasInfo","stopPropagation","TypeaheadInput","typeaheadId","autoComplete","ariaActivedescendant","undefined","onKeyDown","onPaste","intl","formatMessage","messages","clearLabel","CrossIcon","InlineAlert","message","injectIntl","withInputAttributes","nonLabelable"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BA,MAAMA,wBAAwB,GAAG,CAAC,CAAA;AAClC,MAAMC,YAAY,GAAG,GAAG,CAAA;AA0DxB,MAAMC,SAAa,SAAQC,eAAkE,CAAA;AAI3F,EAAA,OAAOC,YAAY,GAAG;AACpBC,IAAAA,QAAQ,EAAE,KAAK;AACfC,IAAAA,cAAc,EAAE,IAAI;AACpBC,IAAAA,SAAS,EAAE,KAAK;AAChBC,IAAAA,cAAc,EAAE,EAAE;AAClBC,IAAAA,SAAS,EAAE,IAAI;AACfC,IAAAA,YAAY,EAAE,EAAE;AAChBC,IAAAA,iBAAiB,EAAE,cAAc;AACjCC,IAAAA,cAAc,EAAEZ,wBAAwB;AACxCa,IAAAA,QAAQ,EAAE,KAAK;AACfC,IAAAA,WAAW,EAAEb,YAAY;AACzBc,IAAAA,eAAe,EAAE,IAAI;AACrBC,IAAAA,YAAY,EAAE,IAAI;IAClBC,IAAI,EAAEC,SAAI,CAACC,MAAM;IACjBC,YAAY,EAAEA,MAAM,IAAA;GACsB,CAAA;EAC5CC,UAAU,CAAA;EAEVC,WAAAA,CAAYC,KAA2C,EAAA;IACrD,KAAK,CAACA,KAAK,CAAC,CAAA;IACZ,MAAM;MAAET,WAAW;MAAEJ,YAAY;AAAEG,MAAAA,QAAAA;KAAU,GAAG,IAAI,CAACU,KAAK,CAAA;IAC1D,IAAI,CAACC,qBAAqB,GAAGC,yBAAQ,CAAC,IAAI,CAACC,YAAY,EAAEZ,WAAW,CAAC,CAAA;AACrE,IAAA,MAAMa,YAAY,GAAG,CAACd,QAAQ,IAAIH,YAAY,CAACkB,MAAM,GAAG,CAAC,GAAGlB,YAAY,CAAC,CAAC,CAAC,CAACmB,KAAK,GAAG,EAAE,CAAA;IACtF,IAA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AK,CACN,CAAA;AAAA,WACE,CACL,EAAChB,YAAY,gBAAGxC,cAAA,CAACyD,mBAAW,EAAA;YAACtB,IAAI,EAAEJ,KAAK,CAACI,IAAK;YAAAtB,QAAA,EAAEkB,KAAK,CAAC2B,OAAAA;WAAqB,CAAC,GAAGzB,IAAI,CAAA;SAChF,CAAA;OACF,CAAA;AAAC,MAAA;AAEV,GAAA;;AAGF,kBAAe0B,oBAAU,CAACC,4BAAmB,CAAChK,SAAS,EAAE;AAAEiK,EAAAA,YAAY,EAAE,IAAA;AAAM,CAAA,CAAC,CAEzD;;;;"}
|
|
1
|
+
{"version":3,"file":"Typeahead.js","sources":["../../src/typeahead/Typeahead.tsx"],"sourcesContent":["import { Cross as CrossIcon } from '@transferwise/icons';\nimport { clsx } from 'clsx';\nimport { DebouncedFunc } from 'lodash';\nimport clamp from 'lodash.clamp';\nimport debounce from 'lodash.debounce';\nimport React, { Component, ReactNode } from 'react';\nimport { injectIntl, WrappedComponentProps } from 'react-intl';\n\nimport Chip from '../chips/Chip';\nimport {\n Size,\n Sentiment,\n SizeMedium,\n SizeLarge,\n addClickClassToDocumentOnIos,\n removeClickClassFromDocumentOnIos,\n stopPropagation,\n} from '../common';\nimport InlineAlert from '../inlineAlert';\nimport { InlineAlertProps } from '../inlineAlert/InlineAlert';\nimport { withInputAttributes, WithInputAttributesProps } from '../inputs/contexts';\n\nimport TypeaheadInput from './typeaheadInput/TypeaheadInput';\nimport TypeaheadOption from './typeaheadOption/TypeaheadOption';\nimport messages from './Typeahead.messages';\n\nconst DEFAULT_MIN_QUERY_LENGTH = 3;\nconst SEARCH_DELAY = 200;\n\nexport type TypeaheadOption<T = string> = {\n label: string;\n note?: string;\n secondary?: string;\n value?: T;\n clearQueryOnSelect?: boolean;\n keepFocusOnSelect?: boolean;\n};\n\nexport interface TypeaheadProps<T> extends Partial<WrappedComponentProps> {\n id: string;\n name: string;\n addon?: ReactNode;\n alert?: {\n message: InlineAlertProps['children'];\n type?: InlineAlertProps['type'];\n };\n allowNew?: boolean;\n autoFillOnBlur?: boolean;\n autoFocus?: boolean;\n chipSeparators?: readonly string[];\n clearable?: boolean;\n footer?: ReactNode;\n initialValue?: readonly TypeaheadOption<T>[];\n inputAutoComplete?: string;\n maxHeight?: number;\n minQueryLength?: number;\n placeholder?: string;\n multiple?: boolean;\n options: readonly TypeaheadOption<T>[];\n searchDelay?: number;\n showSuggestions?: boolean;\n showNewEntry?: boolean;\n size?: SizeMedium | SizeLarge;\n\n onBlur?: () => void;\n onChange: (options: TypeaheadOption<T>[]) => void;\n onFocus?: () => void;\n onInputChange?: (query: string) => void;\n onSearch?: (query: string) => void;\n validateChip?: (chip: TypeaheadOption<T>) => boolean;\n}\n\ntype TypeaheadPropsWithInputAttributes<T> = TypeaheadProps<T> &\n Partial<WithInputAttributesProps> &\n WrappedComponentProps;\n\ntype TypeaheadState<T> = {\n selected: readonly TypeaheadOption<T>[];\n keyboardFocusedOptionIndex: number | null;\n errorState: boolean;\n query: string;\n optionsShown: boolean;\n isFocused: boolean;\n};\n\nclass Typeahead<T> extends Component<TypeaheadPropsWithInputAttributes<T>, TypeaheadState<T>> {\n declare props: TypeaheadPropsWithInputAttributes<T> &\n Required<Pick<TypeaheadPropsWithInputAttributes<T>, keyof typeof Typeahead.defaultProps>>;\n\n static defaultProps = {\n allowNew: false,\n autoFillOnBlur: true,\n autoFocus: false,\n chipSeparators: [],\n clearable: true,\n initialValue: [],\n inputAutoComplete: 'new-password',\n minQueryLength: DEFAULT_MIN_QUERY_LENGTH,\n multiple: false,\n searchDelay: SEARCH_DELAY,\n showSuggestions: true,\n showNewEntry: true,\n size: Size.MEDIUM,\n validateChip: () => true,\n } satisfies Partial<TypeaheadProps<unknown>>;\n optionRefs: (React.RefObject<HTMLLIElement> | null)[];\n\n constructor(props: TypeaheadPropsWithInputAttributes<T>) {\n super(props);\n const { searchDelay, initialValue, multiple } = this.props;\n this.handleSearchDebounced = debounce(this.handleSearch, searchDelay);\n const initialQuery = !multiple && initialValue.length > 0 ? initialValue[0].label : '';\n this.state = {\n selected: initialValue,\n errorState: false,\n query: initialQuery,\n keyboardFocusedOptionIndex: null,\n optionsShown: false,\n isFocused: false,\n };\n this.optionRefs = [] as (React.RefObject<HTMLLIElement> | null)[];\n }\n\n handleSearchDebounced: DebouncedFunc<Typeahead<T>['handleSearch']>;\n\n UNSAFE_componentWillReceiveProps(nextProps: TypeaheadPropsWithInputAttributes<T>) {\n if (nextProps.multiple !== this.props.multiple) {\n this.setState((previousState) => {\n const { selected } = previousState;\n if (!nextProps.multiple && selected.length > 0) {\n return {\n query: selected[0].label,\n selected: [selected[0]],\n };\n }\n return {\n selected: previousState.selected,\n query: '',\n };\n });\n }\n }\n\n componentWillUnmount() {\n this.handleSearchDebounced.cancel();\n }\n\n handleOnFocus = () => {\n this.showMenu();\n this.props.onFocus?.();\n };\n\n onOptionSelected = (event: React.MouseEvent, item: TypeaheadOption<T>) => {\n event.preventDefault();\n this.selectItem(item);\n };\n\n handleOnChange: React.ChangeEventHandler<HTMLInputElement> = (event) => {\n const { optionsShown, selected } = this.state;\n const { multiple, onInputChange } = this.props;\n\n if (!optionsShown) {\n this.showMenu();\n }\n\n const query = event.target.value;\n\n if (!multiple && selected.length > 0) {\n this.updateSelectedValue([]);\n }\n\n this.setState({ query }, () => {\n this.handleSearchDebounced(query);\n if (onInputChange) {\n onInputChange(query);\n }\n });\n };\n\n handleOnPaste: React.ClipboardEventHandler<HTMLInputElement> = (event) => {\n const { allowNew, multiple, chipSeparators } = this.props;\n const { selected } = this.state;\n\n if (allowNew && multiple && chipSeparators.length > 0) {\n event.preventDefault();\n const value = event.clipboardData.getData('text');\n if (value) {\n const regex = new RegExp(chipSeparators.join('|'));\n const pastedChips = value\n .split(regex)\n .map((label) => ({ label: label.trim() }))\n .filter((chip) => chip.label);\n\n this.updateSelectedValue([...selected, ...pastedChips]);\n }\n }\n };\n\n handleOnKeyDown: React.KeyboardEventHandler<HTMLInputElement> = (event) => {\n const { showSuggestions, allowNew, multiple, chipSeparators, options } = this.props;\n const { keyboardFocusedOptionIndex, query, selected } = this.state;\n const chipsMode = !showSuggestions && allowNew && multiple;\n\n if (chipsMode && ['Enter', 'Tab', ...chipSeparators].includes(event.key) && query.trim()) {\n event.preventDefault();\n this.selectItem({ label: query });\n } else {\n switch (event.key) {\n case 'ArrowDown':\n event.preventDefault();\n this.moveFocusedOption(1);\n break;\n case 'ArrowUp':\n event.preventDefault();\n this.moveFocusedOption(-1);\n break;\n case 'Enter':\n event.preventDefault();\n if (keyboardFocusedOptionIndex != null && options[keyboardFocusedOptionIndex]) {\n this.selectItem(options[keyboardFocusedOptionIndex]);\n } else if (allowNew && query.trim()) {\n this.selectItem({ label: query });\n }\n break;\n case 'Backspace':\n if (multiple && !query && selected.length > 0) {\n this.updateSelectedValue(selected.slice(0, -1));\n }\n break;\n default:\n break;\n }\n }\n };\n moveFocusedOption(offset: number) {\n this.setState((previousState) => {\n const { keyboardFocusedOptionIndex } = previousState;\n const { options } = this.props;\n let index = 0;\n if (keyboardFocusedOptionIndex !== null) {\n index = clamp(keyboardFocusedOptionIndex + offset, 0, options.length - 1);\n }\n const optionRef = this.optionRefs[index];\n if (optionRef?.current) {\n optionRef.current.focus(); // Set focus on the option element\n }\n return {\n keyboardFocusedOptionIndex: index,\n };\n });\n }\n\n selectItem = (item: TypeaheadOption<T>) => {\n const { multiple } = this.props;\n let selected = [...this.state.selected];\n let query;\n if (multiple) {\n selected.push(item);\n query = '';\n } else {\n selected = [item];\n query = item.label;\n }\n\n this.updateSelectedValue(selected);\n\n if (!item.keepFocusOnSelect) {\n this.hideMenu();\n }\n\n if (item.clearQueryOnSelect) {\n query = '';\n }\n\n this.setState({\n query,\n });\n };\n\n handleSearch = (query: string) => {\n const { onSearch } = this.props;\n if (onSearch) {\n onSearch(query);\n }\n\n this.setState((previousState) => ({\n keyboardFocusedOptionIndex: previousState.keyboardFocusedOptionIndex === null ? null : 0,\n }));\n };\n\n handleDocumentClick = () => {\n if (this.state.optionsShown) {\n this.hideMenu();\n const { allowNew, onBlur, autoFillOnBlur } = this.props;\n const { query } = this.state;\n this.setState({\n isFocused: false,\n });\n if (allowNew && autoFillOnBlur && query.trim()) {\n this.selectItem({ label: query });\n }\n\n if (onBlur) {\n onBlur();\n }\n }\n };\n\n showMenu = () => {\n this.setState(\n {\n isFocused: true,\n optionsShown: true,\n },\n () => {\n addClickClassToDocumentOnIos();\n document.addEventListener('click', this.handleDocumentClick, false);\n },\n );\n };\n\n hideMenu = () => {\n this.setState(\n {\n optionsShown: false,\n keyboardFocusedOptionIndex: null,\n },\n () => {\n removeClickClassFromDocumentOnIos();\n document.removeEventListener('click', this.handleDocumentClick, false);\n },\n );\n };\n\n updateSelectedValue = (selected: readonly TypeaheadOption<T>[]) => {\n const { onChange, validateChip } = this.props;\n\n const errorState = selected.some((chip) => !validateChip(chip));\n this.setState({ selected, errorState }, () => {\n onChange([...selected]);\n });\n };\n\n clear = (event: React.MouseEvent<HTMLButtonElement>) => {\n event.preventDefault();\n if (this.state.selected.length > 0) {\n this.updateSelectedValue([]);\n }\n\n this.setState({\n query: '',\n });\n };\n\n removeChip = (option: TypeaheadOption<T>) => {\n const { selected } = this.state;\n\n if (selected.length > 0) {\n this.updateSelectedValue([...selected.filter((selectedOption) => selectedOption !== option)]);\n }\n };\n\n renderChip = (option: TypeaheadOption<T>, idx: number): ReactNode => {\n const valid = this.props.validateChip?.(option);\n\n return (\n <Chip\n key={idx}\n label={option.label}\n className={clsx('m-t-1', {\n 'has-error': !valid,\n 'np-chip--valid': valid,\n })}\n onRemove={() => this.removeChip(option)}\n />\n );\n };\n\n renderMenu = ({\n footer,\n options,\n id,\n keyboardFocusedOptionIndex,\n query,\n allowNew,\n showNewEntry,\n dropdownOpen,\n }: Pick<\n TypeaheadPropsWithInputAttributes<T>,\n 'footer' | 'options' | 'id' | 'allowNew' | 'showNewEntry'\n > &\n Pick<TypeaheadState<T>, 'keyboardFocusedOptionIndex' | 'query'> & {\n dropdownOpen: boolean;\n }) => {\n const optionsToRender = [...options];\n if (\n allowNew &&\n query.trim() &&\n options.every((option) => option.label.trim().toUpperCase() !== query.trim().toUpperCase()) &&\n showNewEntry\n ) {\n optionsToRender.push({\n label: query,\n });\n }\n return (\n <div\n className={clsx('dropdown btn-group btn-block', { open: dropdownOpen })}\n id={`menu-${id}`}\n >\n {(!!optionsToRender.length || footer) && (\n <ul className=\"dropdown-menu\" role=\"menu\">\n {optionsToRender.map((option, idx) => {\n const ref = React.createRef<HTMLLIElement>();\n this.optionRefs[idx] = ref;\n return (\n <TypeaheadOption\n key={`${option.label}${idx.toString()}`}\n ref={ref}\n query={query}\n option={option}\n selected={keyboardFocusedOptionIndex === idx}\n id={String(option.label.replace(/\\s+/g, '-'))}\n onClick={(event) => {\n this.onOptionSelected(event, option);\n }}\n />\n );\n })}\n {footer}\n </ul>\n )}\n </div>\n );\n };\n\n render() {\n const {\n inputAttributes,\n id: idProp,\n placeholder,\n multiple,\n size,\n addon,\n name,\n clearable,\n allowNew,\n footer,\n showSuggestions,\n showNewEntry,\n options,\n minQueryLength,\n autoFocus,\n maxHeight,\n alert,\n inputAutoComplete,\n } = this.props;\n const id = idProp ?? inputAttributes?.id;\n\n const { errorState, query, selected, optionsShown, keyboardFocusedOptionIndex } = this.state;\n\n const clearButton = clearable && (query || selected.length > 0);\n\n const dropdownOpen = optionsShown && showSuggestions && query.length >= minQueryLength;\n\n const menu = this.renderMenu({\n footer,\n options,\n id,\n keyboardFocusedOptionIndex,\n query,\n allowNew,\n showNewEntry,\n dropdownOpen,\n });\n\n const alertType = alert?.type ?? Sentiment.NEUTRAL;\n const hasError = errorState || (alert && alertType === Sentiment.ERROR);\n const displayAlert = (!errorState && alert) || (alert && alertType === Sentiment.ERROR);\n const hasWarning = displayAlert && alertType === Sentiment.WARNING;\n const hasInfo = displayAlert && alertType === Sentiment.NEUTRAL;\n return (\n /* eslint-disable-next-line jsx-a11y/click-events-have-key-events */\n <div\n role=\"group\"\n {...inputAttributes}\n id={id}\n className={clsx('typeahead', `typeahead-${size}`, {\n 'typeahead--has-value': selected.length > 0,\n 'typeahead--empty': selected.length === 0,\n 'typeahead--multiple': multiple,\n open: dropdownOpen,\n })}\n onClick={stopPropagation}\n >\n <div\n className={clsx('form-group', {\n 'has-error': hasError,\n 'has-warning': hasWarning,\n 'has-info': hasInfo,\n })}\n >\n <div\n className={clsx(`input-group input-group-${size}`, {\n 'input-group--has-error': hasError,\n })}\n >\n {addon && <span className=\"input-group-addon input-group-addon--search\">{addon}</span>}\n\n <TypeaheadInput\n {...{\n autoFocus,\n multiple,\n dropdownOpen,\n placeholder,\n selected,\n maxHeight,\n }}\n id={id}\n name={name}\n value={query}\n typeaheadId={id}\n renderChip={this.renderChip}\n autoComplete={inputAutoComplete}\n ariaActivedescendant={\n keyboardFocusedOptionIndex !== null && options[keyboardFocusedOptionIndex]\n ? `option-${options[keyboardFocusedOptionIndex].label.replace(/\\s+/g, '-')}`\n : undefined\n }\n onChange={this.handleOnChange}\n onKeyDown={this.handleOnKeyDown}\n onFocus={this.handleOnFocus}\n onPaste={this.handleOnPaste}\n />\n\n {clearButton && (\n <div className=\"input-group-addon\">\n <button\n type=\"button\"\n className=\"btn-unstyled\"\n aria-label={this.props?.intl?.formatMessage(messages.clearLabel)}\n onClick={this.clear}\n >\n <CrossIcon />\n </button>\n </div>\n )}\n </div>\n {displayAlert ? <InlineAlert type={alert.type}>{alert.message}</InlineAlert> : menu}\n </div>\n </div>\n );\n }\n}\n\nexport default injectIntl(withInputAttributes(Typeahead, { nonLabelable: true })) as <T>(\n props: TypeaheadProps<T>,\n) => React.ReactElement;\n"],"names":["DEFAULT_MIN_QUERY_LENGTH","SEARCH_DELAY","Typeahead","Component","defaultProps","allowNew","autoFillOnBlur","autoFocus","chipSeparators","clearable","initialValue","inputAutoComplete","minQueryLength","multiple","searchDelay","showSuggestions","showNewEntry","size","Size","MEDIUM","validateChip","optionRefs","constructor","props","handleSearchDebounced","debounce","handleSearch","initialQuery","length","label","state","selected","errorState","query","keyboardFocusedOptionIndex","optionsShown","isFocused","UNSAFE_componentWillReceiveProps","nextProps","setState","previousState","componentWillUnmount","cancel","handleOnFocus","showMenu","onFocus","onOptionSelected","event","item","preventDefault","selectItem","handleOnChange","onInputChange","target","value","updateSelectedValue","handleOnPaste","clipboardData","getData","regex","RegExp","join","pastedChips","split","map","trim","filter","chip","handleOnKeyDown","options","chipsMode","includes","key","moveFocusedOption","slice","offset","index","clamp","optionRef","current","focus","push","keepFocusOnSelect","hideMenu","clearQueryOnSelect","onSearch","handleDocumentClick","onBlur","addClickClassToDocumentOnIos","document","addEventListener","removeClickClassFromDocumentOnIos","removeEventListener","onChange","some","clear","removeChip","option","selectedOption","renderChip","idx","valid","_jsx","Chip","className","clsx","onRemove","renderMenu","footer","id","dropdownOpen","optionsToRender","every","toUpperCase","open","children","_jsxs","role","ref","React","createRef","TypeaheadOption","String","replace","onClick","toString","render","inputAttributes","idProp","placeholder","addon","name","maxHeight","alert","clearButton","menu","alertType","type","Sentiment","NEUTRAL","hasError","ERROR","displayAlert","hasWarning","WARNING","hasInfo","stopPropagation","TypeaheadInput","typeaheadId","autoComplete","ariaActivedescendant","undefined","onKeyDown","onPaste","intl","formatMessage","messages","clearLabel","CrossIcon","InlineAlert","message","injectIntl","withInputAttributes","nonLabelable"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BA,MAAMA,wBAAwB,GAAG,CAAC;AAClC,MAAMC,YAAY,GAAG,GAAG;AA0DxB,MAAMC,SAAa,SAAQC,eAAkE,CAAA;AAI3F,EAAA,OAAOC,YAAY,GAAG,CAAA,OAAA;AACpBC,IAAAA,QAAQ,EAAE,KAAK;AACfC,IAAAA,cAAc,EAAE,IAAI;AACpBC,IAAAA,SAAS,EAAE,KAAK;AAChBC,IAAAA,cAAc,EAAE,EAAE;AAClBC,IAAAA,SAAS,EAAE,IAAI;AACfC,IAAAA,YAAY,EAAE,EAAE;AAChBC,IAA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OAAO,CAAC,MAAM,EAAE,GAAG,CAAC,CAAE,CAAA,GAC1E4B,SACL;YACD1D,QAAQ,EAAE,IAAI,CAAC1C,cAAe;YAC9BqG,SAAS,EAAE,IAAI,CAACpF,eAAgB;YAChCvB,OAAO,EAAE,IAAI,CAACF,aAAc;YAC5B8G,OAAO,EAAE,IAAI,CAACjG;AAAc,WAG9B,CAAA,EAAC8E,WAAW,iBACVhC,cAAA,CAAA,KAAA,EAAA;AAAKE,YAAAA,SAAS,EAAC,mBAAmB;AAAAW,YAAAA,QAAA,eAChCb,cAAA,CAAA,QAAA,EAAA;AACEmC,cAAAA,IAAI,EAAC,QAAQ;AACbjC,cAAAA,SAAS,EAAC,cAAc;cACxB,YAAY,EAAA,IAAI,CAACjF,KAAK,EAAEmI,IAAI,EAAEC,aAAa,CAACC,0BAAQ,CAACC,UAAU,CAAE;cACjEjC,OAAO,EAAE,IAAI,CAAC7B,KAAM;AAAAoB,cAAAA,QAAA,eAEpBb,cAAA,CAACwD,WAAS,EACZ,EAAA;aAAQ;AACV,WAAK,CACN;AAAA,SACE,CACL,EAAChB,YAAY,gBAAGxC,cAAA,CAACyD,mBAAW,EAAA;UAACtB,IAAI,EAAEJ,KAAK,CAACI,IAAK;UAAAtB,QAAA,EAAEkB,KAAK,CAAC2B;SAAqB,CAAC,GAAGzB,IAAI;OAChF;AACP,KAAK,CAAC;AAEV;;AAGF,kBAAe0B,oBAAU,CAACC,4BAAmB,CAAChK,SAAS,EAAE;AAAEiK,EAAAA,YAAY,EAAE;AAAM,CAAA,CAAC,CAEzD;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Typeahead.messages.js","sources":["../../src/typeahead/Typeahead.messages.ts"],"sourcesContent":["import { defineMessages } from 'react-intl';\n\nexport default defineMessages({\n clearLabel: {\n id: 'neptune.ClearButton.ariaLabel',\n defaultMessage: 'Clear',\n description: 'Description of clear button',\n },\n});\n"],"names":["defineMessages","clearLabel","id"],"mappings":";;;;;;AAEA,eAAeA,wBAAc,CAAC;AAC5BC,EAAAA,UAAU,EAAE;IACVC,EAAE,EAAA
|
|
1
|
+
{"version":3,"file":"Typeahead.messages.js","sources":["../../src/typeahead/Typeahead.messages.ts"],"sourcesContent":["import { defineMessages } from 'react-intl';\n\nexport default defineMessages({\n clearLabel: {\n id: 'neptune.ClearButton.ariaLabel',\n defaultMessage: 'Clear',\n description: 'Description of clear button',\n },\n});\n"],"names":["defineMessages","clearLabel","id"],"mappings":";;;;;;AAEA,eAAeA,wBAAc,CAAC;AAC5BC,EAAAA,UAAU,EAAE;IACVC,EAAE,EAAA;AAGH;AACF,CAAA,CAAC;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Typeahead.messages.mjs","sources":["../../src/typeahead/Typeahead.messages.ts"],"sourcesContent":["import { defineMessages } from 'react-intl';\n\nexport default defineMessages({\n clearLabel: {\n id: 'neptune.ClearButton.ariaLabel',\n defaultMessage: 'Clear',\n description: 'Description of clear button',\n },\n});\n"],"names":["defineMessages","clearLabel","id"],"mappings":";;AAEA,eAAeA,cAAc,CAAC;AAC5BC,EAAAA,UAAU,EAAE;IACVC,EAAE,EAAA
|
|
1
|
+
{"version":3,"file":"Typeahead.messages.mjs","sources":["../../src/typeahead/Typeahead.messages.ts"],"sourcesContent":["import { defineMessages } from 'react-intl';\n\nexport default defineMessages({\n clearLabel: {\n id: 'neptune.ClearButton.ariaLabel',\n defaultMessage: 'Clear',\n description: 'Description of clear button',\n },\n});\n"],"names":["defineMessages","clearLabel","id"],"mappings":";;AAEA,eAAeA,cAAc,CAAC;AAC5BC,EAAAA,UAAU,EAAE;IACVC,EAAE,EAAA;AAGH;AACF,CAAA,CAAC;;;;"}
|