@decisiv/ui-components 2.0.1-alpha.20 → 2.0.1-alpha.201
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/lib/atoms/BaseButton/index.d.ts.map +1 -1
- package/lib/atoms/BaseButton/index.js +1 -1
- package/lib/atoms/BooleanInput/elements.d.ts.map +1 -1
- package/lib/atoms/BooleanInput/elements.js +8 -3
- package/lib/atoms/BooleanInput/index.d.ts.map +1 -1
- package/lib/atoms/BooleanInput/index.js +26 -5
- package/lib/atoms/BooleanInput/index.test.js +17 -6
- package/lib/atoms/BooleanInput/types.d.ts +4 -0
- package/lib/atoms/BooleanInput/types.d.ts.map +1 -1
- package/lib/atoms/BooleanInput/types.js +5 -1
- package/lib/atoms/Calendar/hooks/useCalendar/index.d.ts.map +1 -1
- package/lib/atoms/Calendar/hooks/useCalendar/index.js +2 -1
- package/lib/atoms/Calendar/hooks/useCalendar/index.test.js +5 -6
- package/lib/atoms/Calendar/index.d.ts.map +1 -1
- package/lib/atoms/Calendar/index.js +46 -6
- package/lib/atoms/Calendar/index.test.js +68 -38
- package/lib/atoms/Calendar/types.d.ts +1 -1
- package/lib/atoms/Calendar/types.d.ts.map +1 -1
- package/lib/atoms/Calendar/types.js +5 -1
- package/lib/atoms/InputField/Containers.d.ts +12 -6
- package/lib/atoms/InputField/Containers.d.ts.map +1 -1
- package/lib/atoms/InputField/Containers.js +8 -6
- package/lib/atoms/InputField/HelpMessage.d.ts +1 -1
- package/lib/atoms/InputField/HelpMessage.d.ts.map +1 -1
- package/lib/atoms/InputField/HelpMessage.js +2 -1
- package/lib/atoms/InputField/InputLabel.d.ts +1 -0
- package/lib/atoms/InputField/InputLabel.d.ts.map +1 -1
- package/lib/atoms/InputField/InputLabel.js +2 -1
- package/lib/atoms/InputField/index.d.ts +8 -1
- package/lib/atoms/InputField/index.d.ts.map +1 -1
- package/lib/atoms/InputField/index.js +27 -9
- package/lib/atoms/InputField/index.test.js +91 -0
- package/lib/atoms/InputField/schema.d.ts.map +1 -1
- package/lib/atoms/InputField/schema.js +3 -2
- package/lib/atoms/OptionsList/Category/index.d.ts +4 -0
- package/lib/atoms/OptionsList/Category/index.d.ts.map +1 -0
- package/lib/atoms/OptionsList/{Category.js → Category/index.js} +13 -21
- package/lib/atoms/OptionsList/Category/styles.d.ts +6 -0
- package/lib/atoms/OptionsList/Category/styles.d.ts.map +1 -0
- package/lib/atoms/OptionsList/Category/styles.js +36 -0
- package/lib/atoms/OptionsList/{Option.d.ts → Option/index.d.ts} +2 -2
- package/lib/atoms/OptionsList/Option/index.d.ts.map +1 -0
- package/lib/atoms/OptionsList/Option/index.js +169 -0
- package/lib/atoms/OptionsList/Option/styles.d.ts +17 -0
- package/lib/atoms/OptionsList/Option/styles.d.ts.map +1 -0
- package/lib/atoms/OptionsList/Option/styles.js +83 -0
- package/lib/atoms/OptionsList/index.d.ts.map +1 -1
- package/lib/atoms/OptionsList/index.js +16 -7
- package/lib/atoms/OptionsList/index.test.js +249 -156
- package/lib/atoms/OptionsList/schema.d.ts.map +1 -1
- package/lib/atoms/OptionsList/schema.js +3 -1
- package/lib/atoms/OptionsList/types.d.ts +23 -0
- package/lib/atoms/OptionsList/types.d.ts.map +1 -1
- package/lib/atoms/OptionsList/types.js +5 -1
- package/lib/atoms/RequiredIcon.d.ts +9 -0
- package/lib/atoms/RequiredIcon.d.ts.map +1 -0
- package/lib/atoms/{InputField/RequiredIcon.js → RequiredIcon.js} +7 -3
- package/lib/components/Accordion/types.js +5 -1
- package/lib/components/Accordion/useAccordion/types.js +5 -1
- package/lib/components/Alert/Container.d.ts +201 -0
- package/lib/components/Alert/Container.d.ts.map +1 -0
- package/lib/components/Alert/Container.js +26 -0
- package/lib/components/Alert/StyledButton.d.ts +5 -0
- package/lib/components/Alert/StyledButton.d.ts.map +1 -0
- package/lib/components/Alert/StyledButton.js +23 -0
- package/lib/components/Alert/index.d.ts +27 -0
- package/lib/components/Alert/index.d.ts.map +1 -0
- package/lib/components/Alert/index.js +112 -0
- package/lib/components/Alert/index.test.js +79 -0
- package/lib/components/Alert/intents.d.ts +13 -0
- package/lib/components/Alert/intents.d.ts.map +1 -0
- package/lib/components/Alert/intents.js +72 -0
- package/lib/components/{Tabs/schema.tab.d.ts → Alert/schema.d.ts} +1 -1
- package/lib/components/Alert/schema.d.ts.map +1 -0
- package/lib/components/Alert/schema.js +25 -0
- package/lib/components/Alert/types.d.ts +36 -0
- package/lib/components/Alert/types.d.ts.map +1 -0
- package/lib/components/Alert/types.js +32 -0
- package/lib/components/Avatar/AvatarContainer.d.ts +1 -13
- package/lib/components/Avatar/AvatarContainer.d.ts.map +1 -1
- package/lib/components/Avatar/AvatarContainer.js +12 -13
- package/lib/components/Avatar/AvatarContent.d.ts +2 -2
- package/lib/components/Avatar/AvatarContent.d.ts.map +1 -1
- package/lib/components/Avatar/AvatarContent.js +24 -20
- package/lib/components/Avatar/index.d.ts.map +1 -1
- package/lib/components/Avatar/index.js +39 -5
- package/lib/components/Avatar/index.test.js +4 -0
- package/lib/components/Avatar/schema.d.ts.map +1 -1
- package/lib/components/Avatar/schema.js +3 -1
- package/lib/components/Avatar/types.d.ts +15 -2
- package/lib/components/Avatar/types.d.ts.map +1 -1
- package/lib/components/Avatar/types.js +5 -1
- package/lib/components/Badge/constants.d.ts +2 -0
- package/lib/components/Badge/constants.d.ts.map +1 -0
- package/lib/components/Badge/constants.js +29 -0
- package/lib/components/Badge/index.d.ts.map +1 -1
- package/lib/components/Badge/index.js +3 -70
- package/lib/components/Badge/index.test.js +62 -8
- package/lib/components/Badge/schema.d.ts.map +1 -1
- package/lib/components/Badge/schema.js +2 -1
- package/lib/components/Badge/styles.d.ts +3 -0
- package/lib/components/Badge/styles.d.ts.map +1 -0
- package/lib/components/Badge/styles.js +96 -0
- package/lib/components/Badge/types.d.ts +3 -2
- package/lib/components/Badge/types.d.ts.map +1 -1
- package/lib/components/Badge/types.js +7 -3
- package/lib/components/Breadcrumbs/types.js +5 -1
- package/lib/components/Button/StyledButton.d.ts +3 -6
- package/lib/components/Button/StyledButton.d.ts.map +1 -1
- package/lib/components/Button/StyledButton.js +39 -11
- package/lib/components/Button/index.d.ts.map +1 -1
- package/lib/components/Button/index.js +51 -12
- package/lib/components/Button/index.test.js +43 -8
- package/lib/components/Button/schema.d.ts.map +1 -1
- package/lib/components/Button/schema.js +4 -1
- package/lib/components/Button/types.d.ts +4 -1
- package/lib/components/Button/types.d.ts.map +1 -1
- package/lib/components/Button/types.js +5 -1
- package/lib/components/Checkbox/index.d.ts.map +1 -1
- package/lib/components/Checkbox/index.js +3 -1
- package/lib/components/Checkbox/schema.d.ts.map +1 -1
- package/lib/components/Checkbox/schema.js +2 -0
- package/lib/components/CheckboxGroup/index.d.ts +1 -1
- package/lib/components/Combobox/Target.d.ts.map +1 -1
- package/lib/components/Combobox/Target.js +52 -14
- package/lib/components/Combobox/index.d.ts.map +1 -1
- package/lib/components/Combobox/index.js +217 -85
- package/lib/components/Combobox/index.test.js +370 -147
- package/lib/components/Combobox/schema.d.ts.map +1 -1
- package/lib/components/Combobox/schema.js +10 -2
- package/lib/components/Combobox/types.d.ts +12 -3
- package/lib/components/Combobox/types.d.ts.map +1 -1
- package/lib/components/Combobox/types.js +5 -1
- package/lib/components/Drawer/index.d.ts +22 -0
- package/lib/components/Drawer/index.d.ts.map +1 -0
- package/lib/components/Drawer/index.js +115 -0
- package/lib/components/Drawer/index.test.js +139 -0
- package/lib/components/Drawer/schema.d.ts +3 -0
- package/lib/components/Drawer/schema.d.ts.map +1 -0
- package/lib/components/Drawer/schema.js +32 -0
- package/lib/components/Drawer/styles.d.ts +11 -0
- package/lib/components/Drawer/styles.d.ts.map +1 -0
- package/lib/components/Drawer/styles.js +79 -0
- package/lib/components/DropdownList/index.d.ts +1 -0
- package/lib/components/DropdownList/index.d.ts.map +1 -1
- package/lib/components/DropdownList/index.js +70 -22
- package/lib/components/DropdownList/propTypes.d.ts +4 -0
- package/lib/components/DropdownList/propTypes.d.ts.map +1 -0
- package/lib/components/DropdownList/propTypes.js +42 -0
- package/lib/components/DropdownList/schema.d.ts.map +1 -1
- package/lib/components/DropdownList/schema.js +2 -1
- package/lib/components/DropdownList/types.d.ts +2 -0
- package/lib/components/DropdownList/types.d.ts.map +1 -1
- package/lib/components/Filter/ActionFilter/index.d.ts +5 -0
- package/lib/components/Filter/ActionFilter/index.d.ts.map +1 -0
- package/lib/components/Filter/ActionFilter/index.js +43 -0
- package/lib/components/Filter/IconWrapper/index.d.ts +197 -0
- package/lib/components/Filter/IconWrapper/index.d.ts.map +1 -0
- package/lib/components/Filter/IconWrapper/index.js +35 -0
- package/lib/components/Filter/SimplePrimary/index.d.ts +5 -0
- package/lib/components/Filter/SimplePrimary/index.d.ts.map +1 -0
- package/lib/components/Filter/SimplePrimary/index.js +46 -0
- package/lib/components/Filter/SimplePrimary/index.test.js +34 -0
- package/lib/components/Filter/StyledFilter.d.ts +4 -0
- package/lib/components/Filter/StyledFilter.d.ts.map +1 -0
- package/lib/components/Filter/StyledFilter.js +66 -0
- package/lib/components/Filter/StyledLabel/index.d.ts +8 -0
- package/lib/components/Filter/StyledLabel/index.d.ts.map +1 -0
- package/lib/components/Filter/StyledLabel/index.js +38 -0
- package/lib/components/Filter/index.d.ts +6 -0
- package/lib/components/Filter/index.d.ts.map +1 -0
- package/lib/components/Filter/index.js +107 -0
- package/lib/components/Filter/index.test.js +70 -0
- package/lib/components/Filter/kind.d.ts +7 -0
- package/lib/components/Filter/kind.d.ts.map +1 -0
- package/lib/components/Filter/kind.js +43 -0
- package/lib/components/Filter/schema.d.ts +9 -0
- package/lib/components/Filter/schema.d.ts.map +1 -0
- package/lib/components/Filter/schema.js +37 -0
- package/lib/components/Filter/types.d.ts +31 -0
- package/lib/components/Filter/types.d.ts.map +1 -0
- package/lib/components/Filter/types.js +5 -0
- package/lib/components/JumpTo/JumpToMenu.d.ts +2 -2
- package/lib/components/JumpTo/JumpToMenu.d.ts.map +1 -1
- package/lib/components/JumpTo/JumpToMenu.js +53 -12
- package/lib/components/JumpTo/index.test.js +84 -0
- package/lib/components/JumpTo/schema.d.ts.map +1 -1
- package/lib/components/JumpTo/schema.js +2 -1
- package/lib/components/JumpTo/types.d.ts +1 -0
- package/lib/components/JumpTo/types.d.ts.map +1 -1
- package/lib/components/JumpTo/types.js +5 -1
- package/lib/components/JumpTo/utils.d.ts.map +1 -1
- package/lib/components/JumpTo/utils.js +3 -7
- package/lib/components/LeftNav/Item/ClickArea.js +1 -1
- package/lib/components/LeftNav/Item/ItemWrapper.d.ts.map +1 -1
- package/lib/components/LeftNav/Item/ItemWrapper.js +3 -1
- package/lib/components/LeftNav/Item/MenuItemWrapper.d.ts +7 -0
- package/lib/components/LeftNav/Item/MenuItemWrapper.d.ts.map +1 -0
- package/lib/components/LeftNav/Item/MenuItemWrapper.js +20 -0
- package/lib/components/LeftNav/Item/NavCollapsedXItem/index.d.ts.map +1 -1
- package/lib/components/LeftNav/Item/NavCollapsedXItem/index.js +7 -5
- package/lib/components/LeftNav/Item/NavExpandedItem/index.d.ts.map +1 -1
- package/lib/components/LeftNav/Item/NavExpandedItem/index.js +24 -13
- package/lib/components/LeftNav/Item/types.d.ts +1 -1
- package/lib/components/LeftNav/Item/types.d.ts.map +1 -1
- package/lib/components/LeftNav/Item/types.js +5 -1
- package/lib/components/LeftNav/index.test.js +13 -3
- package/lib/components/LeftNav/schema.d.ts.map +1 -1
- package/lib/components/LeftNav/schema.js +2 -0
- package/lib/components/LeftNav/types.d.ts +1 -0
- package/lib/components/LeftNav/types.d.ts.map +1 -1
- package/lib/components/LeftNav/types.js +5 -1
- package/lib/components/Link/DisabledLink.d.ts +7 -0
- package/lib/components/Link/DisabledLink.d.ts.map +1 -0
- package/lib/components/Link/DisabledLink.js +46 -0
- package/lib/components/Link/Link.d.ts +4 -0
- package/lib/components/Link/Link.d.ts.map +1 -0
- package/lib/components/Link/Link.js +67 -0
- package/lib/components/Link/index.d.ts +4 -23
- package/lib/components/Link/index.d.ts.map +1 -1
- package/lib/components/Link/index.js +20 -158
- package/lib/components/Link/index.test.js +63 -42
- package/lib/components/Link/schema.d.ts.map +1 -1
- package/lib/components/Link/schema.js +2 -1
- package/lib/components/Link/styles.d.ts +20 -0
- package/lib/components/Link/styles.d.ts.map +1 -0
- package/lib/components/Link/styles.js +131 -0
- package/lib/components/Link/types.d.ts +28 -0
- package/lib/components/Link/types.d.ts.map +1 -0
- package/lib/components/Link/types.js +5 -0
- package/lib/components/Loading/Loading.d.ts +12 -0
- package/lib/components/Loading/Loading.d.ts.map +1 -0
- package/lib/components/Loading/Loading.js +70 -0
- package/lib/components/Loading/index.d.ts +4 -0
- package/lib/components/Loading/index.d.ts.map +1 -0
- package/lib/components/Loading/index.js +33 -0
- package/lib/components/Loading/index.test.js +55 -0
- package/lib/components/Loading/schema.d.ts +4 -0
- package/lib/components/Loading/schema.d.ts.map +1 -0
- package/lib/components/Loading/schema.js +31 -0
- package/lib/components/Loading/styles.d.ts +211 -0
- package/lib/components/Loading/styles.d.ts.map +1 -0
- package/lib/components/Loading/styles.js +77 -0
- package/lib/components/Loading/types.d.ts +10 -0
- package/lib/components/Loading/types.d.ts.map +1 -0
- package/lib/components/Loading/types.js +5 -0
- package/lib/components/Menu/types.js +5 -1
- package/lib/components/Modal/Manager.d.ts +6 -0
- package/lib/components/Modal/Manager.d.ts.map +1 -0
- package/lib/components/Modal/Manager.js +53 -0
- package/lib/components/Modal/ResponsiveModalWrapper.d.ts +11 -0
- package/lib/components/Modal/ResponsiveModalWrapper.d.ts.map +1 -0
- package/lib/components/Modal/ResponsiveModalWrapper.js +82 -0
- package/lib/components/Modal/components.d.ts +201 -3
- package/lib/components/Modal/components.d.ts.map +1 -1
- package/lib/components/Modal/components.js +16 -24
- package/lib/components/Modal/index.d.ts +8 -4
- package/lib/components/Modal/index.d.ts.map +1 -1
- package/lib/components/Modal/index.js +56 -95
- package/lib/components/Modal/index.test.js +26 -0
- package/lib/components/Modal/schema.d.ts.map +1 -1
- package/lib/components/Modal/schema.js +2 -1
- package/lib/components/Modal/types.d.ts +2 -1
- package/lib/components/Modal/types.d.ts.map +1 -1
- package/lib/components/Modal/types.js +5 -1
- package/lib/components/Modal/utils.d.ts +1 -1
- package/lib/components/Modal/utils.d.ts.map +1 -1
- package/lib/components/Modal/utils.js +7 -5
- package/lib/components/Notifications/Notification/components.d.ts +3 -3
- package/lib/components/Notifications/Notification/components.d.ts.map +1 -1
- package/lib/components/Notifications/Notification/components.js +12 -6
- package/lib/components/Notifications/Notification/index.d.ts +3 -6
- package/lib/components/Notifications/Notification/index.d.ts.map +1 -1
- package/lib/components/Notifications/Notification/index.js +19 -12
- package/lib/components/Notifications/Notification/index.test.js +38 -19
- package/lib/components/Notifications/NotificationsPanel/index.d.ts +2 -1
- package/lib/components/Notifications/NotificationsPanel/index.d.ts.map +1 -1
- package/lib/components/Notifications/NotificationsPanel/index.js +41 -22
- package/lib/components/Notifications/NotificationsPanel/schema.js +1 -1
- package/lib/components/Notifications/Notifier.test.js +79 -10
- package/lib/components/Notifications/constants.d.ts +2 -0
- package/lib/components/Notifications/constants.d.ts.map +1 -0
- package/lib/components/Notifications/constants.js +16 -0
- package/lib/components/Notifications/schema.d.ts.map +1 -1
- package/lib/components/Notifications/schema.js +2 -1
- package/lib/components/Notifications/useNotifications.d.ts +1 -0
- package/lib/components/Notifications/useNotifications.d.ts.map +1 -1
- package/lib/components/Notifications/useNotifications.test.js +7 -4
- package/lib/components/Pagination/Pagination.d.ts +1 -1
- package/lib/components/Pagination/Pagination.d.ts.map +1 -1
- package/lib/components/Pagination/Pagination.js +1 -0
- package/lib/components/Pagination/Pagination.test.js +9 -0
- package/lib/components/Pagination/types.js +5 -1
- package/lib/components/PasswordField/IconWrapper.d.ts +198 -0
- package/lib/components/PasswordField/IconWrapper.d.ts.map +1 -0
- package/lib/components/PasswordField/IconWrapper.js +32 -0
- package/lib/components/PasswordField/Input.d.ts +6 -0
- package/lib/components/PasswordField/Input.d.ts.map +1 -0
- package/lib/components/PasswordField/Input.js +28 -0
- package/lib/components/PasswordField/ShowPasswordButton.d.ts +8 -0
- package/lib/components/PasswordField/ShowPasswordButton.d.ts.map +1 -0
- package/lib/components/PasswordField/ShowPasswordButton.js +48 -0
- package/lib/components/PasswordField/index.d.ts +14 -0
- package/lib/components/PasswordField/index.d.ts.map +1 -0
- package/lib/components/PasswordField/index.js +113 -0
- package/lib/components/PasswordField/index.test.js +217 -0
- package/lib/components/PasswordField/schema.d.ts +3 -0
- package/lib/components/PasswordField/schema.d.ts.map +1 -0
- package/lib/components/PasswordField/schema.js +27 -0
- package/lib/components/Popover/Arrow.d.ts +2 -2
- package/lib/components/Popover/index.d.ts.map +1 -1
- package/lib/components/Popover/index.js +9 -5
- package/lib/components/Popover/schema.d.ts.map +1 -1
- package/lib/components/Popover/schema.js +27 -20
- package/lib/components/Popover/types.d.ts +4 -2
- package/lib/components/Popover/types.d.ts.map +1 -1
- package/lib/components/Popover/utils.d.ts +1 -1
- package/lib/components/SearchInput/index.d.ts +11 -0
- package/lib/components/SearchInput/index.d.ts.map +1 -0
- package/lib/components/SearchInput/index.js +176 -0
- package/lib/components/SearchInput/index.test.js +660 -0
- package/lib/components/SearchInput/schema.d.ts +3 -0
- package/lib/components/SearchInput/schema.d.ts.map +1 -0
- package/lib/components/SearchInput/schema.js +37 -0
- package/lib/components/SearchInput/styles.d.ts +1176 -0
- package/lib/components/SearchInput/styles.d.ts.map +1 -0
- package/lib/components/SearchInput/styles.js +97 -0
- package/lib/components/SearchInput/types.d.ts +38 -0
- package/lib/components/SearchInput/types.d.ts.map +1 -0
- package/lib/components/SearchInput/types.js +5 -0
- package/lib/components/Select/Target.d.ts.map +1 -1
- package/lib/components/Select/Target.js +6 -2
- package/lib/components/Select/index.d.ts.map +1 -1
- package/lib/components/Select/index.js +26 -3
- package/lib/components/Select/index.test.js +106 -23
- package/lib/components/Select/schema.d.ts.map +1 -1
- package/lib/components/Select/schema.js +5 -0
- package/lib/components/Select/types.d.ts +6 -3
- package/lib/components/Select/types.d.ts.map +1 -1
- package/lib/components/Select/types.js +5 -1
- package/lib/components/SelectDate/Target.d.ts.map +1 -1
- package/lib/components/SelectDate/Target.js +6 -2
- package/lib/components/SelectDate/index.d.ts.map +1 -1
- package/lib/components/SelectDate/index.js +32 -3
- package/lib/components/SelectDate/index.test.js +108 -51
- package/lib/components/SelectDate/schema.d.ts.map +1 -1
- package/lib/components/SelectDate/schema.js +3 -0
- package/lib/components/SelectDate/types.d.ts +3 -0
- package/lib/components/SelectDate/types.d.ts.map +1 -1
- package/lib/components/SelectDate/types.js +5 -1
- package/lib/components/SelectDateRange/index.d.ts.map +1 -1
- package/lib/components/SelectDateRange/index.js +31 -2
- package/lib/components/SelectDateRange/index.test.js +115 -58
- package/lib/components/SelectDateRange/schema.d.ts.map +1 -1
- package/lib/components/SelectDateRange/schema.js +3 -0
- package/lib/components/SelectDateRange/types.js +5 -1
- package/lib/components/StepTracker/index.d.ts +11 -0
- package/lib/components/StepTracker/index.d.ts.map +1 -0
- package/lib/components/StepTracker/index.js +56 -0
- package/lib/components/StepTracker/index.test.js +89 -0
- package/lib/components/StepTracker/schema.d.ts +3 -0
- package/lib/components/StepTracker/schema.d.ts.map +1 -0
- package/lib/components/StepTracker/schema.js +19 -0
- package/lib/components/StepTracker/styles.d.ts +605 -0
- package/lib/components/StepTracker/styles.d.ts.map +1 -0
- package/lib/components/StepTracker/styles.js +114 -0
- package/lib/components/Table/Body.d.ts.map +1 -1
- package/lib/components/Table/Body.js +28 -17
- package/lib/components/Table/Container.d.ts.map +1 -1
- package/lib/components/Table/Container.js +6 -1
- package/lib/components/Table/DataRow.d.ts.map +1 -1
- package/lib/components/Table/DataRow.js +26 -18
- package/lib/components/Table/Head.d.ts +1 -1
- package/lib/components/Table/Head.d.ts.map +1 -1
- package/lib/components/Table/Head.js +10 -5
- package/lib/components/Table/HeaderCell/index.d.ts.map +1 -1
- package/lib/components/Table/HeaderCell/index.js +19 -6
- package/lib/components/Table/HeaderCell/types.d.ts +6 -1
- package/lib/components/Table/HeaderCell/types.d.ts.map +1 -1
- package/lib/components/Table/HeaderCell/types.js +5 -1
- package/lib/components/Table/Provider.d.ts +5 -5
- package/lib/components/Table/Provider.d.ts.map +1 -1
- package/lib/components/Table/Provider.js +10 -11
- package/lib/components/Table/index.d.ts.map +1 -1
- package/lib/components/Table/index.js +110 -20
- package/lib/components/Table/index.test.js +80 -33
- package/lib/components/Table/schema.columns.d.ts.map +1 -1
- package/lib/components/Table/schema.columns.js +6 -4
- package/lib/components/Table/schema.d.ts.map +1 -1
- package/lib/components/Table/schema.js +7 -6
- package/lib/components/Table/types.d.ts +19 -4
- package/lib/components/Table/types.d.ts.map +1 -1
- package/lib/components/Table/utils.d.ts +2 -8
- package/lib/components/Table/utils.d.ts.map +1 -1
- package/lib/components/Table/utils.js +21 -20
- package/lib/components/Tabs/Tab/index.d.ts +13 -0
- package/lib/components/Tabs/Tab/index.d.ts.map +1 -0
- package/lib/components/Tabs/Tab/index.js +94 -0
- package/lib/components/Tabs/Tab/schema.d.ts +3 -0
- package/lib/components/Tabs/Tab/schema.d.ts.map +1 -0
- package/lib/components/Tabs/Tab/styles.d.ts +7 -0
- package/lib/components/Tabs/Tab/styles.d.ts.map +1 -0
- package/lib/components/Tabs/Tab/styles.js +37 -0
- package/lib/components/Tabs/context.d.ts +2 -2
- package/lib/components/Tabs/context.d.ts.map +1 -1
- package/lib/components/Tabs/context.js +1 -1
- package/lib/components/Tabs/index.d.ts +17 -6
- package/lib/components/Tabs/index.d.ts.map +1 -1
- package/lib/components/Tabs/index.js +104 -163
- package/lib/components/Tabs/index.test.js +54 -2
- package/lib/components/Tabs/styles.d.ts +4 -0
- package/lib/components/Tabs/styles.d.ts.map +1 -0
- package/lib/components/Tabs/styles.js +35 -0
- package/lib/components/Tag/Action.d.ts +4 -0
- package/lib/components/Tag/Action.d.ts.map +1 -0
- package/lib/components/Tag/Action.js +39 -0
- package/lib/components/Tag/constants.d.ts +2 -2
- package/lib/components/Tag/constants.d.ts.map +1 -1
- package/lib/components/Tag/constants.js +4 -4
- package/lib/components/Tag/index.d.ts +1 -3
- package/lib/components/Tag/index.d.ts.map +1 -1
- package/lib/components/Tag/index.js +40 -97
- package/lib/components/Tag/index.test.js +239 -2
- package/lib/components/Tag/propTypes.d.ts +4 -1
- package/lib/components/Tag/propTypes.d.ts.map +1 -1
- package/lib/components/Tag/propTypes.js +5 -2
- package/lib/components/Tag/schema.d.ts.map +1 -1
- package/lib/components/Tag/schema.js +2 -0
- package/lib/components/Tag/styles.d.ts +13 -0
- package/lib/components/Tag/styles.d.ts.map +1 -0
- package/lib/components/Tag/styles.js +133 -0
- package/lib/components/Tag/types.d.ts +9 -10
- package/lib/components/Tag/types.d.ts.map +1 -1
- package/lib/components/Tag/types.js +5 -1
- package/lib/components/TagInput/index.d.ts +10 -0
- package/lib/components/TagInput/index.d.ts.map +1 -0
- package/lib/components/TagInput/index.js +217 -0
- package/lib/components/TagInput/index.test.js +1001 -0
- package/lib/components/TagInput/schema.d.ts +3 -0
- package/lib/components/TagInput/schema.d.ts.map +1 -0
- package/lib/components/TagInput/schema.js +30 -0
- package/lib/components/TagInput/styles.d.ts +10 -0
- package/lib/components/TagInput/styles.d.ts.map +1 -0
- package/lib/components/TagInput/styles.js +52 -0
- package/lib/components/TextArea/TextArea.d.ts.map +1 -1
- package/lib/components/TextArea/TextArea.js +1 -1
- package/lib/components/TextArea/index.js +1 -0
- package/lib/components/TextArea/index.test.js +5 -0
- package/lib/components/TextField/Input.js +1 -1
- package/lib/components/TextField/index.test.js +5 -0
- package/lib/components/Toggle/Fieldset.d.ts.map +1 -1
- package/lib/components/Toggle/Fieldset.js +20 -11
- package/lib/components/Toggle/Option.d.ts.map +1 -1
- package/lib/components/Toggle/Option.js +1 -1
- package/lib/components/Toggle/Slider.d.ts +1 -3
- package/lib/components/Toggle/Slider.d.ts.map +1 -1
- package/lib/components/Toggle/Slider.js +29 -24
- package/lib/components/Toggle/index.d.ts.map +1 -1
- package/lib/components/Toggle/index.js +6 -1
- package/lib/components/Toggle/index.test.js +39 -10
- package/lib/components/Toggle/propTypes.js +1 -1
- package/lib/components/Toggle/schema.js +1 -1
- package/lib/components/Toggle/types.d.ts +3 -2
- package/lib/components/Toggle/types.d.ts.map +1 -1
- package/lib/components/Toggle/types.js +5 -1
- package/lib/components/ToggleView/ToggleView.d.ts +5 -0
- package/lib/components/ToggleView/ToggleView.d.ts.map +1 -0
- package/lib/components/ToggleView/ToggleView.js +80 -0
- package/lib/components/ToggleView/index.d.ts +4 -0
- package/lib/components/ToggleView/index.d.ts.map +1 -0
- package/lib/components/ToggleView/index.js +33 -0
- package/lib/components/ToggleView/index.test.js +61 -0
- package/lib/components/ToggleView/schema.d.ts +3 -0
- package/lib/components/ToggleView/schema.d.ts.map +1 -0
- package/lib/components/ToggleView/schema.js +24 -0
- package/lib/components/ToggleView/styles.d.ts +6 -0
- package/lib/components/ToggleView/styles.d.ts.map +1 -0
- package/lib/components/ToggleView/styles.js +23 -0
- package/lib/components/ToggleView/types.d.ts +23 -0
- package/lib/components/ToggleView/types.d.ts.map +1 -0
- package/lib/components/ToggleView/types.js +12 -0
- package/lib/components/Tooltip/index.d.ts.map +1 -1
- package/lib/components/Tooltip/index.js +3 -13
- package/lib/components/Tooltip/schema.d.ts +3 -0
- package/lib/components/Tooltip/schema.d.ts.map +1 -0
- package/lib/components/Tooltip/schema.js +29 -0
- package/lib/components/Typography/withColors.d.ts +1 -1
- package/lib/components/Typography/withColors.d.ts.map +1 -1
- package/lib/components/Typography/withColors.js +1 -1
- package/lib/components/Wizard/index.d.ts +24 -0
- package/lib/components/Wizard/index.d.ts.map +1 -0
- package/lib/components/Wizard/index.js +146 -0
- package/lib/components/Wizard/index.test.js +591 -0
- package/lib/components/Wizard/schema.d.ts +3 -0
- package/lib/components/Wizard/schema.d.ts.map +1 -0
- package/lib/components/Wizard/schema.js +37 -0
- package/lib/components/Wizard/styles.d.ts +990 -0
- package/lib/components/Wizard/styles.d.ts.map +1 -0
- package/lib/components/Wizard/styles.js +79 -0
- package/lib/components/index.d.ts +11 -1
- package/lib/components/index.d.ts.map +1 -1
- package/lib/components/index.js +182 -1
- package/lib/modifiers/palette.d.ts +36 -0
- package/lib/modifiers/palette.d.ts.map +1 -0
- package/lib/modifiers/palette.js +88 -0
- package/lib/modifiers/spacingSchema.d.ts.map +1 -1
- package/lib/modifiers/spacingSchema.js +29 -16
- package/lib/providers/ConfigProvider/index.d.ts.map +1 -1
- package/lib/providers/ConfigProvider/index.js +5 -1
- package/lib/providers/ConfigProvider/utils/context.d.ts +1 -1
- package/lib/providers/ConfigProvider/utils/context.d.ts.map +1 -1
- package/lib/providers/ConfigProvider/utils/normalizer.d.ts.map +1 -1
- package/lib/providers/ConfigProvider/utils/normalizer.js +1 -1
- package/lib/providers/ConfigProvider/utils/translations.d.ts +40 -0
- package/lib/providers/ConfigProvider/utils/translations.d.ts.map +1 -1
- package/lib/providers/ConfigProvider/utils/translations.js +40 -0
- package/lib/providers/NotificationsProvider/index.d.ts +6 -5
- package/lib/providers/NotificationsProvider/index.d.ts.map +1 -1
- package/lib/providers/NotificationsProvider/index.js +47 -28
- package/lib/providers/NotificationsProvider/types.d.ts +4 -1
- package/lib/providers/NotificationsProvider/types.d.ts.map +1 -1
- package/lib/utils/commonUIColors.d.ts +351 -3
- package/lib/utils/commonUIColors.d.ts.map +1 -1
- package/lib/utils/commonUIColors.js +6 -2
- package/lib/utils/joinClassnames.d.ts +3 -0
- package/lib/utils/joinClassnames.d.ts.map +1 -0
- package/lib/utils/joinClassnames.js +26 -0
- package/lib/utils/useDebounce.d.ts +2 -0
- package/lib/utils/useDebounce.d.ts.map +1 -0
- package/lib/utils/useDebounce.js +37 -0
- package/lib/utils/useFirstMount.d.ts +2 -0
- package/lib/utils/useFirstMount.d.ts.map +1 -0
- package/lib/utils/useFirstMount.js +19 -0
- package/lib/utils/useUpdateEffect.d.ts +4 -0
- package/lib/utils/useUpdateEffect.d.ts.map +1 -0
- package/lib/utils/useUpdateEffect.js +28 -0
- package/package.json +2 -2
- package/CHANGELOG.md +0 -796
- package/lib/atoms/InputField/RequiredIcon.d.ts +0 -4
- package/lib/atoms/InputField/RequiredIcon.d.ts.map +0 -1
- package/lib/atoms/OptionsList/Category.d.ts +0 -4
- package/lib/atoms/OptionsList/Category.d.ts.map +0 -1
- package/lib/atoms/OptionsList/Option.d.ts.map +0 -1
- package/lib/atoms/OptionsList/Option.js +0 -194
- package/lib/components/Tabs/Tab.d.ts +0 -5
- package/lib/components/Tabs/Tab.d.ts.map +0 -1
- package/lib/components/Tabs/Tab.js +0 -109
- package/lib/components/Tabs/schema.tab.d.ts.map +0 -1
- package/lib/components/Tabs/types.d.ts +0 -27
- package/lib/components/Tabs/types.d.ts.map +0 -1
- package/lib/components/Tabs/types.js +0 -1
- package/lib/components/Tag/ActionButton.d.ts +0 -5
- package/lib/components/Tag/ActionButton.d.ts.map +0 -1
- package/lib/components/Tag/ActionButton.js +0 -56
- /package/lib/components/Tabs/{schema.tab.js → Tab/schema.js} +0 -0
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { LoadingProps } from './types';
|
|
3
|
+
declare const Loading: {
|
|
4
|
+
({ title, description, variant, size, ...props }: LoadingProps): JSX.Element;
|
|
5
|
+
defaultProps: {
|
|
6
|
+
size: string;
|
|
7
|
+
variant: string;
|
|
8
|
+
};
|
|
9
|
+
propTypes: any;
|
|
10
|
+
};
|
|
11
|
+
export default Loading;
|
|
12
|
+
//# sourceMappingURL=Loading.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Loading.d.ts","sourceRoot":"","sources":["../../../src/components/Loading/Loading.tsx"],"names":[],"mappings":";AAYA,OAAO,EAAQ,YAAY,EAAE,MAAM,SAAS,CAAC;AAQ7C,QAAA,MAAM,OAAO;;;;;;;CAuCZ,CAAC;AASF,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
|
|
10
|
+
var _Typography = require("../Typography");
|
|
11
|
+
|
|
12
|
+
var _schema = _interopRequireDefault(require("./schema"));
|
|
13
|
+
|
|
14
|
+
var _styles = require("./styles");
|
|
15
|
+
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
|
+
|
|
18
|
+
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
19
|
+
|
|
20
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
21
|
+
|
|
22
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
23
|
+
|
|
24
|
+
var TITLE_MAP = {
|
|
25
|
+
small: _Typography.P,
|
|
26
|
+
medium: _Typography.H4,
|
|
27
|
+
large: _Typography.H3
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
var Loading = function Loading(_ref) {
|
|
31
|
+
var title = _ref.title,
|
|
32
|
+
description = _ref.description,
|
|
33
|
+
variant = _ref.variant,
|
|
34
|
+
_ref$size = _ref.size,
|
|
35
|
+
size = _ref$size === void 0 ? 'medium' : _ref$size,
|
|
36
|
+
props = _objectWithoutProperties(_ref, ["title", "description", "variant", "size"]);
|
|
37
|
+
|
|
38
|
+
var Title = TITLE_MAP[size];
|
|
39
|
+
var inverted = variant === 'inverted';
|
|
40
|
+
var textSize = size === 'small' ? 'small' : undefined;
|
|
41
|
+
var titleColor = inverted ? 'snowWhite' : undefined;
|
|
42
|
+
var descriptionColor = inverted ? 'fullMoon' : 'alaskanHusky';
|
|
43
|
+
var showTextContainer = !!title || !!description;
|
|
44
|
+
return _react.default.createElement(_styles.Container, _extends({
|
|
45
|
+
loadingSize: size
|
|
46
|
+
}, props), _react.default.createElement(_styles.AnimationContainer, {
|
|
47
|
+
size: size
|
|
48
|
+
}, _react.default.createElement(_styles.Bouncer, {
|
|
49
|
+
inverted: inverted
|
|
50
|
+
}), _react.default.createElement(_styles.Bouncer, {
|
|
51
|
+
inverted: inverted,
|
|
52
|
+
shadow: true
|
|
53
|
+
})), showTextContainer && _react.default.createElement(_styles.TextContainer, {
|
|
54
|
+
size: size
|
|
55
|
+
}, title && _react.default.createElement(Title, {
|
|
56
|
+
color: titleColor,
|
|
57
|
+
size: textSize
|
|
58
|
+
}, title), description && _react.default.createElement(_Typography.P, {
|
|
59
|
+
size: textSize,
|
|
60
|
+
color: descriptionColor
|
|
61
|
+
}, description)));
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
Loading.defaultProps = {
|
|
65
|
+
size: 'medium',
|
|
66
|
+
variant: 'normal'
|
|
67
|
+
};
|
|
68
|
+
Loading.propTypes = _schema.default.propTypes;
|
|
69
|
+
var _default = Loading;
|
|
70
|
+
exports.default = _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Loading/index.ts"],"names":[],"mappings":"AAAA,OAAO,OAAO,MAAM,WAAW,CAAC;AAEhC,OAAO,EACL,YAAY,EACZ,IAAI,IAAI,WAAW,EACnB,OAAO,IAAI,cAAc,GAC1B,MAAM,SAAS,CAAC;AAEjB,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
Object.defineProperty(exports, "LoadingProps", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function get() {
|
|
9
|
+
return _types.LoadingProps;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
Object.defineProperty(exports, "LoadingSize", {
|
|
13
|
+
enumerable: true,
|
|
14
|
+
get: function get() {
|
|
15
|
+
return _types.Size;
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
Object.defineProperty(exports, "LoadingVariant", {
|
|
19
|
+
enumerable: true,
|
|
20
|
+
get: function get() {
|
|
21
|
+
return _types.Variant;
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
exports.default = void 0;
|
|
25
|
+
|
|
26
|
+
var _Loading = _interopRequireDefault(require("./Loading"));
|
|
27
|
+
|
|
28
|
+
var _types = require("./types");
|
|
29
|
+
|
|
30
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
31
|
+
|
|
32
|
+
var _default = _Loading.default;
|
|
33
|
+
exports.default = _default;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _react = _interopRequireDefault(require("react"));
|
|
4
|
+
|
|
5
|
+
var _react2 = require("@testing-library/react");
|
|
6
|
+
|
|
7
|
+
var _ = _interopRequireDefault(require("."));
|
|
8
|
+
|
|
9
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
10
|
+
|
|
11
|
+
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
12
|
+
|
|
13
|
+
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
14
|
+
|
|
15
|
+
describe('Loading', function () {
|
|
16
|
+
it('renders title', /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
|
|
17
|
+
var _render, getByText;
|
|
18
|
+
|
|
19
|
+
return regeneratorRuntime.wrap(function _callee$(_context) {
|
|
20
|
+
while (1) {
|
|
21
|
+
switch (_context.prev = _context.next) {
|
|
22
|
+
case 0:
|
|
23
|
+
_render = (0, _react2.render)(_react.default.createElement(_.default, {
|
|
24
|
+
title: "Loading..."
|
|
25
|
+
})), getByText = _render.getByText;
|
|
26
|
+
expect(getByText(/loading.../i)).toBeInTheDocument();
|
|
27
|
+
|
|
28
|
+
case 2:
|
|
29
|
+
case "end":
|
|
30
|
+
return _context.stop();
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}, _callee);
|
|
34
|
+
})));
|
|
35
|
+
it('renders description', /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2() {
|
|
36
|
+
var _render2, getByText;
|
|
37
|
+
|
|
38
|
+
return regeneratorRuntime.wrap(function _callee2$(_context2) {
|
|
39
|
+
while (1) {
|
|
40
|
+
switch (_context2.prev = _context2.next) {
|
|
41
|
+
case 0:
|
|
42
|
+
_render2 = (0, _react2.render)(_react.default.createElement(_.default, {
|
|
43
|
+
title: "Loading...",
|
|
44
|
+
description: "Some description"
|
|
45
|
+
})), getByText = _render2.getByText;
|
|
46
|
+
expect(getByText(/some description/i)).toBeInTheDocument();
|
|
47
|
+
|
|
48
|
+
case 2:
|
|
49
|
+
case "end":
|
|
50
|
+
return _context2.stop();
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}, _callee2);
|
|
54
|
+
})));
|
|
55
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/components/Loading/schema.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,0BAA0B,cAQrC,CAAC;AAEH,QAAA,MAAM,MAAM,KAAuC,CAAC;AAIpD,eAAe,MAAM,CAAC"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = exports.makeLoadingSchemaPropTypes = void 0;
|
|
7
|
+
|
|
8
|
+
var _reactDesc = require("react-desc");
|
|
9
|
+
|
|
10
|
+
var _spacingSchema = require("../../modifiers/spacingSchema");
|
|
11
|
+
|
|
12
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { keys.push.apply(keys, Object.getOwnPropertySymbols(object)); } if (enumerableOnly) keys = keys.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); return keys; }
|
|
13
|
+
|
|
14
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(source, true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(source).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
15
|
+
|
|
16
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
17
|
+
|
|
18
|
+
var makeLoadingSchemaPropTypes = function makeLoadingSchemaPropTypes() {
|
|
19
|
+
return _objectSpread({}, (0, _spacingSchema.makeSpacingSchemaPropTypes)(), {
|
|
20
|
+
size: _reactDesc.PropTypes.oneOf(['small', 'medium', 'large']).description("The size in which to render the component's text and icon").defaultValue('medium'),
|
|
21
|
+
variant: _reactDesc.PropTypes.oneOf(['normal', 'inverted']).description('Which loading variant to render.').defaultValue('normal')
|
|
22
|
+
});
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
exports.makeLoadingSchemaPropTypes = makeLoadingSchemaPropTypes;
|
|
26
|
+
var schema = (0, _reactDesc.describe)({
|
|
27
|
+
displayName: 'Loading'
|
|
28
|
+
});
|
|
29
|
+
schema.propTypes = makeLoadingSchemaPropTypes();
|
|
30
|
+
var _default = schema;
|
|
31
|
+
exports.default = _default;
|
|
@@ -0,0 +1,211 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { FlexComponentProps } from '../Flex';
|
|
3
|
+
import { Size } from './types';
|
|
4
|
+
interface ContainerProps extends FlexComponentProps {
|
|
5
|
+
loadingSize: Size;
|
|
6
|
+
}
|
|
7
|
+
export declare const Container: import("styled-components").StyledComponent<"div", any, Partial<{
|
|
8
|
+
readonly alignContent?: string | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<string, {
|
|
9
|
+
readonly XS: "XS";
|
|
10
|
+
readonly SM: "SM";
|
|
11
|
+
readonly MD: "MD";
|
|
12
|
+
readonly LG: "LG";
|
|
13
|
+
readonly XL: "XL";
|
|
14
|
+
}> | undefined;
|
|
15
|
+
readonly alignItems?: string | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<string, {
|
|
16
|
+
readonly XS: "XS";
|
|
17
|
+
readonly SM: "SM";
|
|
18
|
+
readonly MD: "MD";
|
|
19
|
+
readonly LG: "LG";
|
|
20
|
+
readonly XL: "XL";
|
|
21
|
+
}> | undefined;
|
|
22
|
+
readonly alignSelf?: string | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<string, {
|
|
23
|
+
readonly XS: "XS";
|
|
24
|
+
readonly SM: "SM";
|
|
25
|
+
readonly MD: "MD";
|
|
26
|
+
readonly LG: "LG";
|
|
27
|
+
readonly XL: "XL";
|
|
28
|
+
}> | undefined;
|
|
29
|
+
readonly flex?: string | number | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<import("react").ReactText, {
|
|
30
|
+
readonly XS: "XS";
|
|
31
|
+
readonly SM: "SM";
|
|
32
|
+
readonly MD: "MD";
|
|
33
|
+
readonly LG: "LG";
|
|
34
|
+
readonly XL: "XL";
|
|
35
|
+
}> | undefined;
|
|
36
|
+
readonly flexBasis?: string | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<string, {
|
|
37
|
+
readonly XS: "XS";
|
|
38
|
+
readonly SM: "SM";
|
|
39
|
+
readonly MD: "MD";
|
|
40
|
+
readonly LG: "LG";
|
|
41
|
+
readonly XL: "XL";
|
|
42
|
+
}> | undefined;
|
|
43
|
+
readonly flexDirection?: "-moz-initial" | "inherit" | "initial" | "revert" | "unset" | "row" | "column" | "column-reverse" | "row-reverse" | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<import("csstype").FlexDirectionProperty, {
|
|
44
|
+
readonly XS: "XS";
|
|
45
|
+
readonly SM: "SM";
|
|
46
|
+
readonly MD: "MD";
|
|
47
|
+
readonly LG: "LG";
|
|
48
|
+
readonly XL: "XL";
|
|
49
|
+
}> | undefined;
|
|
50
|
+
readonly flexGrow?: number | "-moz-initial" | "inherit" | "initial" | "revert" | "unset" | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<import("csstype").GlobalsNumber, {
|
|
51
|
+
readonly XS: "XS";
|
|
52
|
+
readonly SM: "SM";
|
|
53
|
+
readonly MD: "MD";
|
|
54
|
+
readonly LG: "LG";
|
|
55
|
+
readonly XL: "XL";
|
|
56
|
+
}> | undefined;
|
|
57
|
+
readonly flexShrink?: number | "-moz-initial" | "inherit" | "initial" | "revert" | "unset" | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<import("csstype").GlobalsNumber, {
|
|
58
|
+
readonly XS: "XS";
|
|
59
|
+
readonly SM: "SM";
|
|
60
|
+
readonly MD: "MD";
|
|
61
|
+
readonly LG: "LG";
|
|
62
|
+
readonly XL: "XL";
|
|
63
|
+
}> | undefined;
|
|
64
|
+
readonly flexWrap?: "-moz-initial" | "inherit" | "initial" | "revert" | "unset" | "nowrap" | "wrap" | "wrap-reverse" | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<import("csstype").FlexWrapProperty, {
|
|
65
|
+
readonly XS: "XS";
|
|
66
|
+
readonly SM: "SM";
|
|
67
|
+
readonly MD: "MD";
|
|
68
|
+
readonly LG: "LG";
|
|
69
|
+
readonly XL: "XL";
|
|
70
|
+
}> | undefined;
|
|
71
|
+
readonly justifyContent?: string | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<string, {
|
|
72
|
+
readonly XS: "XS";
|
|
73
|
+
readonly SM: "SM";
|
|
74
|
+
readonly MD: "MD";
|
|
75
|
+
readonly LG: "LG";
|
|
76
|
+
readonly XL: "XL";
|
|
77
|
+
}> | undefined;
|
|
78
|
+
readonly justifyItems?: string | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<string, {
|
|
79
|
+
readonly XS: "XS";
|
|
80
|
+
readonly SM: "SM";
|
|
81
|
+
readonly MD: "MD";
|
|
82
|
+
readonly LG: "LG";
|
|
83
|
+
readonly XL: "XL";
|
|
84
|
+
}> | undefined;
|
|
85
|
+
readonly justifySelf?: string | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<string, {
|
|
86
|
+
readonly XS: "XS";
|
|
87
|
+
readonly SM: "SM";
|
|
88
|
+
readonly MD: "MD";
|
|
89
|
+
readonly LG: "LG";
|
|
90
|
+
readonly XL: "XL";
|
|
91
|
+
}> | undefined;
|
|
92
|
+
readonly order?: number | "-moz-initial" | "inherit" | "initial" | "revert" | "unset" | import("../../utils/dynamicModifiers").DynamicResponsiveModifiersProp<import("csstype").GlobalsNumber, {
|
|
93
|
+
readonly XS: "XS";
|
|
94
|
+
readonly SM: "SM";
|
|
95
|
+
readonly MD: "MD";
|
|
96
|
+
readonly LG: "LG";
|
|
97
|
+
readonly XL: "XL";
|
|
98
|
+
}> | undefined;
|
|
99
|
+
readonly size?: "XS" | "SM" | "MD" | "LG" | "XL" | undefined;
|
|
100
|
+
}> & Partial<{
|
|
101
|
+
readonly margin: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
102
|
+
readonly XS: "XS";
|
|
103
|
+
readonly SM: "SM";
|
|
104
|
+
readonly MD: "MD";
|
|
105
|
+
readonly LG: "LG";
|
|
106
|
+
readonly XL: "XL";
|
|
107
|
+
}>;
|
|
108
|
+
readonly marginBottom: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
109
|
+
readonly XS: "XS";
|
|
110
|
+
readonly SM: "SM";
|
|
111
|
+
readonly MD: "MD";
|
|
112
|
+
readonly LG: "LG";
|
|
113
|
+
readonly XL: "XL";
|
|
114
|
+
}>;
|
|
115
|
+
readonly marginLeft: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
116
|
+
readonly XS: "XS";
|
|
117
|
+
readonly SM: "SM";
|
|
118
|
+
readonly MD: "MD";
|
|
119
|
+
readonly LG: "LG";
|
|
120
|
+
readonly XL: "XL";
|
|
121
|
+
}>;
|
|
122
|
+
readonly marginRight: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
123
|
+
readonly XS: "XS";
|
|
124
|
+
readonly SM: "SM";
|
|
125
|
+
readonly MD: "MD";
|
|
126
|
+
readonly LG: "LG";
|
|
127
|
+
readonly XL: "XL";
|
|
128
|
+
}>;
|
|
129
|
+
readonly marginTop: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
130
|
+
readonly XS: "XS";
|
|
131
|
+
readonly SM: "SM";
|
|
132
|
+
readonly MD: "MD";
|
|
133
|
+
readonly LG: "LG";
|
|
134
|
+
readonly XL: "XL";
|
|
135
|
+
}>;
|
|
136
|
+
readonly marginX: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
137
|
+
readonly XS: "XS";
|
|
138
|
+
readonly SM: "SM";
|
|
139
|
+
readonly MD: "MD";
|
|
140
|
+
readonly LG: "LG";
|
|
141
|
+
readonly XL: "XL";
|
|
142
|
+
}>;
|
|
143
|
+
readonly marginY: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
144
|
+
readonly XS: "XS";
|
|
145
|
+
readonly SM: "SM";
|
|
146
|
+
readonly MD: "MD";
|
|
147
|
+
readonly LG: "LG";
|
|
148
|
+
readonly XL: "XL";
|
|
149
|
+
}>;
|
|
150
|
+
readonly padding: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
151
|
+
readonly XS: "XS";
|
|
152
|
+
readonly SM: "SM";
|
|
153
|
+
readonly MD: "MD";
|
|
154
|
+
readonly LG: "LG";
|
|
155
|
+
readonly XL: "XL";
|
|
156
|
+
}>;
|
|
157
|
+
readonly paddingBottom: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
158
|
+
readonly XS: "XS";
|
|
159
|
+
readonly SM: "SM";
|
|
160
|
+
readonly MD: "MD";
|
|
161
|
+
readonly LG: "LG";
|
|
162
|
+
readonly XL: "XL";
|
|
163
|
+
}>;
|
|
164
|
+
readonly paddingLeft: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
165
|
+
readonly XS: "XS";
|
|
166
|
+
readonly SM: "SM";
|
|
167
|
+
readonly MD: "MD";
|
|
168
|
+
readonly LG: "LG";
|
|
169
|
+
readonly XL: "XL";
|
|
170
|
+
}>;
|
|
171
|
+
readonly paddingRight: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
172
|
+
readonly XS: "XS";
|
|
173
|
+
readonly SM: "SM";
|
|
174
|
+
readonly MD: "MD";
|
|
175
|
+
readonly LG: "LG";
|
|
176
|
+
readonly XL: "XL";
|
|
177
|
+
}>;
|
|
178
|
+
readonly paddingTop: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
179
|
+
readonly XS: "XS";
|
|
180
|
+
readonly SM: "SM";
|
|
181
|
+
readonly MD: "MD";
|
|
182
|
+
readonly LG: "LG";
|
|
183
|
+
readonly XL: "XL";
|
|
184
|
+
}>;
|
|
185
|
+
readonly paddingX: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
186
|
+
readonly XS: "XS";
|
|
187
|
+
readonly SM: "SM";
|
|
188
|
+
readonly MD: "MD";
|
|
189
|
+
readonly LG: "LG";
|
|
190
|
+
readonly XL: "XL";
|
|
191
|
+
}>;
|
|
192
|
+
readonly paddingY: import("../../utils/dynamicModifiers").DynamicModifiersProp<number, {
|
|
193
|
+
readonly XS: "XS";
|
|
194
|
+
readonly SM: "SM";
|
|
195
|
+
readonly MD: "MD";
|
|
196
|
+
readonly LG: "LG";
|
|
197
|
+
readonly XL: "XL";
|
|
198
|
+
}>;
|
|
199
|
+
}> & ContainerProps, never>;
|
|
200
|
+
export declare const AnimationContainer: import("styled-components").StyledComponent<"div", any, {
|
|
201
|
+
size: Size;
|
|
202
|
+
}, never>;
|
|
203
|
+
export declare const Bouncer: import("styled-components").StyledComponent<"div", any, {
|
|
204
|
+
inverted?: boolean | undefined;
|
|
205
|
+
shadow?: boolean | undefined;
|
|
206
|
+
}, never>;
|
|
207
|
+
export declare const TextContainer: import("styled-components").StyledComponent<"div", any, {
|
|
208
|
+
size: Size;
|
|
209
|
+
}, never>;
|
|
210
|
+
export {};
|
|
211
|
+
//# sourceMappingURL=styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/components/Loading/styles.ts"],"names":[],"mappings":";AAOA,OAAa,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAEnD,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAmB/B,UAAU,cAAe,SAAQ,kBAAkB;IACjD,WAAW,EAAE,IAAI,CAAC;CACnB;AAED,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2BAGrB,CAAC;AAoBF,eAAO,MAAM,kBAAkB;;SAI9B,CAAC;AAEF,eAAO,MAAM,OAAO;;;SAiCnB,CAAC;AAmBF,eAAO,MAAM,aAAa;;SAIzB,CAAC"}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.TextContainer = exports.Bouncer = exports.AnimationContainer = exports.Container = void 0;
|
|
7
|
+
|
|
8
|
+
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
9
|
+
|
|
10
|
+
var _toColorString = _interopRequireDefault(require("polished/lib/color/toColorString"));
|
|
11
|
+
|
|
12
|
+
var _rem = _interopRequireDefault(require("polished/lib/helpers/rem"));
|
|
13
|
+
|
|
14
|
+
var _designTokens = require("@decisiv/design-tokens");
|
|
15
|
+
|
|
16
|
+
var _Flex = _interopRequireDefault(require("../Flex"));
|
|
17
|
+
|
|
18
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
|
+
|
|
20
|
+
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } }
|
|
21
|
+
|
|
22
|
+
var CONTAINER_STYLE = {
|
|
23
|
+
small: (0, _styledComponents.css)(["flex-direction:row;gap:", ";"], (0, _rem.default)(_designTokens.spacing.base * 0.5)),
|
|
24
|
+
medium: (0, _styledComponents.css)(["flex-direction:column;align-items:center;gap:", ";"], (0, _rem.default)(_designTokens.spacing.base)),
|
|
25
|
+
large: (0, _styledComponents.css)(["flex-direction:column;align-items:center;gap:", ";"], (0, _rem.default)(_designTokens.spacing.base))
|
|
26
|
+
};
|
|
27
|
+
var Container = (0, _styledComponents.default)(_Flex.default).withConfig({
|
|
28
|
+
displayName: "styles__Container",
|
|
29
|
+
componentId: "fjt04b-0"
|
|
30
|
+
})(["display:flex;", ";"], function (_ref) {
|
|
31
|
+
var loadingSize = _ref.loadingSize;
|
|
32
|
+
return CONTAINER_STYLE[loadingSize];
|
|
33
|
+
});
|
|
34
|
+
exports.Container = Container;
|
|
35
|
+
var ANIMATION_CONTAINER_STYLE = {
|
|
36
|
+
small: (0, _styledComponents.css)(["width:", ";min-width:", ";height:", ";"], (0, _rem.default)(_designTokens.spacing.base * 1.6), (0, _rem.default)(_designTokens.spacing.base * 1.6), (0, _rem.default)(_designTokens.spacing.base * 1.6)),
|
|
37
|
+
medium: (0, _styledComponents.css)(["width:", ";min-width:", ";height:", ";"], (0, _rem.default)(_designTokens.spacing.base * 3.6), (0, _rem.default)(_designTokens.spacing.base * 3.6), (0, _rem.default)(_designTokens.spacing.base * 3.6)),
|
|
38
|
+
large: (0, _styledComponents.css)(["width:", ";min-width:", ";height:", ";"], (0, _rem.default)(_designTokens.spacing.base * 4.8), (0, _rem.default)(_designTokens.spacing.base * 4.8), (0, _rem.default)(_designTokens.spacing.base * 4.8))
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
var AnimationContainer = _styledComponents.default.div.withConfig({
|
|
42
|
+
displayName: "styles__AnimationContainer",
|
|
43
|
+
componentId: "fjt04b-1"
|
|
44
|
+
})(["position:relative;", ""], function (_ref2) {
|
|
45
|
+
var size = _ref2.size;
|
|
46
|
+
return ANIMATION_CONTAINER_STYLE[size];
|
|
47
|
+
});
|
|
48
|
+
|
|
49
|
+
exports.AnimationContainer = AnimationContainer;
|
|
50
|
+
|
|
51
|
+
var Bouncer = _styledComponents.default.div.withConfig({
|
|
52
|
+
displayName: "styles__Bouncer",
|
|
53
|
+
componentId: "fjt04b-2"
|
|
54
|
+
})(["width:100%;height:100%;border-radius:50%;background-color:", ";opacity:0.6;position:absolute;top:0;left:0;animation:sk-bounce 2s infinite ease-in-out;", " ", " @keyframes sk-bounce{0%,100%{transform:scale(0);}50%{transform:scale(1);}}"], (0, _toColorString.default)(_designTokens.color.interaction.pacificOcean40), function (_ref3) {
|
|
55
|
+
var inverted = _ref3.inverted;
|
|
56
|
+
return inverted && (0, _styledComponents.css)(["background-color:", ";"], (0, _toColorString.default)(_designTokens.color.opacity.fullMoon50));
|
|
57
|
+
}, function (_ref4) {
|
|
58
|
+
var shadow = _ref4.shadow;
|
|
59
|
+
return shadow && (0, _styledComponents.css)(["animation-delay:-1s;"]);
|
|
60
|
+
});
|
|
61
|
+
|
|
62
|
+
exports.Bouncer = Bouncer;
|
|
63
|
+
var TEXT_CONTAINER_STYLE = {
|
|
64
|
+
small: (0, _styledComponents.css)(["text-align:left;align-items:flex-start;"]),
|
|
65
|
+
medium: (0, _styledComponents.css)(["gap:", ";text-align:center;align-items:center;"], (0, _rem.default)(_designTokens.spacing.base * 0.5)),
|
|
66
|
+
large: (0, _styledComponents.css)(["gap:", ";text-align:center;align-items:center;"], (0, _rem.default)(_designTokens.spacing.base * 0.5))
|
|
67
|
+
};
|
|
68
|
+
|
|
69
|
+
var TextContainer = _styledComponents.default.div.withConfig({
|
|
70
|
+
displayName: "styles__TextContainer",
|
|
71
|
+
componentId: "fjt04b-3"
|
|
72
|
+
})(["display:flex;flex-direction:column;", ";"], function (_ref5) {
|
|
73
|
+
var size = _ref5.size;
|
|
74
|
+
return TEXT_CONTAINER_STYLE[size];
|
|
75
|
+
});
|
|
76
|
+
|
|
77
|
+
exports.TextContainer = TextContainer;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { FlexComponentProps } from '../Flex';
|
|
2
|
+
export declare type Size = 'small' | 'medium' | 'large';
|
|
3
|
+
export declare type Variant = 'normal' | 'inverted';
|
|
4
|
+
export interface LoadingProps extends Omit<FlexComponentProps, 'size'> {
|
|
5
|
+
title?: string;
|
|
6
|
+
description?: string;
|
|
7
|
+
variant?: Variant;
|
|
8
|
+
size?: Size;
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/Loading/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAE7C,oBAAY,IAAI,GAAG,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC;AAChD,oBAAY,OAAO,GAAG,QAAQ,GAAG,UAAU,CAAC;AAE5C,MAAM,WAAW,YAAa,SAAQ,IAAI,CAAC,kBAAkB,EAAE,MAAM,CAAC;IACpE,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,IAAI,CAAC,EAAE,IAAI,CAAC;CACb"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import React, { PropsWithChildren } from 'react';
|
|
2
|
+
import { ModalProps } from './types';
|
|
3
|
+
declare type ManagerProps = Pick<ModalProps, 'onClose' | 'visible'>;
|
|
4
|
+
declare function Manager({ onClose, visible, children, }: PropsWithChildren<ManagerProps>): React.ReactPortal | null;
|
|
5
|
+
export default Manager;
|
|
6
|
+
//# sourceMappingURL=Manager.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Manager.d.ts","sourceRoot":"","sources":["../../../src/components/Modal/Manager.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAA0B,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAIzE,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAGrC,aAAK,YAAY,GAAG,IAAI,CAAC,UAAU,EAAE,SAAS,GAAG,SAAS,CAAC,CAAC;AAE5D,iBAAS,OAAO,CAAC,EACf,OAAO,EACP,OAAO,EACP,QAAQ,GACT,EAAE,iBAAiB,CAAC,YAAY,CAAC,GAAG,KAAK,CAAC,WAAW,GAAG,IAAI,CA+B5D;AAED,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
var _react = require("react");
|
|
9
|
+
|
|
10
|
+
var _ConfigProvider = require("../../providers/ConfigProvider");
|
|
11
|
+
|
|
12
|
+
var _canUseDOM = _interopRequireDefault(require("../../utils/canUseDOM"));
|
|
13
|
+
|
|
14
|
+
var _utils = require("./utils");
|
|
15
|
+
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
|
+
|
|
18
|
+
function Manager(_ref) {
|
|
19
|
+
var onClose = _ref.onClose,
|
|
20
|
+
visible = _ref.visible,
|
|
21
|
+
children = _ref.children;
|
|
22
|
+
(0, _utils.useReturnFocus)(!visible);
|
|
23
|
+
|
|
24
|
+
var _useConfig = (0, _ConfigProvider.useConfig)(),
|
|
25
|
+
createPortal = _useConfig.createPortal;
|
|
26
|
+
|
|
27
|
+
var onKeyDown = (0, _react.useCallback)(function (event) {
|
|
28
|
+
if (event.key === 'Escape') {
|
|
29
|
+
onClose && onClose(event);
|
|
30
|
+
}
|
|
31
|
+
}, [onClose]); // Allow closing the modal by pressing the Escape key
|
|
32
|
+
|
|
33
|
+
(0, _react.useEffect)(function () {
|
|
34
|
+
if (visible && _canUseDOM.default) {
|
|
35
|
+
document.addEventListener('keydown', onKeyDown);
|
|
36
|
+
return function () {
|
|
37
|
+
document.removeEventListener('keydown', onKeyDown);
|
|
38
|
+
};
|
|
39
|
+
} // eslint has issues with no return statement here...
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
return undefined;
|
|
43
|
+
}, [visible, onKeyDown]);
|
|
44
|
+
|
|
45
|
+
if (visible) {
|
|
46
|
+
return createPortal(children);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
return null;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
var _default = Manager;
|
|
53
|
+
exports.default = _default;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React, { RefObject } from 'react';
|
|
2
|
+
import { sizes } from '@decisiv/breakpoint-observer';
|
|
3
|
+
import { ModalProps } from './types';
|
|
4
|
+
declare type Props = Pick<ModalProps, 'id' | 'onClose' | 'zIndex' | 'size'> & {
|
|
5
|
+
hasFooter?: boolean;
|
|
6
|
+
breakpoint: keyof typeof sizes | undefined;
|
|
7
|
+
observedElementRef: RefObject<HTMLDivElement>;
|
|
8
|
+
};
|
|
9
|
+
declare const ResponsiveModalWrapper: ({ children, breakpoint, hasFooter, id, size, onClose, zIndex, observedElementRef, }: React.PropsWithChildren<Props>) => JSX.Element;
|
|
10
|
+
export default ResponsiveModalWrapper;
|
|
11
|
+
//# sourceMappingURL=ResponsiveModalWrapper.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ResponsiveModalWrapper.d.ts","sourceRoot":"","sources":["../../../src/components/Modal/ResponsiveModalWrapper.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAkC,SAAS,EAAE,MAAM,OAAO,CAAC;AACzE,OAAO,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAC;AAGrD,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAIrC,aAAK,KAAK,GAAG,IAAI,CAAC,UAAU,EAAE,IAAI,GAAG,SAAS,GAAG,QAAQ,GAAG,MAAM,CAAC,GAAG;IACpE,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,EAAE,MAAM,OAAO,KAAK,GAAG,SAAS,CAAC;IAC3C,kBAAkB,EAAE,SAAS,CAAC,cAAc,CAAC,CAAC;CAC/C,CAAC;AAEF,QAAA,MAAM,sBAAsB,sIA4D3B,CAAC;AAEF,eAAe,sBAAsB,CAAC"}
|