@learningpool/ui 1.6.3 → 1.6.5
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/{dist/assets → assets}/Images.d.ts +0 -0
- package/{dist/assets → assets}/Images.js +0 -0
- package/{dist/components → components}/atoms/Autocomplete/Autocomplete.d.ts +0 -0
- package/{dist/components → components}/atoms/Autocomplete/Autocomplete.js +0 -0
- package/{dist/components → components}/atoms/Button/Button.d.ts +0 -0
- package/{dist/components → components}/atoms/Button/Button.js +0 -0
- package/{dist/components → components}/atoms/Checkbox/Checkbox.d.ts +0 -0
- package/{dist/components → components}/atoms/Checkbox/Checkbox.js +0 -0
- package/{dist/components → components}/atoms/IconButton/IconButton.d.ts +0 -0
- package/{dist/components → components}/atoms/IconButton/IconButton.js +0 -0
- package/{dist/components → components}/atoms/Radio/Radio.d.ts +0 -0
- package/{dist/components → components}/atoms/Radio/Radio.js +0 -0
- package/{dist/components → components}/atoms/Select/Select.d.ts +0 -0
- package/{dist/components → components}/atoms/Select/Select.js +0 -0
- package/{dist/components → components}/atoms/Slider/Slider.d.ts +0 -0
- package/{dist/components → components}/atoms/Slider/Slider.js +0 -0
- package/{dist/components → components}/atoms/Switch/Switch.d.ts +0 -0
- package/{dist/components → components}/atoms/Switch/Switch.js +0 -0
- package/{dist/components → components}/atoms/TextField/TextField.d.ts +0 -0
- package/{dist/components → components}/atoms/TextField/TextField.js +0 -0
- package/{dist/components → components}/atoms/ToggleButton/ToggleButton.d.ts +0 -0
- package/{dist/components → components}/atoms/ToggleButton/ToggleButton.js +0 -0
- package/{dist/components → components}/datadisplay/Avatar/Avatar.d.ts +0 -0
- package/{dist/components → components}/datadisplay/Avatar/Avatar.js +0 -0
- package/{dist/components → components}/datadisplay/Chip/Chip.d.ts +0 -0
- package/{dist/components → components}/datadisplay/Chip/Chip.js +0 -0
- package/{dist/components → components}/datadisplay/List/List.d.ts +0 -0
- package/{dist/components → components}/datadisplay/List/List.js +0 -0
- package/{dist/components → components}/datadisplay/Tooltip/Tooltip.d.ts +0 -0
- package/{dist/components → components}/datadisplay/Tooltip/Tooltip.js +0 -0
- package/{dist/components → components}/feedback/Alert/Alert.d.ts +0 -0
- package/{dist/components → components}/feedback/Alert/Alert.js +0 -0
- package/{dist/components → components}/landmarks/Header/Header.d.ts +0 -0
- package/{dist/components → components}/landmarks/Header/Header.js +0 -0
- package/{dist/components → components}/landmarks/Header/HeaderActionButtons.d.ts +0 -0
- package/{dist/components → components}/landmarks/Header/HeaderActionButtons.js +0 -0
- package/{dist/components → components}/landmarks/Header/HeaderStyles.d.ts +0 -0
- package/{dist/components → components}/landmarks/Header/HeaderStyles.js +0 -0
- package/{dist/components → components}/navigation/Drawer/Drawer.d.ts +0 -0
- package/{dist/components → components}/navigation/Drawer/Drawer.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigation.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigation.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationAvatar.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationAvatar.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationAvatarStyles.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationAvatarStyles.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationDrawer.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationDrawer.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationDrawerStyles.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationDrawerStyles.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItem.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItem.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenu.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenu.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenuStyles.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenuStyles.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemStyles.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemStyles.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationMotion.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationMotion.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationNotchIndicator.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationNotchIndicator.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationSearch.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationSearch.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationSearchStyles.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationSearchStyles.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationStyles.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationStyles.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationToggleSearchX.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationToggleSearchX.js +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationToggleX.d.ts +0 -0
- package/{dist/components → components}/navigation/MobileNavigation/MobileNavigationToggleX.js +0 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigation.d.ts +1 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigation.js +12 -10
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationAvatar.d.ts +0 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationAvatar.js +11 -7
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationAvatarStyles.d.ts +49 -0
- package/components/navigation/VerticalNavigation/VerticalNavigationAvatarStyles.js +33 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItem.d.ts +0 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItem.js +0 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenu.d.ts +0 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenu.js +3 -3
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenuStyles.d.ts +1 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenuStyles.js +16 -15
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemStyles.d.ts +0 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemStyles.js +3 -3
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationMotion.d.ts +0 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationMotion.js +0 -0
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationStyles.d.ts +6 -1
- package/{dist/components → components}/navigation/VerticalNavigation/VerticalNavigationStyles.js +14 -15
- package/{dist/components → components}/pages/ErrorPage/ErrorPage.d.ts +0 -0
- package/{dist/components → components}/pages/ErrorPage/ErrorPage.js +0 -0
- package/{dist/components → components}/pages/ErrorPage/ErrorPageStyles.d.ts +0 -0
- package/{dist/components → components}/pages/ErrorPage/ErrorPageStyles.js +0 -0
- package/{dist/components → components}/pages/SideInSide/SideInSide.d.ts +0 -0
- package/{dist/components → components}/pages/SideInSide/SideInSide.js +0 -0
- package/{dist/components → components}/pages/SideInSide/SideInSideStyles.d.ts +0 -0
- package/{dist/components → components}/pages/SideInSide/SideInSideStyles.js +0 -0
- package/{dist/components → components}/stream/AppSwitcher/AppSwitcher.d.ts +0 -0
- package/{dist/components → components}/stream/AppSwitcher/AppSwitcher.js +1 -1
- package/{dist/components → components}/stream/AppSwitcher/AppSwitcherItem.d.ts +0 -0
- package/{dist/components → components}/stream/AppSwitcher/AppSwitcherItem.js +0 -0
- package/{dist/components → components}/stream/AppSwitcher/AppSwitcherStyles.d.ts +0 -0
- package/{dist/components → components}/stream/AppSwitcher/AppSwitcherStyles.js +8 -6
- package/{dist/components → components}/stream/AppSwitcher/constants.d.ts +0 -0
- package/{dist/components → components}/stream/AppSwitcher/constants.js +0 -0
- package/{dist/index.d.ts → index.d.ts} +0 -0
- package/{dist/index.js → index.js} +0 -0
- package/lang/en-us.d.ts +15 -0
- package/lang/en-us.js +18 -0
- package/package.json +3 -70
- package/{dist/types → types}/components/navigation/VerticalNavigation.d.ts +0 -0
- package/{dist/types → types}/components/navigation/VerticalNavigation.js +0 -0
- package/{dist/types → types}/components/navigation/VerticalNavigationAvatar.d.ts +1 -0
- package/{dist/types → types}/components/navigation/VerticalNavigationAvatar.js +0 -0
- package/{dist/types → types}/components/stream/AppSwitcher.d.ts +0 -0
- package/{dist/types → types}/components/stream/AppSwitcher.js +0 -0
- package/{dist/types → types}/index.d.ts +0 -0
- package/{dist/types → types}/index.js +0 -0
- package/{dist/utils → utils}/constants.d.ts +0 -0
- package/{dist/utils → utils}/constants.js +0 -0
- package/{dist/utils → utils}/helpers.d.ts +0 -0
- package/{dist/utils → utils}/helpers.js +0 -0
- package/{dist/utils → utils}/hooks.d.ts +0 -0
- package/{dist/utils → utils}/hooks.js +0 -0
- package/{dist/utils → utils}/index.d.ts +0 -0
- package/{dist/utils → utils}/index.js +0 -0
- package/{dist/utils → utils}/theme.d.ts +0 -0
- package/{dist/utils → utils}/theme.js +0 -0
- package/.eslintrc.js +0 -40
- package/.github/pull_request_template.md +0 -23
- package/.github/renovate.json +0 -57
- package/.github/workflows/integration.yml +0 -53
- package/.github/workflows/wss.yml +0 -22
- package/.jest-test-results.json +0 -1
- package/.releaserc +0 -32
- package/.storybook/learningpoolTheme.js +0 -39
- package/.storybook/main.js +0 -21
- package/.storybook/manager-head.html +0 -175
- package/.storybook/manager.js +0 -34
- package/.storybook/preview-head.html +0 -212
- package/.storybook/preview.js +0 -120
- package/.storybook/storybook-sort.js +0 -54
- package/CHANGELOG.md +0 -20
- package/amplify.yml +0 -16
- package/babel.config.json +0 -14
- package/dist/components/navigation/VerticalNavigation/VerticalNavigationAvatarStyles.js +0 -31
- package/dist/lang/en-us.d.ts +0 -6
- package/dist/lang/en-us.js +0 -6
- package/dist/package.json +0 -41
- package/jest.config.ts +0 -11
- package/jest.setup.ts +0 -5
- package/license +0 -7
- package/merge.js +0 -27
- 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 +0 -5
- package/public/assets/automation.svg +0 -1
- 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 +0 -6
- package/public/assets/flux/icon-light.svg +0 -1
- package/public/assets/flux/icon-white.svg +0 -6
- package/public/assets/flux/icon.svg +0 -6
- package/public/assets/flux/logo-dark.svg +0 -22
- package/public/assets/flux/logo-light.svg +0 -1
- package/public/assets/flux/logo-white.svg +0 -22
- package/public/assets/flux/logo.svg +0 -22
- 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 +0 -1
- package/public/assets/molecules.svg +0 -8
- package/public/assets/organisms.svg +0 -21
- package/public/assets/pages.svg +0 -4
- package/public/assets/particles.svg +0 -3
- package/public/assets/stream-dark.png +0 -0
- package/public/assets/stream-suite-logo.svg +0 -38
- package/public/assets/stream-white.png +0 -0
- package/public/assets/stream.png +0 -0
- package/public/assets/templates.svg +0 -3
- package/public/favicon-16x16.png +0 -0
- package/public/favicon-32x32.png +0 -0
- package/public/favicon.ico +0 -0
- package/public/index.html +0 -43
- package/public/logo192.png +0 -0
- package/public/logo512.png +0 -0
- package/public/manifest.json +0 -25
- package/public/robots.txt +0 -3
- package/public/site.webmanifest +0 -1
- package/readme.md +0 -132
- package/src/docs.tsx +0 -167
- package/src/lib/assets/Images.tsx +0 -47
- package/src/lib/assets/stream-suite-logo.svg +0 -38
- package/src/lib/components/atoms/Autocomplete/Autocomplete.test.tsx +0 -179
- package/src/lib/components/atoms/Autocomplete/Autocomplete.tsx +0 -14
- package/src/lib/components/atoms/Button/Button.test.tsx +0 -166
- package/src/lib/components/atoms/Button/Button.tsx +0 -16
- package/src/lib/components/atoms/Checkbox/Checkbox.test.tsx +0 -85
- package/src/lib/components/atoms/Checkbox/Checkbox.tsx +0 -10
- package/src/lib/components/atoms/IconButton/IconButton.test.tsx +0 -60
- package/src/lib/components/atoms/IconButton/IconButton.tsx +0 -9
- package/src/lib/components/atoms/Radio/Radio.test.tsx +0 -136
- package/src/lib/components/atoms/Radio/Radio.tsx +0 -10
- package/src/lib/components/atoms/Select/Select.test.tsx +0 -158
- package/src/lib/components/atoms/Select/Select.tsx +0 -12
- package/src/lib/components/atoms/Slider/Slider.test.tsx +0 -103
- package/src/lib/components/atoms/Slider/Slider.tsx +0 -10
- package/src/lib/components/atoms/Switch/Switch.test.tsx +0 -96
- package/src/lib/components/atoms/Switch/Switch.tsx +0 -10
- package/src/lib/components/atoms/TextField/TextField.test.tsx +0 -131
- package/src/lib/components/atoms/TextField/TextField.tsx +0 -31
- package/src/lib/components/atoms/ToggleButton/ToggleButton.test.tsx +0 -122
- package/src/lib/components/atoms/ToggleButton/ToggleButton.tsx +0 -10
- package/src/lib/components/datadisplay/Avatar/Avatar.test.tsx +0 -187
- package/src/lib/components/datadisplay/Avatar/Avatar.tsx +0 -35
- package/src/lib/components/datadisplay/Avatar/avatar-1.jpg +0 -0
- package/src/lib/components/datadisplay/Chip/Chip.test.tsx +0 -82
- package/src/lib/components/datadisplay/Chip/Chip.tsx +0 -11
- package/src/lib/components/datadisplay/List/List.test.tsx +0 -168
- package/src/lib/components/datadisplay/List/List.tsx +0 -8
- package/src/lib/components/datadisplay/Tooltip/Tooltip.test.tsx +0 -98
- package/src/lib/components/datadisplay/Tooltip/Tooltip.tsx +0 -9
- package/src/lib/components/feedback/Alert/Alert.test.tsx +0 -139
- package/src/lib/components/feedback/Alert/Alert.tsx +0 -10
- package/src/lib/components/landmarks/Header/Header.tsx +0 -140
- package/src/lib/components/landmarks/Header/HeaderActionButtons.tsx +0 -117
- package/src/lib/components/landmarks/Header/HeaderStyles.tsx +0 -62
- package/src/lib/components/navigation/Drawer/Drawer.test.tsx +0 -95
- package/src/lib/components/navigation/Drawer/Drawer.tsx +0 -21
- package/src/lib/components/navigation/MobileNavigation/MobileNavigation.tsx +0 -276
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationAvatar.tsx +0 -334
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationAvatarStyles.tsx +0 -77
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationDrawer.tsx +0 -197
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationDrawerStyles.tsx +0 -143
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItem.tsx +0 -192
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenu.tsx +0 -67
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemFlyoutMenuStyles.tsx +0 -192
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationItem/MobileNavigationItemStyles.tsx +0 -217
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationMotion.tsx +0 -119
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationNotchIndicator.tsx +0 -35
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationSearch.tsx +0 -114
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationSearchStyles.tsx +0 -47
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationStyles.tsx +0 -320
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationToggleSearchX.tsx +0 -59
- package/src/lib/components/navigation/MobileNavigation/MobileNavigationToggleX.tsx +0 -51
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigation.tsx +0 -468
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationAvatar.tsx +0 -208
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationAvatarStyles.tsx +0 -75
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItem.tsx +0 -196
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenu.tsx +0 -94
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemFlyoutMenuStyles.tsx +0 -212
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationItem/VerticalNavigationItemStyles.tsx +0 -240
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationMotion.tsx +0 -119
- package/src/lib/components/navigation/VerticalNavigation/VerticalNavigationStyles.tsx +0 -302
- package/src/lib/components/pages/ErrorPage/ErrorPage.test.tsx +0 -78
- package/src/lib/components/pages/ErrorPage/ErrorPage.tsx +0 -50
- package/src/lib/components/pages/ErrorPage/ErrorPageStyles.tsx +0 -30
- package/src/lib/components/pages/SideInSide/SideInSide.tsx +0 -100
- package/src/lib/components/pages/SideInSide/SideInSideStyles.tsx +0 -62
- package/src/lib/components/stream/AppSwitcher/AppSwitcher.tsx +0 -381
- package/src/lib/components/stream/AppSwitcher/AppSwitcherItem.tsx +0 -84
- package/src/lib/components/stream/AppSwitcher/AppSwitcherStyles.tsx +0 -325
- package/src/lib/components/stream/AppSwitcher/constants.tsx +0 -28
- package/src/lib/index.tsx +0 -148
- package/src/lib/lang/en-us.js +0 -6
- package/src/lib/types/components/navigation/VerticalNavigation.ts +0 -52
- package/src/lib/types/components/navigation/VerticalNavigationAvatar.ts +0 -26
- package/src/lib/types/components/stream/AppSwitcher.ts +0 -10
- package/src/lib/types/index.ts +0 -9
- package/src/lib/utils/constants.tsx +0 -11
- package/src/lib/utils/helpers.tsx +0 -77
- package/src/lib/utils/hooks.tsx +0 -33
- package/src/lib/utils/index.tsx +0 -4
- package/src/lib/utils/theme.tsx +0 -79
- package/src/react-app-env.d.ts +0 -1
- package/src/setupTests.ts +0 -5
- package/src/stories/Components/DataDisplay/Avatar/Accessibility.stories.mdx +0 -34
- package/src/stories/Components/DataDisplay/Avatar/AllCombinations.tsx +0 -56
- package/src/stories/Components/DataDisplay/Avatar/Avatar.stories.tsx +0 -19
- package/src/stories/Components/DataDisplay/Avatar/Examples.stories.tsx +0 -278
- package/src/stories/Components/DataDisplay/Avatar/Overview.stories.mdx +0 -47
- package/src/stories/Components/DataDisplay/Chip/Accessibility.stories.mdx +0 -29
- package/src/stories/Components/DataDisplay/Chip/AllCombinations.tsx +0 -58
- package/src/stories/Components/DataDisplay/Chip/Chip.stories.tsx +0 -21
- package/src/stories/Components/DataDisplay/Chip/Examples.stories.tsx +0 -126
- package/src/stories/Components/DataDisplay/Chip/Overview.stories.mdx +0 -57
- package/src/stories/Components/DataDisplay/List/Accessibility.stories.mdx +0 -54
- package/src/stories/Components/DataDisplay/List/AllCombinations.tsx +0 -396
- package/src/stories/Components/DataDisplay/List/Examples.stories.tsx +0 -501
- package/src/stories/Components/DataDisplay/List/List.stories.tsx +0 -35
- package/src/stories/Components/DataDisplay/List/Overview.stories.mdx +0 -69
- package/src/stories/Components/DataDisplay/Table/Overview.stories.mdx +0 -70
- package/src/stories/Components/DataDisplay/Tooltip/Accessibility.stories.mdx +0 -39
- package/src/stories/Components/DataDisplay/Tooltip/AllCombinations.tsx +0 -134
- package/src/stories/Components/DataDisplay/Tooltip/Examples.stories.tsx +0 -237
- package/src/stories/Components/DataDisplay/Tooltip/Overview.stories.mdx +0 -58
- package/src/stories/Components/DataDisplay/Tooltip/Tooltip.stories.tsx +0 -22
- package/src/stories/Components/Feedback/Alert/Accessibility.stories.mdx +0 -25
- package/src/stories/Components/Feedback/Alert/Alert.stories.tsx +0 -22
- package/src/stories/Components/Feedback/Alert/AllCombinations.tsx +0 -37
- package/src/stories/Components/Feedback/Alert/Examples.stories.tsx +0 -137
- package/src/stories/Components/Feedback/Alert/Overview.stories.mdx +0 -62
- package/src/stories/Components/Inputs/Autocomplete/Accessibility.stories.mdx +0 -31
- package/src/stories/Components/Inputs/Autocomplete/AllCombinations.tsx +0 -182
- package/src/stories/Components/Inputs/Autocomplete/Autocomplete.stories.tsx +0 -31
- package/src/stories/Components/Inputs/Autocomplete/Examples.stories.tsx +0 -233
- package/src/stories/Components/Inputs/Autocomplete/Overview.stories.mdx +0 -52
- package/src/stories/Components/Inputs/Button/Accessibility.stories.mdx +0 -52
- package/src/stories/Components/Inputs/Button/AllCombinations.tsx +0 -53
- package/src/stories/Components/Inputs/Button/Button.stories.tsx +0 -23
- package/src/stories/Components/Inputs/Button/Examples.stories.tsx +0 -190
- package/src/stories/Components/Inputs/Button/Overview.stories.mdx +0 -52
- package/src/stories/Components/Inputs/Checkbox/Accessibility.stories.mdx +0 -38
- package/src/stories/Components/Inputs/Checkbox/AllCombinations.tsx +0 -55
- package/src/stories/Components/Inputs/Checkbox/Checkbox.stories.tsx +0 -22
- package/src/stories/Components/Inputs/Checkbox/Examples.stories.tsx +0 -363
- package/src/stories/Components/Inputs/Checkbox/Overview.stories.mdx +0 -63
- package/src/stories/Components/Inputs/IconButton/Examples.stories.tsx +0 -24
- package/src/stories/Components/Inputs/IconButton/IconButton.stories.tsx +0 -26
- package/src/stories/Components/Inputs/Radio/Accessibility.stories.mdx +0 -61
- package/src/stories/Components/Inputs/Radio/AllCombinations.tsx +0 -75
- package/src/stories/Components/Inputs/Radio/Examples.stories.tsx +0 -333
- package/src/stories/Components/Inputs/Radio/Overview.stories.mdx +0 -74
- package/src/stories/Components/Inputs/Radio/Radio.stories.tsx +0 -22
- package/src/stories/Components/Inputs/Select/Accessibility.stories.mdx +0 -51
- package/src/stories/Components/Inputs/Select/AllCombinations.tsx +0 -63
- package/src/stories/Components/Inputs/Select/Examples.stories.tsx +0 -803
- package/src/stories/Components/Inputs/Select/Overview.stories.mdx +0 -73
- package/src/stories/Components/Inputs/Select/Select.stories.tsx +0 -22
- package/src/stories/Components/Inputs/Slider/Accessibility.stories.mdx +0 -43
- package/src/stories/Components/Inputs/Slider/AllCombinations.tsx +0 -30
- package/src/stories/Components/Inputs/Slider/Examples.stories.tsx +0 -146
- package/src/stories/Components/Inputs/Slider/Overview.stories.mdx +0 -59
- package/src/stories/Components/Inputs/Slider/Slider.stories.tsx +0 -27
- package/src/stories/Components/Inputs/Switch/Accessibility.stories.mdx +0 -34
- package/src/stories/Components/Inputs/Switch/AllCombinations.tsx +0 -45
- package/src/stories/Components/Inputs/Switch/Examples.stories.tsx +0 -213
- package/src/stories/Components/Inputs/Switch/Overview.stories.mdx +0 -62
- package/src/stories/Components/Inputs/Switch/Switch.stories.tsx +0 -22
- package/src/stories/Components/Inputs/TextField/Accessibility.stories.mdx +0 -29
- package/src/stories/Components/Inputs/TextField/AllCombinations.tsx +0 -57
- package/src/stories/Components/Inputs/TextField/Examples.stories.tsx +0 -127
- package/src/stories/Components/Inputs/TextField/Overview.stories.mdx +0 -60
- package/src/stories/Components/Inputs/TextField/TextField.stories.tsx +0 -261
- package/src/stories/Components/Inputs/ToggleButton/Accessibility.stories.mdx +0 -32
- package/src/stories/Components/Inputs/ToggleButton/AllCombinations.tsx +0 -113
- package/src/stories/Components/Inputs/ToggleButton/Examples.stories.tsx +0 -339
- package/src/stories/Components/Inputs/ToggleButton/Overview.stories.mdx +0 -55
- package/src/stories/Components/Inputs/ToggleButton/ToggleButton.stories.tsx +0 -19
- package/src/stories/Components/Landmarks/Header/Examples.stories.tsx +0 -197
- package/src/stories/Components/Landmarks/Header/Header.stories.tsx +0 -34
- package/src/stories/Components/Landmarks/Header/Overview.stories.mdx +0 -44
- package/src/stories/Components/Navigation/Drawer/Accessibility.stories.mdx +0 -13
- package/src/stories/Components/Navigation/Drawer/Drawer.stories.tsx +0 -80
- package/src/stories/Components/Navigation/Drawer/Examples.stories.tsx +0 -440
- package/src/stories/Components/Navigation/Drawer/Overview.stories.mdx +0 -43
- package/src/stories/Components/Navigation/MobileNavigation/Accessibility.stories.mdx +0 -14
- package/src/stories/Components/Navigation/MobileNavigation/Examples.stories.tsx +0 -384
- package/src/stories/Components/Navigation/MobileNavigation/MobileNavigation.stories.tsx +0 -24
- package/src/stories/Components/Navigation/MobileNavigation/Overview.stories.mdx +0 -47
- package/src/stories/Components/Navigation/VerticalNavigation/Accessibility.stories.mdx +0 -14
- package/src/stories/Components/Navigation/VerticalNavigation/Examples.stories.tsx +0 -307
- package/src/stories/Components/Navigation/VerticalNavigation/Overview.stories.mdx +0 -47
- package/src/stories/Components/Navigation/VerticalNavigation/VerticalNavigation.stories.tsx +0 -24
- package/src/stories/ContactUs.stories.mdx +0 -21
- package/src/stories/Experimental/Test.stories.mdx +0 -46
- package/src/stories/GettingStarted/Designer.stories.mdx +0 -86
- package/src/stories/GettingStarted/Developer.stories.mdx +0 -134
- package/src/stories/Guidelines/Accessibility/AssistiveTechnology.stories.mdx +0 -70
- package/src/stories/Guidelines/Accessibility/ColorAndContrast.stories.mdx +0 -109
- package/src/stories/Guidelines/Accessibility/Hierarchy.stories.mdx +0 -119
- package/src/stories/Guidelines/Accessibility/Imagery.stories.mdx +0 -136
- package/src/stories/Guidelines/Accessibility/Overview.stories.mdx +0 -44
- package/src/stories/Guidelines/Accessibility/Principles.stories.mdx +0 -156
- package/src/stories/Guidelines/Accessibility/SoundAndMotion.stories.mdx +0 -59
- package/src/stories/Guidelines/Accessibility/Typography.stories.mdx +0 -69
- package/src/stories/Guidelines/Accessibility/Writing.stories.mdx +0 -188
- package/src/stories/Guidelines/Styleguide/ColorSwatch.tsx +0 -53
- package/src/stories/Guidelines/Styleguide/Colors.stories.mdx +0 -118
- package/src/stories/Guidelines/Styleguide/Typography.stories.mdx +0 -84
- package/src/stories/Introduction.stories.mdx +0 -65
- package/src/stories/Pages/ErrorPage.stories.tsx +0 -30
- package/src/stories/Pages/SideInSide.stories.tsx +0 -195
- package/src/stories/Roadmap.stories.mdx +0 -19
- package/src/stories/Templates/Login.stories.mdx +0 -46
- package/src/stories/assets/Atomic_Design_Icons-Dark.svg +0 -24
- package/src/stories/assets/Atomic_Design_Icons-Light.svg +0 -25
- 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 +0 -6
- 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 +0 -9
- package/src/stories/assets/organisms.svg +0 -22
- package/src/stories/assets/pages.svg +0 -5
- package/src/stories/assets/particles.svg +0 -4
- package/src/stories/assets/templates.svg +0 -4
- package/src/stories/assets/testData.tsx +0 -102
- 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 +0 -44
- package/tsconfig.eslint.json +0 -16
- package/tsconfig.json +0 -50
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { Canvas, Meta, Story } from '@storybook/addon-docs';
|
|
2
|
-
import Autocomplete from '../../../../lib/components/atoms/Autocomplete/Autocomplete';
|
|
3
|
-
import TextField from '../../../../lib/components/atoms/TextField/TextField';
|
|
4
|
-
import { MUIIcon, MaterialDesignIcon, W3CIcon, FigmaIcon, GithubIcon } from '../../../utils/CustomIcons';
|
|
5
|
-
import Chip from '../../../../lib/components/datadisplay/Chip/Chip';
|
|
6
|
-
import Stack from '@mui/material/Stack';
|
|
7
|
-
import { top100Films } from '../../../assets/testData'
|
|
8
|
-
|
|
9
|
-
<Meta title="Components/Inputs/Autocomplete/Overview" component={Autocomplete} />
|
|
10
|
-
|
|
11
|
-
[](#autocomplete-overview)Autocomplete Overview <span class="sbdocs-edit-link"><Chip clickable component="a" href="https://github.com/ht2-labs/design-system/tree/main/src/stories/Components/Inputs/Autocomplete/Overview.stories.mdx" size="small" label="Edit" variant="outlined" /></span>
|
|
12
|
-
=================================================================================
|
|
13
|
-
|
|
14
|
-
### [](#what-does-it-do)What does it do?
|
|
15
|
-
|
|
16
|
-
The autocomplete is a normal text input enhanced by a panel of suggested options.
|
|
17
|
-
|
|
18
|
-
<Stack direction="row" spacing={1}>
|
|
19
|
-
<Chip clickable component="a" href="https://mui.com/components/autocompletes/" size="small" icon={<MUIIcon viewBox="-5 0 40 30" />} label="Material UI" variant="outlined" />
|
|
20
|
-
<Chip clickable component="a" href="https://material.io/components/autocompletes" size="small" icon={<MaterialDesignIcon />} label="Material Design" variant="outlined" />
|
|
21
|
-
<Chip clickable component="a" href="https://www.w3.org/TR/wai-aria-practices/#autocomplete" size="small" icon={<W3CIcon />} label="WAI-ARIA" variant="outlined" />
|
|
22
|
-
<Chip clickable component="a" href="https://www.figma.com/proto/mBDuFn79U8wQIIEoCGpMew/DS%3A-Component-Library?node-id=487%3A14431&scaling=min-zoom&page-id=310%3A35254&starting-point-node-id=487%3A14431" size="small" icon={<FigmaIcon />} label="Figma" variant="outlined" />
|
|
23
|
-
<Chip clickable component="a" href="https://github.com/HT2-Labs/design-system/tree/main/src/lib/components/atoms/Autocomplete" size="small" icon={<GithubIcon />} label="Github" variant="outlined" />
|
|
24
|
-
</Stack>
|
|
25
|
-
|
|
26
|
-
### [](#why-use-it)Why use it?
|
|
27
|
-
|
|
28
|
-
* Use an Autocomplete component when you want to provide a list of suggested options to the user.
|
|
29
|
-
* Use an Autocomplete component when you want to suggest a word or phrase based on user input.
|
|
30
|
-
|
|
31
|
-
### [](#how-to-implement-it)How to implement it?
|
|
32
|
-
|
|
33
|
-
Below is an example of the Autocomplete component:
|
|
34
|
-
|
|
35
|
-
<Canvas isExpanded>
|
|
36
|
-
<Autocomplete
|
|
37
|
-
sx={{ width: 300 }}
|
|
38
|
-
id="combo-box-demo"
|
|
39
|
-
options={top100Films.map((option) => option.title)}
|
|
40
|
-
renderInput={(params) => <TextField {...params} label="combo box" />}
|
|
41
|
-
/>
|
|
42
|
-
</Canvas>
|
|
43
|
-
|
|
44
|
-
### [](#best-practices)Best practices
|
|
45
|
-
|
|
46
|
-
The widget is useful for setting the value of a single-line textbox in one of two types of scenarios:
|
|
47
|
-
|
|
48
|
-
1. [Combo Box](?path=/story/components-inputs-autocomplete-examples--combo-box) - The value for the textbox must be chosen from a predefined set of allowed values, e.g., a location field must contain a valid location name.
|
|
49
|
-
2. [Free Solo](?path=/story/components-inputs-autocomplete-examples--free-solo) - The textbox may contain any arbitrary value, but it is advantageous to suggest possible values to the user, e.g., a search field may suggest similar or previous searches to save the user time.
|
|
50
|
-
|
|
51
|
-
### [](#design-prototype)Design prototype
|
|
52
|
-
TODO: Add Figma link
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { Canvas, Meta, Story } from '@storybook/addon-docs';
|
|
2
|
-
import { Stack } from '@mui/material';
|
|
3
|
-
import DeleteIcon from '@mui/icons-material/Delete';
|
|
4
|
-
import Button from '../../../../lib/components/atoms/Button/Button';
|
|
5
|
-
import IconButton from '../../../../lib/components/atoms/IconButton/IconButton';
|
|
6
|
-
import Chip from '@mui/material/Chip';
|
|
7
|
-
|
|
8
|
-
<Meta title="Components/Inputs/Button/Accessibility" />
|
|
9
|
-
|
|
10
|
-
[](#button-accessibility)Button Accessibility <span class="sbdocs-edit-link"><Chip clickable component="a" href="https://github.com/ht2-labs/design-system/tree/main/src/stories/Components/Inputs/Button/Accessibility.stories.mdx" size="small" label="Edit" variant="outlined" /></span>
|
|
11
|
-
=================================================================================
|
|
12
|
-
|
|
13
|
-
This component has been validated to meet the WCAG 2.1 AA and Section 508 accessibility guidelines; however, changes made by the developer can affect accessibility compliance.
|
|
14
|
-
|
|
15
|
-
Please follow the guidance in this section and see [WAI-ARIA Checkboxes](https://www.w3.org/TR/wai-aria-practices-1.1/#button) for more information.
|
|
16
|
-
|
|
17
|
-
## [](#accessibility-guidelines)Guidelines
|
|
18
|
-
* The button can be activated using both the Space or Enter key.
|
|
19
|
-
* The button should have text or label that accurately describes the action of the button.
|
|
20
|
-
* If a description of the button's function is present, the button element should have an aria-describedby set to the ID of the element containing the description.
|
|
21
|
-
* After the button is activated ensure the focus is set correctly based on the type of action the button performs.
|
|
22
|
-
|
|
23
|
-
### [](#when-to-use-this-component)When to use this component
|
|
24
|
-
There can be some confusion around which element to use for interface design. When do you use a `<link>` and when do you use a `<button>`? With a link, the visitor navigates to a new resource, taking them away from the current context; but a button prompts a change in the current interface.
|
|
25
|
-
|
|
26
|
-
When navigating to a different resource, provide a URL via the `href` prop so the component will render a `<a>` element:
|
|
27
|
-
<Canvas>
|
|
28
|
-
<Button href="https://learningpool.com" variant="contained">Link</Button>
|
|
29
|
-
</Canvas>
|
|
30
|
-
|
|
31
|
-
When interacting with the UI, simply leave off the `href` prop and the component will render a `<button>` element. A `<button>` is the best element for opening a modal window, triggering a pop-up, toggling an interface or playing media content.
|
|
32
|
-
<Canvas>
|
|
33
|
-
<Button variant="contained">Button</Button>
|
|
34
|
-
</Canvas>
|
|
35
|
-
|
|
36
|
-
### [](#aria-attributes)ARIA attributes
|
|
37
|
-
There are cases where to reduce visual noise buttons that have the same action but with different context, will have the same text. In those cases, `aria-label` should be added with unique information about for the action in the page context:
|
|
38
|
-
<Canvas>
|
|
39
|
-
<Stack direction="row" spacing={2}>
|
|
40
|
-
<Button aria-label="Button 1 description" variant="contained">Button</Button>
|
|
41
|
-
<Button aria-label="Button 2 description" variant="contained">Button</Button>
|
|
42
|
-
<Button aria-label="Button 3 description" variant="contained">Button</Button>
|
|
43
|
-
</Stack>
|
|
44
|
-
</Canvas>
|
|
45
|
-
|
|
46
|
-
#### [](#iconbutton)IconButton
|
|
47
|
-
Sometimes you may want to use a IconButton with only an icon and no visible text. In this case, you must also provide an `aria-label` prop to communicate alternative information to screen readers.
|
|
48
|
-
<Canvas>
|
|
49
|
-
<IconButton aria-label="Your label goes here">
|
|
50
|
-
<DeleteIcon />
|
|
51
|
-
</IconButton>
|
|
52
|
-
</Canvas>
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
import { Box } from '@mui/material'
|
|
2
|
-
import * as React from 'react'
|
|
3
|
-
import Button from '../../../../lib/components/atoms/Button/Button'
|
|
4
|
-
import DeleteIcon from '@mui/icons-material/Delete'
|
|
5
|
-
import SendIcon from '@mui/icons-material/Send'
|
|
6
|
-
|
|
7
|
-
const ButtonGrid = (args: any): JSX.Element => {
|
|
8
|
-
return (
|
|
9
|
-
<div>
|
|
10
|
-
<Button {...args}>{args.content ? args.content : 'Default'}</Button>
|
|
11
|
-
<Button {...args} color="primary">{args.content ? args.content : 'Primary'}</Button>
|
|
12
|
-
<Button {...args} color="secondary">{args.content ? args.content : 'Secondary'}</Button>
|
|
13
|
-
<Button {...args} color="error">{args.content ? args.content : 'Error'}</Button>
|
|
14
|
-
<Button {...args} color="success">{args.content ? args.content : 'Success'}</Button>
|
|
15
|
-
<Button {...args} color="info">{args.content ? args.content : 'Info'}</Button>
|
|
16
|
-
<Button {...args} color="warning">{args.content ? args.content : 'Warning'}</Button>
|
|
17
|
-
</div>
|
|
18
|
-
)
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
export default function AllCombinations (): JSX.Element {
|
|
22
|
-
const combinations = [
|
|
23
|
-
{ size: 'small' },
|
|
24
|
-
{ size: 'small', variant: 'text' },
|
|
25
|
-
{ size: 'small', variant: 'outlined' },
|
|
26
|
-
{ size: 'small', variant: 'contained' },
|
|
27
|
-
{ size: 'small', variant: 'contained', disabled: true },
|
|
28
|
-
{ size: 'small', variant: 'contained', startIcon: <DeleteIcon /> },
|
|
29
|
-
{ size: 'small', variant: 'contained', endIcon: <SendIcon /> },
|
|
30
|
-
{ size: 'medium' },
|
|
31
|
-
{ size: 'medium', variant: 'text' },
|
|
32
|
-
{ size: 'medium', variant: 'outlined' },
|
|
33
|
-
{ size: 'medium', variant: 'contained' },
|
|
34
|
-
{ size: 'medium', variant: 'contained', disabled: true },
|
|
35
|
-
{ size: 'medium', variant: 'contained', startIcon: <DeleteIcon /> },
|
|
36
|
-
{ size: 'medium', variant: 'contained', endIcon: <SendIcon /> },
|
|
37
|
-
{ size: 'large' },
|
|
38
|
-
{ size: 'large', variant: 'text' },
|
|
39
|
-
{ size: 'large', variant: 'outlined' },
|
|
40
|
-
{ size: 'large', variant: 'contained' },
|
|
41
|
-
{ size: 'large', variant: 'contained', disabled: true },
|
|
42
|
-
{ size: 'large', variant: 'contained', startIcon: <DeleteIcon /> },
|
|
43
|
-
{ size: 'large', variant: 'contained', endIcon: <SendIcon /> }
|
|
44
|
-
]
|
|
45
|
-
|
|
46
|
-
return (
|
|
47
|
-
<Box sx={{ '& button': { m: 1 } }}>
|
|
48
|
-
{combinations.map(buttonConfig => (
|
|
49
|
-
<ButtonGrid {...buttonConfig} disableRipple={true} />
|
|
50
|
-
))}
|
|
51
|
-
</Box>
|
|
52
|
-
)
|
|
53
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { ComponentMeta, ComponentStory } from '@storybook/react'
|
|
2
|
-
import * as React from 'react'
|
|
3
|
-
import Button from '../../../../lib/components/atoms/Button/Button'
|
|
4
|
-
|
|
5
|
-
const Default: ComponentMeta<typeof Button> = {
|
|
6
|
-
title: 'Components/Inputs/Button/Properties',
|
|
7
|
-
component: Button,
|
|
8
|
-
parameters: {
|
|
9
|
-
controls: {
|
|
10
|
-
sort: 'requiredFirst'
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
export default Default
|
|
16
|
-
|
|
17
|
-
// 👇 We create a “template” of how args map to rendering
|
|
18
|
-
const Template: ComponentStory<typeof Button> = (args) => <Button {...args} />
|
|
19
|
-
|
|
20
|
-
export const Properties = Template.bind({})
|
|
21
|
-
Properties.args = {
|
|
22
|
-
children: 'Button'
|
|
23
|
-
}
|
|
@@ -1,190 +0,0 @@
|
|
|
1
|
-
import { Box, Stack } from '@mui/material'
|
|
2
|
-
import { ComponentMeta, ComponentStory } from '@storybook/react'
|
|
3
|
-
import * as React from 'react'
|
|
4
|
-
import { DOCS } from '../../../../docs'
|
|
5
|
-
import Button from '../../../../lib/components/atoms/Button/Button'
|
|
6
|
-
import IconButton from '../../../../lib/components/atoms/IconButton/IconButton'
|
|
7
|
-
import AllCombinations from './AllCombinations'
|
|
8
|
-
import DeleteIcon from '@mui/icons-material/Delete'
|
|
9
|
-
import SendIcon from '@mui/icons-material/Send'
|
|
10
|
-
import AlarmIcon from '@mui/icons-material/Alarm'
|
|
11
|
-
import AddShoppingCartIcon from '@mui/icons-material/AddShoppingCart'
|
|
12
|
-
|
|
13
|
-
export default {
|
|
14
|
-
title: 'Components/Inputs/Button/Examples',
|
|
15
|
-
component: Button
|
|
16
|
-
} as ComponentMeta<typeof Button>
|
|
17
|
-
|
|
18
|
-
export const Default: ComponentStory<typeof Button> = (args) => (
|
|
19
|
-
<Stack spacing={2} direction="row">
|
|
20
|
-
<Button variant="text">Text</Button>
|
|
21
|
-
<Button variant="contained">Contained</Button>
|
|
22
|
-
<Button variant="outlined">Outlined</Button>
|
|
23
|
-
</Stack>
|
|
24
|
-
)
|
|
25
|
-
Default.parameters = {
|
|
26
|
-
docs: {
|
|
27
|
-
description: {
|
|
28
|
-
component: DOCS.Button.Default
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
export const Text: ComponentStory<typeof Button> = (args) => (
|
|
34
|
-
<Stack direction="row" spacing={2}>
|
|
35
|
-
<Button {...args}>Primary</Button>
|
|
36
|
-
<Button {...args} disabled>Disabled</Button>
|
|
37
|
-
<Button {...args} href="#text-buttons">Link</Button>
|
|
38
|
-
</Stack>
|
|
39
|
-
)
|
|
40
|
-
Text.parameters = {
|
|
41
|
-
docs: {
|
|
42
|
-
description: {
|
|
43
|
-
story: DOCS.Button.Text
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
export const Contained: ComponentStory<typeof Button> = (args) => (
|
|
49
|
-
<Stack direction="row" spacing={2}>
|
|
50
|
-
<Button variant="contained">Contained</Button>
|
|
51
|
-
<Button variant="contained" disabled>
|
|
52
|
-
Disabled
|
|
53
|
-
</Button>
|
|
54
|
-
<Button variant="contained" href="#contained-buttons">
|
|
55
|
-
Link
|
|
56
|
-
</Button>
|
|
57
|
-
</Stack>
|
|
58
|
-
)
|
|
59
|
-
Contained.parameters = {
|
|
60
|
-
docs: {
|
|
61
|
-
description: {
|
|
62
|
-
story: DOCS.Button.Contained
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
export const Outlined: ComponentStory<typeof Button> = (args) => (
|
|
68
|
-
<Stack direction="row" spacing={2}>
|
|
69
|
-
<Button variant="outlined">Primary</Button>
|
|
70
|
-
<Button variant="outlined" disabled>
|
|
71
|
-
Disabled
|
|
72
|
-
</Button>
|
|
73
|
-
<Button variant="outlined" href="#outlined-buttons">
|
|
74
|
-
Link
|
|
75
|
-
</Button>
|
|
76
|
-
</Stack>
|
|
77
|
-
)
|
|
78
|
-
Outlined.parameters = {
|
|
79
|
-
docs: {
|
|
80
|
-
description: {
|
|
81
|
-
story: DOCS.Button.Outlined
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
export const Colors: ComponentStory<typeof Button> = (args) => (
|
|
87
|
-
<Stack direction="row" spacing={2}>
|
|
88
|
-
<Button variant="contained" color="primary">Primary</Button>
|
|
89
|
-
<Button variant="contained" color="secondary">Secondary</Button>
|
|
90
|
-
<Button variant="contained" color="error">Error</Button>
|
|
91
|
-
<Button variant="contained" color="warning">Warning</Button>
|
|
92
|
-
<Button variant="contained" color="success">Success</Button>
|
|
93
|
-
<Button variant="contained" color="info">Info</Button>
|
|
94
|
-
</Stack>
|
|
95
|
-
)
|
|
96
|
-
Colors.parameters = {
|
|
97
|
-
docs: {
|
|
98
|
-
description: {
|
|
99
|
-
story: DOCS.Button.Colors
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
export const Sizes: ComponentStory<typeof Button> = (args) => (
|
|
105
|
-
<Box sx={{ '& button': { m: 1 } }}>
|
|
106
|
-
<div>
|
|
107
|
-
<Button size="small">Small</Button>
|
|
108
|
-
<Button size="medium">Medium</Button>
|
|
109
|
-
<Button size="large">Large</Button>
|
|
110
|
-
</div>
|
|
111
|
-
<div>
|
|
112
|
-
<Button variant="outlined" size="small">
|
|
113
|
-
Small
|
|
114
|
-
</Button>
|
|
115
|
-
<Button variant="outlined" size="medium">
|
|
116
|
-
Medium
|
|
117
|
-
</Button>
|
|
118
|
-
<Button variant="outlined" size="large">
|
|
119
|
-
Large
|
|
120
|
-
</Button>
|
|
121
|
-
</div>
|
|
122
|
-
<div>
|
|
123
|
-
<Button variant="contained" size="small">
|
|
124
|
-
Small
|
|
125
|
-
</Button>
|
|
126
|
-
<Button variant="contained" size="medium">
|
|
127
|
-
Medium
|
|
128
|
-
</Button>
|
|
129
|
-
<Button variant="contained" size="large">
|
|
130
|
-
Large
|
|
131
|
-
</Button>
|
|
132
|
-
</div>
|
|
133
|
-
</Box>
|
|
134
|
-
)
|
|
135
|
-
Sizes.parameters = {
|
|
136
|
-
docs: {
|
|
137
|
-
description: {
|
|
138
|
-
story: DOCS.Button.Sizes
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
export const WithIcon: ComponentStory<typeof Button> = (args) => (
|
|
144
|
-
<Stack direction="row" spacing={2}>
|
|
145
|
-
<Button variant="outlined" startIcon={<DeleteIcon />}>
|
|
146
|
-
Delete
|
|
147
|
-
</Button>
|
|
148
|
-
<Button variant="contained" endIcon={<SendIcon />}>
|
|
149
|
-
Send
|
|
150
|
-
</Button>
|
|
151
|
-
</Stack>
|
|
152
|
-
)
|
|
153
|
-
WithIcon.parameters = {
|
|
154
|
-
docs: {
|
|
155
|
-
description: {
|
|
156
|
-
story: DOCS.Button.WithIcon
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
export const IconButtons: ComponentStory<typeof Button> = (args) => (
|
|
162
|
-
<Stack direction="row" spacing={1}>
|
|
163
|
-
<IconButton aria-label="delete">
|
|
164
|
-
<DeleteIcon />
|
|
165
|
-
</IconButton>
|
|
166
|
-
<IconButton aria-label="delete" disabled color="primary">
|
|
167
|
-
<DeleteIcon />
|
|
168
|
-
</IconButton>
|
|
169
|
-
<IconButton color="secondary" aria-label="add an alarm">
|
|
170
|
-
<AlarmIcon />
|
|
171
|
-
</IconButton>
|
|
172
|
-
<IconButton color="primary" aria-label="add to shopping cart">
|
|
173
|
-
<AddShoppingCartIcon />
|
|
174
|
-
</IconButton>
|
|
175
|
-
</Stack>
|
|
176
|
-
)
|
|
177
|
-
IconButtons.parameters = {
|
|
178
|
-
docs: {
|
|
179
|
-
description: {
|
|
180
|
-
story: DOCS.Button.IconButtons
|
|
181
|
-
},
|
|
182
|
-
source: {
|
|
183
|
-
type: 'code'
|
|
184
|
-
}
|
|
185
|
-
}
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
export const All: ComponentStory<typeof AllCombinations> = (args) => (
|
|
189
|
-
<AllCombinations />
|
|
190
|
-
)
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { Canvas, Meta, Story } from '@storybook/addon-docs';
|
|
2
|
-
import Button from '../../../../lib/components/atoms/Button/Button';
|
|
3
|
-
import { MUIIcon, MaterialDesignIcon, W3CIcon, FigmaIcon, GithubIcon } from '../../../utils/CustomIcons';
|
|
4
|
-
import Chip from '@mui/material/Chip';
|
|
5
|
-
import Stack from '@mui/material/Stack';
|
|
6
|
-
|
|
7
|
-
<Meta title="Components/Inputs/Button/Overview" component={Button} />
|
|
8
|
-
|
|
9
|
-
[](#button-overview)Button Overview <span class="sbdocs-edit-link"><Chip clickable component="a" href="https://github.com/ht2-labs/design-system/tree/main/src/stories/Components/Inputs/Button/Overview.stories.mdx" size="small" label="Edit" variant="outlined" /></span>
|
|
10
|
-
=================================================================================
|
|
11
|
-
|
|
12
|
-
### [](#what-does-it-do)What does it do?
|
|
13
|
-
|
|
14
|
-
A button helps the user to find the most important actions of a page or within a viewport and enables them to perform these actions. The label is used to clearly indicate to the user what action will be triggered.
|
|
15
|
-
|
|
16
|
-
<Stack direction="row" spacing={1}>
|
|
17
|
-
<Chip clickable component="a" href="https://mui.com/components/buttons/" size="small" icon={<MUIIcon viewBox="-5 0 40 30" />} label="Material UI" variant="outlined" />
|
|
18
|
-
<Chip clickable component="a" href="https://material.io/components/buttons" size="small" icon={<MaterialDesignIcon />} label="Material Design" variant="outlined" />
|
|
19
|
-
<Chip clickable component="a" href="https://www.w3.org/TR/wai-aria-practices/#button" size="small" icon={<W3CIcon />} label="WAI-ARIA" variant="outlined" />
|
|
20
|
-
<Chip clickable component="a" href="https://www.figma.com/proto/mBDuFn79U8wQIIEoCGpMew/DS%3A-Component-Library?node-id=487%3A14431&scaling=min-zoom&page-id=310%3A35254&starting-point-node-id=487%3A14431" size="small" icon={<FigmaIcon />} label="Figma" variant="outlined" />
|
|
21
|
-
<Chip clickable component="a" href="https://github.com/HT2-Labs/design-system/tree/main/src/lib/components/atoms/Button" size="small" icon={<GithubIcon />} label="Github" variant="outlined" />
|
|
22
|
-
</Stack>
|
|
23
|
-
|
|
24
|
-
### [](#why-use-it)Why use it?
|
|
25
|
-
|
|
26
|
-
* Buttons are used to show the user's choice of options for actions and assign these to a clear hierarchy.
|
|
27
|
-
* Buttons allow users to commit a change, complete steps in a task, or make choices.
|
|
28
|
-
|
|
29
|
-
### [](#how-to-implement-it)How to implement it?
|
|
30
|
-
|
|
31
|
-
Below is an overview of the Contained, Outlined and Text button components.
|
|
32
|
-
|
|
33
|
-
<Canvas isExpanded>
|
|
34
|
-
<Button variant="text">Text</Button>
|
|
35
|
-
<Button variant="contained">Contained</Button>
|
|
36
|
-
<Button variant="outlined">Outlined</Button>
|
|
37
|
-
</Canvas>
|
|
38
|
-
|
|
39
|
-
### [](#best-practices)Best practices
|
|
40
|
-
|
|
41
|
-
* Text button (low emphasis) - Text buttons are typically used for less important actions.
|
|
42
|
-
* Outlined Button (medium emphasis) - Outlined buttons are used for more emphasis than text buttons due to the stroke.
|
|
43
|
-
* Contained button (high emphasis) - Contained buttons have more emphasis, as they use a color fill and shadow.
|
|
44
|
-
|
|
45
|
-
### [](#design-prototype)Design prototype
|
|
46
|
-
<iframe
|
|
47
|
-
allowfullscreen
|
|
48
|
-
frameborder="0"
|
|
49
|
-
height="350"
|
|
50
|
-
width="100%"
|
|
51
|
-
src="https://www.figma.com/embed?embed_host=share&url=https://www.figma.com/proto/mBDuFn79U8wQIIEoCGpMew/DS%3A-Component-Library?node-id=487%3A14431&scaling=min-zoom&page-id=310%3A35254&starting-point-node-id=487%3A14431"
|
|
52
|
-
/>
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { Canvas, Meta, Story } from '@storybook/addon-docs';
|
|
2
|
-
import Checkbox from '../../../../lib/components/atoms/Checkbox/Checkbox';
|
|
3
|
-
import FormControlLabel from '@mui/material/FormControlLabel';
|
|
4
|
-
import Chip from '@mui/material/Chip';
|
|
5
|
-
|
|
6
|
-
<Meta title="Components/Inputs/Checkbox/Accessibility" />
|
|
7
|
-
|
|
8
|
-
[](#checkbox-accessibility)Checkbox Accessibility <span class="sbdocs-edit-link"><Chip clickable component="a" href="https://github.com/ht2-labs/design-system/tree/main/src/stories/Components/Inputs/Checkbox/Accessibility.stories.mdx" size="small" label="Edit" variant="outlined" /></span>
|
|
9
|
-
=================================================================================
|
|
10
|
-
|
|
11
|
-
This component has been validated to meet the WCAG 2.1 AA and Section 508 accessibility guidelines; however, changes made by the developer can affect accessibility compliance.
|
|
12
|
-
|
|
13
|
-
Please follow the guidance in this section and see [WAI-ARIA Checkboxes](https://www.w3.org/TR/wai-aria-practices/#checkbox) for more information.
|
|
14
|
-
|
|
15
|
-
## [](#guidelines)Guidelines
|
|
16
|
-
* Checkboxes must have a clear and concise description provided by a `<label>` element or `aria-label` attribute.
|
|
17
|
-
* Users should be warned if selecting a checkbox will cause a change in context.
|
|
18
|
-
* If the checkbox is a required field include the `aria-required` property and indicate that it is a required field and use the validation message for input errors.
|
|
19
|
-
|
|
20
|
-
### [](#when-to-use-this-component)When to use this component
|
|
21
|
-
Checkboxes are used when there are lists of options and the user may select any number of choices, including zero, one, or several. In other words, each checkbox is independent of all other checkboxes in the list, so checking one box doesn't uncheck the others.
|
|
22
|
-
|
|
23
|
-
### [](#screen-readers)Screen readers
|
|
24
|
-
Checkboxes should have unique labels to identify their usage to assistive technologies whenever possible. In most cases, this is done by using a `<label>` element generated by the `FormControlLabel` component:
|
|
25
|
-
<Canvas>
|
|
26
|
-
<FormControlLabel control={<Checkbox defaultChecked />} label="Your label goes here" />
|
|
27
|
-
</Canvas>
|
|
28
|
-
|
|
29
|
-
When a label element can't be used, it's necessary to add an attribute directly to the input component to provide information to assistive technologies. In this case, you can apply the additional attribute (e.g. `aria-label`, `aria-labelledby`, `title`) via the `inputProps` prop:
|
|
30
|
-
<Canvas>
|
|
31
|
-
<Checkbox
|
|
32
|
-
inputProps={{
|
|
33
|
-
'aria-label': 'Your label goes here',
|
|
34
|
-
}}
|
|
35
|
-
/>
|
|
36
|
-
</Canvas>
|
|
37
|
-
|
|
38
|
-
Use positive and active wording for checkbox labels, so that it's clear what will happen if the user turns on the checkbox. In other words, avoid negations such as "Don't send me more email," which would mean that the user would have to check the box in order for something not to happen. Write checkbox labels so that users know both what will happen if they check a particular box, and what will happen if they leave it unchecked.
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import * as React from 'react'
|
|
2
|
-
import {
|
|
3
|
-
Bookmark as BookmarkIcon,
|
|
4
|
-
BookmarkBorder as BookmarkBorderIcon,
|
|
5
|
-
Favorite as FavoriteIcon,
|
|
6
|
-
FavoriteBorder as FavoriteBorderIcon
|
|
7
|
-
} from '@mui/icons-material'
|
|
8
|
-
import { Box, FormControlLabel, FormGroup } from '@mui/material'
|
|
9
|
-
import Checkbox from '../../../../lib/components/atoms/Checkbox/Checkbox'
|
|
10
|
-
|
|
11
|
-
const CheckboxGrid = (args: any): JSX.Element => {
|
|
12
|
-
const label = { inputProps: { 'aria-label': 'Checkbox demo' } }
|
|
13
|
-
|
|
14
|
-
return (
|
|
15
|
-
<Box>
|
|
16
|
-
<Checkbox {...label} {...args} />
|
|
17
|
-
<Checkbox {...label} {...args} color="primary" />
|
|
18
|
-
<Checkbox {...label} {...args} color="secondary" />
|
|
19
|
-
<Checkbox {...label} {...args} color="error" />
|
|
20
|
-
<Checkbox {...label} {...args} color="success" />
|
|
21
|
-
<Checkbox {...label} {...args} color="info" />
|
|
22
|
-
<Checkbox {...label} {...args} color="warning" />
|
|
23
|
-
<Checkbox {...label} {...args} icon={<FavoriteBorderIcon />} checkedIcon={<FavoriteIcon />} />
|
|
24
|
-
<Checkbox {...label} {...args} icon={<BookmarkBorderIcon />} checkedIcon={<BookmarkIcon />} />
|
|
25
|
-
<FormGroup row>
|
|
26
|
-
<FormControlLabel control={<Checkbox {...label} {...args} />} label="Label"/>
|
|
27
|
-
<FormControlLabel control={<Checkbox {...label} {...args} color="primary" />} label="Primary"/>
|
|
28
|
-
<FormControlLabel control={<Checkbox {...label} {...args} color="secondary" />} label="Secondary"/>
|
|
29
|
-
<FormControlLabel control={<Checkbox {...label} {...args} color="error" />} label="Error"/>
|
|
30
|
-
<FormControlLabel control={<Checkbox {...label} {...args} color="success" />} label="Success"/>
|
|
31
|
-
<FormControlLabel control={<Checkbox {...label} {...args} color="info" />} label="Info"/>
|
|
32
|
-
<FormControlLabel control={<Checkbox {...label} {...args} color="warning" />} label="Warning"/>
|
|
33
|
-
<FormControlLabel control={<Checkbox {...label} {...args} icon={<FavoriteBorderIcon />} checkedIcon={<FavoriteIcon />} />} label="Label"/>
|
|
34
|
-
<FormControlLabel control={<Checkbox {...label} {...args} icon={<BookmarkBorderIcon />} checkedIcon={<BookmarkIcon />} />} label="Label"/>
|
|
35
|
-
</FormGroup>
|
|
36
|
-
</Box>
|
|
37
|
-
)
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
export default function AllCombinations (): JSX.Element {
|
|
41
|
-
const combinations = [
|
|
42
|
-
{ defaultChecked: true },
|
|
43
|
-
{ },
|
|
44
|
-
{ disabled: true },
|
|
45
|
-
{ disabled: true, checked: true }
|
|
46
|
-
]
|
|
47
|
-
|
|
48
|
-
return (
|
|
49
|
-
<Box>
|
|
50
|
-
{combinations.map(checkboxConfig => (
|
|
51
|
-
<CheckboxGrid {...checkboxConfig} />
|
|
52
|
-
))}
|
|
53
|
-
</Box>
|
|
54
|
-
)
|
|
55
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { ComponentMeta, ComponentStory } from '@storybook/react'
|
|
2
|
-
import * as React from 'react'
|
|
3
|
-
import Checkbox from '../../../../lib/components/atoms/Checkbox/Checkbox'
|
|
4
|
-
|
|
5
|
-
export default {
|
|
6
|
-
title: 'Components/Inputs/Checkbox/Properties',
|
|
7
|
-
component: Checkbox,
|
|
8
|
-
parameters: {
|
|
9
|
-
controls: {
|
|
10
|
-
sort: 'requiredFirst'
|
|
11
|
-
}
|
|
12
|
-
},
|
|
13
|
-
addons: {
|
|
14
|
-
panelPosition: 'right'
|
|
15
|
-
}
|
|
16
|
-
} as ComponentMeta<typeof Checkbox>
|
|
17
|
-
|
|
18
|
-
// 👇 We create a “template” of how args map to rendering
|
|
19
|
-
const Template: ComponentStory<typeof Checkbox> = (args) => <Checkbox {...args} />
|
|
20
|
-
|
|
21
|
-
export const Properties = Template.bind({})
|
|
22
|
-
Properties.args = {}
|