@progressiveui/react 1.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.storybook/Logo.js +62 -0
- package/.storybook/WfpTheme.js +38 -0
- package/.storybook/main.ts +42 -0
- package/.storybook/manager.js +9 -0
- package/.storybook/preview.tsx +72 -0
- package/.storybook/reactHookFormDecorator.module.scss +5 -0
- package/.storybook/reactHookFormDecorator.tsx +59 -0
- package/.storybook/storybook.scss +60 -0
- package/.storybook/theme.js +14 -0
- package/LICENSE +201 -0
- package/README.md +15 -0
- package/config/jest/cssTransform.js +13 -0
- package/config/jest/fileTransform.js +11 -0
- package/config/jest/jsTransform.js +8 -0
- package/config/jest/setup.js +16 -0
- package/config/polyfills.js +22 -0
- package/es/dist/components/Accordion/__tests__/utils.d.ts +12 -0
- package/es/dist/components/Accordion/components/Accordion.d.ts +7 -0
- package/es/dist/components/Accordion/components/AccordionItem.d.ts +46 -0
- package/es/dist/components/Accordion/components/AccordionProvider.d.ts +7 -0
- package/es/dist/components/Accordion/components/ControlledAccordion.d.ts +8 -0
- package/es/dist/components/Accordion/components/withAccordionItem.d.ts +11 -0
- package/es/dist/components/Accordion/hooks/useAccordion.d.ts +5 -0
- package/es/dist/components/Accordion/hooks/useAccordionContext.d.ts +5 -0
- package/es/dist/components/Accordion/hooks/useAccordionItem.d.ts +7 -0
- package/es/dist/components/Accordion/hooks/useAccordionItemEffect.d.ts +13 -0
- package/es/dist/components/Accordion/hooks/useAccordionProvider.d.ts +3 -0
- package/es/dist/components/Accordion/hooks/useAccordionState.d.ts +14 -0
- package/es/dist/components/Accordion/hooks/useHeightTransition.d.ts +4 -0
- package/es/dist/components/Accordion/hooks/useId.d.ts +3 -0
- package/es/dist/components/Accordion/hooks/useMergeRef.d.ts +4 -0
- package/es/dist/components/Accordion/index.d.ts +17 -0
- package/es/dist/components/Accordion/utils/bem.d.ts +7 -0
- package/es/dist/components/Accordion/utils/constants.d.ts +58 -0
- package/es/dist/components/Accordion/utils/mergeProps.d.ts +2 -0
- package/es/dist/components/Accordion/utils/useIsomorphicLayoutEffect.d.ts +3 -0
- package/es/dist/components/AnchorNavigation/AnchorNavigation.d.ts +6 -0
- package/es/dist/components/AnchorNavigation/index.d.ts +1 -0
- package/es/dist/components/AuthLayout/AuthLayout.d.ts +20 -0
- package/es/dist/components/AuthLayout/index.d.ts +1 -0
- package/es/dist/components/Avatar/Avatar.d.ts +33 -0
- package/es/dist/components/Avatar/index.d.ts +1 -0
- package/es/dist/components/BannerNavigation/BannerNavigation.d.ts +20 -0
- package/es/dist/components/BannerNavigation/BannerNavigationWithContent.d.ts +13 -0
- package/es/dist/components/BannerNavigation/index.d.ts +2 -0
- package/es/dist/components/Breadcrumb/Breadcrumb.d.ts +11 -0
- package/es/dist/components/Breadcrumb/index.d.ts +1 -0
- package/es/dist/components/BreadcrumbHome/BreadcrumbHome.d.ts +13 -0
- package/es/dist/components/BreadcrumbHome/index.d.ts +1 -0
- package/es/dist/components/BreadcrumbItem/BreadcrumbItem.d.ts +21 -0
- package/es/dist/components/BreadcrumbItem/index.d.ts +1 -0
- package/es/dist/components/Button/Button.Skeleton.d.ts +7 -0
- package/es/dist/components/Button/Button.d.ts +55 -0
- package/es/dist/components/Button/index.d.ts +1 -0
- package/es/dist/components/Card/Card.d.ts +61 -0
- package/es/dist/components/Card/CardExternal.d.ts +37 -0
- package/es/dist/components/Card/index.d.ts +2 -0
- package/es/dist/components/Checkbox/Checkbox.d.ts +37 -0
- package/es/dist/components/Checkbox/index.d.ts +1 -0
- package/es/dist/components/ContentSwitcher/ContentSwitcher.d.ts +12 -0
- package/es/dist/components/ContentSwitcher/index.d.ts +1 -0
- package/es/dist/components/ContextMenu/ContextMenu.d.ts +31 -0
- package/es/dist/components/ContextMenu/index.d.ts +1 -0
- package/es/dist/components/Credits/Credits.d.ts +10 -0
- package/es/dist/components/Credits/index.d.ts +1 -0
- package/es/dist/components/DatePicker/DatePicker.d.ts +8 -0
- package/es/dist/components/DatePicker/DatePickerInput.d.ts +38 -0
- package/es/dist/components/DatePicker/DateRangePicker.d.ts +8 -0
- package/es/dist/components/DatePicker/DateRangePickerInput.d.ts +34 -0
- package/es/dist/components/DatePicker/index.d.ts +4 -0
- package/es/dist/components/DatePickerNew/DateRangePickerInput.d.ts +11 -0
- package/es/dist/components/Empty/Empty.d.ts +40 -0
- package/es/dist/components/Empty/index.d.ts +1 -0
- package/es/dist/components/Footer/Footer.d.ts +47 -0
- package/es/dist/components/Footer/FooterExternal.d.ts +22 -0
- package/es/dist/components/Footer/index.d.ts +2 -0
- package/es/dist/components/Form/Form.d.ts +15 -0
- package/es/dist/components/Form/index.d.ts +1 -0
- package/es/dist/components/FormGroup/FormGroup.d.ts +14 -0
- package/es/dist/components/FormGroup/index.d.ts +1 -0
- package/es/dist/components/FormHint/FormHint.d.ts +15 -0
- package/es/dist/components/FormHint/index.d.ts +1 -0
- package/es/dist/components/FormItem/FormItem.d.ts +17 -0
- package/es/dist/components/FormItem/index.d.ts +1 -0
- package/es/dist/components/FormLabel/FormLabel.d.ts +15 -0
- package/es/dist/components/FormLabel/index.d.ts +1 -0
- package/es/dist/components/Hero/Hero.d.ts +53 -0
- package/es/dist/components/Hero/HeroExternal.d.ts +22 -0
- package/es/dist/components/Hero/index.d.ts +2 -0
- package/es/dist/components/InfoBar/InfoBar.d.ts +23 -0
- package/es/dist/components/InfoBar/index.d.ts +1 -0
- package/es/dist/components/InlineLoading/InlineLoading.d.ts +26 -0
- package/es/dist/components/InlineLoading/index.d.ts +1 -0
- package/es/dist/components/Input/Input.d.ts +152 -0
- package/es/dist/components/Input/index.d.ts +3 -0
- package/es/dist/components/Input/useInput.d.ts +123 -0
- package/es/dist/components/InputGroup/InputGroup.d.ts +48 -0
- package/es/dist/components/InputGroup/index.d.ts +1 -0
- package/es/dist/components/Item/Item.d.ts +59 -0
- package/es/dist/components/Item/index.d.ts +1 -0
- package/es/dist/components/Link/Link.d.ts +37 -0
- package/es/dist/components/Link/index.d.ts +1 -0
- package/es/dist/components/List/List.d.ts +32 -0
- package/es/dist/components/List/ListItem.d.ts +25 -0
- package/es/dist/components/List/index.d.ts +2 -0
- package/es/dist/components/Loading/Loading.d.ts +16 -0
- package/es/dist/components/Loading/index.d.ts +7 -0
- package/es/dist/components/MainNavigation/MainNavigation.d.ts +51 -0
- package/es/dist/components/MainNavigation/MainNavigationContext.d.ts +25 -0
- package/es/dist/components/MainNavigation/MainNavigationExternal.d.ts +72 -0
- package/es/dist/components/MainNavigation/MobileButton.d.ts +17 -0
- package/es/dist/components/MainNavigation/index.d.ts +4 -0
- package/es/dist/components/MainNavigation/useMainNavigation.d.ts +7 -0
- package/es/dist/components/MainNavigationItem/MainNavigationItem.d.ts +29 -0
- package/es/dist/components/MainNavigationItem/index.d.ts +1 -0
- package/es/dist/components/MdxComponents/MdxComponentsNew.d.ts +2 -0
- package/es/dist/components/MdxComponents/index.d.ts +1 -0
- package/es/dist/components/Modal/Modal.d.ts +122 -0
- package/es/dist/components/Modal/ModalFooter.d.ts +8 -0
- package/es/dist/components/Modal/index.d.ts +2 -0
- package/es/dist/components/ModalWrapper/ModalWrapper.d.ts +53 -0
- package/es/dist/components/ModalWrapper/index.d.ts +1 -0
- package/es/dist/components/Module/Module.d.ts +38 -0
- package/es/dist/components/Module/ModuleBody.d.ts +21 -0
- package/es/dist/components/Module/ModuleFooter.d.ts +10 -0
- package/es/dist/components/Module/ModuleHeader.d.ts +16 -0
- package/es/dist/components/Module/index.d.ts +4 -0
- package/es/dist/components/Notification/Callout.d.ts +59 -0
- package/es/dist/components/Notification/NotificationActionButton.d.ts +18 -0
- package/es/dist/components/Notification/NotificationButton.d.ts +36 -0
- package/es/dist/components/Notification/NotificationIcon.d.ts +8 -0
- package/es/dist/components/Notification/NotificationTextDetails.d.ts +10 -0
- package/es/dist/components/Notification/ToastNotification.d.ts +10 -0
- package/es/dist/components/Notification/index.d.ts +5 -0
- package/es/dist/components/NumberInput/NumberInput.Skeleton.d.ts +10 -0
- package/es/dist/components/NumberInput/NumberInput.d.ts +64 -0
- package/es/dist/components/NumberInput/index.d.ts +2 -0
- package/es/dist/components/Pagination/Pagination.d.ts +92 -0
- package/es/dist/components/Pagination/index.d.ts +1 -0
- package/es/dist/components/RadioButton/RadioButton.d.ts +27 -0
- package/es/dist/components/RadioButton/index.d.ts +2 -0
- package/es/dist/components/ReadMore/ReadMore.d.ts +45 -0
- package/es/dist/components/ReadMore/index.d.ts +1 -0
- package/es/dist/components/Search/Search.d.ts +50 -0
- package/es/dist/components/Search/index.d.ts +1 -0
- package/es/dist/components/SecondaryNavigation/SecondaryNavigation.d.ts +19 -0
- package/es/dist/components/SecondaryNavigation/SecondaryNavigationTitle.d.ts +8 -0
- package/es/dist/components/SecondaryNavigation/index.d.ts +2 -0
- package/es/dist/components/Select/Select.d.ts +24 -0
- package/es/dist/components/Select/index.d.ts +1 -0
- package/es/dist/components/SelectItem/SelectItem.d.ts +28 -0
- package/es/dist/components/SelectItem/index.d.ts +1 -0
- package/es/dist/components/SelectItemGroup/SelectItemGroup.d.ts +21 -0
- package/es/dist/components/SelectItemGroup/index.d.ts +1 -0
- package/es/dist/components/Sidebar/Sidebar.d.ts +46 -0
- package/es/dist/components/Sidebar/index.d.ts +1 -0
- package/es/dist/components/SkeletonText/SkeletonText.d.ts +22 -0
- package/es/dist/components/SkeletonText/index.d.ts +1 -0
- package/es/dist/components/Slider/Slider.d.ts +71 -0
- package/es/dist/components/Slider/index.d.ts +1 -0
- package/es/dist/components/StepNavigation/StepNavigation.Skeleton.d.ts +2 -0
- package/es/dist/components/StepNavigation/StepNavigation.d.ts +42 -0
- package/es/dist/components/StepNavigation/index.d.ts +2 -0
- package/es/dist/components/StepNavigationItem/StepNavigationItem.d.ts +55 -0
- package/es/dist/components/StepNavigationItem/index.d.ts +1 -0
- package/es/dist/components/Story/Story.d.ts +7 -0
- package/es/dist/components/Story/index.d.ts +1 -0
- package/es/dist/components/SubNavigation/SubNavigation.d.ts +5 -0
- package/es/dist/components/SubNavigation/SubNavigationContent.d.ts +9 -0
- package/es/dist/components/SubNavigation/SubNavigationFilter.d.ts +9 -0
- package/es/dist/components/SubNavigation/SubNavigationGroup.d.ts +17 -0
- package/es/dist/components/SubNavigation/SubNavigationHeader.d.ts +9 -0
- package/es/dist/components/SubNavigation/SubNavigationItem.d.ts +9 -0
- package/es/dist/components/SubNavigation/SubNavigationLink.d.ts +9 -0
- package/es/dist/components/SubNavigation/SubNavigationList.d.ts +9 -0
- package/es/dist/components/SubNavigation/SubNavigationTitle.d.ts +9 -0
- package/es/dist/components/SubNavigation/index.d.ts +9 -0
- package/es/dist/components/Tab/Tab.d.ts +83 -0
- package/es/dist/components/Tab/index.d.ts +2 -0
- package/es/dist/components/Tab/useTab.d.ts +12 -0
- package/es/dist/components/TabContent/TabContent.d.ts +13 -0
- package/es/dist/components/TabContent/index.d.ts +1 -0
- package/es/dist/components/Table/Table.d.ts +8 -0
- package/es/dist/components/Table/TableSorting.d.ts +11 -0
- package/es/dist/components/Table/index.d.ts +2 -0
- package/es/dist/components/TablePagination/TablePagination.d.ts +33 -0
- package/es/dist/components/TablePagination/index.d.ts +1 -0
- package/es/dist/components/Tabs/Tabs.d.ts +67 -0
- package/es/dist/components/Tabs/TabsContext.d.ts +8 -0
- package/es/dist/components/Tabs/index.d.ts +1 -0
- package/es/dist/components/Tag/Tag.d.ts +14 -0
- package/es/dist/components/Tag/index.d.ts +2 -0
- package/es/dist/components/Text/Text.d.ts +30 -0
- package/es/dist/components/Text/index.d.ts +1 -0
- package/es/dist/components/TextArea/TextArea.d.ts +8 -0
- package/es/dist/components/TextArea/index.d.ts +1 -0
- package/es/dist/components/TextInput/TextInput.d.ts +7 -0
- package/es/dist/components/TextInput/index.d.ts +1 -0
- package/es/dist/components/Toggle/Toggle.d.ts +38 -0
- package/es/dist/components/Toggle/index.d.ts +1 -0
- package/es/dist/components/Tooltip/Tooltip.d.ts +103 -0
- package/es/dist/components/Tooltip/index.d.ts +2 -0
- package/es/dist/components/Unit/InvalidUnit.d.ts +2 -0
- package/es/dist/components/Unit/SimpleCalc.d.ts +17 -0
- package/es/dist/components/Unit/StringUnit.d.ts +2 -0
- package/es/dist/components/Unit/SvgUnit.d.ts +2 -0
- package/es/dist/components/Unit/Unit.d.ts +54 -0
- package/es/dist/components/Unit/UnitList.d.ts +96 -0
- package/es/dist/components/Unit/YearMonthCalc.d.ts +7 -0
- package/es/dist/components/Unit/currencyCalc.d.ts +21 -0
- package/es/dist/components/Unit/index.d.ts +1 -0
- package/es/dist/components/Unit/percentageCalc.d.ts +18 -0
- package/es/dist/components/Unit/scaleLookup.d.ts +24 -0
- package/es/dist/components/User/User.d.ts +55 -0
- package/es/dist/components/User/index.d.ts +1 -0
- package/es/dist/components/Value/Value.d.ts +11 -0
- package/es/dist/components/Value/index.d.ts +1 -0
- package/es/dist/components/WFPCoreSettings/WFPCoreProvider.d.ts +21 -0
- package/es/dist/components/WFPCoreSettings/defaults.d.ts +2 -0
- package/es/dist/components/WFPCoreSettings/index.d.ts +4 -0
- package/es/dist/components/WFPCoreSettings/useTheme.d.ts +2 -0
- package/es/dist/components/WFPCoreSettings/withWFPCoreSettings.d.ts +2 -0
- package/es/dist/components/Wrapper/Wrapper.d.ts +22 -0
- package/es/dist/components/Wrapper/index.d.ts +2 -0
- package/es/dist/globals/data/colors.d.ts +609 -0
- package/es/dist/globals/js/settings.d.ts +34 -0
- package/es/dist/hooks/index.d.ts +1 -0
- package/es/dist/hooks/togglable.d.ts +5 -0
- package/es/dist/hooks/useHeightTransition.d.ts +4 -0
- package/es/dist/hooks/useId.d.ts +3 -0
- package/es/dist/hooks/useIsomorphicLayoutEffect.d.ts +12 -0
- package/es/dist/hooks/useMediaQuery.d.ts +19 -0
- package/es/dist/hooks/useMergeRef.d.ts +4 -0
- package/es/dist/hooks/useSettings.d.ts +2 -0
- package/es/dist/index.d.ts +75 -0
- package/es/dist/internal/FeatureFlags.d.ts +19 -0
- package/es/dist/prop-types/types.d.ts +5 -0
- package/es/dist/tools/uniqueId.d.ts +2 -0
- package/es/index.js +5470 -0
- package/lib/dist/components/Accordion/__tests__/utils.d.ts +12 -0
- package/lib/dist/components/Accordion/components/Accordion.d.ts +7 -0
- package/lib/dist/components/Accordion/components/AccordionItem.d.ts +46 -0
- package/lib/dist/components/Accordion/components/AccordionProvider.d.ts +7 -0
- package/lib/dist/components/Accordion/components/ControlledAccordion.d.ts +8 -0
- package/lib/dist/components/Accordion/components/withAccordionItem.d.ts +11 -0
- package/lib/dist/components/Accordion/hooks/useAccordion.d.ts +5 -0
- package/lib/dist/components/Accordion/hooks/useAccordionContext.d.ts +5 -0
- package/lib/dist/components/Accordion/hooks/useAccordionItem.d.ts +7 -0
- package/lib/dist/components/Accordion/hooks/useAccordionItemEffect.d.ts +13 -0
- package/lib/dist/components/Accordion/hooks/useAccordionProvider.d.ts +3 -0
- package/lib/dist/components/Accordion/hooks/useAccordionState.d.ts +14 -0
- package/lib/dist/components/Accordion/hooks/useHeightTransition.d.ts +4 -0
- package/lib/dist/components/Accordion/hooks/useId.d.ts +3 -0
- package/lib/dist/components/Accordion/hooks/useMergeRef.d.ts +4 -0
- package/lib/dist/components/Accordion/index.d.ts +17 -0
- package/lib/dist/components/Accordion/utils/bem.d.ts +7 -0
- package/lib/dist/components/Accordion/utils/constants.d.ts +58 -0
- package/lib/dist/components/Accordion/utils/mergeProps.d.ts +2 -0
- package/lib/dist/components/Accordion/utils/useIsomorphicLayoutEffect.d.ts +3 -0
- package/lib/dist/components/AnchorNavigation/AnchorNavigation.d.ts +6 -0
- package/lib/dist/components/AnchorNavigation/index.d.ts +1 -0
- package/lib/dist/components/AuthLayout/AuthLayout.d.ts +20 -0
- package/lib/dist/components/AuthLayout/index.d.ts +1 -0
- package/lib/dist/components/Avatar/Avatar.d.ts +33 -0
- package/lib/dist/components/Avatar/index.d.ts +1 -0
- package/lib/dist/components/BannerNavigation/BannerNavigation.d.ts +20 -0
- package/lib/dist/components/BannerNavigation/BannerNavigationWithContent.d.ts +13 -0
- package/lib/dist/components/BannerNavigation/index.d.ts +2 -0
- package/lib/dist/components/Breadcrumb/Breadcrumb.d.ts +11 -0
- package/lib/dist/components/Breadcrumb/index.d.ts +1 -0
- package/lib/dist/components/BreadcrumbHome/BreadcrumbHome.d.ts +13 -0
- package/lib/dist/components/BreadcrumbHome/index.d.ts +1 -0
- package/lib/dist/components/BreadcrumbItem/BreadcrumbItem.d.ts +21 -0
- package/lib/dist/components/BreadcrumbItem/index.d.ts +1 -0
- package/lib/dist/components/Button/Button.Skeleton.d.ts +7 -0
- package/lib/dist/components/Button/Button.d.ts +55 -0
- package/lib/dist/components/Button/index.d.ts +1 -0
- package/lib/dist/components/Card/Card.d.ts +61 -0
- package/lib/dist/components/Card/CardExternal.d.ts +37 -0
- package/lib/dist/components/Card/index.d.ts +2 -0
- package/lib/dist/components/Checkbox/Checkbox.d.ts +37 -0
- package/lib/dist/components/Checkbox/index.d.ts +1 -0
- package/lib/dist/components/ContentSwitcher/ContentSwitcher.d.ts +12 -0
- package/lib/dist/components/ContentSwitcher/index.d.ts +1 -0
- package/lib/dist/components/ContextMenu/ContextMenu.d.ts +31 -0
- package/lib/dist/components/ContextMenu/index.d.ts +1 -0
- package/lib/dist/components/Credits/Credits.d.ts +10 -0
- package/lib/dist/components/Credits/index.d.ts +1 -0
- package/lib/dist/components/DatePicker/DatePicker.d.ts +8 -0
- package/lib/dist/components/DatePicker/DatePickerInput.d.ts +38 -0
- package/lib/dist/components/DatePicker/DateRangePicker.d.ts +8 -0
- package/lib/dist/components/DatePicker/DateRangePickerInput.d.ts +34 -0
- package/lib/dist/components/DatePicker/index.d.ts +4 -0
- package/lib/dist/components/DatePickerNew/DateRangePickerInput.d.ts +11 -0
- package/lib/dist/components/Empty/Empty.d.ts +40 -0
- package/lib/dist/components/Empty/index.d.ts +1 -0
- package/lib/dist/components/Footer/Footer.d.ts +47 -0
- package/lib/dist/components/Footer/FooterExternal.d.ts +22 -0
- package/lib/dist/components/Footer/index.d.ts +2 -0
- package/lib/dist/components/Form/Form.d.ts +15 -0
- package/lib/dist/components/Form/index.d.ts +1 -0
- package/lib/dist/components/FormGroup/FormGroup.d.ts +14 -0
- package/lib/dist/components/FormGroup/index.d.ts +1 -0
- package/lib/dist/components/FormHint/FormHint.d.ts +15 -0
- package/lib/dist/components/FormHint/index.d.ts +1 -0
- package/lib/dist/components/FormItem/FormItem.d.ts +17 -0
- package/lib/dist/components/FormItem/index.d.ts +1 -0
- package/lib/dist/components/FormLabel/FormLabel.d.ts +15 -0
- package/lib/dist/components/FormLabel/index.d.ts +1 -0
- package/lib/dist/components/Hero/Hero.d.ts +53 -0
- package/lib/dist/components/Hero/HeroExternal.d.ts +22 -0
- package/lib/dist/components/Hero/index.d.ts +2 -0
- package/lib/dist/components/InfoBar/InfoBar.d.ts +23 -0
- package/lib/dist/components/InfoBar/index.d.ts +1 -0
- package/lib/dist/components/InlineLoading/InlineLoading.d.ts +26 -0
- package/lib/dist/components/InlineLoading/index.d.ts +1 -0
- package/lib/dist/components/Input/Input.d.ts +152 -0
- package/lib/dist/components/Input/index.d.ts +3 -0
- package/lib/dist/components/Input/useInput.d.ts +123 -0
- package/lib/dist/components/InputGroup/InputGroup.d.ts +48 -0
- package/lib/dist/components/InputGroup/index.d.ts +1 -0
- package/lib/dist/components/Item/Item.d.ts +59 -0
- package/lib/dist/components/Item/index.d.ts +1 -0
- package/lib/dist/components/Link/Link.d.ts +37 -0
- package/lib/dist/components/Link/index.d.ts +1 -0
- package/lib/dist/components/List/List.d.ts +32 -0
- package/lib/dist/components/List/ListItem.d.ts +25 -0
- package/lib/dist/components/List/index.d.ts +2 -0
- package/lib/dist/components/Loading/Loading.d.ts +16 -0
- package/lib/dist/components/Loading/index.d.ts +7 -0
- package/lib/dist/components/MainNavigation/MainNavigation.d.ts +51 -0
- package/lib/dist/components/MainNavigation/MainNavigationContext.d.ts +25 -0
- package/lib/dist/components/MainNavigation/MainNavigationExternal.d.ts +72 -0
- package/lib/dist/components/MainNavigation/MobileButton.d.ts +17 -0
- package/lib/dist/components/MainNavigation/index.d.ts +4 -0
- package/lib/dist/components/MainNavigation/useMainNavigation.d.ts +7 -0
- package/lib/dist/components/MainNavigationItem/MainNavigationItem.d.ts +29 -0
- package/lib/dist/components/MainNavigationItem/index.d.ts +1 -0
- package/lib/dist/components/MdxComponents/MdxComponentsNew.d.ts +2 -0
- package/lib/dist/components/MdxComponents/index.d.ts +1 -0
- package/lib/dist/components/Modal/Modal.d.ts +122 -0
- package/lib/dist/components/Modal/ModalFooter.d.ts +8 -0
- package/lib/dist/components/Modal/index.d.ts +2 -0
- package/lib/dist/components/ModalWrapper/ModalWrapper.d.ts +53 -0
- package/lib/dist/components/ModalWrapper/index.d.ts +1 -0
- package/lib/dist/components/Module/Module.d.ts +38 -0
- package/lib/dist/components/Module/ModuleBody.d.ts +21 -0
- package/lib/dist/components/Module/ModuleFooter.d.ts +10 -0
- package/lib/dist/components/Module/ModuleHeader.d.ts +16 -0
- package/lib/dist/components/Module/index.d.ts +4 -0
- package/lib/dist/components/Notification/Callout.d.ts +59 -0
- package/lib/dist/components/Notification/NotificationActionButton.d.ts +18 -0
- package/lib/dist/components/Notification/NotificationButton.d.ts +36 -0
- package/lib/dist/components/Notification/NotificationIcon.d.ts +8 -0
- package/lib/dist/components/Notification/NotificationTextDetails.d.ts +10 -0
- package/lib/dist/components/Notification/ToastNotification.d.ts +10 -0
- package/lib/dist/components/Notification/index.d.ts +5 -0
- package/lib/dist/components/NumberInput/NumberInput.Skeleton.d.ts +10 -0
- package/lib/dist/components/NumberInput/NumberInput.d.ts +64 -0
- package/lib/dist/components/NumberInput/index.d.ts +2 -0
- package/lib/dist/components/Pagination/Pagination.d.ts +92 -0
- package/lib/dist/components/Pagination/index.d.ts +1 -0
- package/lib/dist/components/RadioButton/RadioButton.d.ts +27 -0
- package/lib/dist/components/RadioButton/index.d.ts +2 -0
- package/lib/dist/components/ReadMore/ReadMore.d.ts +45 -0
- package/lib/dist/components/ReadMore/index.d.ts +1 -0
- package/lib/dist/components/Search/Search.d.ts +50 -0
- package/lib/dist/components/Search/index.d.ts +1 -0
- package/lib/dist/components/SecondaryNavigation/SecondaryNavigation.d.ts +19 -0
- package/lib/dist/components/SecondaryNavigation/SecondaryNavigationTitle.d.ts +8 -0
- package/lib/dist/components/SecondaryNavigation/index.d.ts +2 -0
- package/lib/dist/components/Select/Select.d.ts +24 -0
- package/lib/dist/components/Select/index.d.ts +1 -0
- package/lib/dist/components/SelectItem/SelectItem.d.ts +28 -0
- package/lib/dist/components/SelectItem/index.d.ts +1 -0
- package/lib/dist/components/SelectItemGroup/SelectItemGroup.d.ts +21 -0
- package/lib/dist/components/SelectItemGroup/index.d.ts +1 -0
- package/lib/dist/components/Sidebar/Sidebar.d.ts +46 -0
- package/lib/dist/components/Sidebar/index.d.ts +1 -0
- package/lib/dist/components/SkeletonText/SkeletonText.d.ts +22 -0
- package/lib/dist/components/SkeletonText/index.d.ts +1 -0
- package/lib/dist/components/Slider/Slider.d.ts +71 -0
- package/lib/dist/components/Slider/index.d.ts +1 -0
- package/lib/dist/components/StepNavigation/StepNavigation.Skeleton.d.ts +2 -0
- package/lib/dist/components/StepNavigation/StepNavigation.d.ts +42 -0
- package/lib/dist/components/StepNavigation/index.d.ts +2 -0
- package/lib/dist/components/StepNavigationItem/StepNavigationItem.d.ts +55 -0
- package/lib/dist/components/StepNavigationItem/index.d.ts +1 -0
- package/lib/dist/components/Story/Story.d.ts +7 -0
- package/lib/dist/components/Story/index.d.ts +1 -0
- package/lib/dist/components/SubNavigation/SubNavigation.d.ts +5 -0
- package/lib/dist/components/SubNavigation/SubNavigationContent.d.ts +9 -0
- package/lib/dist/components/SubNavigation/SubNavigationFilter.d.ts +9 -0
- package/lib/dist/components/SubNavigation/SubNavigationGroup.d.ts +17 -0
- package/lib/dist/components/SubNavigation/SubNavigationHeader.d.ts +9 -0
- package/lib/dist/components/SubNavigation/SubNavigationItem.d.ts +9 -0
- package/lib/dist/components/SubNavigation/SubNavigationLink.d.ts +9 -0
- package/lib/dist/components/SubNavigation/SubNavigationList.d.ts +9 -0
- package/lib/dist/components/SubNavigation/SubNavigationTitle.d.ts +9 -0
- package/lib/dist/components/SubNavigation/index.d.ts +9 -0
- package/lib/dist/components/Tab/Tab.d.ts +83 -0
- package/lib/dist/components/Tab/index.d.ts +2 -0
- package/lib/dist/components/Tab/useTab.d.ts +12 -0
- package/lib/dist/components/TabContent/TabContent.d.ts +13 -0
- package/lib/dist/components/TabContent/index.d.ts +1 -0
- package/lib/dist/components/Table/Table.d.ts +8 -0
- package/lib/dist/components/Table/TableSorting.d.ts +11 -0
- package/lib/dist/components/Table/index.d.ts +2 -0
- package/lib/dist/components/TablePagination/TablePagination.d.ts +33 -0
- package/lib/dist/components/TablePagination/index.d.ts +1 -0
- package/lib/dist/components/Tabs/Tabs.d.ts +67 -0
- package/lib/dist/components/Tabs/TabsContext.d.ts +8 -0
- package/lib/dist/components/Tabs/index.d.ts +1 -0
- package/lib/dist/components/Tag/Tag.d.ts +14 -0
- package/lib/dist/components/Tag/index.d.ts +2 -0
- package/lib/dist/components/Text/Text.d.ts +30 -0
- package/lib/dist/components/Text/index.d.ts +1 -0
- package/lib/dist/components/TextArea/TextArea.d.ts +8 -0
- package/lib/dist/components/TextArea/index.d.ts +1 -0
- package/lib/dist/components/TextInput/TextInput.d.ts +7 -0
- package/lib/dist/components/TextInput/index.d.ts +1 -0
- package/lib/dist/components/Toggle/Toggle.d.ts +38 -0
- package/lib/dist/components/Toggle/index.d.ts +1 -0
- package/lib/dist/components/Tooltip/Tooltip.d.ts +103 -0
- package/lib/dist/components/Tooltip/index.d.ts +2 -0
- package/lib/dist/components/UNCoreSettings/UNCoreProvider.d.ts +21 -0
- package/lib/dist/components/UNCoreSettings/defaults.d.ts +2 -0
- package/lib/dist/components/UNCoreSettings/index.d.ts +4 -0
- package/lib/dist/components/UNCoreSettings/useTheme.d.ts +2 -0
- package/lib/dist/components/UNCoreSettings/withUNCoreSettings.d.ts +2 -0
- package/lib/dist/components/Unit/InvalidUnit.d.ts +2 -0
- package/lib/dist/components/Unit/SimpleCalc.d.ts +17 -0
- package/lib/dist/components/Unit/StringUnit.d.ts +2 -0
- package/lib/dist/components/Unit/SvgUnit.d.ts +2 -0
- package/lib/dist/components/Unit/Unit.d.ts +54 -0
- package/lib/dist/components/Unit/UnitList.d.ts +96 -0
- package/lib/dist/components/Unit/YearMonthCalc.d.ts +7 -0
- package/lib/dist/components/Unit/currencyCalc.d.ts +21 -0
- package/lib/dist/components/Unit/index.d.ts +1 -0
- package/lib/dist/components/Unit/percentageCalc.d.ts +18 -0
- package/lib/dist/components/Unit/scaleLookup.d.ts +24 -0
- package/lib/dist/components/User/User.d.ts +55 -0
- package/lib/dist/components/User/index.d.ts +1 -0
- package/lib/dist/components/Value/Value.d.ts +11 -0
- package/lib/dist/components/Value/index.d.ts +1 -0
- package/lib/dist/components/WFPCoreSettings/WFPCoreProvider.d.ts +21 -0
- package/lib/dist/components/WFPCoreSettings/defaults.d.ts +2 -0
- package/lib/dist/components/WFPCoreSettings/index.d.ts +4 -0
- package/lib/dist/components/WFPCoreSettings/useTheme.d.ts +2 -0
- package/lib/dist/components/WFPCoreSettings/withWFPCoreSettings.d.ts +2 -0
- package/lib/dist/components/Wrapper/Wrapper.d.ts +22 -0
- package/lib/dist/components/Wrapper/index.d.ts +2 -0
- package/lib/dist/globals/data/colors.d.ts +609 -0
- package/lib/dist/globals/js/settings.d.ts +34 -0
- package/lib/dist/hooks/index.d.ts +1 -0
- package/lib/dist/hooks/togglable.d.ts +5 -0
- package/lib/dist/hooks/useHeightTransition.d.ts +4 -0
- package/lib/dist/hooks/useId.d.ts +3 -0
- package/lib/dist/hooks/useIsomorphicLayoutEffect.d.ts +12 -0
- package/lib/dist/hooks/useMediaQuery.d.ts +19 -0
- package/lib/dist/hooks/useMergeRef.d.ts +4 -0
- package/lib/dist/hooks/useSettings.d.ts +2 -0
- package/lib/dist/index.d.ts +75 -0
- package/lib/dist/indexStories.d.ts +1 -0
- package/lib/dist/internal/FeatureFlags.d.ts +19 -0
- package/lib/dist/prop-types/types.d.ts +5 -0
- package/lib/dist/tools/uniqueId.d.ts +2 -0
- package/lib/index.js +5670 -0
- package/package.json +170 -0
- package/src/assets/internal/background-contrast.png +0 -0
- package/src/assets/internal/brand-color.png +0 -0
- package/src/assets/internal/branding.svg +31 -0
- package/src/assets/internal/colors.png +0 -0
- package/src/assets/internal/hero-image.jpg +0 -0
- package/src/assets/internal/mobile-android-general.png +0 -0
- package/src/assets/internal/secondary-color.png +0 -0
- package/src/assets/internal/toolkit.svg +17 -0
- package/src/assets/internal/usability.svg +12 -0
- package/src/assets/internal/wfp-favicon-png32.png +0 -0
- package/src/assets/internal/wfp-favicon-png512.png +0 -0
- package/src/assets/internal/wfp-favicon-preview-png32.png +0 -0
- package/src/assets/internal/wfp-favicon-preview-png512.png +0 -0
- package/src/assets/internal/yemen-hero-min.jpg +0 -0
- package/src/components/Accordion/Accordion.stories.tsx +41 -0
- package/src/components/Accordion/README.mdx +0 -0
- package/src/components/Accordion/__tests__/components/Accordion.test.tsx.new +122 -0
- package/src/components/Accordion/__tests__/components/AccordionItem.test.tsx.new +353 -0
- package/src/components/Accordion/__tests__/components/AccordionMock.test.tsx.new +18 -0
- package/src/components/Accordion/__tests__/components/ControlledAccordion.test.tsx.new +38 -0
- package/src/components/Accordion/__tests__/hooks/useAccordionProvider.test.ts +56 -0
- package/src/components/Accordion/__tests__/hooks/useAccordionState.test.tsx.new +54 -0
- package/src/components/Accordion/__tests__/hooks/useId.test.ts +19 -0
- package/src/components/Accordion/__tests__/ssr.test.ts +32 -0
- package/src/components/Accordion/__tests__/utils.tsx +48 -0
- package/src/components/Accordion/components/Accordion.tsx +44 -0
- package/src/components/Accordion/components/AccordionItem.tsx +181 -0
- package/src/components/Accordion/components/AccordionProvider.tsx +9 -0
- package/src/components/Accordion/components/ControlledAccordion.tsx +35 -0
- package/src/components/Accordion/components/withAccordionItem.tsx +37 -0
- package/src/components/Accordion/hooks/useAccordion.ts +56 -0
- package/src/components/Accordion/hooks/useAccordionContext.ts +32 -0
- package/src/components/Accordion/hooks/useAccordionItem.ts +31 -0
- package/src/components/Accordion/hooks/useAccordionItemEffect.ts +36 -0
- package/src/components/Accordion/hooks/useAccordionProvider.ts +35 -0
- package/src/components/Accordion/hooks/useAccordionState.ts +14 -0
- package/src/components/Accordion/index.ts +23 -0
- package/src/components/Accordion/utils/bem.ts +33 -0
- package/src/components/Accordion/utils/constants.ts +82 -0
- package/src/components/Accordion/utils/mergeProps.ts +24 -0
- package/src/components/Accordion/utils/useIsomorphicLayoutEffect.ts +15 -0
- package/src/components/AnchorNavigation/AnchorNavigation-test.js +48 -0
- package/src/components/AnchorNavigation/AnchorNavigation.stories.tsx +56 -0
- package/src/components/AnchorNavigation/AnchorNavigation.tsx +29 -0
- package/src/components/AnchorNavigation/README.mdx +0 -0
- package/src/components/AnchorNavigation/index.ts +1 -0
- package/src/components/AuthLayout/AuthLayout-test.js +46 -0
- package/src/components/AuthLayout/AuthLayout.stories.tsx +146 -0
- package/src/components/AuthLayout/AuthLayout.tsx +64 -0
- package/src/components/AuthLayout/README.mdx +0 -0
- package/src/components/AuthLayout/index.ts +1 -0
- package/src/components/Avatar/Avatar.stories.tsx +19 -0
- package/src/components/Avatar/Avatar.tsx +99 -0
- package/src/components/Avatar/index.ts +1 -0
- package/src/components/BannerNavigation/BannerNavigation-test.js +48 -0
- package/src/components/BannerNavigation/BannerNavigation.hbs +45 -0
- package/src/components/BannerNavigation/BannerNavigation.stories.tsx +64 -0
- package/src/components/BannerNavigation/BannerNavigation.tsx +55 -0
- package/src/components/BannerNavigation/BannerNavigation.twig +16 -0
- package/src/components/BannerNavigation/BannerNavigationWithContent.tsx +93 -0
- package/src/components/BannerNavigation/README.mdx +62 -0
- package/src/components/BannerNavigation/index.ts +2 -0
- package/src/components/BannerNavigation/kinds.js +3 -0
- package/src/components/Breadcrumb/Breadcrumb-test.js +50 -0
- package/src/components/Breadcrumb/Breadcrumb.Skeleton.jsx +22 -0
- package/src/components/Breadcrumb/Breadcrumb.hbs +16 -0
- package/src/components/Breadcrumb/Breadcrumb.stories.tsx +39 -0
- package/src/components/Breadcrumb/Breadcrumb.tsx +27 -0
- package/src/components/Breadcrumb/README.mdx +23 -0
- package/src/components/Breadcrumb/index.ts +2 -0
- package/src/components/BreadcrumbHome/BreadcrumbHome.tsx +37 -0
- package/src/components/BreadcrumbHome/index.ts +1 -0
- package/src/components/BreadcrumbItem/BreadcrumbItem.tsx +54 -0
- package/src/components/BreadcrumbItem/index.ts +1 -0
- package/src/components/Button/Button.Skeleton.tsx +30 -0
- package/src/components/Button/Button.d.ts +7 -0
- package/src/components/Button/Button.stories.tsx +339 -0
- package/src/components/Button/Button.test.tsx +135 -0
- package/src/components/Button/Button.tsx +201 -0
- package/src/components/Button/Button.twig +1 -0
- package/src/components/Button/README.mdx +34 -0
- package/src/components/Button/__snapshots__/Button.test.tsx.snap +12 -0
- package/src/components/Button/index.ts +2 -0
- package/src/components/Card/Card-old.js +187 -0
- package/src/components/Card/Card-test.js +27 -0
- package/src/components/Card/Card.stories.tsx +105 -0
- package/src/components/Card/Card.tsx +159 -0
- package/src/components/Card/Card.twig +21 -0
- package/src/components/Card/CardExternal.tsx +174 -0
- package/src/components/Card/README.mdx +1 -0
- package/src/components/Card/index.ts +2 -0
- package/src/components/Checkbox/Checkbox-old.js +132 -0
- package/src/components/Checkbox/Checkbox-test.js +205 -0
- package/src/components/Checkbox/Checkbox.Skeleton.js +37 -0
- package/src/components/Checkbox/Checkbox.hbs +15 -0
- package/src/components/Checkbox/Checkbox.legacy.js +126 -0
- package/src/components/Checkbox/Checkbox.stories.tsx +179 -0
- package/src/components/Checkbox/Checkbox.tsx +123 -0
- package/src/components/Checkbox/README.mdx +59 -0
- package/src/components/Checkbox/index.ts +1 -0
- package/src/components/CheckboxGroup/README.md +29 -0
- package/src/components/CheckboxGroup/RadioButtonGroup.js +158 -0
- package/src/components/CheckboxGroup/RadioButtonGroupWithoutControls.js +46 -0
- package/src/components/CheckboxGroup/index.js +1 -0
- package/src/components/ContentSwitcher/ContentSwitcher-test.js +117 -0
- package/src/components/ContentSwitcher/ContentSwitcher.hbs +5 -0
- package/src/components/ContentSwitcher/ContentSwitcher.stories.tsx +94 -0
- package/src/components/ContentSwitcher/ContentSwitcher.tsx +57 -0
- package/src/components/ContentSwitcher/README.mdx +31 -0
- package/src/components/ContentSwitcher/index.ts +1 -0
- package/src/components/ContextMenu/ContextMenu.stories.tsx +137 -0
- package/src/components/ContextMenu/ContextMenu.tsx +89 -0
- package/src/components/ContextMenu/README.mdx +13 -0
- package/src/components/ContextMenu/index.ts +1 -0
- package/src/components/Credits/Credits-test.js +25 -0
- package/src/components/Credits/Credits.hbs +4 -0
- package/src/components/Credits/Credits.stories.tsx +30 -0
- package/src/components/Credits/Credits.tsx +31 -0
- package/src/components/Credits/README.mdx +1 -0
- package/src/components/Credits/index.ts +1 -0
- package/src/components/DatePicker/DatePicker.stories.tsx +51 -0
- package/src/components/DatePicker/DatePicker.tsx +53 -0
- package/src/components/DatePicker/DatePickerInput.tsx +82 -0
- package/src/components/DatePicker/DatePickerNew.stories.js.new +195 -0
- package/src/components/DatePicker/DateRangePicker.tsx +63 -0
- package/src/components/DatePicker/DateRangePickerInput.tsx +106 -0
- package/src/components/DatePicker/README.mdx +50 -0
- package/src/components/DatePicker/index.ts +4 -0
- package/src/components/Empty/Empty-test.js +69 -0
- package/src/components/Empty/Empty.stories.tsx +54 -0
- package/src/components/Empty/Empty.tsx +95 -0
- package/src/components/Empty/README.mdx +28 -0
- package/src/components/Empty/index.ts +1 -0
- package/src/components/Footer/Footer-external.hbs +22 -0
- package/src/components/Footer/Footer-internal.hbs +30 -0
- package/src/components/Footer/Footer.stories.tsx +331 -0
- package/src/components/Footer/Footer.test.tsx +64 -0
- package/src/components/Footer/Footer.tsx +156 -0
- package/src/components/Footer/FooterExternal.tsx +172 -0
- package/src/components/Footer/README.mdx +20 -0
- package/src/components/Footer/index.ts +2 -0
- package/src/components/Form/Form-test.js +56 -0
- package/src/components/Form/Form.stories.tsx +485 -0
- package/src/components/Form/Form.tsx +40 -0
- package/src/components/Form/README.mdx +46 -0
- package/src/components/Form/index.ts +1 -0
- package/src/components/FormGroup/FormGroup-old.js +100 -0
- package/src/components/FormGroup/FormGroup-test.js +49 -0
- package/src/components/FormGroup/FormGroup.stories.tsx.new +306 -0
- package/src/components/FormGroup/FormGroup.tsx +63 -0
- package/src/components/FormGroup/README.mdx +7 -0
- package/src/components/FormGroup/index.ts +1 -0
- package/src/components/FormHint/FormHint-old.js +44 -0
- package/src/components/FormHint/FormHint-test.js +13 -0
- package/src/components/FormHint/FormHint.stories.tsx +72 -0
- package/src/components/FormHint/FormHint.tsx +37 -0
- package/src/components/FormHint/README.mdx +13 -0
- package/src/components/FormHint/index.ts +1 -0
- package/src/components/FormItem/FormItem-test.js +10 -0
- package/src/components/FormItem/FormItem.tsx +45 -0
- package/src/components/FormItem/RfFormItem.js +44 -0
- package/src/components/FormItem/__snapshots__/FormItem-test.js.snap +7 -0
- package/src/components/FormItem/index.ts +1 -0
- package/src/components/FormLabel/FormLabel-test.js +10 -0
- package/src/components/FormLabel/FormLabel.hbs +1 -0
- package/src/components/FormLabel/FormLabel.stories.tsx +15 -0
- package/src/components/FormLabel/FormLabel.tsx +35 -0
- package/src/components/FormLabel/README.mdx +1 -0
- package/src/components/FormLabel/RfFormLabel.js +38 -0
- package/src/components/FormLabel/__snapshots__/FormLabel-test.js.snap +7 -0
- package/src/components/FormLabel/index.ts +1 -0
- package/src/components/Hero/Hero-old.js +154 -0
- package/src/components/Hero/Hero-test.js +81 -0
- package/src/components/Hero/Hero.hbs +4 -0
- package/src/components/Hero/Hero.stories.tsx +356 -0
- package/src/components/Hero/Hero.tsx +142 -0
- package/src/components/Hero/Hero.twig +10 -0
- package/src/components/Hero/HeroExternal-old.js +54 -0
- package/src/components/Hero/HeroExternal.tsx +64 -0
- package/src/components/Hero/README.mdx +5 -0
- package/src/components/Hero/index.ts +2 -0
- package/src/components/InfoBar/InfoBar-test.js +17 -0
- package/src/components/InfoBar/InfoBar.stories.tsx +42 -0
- package/src/components/InfoBar/InfoBar.test.tsx +46 -0
- package/src/components/InfoBar/InfoBar.tsx +46 -0
- package/src/components/InfoBar/README.mdx +5 -0
- package/src/components/InfoBar/__snapshots__/InfoBar.test.tsx.snap +15 -0
- package/src/components/InfoBar/index.ts +1 -0
- package/src/components/InlineLoading/InlineLoading-FCold.js +90 -0
- package/src/components/InlineLoading/InlineLoading-Old.js +102 -0
- package/src/components/InlineLoading/InlineLoading-test.js +90 -0
- package/src/components/InlineLoading/InlineLoading.stories.tsx +39 -0
- package/src/components/InlineLoading/InlineLoading.tsx +79 -0
- package/src/components/InlineLoading/README.mdx +89 -0
- package/src/components/InlineLoading/index.ts +1 -0
- package/src/components/InlineLoading/inline-loading.config.js +25 -0
- package/src/components/InlineLoading/inline-loading.hbs +28 -0
- package/src/components/InlineLoading/inline-loading.js +135 -0
- package/src/components/Input/Input-test.js +120 -0
- package/src/components/Input/Input.stories.tsx +48 -0
- package/src/components/Input/Input.tsx +345 -0
- package/src/components/Input/README.mdx +46 -0
- package/src/components/Input/index.tsx +13 -0
- package/src/components/Input/useInput.tsx +189 -0
- package/src/components/InputGroup/InputGroup-old.js +166 -0
- package/src/components/InputGroup/InputGroup-test.js +114 -0
- package/src/components/InputGroup/InputGroup.stories.tsx +265 -0
- package/src/components/InputGroup/InputGroup.tsx +132 -0
- package/src/components/InputGroup/README.mdx +19 -0
- package/src/components/InputGroup/RadioButtonGroupWithoutControls.js +36 -0
- package/src/components/InputGroup/index.tsx +1 -0
- package/src/components/Item/Item-test.js +33 -0
- package/src/components/Item/Item.stories.tsx +158 -0
- package/src/components/Item/Item.tsx +134 -0
- package/src/components/Item/README.mdx +28 -0
- package/src/components/Item/index.ts +1 -0
- package/src/components/Link/Link-test.e2e.js +35 -0
- package/src/components/Link/Link-test.js +115 -0
- package/src/components/Link/Link.mdx +41 -0
- package/src/components/Link/Link.stories.tsx +95 -0
- package/src/components/Link/Link.test.tsx +100 -0
- package/src/components/Link/Link.tsx +91 -0
- package/src/components/Link/README.mdx +35 -0
- package/src/components/Link/__snapshots__/Link.test.tsx.snap +12 -0
- package/src/components/Link/index.ts +1 -0
- package/src/components/Link/link-avt.md +32 -0
- package/src/components/List/List-test.js +27 -0
- package/src/components/List/List.hbs +11 -0
- package/src/components/List/List.stories.tsx +195 -0
- package/src/components/List/List.tsx +91 -0
- package/src/components/List/ListItem.tsx +54 -0
- package/src/components/List/README.mdx +19 -0
- package/src/components/List/index.ts +2 -0
- package/src/components/Loading/Loading-oldClass.js +93 -0
- package/src/components/Loading/Loading-oldFC.js +80 -0
- package/src/components/Loading/Loading-test.js +68 -0
- package/src/components/Loading/Loading.stories.tsx +94 -0
- package/src/components/Loading/Loading.tsx +74 -0
- package/src/components/Loading/README.mdx +23 -0
- package/src/components/Loading/index.ts +8 -0
- package/src/components/Loading/loading-vanilla.js +137 -0
- package/src/components/Loading/loading.config.js +42 -0
- package/src/components/Loading/loading.hbs +18 -0
- package/src/components/MainNavigation/MainNavigation-test.js +26 -0
- package/src/components/MainNavigation/MainNavigation.hbs +180 -0
- package/src/components/MainNavigation/MainNavigation.stories.tsx +681 -0
- package/src/components/MainNavigation/MainNavigation.tsx +174 -0
- package/src/components/MainNavigation/MainNavigationContext.ts +34 -0
- package/src/components/MainNavigation/MainNavigationExternal.tsx +338 -0
- package/src/components/MainNavigation/MainNavigationRtl-story.legacy.js +95 -0
- package/src/components/MainNavigation/MobileButton.tsx +29 -0
- package/src/components/MainNavigation/README.mdx.legacy +173 -0
- package/src/components/MainNavigation/index.ts +4 -0
- package/src/components/MainNavigation/main-navigation.js +74 -0
- package/src/components/MainNavigation/useMainNavigation.tsx +17 -0
- package/src/components/MainNavigationItem/MainNavigationItem.tsx +110 -0
- package/src/components/MainNavigationItem/index.ts +1 -0
- package/src/components/MdxComponents/MdxComponents.stories.tsx +32 -0
- package/src/components/MdxComponents/MdxComponentsNew.tsx +181 -0
- package/src/components/MdxComponents/README.mdx +22 -0
- package/src/components/MdxComponents/index.ts +1 -0
- package/src/components/MdxComponents/markdown.mdx +109 -0
- package/src/components/Modal/Modal-test.js +206 -0
- package/src/components/Modal/Modal.hbs +26 -0
- package/src/components/Modal/Modal.stories.tsx +36 -0
- package/src/components/Modal/Modal.tsx +378 -0
- package/src/components/Modal/ModalFooter-old.js +41 -0
- package/src/components/Modal/ModalFooter.tsx +60 -0
- package/src/components/Modal/ModalHeader.js +25 -0
- package/src/components/Modal/ModalWithControls-story.legacy.js +44 -0
- package/src/components/Modal/README.mdx.legacy +102 -0
- package/src/components/Modal/index.ts +2 -0
- package/src/components/ModalWrapper/ModalWrapper-old.js +141 -0
- package/src/components/ModalWrapper/ModalWrapper-test.js +108 -0
- package/src/components/ModalWrapper/ModalWrapper.stories.tsx +109 -0
- package/src/components/ModalWrapper/ModalWrapper.tsx +149 -0
- package/src/components/ModalWrapper/README.mdx +16 -0
- package/src/components/ModalWrapper/index.ts +1 -0
- package/src/components/Module/Module-old.js +74 -0
- package/src/components/Module/Module-test.js +54 -0
- package/src/components/Module/Module.hbs +3 -0
- package/src/components/Module/Module.stories.tsx +108 -0
- package/src/components/Module/Module.tsx +75 -0
- package/src/components/Module/ModuleBody.tsx +42 -0
- package/src/components/Module/ModuleFooter.tsx +26 -0
- package/src/components/Module/ModuleHeader.tsx +34 -0
- package/src/components/Module/README.mdx +28 -0
- package/src/components/Module/index.ts +6 -0
- package/src/components/Notification/Callout.tsx +141 -0
- package/src/components/Notification/InlineNotification.tsx.legacy +142 -0
- package/src/components/Notification/Notification-test.js +258 -0
- package/src/components/Notification/Notification.stories.tsx +286 -0
- package/src/components/Notification/NotificationActionButton.tsx +48 -0
- package/src/components/Notification/NotificationButton.tsx +86 -0
- package/src/components/Notification/NotificationIcon.tsx +41 -0
- package/src/components/Notification/NotificationTextDetails.tsx +51 -0
- package/src/components/Notification/README.mdx +26 -0
- package/src/components/Notification/ToastNotification.tsx +110 -0
- package/src/components/Notification/a11yIconWarningSolid.js +36 -0
- package/src/components/Notification/index.ts +7 -0
- package/src/components/NumberInput/NumberInput-test.js +285 -0
- package/src/components/NumberInput/NumberInput.Skeleton.tsx +29 -0
- package/src/components/NumberInput/NumberInput.js.legacy +255 -0
- package/src/components/NumberInput/NumberInput.legacy.js +330 -0
- package/src/components/NumberInput/NumberInput.stories.tsx +79 -0
- package/src/components/NumberInput/NumberInput.tsx +215 -0
- package/src/components/NumberInput/README.mdx +16 -0
- package/src/components/NumberInput/index.ts +2 -0
- package/src/components/Pagination/Pagination-fc.js +217 -0
- package/src/components/Pagination/Pagination-old.js +346 -0
- package/src/components/Pagination/Pagination-test.js +400 -0
- package/src/components/Pagination/Pagination.Skeleton.jsx +22 -0
- package/src/components/Pagination/Pagination.stories.tsx +22 -0
- package/src/components/Pagination/Pagination.tsx +263 -0
- package/src/components/Pagination/README.mdx +27 -0
- package/src/components/Pagination/index.js +2 -0
- package/src/components/RadioButton/README.mdx +34 -0
- package/src/components/RadioButton/RadioButton-fc.js +103 -0
- package/src/components/RadioButton/RadioButton-old.js +109 -0
- package/src/components/RadioButton/RadioButton-test.js +131 -0
- package/src/components/RadioButton/RadioButton.Skeleton.jsx +20 -0
- package/src/components/RadioButton/RadioButton.hbs +7 -0
- package/src/components/RadioButton/RadioButton.stories.tsx +183 -0
- package/src/components/RadioButton/RadioButton.tsx +85 -0
- package/src/components/RadioButton/index.ts +3 -0
- package/src/components/RadioButtonGroup/README.md +31 -0
- package/src/components/RadioButtonGroup/RadioButtonGroup-test.js +65 -0
- package/src/components/RadioButtonGroup/RadioButtonGroup.js +172 -0
- package/src/components/RadioButtonGroup/RadioButtonGroupWithoutControls.js +44 -0
- package/src/components/RadioButtonGroup/index.js +1 -0
- package/src/components/ReactSelect/README.mdx +33 -0
- package/src/components/ReactSelect/ReactSelect.stories.tsx +56 -0
- package/src/components/ReadMore/README.mdx +30 -0
- package/src/components/ReadMore/ReadMore-test.js +17 -0
- package/src/components/ReadMore/ReadMore.stories.tsx +37 -0
- package/src/components/ReadMore/ReadMore.tsx +185 -0
- package/src/components/ReadMore/index.js +1 -0
- package/src/components/Search/README.mdx +22 -0
- package/src/components/Search/Search-test.js +178 -0
- package/src/components/Search/Search.stories.tsx +112 -0
- package/src/components/Search/Search.tsx +177 -0
- package/src/components/Search/index.ts +2 -0
- package/src/components/SecondaryNavigation/README.mdx +1 -0
- package/src/components/SecondaryNavigation/SecondaryNavigation-old.js +80 -0
- package/src/components/SecondaryNavigation/SecondaryNavigation-test.js +27 -0
- package/src/components/SecondaryNavigation/SecondaryNavigation.hbs +35 -0
- package/src/components/SecondaryNavigation/SecondaryNavigation.stories.tsx +133 -0
- package/src/components/SecondaryNavigation/SecondaryNavigation.tsx +56 -0
- package/src/components/SecondaryNavigation/SecondaryNavigationTitle.tsx +24 -0
- package/src/components/SecondaryNavigation/index.js +2 -0
- package/src/components/Select/README.mdx +17 -0
- package/src/components/Select/Select-test.js +165 -0
- package/src/components/Select/Select.Skeleton.js +25 -0
- package/src/components/Select/Select.stories.tsx +54 -0
- package/src/components/Select/Select.tsx +98 -0
- package/src/components/Select/index.ts +1 -0
- package/src/components/SelectItem/SelectItem-old.js +40 -0
- package/src/components/SelectItem/SelectItem-test.js +45 -0
- package/src/components/SelectItem/SelectItem.tsx +57 -0
- package/src/components/SelectItem/index.ts +1 -0
- package/src/components/SelectItemGroup/SelectItemGroup-test.js +34 -0
- package/src/components/SelectItemGroup/SelectItemGroup.tsx +40 -0
- package/src/components/SelectItemGroup/index.ts +1 -0
- package/src/components/Sidebar/PHONEBOOK.json +1101 -0
- package/src/components/Sidebar/README.mdx +0 -0
- package/src/components/Sidebar/Sidebar-test.js +55 -0
- package/src/components/Sidebar/Sidebar.stories.tsx.new +430 -0
- package/src/components/Sidebar/Sidebar.tsx +164 -0
- package/src/components/Sidebar/index.ts +8 -0
- package/src/components/SkeletonText/README.mdx +29 -0
- package/src/components/SkeletonText/SkeletonText-old.js +95 -0
- package/src/components/SkeletonText/SkeletonText-test.js +23 -0
- package/src/components/SkeletonText/SkeletonText.stories.tsx +19 -0
- package/src/components/SkeletonText/SkeletonText.tsx +90 -0
- package/src/components/SkeletonText/index.ts +1 -0
- package/src/components/Slider/README.mdx +21 -0
- package/src/components/Slider/Slider-old.js +315 -0
- package/src/components/Slider/Slider-test.js +145 -0
- package/src/components/Slider/Slider.Skeleton.jsx +29 -0
- package/src/components/Slider/Slider.legacy.js +476 -0
- package/src/components/Slider/Slider.stories.tsx +116 -0
- package/src/components/Slider/Slider.tsx +242 -0
- package/src/components/Slider/index.ts +2 -0
- package/src/components/StepNavigation/README.mdx +16 -0
- package/src/components/StepNavigation/StepNavigation-test.js +20 -0
- package/src/components/StepNavigation/StepNavigation.Skeleton.tsx +33 -0
- package/src/components/StepNavigation/StepNavigation.hbs +14 -0
- package/src/components/StepNavigation/StepNavigation.stories.tsx +131 -0
- package/src/components/StepNavigation/StepNavigation.tsx +159 -0
- package/src/components/StepNavigation/index.ts +2 -0
- package/src/components/StepNavigationItem/StepNavigationItem-test.js +24 -0
- package/src/components/StepNavigationItem/StepNavigationItem.tsx +155 -0
- package/src/components/StepNavigationItem/index.ts +1 -0
- package/src/components/Story/README.mdx +27 -0
- package/src/components/Story/Story-text.js +22 -0
- package/src/components/Story/Story.hbs +12 -0
- package/src/components/Story/Story.stories.tsx +109 -0
- package/src/components/Story/Story.tsx +25 -0
- package/src/components/Story/index.ts +1 -0
- package/src/components/SubNavigation/README.mdx +111 -0
- package/src/components/SubNavigation/SubNavigation-test.js +161 -0
- package/src/components/SubNavigation/SubNavigation.stories.tsx +249 -0
- package/src/components/SubNavigation/SubNavigation.tsx +6 -0
- package/src/components/SubNavigation/SubNavigationContent.tsx +26 -0
- package/src/components/SubNavigation/SubNavigationFilter.tsx +26 -0
- package/src/components/SubNavigation/SubNavigationGroup.tsx +48 -0
- package/src/components/SubNavigation/SubNavigationHeader.tsx +26 -0
- package/src/components/SubNavigation/SubNavigationItem.tsx +25 -0
- package/src/components/SubNavigation/SubNavigationLink.tsx +25 -0
- package/src/components/SubNavigation/SubNavigationList.tsx +25 -0
- package/src/components/SubNavigation/SubNavigationTitle.tsx +26 -0
- package/src/components/SubNavigation/index.ts +9 -0
- package/src/components/Tab/Tab-oldClass.js +209 -0
- package/src/components/Tab/Tab-oldFunc.js +206 -0
- package/src/components/Tab/Tab-test.js +93 -0
- package/src/components/Tab/Tab.tsx +149 -0
- package/src/components/Tab/index.ts +3 -0
- package/src/components/Tab/useTab.tsx +89 -0
- package/src/components/TabContent/TabContent-old.js +30 -0
- package/src/components/TabContent/TabContent-test.js +28 -0
- package/src/components/TabContent/TabContent.tsx +26 -0
- package/src/components/TabContent/index.ts +1 -0
- package/src/components/Table/README.mdx +0 -0
- package/src/components/Table/Table-test.js +22 -0
- package/src/components/Table/Table.stories.tsx +524 -0
- package/src/components/Table/Table.tsx +34 -0
- package/src/components/Table/TableResponsive-story-legacy.js +216 -0
- package/src/components/Table/TableSimple-story-legacy.js +39 -0
- package/src/components/Table/TableSorting.tsx +31 -0
- package/src/components/Table/index.ts +2 -0
- package/src/components/Table/makeData.js +75 -0
- package/src/components/TablePagination/TablePagination.tsx +98 -0
- package/src/components/TablePagination/index.ts +1 -0
- package/src/components/Tabs/README.mdx +113 -0
- package/src/components/Tabs/Tabs-old.js.legacy +281 -0
- package/src/components/Tabs/Tabs-test.js +284 -0
- package/src/components/Tabs/Tabs.Skeleton.jsx +33 -0
- package/src/components/Tabs/Tabs.hbs +14 -0
- package/src/components/Tabs/Tabs.stories.tsx +73 -0
- package/src/components/Tabs/Tabs.tsx +270 -0
- package/src/components/Tabs/TabsContext.ts +15 -0
- package/src/components/Tabs/index.ts +2 -0
- package/src/components/Tag/README.mdx +19 -0
- package/src/components/Tag/Tag-test.js +42 -0
- package/src/components/Tag/Tag.Skeleton.jsx +9 -0
- package/src/components/Tag/Tag.stories.tsx +20 -0
- package/src/components/Tag/Tag.tsx +46 -0
- package/src/components/Tag/index.ts +3 -0
- package/src/components/Tag/tag.config.js +69 -0
- package/src/components/Tag/tag.hbs +10 -0
- package/src/components/Text/README.mdx +57 -0
- package/src/components/Text/Text-test.js +19 -0
- package/src/components/Text/Text.js.legacy +102 -0
- package/src/components/Text/Text.stories.tsx +390 -0
- package/src/components/Text/Text.tsx +81 -0
- package/src/components/Text/index.ts +2 -0
- package/src/components/TextArea/README.mdx +3 -0
- package/src/components/TextArea/TextArea-old.js +207 -0
- package/src/components/TextArea/TextArea-test.js +167 -0
- package/src/components/TextArea/TextArea.Skeleton.jsx +21 -0
- package/src/components/TextArea/TextArea.stories.tsx +43 -0
- package/src/components/TextArea/TextArea.tsx +40 -0
- package/src/components/TextArea/index.ts +2 -0
- package/src/components/TextInput/README.mdx +3 -0
- package/src/components/TextInput/TextInput-old.js +162 -0
- package/src/components/TextInput/TextInput-test.js +156 -0
- package/src/components/TextInput/TextInput.Skeleton.jsx +21 -0
- package/src/components/TextInput/TextInput.hbs +4 -0
- package/src/components/TextInput/TextInput.legacy.js +162 -0
- package/src/components/TextInput/TextInput.stories.tsx +80 -0
- package/src/components/TextInput/TextInput.tsx +52 -0
- package/src/components/TextInput/index.ts +2 -0
- package/src/components/Toggle/README.mdx +4 -0
- package/src/components/Toggle/Toggle-old.js +113 -0
- package/src/components/Toggle/Toggle-test.js +114 -0
- package/src/components/Toggle/Toggle.Skeleton.jsx +18 -0
- package/src/components/Toggle/Toggle.stories.tsx +21 -0
- package/src/components/Toggle/Toggle.tsx +113 -0
- package/src/components/Toggle/index.ts +2 -0
- package/src/components/Tooltip/Empty.js +5 -0
- package/src/components/Tooltip/README.mdx +1 -0
- package/src/components/Tooltip/Tooltip.stories.tsx +99 -0
- package/src/components/Tooltip/Tooltip.tsx +235 -0
- package/src/components/Tooltip/_mixins.scss +107 -0
- package/src/components/Tooltip/_tooltip.legacy.scss +58 -0
- package/src/components/Tooltip/_tooltip.scss +112 -0
- package/src/components/Tooltip/_vars.scss +6 -0
- package/src/components/Tooltip/animations/fade.scss +10 -0
- package/src/components/Tooltip/backdrop.scss +66 -0
- package/src/components/Tooltip/index.tsx +2 -0
- package/src/components/Tooltip/legacy/_mixins.scss +191 -0
- package/src/components/Tooltip/legacy/_tooltip.scss +70 -0
- package/src/components/Tooltip/legacy/_vars.scss +5 -0
- package/src/components/Tooltip/legacy/themes/light.scss +30 -0
- package/src/components/Tooltip/svg-arrow.scss +37 -0
- package/src/components/Tooltip/themes/light-border.scss +158 -0
- package/src/components/Tooltip/themes/light.scss +28 -0
- package/src/components/Unit/InvalidUnit.tsx +11 -0
- package/src/components/Unit/README.mdx +1 -0
- package/src/components/Unit/SimpleCalc.tsx +49 -0
- package/src/components/Unit/StringUnit.tsx +13 -0
- package/src/components/Unit/SvgUnit.tsx +22 -0
- package/src/components/Unit/Unit-old.js +138 -0
- package/src/components/Unit/Unit-test.js +18 -0
- package/src/components/Unit/Unit.hbs +1 -0
- package/src/components/Unit/Unit.stories.tsx +161 -0
- package/src/components/Unit/Unit.tsx +158 -0
- package/src/components/Unit/UnitList.tsx +84 -0
- package/src/components/Unit/YearMonthCalc.tsx +59 -0
- package/src/components/Unit/currencyCalc.tsx +124 -0
- package/src/components/Unit/index.js +1 -0
- package/src/components/Unit/percentageCalc.tsx +73 -0
- package/src/components/Unit/scaleLookup.tsx +19 -0
- package/src/components/User/README.mdx +1 -0
- package/src/components/User/User-test.js +50 -0
- package/src/components/User/User.hbs +8 -0
- package/src/components/User/User.stories.tsx +100 -0
- package/src/components/User/User.tsx +111 -0
- package/src/components/User/index.ts +1 -0
- package/src/components/Value/README.mdx +1 -0
- package/src/components/Value/Value-test.js +28 -0
- package/src/components/Value/Value.stories.tsx +28 -0
- package/src/components/Value/Value.tsx +34 -0
- package/src/components/Value/index.ts +1 -0
- package/src/components/WFPCoreSettings/WFPCoreProvider.tsx +125 -0
- package/src/components/WFPCoreSettings/defaults.ts +3 -0
- package/src/components/WFPCoreSettings/index.ts +4 -0
- package/src/components/WFPCoreSettings/useTheme.tsx +7 -0
- package/src/components/WFPCoreSettings/withWFPCoreSettings.tsx +12 -0
- package/src/components/Wrapper/README.mdx +11 -0
- package/src/components/Wrapper/Wrapper-test.js +51 -0
- package/src/components/Wrapper/Wrapper.stories.tsx +26 -0
- package/src/components/Wrapper/Wrapper.test.tsx +94 -0
- package/src/components/Wrapper/Wrapper.tsx +86 -0
- package/src/components/Wrapper/__snapshots__/Wrapper.test.tsx.snap +11 -0
- package/src/components/Wrapper/index.ts +2 -0
- package/src/globals/data/colors.js +716 -0
- package/src/globals/data/colors.json +273 -0
- package/src/globals/js/boot.js +39 -0
- package/src/globals/js/components.js +36 -0
- package/src/globals/js/index.js +1 -0
- package/src/globals/js/misc/event-matches.js +29 -0
- package/src/globals/js/misc/get-launching-details.js +24 -0
- package/src/globals/js/misc/mixin.js +30 -0
- package/src/globals/js/misc/on.js +9 -0
- package/src/globals/js/misc/resize.js +53 -0
- package/src/globals/js/misc/svg-toggle-class.js +23 -0
- package/src/globals/js/mixins/README.md +207 -0
- package/src/globals/js/mixins/create-component.js +69 -0
- package/src/globals/js/mixins/evented-show-hide-state.js +40 -0
- package/src/globals/js/mixins/evented-state.js +124 -0
- package/src/globals/js/mixins/handles.js +45 -0
- package/src/globals/js/mixins/init-component-by-event.js +84 -0
- package/src/globals/js/mixins/init-component-by-launcher.js +89 -0
- package/src/globals/js/mixins/init-component-by-search.js +41 -0
- package/src/globals/js/mixins/track-blur.js +45 -0
- package/src/globals/js/settings.tsx +49 -0
- package/src/globals/js/watch.js +95 -0
- package/src/globals/scss/styles.scss +146 -0
- package/src/hooks/index.js +1 -0
- package/src/hooks/togglable.js +12 -0
- package/src/hooks/useHeightTransition.ts +33 -0
- package/src/hooks/useId.ts +14 -0
- package/src/hooks/useIsomorphicLayoutEffect.tsx +14 -0
- package/src/hooks/useMediaQuery.tsx +79 -0
- package/src/hooks/useMergeRef.ts +24 -0
- package/src/hooks/useSettings.tsx +20 -0
- package/src/hooks/useWizard.js +77 -0
- package/src/index.ts +185 -0
- package/src/indexStories.ts +44 -0
- package/src/internal/FeatureFlags.js +21 -0
- package/src/internal/FloatingMenu.js +352 -0
- package/src/internal/OptimizedResize.js +54 -0
- package/src/internal/RfFormJest.js +45 -0
- package/src/internal/RfFormWrapper.js +86 -0
- package/src/internal/configureStore.js +13 -0
- package/src/internal/loadDefaultData.js +20 -0
- package/src/internal/useDetectPrint.js.legacy +20 -0
- package/src/internal/withTests.js +7 -0
- package/src/prop-types/types.ts +32 -0
- package/src/tools/__tests__/uniqueId.test.ts +16 -0
- package/src/tools/mergeRefs.js +23 -0
- package/src/tools/setupGetInstanceId.js +10 -0
- package/src/tools/uniqueId.ts +8 -0
- package/src/tools/withState.js +21 -0
- package/src/tools/wrapComponent.js +23 -0
- package/src/utils/index.d.ts +138 -0
- package/umd/dist/components/Accordion/__tests__/utils.d.ts +12 -0
- package/umd/dist/components/Accordion/components/Accordion.d.ts +7 -0
- package/umd/dist/components/Accordion/components/AccordionItem.d.ts +46 -0
- package/umd/dist/components/Accordion/components/AccordionProvider.d.ts +7 -0
- package/umd/dist/components/Accordion/components/ControlledAccordion.d.ts +8 -0
- package/umd/dist/components/Accordion/components/withAccordionItem.d.ts +11 -0
- package/umd/dist/components/Accordion/hooks/useAccordion.d.ts +5 -0
- package/umd/dist/components/Accordion/hooks/useAccordionContext.d.ts +5 -0
- package/umd/dist/components/Accordion/hooks/useAccordionItem.d.ts +7 -0
- package/umd/dist/components/Accordion/hooks/useAccordionItemEffect.d.ts +13 -0
- package/umd/dist/components/Accordion/hooks/useAccordionProvider.d.ts +3 -0
- package/umd/dist/components/Accordion/hooks/useAccordionState.d.ts +14 -0
- package/umd/dist/components/Accordion/hooks/useHeightTransition.d.ts +4 -0
- package/umd/dist/components/Accordion/hooks/useId.d.ts +3 -0
- package/umd/dist/components/Accordion/hooks/useMergeRef.d.ts +4 -0
- package/umd/dist/components/Accordion/index.d.ts +17 -0
- package/umd/dist/components/Accordion/utils/bem.d.ts +7 -0
- package/umd/dist/components/Accordion/utils/constants.d.ts +58 -0
- package/umd/dist/components/Accordion/utils/mergeProps.d.ts +2 -0
- package/umd/dist/components/Accordion/utils/useIsomorphicLayoutEffect.d.ts +3 -0
- package/umd/dist/components/AnchorNavigation/AnchorNavigation.d.ts +6 -0
- package/umd/dist/components/AnchorNavigation/index.d.ts +1 -0
- package/umd/dist/components/AuthLayout/AuthLayout.d.ts +20 -0
- package/umd/dist/components/AuthLayout/index.d.ts +1 -0
- package/umd/dist/components/Avatar/Avatar.d.ts +33 -0
- package/umd/dist/components/Avatar/index.d.ts +1 -0
- package/umd/dist/components/BannerNavigation/BannerNavigation.d.ts +20 -0
- package/umd/dist/components/BannerNavigation/BannerNavigationWithContent.d.ts +13 -0
- package/umd/dist/components/BannerNavigation/index.d.ts +2 -0
- package/umd/dist/components/Breadcrumb/Breadcrumb.d.ts +11 -0
- package/umd/dist/components/Breadcrumb/index.d.ts +1 -0
- package/umd/dist/components/BreadcrumbHome/BreadcrumbHome.d.ts +13 -0
- package/umd/dist/components/BreadcrumbHome/index.d.ts +1 -0
- package/umd/dist/components/BreadcrumbItem/BreadcrumbItem.d.ts +21 -0
- package/umd/dist/components/BreadcrumbItem/index.d.ts +1 -0
- package/umd/dist/components/Button/Button.Skeleton.d.ts +7 -0
- package/umd/dist/components/Button/Button.d.ts +55 -0
- package/umd/dist/components/Button/index.d.ts +1 -0
- package/umd/dist/components/Card/Card.d.ts +61 -0
- package/umd/dist/components/Card/CardExternal.d.ts +37 -0
- package/umd/dist/components/Card/index.d.ts +2 -0
- package/umd/dist/components/Checkbox/Checkbox.d.ts +37 -0
- package/umd/dist/components/Checkbox/index.d.ts +1 -0
- package/umd/dist/components/ContentSwitcher/ContentSwitcher.d.ts +12 -0
- package/umd/dist/components/ContentSwitcher/index.d.ts +1 -0
- package/umd/dist/components/ContextMenu/ContextMenu.d.ts +31 -0
- package/umd/dist/components/ContextMenu/index.d.ts +1 -0
- package/umd/dist/components/Credits/Credits.d.ts +10 -0
- package/umd/dist/components/Credits/index.d.ts +1 -0
- package/umd/dist/components/DatePicker/DatePicker.d.ts +8 -0
- package/umd/dist/components/DatePicker/DatePickerInput.d.ts +38 -0
- package/umd/dist/components/DatePicker/DateRangePicker.d.ts +8 -0
- package/umd/dist/components/DatePicker/DateRangePickerInput.d.ts +34 -0
- package/umd/dist/components/DatePicker/index.d.ts +4 -0
- package/umd/dist/components/DatePickerNew/DateRangePickerInput.d.ts +11 -0
- package/umd/dist/components/Empty/Empty.d.ts +40 -0
- package/umd/dist/components/Empty/index.d.ts +1 -0
- package/umd/dist/components/Footer/Footer.d.ts +47 -0
- package/umd/dist/components/Footer/FooterExternal.d.ts +22 -0
- package/umd/dist/components/Footer/index.d.ts +2 -0
- package/umd/dist/components/Form/Form.d.ts +15 -0
- package/umd/dist/components/Form/index.d.ts +1 -0
- package/umd/dist/components/FormGroup/FormGroup.d.ts +14 -0
- package/umd/dist/components/FormGroup/index.d.ts +1 -0
- package/umd/dist/components/FormHint/FormHint.d.ts +15 -0
- package/umd/dist/components/FormHint/index.d.ts +1 -0
- package/umd/dist/components/FormItem/FormItem.d.ts +17 -0
- package/umd/dist/components/FormItem/index.d.ts +1 -0
- package/umd/dist/components/FormLabel/FormLabel.d.ts +15 -0
- package/umd/dist/components/FormLabel/index.d.ts +1 -0
- package/umd/dist/components/Hero/Hero.d.ts +53 -0
- package/umd/dist/components/Hero/HeroExternal.d.ts +22 -0
- package/umd/dist/components/Hero/index.d.ts +2 -0
- package/umd/dist/components/InfoBar/InfoBar.d.ts +23 -0
- package/umd/dist/components/InfoBar/index.d.ts +1 -0
- package/umd/dist/components/InlineLoading/InlineLoading.d.ts +26 -0
- package/umd/dist/components/InlineLoading/index.d.ts +1 -0
- package/umd/dist/components/Input/Input.d.ts +152 -0
- package/umd/dist/components/Input/index.d.ts +3 -0
- package/umd/dist/components/Input/useInput.d.ts +123 -0
- package/umd/dist/components/InputGroup/InputGroup.d.ts +48 -0
- package/umd/dist/components/InputGroup/index.d.ts +1 -0
- package/umd/dist/components/Item/Item.d.ts +59 -0
- package/umd/dist/components/Item/index.d.ts +1 -0
- package/umd/dist/components/Link/Link.d.ts +37 -0
- package/umd/dist/components/Link/index.d.ts +1 -0
- package/umd/dist/components/List/List.d.ts +32 -0
- package/umd/dist/components/List/ListItem.d.ts +25 -0
- package/umd/dist/components/List/index.d.ts +2 -0
- package/umd/dist/components/Loading/Loading.d.ts +16 -0
- package/umd/dist/components/Loading/index.d.ts +7 -0
- package/umd/dist/components/MainNavigation/MainNavigation.d.ts +51 -0
- package/umd/dist/components/MainNavigation/MainNavigationContext.d.ts +25 -0
- package/umd/dist/components/MainNavigation/MainNavigationExternal.d.ts +72 -0
- package/umd/dist/components/MainNavigation/MobileButton.d.ts +17 -0
- package/umd/dist/components/MainNavigation/index.d.ts +4 -0
- package/umd/dist/components/MainNavigation/useMainNavigation.d.ts +7 -0
- package/umd/dist/components/MainNavigationItem/MainNavigationItem.d.ts +29 -0
- package/umd/dist/components/MainNavigationItem/index.d.ts +1 -0
- package/umd/dist/components/MdxComponents/MdxComponentsNew.d.ts +2 -0
- package/umd/dist/components/MdxComponents/index.d.ts +1 -0
- package/umd/dist/components/Modal/Modal.d.ts +122 -0
- package/umd/dist/components/Modal/ModalFooter.d.ts +8 -0
- package/umd/dist/components/Modal/index.d.ts +2 -0
- package/umd/dist/components/ModalWrapper/ModalWrapper.d.ts +53 -0
- package/umd/dist/components/ModalWrapper/index.d.ts +1 -0
- package/umd/dist/components/Module/Module.d.ts +38 -0
- package/umd/dist/components/Module/ModuleBody.d.ts +21 -0
- package/umd/dist/components/Module/ModuleFooter.d.ts +10 -0
- package/umd/dist/components/Module/ModuleHeader.d.ts +16 -0
- package/umd/dist/components/Module/index.d.ts +4 -0
- package/umd/dist/components/Notification/Callout.d.ts +59 -0
- package/umd/dist/components/Notification/NotificationActionButton.d.ts +18 -0
- package/umd/dist/components/Notification/NotificationButton.d.ts +36 -0
- package/umd/dist/components/Notification/NotificationIcon.d.ts +8 -0
- package/umd/dist/components/Notification/NotificationTextDetails.d.ts +10 -0
- package/umd/dist/components/Notification/ToastNotification.d.ts +10 -0
- package/umd/dist/components/Notification/index.d.ts +5 -0
- package/umd/dist/components/NumberInput/NumberInput.Skeleton.d.ts +10 -0
- package/umd/dist/components/NumberInput/NumberInput.d.ts +64 -0
- package/umd/dist/components/NumberInput/index.d.ts +2 -0
- package/umd/dist/components/Pagination/Pagination.d.ts +92 -0
- package/umd/dist/components/Pagination/index.d.ts +1 -0
- package/umd/dist/components/RadioButton/RadioButton.d.ts +27 -0
- package/umd/dist/components/RadioButton/index.d.ts +2 -0
- package/umd/dist/components/ReadMore/ReadMore.d.ts +45 -0
- package/umd/dist/components/ReadMore/index.d.ts +1 -0
- package/umd/dist/components/Search/Search.d.ts +50 -0
- package/umd/dist/components/Search/index.d.ts +1 -0
- package/umd/dist/components/SecondaryNavigation/SecondaryNavigation.d.ts +19 -0
- package/umd/dist/components/SecondaryNavigation/SecondaryNavigationTitle.d.ts +8 -0
- package/umd/dist/components/SecondaryNavigation/index.d.ts +2 -0
- package/umd/dist/components/Select/Select.d.ts +24 -0
- package/umd/dist/components/Select/index.d.ts +1 -0
- package/umd/dist/components/SelectItem/SelectItem.d.ts +28 -0
- package/umd/dist/components/SelectItem/index.d.ts +1 -0
- package/umd/dist/components/SelectItemGroup/SelectItemGroup.d.ts +21 -0
- package/umd/dist/components/SelectItemGroup/index.d.ts +1 -0
- package/umd/dist/components/Sidebar/Sidebar.d.ts +46 -0
- package/umd/dist/components/Sidebar/index.d.ts +1 -0
- package/umd/dist/components/SkeletonText/SkeletonText.d.ts +22 -0
- package/umd/dist/components/SkeletonText/index.d.ts +1 -0
- package/umd/dist/components/Slider/Slider.d.ts +71 -0
- package/umd/dist/components/Slider/index.d.ts +1 -0
- package/umd/dist/components/StepNavigation/StepNavigation.Skeleton.d.ts +2 -0
- package/umd/dist/components/StepNavigation/StepNavigation.d.ts +42 -0
- package/umd/dist/components/StepNavigation/index.d.ts +2 -0
- package/umd/dist/components/StepNavigationItem/StepNavigationItem.d.ts +55 -0
- package/umd/dist/components/StepNavigationItem/index.d.ts +1 -0
- package/umd/dist/components/Story/Story.d.ts +7 -0
- package/umd/dist/components/Story/index.d.ts +1 -0
- package/umd/dist/components/SubNavigation/SubNavigation.d.ts +5 -0
- package/umd/dist/components/SubNavigation/SubNavigationContent.d.ts +9 -0
- package/umd/dist/components/SubNavigation/SubNavigationFilter.d.ts +9 -0
- package/umd/dist/components/SubNavigation/SubNavigationGroup.d.ts +17 -0
- package/umd/dist/components/SubNavigation/SubNavigationHeader.d.ts +9 -0
- package/umd/dist/components/SubNavigation/SubNavigationItem.d.ts +9 -0
- package/umd/dist/components/SubNavigation/SubNavigationLink.d.ts +9 -0
- package/umd/dist/components/SubNavigation/SubNavigationList.d.ts +9 -0
- package/umd/dist/components/SubNavigation/SubNavigationTitle.d.ts +9 -0
- package/umd/dist/components/SubNavigation/index.d.ts +9 -0
- package/umd/dist/components/Tab/Tab.d.ts +83 -0
- package/umd/dist/components/Tab/index.d.ts +2 -0
- package/umd/dist/components/Tab/useTab.d.ts +12 -0
- package/umd/dist/components/TabContent/TabContent.d.ts +13 -0
- package/umd/dist/components/TabContent/index.d.ts +1 -0
- package/umd/dist/components/Table/Table.d.ts +8 -0
- package/umd/dist/components/Table/TableSorting.d.ts +11 -0
- package/umd/dist/components/Table/index.d.ts +2 -0
- package/umd/dist/components/TablePagination/TablePagination.d.ts +33 -0
- package/umd/dist/components/TablePagination/index.d.ts +1 -0
- package/umd/dist/components/Tabs/Tabs.d.ts +67 -0
- package/umd/dist/components/Tabs/TabsContext.d.ts +8 -0
- package/umd/dist/components/Tabs/index.d.ts +1 -0
- package/umd/dist/components/Tag/Tag.d.ts +14 -0
- package/umd/dist/components/Tag/index.d.ts +2 -0
- package/umd/dist/components/Text/Text.d.ts +30 -0
- package/umd/dist/components/Text/index.d.ts +1 -0
- package/umd/dist/components/TextArea/TextArea.d.ts +8 -0
- package/umd/dist/components/TextArea/index.d.ts +1 -0
- package/umd/dist/components/TextInput/TextInput.d.ts +7 -0
- package/umd/dist/components/TextInput/index.d.ts +1 -0
- package/umd/dist/components/Toggle/Toggle.d.ts +38 -0
- package/umd/dist/components/Toggle/index.d.ts +1 -0
- package/umd/dist/components/Tooltip/Tooltip.d.ts +103 -0
- package/umd/dist/components/Tooltip/index.d.ts +2 -0
- package/umd/dist/components/UNCoreSettings/UNCoreProvider.d.ts +21 -0
- package/umd/dist/components/UNCoreSettings/defaults.d.ts +2 -0
- package/umd/dist/components/UNCoreSettings/index.d.ts +4 -0
- package/umd/dist/components/UNCoreSettings/useTheme.d.ts +2 -0
- package/umd/dist/components/UNCoreSettings/withUNCoreSettings.d.ts +2 -0
- package/umd/dist/components/Unit/InvalidUnit.d.ts +2 -0
- package/umd/dist/components/Unit/SimpleCalc.d.ts +17 -0
- package/umd/dist/components/Unit/StringUnit.d.ts +2 -0
- package/umd/dist/components/Unit/SvgUnit.d.ts +2 -0
- package/umd/dist/components/Unit/Unit.d.ts +54 -0
- package/umd/dist/components/Unit/UnitList.d.ts +96 -0
- package/umd/dist/components/Unit/YearMonthCalc.d.ts +7 -0
- package/umd/dist/components/Unit/currencyCalc.d.ts +21 -0
- package/umd/dist/components/Unit/index.d.ts +1 -0
- package/umd/dist/components/Unit/percentageCalc.d.ts +18 -0
- package/umd/dist/components/Unit/scaleLookup.d.ts +24 -0
- package/umd/dist/components/User/User.d.ts +55 -0
- package/umd/dist/components/User/index.d.ts +1 -0
- package/umd/dist/components/Value/Value.d.ts +11 -0
- package/umd/dist/components/Value/index.d.ts +1 -0
- package/umd/dist/components/WFPCoreSettings/WFPCoreProvider.d.ts +21 -0
- package/umd/dist/components/WFPCoreSettings/defaults.d.ts +2 -0
- package/umd/dist/components/WFPCoreSettings/index.d.ts +4 -0
- package/umd/dist/components/WFPCoreSettings/useTheme.d.ts +2 -0
- package/umd/dist/components/WFPCoreSettings/withWFPCoreSettings.d.ts +2 -0
- package/umd/dist/components/Wrapper/Wrapper.d.ts +22 -0
- package/umd/dist/components/Wrapper/index.d.ts +2 -0
- package/umd/dist/globals/data/colors.d.ts +609 -0
- package/umd/dist/globals/js/settings.d.ts +34 -0
- package/umd/dist/hooks/index.d.ts +1 -0
- package/umd/dist/hooks/togglable.d.ts +5 -0
- package/umd/dist/hooks/useHeightTransition.d.ts +4 -0
- package/umd/dist/hooks/useId.d.ts +3 -0
- package/umd/dist/hooks/useIsomorphicLayoutEffect.d.ts +12 -0
- package/umd/dist/hooks/useMediaQuery.d.ts +19 -0
- package/umd/dist/hooks/useMergeRef.d.ts +4 -0
- package/umd/dist/hooks/useSettings.d.ts +2 -0
- package/umd/dist/index.d.ts +75 -0
- package/umd/dist/indexStories.d.ts +1 -0
- package/umd/dist/internal/FeatureFlags.d.ts +19 -0
- package/umd/dist/prop-types/types.d.ts +5 -0
- package/umd/dist/tools/uniqueId.d.ts +2 -0
- package/umd/index.js +5470 -0
- package/umd/index.js.map +1 -0
- package/umd/index.min.js +1 -0
- package/umd/index.min.js.map +1 -0
package/src/index.ts
ADDED
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
export { Accordion, AccordionItem } from "./components/Accordion";
|
|
2
|
+
|
|
3
|
+
export { AuthLayout, BackgroundContent } from "./components/AuthLayout";
|
|
4
|
+
export {
|
|
5
|
+
BannerNavigation,
|
|
6
|
+
BannerNavigationItem,
|
|
7
|
+
BannerNavigationWithContent,
|
|
8
|
+
} from "./components/BannerNavigation";
|
|
9
|
+
|
|
10
|
+
export { default as Avatar } from "./components/Avatar";
|
|
11
|
+
//export { default as Blockquote } from './components/Blockquote';
|
|
12
|
+
export { default as Breadcrumb } from "./components/Breadcrumb";
|
|
13
|
+
export { default as BreadcrumbItem } from "./components/BreadcrumbItem";
|
|
14
|
+
export { default as BreadcrumbHome } from "./components/BreadcrumbHome";
|
|
15
|
+
export { default as Button } from "./components/Button";
|
|
16
|
+
|
|
17
|
+
export { buttonKinds, notificationtypes } from "./prop-types/types";
|
|
18
|
+
export { default as Empty } from "./components/Empty";
|
|
19
|
+
export { Hero, HeroExternal } from "./components/Hero";
|
|
20
|
+
export { Card, CardExternal } from "./components/Card";
|
|
21
|
+
|
|
22
|
+
export {
|
|
23
|
+
DatePicker,
|
|
24
|
+
DateRangePicker,
|
|
25
|
+
DatePickerInput,
|
|
26
|
+
DateRangePickerInput,
|
|
27
|
+
} from "./components/DatePicker";
|
|
28
|
+
|
|
29
|
+
export { default as Checkbox } from "./components/Checkbox";
|
|
30
|
+
export { default as Credits } from "./components/Credits";
|
|
31
|
+
export { default as ContentSwitcher } from "./components/ContentSwitcher";
|
|
32
|
+
export {
|
|
33
|
+
ContextMenu,
|
|
34
|
+
ContextMenuGroup,
|
|
35
|
+
ContextMenuItem,
|
|
36
|
+
} from "./components/ContextMenu";
|
|
37
|
+
/*export {
|
|
38
|
+
SingleDatePickerInput,
|
|
39
|
+
DateRangePickerInput,
|
|
40
|
+
} from './components/DatePicker';*/
|
|
41
|
+
|
|
42
|
+
//export * from './FileUploader.Skeleton';
|
|
43
|
+
/*export {
|
|
44
|
+
FeatureFlags,
|
|
45
|
+
FeatureFlagContext,
|
|
46
|
+
useFeatureFlags,
|
|
47
|
+
useFeatureFlag,
|
|
48
|
+
} from './components/FeatureFlags';
|
|
49
|
+
*/
|
|
50
|
+
export {
|
|
51
|
+
Footer,
|
|
52
|
+
FooterExternal,
|
|
53
|
+
FooterMetaLink,
|
|
54
|
+
LinksColumn,
|
|
55
|
+
} from "./components/Footer";
|
|
56
|
+
|
|
57
|
+
export { default as Form } from "./components/Form";
|
|
58
|
+
//export { default as FormControls } from './components/FormControls';
|
|
59
|
+
//export { default as FormError } from './components/FormError';
|
|
60
|
+
export { default as FormGroup } from "./components/FormGroup";
|
|
61
|
+
export { default as FormHint } from "./components/FormHint";
|
|
62
|
+
export { default as FormItem } from "./components/FormItem";
|
|
63
|
+
export { default as FormLabel } from "./components/FormLabel";
|
|
64
|
+
//export { default as FormWizard } from './components/FormWizard';
|
|
65
|
+
//export { default as Icon } from './components/Icon/index.ts.legacy';
|
|
66
|
+
export { default as InfoBar } from "./components/InfoBar";
|
|
67
|
+
export { default as Link } from "./components/Link";
|
|
68
|
+
export { default as Loading } from "./components/Loading";
|
|
69
|
+
export {
|
|
70
|
+
default as Input,
|
|
71
|
+
useInput,
|
|
72
|
+
Label,
|
|
73
|
+
InlineErrorMessage,
|
|
74
|
+
Helper,
|
|
75
|
+
AddonBefore,
|
|
76
|
+
AddonAfter,
|
|
77
|
+
} from "./components/Input";
|
|
78
|
+
export { default as InlineLoading } from "./components/InlineLoading";
|
|
79
|
+
export { List, ListItem } from "./components/List";
|
|
80
|
+
export {
|
|
81
|
+
MainNavigation,
|
|
82
|
+
MainNavigationContext,
|
|
83
|
+
MainNavigationExternal,
|
|
84
|
+
useMainNavigation,
|
|
85
|
+
} from "./components/MainNavigation";
|
|
86
|
+
export { default as MainNavigationItem } from "./components/MainNavigationItem";
|
|
87
|
+
export {
|
|
88
|
+
SubNavigation,
|
|
89
|
+
SubNavigationHeader,
|
|
90
|
+
SubNavigationTitle,
|
|
91
|
+
SubNavigationLink,
|
|
92
|
+
SubNavigationFilter,
|
|
93
|
+
SubNavigationContent,
|
|
94
|
+
SubNavigationList,
|
|
95
|
+
SubNavigationGroup,
|
|
96
|
+
SubNavigationItem,
|
|
97
|
+
} from "./components/SubNavigation";
|
|
98
|
+
export { default as mdxComponents } from "./components/MdxComponents";
|
|
99
|
+
export { default as Modal, ModalFooter } from "./components/Modal";
|
|
100
|
+
export { default as ModalWrapper } from "./components/ModalWrapper";
|
|
101
|
+
export {
|
|
102
|
+
Module,
|
|
103
|
+
ModuleBody,
|
|
104
|
+
ModuleHeader,
|
|
105
|
+
ModuleFooter,
|
|
106
|
+
} from "./components/Module";
|
|
107
|
+
// export notificationStyle from './components/Notification/Notification.legacy';
|
|
108
|
+
export {
|
|
109
|
+
ToastNotification,
|
|
110
|
+
// InlineNotification,
|
|
111
|
+
NotificationActionButton,
|
|
112
|
+
NotificationButton,
|
|
113
|
+
NotificationTextDetails,
|
|
114
|
+
Callout,
|
|
115
|
+
} from "./components/Notification";
|
|
116
|
+
|
|
117
|
+
// Legacy export for backwards compatibility
|
|
118
|
+
export { Callout as BlockNotification } from "./components/Notification";
|
|
119
|
+
export { default as NumberInput } from "./components/NumberInput";
|
|
120
|
+
export { default as Pagination } from "./components/Pagination";
|
|
121
|
+
export { default as RadioButton } from "./components/RadioButton";
|
|
122
|
+
export { default as InputGroup } from "./components/InputGroup";
|
|
123
|
+
// export { default as RadioButtonGroup } from "./components/RadioButtonGroup";
|
|
124
|
+
export { default as ReadMore } from "./components/ReadMore";
|
|
125
|
+
//export { default as ReduxFormWrapper } from './components/ReduxFormWrapper';
|
|
126
|
+
export { default as Search } from "./components/Search";
|
|
127
|
+
export {
|
|
128
|
+
SecondaryNavigation,
|
|
129
|
+
SecondaryNavigationTitle,
|
|
130
|
+
} from "./components/SecondaryNavigation";
|
|
131
|
+
export { default as StepNavigation } from "./components/StepNavigation";
|
|
132
|
+
export { default as StepNavigationItem } from "./components/StepNavigationItem";
|
|
133
|
+
export { default as Select } from "./components/Select";
|
|
134
|
+
export { default as SelectItem } from "./components/SelectItem";
|
|
135
|
+
export { default as SelectItemGroup } from "./components/SelectItemGroup";
|
|
136
|
+
export {
|
|
137
|
+
Sidebar,
|
|
138
|
+
SidebarHeader,
|
|
139
|
+
SidebarScroll,
|
|
140
|
+
SidebarContentHeader,
|
|
141
|
+
SidebarContentBody,
|
|
142
|
+
SidebarBackButton,
|
|
143
|
+
} from "./components/Sidebar";
|
|
144
|
+
//export { default as Switch } from './components/Switch';
|
|
145
|
+
export { default as Slider } from "./components/Slider";
|
|
146
|
+
export { default as Story } from "./components/Story";
|
|
147
|
+
export { default as Item } from "./components/Item";
|
|
148
|
+
export { default as Table, TableSorting } from "./components/Table";
|
|
149
|
+
export { default as TablePagination } from "./components/TablePagination";
|
|
150
|
+
export { default as Tab, useTab } from "./components/Tab";
|
|
151
|
+
export { default as TabContent } from "./components/TabContent";
|
|
152
|
+
export { default as Tabs } from "./components/Tabs";
|
|
153
|
+
export { default as Tag } from "./components/Tag";
|
|
154
|
+
export { default as Text } from "./components/Text";
|
|
155
|
+
export { default as TextArea } from "./components/TextArea";
|
|
156
|
+
export { default as TextInput } from "./components/TextInput";
|
|
157
|
+
export {
|
|
158
|
+
default as Tooltip,
|
|
159
|
+
tooltipStyle,
|
|
160
|
+
tooltipStyleDark,
|
|
161
|
+
} from "./components/Tooltip";
|
|
162
|
+
export { default as Toggle } from "./components/Toggle";
|
|
163
|
+
export { default as User } from "./components/User";
|
|
164
|
+
export { default as Unit } from "./components/Unit";
|
|
165
|
+
export { default as Value } from "./components/Value";
|
|
166
|
+
export { default as Wrapper, pageWidths } from "./components/Wrapper";
|
|
167
|
+
//export { default as Grid } from './components/Grid';
|
|
168
|
+
//export { default as Col } from './components/Col';
|
|
169
|
+
|
|
170
|
+
// export { default as useDetectPrint } from './internal/useDetectPrint.js.legacy';
|
|
171
|
+
export { uniqueId } from "./tools/uniqueId";
|
|
172
|
+
export {
|
|
173
|
+
WFPCoreProvider,
|
|
174
|
+
WFPCoreContext,
|
|
175
|
+
withWFPCoreSettings,
|
|
176
|
+
useTheme,
|
|
177
|
+
defaultWFPContext,
|
|
178
|
+
} from "./components/WFPCoreSettings";
|
|
179
|
+
|
|
180
|
+
export { default as SkeletonText } from "./components/SkeletonText";
|
|
181
|
+
|
|
182
|
+
export { default as colors } from "./globals/data/colors";
|
|
183
|
+
|
|
184
|
+
export { useMediaQuery } from "./hooks/useMediaQuery";
|
|
185
|
+
export { useIsomorphicLayoutEffect } from "./hooks/useIsomorphicLayoutEffect";
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
export * as Accordion from "./components/Accordion/Accordion.stories.tsx";
|
|
2
|
+
export * as Avatar from "./components/Avatar/Avatar.stories.tsx";
|
|
3
|
+
export * as BannerNavigation from "./components/BannerNavigation/BannerNavigation.stories.tsx";
|
|
4
|
+
export * as Breadcrumb from "./components/Breadcrumb/Breadcrumb.stories.tsx";
|
|
5
|
+
export * as Button from "./components/Button/Button.stories.tsx";
|
|
6
|
+
export * as Card from "./components/Card/Card.stories.tsx";
|
|
7
|
+
export * as Checkbox from "./components/Checkbox/Checkbox.stories.tsx";
|
|
8
|
+
export * as ContentSwitcher from "./components/ContentSwitcher/ContentSwitcher.stories.tsx";
|
|
9
|
+
export * as Credits from "./components/Credits/Credits.stories.tsx";
|
|
10
|
+
export * as DatePicker from "./components/DatePicker/DatePicker.stories.tsx";
|
|
11
|
+
export * as Empty from "./components/Empty/Empty.stories.tsx";
|
|
12
|
+
export * as Footer from "./components/Footer/Footer.stories.tsx";
|
|
13
|
+
export * as Form from "./components/Form/Form.stories.tsx";
|
|
14
|
+
export * as FormLabel from "./components/FormLabel/FormLabel.stories.tsx";
|
|
15
|
+
export * as InfoBar from "./components/InfoBar/InfoBar.stories.tsx";
|
|
16
|
+
export * as InlineLoading from "./components/InlineLoading/InlineLoading.stories.tsx";
|
|
17
|
+
export * as Input from "./components/Input/Input.stories.tsx";
|
|
18
|
+
export * as Item from "./components/Item/Item.stories.tsx";
|
|
19
|
+
export * as Link from "./components/Link/Link.stories.tsx";
|
|
20
|
+
export * as List from "./components/List/List.stories.tsx";
|
|
21
|
+
export * as Loading from "./components/Loading/Loading.stories.tsx";
|
|
22
|
+
export * as MainNavigation from "./components/MainNavigation/MainNavigation.stories.tsx";
|
|
23
|
+
export * as Modal from "./components/Modal/Modal.stories.tsx";
|
|
24
|
+
export * as ModalWrapper from "./components/ModalWrapper/ModalWrapper.stories.tsx";
|
|
25
|
+
export * as Module from "./components/Module/Module.stories.tsx";
|
|
26
|
+
export * as Notification from "./components/Notification/Notification.stories.tsx";
|
|
27
|
+
export * as NumberInput from "./components/NumberInput/NumberInput.stories.tsx";
|
|
28
|
+
export * as Pagination from "./components/Pagination/Pagination.stories.tsx";
|
|
29
|
+
export * as RadioButton from "./components/RadioButton/RadioButton.stories.tsx";
|
|
30
|
+
export * as ReadMore from "./components/ReadMore/ReadMore.stories.tsx";
|
|
31
|
+
export * as Search from "./components/Search/Search.stories.tsx";
|
|
32
|
+
export * as SecondaryNavigation from "./components/SecondaryNavigation/SecondaryNavigation.stories.tsx";
|
|
33
|
+
export * as Select from "./components/Select/Select.stories.tsx";
|
|
34
|
+
export * as Slider from "./components/Slider/Slider.stories.tsx";
|
|
35
|
+
export * as StepNavigation from "./components/StepNavigation/StepNavigation.stories.tsx";
|
|
36
|
+
export * as Story from "./components/Story/Story.stories.tsx";
|
|
37
|
+
export * as Tabs from "./components/Tabs/Tabs.stories.tsx";
|
|
38
|
+
export * as TextArea from "./components/TextArea/TextArea.stories.tsx";
|
|
39
|
+
export * as TextInput from "./components/TextInput/TextInput.stories.tsx";
|
|
40
|
+
export * as Text from "./components/Text/Text.stories.tsx";
|
|
41
|
+
export * as Tooltip from "./components/Tooltip/Tooltip.stories.tsx";
|
|
42
|
+
export * as Toggle from "./components/Toggle/Toggle.stories.tsx";
|
|
43
|
+
export * as User from "./components/User/User.stories.tsx";
|
|
44
|
+
export * as Wrapper from "./components/Wrapper/Wrapper.stories.tsx";
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file contains the list of the default values of compile-time feature flags.
|
|
3
|
+
*
|
|
4
|
+
* Build toolchain can replace variable here and/or the references
|
|
5
|
+
* in order to apply non-default values to those feature flags.
|
|
6
|
+
*
|
|
7
|
+
* @example Render `foo` if `aFeatureFlag` is `true`, render `bar` otherwise.
|
|
8
|
+
* import { aFeatureFlag } from '/path/to/FeatureFlags';
|
|
9
|
+
* ...
|
|
10
|
+
* const MyComponent = props => (<div {...props}>{aFeatureFlag ? 'foo' : 'bar'}</div>);
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* Next gen of Carbon component design.
|
|
15
|
+
*/
|
|
16
|
+
export const componentsX = false;
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* Support for prop -> state sync of `<Slider>` value.
|
|
20
|
+
*/
|
|
21
|
+
export const sliderValuePropSync = false;
|
|
@@ -0,0 +1,352 @@
|
|
|
1
|
+
import warning from 'warning';
|
|
2
|
+
import PropTypes from 'prop-types';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import ReactDOM from 'react-dom';
|
|
5
|
+
import window from 'window-or-global';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* The structure for the position of floating menu.
|
|
9
|
+
* @typedef {Object} FloatingMenu~position
|
|
10
|
+
* @property {number} left The left position.
|
|
11
|
+
* @property {number} top The top position.
|
|
12
|
+
* @property {number} right The right position.
|
|
13
|
+
* @property {number} bottom The bottom position.
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* The structure for the size of floating menu.
|
|
18
|
+
* @typedef {Object} FloatingMenu~size
|
|
19
|
+
* @property {number} width The width.
|
|
20
|
+
* @property {number} height The height.
|
|
21
|
+
*/
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* The structure for the position offset of floating menu.
|
|
25
|
+
* @typedef {Object} FloatingMenu~offset
|
|
26
|
+
* @property {number} top The top position.
|
|
27
|
+
* @property {number} left The left position.
|
|
28
|
+
*/
|
|
29
|
+
|
|
30
|
+
export const DIRECTION_LEFT = 'left';
|
|
31
|
+
export const DIRECTION_TOP = 'top';
|
|
32
|
+
export const DIRECTION_RIGHT = 'right';
|
|
33
|
+
export const DIRECTION_BOTTOM = 'bottom';
|
|
34
|
+
|
|
35
|
+
const hasCreatePortal = typeof ReactDOM.createPortal === 'function';
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* @param {FloatingMenu~offset} [oldMenuOffset={}] The old value.
|
|
39
|
+
* @param {FloatingMenu~offset} [menuOffset={}] The new value.
|
|
40
|
+
* @returns `true` if the parent component wants to change in the adjustment of the floating menu position.
|
|
41
|
+
* @private
|
|
42
|
+
*/
|
|
43
|
+
const hasChangeInOffset = (oldMenuOffset = {}, menuOffset = {}) => {
|
|
44
|
+
if (typeof oldMenuOffset !== typeof menuOffset) {
|
|
45
|
+
return true;
|
|
46
|
+
} else if (
|
|
47
|
+
Object(menuOffset) === menuOffset &&
|
|
48
|
+
typeof menuOffset !== 'function'
|
|
49
|
+
) {
|
|
50
|
+
return (
|
|
51
|
+
oldMenuOffset.top !== menuOffset.top ||
|
|
52
|
+
oldMenuOffset.left !== menuOffset.left
|
|
53
|
+
);
|
|
54
|
+
}
|
|
55
|
+
return oldMenuOffset !== menuOffset;
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* @param {Object} params The parameters.
|
|
60
|
+
* @param {FloatingMenu~size} params.menuSize The size of the menu.
|
|
61
|
+
* @param {FloatingMenu~position} params.refPosition The position of the triggering element.
|
|
62
|
+
* @param {FloatingMenu~offset} [params.offset={ left: 0, top: 0 }] The position offset of the menu.
|
|
63
|
+
* @param {string} [params.direction=bottom] The menu direction.
|
|
64
|
+
* @param {number} [params.scrollY=0] The scroll position of the viewport.
|
|
65
|
+
* @returns {FloatingMenu~offset} The position of the menu, relative to the top-left corner of the viewport.
|
|
66
|
+
* @private
|
|
67
|
+
*/
|
|
68
|
+
const getFloatingPosition = ({
|
|
69
|
+
menuSize,
|
|
70
|
+
refPosition,
|
|
71
|
+
offset = {},
|
|
72
|
+
direction = DIRECTION_BOTTOM,
|
|
73
|
+
scrollY = 0,
|
|
74
|
+
}) => {
|
|
75
|
+
const {
|
|
76
|
+
left: refLeft = 0,
|
|
77
|
+
top: refTop = 0,
|
|
78
|
+
right: refRight = 0,
|
|
79
|
+
bottom: refBottom = 0,
|
|
80
|
+
} = refPosition;
|
|
81
|
+
|
|
82
|
+
const { width, height } = menuSize;
|
|
83
|
+
const { top = 0, left = 0 } = offset;
|
|
84
|
+
const refCenterHorizontal = (refLeft + refRight) / 2;
|
|
85
|
+
const refCenterVertical = (refTop + refBottom) / 2;
|
|
86
|
+
|
|
87
|
+
return {
|
|
88
|
+
[DIRECTION_LEFT]: () => ({
|
|
89
|
+
left: refLeft - width - left,
|
|
90
|
+
top: refCenterVertical - height / 2 + scrollY + top,
|
|
91
|
+
}),
|
|
92
|
+
[DIRECTION_TOP]: () => ({
|
|
93
|
+
left: refCenterHorizontal - width / 2 + left,
|
|
94
|
+
top: refTop - height + scrollY - top,
|
|
95
|
+
}),
|
|
96
|
+
[DIRECTION_RIGHT]: () => ({
|
|
97
|
+
left: refRight + left,
|
|
98
|
+
top: refCenterVertical - height / 2 + scrollY + top,
|
|
99
|
+
}),
|
|
100
|
+
[DIRECTION_BOTTOM]: () => ({
|
|
101
|
+
left: refCenterHorizontal - width / 2 + left,
|
|
102
|
+
top: refBottom + scrollY + top,
|
|
103
|
+
}),
|
|
104
|
+
}[direction]();
|
|
105
|
+
};
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* A menu that is detached from the triggering element.
|
|
109
|
+
* Useful when the container of the triggering element cannot have `overflow:visible` style, etc.
|
|
110
|
+
*/
|
|
111
|
+
class FloatingMenu extends React.Component {
|
|
112
|
+
static propTypes = {
|
|
113
|
+
/**
|
|
114
|
+
* Contents to put into the floating menu.
|
|
115
|
+
*/
|
|
116
|
+
children: PropTypes.object,
|
|
117
|
+
|
|
118
|
+
/**
|
|
119
|
+
* The position in the viewport of the trigger button.
|
|
120
|
+
*/
|
|
121
|
+
menuPosition: PropTypes.shape({
|
|
122
|
+
top: PropTypes.number,
|
|
123
|
+
right: PropTypes.number,
|
|
124
|
+
bottom: PropTypes.number,
|
|
125
|
+
left: PropTypes.number,
|
|
126
|
+
}),
|
|
127
|
+
|
|
128
|
+
/**
|
|
129
|
+
* Where to put the tooltip, relative to the trigger button.
|
|
130
|
+
*/
|
|
131
|
+
menuDirection: PropTypes.oneOf([
|
|
132
|
+
DIRECTION_LEFT,
|
|
133
|
+
DIRECTION_TOP,
|
|
134
|
+
DIRECTION_RIGHT,
|
|
135
|
+
DIRECTION_BOTTOM,
|
|
136
|
+
]),
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* The adjustment of the floating menu position, considering the position of dropdown arrow, etc.
|
|
140
|
+
*/
|
|
141
|
+
menuOffset: PropTypes.oneOfType([
|
|
142
|
+
PropTypes.shape({
|
|
143
|
+
top: PropTypes.number,
|
|
144
|
+
left: PropTypes.number,
|
|
145
|
+
}),
|
|
146
|
+
PropTypes.func,
|
|
147
|
+
]),
|
|
148
|
+
|
|
149
|
+
/**
|
|
150
|
+
* The additional styles to put to the floating menu.
|
|
151
|
+
*/
|
|
152
|
+
styles: PropTypes.object,
|
|
153
|
+
|
|
154
|
+
/**
|
|
155
|
+
* The callback called when the menu body has been mounted to/will be unmounted from the DOM.
|
|
156
|
+
*/
|
|
157
|
+
menuRef: PropTypes.func,
|
|
158
|
+
};
|
|
159
|
+
|
|
160
|
+
static defaultProps = {
|
|
161
|
+
menuPosition: {},
|
|
162
|
+
menuOffset: {},
|
|
163
|
+
menuDirection: DIRECTION_BOTTOM,
|
|
164
|
+
};
|
|
165
|
+
|
|
166
|
+
state = {
|
|
167
|
+
/**
|
|
168
|
+
* The position of the menu, relative to the top-left corner of the viewport.
|
|
169
|
+
* @type {FloatingMenu~offset}
|
|
170
|
+
*/
|
|
171
|
+
floatingPosition: undefined,
|
|
172
|
+
};
|
|
173
|
+
|
|
174
|
+
/**
|
|
175
|
+
* The cached refernce to the menu container.
|
|
176
|
+
* Only used if React portal API is not available.
|
|
177
|
+
* @type {Element}
|
|
178
|
+
* @private
|
|
179
|
+
*/
|
|
180
|
+
_menuContainer = null;
|
|
181
|
+
|
|
182
|
+
/**
|
|
183
|
+
* The cached refernce to the menu body.
|
|
184
|
+
* @type {Element}
|
|
185
|
+
* @private
|
|
186
|
+
*/
|
|
187
|
+
_menuBody = null;
|
|
188
|
+
|
|
189
|
+
constructor(props) {
|
|
190
|
+
super(props);
|
|
191
|
+
if (typeof document !== 'undefined' && hasCreatePortal) {
|
|
192
|
+
this.el = document.createElement('div');
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
/**
|
|
197
|
+
* Calculates the position in the viewport of floating menu,
|
|
198
|
+
* once this component is mounted or updated upon change in the following props:
|
|
199
|
+
*
|
|
200
|
+
* * `menuPosition` (The position in the viewport of the trigger button)
|
|
201
|
+
* * `menuOffset` (The adjustment that should be applied to the calculated floating menu's position)
|
|
202
|
+
* * `menuDirection` (Where the floating menu menu should be placed relative to the trigger button)
|
|
203
|
+
*
|
|
204
|
+
* @private
|
|
205
|
+
*/
|
|
206
|
+
_updateMenuSize = (prevProps = {}) => {
|
|
207
|
+
const menuBody = this._menuBody;
|
|
208
|
+
warning(
|
|
209
|
+
menuBody,
|
|
210
|
+
'The DOM node for menu body for calculating its position is not available. Skipping...'
|
|
211
|
+
);
|
|
212
|
+
if (!menuBody) {
|
|
213
|
+
return;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
const {
|
|
217
|
+
menuPosition: oldRefPosition = {},
|
|
218
|
+
menuOffset: oldMenuOffset = {},
|
|
219
|
+
menuDirection: oldMenuDirection,
|
|
220
|
+
} = prevProps;
|
|
221
|
+
const {
|
|
222
|
+
menuPosition: refPosition = {},
|
|
223
|
+
menuOffset = {},
|
|
224
|
+
menuDirection,
|
|
225
|
+
} = this.props;
|
|
226
|
+
|
|
227
|
+
if (
|
|
228
|
+
oldRefPosition.top !== refPosition.top ||
|
|
229
|
+
oldRefPosition.right !== refPosition.right ||
|
|
230
|
+
oldRefPosition.bottom !== refPosition.bottom ||
|
|
231
|
+
oldRefPosition.left !== refPosition.left ||
|
|
232
|
+
hasChangeInOffset(oldMenuOffset, menuOffset) ||
|
|
233
|
+
oldMenuDirection !== menuDirection
|
|
234
|
+
) {
|
|
235
|
+
const menuSize = menuBody.getBoundingClientRect();
|
|
236
|
+
const offset =
|
|
237
|
+
typeof menuOffset !== 'function'
|
|
238
|
+
? menuOffset
|
|
239
|
+
: menuOffset(menuBody, menuDirection);
|
|
240
|
+
// Skips if either in the following condition:
|
|
241
|
+
// a) Menu body has `display:none`
|
|
242
|
+
// b) `menuOffset` as a callback returns `undefined` (The callback saw that it couldn't calculate the value)
|
|
243
|
+
if ((menuSize.width > 0 && menuSize.height > 0) || !offset) {
|
|
244
|
+
this.setState({
|
|
245
|
+
floatingPosition: getFloatingPosition({
|
|
246
|
+
menuSize,
|
|
247
|
+
refPosition,
|
|
248
|
+
direction: menuDirection,
|
|
249
|
+
offset,
|
|
250
|
+
scrollY: window.scrollY,
|
|
251
|
+
}),
|
|
252
|
+
});
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
};
|
|
256
|
+
|
|
257
|
+
componentDidUpdate(prevProps) {
|
|
258
|
+
if (!hasCreatePortal) {
|
|
259
|
+
ReactDOM.render(this._getChildrenWithProps(), this._menuContainer);
|
|
260
|
+
} else {
|
|
261
|
+
this._updateMenuSize(prevProps);
|
|
262
|
+
}
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
componentDidMount() {
|
|
266
|
+
const { menuRef } = this.props;
|
|
267
|
+
if (!hasCreatePortal) {
|
|
268
|
+
this._menuContainer = document.createElement('div');
|
|
269
|
+
document.body.appendChild(this._menuContainer);
|
|
270
|
+
const style = {
|
|
271
|
+
display: 'block',
|
|
272
|
+
opacity: 0,
|
|
273
|
+
};
|
|
274
|
+
const childrenWithProps = React.cloneElement(this.props.children, {
|
|
275
|
+
style,
|
|
276
|
+
});
|
|
277
|
+
ReactDOM.render(childrenWithProps, this._menuContainer, () => {
|
|
278
|
+
this._menuBody = this._menuContainer.firstChild;
|
|
279
|
+
this._updateMenuSize();
|
|
280
|
+
ReactDOM.render(
|
|
281
|
+
this._getChildrenWithProps(),
|
|
282
|
+
this._menuContainer,
|
|
283
|
+
() => {
|
|
284
|
+
menuRef && menuRef(this._menuBody);
|
|
285
|
+
}
|
|
286
|
+
);
|
|
287
|
+
});
|
|
288
|
+
} else {
|
|
289
|
+
if (this.el && this.el.firstChild) {
|
|
290
|
+
this._menuBody = this.el.firstChild;
|
|
291
|
+
document.body.appendChild(this._menuBody);
|
|
292
|
+
menuRef && menuRef(this._menuBody);
|
|
293
|
+
}
|
|
294
|
+
this._updateMenuSize();
|
|
295
|
+
}
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
componentWillUnmount() {
|
|
299
|
+
const { menuRef } = this.props;
|
|
300
|
+
menuRef && menuRef(null);
|
|
301
|
+
if (!hasCreatePortal) {
|
|
302
|
+
const menuContainer = this._menuContainer;
|
|
303
|
+
ReactDOM.unmountComponentAtNode(menuContainer);
|
|
304
|
+
if (menuContainer && menuContainer.parentNode) {
|
|
305
|
+
menuContainer.parentNode.removeChild(menuContainer);
|
|
306
|
+
}
|
|
307
|
+
this._menuContainer = null;
|
|
308
|
+
} else if (this._menuBody) {
|
|
309
|
+
// Moves the menu body back to the portal container so that React unmount code does not crash
|
|
310
|
+
this.el.appendChild(this._menuBody);
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
/**
|
|
315
|
+
* @returns The child nodes, with styles containing the floating menu position.
|
|
316
|
+
* @private
|
|
317
|
+
*/
|
|
318
|
+
_getChildrenWithProps = () => {
|
|
319
|
+
const { styles, children } = this.props;
|
|
320
|
+
const { floatingPosition: pos } = this.state;
|
|
321
|
+
// If no pos available, we need to hide the element (offscreen to the left)
|
|
322
|
+
// This is done so we can measure the content before positioning it correctly.
|
|
323
|
+
const positioningStyle = pos
|
|
324
|
+
? {
|
|
325
|
+
left: `${pos.left}px`,
|
|
326
|
+
top: `${pos.top}px`,
|
|
327
|
+
right: 'auto',
|
|
328
|
+
}
|
|
329
|
+
: {
|
|
330
|
+
left: `${window.innerWidth}px`,
|
|
331
|
+
top: '0px',
|
|
332
|
+
};
|
|
333
|
+
return React.cloneElement(children, {
|
|
334
|
+
style: {
|
|
335
|
+
...styles,
|
|
336
|
+
...positioningStyle,
|
|
337
|
+
position: 'absolute',
|
|
338
|
+
margin: 0,
|
|
339
|
+
opacity: 1,
|
|
340
|
+
},
|
|
341
|
+
});
|
|
342
|
+
};
|
|
343
|
+
|
|
344
|
+
render() {
|
|
345
|
+
if (typeof document !== 'undefined' && hasCreatePortal) {
|
|
346
|
+
return ReactDOM.createPortal(this._getChildrenWithProps(), this.el);
|
|
347
|
+
}
|
|
348
|
+
return null;
|
|
349
|
+
}
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
export default FloatingMenu;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
// mdn resize function
|
|
2
|
+
import window from 'window-or-global';
|
|
3
|
+
|
|
4
|
+
const OptimizedResize = (function optimizedResize() {
|
|
5
|
+
const callbacks = [];
|
|
6
|
+
let running = false;
|
|
7
|
+
|
|
8
|
+
// run the actual callbacks
|
|
9
|
+
function runCallbacks() {
|
|
10
|
+
callbacks.forEach(callback => {
|
|
11
|
+
callback();
|
|
12
|
+
});
|
|
13
|
+
|
|
14
|
+
running = false;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
// fired on resize event
|
|
18
|
+
function resize() {
|
|
19
|
+
if (!running) {
|
|
20
|
+
running = true;
|
|
21
|
+
window.requestAnimationFrame(runCallbacks);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
// adds callback to loop
|
|
26
|
+
function addCallback(callback) {
|
|
27
|
+
if (callback) {
|
|
28
|
+
const index = callbacks.indexOf(callback);
|
|
29
|
+
if (index < 0) {
|
|
30
|
+
callbacks.push(callback);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
return {
|
|
36
|
+
// public method to add additional callback
|
|
37
|
+
add: callback => {
|
|
38
|
+
if (!callbacks.length) {
|
|
39
|
+
window.addEventListener('resize', resize);
|
|
40
|
+
}
|
|
41
|
+
addCallback(callback);
|
|
42
|
+
return {
|
|
43
|
+
release() {
|
|
44
|
+
const index = callbacks.indexOf(callback);
|
|
45
|
+
if (index >= 0) {
|
|
46
|
+
callbacks.splice(index, 1);
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
};
|
|
50
|
+
},
|
|
51
|
+
};
|
|
52
|
+
})();
|
|
53
|
+
|
|
54
|
+
export default OptimizedResize;
|