@learningpool/ui 1.6.0 → 1.6.1
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/.eslintrc.js +40 -0
- package/.github/pull_request_template.md +23 -0
- package/.github/renovate.json +57 -0
- package/.github/workflows/integration.yml +53 -0
- package/.github/workflows/wss.yml +22 -0
- package/.jest-test-results.json +1 -0
- package/.releaserc +32 -0
- package/.storybook/learningpoolTheme.js +39 -0
- package/.storybook/main.js +21 -0
- package/.storybook/manager-head.html +175 -0
- package/.storybook/manager.js +34 -0
- package/.storybook/preview-head.html +212 -0
- package/.storybook/preview.js +120 -0
- package/.storybook/storybook-sort.js +54 -0
- package/CHANGELOG.md +6 -0
- package/amplify.yml +16 -0
- package/babel.config.json +14 -0
- package/{assets → dist/assets}/Images.d.ts +0 -0
- package/{assets → dist/assets}/Images.js +0 -0
- package/{components → dist/components}/atoms/Autocomplete/Autocomplete.d.ts +0 -0
- package/{components → dist/components}/atoms/Autocomplete/Autocomplete.js +0 -0
- package/{components → dist/components}/atoms/Button/Button.d.ts +0 -0
- package/{components → dist/components}/atoms/Button/Button.js +0 -0
- package/{components → dist/components}/atoms/Checkbox/Checkbox.d.ts +0 -0
- package/{components → dist/components}/atoms/Checkbox/Checkbox.js +0 -0
- package/{components → dist/components}/atoms/IconButton/IconButton.d.ts +0 -0
- package/{components → dist/components}/atoms/IconButton/IconButton.js +0 -0
- package/{components → dist/components}/atoms/Radio/Radio.d.ts +0 -0
- package/{components → dist/components}/atoms/Radio/Radio.js +0 -0
- package/{components → dist/components}/atoms/Select/Select.d.ts +0 -0
- package/{components → dist/components}/atoms/Select/Select.js +0 -0
- package/{components → dist/components}/atoms/Slider/Slider.d.ts +0 -0
- package/{components → dist/components}/atoms/Slider/Slider.js +0 -0
- package/{components → dist/components}/atoms/Switch/Switch.d.ts +0 -0
- package/{components → dist/components}/atoms/Switch/Switch.js +0 -0
- package/{components → dist/components}/atoms/TextField/TextField.d.ts +0 -0
- package/{components → dist/components}/atoms/TextField/TextField.js +0 -0
- package/{components → dist/components}/atoms/ToggleButton/ToggleButton.d.ts +0 -0
- package/{components → dist/components}/atoms/ToggleButton/ToggleButton.js +0 -0
- package/{components → dist/components}/datadisplay/Avatar/Avatar.d.ts +0 -0
- package/{components → dist/components}/datadisplay/Avatar/Avatar.js +0 -0
- package/{components → dist/components}/datadisplay/Chip/Chip.d.ts +0 -0
- package/{components → dist/components}/datadisplay/Chip/Chip.js +0 -0
- package/{components → dist/components}/datadisplay/List/List.d.ts +0 -0
- package/{components → dist/components}/datadisplay/List/List.js +0 -0
- package/{components → dist/components}/datadisplay/Tooltip/Tooltip.d.ts +0 -0
- package/{components → dist/components}/datadisplay/Tooltip/Tooltip.js +0 -0
- package/{components → dist/components}/feedback/Alert/Alert.d.ts +0 -0
- package/{components → dist/components}/feedback/Alert/Alert.js +0 -0
- package/{components → dist/components}/landmarks/Header/Header.d.ts +0 -0
- package/{components → dist/components}/landmarks/Header/Header.js +0 -0
- package/{components → dist/components}/landmarks/Header/HeaderActionButtons.d.ts +0 -0
- package/{components → dist/components}/landmarks/Header/HeaderActionButtons.js +0 -0
- package/{components → dist/components}/landmarks/Header/HeaderStyles.d.ts +0 -0
- package/{components → dist/components}/landmarks/Header/HeaderStyles.js +0 -0
- package/{components → dist/components}/navigation/Drawer/Drawer.d.ts +0 -0
- package/{components → dist/components}/navigation/Drawer/Drawer.js +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigation.d.ts +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigation.js +64 -41
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationAvatar.d.ts +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationAvatar.js +23 -19
- package/dist/components/navigation/MobileNavigation/MobileNavigationAvatarStyles.d.ts +3296 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationAvatarStyles.js +4 -4
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationDrawer.d.ts +0 -0
- package/dist/components/navigation/MobileNavigation/MobileNavigationDrawer.js +71 -0
- package/dist/components/navigation/MobileNavigation/MobileNavigationDrawerStyles.d.ts +1215 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationDrawerStyles.js +2 -2
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItem.d.ts +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItem.js +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenu.d.ts +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenu.js +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenuStyles.d.ts +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenuStyles.js +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemStyles.d.ts +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemStyles.js +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationMotion.d.ts +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationMotion.js +0 -0
- package/dist/components/navigation/MobileNavigation/MobileNavigationNotchIndicator.d.ts +3 -0
- package/dist/components/navigation/MobileNavigation/MobileNavigationNotchIndicator.js +19 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationSearch.d.ts +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationSearch.js +8 -6
- package/dist/components/navigation/MobileNavigation/MobileNavigationSearchStyles.d.ts +1080 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationSearchStyles.js +2 -2
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationStyles.d.ts +0 -0
- package/{components → dist/components}/navigation/MobileNavigation/MobileNavigationStyles.js +0 -0
- package/dist/components/navigation/MobileNavigation/MobileNavigationToggleSearchX.d.ts +3 -0
- package/dist/components/navigation/MobileNavigation/MobileNavigationToggleSearchX.js +28 -0
- package/dist/components/navigation/MobileNavigation/MobileNavigationToggleX.d.ts +3 -0
- package/dist/components/navigation/MobileNavigation/MobileNavigationToggleX.js +28 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigation.d.ts +0 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigation.js +18 -16
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationAvatar.d.ts +0 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationAvatar.js +20 -25
- package/dist/components/navigation/VerticalNavigation/VerticalNavigationAvatarStyles.d.ts +3296 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationAvatarStyles.js +4 -4
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItem.d.ts +0 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItem.js +5 -1
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenu.d.ts +0 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenu.js +0 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenuStyles.d.ts +0 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenuStyles.js +0 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemStyles.d.ts +0 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemStyles.js +0 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationMotion.d.ts +0 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationMotion.js +0 -0
- package/dist/components/navigation/VerticalNavigation/VerticalNavigationStyles.d.ts +1163 -0
- package/{components → dist/components}/navigation/VerticalNavigation/VerticalNavigationStyles.js +3 -2
- package/{components → dist/components}/pages/ErrorPage/ErrorPage.d.ts +0 -0
- package/{components → dist/components}/pages/ErrorPage/ErrorPage.js +0 -0
- package/{components → dist/components}/pages/ErrorPage/ErrorPageStyles.d.ts +0 -0
- package/{components → dist/components}/pages/ErrorPage/ErrorPageStyles.js +0 -0
- package/{components → dist/components}/pages/SideInSide/SideInSide.d.ts +0 -0
- package/{components → dist/components}/pages/SideInSide/SideInSide.js +0 -0
- package/{components → dist/components}/pages/SideInSide/SideInSideStyles.d.ts +0 -0
- package/{components → dist/components}/pages/SideInSide/SideInSideStyles.js +0 -0
- package/{components → dist/components}/stream/AppSwitcher/AppSwitcher.d.ts +0 -0
- package/{components → dist/components}/stream/AppSwitcher/AppSwitcher.js +0 -0
- package/{components → dist/components}/stream/AppSwitcher/AppSwitcherItem.d.ts +0 -0
- package/{components → dist/components}/stream/AppSwitcher/AppSwitcherItem.js +0 -0
- package/{components → dist/components}/stream/AppSwitcher/AppSwitcherStyles.d.ts +0 -0
- package/{components → dist/components}/stream/AppSwitcher/AppSwitcherStyles.js +0 -0
- package/{components → dist/components}/stream/AppSwitcher/constants.d.ts +0 -0
- package/{components → dist/components}/stream/AppSwitcher/constants.js +0 -0
- package/{index.d.ts → dist/index.d.ts} +0 -0
- package/{index.js → dist/index.js} +0 -0
- package/{lang → dist/lang}/en-us.d.ts +0 -0
- package/{lang → dist/lang}/en-us.js +0 -0
- package/dist/package.json +41 -0
- package/{types → dist/types}/components/navigation/VerticalNavigation.d.ts +0 -0
- package/{types → dist/types}/components/navigation/VerticalNavigation.js +0 -0
- package/{types → dist/types}/components/navigation/VerticalNavigationAvatar.d.ts +1 -0
- package/{types → dist/types}/components/navigation/VerticalNavigationAvatar.js +0 -0
- package/{types → dist/types}/components/stream/AppSwitcher.d.ts +0 -0
- package/{types → dist/types}/components/stream/AppSwitcher.js +0 -0
- package/{types → dist/types}/index.d.ts +0 -0
- package/{types → dist/types}/index.js +0 -0
- package/{utils → dist/utils}/constants.d.ts +0 -0
- package/{utils → dist/utils}/constants.js +0 -0
- package/dist/utils/helpers.d.ts +21 -0
- package/dist/utils/helpers.js +64 -0
- package/{utils → dist/utils}/hooks.d.ts +0 -0
- package/{utils → dist/utils}/hooks.js +0 -0
- package/{utils → dist/utils}/index.d.ts +0 -0
- package/{utils → dist/utils}/index.js +0 -0
- package/{utils → dist/utils}/theme.d.ts +0 -0
- package/{utils → dist/utils}/theme.js +0 -0
- package/jest.config.ts +11 -0
- package/jest.setup.ts +5 -0
- package/{LICENSE → license} +0 -0
- package/merge.js +27 -0
- package/package.json +71 -4
- package/public/android-chrome-192x192.png +0 -0
- package/public/android-chrome-512x512.png +0 -0
- package/public/apple-touch-icon.png +0 -0
- package/public/assets/atoms.svg +5 -0
- package/public/assets/automation.svg +1 -0
- package/public/assets/avatar-1.jpg +0 -0
- package/public/assets/avatar-2.jpg +0 -0
- package/public/assets/avatar-3.jpg +0 -0
- package/public/assets/flux/icon-dark.svg +6 -0
- package/public/assets/flux/icon-light.svg +1 -0
- package/public/assets/flux/icon-white.svg +6 -0
- package/public/assets/flux/icon.svg +6 -0
- package/public/assets/flux/logo-dark.svg +22 -0
- package/public/assets/flux/logo-light.svg +1 -0
- package/public/assets/flux/logo-white.svg +22 -0
- package/public/assets/flux/logo.svg +22 -0
- package/public/assets/iPhone6.jpg +0 -0
- package/public/assets/iPhone6Plus.jpg +0 -0
- package/public/assets/lp-logo.png +0 -0
- package/public/assets/lplogo.svg +1 -0
- package/public/assets/molecules.svg +8 -0
- package/public/assets/organisms.svg +21 -0
- package/public/assets/pages.svg +4 -0
- package/public/assets/particles.svg +3 -0
- package/public/assets/stream-dark.png +0 -0
- package/public/assets/stream-suite-logo.svg +38 -0
- package/public/assets/stream-white.png +0 -0
- package/public/assets/stream.png +0 -0
- package/public/assets/templates.svg +3 -0
- package/public/favicon-16x16.png +0 -0
- package/public/favicon-32x32.png +0 -0
- package/public/favicon.ico +0 -0
- package/public/index.html +43 -0
- package/public/logo192.png +0 -0
- package/public/logo512.png +0 -0
- package/public/manifest.json +25 -0
- package/public/robots.txt +3 -0
- package/public/site.webmanifest +1 -0
- package/{README.md → readme.md} +0 -0
- package/src/docs.tsx +167 -0
- package/src/lib/assets/Images.tsx +47 -0
- package/src/lib/assets/stream-suite-logo.svg +38 -0
- package/src/lib/components/atoms/Autocomplete/Autocomplete.test.tsx +179 -0
- package/src/lib/components/atoms/Autocomplete/Autocomplete.tsx +14 -0
- package/src/lib/components/atoms/Button/Button.test.tsx +166 -0
- package/src/lib/components/atoms/Button/Button.tsx +16 -0
- package/src/lib/components/atoms/Checkbox/Checkbox.test.tsx +85 -0
- package/src/lib/components/atoms/Checkbox/Checkbox.tsx +10 -0
- package/src/lib/components/atoms/IconButton/IconButton.test.tsx +60 -0
- package/src/lib/components/atoms/IconButton/IconButton.tsx +9 -0
- package/src/lib/components/atoms/Radio/Radio.test.tsx +136 -0
- package/src/lib/components/atoms/Radio/Radio.tsx +10 -0
- package/src/lib/components/atoms/Select/Select.test.tsx +158 -0
- package/src/lib/components/atoms/Select/Select.tsx +12 -0
- package/src/lib/components/atoms/Slider/Slider.test.tsx +103 -0
- package/src/lib/components/atoms/Slider/Slider.tsx +10 -0
- package/src/lib/components/atoms/Switch/Switch.test.tsx +96 -0
- package/src/lib/components/atoms/Switch/Switch.tsx +10 -0
- package/src/lib/components/atoms/TextField/TextField.test.tsx +131 -0
- package/src/lib/components/atoms/TextField/TextField.tsx +31 -0
- package/src/lib/components/atoms/ToggleButton/ToggleButton.test.tsx +122 -0
- package/src/lib/components/atoms/ToggleButton/ToggleButton.tsx +10 -0
- package/src/lib/components/datadisplay/Avatar/Avatar.test.tsx +187 -0
- package/src/lib/components/datadisplay/Avatar/Avatar.tsx +35 -0
- package/src/lib/components/datadisplay/Avatar/avatar-1.jpg +0 -0
- package/src/lib/components/datadisplay/Chip/Chip.test.tsx +82 -0
- package/src/lib/components/datadisplay/Chip/Chip.tsx +11 -0
- package/src/lib/components/datadisplay/List/List.test.tsx +168 -0
- package/src/lib/components/datadisplay/List/List.tsx +8 -0
- package/src/lib/components/datadisplay/Tooltip/Tooltip.test.tsx +98 -0
- package/src/lib/components/datadisplay/Tooltip/Tooltip.tsx +9 -0
- package/src/lib/components/feedback/Alert/Alert.test.tsx +139 -0
- package/src/lib/components/feedback/Alert/Alert.tsx +10 -0
- package/src/lib/components/landmarks/Header/Header.tsx +140 -0
- package/src/lib/components/landmarks/Header/HeaderActionButtons.tsx +117 -0
- package/src/lib/components/landmarks/Header/HeaderStyles.tsx +62 -0
- package/src/lib/components/navigation/Drawer/Drawer.test.tsx +95 -0
- package/src/lib/components/navigation/Drawer/Drawer.tsx +21 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigation.tsx +276 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationAvatar.tsx +334 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationAvatarStyles.tsx +77 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationDrawer.tsx +197 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationDrawerStyles.tsx +143 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItem.tsx +192 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenu.tsx +67 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenuStyles.tsx +192 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemStyles.tsx +217 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationMotion.tsx +119 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationNotchIndicator.tsx +35 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationSearch.tsx +114 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationSearchStyles.tsx +47 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationStyles.tsx +320 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationToggleSearchX.tsx +59 -0
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationToggleX.tsx +51 -0
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigation.tsx +467 -0
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationAvatar.tsx +208 -0
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationAvatarStyles.tsx +75 -0
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItem.tsx +196 -0
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenu.tsx +94 -0
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenuStyles.tsx +212 -0
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemStyles.tsx +240 -0
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationMotion.tsx +119 -0
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationStyles.tsx +303 -0
- package/src/lib/components/pages/ErrorPage/ErrorPage.test.tsx +78 -0
- package/src/lib/components/pages/ErrorPage/ErrorPage.tsx +50 -0
- package/src/lib/components/pages/ErrorPage/ErrorPageStyles.tsx +30 -0
- package/src/lib/components/pages/SideInSide/SideInSide.tsx +100 -0
- package/src/lib/components/pages/SideInSide/SideInSideStyles.tsx +62 -0
- package/src/lib/components/stream/AppSwitcher/AppSwitcher.tsx +392 -0
- package/src/lib/components/stream/AppSwitcher/AppSwitcherItem.tsx +83 -0
- package/src/lib/components/stream/AppSwitcher/AppSwitcherStyles.tsx +325 -0
- package/src/lib/components/stream/AppSwitcher/constants.tsx +28 -0
- package/src/lib/index.tsx +148 -0
- package/src/lib/lang/en-us.js +6 -0
- package/src/lib/types/components/navigation/VerticalNavigation.ts +52 -0
- package/src/lib/types/components/navigation/VerticalNavigationAvatar.ts +26 -0
- package/src/lib/types/components/stream/AppSwitcher.ts +10 -0
- package/src/lib/types/index.ts +9 -0
- package/src/lib/utils/constants.tsx +11 -0
- package/src/lib/utils/helpers.tsx +77 -0
- package/src/lib/utils/hooks.tsx +33 -0
- package/src/lib/utils/index.tsx +4 -0
- package/src/lib/utils/theme.tsx +79 -0
- package/src/react-app-env.d.ts +1 -0
- package/src/setupTests.ts +5 -0
- package/src/stories/Components/DataDisplay/Avatar/Accessibility.stories.mdx +34 -0
- package/src/stories/Components/DataDisplay/Avatar/AllCombinations.tsx +56 -0
- package/src/stories/Components/DataDisplay/Avatar/Avatar.stories.tsx +19 -0
- package/src/stories/Components/DataDisplay/Avatar/Examples.stories.tsx +278 -0
- package/src/stories/Components/DataDisplay/Avatar/Overview.stories.mdx +47 -0
- package/src/stories/Components/DataDisplay/Chip/Accessibility.stories.mdx +29 -0
- package/src/stories/Components/DataDisplay/Chip/AllCombinations.tsx +58 -0
- package/src/stories/Components/DataDisplay/Chip/Chip.stories.tsx +21 -0
- package/src/stories/Components/DataDisplay/Chip/Examples.stories.tsx +126 -0
- package/src/stories/Components/DataDisplay/Chip/Overview.stories.mdx +57 -0
- package/src/stories/Components/DataDisplay/List/Accessibility.stories.mdx +54 -0
- package/src/stories/Components/DataDisplay/List/AllCombinations.tsx +396 -0
- package/src/stories/Components/DataDisplay/List/Examples.stories.tsx +501 -0
- package/src/stories/Components/DataDisplay/List/List.stories.tsx +35 -0
- package/src/stories/Components/DataDisplay/List/Overview.stories.mdx +69 -0
- package/src/stories/Components/DataDisplay/Table/Overview.stories.mdx +70 -0
- package/src/stories/Components/DataDisplay/Tooltip/Accessibility.stories.mdx +39 -0
- package/src/stories/Components/DataDisplay/Tooltip/AllCombinations.tsx +134 -0
- package/src/stories/Components/DataDisplay/Tooltip/Examples.stories.tsx +237 -0
- package/src/stories/Components/DataDisplay/Tooltip/Overview.stories.mdx +58 -0
- package/src/stories/Components/DataDisplay/Tooltip/Tooltip.stories.tsx +22 -0
- package/src/stories/Components/Feedback/Alert/Accessibility.stories.mdx +25 -0
- package/src/stories/Components/Feedback/Alert/Alert.stories.tsx +22 -0
- package/src/stories/Components/Feedback/Alert/AllCombinations.tsx +37 -0
- package/src/stories/Components/Feedback/Alert/Examples.stories.tsx +137 -0
- package/src/stories/Components/Feedback/Alert/Overview.stories.mdx +62 -0
- package/src/stories/Components/Inputs/Autocomplete/Accessibility.stories.mdx +31 -0
- package/src/stories/Components/Inputs/Autocomplete/AllCombinations.tsx +182 -0
- package/src/stories/Components/Inputs/Autocomplete/Autocomplete.stories.tsx +31 -0
- package/src/stories/Components/Inputs/Autocomplete/Examples.stories.tsx +233 -0
- package/src/stories/Components/Inputs/Autocomplete/Overview.stories.mdx +52 -0
- package/src/stories/Components/Inputs/Button/Accessibility.stories.mdx +52 -0
- package/src/stories/Components/Inputs/Button/AllCombinations.tsx +53 -0
- package/src/stories/Components/Inputs/Button/Button.stories.tsx +23 -0
- package/src/stories/Components/Inputs/Button/Examples.stories.tsx +190 -0
- package/src/stories/Components/Inputs/Button/Overview.stories.mdx +52 -0
- package/src/stories/Components/Inputs/Checkbox/Accessibility.stories.mdx +38 -0
- package/src/stories/Components/Inputs/Checkbox/AllCombinations.tsx +55 -0
- package/src/stories/Components/Inputs/Checkbox/Checkbox.stories.tsx +22 -0
- package/src/stories/Components/Inputs/Checkbox/Examples.stories.tsx +363 -0
- package/src/stories/Components/Inputs/Checkbox/Overview.stories.mdx +63 -0
- package/src/stories/Components/Inputs/IconButton/Examples.stories.tsx +24 -0
- package/src/stories/Components/Inputs/IconButton/IconButton.stories.tsx +26 -0
- package/src/stories/Components/Inputs/Radio/Accessibility.stories.mdx +61 -0
- package/src/stories/Components/Inputs/Radio/AllCombinations.tsx +75 -0
- package/src/stories/Components/Inputs/Radio/Examples.stories.tsx +333 -0
- package/src/stories/Components/Inputs/Radio/Overview.stories.mdx +74 -0
- package/src/stories/Components/Inputs/Radio/Radio.stories.tsx +22 -0
- package/src/stories/Components/Inputs/Select/Accessibility.stories.mdx +51 -0
- package/src/stories/Components/Inputs/Select/AllCombinations.tsx +63 -0
- package/src/stories/Components/Inputs/Select/Examples.stories.tsx +803 -0
- package/src/stories/Components/Inputs/Select/Overview.stories.mdx +73 -0
- package/src/stories/Components/Inputs/Select/Select.stories.tsx +22 -0
- package/src/stories/Components/Inputs/Slider/Accessibility.stories.mdx +43 -0
- package/src/stories/Components/Inputs/Slider/AllCombinations.tsx +30 -0
- package/src/stories/Components/Inputs/Slider/Examples.stories.tsx +146 -0
- package/src/stories/Components/Inputs/Slider/Overview.stories.mdx +59 -0
- package/src/stories/Components/Inputs/Slider/Slider.stories.tsx +27 -0
- package/src/stories/Components/Inputs/Switch/Accessibility.stories.mdx +34 -0
- package/src/stories/Components/Inputs/Switch/AllCombinations.tsx +45 -0
- package/src/stories/Components/Inputs/Switch/Examples.stories.tsx +213 -0
- package/src/stories/Components/Inputs/Switch/Overview.stories.mdx +62 -0
- package/src/stories/Components/Inputs/Switch/Switch.stories.tsx +22 -0
- package/src/stories/Components/Inputs/TextField/Accessibility.stories.mdx +29 -0
- package/src/stories/Components/Inputs/TextField/AllCombinations.tsx +57 -0
- package/src/stories/Components/Inputs/TextField/Examples.stories.tsx +127 -0
- package/src/stories/Components/Inputs/TextField/Overview.stories.mdx +60 -0
- package/src/stories/Components/Inputs/TextField/TextField.stories.tsx +261 -0
- package/src/stories/Components/Inputs/ToggleButton/Accessibility.stories.mdx +32 -0
- package/src/stories/Components/Inputs/ToggleButton/AllCombinations.tsx +113 -0
- package/src/stories/Components/Inputs/ToggleButton/Examples.stories.tsx +339 -0
- package/src/stories/Components/Inputs/ToggleButton/Overview.stories.mdx +55 -0
- package/src/stories/Components/Inputs/ToggleButton/ToggleButton.stories.tsx +19 -0
- package/src/stories/Components/Landmarks/Header/Examples.stories.tsx +197 -0
- package/src/stories/Components/Landmarks/Header/Header.stories.tsx +34 -0
- package/src/stories/Components/Landmarks/Header/Overview.stories.mdx +44 -0
- package/src/stories/Components/Navigation/Drawer/Accessibility.stories.mdx +13 -0
- package/src/stories/Components/Navigation/Drawer/Drawer.stories.tsx +80 -0
- package/src/stories/Components/Navigation/Drawer/Examples.stories.tsx +440 -0
- package/src/stories/Components/Navigation/Drawer/Overview.stories.mdx +43 -0
- package/src/stories/Components/Navigation/MobileNavigation/Accessibility.stories.mdx +14 -0
- package/src/stories/Components/Navigation/MobileNavigation/Examples.stories.tsx +384 -0
- package/src/stories/Components/Navigation/MobileNavigation/MobileNavigation.stories.tsx +24 -0
- package/src/stories/Components/Navigation/MobileNavigation/Overview.stories.mdx +47 -0
- package/src/stories/Components/Navigation/VerticalNavigation/Accessibility.stories.mdx +14 -0
- package/src/stories/Components/Navigation/VerticalNavigation/Examples.stories.tsx +307 -0
- package/src/stories/Components/Navigation/VerticalNavigation/Overview.stories.mdx +47 -0
- package/src/stories/Components/Navigation/VerticalNavigation/VerticalNavigation.stories.tsx +24 -0
- package/src/stories/ContactUs.stories.mdx +21 -0
- package/src/stories/Experimental/Test.stories.mdx +46 -0
- package/src/stories/GettingStarted/Designer.stories.mdx +86 -0
- package/src/stories/GettingStarted/Developer.stories.mdx +134 -0
- package/src/stories/Guidelines/Accessibility/AssistiveTechnology.stories.mdx +70 -0
- package/src/stories/Guidelines/Accessibility/ColorAndContrast.stories.mdx +109 -0
- package/src/stories/Guidelines/Accessibility/Hierarchy.stories.mdx +119 -0
- package/src/stories/Guidelines/Accessibility/Imagery.stories.mdx +136 -0
- package/src/stories/Guidelines/Accessibility/Overview.stories.mdx +44 -0
- package/src/stories/Guidelines/Accessibility/Principles.stories.mdx +156 -0
- package/src/stories/Guidelines/Accessibility/SoundAndMotion.stories.mdx +59 -0
- package/src/stories/Guidelines/Accessibility/Typography.stories.mdx +69 -0
- package/src/stories/Guidelines/Accessibility/Writing.stories.mdx +188 -0
- package/src/stories/Guidelines/Styleguide/ColorSwatch.tsx +53 -0
- package/src/stories/Guidelines/Styleguide/Colors.stories.mdx +118 -0
- package/src/stories/Guidelines/Styleguide/Typography.stories.mdx +84 -0
- package/src/stories/Introduction.stories.mdx +65 -0
- package/src/stories/Pages/ErrorPage.stories.tsx +30 -0
- package/src/stories/Pages/SideInSide.stories.tsx +195 -0
- package/src/stories/Roadmap.stories.mdx +19 -0
- package/src/stories/Templates/Login.stories.mdx +46 -0
- package/src/stories/assets/Atomic_Design_Icons-Dark.svg +24 -0
- package/src/stories/assets/Atomic_Design_Icons-Light.svg +25 -0
- package/src/stories/assets/accessibility-1.png +0 -0
- package/src/stories/assets/accessibility-2.png +0 -0
- package/src/stories/assets/accessibility-3.png +0 -0
- package/src/stories/assets/accessibility-banner.png +0 -0
- package/src/stories/assets/atoms.svg +6 -0
- package/src/stories/assets/design_system_2022-02-11_12.22pm.png +0 -0
- package/src/stories/assets/figma-tokens.png +0 -0
- package/src/stories/assets/hierarchy-1.jpg +0 -0
- package/src/stories/assets/hierarchy-2.jpg +0 -0
- package/src/stories/assets/hierarchy-3.jpg +0 -0
- package/src/stories/assets/icon-contrast-1.jpg +0 -0
- package/src/stories/assets/icon-contrast-2.jpg +0 -0
- package/src/stories/assets/imagery-1.png +0 -0
- package/src/stories/assets/imagery-2.png +0 -0
- package/src/stories/assets/imagery-3.png +0 -0
- package/src/stories/assets/imagery-4.jpg +0 -0
- package/src/stories/assets/molecules.svg +9 -0
- package/src/stories/assets/organisms.svg +22 -0
- package/src/stories/assets/pages.svg +5 -0
- package/src/stories/assets/particles.svg +4 -0
- package/src/stories/assets/templates.svg +4 -0
- package/src/stories/assets/testData.tsx +102 -0
- package/src/stories/assets/text-contrast-1.jpg +0 -0
- package/src/stories/assets/text-contrast-2.jpg +0 -0
- package/src/stories/assets/typography-1.png +0 -0
- package/src/stories/assets/visual-clues-1.png +0 -0
- package/src/stories/assets/visual-clues-2.png +0 -0
- package/src/stories/assets/writing-1.jpg +0 -0
- package/src/stories/assets/writing-2.png +0 -0
- package/src/stories/assets/writing-3.png +0 -0
- package/src/stories/assets/writing-4.png +0 -0
- package/src/stories/utils/CustomIcons.tsx +44 -0
- package/tsconfig.eslint.json +16 -0
- package/tsconfig.json +50 -0
- package/components/navigation/MobileNavigation/MobileNavigationAvatarStyles.d.ts +0 -827
- package/components/navigation/MobileNavigation/MobileNavigationDrawer.js +0 -147
- package/components/navigation/MobileNavigation/MobileNavigationDrawerStyles.d.ts +0 -392
- package/components/navigation/MobileNavigation/MobileNavigationNotchIndicator.d.ts +0 -3
- package/components/navigation/MobileNavigation/MobileNavigationNotchIndicator.js +0 -31
- package/components/navigation/MobileNavigation/MobileNavigationSearchStyles.d.ts +0 -257
- package/components/navigation/MobileNavigation/MobileNavigationToggleSearchX.d.ts +0 -3
- package/components/navigation/MobileNavigation/MobileNavigationToggleSearchX.js +0 -33
- package/components/navigation/MobileNavigation/MobileNavigationToggleX.d.ts +0 -3
- package/components/navigation/MobileNavigation/MobileNavigationToggleX.js +0 -27
- package/components/navigation/MobileNavigation/MobileNavigationToggleXStyles.d.ts +0 -36
- package/components/navigation/MobileNavigation/MobileNavigationToggleXStyles.js +0 -10
- package/components/navigation/VerticalNavigation/VerticalNavigationAvatarStyles.d.ts +0 -827
- package/components/navigation/VerticalNavigation/VerticalNavigationStyles.d.ts +0 -88
- package/utils/helpers.d.ts +0 -6
- package/utils/helpers.js +0 -17
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import {
|
|
2
|
+
SwipeableDrawer, OutlinedInput, InputLabel
|
|
3
|
+
} from '../../../index'
|
|
4
|
+
import { styled } from '@mui/material/styles'
|
|
5
|
+
import { animated } from '@react-spring/web'
|
|
6
|
+
|
|
7
|
+
export const StyledSwipeableSearch = styled(SwipeableDrawer)`
|
|
8
|
+
.MuiPaper-root {
|
|
9
|
+
box-shadow: 0px 3px 5px -1px rgba(0, 0, 0, 0.2),
|
|
10
|
+
0px 5px 8px 0px rgba(0, 0, 0, 0.14),
|
|
11
|
+
0px 1px 14px 0px rgba(0, 0, 0, 0.12);
|
|
12
|
+
border: none;
|
|
13
|
+
border-radius: 20px 20px 0 0;
|
|
14
|
+
z-index: 1;
|
|
15
|
+
}
|
|
16
|
+
`
|
|
17
|
+
|
|
18
|
+
export const StyledBox = styled(animated.div)`
|
|
19
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
20
|
+
? '#003366'
|
|
21
|
+
: props.theme.palette.background.paper};
|
|
22
|
+
background-image: ${props => props.theme.palette.mode === 'dark'
|
|
23
|
+
? 'none'
|
|
24
|
+
: 'radial-gradient( circle farthest-corner at 10% 20%, #fdfbfb 0.1%, #ebedee 99.8% )'};
|
|
25
|
+
padding: ${props => props.theme.spacing(3, 2.5, '80px', 2.5)};
|
|
26
|
+
height: 100%;
|
|
27
|
+
`
|
|
28
|
+
|
|
29
|
+
export const StyledOutlinedInputLabel = styled(InputLabel)`
|
|
30
|
+
&.Mui-focused {
|
|
31
|
+
color: ${props => props.theme.palette.mode === 'dark' ? props.theme.palette.primary.contrastText : '#003366'};
|
|
32
|
+
}
|
|
33
|
+
`
|
|
34
|
+
|
|
35
|
+
export const StyledOutlinedInput = styled(OutlinedInput)`
|
|
36
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
37
|
+
? '#003366'
|
|
38
|
+
: props.theme.palette.background.paper};
|
|
39
|
+
color: ${props => props.theme.palette.mode === 'dark'
|
|
40
|
+
? props.theme.palette.primary.contrastText
|
|
41
|
+
: props.theme.palette.text.primary};
|
|
42
|
+
|
|
43
|
+
&:hover .MuiOutlinedInput-notchedOutline,
|
|
44
|
+
&.Mui-focused .MuiOutlinedInput-notchedOutline {
|
|
45
|
+
border-color: ${props => props.theme.palette.mode === 'dark' ? props.theme.palette.primary.contrastText : '#003366'};
|
|
46
|
+
}
|
|
47
|
+
`
|
|
@@ -0,0 +1,320 @@
|
|
|
1
|
+
import Drawer from '@mui/material/Drawer'
|
|
2
|
+
import {
|
|
3
|
+
Box, IconButton, BottomNavigation,
|
|
4
|
+
BottomNavigationAction, Paper
|
|
5
|
+
} from '../../../index'
|
|
6
|
+
import { styled } from '@mui/material/styles'
|
|
7
|
+
import { motion } from '../../../utils/theme'
|
|
8
|
+
|
|
9
|
+
export const DRAWER_WIDTH = {
|
|
10
|
+
Collapsed: 60,
|
|
11
|
+
Expanded: 300
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export const StyledPaper = styled(Paper)`
|
|
15
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
16
|
+
? props.theme.palette.primary.main
|
|
17
|
+
: props.theme.palette.background.paper};
|
|
18
|
+
background-image: none;
|
|
19
|
+
border-radius: 0;
|
|
20
|
+
bottom: 0;
|
|
21
|
+
left: 0;
|
|
22
|
+
position: fixed;
|
|
23
|
+
right: 0;
|
|
24
|
+
z-index: 1000000000;
|
|
25
|
+
`
|
|
26
|
+
|
|
27
|
+
export const StyledNotchSVG = styled('svg', {
|
|
28
|
+
shouldForwardProp: (prop) => prop !== 'mobileNotchPosition'
|
|
29
|
+
})<{ mobileNotchPosition?: number }>`
|
|
30
|
+
display: block;
|
|
31
|
+
fill: ${props => props.theme.palette.mode === 'dark'
|
|
32
|
+
? props.theme.palette.primary.main
|
|
33
|
+
: props.theme.palette.background.paper};
|
|
34
|
+
height: 50px;
|
|
35
|
+
left: 0;
|
|
36
|
+
padding: 0;
|
|
37
|
+
position: absolute;
|
|
38
|
+
stroke: transparent;
|
|
39
|
+
top: -29px;
|
|
40
|
+
transform: rotate(270deg);
|
|
41
|
+
width: 50px;
|
|
42
|
+
z-index: -1;
|
|
43
|
+
`
|
|
44
|
+
|
|
45
|
+
export const StyledBottomNavigation = styled(BottomNavigation)`
|
|
46
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
47
|
+
? props.theme.palette.primary.main
|
|
48
|
+
: props.theme.palette.background.paper};
|
|
49
|
+
position: relative;
|
|
50
|
+
`
|
|
51
|
+
|
|
52
|
+
export const StyledBottomNavigationAction = styled(BottomNavigationAction)`
|
|
53
|
+
backgroundColor: ${props => props.theme.palette.mode === 'dark'
|
|
54
|
+
? props.theme.palette.primary.main
|
|
55
|
+
: props.theme.palette.background.paper};
|
|
56
|
+
color: ${props => props.theme.palette.mode === 'dark'
|
|
57
|
+
? props.theme.palette.primary.contrastText
|
|
58
|
+
: props.theme.palette.getContrastText(props.theme.palette.background.paper)};
|
|
59
|
+
flex: none;
|
|
60
|
+
height: 56px;
|
|
61
|
+
max-width: 168px;
|
|
62
|
+
min-width: 80px;
|
|
63
|
+
overflow: hidden;
|
|
64
|
+
padding: 0;
|
|
65
|
+
stroke: ${props => props.theme.palette.mode === 'dark'
|
|
66
|
+
? props.theme.palette.primary.contrastText
|
|
67
|
+
: props.theme.palette.text.primary};
|
|
68
|
+
|
|
69
|
+
.MuiBottomNavigationAction-label {
|
|
70
|
+
color: inherit;
|
|
71
|
+
font-size: 0.65rem;
|
|
72
|
+
|
|
73
|
+
// Handle long text string overflow
|
|
74
|
+
overflow: hidden;
|
|
75
|
+
text-overflow: ellipsis;
|
|
76
|
+
white-space: nowrap;
|
|
77
|
+
width: 100%;
|
|
78
|
+
|
|
79
|
+
&.Mui-selected {
|
|
80
|
+
color: ${props =>
|
|
81
|
+
props.theme.palette.mode === 'dark'
|
|
82
|
+
? props.theme.palette.primary.contrastText
|
|
83
|
+
: props.theme.palette.getContrastText(props.theme.palette.background.paper)};
|
|
84
|
+
font-size: 0.75rem;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.MuiSvgIcon-root {
|
|
89
|
+
fill: ${props =>
|
|
90
|
+
props.theme.palette.mode === 'dark'
|
|
91
|
+
? props.theme.palette.primary.contrastText
|
|
92
|
+
: props.theme.palette.getContrastText(props.theme.palette.background.paper)};
|
|
93
|
+
}
|
|
94
|
+
`
|
|
95
|
+
|
|
96
|
+
export const DrawerHeader = styled('div', {
|
|
97
|
+
shouldForwardProp: (prop) => prop !== 'isDrawerOpen'
|
|
98
|
+
})<{ isDrawerOpen?: any }>`
|
|
99
|
+
`
|
|
100
|
+
|
|
101
|
+
export const DrawerToggle = styled(IconButton)`
|
|
102
|
+
background: transparent;
|
|
103
|
+
height: 44px;
|
|
104
|
+
padding: 0 ${props => props.theme.spacing(2)} !important;
|
|
105
|
+
position: absolute;
|
|
106
|
+
transform: translate(22px, calc(50% - 5.5px));
|
|
107
|
+
transition: all 225ms ${motion.easeInOut} 0ms !important;
|
|
108
|
+
width: 44px;
|
|
109
|
+
z-index: 10;
|
|
110
|
+
|
|
111
|
+
@media (min-width: ${props => props.theme.breakpoints.values.sm}) {
|
|
112
|
+
padding: 0 ${props => props.theme.spacing(2.5)} !important;
|
|
113
|
+
}
|
|
114
|
+
`
|
|
115
|
+
|
|
116
|
+
export const DrawerToggleHitboxContent = styled('span')`
|
|
117
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
118
|
+
? props.theme.palette.primary.main
|
|
119
|
+
: props.theme.palette.background.paper};
|
|
120
|
+
border-radius: 50%;
|
|
121
|
+
box-shadow: 5px 0 15px 0 rgb(0 0 0 / 10%);
|
|
122
|
+
box-sizing: content-box;
|
|
123
|
+
height: 1.75rem;
|
|
124
|
+
padding: ${props => props.theme.spacing(0.5)};
|
|
125
|
+
width: 1.75rem;
|
|
126
|
+
`
|
|
127
|
+
|
|
128
|
+
export const StyledAside = styled('aside')``
|
|
129
|
+
|
|
130
|
+
export const StyledNav = styled('nav')`
|
|
131
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
132
|
+
? props.theme.palette.primary.main
|
|
133
|
+
: props.theme.palette.background.paper};
|
|
134
|
+
display: flex;
|
|
135
|
+
flex: 1 auto;
|
|
136
|
+
flex-direction: column;
|
|
137
|
+
justify-content: flex-start;
|
|
138
|
+
margin-top: -1px;
|
|
139
|
+
overflow-x: hidden;
|
|
140
|
+
overflow-y: auto;
|
|
141
|
+
|
|
142
|
+
// Firefox and future scrollbars
|
|
143
|
+
* & {
|
|
144
|
+
scrollbar-width: thin;
|
|
145
|
+
scrollbar-color: ${props =>
|
|
146
|
+
props.theme.palette.mode === 'dark'
|
|
147
|
+
? 'rgba(255, 255, 255, 0.12) transparent'
|
|
148
|
+
: 'rgba(0, 0, 0, 0.12) transparent'};
|
|
149
|
+
transition: backgroundColor 225ms ${motion.easeIn};
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
* &:hover {
|
|
153
|
+
scrollbar-color: ${props =>
|
|
154
|
+
props.theme.palette.mode === 'dark'
|
|
155
|
+
? 'rgba(255, 255, 255, 0.24) transparent'
|
|
156
|
+
: 'rgba(0, 0, 0, 0.24) transparent'};
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
// Webkit and fall back scrollbars
|
|
160
|
+
::-webkit-scrollbar {
|
|
161
|
+
width: 8px;
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
::-webkit-scrollbar-track {
|
|
165
|
+
background-color: transparent;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
::-webkit-scrollbar-thumb {
|
|
169
|
+
background-color: ${props =>
|
|
170
|
+
props.theme.palette.mode === 'dark'
|
|
171
|
+
? 'rgba(255, 255, 255, 0.12)'
|
|
172
|
+
: 'rgba(0, 0, 0, 0.12)'};
|
|
173
|
+
border-radius: 55px;
|
|
174
|
+
transition: background-color 225ms ${motion.easeIn};
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
::-webkit-scrollbar-thumb:hover {
|
|
178
|
+
background-color: ${props =>
|
|
179
|
+
props.theme.palette.mode === 'dark'
|
|
180
|
+
? 'rgba(255, 255, 255, 0.24)'
|
|
181
|
+
: 'rgba(0, 0, 0, 0.24)'};
|
|
182
|
+
}
|
|
183
|
+
`
|
|
184
|
+
|
|
185
|
+
export const StyledNavSecondary = styled('nav')`
|
|
186
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
187
|
+
? props.theme.palette.primary.main
|
|
188
|
+
: props.theme.palette.background.paper};
|
|
189
|
+
display: flex;
|
|
190
|
+
flex: 1 auto;
|
|
191
|
+
flex-direction: column;
|
|
192
|
+
justify-content: flex-end;
|
|
193
|
+
margin-top: auto;
|
|
194
|
+
overflow: hidden;
|
|
195
|
+
`
|
|
196
|
+
export const DrawerShadow = styled(Box, {
|
|
197
|
+
shouldForwardProp: (prop) => prop !== 'isDrawerOpen'
|
|
198
|
+
})<{ isDrawerOpen?: boolean }>`
|
|
199
|
+
background: rgba(0,0,0,0.125);
|
|
200
|
+
content: '';
|
|
201
|
+
display: block;
|
|
202
|
+
filter: blur(13px);
|
|
203
|
+
height: 100%;
|
|
204
|
+
left: ${props => props.isDrawerOpen
|
|
205
|
+
? `${DRAWER_WIDTH.Expanded - 38}px`
|
|
206
|
+
: `${DRAWER_WIDTH.Collapsed - 41}px`};
|
|
207
|
+
position: fixed;
|
|
208
|
+
top: 0;
|
|
209
|
+
transition: left 225ms ${motion.easeInOut} 0ms;
|
|
210
|
+
visibility: visible;
|
|
211
|
+
width: 40px;
|
|
212
|
+
|
|
213
|
+
@media (min-width: ${props => props.theme.breakpoints.values.sm}) {
|
|
214
|
+
left: ${props =>
|
|
215
|
+
props.isDrawerOpen
|
|
216
|
+
? `${DRAWER_WIDTH.Expanded - 38}px`
|
|
217
|
+
: `${DRAWER_WIDTH.Collapsed - 33}px`};
|
|
218
|
+
}
|
|
219
|
+
`
|
|
220
|
+
|
|
221
|
+
export const NotchContainer = styled(Box)`
|
|
222
|
+
display: flex;
|
|
223
|
+
justify-content: flex-end;
|
|
224
|
+
height: auto;
|
|
225
|
+
margin-top: -${props => props.theme.spacing(0.5)};
|
|
226
|
+
position: relative;
|
|
227
|
+
transition: width 225ms ${motion.easeInOut} 0ms !important;
|
|
228
|
+
width: 100%;
|
|
229
|
+
z-index: 9;
|
|
230
|
+
`
|
|
231
|
+
|
|
232
|
+
export const NotchBackground = styled(Box)`
|
|
233
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
234
|
+
? props.theme.palette.primary.main
|
|
235
|
+
: props.theme.palette.background.paper};
|
|
236
|
+
flex: 1;
|
|
237
|
+
height: auto;
|
|
238
|
+
width: auto;
|
|
239
|
+
`
|
|
240
|
+
|
|
241
|
+
export const NotchBackgroundClip = styled(Box)`
|
|
242
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
243
|
+
? props.theme.palette.primary.main
|
|
244
|
+
: props.theme.palette.background.paper};
|
|
245
|
+
clip-path: url("#notch");
|
|
246
|
+
display: flex;
|
|
247
|
+
height: 85px;
|
|
248
|
+
width: 45px;
|
|
249
|
+
`
|
|
250
|
+
|
|
251
|
+
export const NotchSeemMask = styled(Box)`
|
|
252
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
253
|
+
? props.theme.palette.primary.main
|
|
254
|
+
: props.theme.palette.background.paper};
|
|
255
|
+
height: 90px;
|
|
256
|
+
position: absolute;
|
|
257
|
+
right: 25px;
|
|
258
|
+
top: -2px;
|
|
259
|
+
width: calc(100% - 25px);
|
|
260
|
+
`
|
|
261
|
+
|
|
262
|
+
export const StyledDrawer = styled(Drawer, {
|
|
263
|
+
shouldForwardProp: (prop) => prop !== 'open'
|
|
264
|
+
})<{ open?: boolean }>`
|
|
265
|
+
box-shadow: none;
|
|
266
|
+
box-sizing: border-box;
|
|
267
|
+
flexshrink: 0;
|
|
268
|
+
overflow-x: visible;
|
|
269
|
+
transition: width 225ms ${motion.easeInOut} 0ms !important;
|
|
270
|
+
white-space: nowrap;
|
|
271
|
+
width: ${props => !props.open ? `calc(${props.theme.spacing(7)} + 1px)` : `${DRAWER_WIDTH.Expanded}px`};
|
|
272
|
+
|
|
273
|
+
@media (min-width: ${props => props.theme.breakpoints.values.sm}) {
|
|
274
|
+
width: ${props => !props.open ? `calc(${props.theme.spacing(8)} + 1px)` : `${DRAWER_WIDTH.Expanded}px`};
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
.MuiDrawer-paper {
|
|
278
|
+
background: transparent none;
|
|
279
|
+
border: 0;
|
|
280
|
+
box-shadow: none;
|
|
281
|
+
color: ${props =>
|
|
282
|
+
props.theme.palette.mode === 'dark'
|
|
283
|
+
? props.theme.palette.primary.contrastText
|
|
284
|
+
: props.theme.palette.getContrastText(props.theme.palette.background.paper)};
|
|
285
|
+
overflow: visible !important;
|
|
286
|
+
overflow-x: visible;
|
|
287
|
+
transform: translateX(0) !important;
|
|
288
|
+
transition: width 225ms ${motion.easeInOut} 0ms !important;
|
|
289
|
+
visibility: visible;
|
|
290
|
+
width: ${props => !props.open ? `calc(${props.theme.spacing(7)} + 1px)` : `${DRAWER_WIDTH.Expanded}px`};
|
|
291
|
+
|
|
292
|
+
[theme.breakpoints.up('sm')] {
|
|
293
|
+
width: ${props => !props.open ? `calc(${props.theme.spacing(8)} + 1px)` : `${DRAWER_WIDTH.Expanded}px`};
|
|
294
|
+
}
|
|
295
|
+
}
|
|
296
|
+
`
|
|
297
|
+
|
|
298
|
+
export const StyledNotchShadow = styled(Box)`
|
|
299
|
+
border-radius: 50%;
|
|
300
|
+
box-shadow: 0px -7px 10px -5px rgb(0 0 0 / 20%), 0px 2px 10px 0px rgb(0 0 0 / 14%), 0px 0px 8px 0px rgb(0 0 0 / 12%);
|
|
301
|
+
height: 13px;
|
|
302
|
+
left: 13px;
|
|
303
|
+
position: absolute;
|
|
304
|
+
top: -7px;
|
|
305
|
+
width: 25px;
|
|
306
|
+
z-index: -2;
|
|
307
|
+
`
|
|
308
|
+
|
|
309
|
+
export const StyledNotchShadowMask = styled(Box)`
|
|
310
|
+
background-color: ${props => props.theme.palette.mode === 'dark'
|
|
311
|
+
? props.theme.palette.primary.main
|
|
312
|
+
: props.theme.palette.background.paper};
|
|
313
|
+
border-radius: 50%;
|
|
314
|
+
height: 13px;
|
|
315
|
+
left: 13px;
|
|
316
|
+
position: absolute;
|
|
317
|
+
top: -1px;
|
|
318
|
+
width: 25px;
|
|
319
|
+
z-index: -1;
|
|
320
|
+
`
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
// @ts-ignore
|
|
2
|
+
import * as React from 'react'
|
|
3
|
+
import { useSpring, animated, easings } from '@react-spring/web'
|
|
4
|
+
|
|
5
|
+
const Path = (props: any) => (
|
|
6
|
+
<animated.path
|
|
7
|
+
fill='transparent'
|
|
8
|
+
strokeWidth='3'
|
|
9
|
+
stroke='inherit'
|
|
10
|
+
strokeLinecap='round'
|
|
11
|
+
{...props}
|
|
12
|
+
/>
|
|
13
|
+
)
|
|
14
|
+
|
|
15
|
+
const ToggleSearchX = (props: any): React.ReactElement => {
|
|
16
|
+
const animationDefaults = {
|
|
17
|
+
reverse: props?.isOpen,
|
|
18
|
+
config: {
|
|
19
|
+
duration: 150,
|
|
20
|
+
easing: easings.easeInOutQuad
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
const handle = useSpring({
|
|
25
|
+
...animationDefaults,
|
|
26
|
+
from: { d: 'M 15 15 L 35 35' },
|
|
27
|
+
to: { d: 'M 26 26 L 35 35' }
|
|
28
|
+
})
|
|
29
|
+
|
|
30
|
+
const closeBar = useSpring({
|
|
31
|
+
...animationDefaults,
|
|
32
|
+
from: { d: 'M 15 35 L 35 15', opacity: 1, scale: 1 },
|
|
33
|
+
to: { d: 'M 26 26 L 35 35', opacity: 0, scale: 0 }
|
|
34
|
+
})
|
|
35
|
+
|
|
36
|
+
const circle = useSpring({
|
|
37
|
+
...animationDefaults,
|
|
38
|
+
from: { opacity: 0, scale: 0 },
|
|
39
|
+
to: { opacity: 1, scale: 1 }
|
|
40
|
+
})
|
|
41
|
+
|
|
42
|
+
return (
|
|
43
|
+
<svg width='40' height='40' viewBox='0 0 50 50' stroke='inherit'>
|
|
44
|
+
<Path {...handle} />
|
|
45
|
+
<Path {...closeBar} />
|
|
46
|
+
<animated.circle
|
|
47
|
+
{...circle}
|
|
48
|
+
cx='20'
|
|
49
|
+
cy='20'
|
|
50
|
+
r='8'
|
|
51
|
+
fill='transparent'
|
|
52
|
+
strokeWidth='3'
|
|
53
|
+
stroke='inherit'
|
|
54
|
+
/>
|
|
55
|
+
</svg>
|
|
56
|
+
)
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export default ToggleSearchX
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
// @ts-ignore
|
|
2
|
+
import * as React from 'react'
|
|
3
|
+
import { useSpring, animated, easings } from '@react-spring/web'
|
|
4
|
+
|
|
5
|
+
const Path = (props: any) => (
|
|
6
|
+
<animated.path
|
|
7
|
+
fill='transparent'
|
|
8
|
+
strokeWidth='3'
|
|
9
|
+
stroke='inherit'
|
|
10
|
+
strokeLinecap='round'
|
|
11
|
+
{...props}
|
|
12
|
+
/>
|
|
13
|
+
)
|
|
14
|
+
|
|
15
|
+
const ToggleX = (props: any): React.ReactElement => {
|
|
16
|
+
const animationDefaults = {
|
|
17
|
+
reverse: props?.isOpen,
|
|
18
|
+
config: {
|
|
19
|
+
duration: 150,
|
|
20
|
+
easing: easings.easeInOutQuad
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
const topBar = useSpring({
|
|
25
|
+
...animationDefaults,
|
|
26
|
+
from: { d: 'M 15 15 L 35 35' },
|
|
27
|
+
to: { d: 'M 10 15 L 40 15' }
|
|
28
|
+
})
|
|
29
|
+
|
|
30
|
+
const middleBar = useSpring({
|
|
31
|
+
...animationDefaults,
|
|
32
|
+
from: { opacity: 0, scale: 0 },
|
|
33
|
+
to: { opacity: 1, scale: 1 }
|
|
34
|
+
})
|
|
35
|
+
|
|
36
|
+
const bottomBar = useSpring({
|
|
37
|
+
...animationDefaults,
|
|
38
|
+
from: { d: 'M 15 35 L 35 15' },
|
|
39
|
+
to: { d: 'M 10 35 L 40 35' }
|
|
40
|
+
})
|
|
41
|
+
|
|
42
|
+
return (
|
|
43
|
+
<svg width="40" height="40" viewBox="0 0 50 50">
|
|
44
|
+
<Path {...topBar} />
|
|
45
|
+
<Path d='M 10 25 L 40 25' {...middleBar} />
|
|
46
|
+
<Path {...bottomBar} />
|
|
47
|
+
</svg>
|
|
48
|
+
)
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export default ToggleX
|