diff --git a/.changeset/quick-wasps-kick.md b/.changeset/quick-wasps-kick.md
new file mode 100644
index 0000000000..c7de2f8fc6
--- /dev/null
+++ b/.changeset/quick-wasps-kick.md
@@ -0,0 +1,5 @@
+---
+"@primer/css": major
+---
+
+Remove `ActionList`
diff --git a/docs/content/components/action-list.md b/docs/content/components/action-list.md
deleted file mode 100644
index 1296346e2f..0000000000
--- a/docs/content/components/action-list.md
+++ /dev/null
@@ -1,445 +0,0 @@
----
-title: Action List
-path: components/action-list
-status: alpha
-source: 'https://github.com/primer/css/tree/main/src/actionlist'
-bundle: action-list
-storybook: https://primer.style/css/storybook/?path=/story/components-actionlist-actionlistitem--playground
----
-
-Reference the [Action list interface guidelines](https://primer.style/design/components/action-list) for details on where and how to use Action list.
-
-## Action list
-
-Action list is a `ul` list designed to contain list items.
-
-### Variants
-
-| Class | Description |
-| :- | :- |
-| `ActionList` | Default styles |
-| `ActionList--divided` | Show dividers between items |
-| `ActionList--subGroup` | If Action List is nested as a sub-list |
-| `ActionList--tree` | Tree-view specific styles |
-
-#### Default
-
-```html live
-
-
-
- Action list item
-
-
-
-
- Action list item
-
-
-
-```
-
-#### Item dividers
-
-```html live
-
-```
-
-#### Nested sub list
-
-```html live
-
-
- Access
-
-
-
-
-
-
-
- Moderation
-
-
-
-
-
-
-
-
-```
-
-
-## Action list divider
-
-List item `li` for separating groups of content
-
-### Variants
-
-| Class | Description |
-| :- | :- |
-| `ActionList-sectionDivider` | Default subtle divider line |
-| `ActionList-sectionDivider--filled` | Thicker divider line |
-| `ActionList-item-description` | Optional section header secondary text |
-
-#### Default
-
-```html live
-
-```
-
-#### Filled
-
-```html live
-
-```
-### Divider with label text
-
-When using a section label for a group, give the `h3` an id to be referenced by the group `ul`
-#### Filled with section label
-
-```html live
-
-
-
- List group title
-
-
-
-
-```
-
-#### Default with section label
-
-```html live
-
-
-
- List group title
-
-
-
-
-```
-
-#### Default with section label + description
-
-```html live
-
-
-
- List group title
-
- Group description
-
-
-
-```
-
-## Action list item
-
-List item `li` handling semantics, state and interactions
-
-### Variants
-
-| Class | Description |
-| :- | :- |
-| `ActionList-item` | Default styles |
-| `ActionList-item--hasSubItem` | Item contains a sub item `ul` |
-| `ActionList-item--subItem` | Indent + small font size for sub item `li` (optional) |
-| `ActionList-item--navActive` | Nav item and `aria-current` |
-| `ActionList-item--danger` | Item is destructive |
-
-
-## Action list item content
-
-Contains and places all child elements within action list item. Can be either an `a href` tag for list link items, or a `button` for items that provide an event on Action List Item `li`.
-
-### Variants
-
-| Class | Description |
-| :- | :- |
-| `ActionList-content` | Defines the overall layout grid |
-| `ActionList-content--sizeMedium` | 40px row height |
-| `ActionList-content--sizeLarge` | 48px row height, default for touch devices |
-| `ActionList-content--visual16` | Creates left padding for sub list if leading visual exists |
-| `ActionList-content--visual20` | Creates left padding for sub list if leading visual exists |
-| `ActionList-content--visual24` | Creates left padding for sub list if leading visual exists |
-| `ActionList-content--hasActiveSubItem` | Handles active nav state if child item is active |
-| `ActionList-item-action` | min-height + default styles for visual slot |
-| `ActionList-item-action--leading` | Slot: multi/single select |
-| `ActionList-item-action--trailing` | Slot: Button, collapse icon |
-| `ActionList-item-visual` | min-height + default styles for visual slot |
-| `ActionList-item-visual--leading` | Slot: SVG or graphic like Avatar |
-| `ActionList-item-visual--trailing` | Slot: SVG or text |
-| `ActionList-item-label` | Item text |
-| `ActionList-item-descriptionWrap` | Wraps label/description |
-| `ActionList-item-descriptionWrap--inline` | Display description inline with label |
-| `ActionList-item-description` | Item description (block by default) |
-
-### Basic text only item
-
-```html live
-
-
-
- Basic item label
-
-
-
-```
-
-### Size (all options)
-
-```html live
-
-
-```
-
-### Visuals (all options- leading & trailing)
-
-```html live
-
-
-
-
-
-
-
-
- Item with trailing visual
-
-
-
-
-
-
-
-
-```
-
-### Trailing visual as text
-
-```html live
-
-
-
- Item with trailing visual
-
- ⌘N
-
-
-
-
-```
-
-### Inline description
-
-```html live
-
-
-
-
- Item label
- This is a description
-
-
-
-
-```
-
-### Active navigational item
-
-```html live
-
-
-```
-
-### Danger item
-
-```html live
-
-
-
- Danger danger
-
-
-
-```
-
-### Actions
-
-### Leading action: single select listbox
-
-```html live
-
-
-
-
-
-
-
- Option label
-
-
-
-
-
-
-
-
- Option label
-
-
-
-
-
-
-
-
- Option label
-
-
-
-```
-
-### Leading action: multi select listbox
-
-```html live
-
-
-
-
-
-
-
-
-
- Multi select item
-
-
-
-
-
-
-
-
-
-
- Multi select item
-
-
-
-```
-
-### Trailing action: collapse
-
-```html live
-
-
-
- Collapsible
-
-
-
-
-
-
-
-
-```
diff --git a/docs/src/stories/components/ActionList/ActionList.stories.jsx b/docs/src/stories/components/ActionList/ActionList.stories.jsx
deleted file mode 100644
index 2dbad09abd..0000000000
--- a/docs/src/stories/components/ActionList/ActionList.stories.jsx
+++ /dev/null
@@ -1,77 +0,0 @@
-import React from 'react'
-import {ListItemTemplate} from '../../ui-patterns/ActionList/ActionListItem.stories'
-import {ListTemplate} from '../../ui-patterns/ActionList/ActionList.stories.jsx'
-
-export default {
- title: 'Components/ActionList/ActionList',
- excludeStories: ['ActionListTemplate'],
- argTypes: {
- showDividers: {
- control: {type: 'boolean'},
- description: 'Show dividers between items',
- table: {
- category: 'CSS'
- }
- },
- role: {
- options: ['list'],
- control: {
- type: 'inline-radio'
- },
- description: 'Semantic list role',
- table: {
- category: 'HTML'
- }
- },
- ariaLabel: {
- name: 'ariaLabel',
- type: 'string',
- description: 'If no list ActionListDivider is provided, include an aria-label',
- table: {
- category: 'HTML'
- }
- },
- ariaLabelledBy: {
- name: 'ariaLabelledBy',
- type: 'string',
- description: 'Reference ID of ActionListDivider',
- table: {
- category: 'HTML'
- }
- },
- listPadding: {
- options: [0, 1], // iterator
- mapping: [null, 'ActionList--full'], // values
- control: {
- type: 'inline-radio',
- labels: ['inset', 'full-bleed']
- },
- description: 'ActionList includes 8px padding by default, full-bleed removes all padding',
- table: {
- category: 'CSS'
- }
- },
- children: {
- table: {
- disable: true
- }
- }
- }
-}
-
-export const ActionListTemplate = ListTemplate.bind({})
-
-export const Playground = ActionListTemplate.bind({})
-Playground.args = {
- showDividers: false,
- listPadding: 0,
- role: 'list',
- ariaLabel: '',
- ariaLabelledBy: '',
- children: (
- <>
-
-
- >
- )
-}
diff --git a/docs/src/stories/components/ActionList/ActionListDivider.stories.jsx b/docs/src/stories/components/ActionList/ActionListDivider.stories.jsx
deleted file mode 100644
index eab957deaf..0000000000
--- a/docs/src/stories/components/ActionList/ActionListDivider.stories.jsx
+++ /dev/null
@@ -1,65 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import {ListTemplate} from '../../ui-patterns/ActionList/ActionList.stories.jsx'
-import {DividerTemplate} from '../../ui-patterns/ActionList/ActionListDivider.stories.jsx'
-
-export default {
- title: 'Components/ActionList/ActionListDivider',
- excludeStories: ['ActionDividerTemplate'],
- argTypes: {
- variant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-sectionDivider--filled'], // values
- control: {
- type: 'inline-radio',
- labels: ['subtle', 'filled']
- },
- table: {
- category: 'CSS'
- }
- },
- title: {
- defaultValue: '',
- type: 'string',
- name: 'title',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- description: {
- defaultValue: '',
- type: 'string',
- name: 'description',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- id: {
- defaultValue: '',
- type: 'string',
- name: 'id',
- description: 'Provide label for NavigationList aria-labelledby',
- table: {
- category: 'HTML'
- }
- }
- }
-}
-
-export const ActionDividerTemplate = DividerTemplate.bind({})
-
-export const Playground = ActionDividerTemplate.bind({})
-Playground.args = {
- title: 'Section title',
- description: 'Section description',
- variant: 0
-}
-Playground.decorators = [
- Story => (
-
-
-
- )
-]
diff --git a/docs/src/stories/components/ActionList/ActionListDividerFeatures.stories.jsx b/docs/src/stories/components/ActionList/ActionListDividerFeatures.stories.jsx
deleted file mode 100644
index a4e5c8b8ab..0000000000
--- a/docs/src/stories/components/ActionList/ActionListDividerFeatures.stories.jsx
+++ /dev/null
@@ -1,28 +0,0 @@
-import React from 'react'
-import {ListTemplate} from '../../ui-patterns/ActionList/ActionList.stories.jsx'
-
-import {
- PatternTitle,
- PatternFilled,
- PatternWithDescription,
- PatternSeparator
-} from '../../ui-patterns/ActionList/ActionListDividerFeatures.stories.jsx'
-
-export default {
- title: 'Components/ActionList/ActionListDivider/Features',
- decorators: [
- Story => (
-
-
-
- )
- ]
-}
-
-export const Title = ({}) =>
-
-export const Filled = ({}) =>
-
-export const WithDescription = ({}) =>
-
-export const Separator = ({}) =>
diff --git a/docs/src/stories/components/ActionList/ActionListExamples.stories.jsx b/docs/src/stories/components/ActionList/ActionListExamples.stories.jsx
deleted file mode 100644
index da1b0b1cc0..0000000000
--- a/docs/src/stories/components/ActionList/ActionListExamples.stories.jsx
+++ /dev/null
@@ -1,54 +0,0 @@
-import React from 'react'
-import {DividerTemplate} from '../../ui-patterns/ActionList/ActionListDivider.stories'
-import {ListItemTemplate} from '../../ui-patterns/ActionList/ActionListItem.stories'
-import {ListTemplate} from '../../ui-patterns/ActionList/ActionList.stories.jsx'
-
-export default {
- title: 'Components/ActionList/Examples'
-}
-
-export const List = ListTemplate.bind({})
-List.storyName = 'List of links'
-List.args = {
- ...ListTemplate.args,
- ...ListItemTemplate.args,
- role: undefined,
- showDividers: false,
- children: (
- <>
-
-
-
- `}
- />
- `}
- />
- `}
- />
- `}
- />
-
-
- >
- )
-}
diff --git a/docs/src/stories/components/ActionList/ActionListFeatures.stories.jsx b/docs/src/stories/components/ActionList/ActionListFeatures.stories.jsx
deleted file mode 100644
index 6b4686f183..0000000000
--- a/docs/src/stories/components/ActionList/ActionListFeatures.stories.jsx
+++ /dev/null
@@ -1,16 +0,0 @@
-import React from 'react'
-import {
- PatternShowDividers,
- PatternInsetPadding,
- PatternFullBleed
-} from '../../ui-patterns/ActionList/ActionListFeatures.stories.jsx'
-
-export default {
- title: 'Components/ActionList/ActionList/Features'
-}
-
-export const ShowDividers = ({}) =>
-
-export const InsetPadding = ({}) =>
-
-export const FullBleed = ({}) =>
diff --git a/docs/src/stories/components/ActionList/ActionListItem.stories.jsx b/docs/src/stories/components/ActionList/ActionListItem.stories.jsx
deleted file mode 100644
index 906108a11b..0000000000
--- a/docs/src/stories/components/ActionList/ActionListItem.stories.jsx
+++ /dev/null
@@ -1,139 +0,0 @@
-import React from 'react'
-import {ListTemplate} from '../../ui-patterns/ActionList/ActionList.stories.jsx'
-import {ListItemTemplate} from '../../ui-patterns/ActionList/ActionListItem.stories.jsx'
-
-export default {
- title: 'Components/ActionList/ActionListItem',
- excludeStories: ['ActionListItemTemplate'],
- argTypes: {
- size: {
- options: [0, 1, 2], // iterator
- mapping: ['', 'ActionList-content--sizeMedium', 'ActionList-content--sizeLarge'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'medium', 'large']
- },
- description: 'small (default), medium, large',
- defaultValue: '',
- table: {
- category: 'CSS'
- }
- },
- variant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-item--danger'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'danger']
- },
- defaultValue: '',
- table: {
- category: 'CSS'
- }
- },
- truncateItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- leadingVisual: {
- defaultValue: '',
- name: 'leadingVisual',
- type: 'string',
- description: 'Paste [Octicon](https://primer.style/octicons/) in control field',
- table: {
- category: 'HTML'
- }
- },
- leadingVisualSize: {
- options: [0, 1, 2], // iterator
- mapping: ['ActionList-content--visual16', 'ActionList-content--visual20', 'ActionList-content--visual24'], // values
- control: {
- type: 'inline-radio',
- labels: ['16px', '20px', '24px']
- },
- description: 'leading visual width',
- defaultValue: 'ActionList-content--visual16',
- table: {
- category: 'CSS'
- }
- },
- trailingVisual: {
- defaultValue: '',
- name: 'trailingVisual',
- type: 'string',
- description: 'Paste [Octicon](https://primer.style/octicons/) in control field',
- table: {
- category: 'HTML'
- }
- },
- text: {
- defaultValue: 'Item label',
- type: 'string',
- name: 'text',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- href: {
- defaultValue: '',
- type: 'string',
- name: 'href',
- description: 'Item link (href)',
- table: {
- category: 'HTML'
- }
- },
- ariaCurrent: {
- options: ['location', 'page'],
- control: {type: 'inline-radio'},
- description: 'location for anchor links, page for global page navigation',
- table: {
- category: 'HTML'
- }
- },
- description: {
- defaultValue: '',
- type: 'string',
- name: 'description',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- descriptionVariant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-item-descriptionWrap--inline'], // values
- control: {
- type: 'inline-radio',
- labels: ['block', 'inline']
- },
- description: 'block (default), inline',
- defaultValue: 'ActionList-item-blockDescription',
- table: {
- category: 'CSS'
- }
- }
- }
-}
-
-export const ActionListItemTemplate = ListItemTemplate.bind({})
-
-export const Playground = ActionListItemTemplate.bind({})
-Playground.decorators = [
- Story => (
-
-
-
- )
-]
-Playground.args = {
- truncateItem: false,
- size: 0,
- variant: 0,
- descriptionVariant: 0,
- leadingVisualSize: 0
-}
diff --git a/docs/src/stories/components/ActionList/ActionListItemFeatures.stories.jsx b/docs/src/stories/components/ActionList/ActionListItemFeatures.stories.jsx
deleted file mode 100644
index a2eb8f7805..0000000000
--- a/docs/src/stories/components/ActionList/ActionListItemFeatures.stories.jsx
+++ /dev/null
@@ -1,130 +0,0 @@
-import React from 'react'
-import {ListTemplate} from '../../ui-patterns/ActionList/ActionList.stories.jsx'
-import {
- PatternTextOnly,
- PatternSizeMedium,
- PatternSizeMediumWithDescription,
- PatternSizeLarge,
- PatternSizeLargeWithDescription,
- PatternVisualLeading,
- PatternVisualTrailing,
- PatternVisualTrailingText,
- PatternVisualLeadingAndTrailing,
- PatternDescriptionBlock,
- PatternDescriptionBlockWithLeadingVisual,
- PatternDescriptionBlockWithTrailingVisual,
- PatternDescriptionBlockWithLeadingAndTrailingVisual,
- PatternDescriptionInline,
- PatternDescriptionInlineWithLeadingVisual,
- PatternDescriptionInlineWithTrailingVisual,
- PatternDescriptionInlineWithLeadingAndTrailingVisual,
- PatternNavActiveAnchor,
- PatternNavActivePage,
- PatternVariantDangerItem,
- PatternVariantDangerItemLeading,
- PatternVariantDangerItemTrailing,
- PatternVariantDangerItemLeadingTrailing,
- PatternTruncateText,
- PatternWrapText
-} from '../../ui-patterns/ActionList/ActionListItemFeatures.stories.jsx'
-
-export default {
- title: 'Components/ActionList/ActionListItem/Features',
- decorators: [
- Story => (
-
-
-
- )
- ]
-}
-
-export const TextOnly = ({}) =>
-
-export const SizeMedium = ({}) =>
-
-export const SizeMediumWithDescription = ({}) => (
-
-)
-
-export const SizeLarge = ({}) =>
-
-export const SizeLargeWithDescription = ({}) => (
-
-)
-
-export const VisualLeading = ({}) =>
-
-export const VisualTrailing = ({}) =>
-
-export const VisualTrailingText = ({}) =>
-
-export const VisualLeadingAndTrailing = ({}) => (
-
-)
-
-export const DescriptionBlock = ({}) =>
-
-export const DescriptionBlockWithLeadingVisual = ({}) => (
-
-)
-
-export const DescriptionBlockWithTrailingVisual = ({}) => (
-
-)
-
-export const DescriptionBlockWithLeadingAndTrailingVisual = ({}) => (
-
-)
-
-export const DescriptionInline = ({}) =>
-
-export const DescriptionInlineWithLeadingVisual = ({}) => (
-
-)
-
-export const DescriptionInlineWithTrailingVisual = ({}) => (
-
-)
-
-export const DescriptionInlineWithLeadingAndTrailingVisual = ({}) => (
-
-)
-
-export const NavActiveAnchor = ({}) =>
-
-export const NavActivePage = ({}) =>
-
-export const VariantDangerItem = ({}) =>
-
-export const VariantDangerItemLeading = ({}) => (
-
-)
-
-export const VariantDangerItemTrailing = ({}) => (
-
-)
-
-export const VariantDangerItemLeadingTrailing = ({}) => (
-
-)
-
-export const VariantDisabledItem = ({}) =>
-
-export const VariantDisabledItemLeading = ({}) => (
-
-)
-
-export const VariantDisabledItemTrailing = ({}) => (
-
-)
-
-export const VariantDisabledItemLeadingTrailing = ({}) => (
-
-)
-
-export const TruncateText = ({}) =>
-
-export const WrapText = ({}) =>
diff --git a/docs/src/stories/components/Layout/LayoutExamples.stories.jsx b/docs/src/stories/components/Layout/LayoutExamples.stories.jsx
deleted file mode 100644
index 3c9ff444e8..0000000000
--- a/docs/src/stories/components/Layout/LayoutExamples.stories.jsx
+++ /dev/null
@@ -1,316 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import {PageLayoutTemplate} from './PageLayout.stories'
-import {SplitPageLayoutTemplate} from './SplitPageLayout.stories'
-import {ActionListTreeViewTemplate} from '../../ui-patterns/ActionList/ActionListTree.stories'
-import {RepoSettings, NavDiscussionsPane} from '../NavigationList/NavigationListExamples.stories'
-import {LayoutAlphaTemplate} from './LayoutAlpha.stories'
-
-export default {
- title: 'Components/Layout/Beta/Examples'
-}
-
-export const Settings = SplitPageLayoutTemplate.bind({})
-Settings.storyName = 'Settings'
-Settings.parameters = {
- layout: 'fullscreen'
-}
-Settings.args = {
- // Structure
- padding: 'normal',
-
- // Responsive
- primaryRegion: 'pane',
-
- // Pane
- paneWidth: 'wide',
- paneIsSticky: true,
-
- // Content
- contentWidth: 'md',
-
- paneChildren: (
- <>
- Repository settings
-
-
-
- >
- ),
-
- contentChildren: (
- <>
- General
-
- {' '}
-
-
- {' '}
-
-
- {' '}
-
- >
- )
-}
-
-export const Discussions = PageLayoutTemplate.bind({})
-Discussions.parameters = {
- layout: 'fullscreen'
-}
-Discussions.storyName = 'Discussions'
-Discussions.args = {
- responsiveVariant: 'separateRegions',
- panePosition: 'start',
- paneWidth: 'narrow',
- hasHeader: true,
- headerChildren: (
- <>
-
-
-
- All discussions
-
- {/*
- I'm using a `no-wrap` class between the heading and the `triangle-down`
- octicon to make sure it won't be ever rendered as a typographic widow
- */}
-
-
-
-
-
-
New
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- New
-
-
- Top
-
-
-
-
Labels
-
-
New discussion
-
-
- >
- ),
-
- paneChildren: (
- <>
-
-
-
- >
- ),
-
- contentChildren: (
- <>
-
-
- {' '}
-
- >
- }
- sidebarChildren={
- <>
-
- {' '}
-
-
- {' '}
-
- >
- }
- />
- >
- )
-}
-
-export const IssueDetail = PageLayoutTemplate.bind({})
-IssueDetail.storyName = 'Issue detail'
-IssueDetail.parameters = {
- layout: 'fullscreen'
-}
-IssueDetail.args = {
- panePosition: 'end',
- paneWidth: 'default',
- hasHeader: true,
- hasHeaderDivider: true,
- headerDividerWhenNarrow: 'filled',
- paneDividerWhenNarrow: 'filled',
- headerChildren: (
- <>
-
- Traverse does not calculate scope in object deconstructor
- #14024
-
-
-
-
-
-
- {' '}
- Open
-
-
- monalisa opened this issue 6 days ago
-
-
- >
- ),
- contentChildren: (
- <>
-
- {' '}
-
- >
- ),
- paneChildren: (
- <>
-
- {' '}
-
-
- {' '}
-
-
- {' '}
-
- >
- )
-}
-
-export const PullDetail = SplitPageLayoutTemplate.bind({});
-PullDetail.storyName = 'Pull request detail';
-PullDetail.parameters = {
- layout: 'fullscreen',
-};
-PullDetail.args = {
- padding: 'none',
- primaryRegion: 'content',
- paneWidth: 'wide',
- paneIsSticky: true,
- contentWidth: 'full',
- hasHeader: true,
- hasFooter: true,
- headerChildren: (
- <>
-
-
- Traverse does not calculate scope in object deconstructor
- #14024
-
-
-
- Open
-
-
monalisa opened this issue 6 days ago
-
-
-
-
-
- Conversation
-
-
-
- Commits
-
-
-
- Checks
-
-
-
- Files changed
- 12
-
-
-
-
- >
- ),
- contentChildren: (
- <>
-
-
-
- Review changes
-
-
-
-
-
-
-
-
-
-
-
- >
- ),
- paneChildren: (
- <>
-
-
-
- Show: all changes
-
-
-
-
-
-
-
-
-
-
-
-
- {/*
-
-
*/}
- >
- ),
- footerChildren: (
- <>
- footer
- >
- )
-};
diff --git a/docs/src/stories/components/NavigationList/NavigationList.stories.jsx b/docs/src/stories/components/NavigationList/NavigationList.stories.jsx
deleted file mode 100644
index 69c539286f..0000000000
--- a/docs/src/stories/components/NavigationList/NavigationList.stories.jsx
+++ /dev/null
@@ -1,97 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import {NavigationListItemTemplate} from './NavigationListItem.stories'
-import ConditionalWrapper from '../../helpers/ConditionalWrapper'
-
-export default {
- title: 'Components/NavigationList/NavigationList',
- excludeStories: ['NavigationListTemplate'],
- argTypes: {
- showDividers: {
- control: {type: 'boolean'},
- description: 'Show dividers between items',
- table: {
- category: 'CSS'
- }
- },
- ariaLabel: {
- name: 'ariaLabel',
- type: 'string',
- description: 'Required if no visible group title provided by NavigationListDivider',
- table: {
- category: 'HTML'
- }
- },
- ariaLabelledBy: {
- name: 'ariaLabelledBy',
- type: 'string',
- description: 'Reference ID of NavigationListDivider',
- table: {
- category: 'HTML'
- }
- },
- children: {
- table: {
- disable: true
- }
- },
- listPadding: {
- options: [0, 1], // iterator
- mapping: [null, 'ActionList--full'], // values
- control: {
- type: 'inline-radio',
- labels: ['inset', 'full-bleed']
- },
- description: 'ActionList includes 8px padding by default, full-bleed removes all padding',
- table: {
- category: 'CSS'
- }
- },
- listType: {
- options: [0, 1], // iterator
- mapping: ['parent', 'nested'], // values
- control: {
- type: 'inline-radio',
- labels: ['parent', 'nested']
- },
- description: 'NavigationList can be a parent list with a or a nested list with just ',
- table: {
- category: 'CSS'
- }
- }
- }
-}
-
-export const NavigationListTemplate = ({showDividers, children, ariaLabel, ariaLabelledBy, listPadding, listType}) => (
- // wrap ul in if parent list
- {children} }>
-
-
-)
-
-export const Playground = NavigationListTemplate.bind({})
-Playground.args = {
- listType: 'parent',
- ariaLabel: '',
- showDividers: false,
- listPadding: 0,
- ariaLabelledBy: '',
- children: (
- <>
-
-
- >
- )
-}
diff --git a/docs/src/stories/components/NavigationList/NavigationListDivider.stories.jsx b/docs/src/stories/components/NavigationList/NavigationListDivider.stories.jsx
deleted file mode 100644
index b80099dc6e..0000000000
--- a/docs/src/stories/components/NavigationList/NavigationListDivider.stories.jsx
+++ /dev/null
@@ -1,63 +0,0 @@
-import React from 'react'
-import {NavigationListTemplate} from './NavigationList.stories'
-import {DividerTemplate} from '../../ui-patterns/ActionList/ActionListDivider.stories.jsx'
-
-export default {
- title: 'Components/NavigationList/NavigationListDivider',
- excludeStories: ['NavigationListDividerTemplate'],
- argTypes: {
- variant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-sectionDivider--filled'], // values
- control: {
- type: 'inline-radio',
- labels: ['subtle', 'filled']
- },
- table: {
- category: 'CSS'
- }
- },
- title: {
- defaultValue: '',
- type: 'string',
- name: 'title',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- description: {
- defaultValue: '',
- type: 'string',
- name: 'description',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- id: {
- defaultValue: '',
- type: 'string',
- name: 'id',
- description: 'Provide label for NavigationList aria-labelledby',
- table: {
- category: 'HTML'
- }
- }
- }
-}
-
-export const NavigationListDividerTemplate = DividerTemplate.bind({})
-
-export const Playground = NavigationListDividerTemplate.bind({})
-Playground.args = {
- title: 'Section title',
- description: 'Section description'
-}
-Playground.decorators = [
- Story => (
-
-
-
- )
-]
diff --git a/docs/src/stories/components/NavigationList/NavigationListDividerFeatures.stories.jsx b/docs/src/stories/components/NavigationList/NavigationListDividerFeatures.stories.jsx
deleted file mode 100644
index f5495673c5..0000000000
--- a/docs/src/stories/components/NavigationList/NavigationListDividerFeatures.stories.jsx
+++ /dev/null
@@ -1,27 +0,0 @@
-import React from 'react'
-import {NavigationListTemplate} from './NavigationList.stories'
-import {
- PatternTitle,
- PatternFilled,
- PatternWithDescription,
- PatternSeparator
-} from '../../ui-patterns/ActionList/ActionListDividerFeatures.stories.jsx'
-
-export default {
- title: 'Components/NavigationList/NavigationListDivider/Features',
- decorators: [
- Story => (
-
-
-
- )
- ]
-}
-
-export const Title = ({}) =>
-
-export const Filled = ({}) =>
-
-export const WithDescription = ({}) =>
-
-export const Separator = ({}) =>
diff --git a/docs/src/stories/components/NavigationList/NavigationListExamples.stories.jsx b/docs/src/stories/components/NavigationList/NavigationListExamples.stories.jsx
deleted file mode 100644
index 2e1400729a..0000000000
--- a/docs/src/stories/components/NavigationList/NavigationListExamples.stories.jsx
+++ /dev/null
@@ -1,161 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import {NavigationListDividerTemplate} from './NavigationListDivider.stories'
-import {NavigationListItemTemplate} from './NavigationListItem.stories'
-import {NavigationListTemplate} from './NavigationList.stories'
-import {NavigationListItemCollapsibleTemplate} from './NavigationListItemCollapsible.stories'
-
-export default {
- title: 'Components/NavigationList/Examples'
-}
-
-export const RepoSettings = ({}) => (
-
-
- `}
- />
-
-
-
-
- `}
- />
- `}
- collapsePosition={1}
- containsSubItem
- containsActiveSubItem
- leadingVisualSize="ActionList-content--visual16"
- >
-
-
-
-
-
-
-
-
-
-
-
-
- `}
- />
- `}
- />
-
-
- `}
- />
-
-
- `}
- />
-
-
-
-
-)
-
-export const NavDiscussionsPane = NavigationListTemplate.bind({})
-NavDiscussionsPane.storyName = 'Discussions pane'
-NavDiscussionsPane.args = {
- ...NavigationListTemplate.args,
- ...NavigationListItemTemplate.args,
- ariaLabel: 'Discussion type navigation',
- showDividers: false,
- children: (
- <>
- `}
- />
-
-
-
-
-
-
-
- >
- )
-}
-NavDiscussionsPane.decorators = [
- Story => (
-
-
-
- )
-]
diff --git a/docs/src/stories/components/NavigationList/NavigationListFeatures.stories.jsx b/docs/src/stories/components/NavigationList/NavigationListFeatures.stories.jsx
deleted file mode 100644
index 95c325acc8..0000000000
--- a/docs/src/stories/components/NavigationList/NavigationListFeatures.stories.jsx
+++ /dev/null
@@ -1,19 +0,0 @@
-import React from 'react'
-import {
- PatternShowDividers,
- PatternInsetPadding,
- PatternFullBleed,
- PatternNestedGroup
-} from '../../ui-patterns/ActionList/ActionListFeatures.stories.jsx'
-
-export default {
- title: 'Components/NavigationList/NavigationList/Features'
-}
-
-export const ShowDividers = ({}) =>
-
-export const InsetPadding = ({}) =>
-
-export const FullBleed = ({}) =>
-
-export const NestedGroup = ({}) =>
diff --git a/docs/src/stories/components/NavigationList/NavigationListItem.stories.jsx b/docs/src/stories/components/NavigationList/NavigationListItem.stories.jsx
deleted file mode 100644
index b6933da9ca..0000000000
--- a/docs/src/stories/components/NavigationList/NavigationListItem.stories.jsx
+++ /dev/null
@@ -1,167 +0,0 @@
-import React from 'react'
-import {NavigationListTemplate} from './NavigationList.stories'
-import {ListItemTemplate} from '../../ui-patterns/ActionList/ActionListItem.stories.jsx'
-
-export default {
- title: 'Components/NavigationList/NavigationListItem',
- excludeStories: ['NavigationListItemTemplate'],
- argTypes: {
- size: {
- options: [0, 1, 2], // iterator
- mapping: ['', 'ActionList-content--sizeMedium', 'ActionList-content--sizeLarge'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'medium', 'large']
- },
- description: 'small (default), medium, large',
- defaultValue: '',
- table: {
- category: 'CSS'
- }
- },
- variant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-item--danger'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'danger']
- },
- defaultValue: '',
- table: {
- category: 'CSS'
- }
- },
- subItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- hasSubItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- truncateItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- leadingVisual: {
- defaultValue: '',
- name: 'leadingVisual',
- type: 'string',
- description: 'Paste [Octicon](https://primer.style/octicons/) in control field',
- table: {
- category: 'HTML'
- }
- },
- leadingVisualSize: {
- options: [0, 1, 2], // iterator
- mapping: ['ActionList-content--visual16', 'ActionList-content--visual20', 'ActionList-content--visual24'], // values
- control: {
- type: 'inline-radio',
- labels: ['16px', '20px', '24px']
- },
- description: 'leading visual width',
- defaultValue: 'ActionList-content--visual16',
- table: {
- category: 'CSS'
- }
- },
- trailingVisual: {
- defaultValue: '',
- name: 'trailingVisual',
- type: 'string',
- description: 'Paste [Octicon](https://primer.style/octicons/) in control field',
- table: {
- category: 'HTML'
- }
- },
- text: {
- defaultValue: 'Item label',
- type: 'string',
- name: 'text',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- href: {
- defaultValue: '',
- type: 'string',
- name: 'href',
- description: 'Item link (href)',
- table: {
- category: 'HTML'
- }
- },
- ariaCurrent: {
- options: ['location', 'page', null],
- control: {type: 'inline-radio'},
- description: 'location for anchor links, page for global page navigation',
- table: {
- category: 'HTML'
- }
- },
- description: {
- defaultValue: '',
- type: 'string',
- name: 'description',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- descriptionVariant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-item-descriptionWrap--inline'], // values
- control: {
- type: 'inline-radio',
- labels: ['block', 'inline']
- },
- description: 'block (default), inline',
- defaultValue: 'ActionList-item-blockDescription',
- table: {
- category: 'CSS'
- }
- },
- fontSize: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-content--fontSmall'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'small']
- },
- description: 'Used to adjust font-size for subgroup items',
- table: {
- category: 'CSS'
- }
- }
- }
-}
-
-export const NavigationListItemTemplate = ListItemTemplate.bind({})
-
-export const Playground = NavigationListItemTemplate.bind({})
-Playground.decorators = [
- Story => (
-
-
-
- )
-]
-Playground.args = {
- truncateItem: false,
- size: 0,
- variant: 0,
- descriptionVariant: 0,
- fontSize: 0,
- ariaCurrent: null,
- leadingVisualSize: 0
-}
diff --git a/docs/src/stories/components/NavigationList/NavigationListItemCollapsible.stories.jsx b/docs/src/stories/components/NavigationList/NavigationListItemCollapsible.stories.jsx
deleted file mode 100644
index da0aa2935b..0000000000
--- a/docs/src/stories/components/NavigationList/NavigationListItemCollapsible.stories.jsx
+++ /dev/null
@@ -1,155 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import useToggle from '../../helpers/useToggle.jsx'
-import {NavigationListTemplate} from './NavigationList.stories'
-import {ActionListItemCollapsibleTemplate} from '../../ui-patterns/ActionList/ActionListItemCollapsible.stories.jsx'
-
-export default {
- title: 'Components/NavigationList/NavigationListItemCollapsible',
- excludeStories: ['NavigationListItemCollapsibleTemplate'],
- argTypes: {
- size: {
- options: [0, 1, 2], // iterator
- mapping: ['', 'ActionList-content--sizeMedium', 'ActionList-content--sizeLarge'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'medium', 'large']
- },
- description: 'small (default), medium, large',
- defaultValue: '',
- table: {
- category: 'CSS'
- }
- },
- containsSubItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- truncateItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- containsActiveSubItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- leadingVisual: {
- defaultValue: '',
- name: 'leadingVisual',
- type: 'string',
- description: 'Paste [Octicon](https://primer.style/octicons/) in control field',
- table: {
- category: 'HTML'
- }
- },
- leadingVisualSize: {
- options: [0, 1, 2], // iterator
- mapping: ['ActionList-content--visual16', 'ActionList-content--visual20', 'ActionList-content--visual24'], // values
- control: {
- type: 'inline-radio',
- labels: ['16px', '20px', '24px']
- },
- description: 'leading visual width',
- defaultValue: 'ActionList-content--visual16',
- table: {
- category: 'CSS'
- }
- },
- trailingVisual: {
- defaultValue: '',
- name: 'trailingVisual',
- type: 'string',
- description: 'Paste [Octicon](https://primer.style/octicons/) in control field',
- table: {
- category: 'HTML'
- }
- },
- text: {
- defaultValue: 'Item label',
- type: 'string',
- name: 'text',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- description: {
- defaultValue: '',
- type: 'string',
- name: 'description',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- descriptionVariant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-item-descriptionWrap--inline'], // values
- control: {
- type: 'inline-radio',
- labels: ['block', 'inline']
- },
- description: 'block (default), inline',
- defaultValue: 'ActionList-item-blockDescription',
- table: {
- category: 'CSS'
- }
- },
- id: {
- defaultValue: '',
- type: 'string',
- name: 'id',
- description: 'Pass in ID of nested NavigationList',
- table: {
- category: 'HTML'
- }
- },
- ariaControlsId: {
- defaultValue: '',
- type: 'string',
- name: 'id',
- description: 'Pass in ID of nested NavigationList',
- table: {
- category: 'HTML'
- }
- },
- collapsePosition: {
- options: [0, 1], // iterator
- control: {
- type: 'inline-radio',
- labels: ['leading', 'trailing']
- },
- description: 'Handle collapse action visual position',
- table: {
- category: 'HTML'
- }
- }
- }
-}
-
-export const NavigationListItemCollapsibleTemplate = ActionListItemCollapsibleTemplate.bind({})
-
-export const Playground = NavigationListItemCollapsibleTemplate.bind({})
-Playground.decorators = [
- Story => (
-
-
-
- )
-]
-Playground.args = {
- truncateItem: false,
- size: 0,
- descriptionVariant: 0,
- leadingVisualSize: 0,
- collapsePosition: 0
-}
diff --git a/docs/src/stories/components/NavigationList/NavigationListItemCollapsibleFeatures.stories.jsx b/docs/src/stories/components/NavigationList/NavigationListItemCollapsibleFeatures.stories.jsx
deleted file mode 100644
index 014104deb6..0000000000
--- a/docs/src/stories/components/NavigationList/NavigationListItemCollapsibleFeatures.stories.jsx
+++ /dev/null
@@ -1,69 +0,0 @@
-import React from 'react'
-import {NavigationListTemplate} from './NavigationList.stories'
-import {
- PatternTrailingCollapsible,
- PatternTrailingCollapsibleLeadingVis,
- PatternTrailingCollapsibleLeadingTrailingVis,
- PatternTrailingCollapsibleTrailingVis,
- PatternLeadingCollapsible,
- PatternLeadingCollapsibleLeadingVis,
- PatternLeadingCollapsibleLeadingTrailingVis,
- PatternLeadingCollapsibleTrailingVis,
- PatternSizeMedium,
- PatternSizeLarge,
- PatternContainsSubItem,
- PatternContainsActiveSubItem,
- PatternTruncateText,
- PatternWrapText
-} from '../../ui-patterns/ActionList/ActionListItemCollapsibleFeatures.stories.jsx'
-
-export default {
- title: 'Components/NavigationList/NavigationListItemCollapsible/Features',
- decorators: [
- Story => (
-
-
-
- )
- ]
-}
-
-export const TrailingCollapsible = ({}) =>
-
-export const TrailingCollapsibleLeadingVis = ({}) => (
-
-)
-
-export const TrailingCollapsibleLeadingTrailingVis = ({}) => (
-
-)
-
-export const TrailingCollapsibleTrailingVis = ({}) => (
-
-)
-
-export const LeadingCollapsible = ({}) =>
-
-export const LeadingCollapsibleLeadingVis = ({}) => (
-
-)
-
-export const LeadingCollapsibleLeadingTrailingVis = ({}) => (
-
-)
-
-export const LeadingCollapsibleTrailingVis = ({}) => (
-
-)
-
-export const SizeMedium = ({}) =>
-
-export const SizeLarge = ({}) =>
-
-export const ContainsSubItem = ({}) =>
-
-export const ContainsActiveSubItem = ({}) =>
-
-export const TruncateText = ({}) =>
-
-export const WrapText = ({}) =>
diff --git a/docs/src/stories/components/NavigationList/NavigationListItemFeatures.stories.jsx b/docs/src/stories/components/NavigationList/NavigationListItemFeatures.stories.jsx
deleted file mode 100644
index c303f6d7a6..0000000000
--- a/docs/src/stories/components/NavigationList/NavigationListItemFeatures.stories.jsx
+++ /dev/null
@@ -1,98 +0,0 @@
-import React from 'react'
-import {NavigationListTemplate} from './NavigationList.stories'
-import {
- PatternTextOnly,
- PatternSizeMedium,
- PatternSizeMediumWithDescription,
- PatternSizeLarge,
- PatternSizeLargeWithDescription,
- PatternVisualLeading,
- PatternVisualTrailing,
- PatternVisualTrailingText,
- PatternVisualLeadingAndTrailing,
- PatternDescriptionBlock,
- PatternDescriptionBlockWithLeadingVisual,
- PatternDescriptionBlockWithTrailingVisual,
- PatternDescriptionBlockWithLeadingAndTrailingVisual,
- PatternDescriptionInline,
- PatternDescriptionInlineWithLeadingVisual,
- PatternDescriptionInlineWithTrailingVisual,
- PatternDescriptionInlineWithLeadingAndTrailingVisual,
- PatternNavActiveAnchor,
- PatternNavActivePage,
- PatternTruncateText,
- PatternWrapText
-} from '../../ui-patterns/ActionList/ActionListItemFeatures.stories.jsx'
-
-export default {
- title: 'Components/NavigationList/NavigationListItem/Features',
- decorators: [
- Story => (
-
-
-
- )
- ]
-}
-
-export const TextOnly = ({}) =>
-
-export const SizeMedium = ({}) =>
-
-export const SizeMediumWithDescription = ({}) => (
-
-)
-
-export const SizeLarge = ({}) =>
-
-export const SizeLargeWithDescription = ({}) => (
-
-)
-
-export const VisualLeading = ({}) =>
-
-export const VisualTrailing = ({}) =>
-
-export const VisualTrailingText = ({}) =>
-
-export const VisualLeadingAndTrailing = ({}) => (
-
-)
-
-export const DescriptionBlock = ({}) =>
-
-export const DescriptionBlockWithLeadingVisual = ({}) => (
-
-)
-
-export const DescriptionBlockWithTrailingVisual = ({}) => (
-
-)
-
-export const DescriptionBlockWithLeadingAndTrailingVisual = ({}) => (
-
-)
-
-export const DescriptionInline = ({}) =>
-
-export const DescriptionInlineWithLeadingVisual = ({}) => (
-
-)
-
-export const DescriptionInlineWithTrailingVisual = ({}) => (
-
-)
-
-export const DescriptionInlineWithLeadingAndTrailingVisual = ({}) => (
-
-)
-
-export const NavActiveAnchor = ({}) =>
-
-export const NavActivePage = ({}) =>
-
-export const TruncateText = ({}) =>
-
-export const WrapText = ({}) =>
diff --git a/docs/src/stories/components/TreeView/TreeView.stories.jsx b/docs/src/stories/components/TreeView/TreeView.stories.jsx
deleted file mode 100644
index c83561fb8f..0000000000
--- a/docs/src/stories/components/TreeView/TreeView.stories.jsx
+++ /dev/null
@@ -1,49 +0,0 @@
-import React from 'react'
-import {ActionListTreeViewTemplate} from '../../ui-patterns/ActionList/ActionListTree.stories.jsx'
-
-export default {
- title: 'Components/TreeView/TreeView',
- excludeStories: ['TreeViewTemplate'],
- layout: 'padded',
- argTypes: {
- showGroupIcon: {
- control: {type: 'boolean'},
- description: 'show subgroup leading icon',
- table: {
- category: 'Interactive'
- }
- },
- showSubItemIcon: {
- control: {type: 'boolean'},
- description: 'show subgroup item leading icon',
- table: {
- category: 'Interactive'
- }
- },
- text: {
- defaultValue: '',
- type: 'string',
- name: 'title',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- truncateItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- }
- }
-}
-
-export const TreeViewTemplate = ActionListTreeViewTemplate.bind({})
-
-export const Playground = TreeViewTemplate.bind({})
-Playground.args = {
- showSubItemIcon: true,
- showGroupIcon: true,
- text: 'item'
-}
diff --git a/docs/src/stories/ui-patterns/ActionList/API.stories.mdx b/docs/src/stories/ui-patterns/ActionList/API.stories.mdx
deleted file mode 100644
index e300a0b283..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/API.stories.mdx
+++ /dev/null
@@ -1,111 +0,0 @@
-import {Meta, Story, Canvas} from '@storybook/addon-docs'
-
-
-
-### Action list
-
-`ActionList` CSS is primarily used as the building blocks for compositional components, such as NavigationList. Below is an overview of how the markup may look for specific kinds of implementations and contexts.
-
-An action list is a vertical list of interactive actions or options .
-
-| Term | Context |
-| :------ | :------------------------------------ |
-| Actions | links `a href` or events `onclick` |
-| Options | checkbox role `checked` or `selected` |
-
-### Semantic markup
-
-The markup for Action list changes depending on the intended use case.
-
-In all cases, the basic structure is as follows:
-
-```html
-
-```
-
-### Menu
-
-[Menu spec](https://www.w3.org/TR/wai-aria-practices-1.2/examples/menu-button/menu-button-links.html)
-
-The `menu` role should be reserved for menu scenarios
-
-| Element | Role |
-| :------ | :------------------------------ |
-| `ul` | `role="menu"` |
-| `li` | no child link `role="menuitem"` |
-| `li` | has child link `role="none"` |
-| `a` | `role="menuitem"` |
-
-### Navigational list of links
-
-[Navigation spec](https://www.w3.org/TR/wai-aria-practices-1.2/examples/landmarks/navigation.html)
-
-Wrap `ActionList` in a `nav` element for site or page navigation, like a sidebar
-
-| Element | Role |
-| :------ | :------------ |
-| `ul` | `role="list"` |
-| `li` | no role |
-| `li` | no role |
-| `a` | no role |
-
-### Multi select menu
-
-[Menu spec](https://www.w3.org/TR/wai-aria-practices-1.2/examples/menubar/menubar-2/menubar-2.html)
-
-| Element | Role |
-| :------ | :-------------------------- |
-| `ul` | `role="menu"` |
-| `li` | `role="menuitemcheckbox"` |
-| `li` | `aria-checked="true/false"` |
-
-### Single select menu
-
-[Menu spec](https://www.w3.org/TR/wai-aria-practices-1.2/examples/menubar/menubar-2/menubar-2.html)
-
-| Element | Role |
-| :------ | :-------------------------- |
-| `ul` | `role="menu"` |
-| `li` | `role="menuitemradio"` |
-| `li` | `aria-checked="true/false"` |
-
-### Multi select listbox
-
-[Listbox spec](https://www.w3.org/TR/wai-aria-practices-1.2/examples/listbox/listbox-collapsible.html)
-
-| Element | Role |
-| :------ | :---------------------------- |
-| `ul` | `role="listbox"` |
-| `ul` | `aria-multiselectable="true"` |
-| `li` | `role="option"` |
-| `li` | `aria-selected="true/false"` |
-
-### Single select listbox
-
-[Listbox spec](https://www.w3.org/TR/wai-aria-practices-1.2/examples/listbox/listbox-collapsible.html)
-
-Note: JS is required for to provide [keyboard handling](https://www.w3.org/TR/wai-aria-practices-1.1/#listbox_kbd_interaction)
-
-| Element | Role |
-| :------ | :--------------------------- |
-| `ul` | `role="listbox"` |
-| `li` | `role="option"` |
-| `li` | `aria-selected="true/false"` |
-
-### Dividers
-
-| Element | Role |
-| :------ | :-------------------------------------- |
-| `li` | `role="separator"` `aria-hidden="true"` |
-
-| Element | Role |
-| :------ | :--- |
-| `h3` | id |
diff --git a/docs/src/stories/ui-patterns/ActionList/ActionList.stories.jsx b/docs/src/stories/ui-patterns/ActionList/ActionList.stories.jsx
deleted file mode 100644
index 163fc4276f..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/ActionList.stories.jsx
+++ /dev/null
@@ -1,136 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import {ListItemTemplate} from './ActionListItem.stories'
-
-export default {
- title: 'UI Patterns/ActionList/ActionList',
- excludeStories: ['ListTemplate'],
- argTypes: {
- showDividers: {
- control: {type: 'boolean'},
- description: 'Show dividers between items',
- table: {
- category: 'CSS'
- }
- },
- role: {
- options: [null, 'menu', 'group', 'listbox', 'menubar', 'none', 'radiogroup', 'list'],
- control: {
- type: 'inline-radio'
- },
- description: 'Semantic list role',
- table: {
- category: 'HTML'
- }
- },
- variant: {
- options: [0, 1], // iterator
- mapping: [null, 'ActionList--tree'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'tree-view']
- },
- description: 'Specifies variants for different types of lists',
- table: {
- category: 'CSS'
- }
- },
- ariaLabel: {
- name: 'ariaLabel',
- type: 'string',
- description: 'Descriptive label for menu contents',
- table: {
- category: 'HTML'
- }
- },
- ariaLabelledBy: {
- name: 'ariaLabelledBy',
- type: 'string',
- description: 'Reference ID of NavigationListDivider',
- table: {
- category: 'HTML'
- }
- },
- listboxMultiSelect: {
- name: 'listboxMultiSelect',
- type: 'boolean',
- description: 'If ActionList has listbox role + multiselect children',
- table: {
- category: 'HTML'
- }
- },
- listPadding: {
- options: [0, 1], // iterator
- mapping: [null, 'ActionList--full'], // values
- control: {
- type: 'inline-radio',
- labels: ['inset', 'full-bleed']
- },
- description: 'ActionList includes 8px padding by default, full-bleed removes all padding',
- table: {
- category: 'CSS'
- }
- },
- listType: {
- options: [0, 1], // iterator
- mapping: ['parent', 'nested'], // values
- control: {
- type: 'inline-radio',
- labels: ['parent', 'nested']
- },
- description: 'NavigationList can be a parent list with a or a nested list with just ',
- table: {
- category: 'CSS'
- }
- },
- children: {
- table: {
- disable: true
- }
- }
- }
-}
-
-export const ListTemplate = ({
- showDividers,
- children,
- role,
- ariaLabel,
- ariaLabelledBy,
- listboxMultiSelect,
- listPadding,
- variant,
- listType
-}) => (
-
-)
-
-export const Playground = ListTemplate.bind({})
-Playground.args = {
- listType: 'parent',
- showDividers: false,
- listboxMultiSelect: false,
- listPadding: 0,
- variant: 0,
- role: 'list',
- children: (
- <>
-
-
- >
- )
-}
diff --git a/docs/src/stories/ui-patterns/ActionList/ActionListDivider.stories.jsx b/docs/src/stories/ui-patterns/ActionList/ActionListDivider.stories.jsx
deleted file mode 100644
index dca279e02d..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/ActionListDivider.stories.jsx
+++ /dev/null
@@ -1,86 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import {ListTemplate} from './ActionList.stories'
-
-export default {
- title: 'UI Patterns/ActionList/ActionListDivider',
- excludeStories: ['DividerTemplate'],
- argTypes: {
- variant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-sectionDivider--filled'], // values
- control: {
- type: 'inline-radio',
- labels: ['subtle', 'filled']
- },
- table: {
- category: 'CSS'
- }
- },
- title: {
- defaultValue: '',
- type: 'string',
- name: 'title',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- description: {
- defaultValue: '',
- type: 'string',
- name: 'description',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- id: {
- defaultValue: '',
- type: 'string',
- name: 'id',
- description: 'Provide label for NavigationList aria-labelledby',
- table: {
- category: 'HTML'
- }
- }
- },
- decorators: [
- Story => (
-
- )
- ]
-}
-
-export const DividerTemplate = ({title, description, variant, id}) => (
- <>
-
- {title && (
-
- {title}
-
- )}
- {description && {description} }
-
- >
-)
-
-export const Playground = DividerTemplate.bind({})
-Playground.args = {
- title: 'Section title',
- description: 'Section description',
- variant: 'subtle'
-}
-Playground.decorators = [
- Story => (
-
-
-
- )
-]
diff --git a/docs/src/stories/ui-patterns/ActionList/ActionListDividerFeatures.stories.jsx b/docs/src/stories/ui-patterns/ActionList/ActionListDividerFeatures.stories.jsx
deleted file mode 100644
index 8c8af1a7e7..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/ActionListDividerFeatures.stories.jsx
+++ /dev/null
@@ -1,36 +0,0 @@
-import React from 'react'
-import {ListTemplate} from './ActionList.stories'
-import {DividerTemplate} from './ActionListDivider.stories'
-
-export default {
- title: 'UI Patterns/ActionList/ActionListDivider/Features',
- decorators: [
- Story => (
-
-
-
- )
- ]
-}
-
-export const PatternTitle = DividerTemplate.bind({})
-PatternTitle.storyName = 'Title'
-PatternTitle.args = {
- title: 'List group title'
-}
-
-export const PatternFilled = DividerTemplate.bind({})
-PatternFilled.storyName = 'Filled'
-PatternFilled.args = {
- variant: 'ActionList-sectionDivider--filled'
-}
-
-export const PatternWithDescription = DividerTemplate.bind({})
-PatternWithDescription.storyName = 'With description'
-PatternWithDescription.args = {
- title: 'List group title',
- description: 'Group description'
-}
-
-export const PatternSeparator = DividerTemplate.bind({})
-PatternSeparator.storyName = 'Separator'
diff --git a/docs/src/stories/ui-patterns/ActionList/ActionListFeatures.stories.jsx b/docs/src/stories/ui-patterns/ActionList/ActionListFeatures.stories.jsx
deleted file mode 100644
index 46a4097f36..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/ActionListFeatures.stories.jsx
+++ /dev/null
@@ -1,60 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import {ListTemplate} from './ActionList.stories'
-import {ListItemTemplate} from './ActionListItem.stories'
-
-export default {
- title: 'UI Patterns/ActionList/ActionList/Features'
-}
-
-export const PatternShowDividers = ListTemplate.bind({})
-PatternShowDividers.storyName = 'Show dividers'
-PatternShowDividers.args = {
- showDividers: true,
- children: (
- <>
-
-
-
- >
- )
-}
-
-export const PatternInsetPadding = ListTemplate.bind({})
-PatternInsetPadding.storyName = 'Inset padding'
-PatternInsetPadding.args = {
- listPadding: null,
- children: (
- <>
-
-
-
- >
- )
-}
-
-export const PatternFullBleed = ListTemplate.bind({})
-PatternFullBleed.storyName = 'Full bleed'
-PatternFullBleed.args = {
- listPadding: 'ActionList--full',
- children: (
- <>
-
-
-
- >
- )
-}
-
-export const PatternNestedGroup = ListTemplate.bind({})
-PatternNestedGroup.storyName = 'Nested group'
-PatternNestedGroup.args = {
- listType: 'nested',
- children: (
- <>
-
-
-
- >
- )
-}
diff --git a/docs/src/stories/ui-patterns/ActionList/ActionListItem.stories.jsx b/docs/src/stories/ui-patterns/ActionList/ActionListItem.stories.jsx
deleted file mode 100644
index ce8814f7d1..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/ActionListItem.stories.jsx
+++ /dev/null
@@ -1,478 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import useToggle from '../../helpers/useToggle.jsx'
-import {ListTemplate} from './ActionList.stories.jsx'
-
-export default {
- title: 'UI Patterns/ActionList/ActionListItem',
- excludeStories: ['ListItemTemplate'],
- argTypes: {
- size: {
- options: [0, 1, 2], // iterator
- mapping: ['', 'ActionList-content--sizeMedium', 'ActionList-content--sizeLarge'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'medium', 'large']
- },
- description: 'small (default), medium, large',
- defaultValue: '',
- table: {
- category: 'CSS'
- }
- },
- variant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-item--danger'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'danger']
- },
- defaultValue: '',
- table: {
- category: 'CSS'
- }
- },
- subItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- hasSubItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- truncateItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- leadingVisual: {
- defaultValue: '',
- name: 'leadingVisual',
- type: 'string',
- description: 'Paste [Octicon](https://primer.style/octicons/) in control field',
- table: {
- category: 'HTML'
- }
- },
- leadingVisualSize: {
- options: [0, 1, 2], // iterator
- mapping: ['ActionList-content--visual16', 'ActionList-content--visual20', 'ActionList-content--visual24'], // values
- control: {
- type: 'inline-radio',
- labels: ['16px', '20px', '24px']
- },
- description: 'leading visual width',
- defaultValue: 'ActionList-content--visual16',
- table: {
- category: 'CSS'
- }
- },
- trailingVisual: {
- defaultValue: '',
- name: 'trailingVisual',
- type: 'string',
- description: 'Paste [Octicon](https://primer.style/octicons/) in control field',
- table: {
- category: 'HTML'
- }
- },
- text: {
- defaultValue: 'Item label',
- type: 'string',
- name: 'text',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- href: {
- defaultValue: '',
- type: 'string',
- name: 'href',
- description: 'Item link (href)',
- table: {
- category: 'HTML'
- }
- },
- ariaCurrent: {
- options: ['location', 'page'],
- control: {type: 'inline-radio'},
- description: 'location for anchor links, page for global page navigation',
- table: {
- category: 'HTML'
- }
- },
- description: {
- defaultValue: '',
- type: 'string',
- name: 'description',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- descriptionVariant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-item-descriptionWrap--inline'], // values
- control: {
- type: 'inline-radio',
- labels: ['block', 'inline']
- },
- description: 'block (default), inline',
- defaultValue: 'ActionList-item-blockDescription',
- table: {
- category: 'CSS'
- }
- },
- singleSelect: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'Interactive'
- }
- },
- multiSelect: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'Interactive'
- }
- },
- listSingleSelect: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'Interactive'
- }
- },
- listMultiSelect: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'Interactive'
- }
- },
- treeitem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'HTML'
- }
- },
- treeItemSingleton: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- ariaDisabled: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'Interactive'
- }
- },
- ariaLevel: {
- name: 'ariaLevel',
- type: 'string',
- description: 'number - nested subgroup',
- table: {
- category: 'HTML'
- }
- },
- ariaSetSize: {
- name: 'ariaSetSize',
- type: 'string',
- description:
- 'Defines the number of treeitem elements in the set of treeitem elements that are in the same branch and at the same level within the hierarchy',
- table: {
- category: 'HTML'
- }
- },
- ariaPosInset: {
- name: 'ariaPosInset',
- type: 'string',
- description:
- 'Defines the position of the element within the set of other treeitem elements that are in the same branch and at the same level within the hierarchy.',
- table: {
- category: 'HTML'
- }
- },
- fontSize: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-content--fontSmall'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'small']
- },
- description: 'Used to adjust font-size for subgroup items',
- table: {
- category: 'CSS'
- }
- }
- }
-}
-
-export const ListItemTemplate = ({
- text,
- size,
- leadingVisual,
- leadingVisualSize,
- trailingVisual,
- description,
- descriptionVariant,
- variant,
- href,
- ariaCurrent,
- children,
- subItem,
- hasSubItem,
- trailingAction,
- leadingAction,
- singleSelect,
- multiSelect,
- listSingleSelect,
- listMultiSelect,
- listSemantic,
- ariaDisabled,
- truncateItem,
- ariaLevel,
- fontSize,
- treeitem,
- ariaSetSize,
- ariaPosInset,
- menuItem,
- treeItemSingleton
-}) => {
- const [isChecked, itemIsChecked] = useToggle()
- const itemStyle = {
- '--ActionList-tree-depth': `${ariaLevel}`
- }
- return (
-
- {href ? (
- <>
-
- {(leadingAction || singleSelect || multiSelect || listSingleSelect || listMultiSelect) && (
-
- {singleSelect ||
- (listSingleSelect && (
-
-
-
- ))}
- {multiSelect ||
- (listMultiSelect && (
-
-
-
-
- ))}
- {leadingAction}
-
- )}
- {leadingVisual && (
-
- )}
- {description && (
-
-
- {text}
-
- {description}
-
- )}
- {!description && text && (
-
- {text}
-
- )}
- {trailingVisual && (
-
- )}
- {trailingAction && (
- {trailingAction}
- )}
-
- {children}
- >
- ) : (
- <>
- {text && (
-
- {(leadingAction || singleSelect || multiSelect || listSingleSelect || listMultiSelect) && (
-
- {(singleSelect || listSingleSelect) && (
-
-
-
- )}
- {(multiSelect || listMultiSelect) && (
-
-
-
-
- )}
- {leadingAction}
-
- )}
- {leadingVisual && (
-
- )}
- {description && (
-
-
- {text}
-
- {description}
-
- )}
- {!description && text && (
-
- {text}
-
- )}
-
- {trailingVisual && (
-
- )}
- {trailingAction && (
- {trailingAction}
- )}
-
- )}
- {children}
- >
- )}
-
- )
-}
-
-export const Playground = ListItemTemplate.bind({})
-Playground.decorators = [
- Story => (
-
-
-
- )
-]
-Playground.args = {
- truncateItem: false,
- treeItemSingleton: false
-}
diff --git a/docs/src/stories/ui-patterns/ActionList/ActionListItemCollapsible.stories.jsx b/docs/src/stories/ui-patterns/ActionList/ActionListItemCollapsible.stories.jsx
deleted file mode 100644
index 5cae4ea473..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/ActionListItemCollapsible.stories.jsx
+++ /dev/null
@@ -1,261 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import useToggle from '../../helpers/useToggle.jsx'
-import {ListTemplate} from './ActionList.stories'
-
-export default {
- title: 'UI Patterns/ActionList/ActionListItemCollapsible',
- excludeStories: ['ActionListItemCollapsibleTemplate'],
- argTypes: {
- size: {
- options: [0, 1, 2], // iterator
- mapping: ['', 'ActionList-content--sizeMedium', 'ActionList-content--sizeLarge'], // values
- control: {
- type: 'inline-radio',
- labels: ['default', 'medium', 'large']
- },
- description: 'small (default), medium, large',
- defaultValue: '',
- table: {
- category: 'CSS'
- }
- },
- containsSubItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- truncateItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- containsActiveSubItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- },
- leadingVisual: {
- defaultValue: '',
- name: 'leadingVisual',
- type: 'string',
- description: 'Paste [Octicon](https://primer.style/octicons/) in control field',
- table: {
- category: 'HTML'
- }
- },
- leadingVisualSize: {
- options: [0, 1, 2], // iterator
- mapping: ['ActionList-content--visual16', 'ActionList-content--visual20', 'ActionList-content--visual24'], // values
- control: {
- type: 'inline-radio',
- labels: ['16px', '20px', '24px']
- },
- description: 'leading visual width',
- defaultValue: 'ActionList-content--visual16',
- table: {
- category: 'CSS'
- }
- },
- trailingVisual: {
- defaultValue: '',
- name: 'trailingVisual',
- type: 'string',
- description: 'Paste [Octicon](https://primer.style/octicons/) in control field',
- table: {
- category: 'HTML'
- }
- },
- text: {
- defaultValue: 'Item label',
- type: 'string',
- name: 'text',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- description: {
- defaultValue: '',
- type: 'string',
- name: 'description',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- descriptionVariant: {
- options: [0, 1], // iterator
- mapping: ['', 'ActionList-item-descriptionWrap--inline'], // values
- control: {
- type: 'inline-radio',
- labels: ['block', 'inline']
- },
- description: 'block (default), inline',
- defaultValue: 'ActionList-item-blockDescription',
- table: {
- category: 'CSS'
- }
- },
- id: {
- defaultValue: '',
- type: 'string',
- name: 'id',
- description: 'Pass in ID of nested NavigationList',
- table: {
- category: 'HTML'
- }
- },
- ariaControlsId: {
- defaultValue: '',
- type: 'string',
- name: 'id',
- description: 'Pass in ID of nested NavigationList',
- table: {
- category: 'HTML'
- }
- },
- collapsePosition: {
- options: [0, 1], // iterator
- control: {
- type: 'inline-radio',
- labels: ['leading', 'trailing']
- },
- description: 'Handle collapse action visual position',
- table: {
- category: 'HTML'
- }
- },
- ariaLevel: {
- name: 'ariaLevel',
- type: 'string',
- description: 'number - nested subgroup',
- table: {
- category: 'HTML'
- }
- }
- }
-}
-
-export const ActionListItemCollapsibleTemplate = ({
- text,
- size,
- leadingVisual,
- leadingVisualSize,
- trailingVisual,
- description,
- descriptionVariant,
- children,
- containsSubItem,
- id,
- containsActiveSubItem,
- truncateItem,
- collapsePosition,
- ariaControlsId,
- ariaLevel
-}) => {
- const [isCollapsed, itemIsCollapsed] = useToggle()
- const itemStyle = {
- '--ActionList-tree-depth': `${ariaLevel}`
- }
- return (
-
-
- {collapsePosition === 0 && (
-
-
-
-
-
- )}
- {leadingVisual && (
-
- )}
- {description && (
-
-
- {text}
-
- {description}
-
- )}
- {!description && text && (
-
- {text}
-
- )}
- {trailingVisual && (
-
- )}
- {collapsePosition === 1 && (
-
-
-
-
-
- )}
-
- {children}
-
- )
-}
-
-export const Playground = ActionListItemCollapsibleTemplate.bind({})
-Playground.decorators = [
- Story => (
-
-
-
- )
-]
-Playground.args = {
- id: null,
- truncateItem: false
-}
diff --git a/docs/src/stories/ui-patterns/ActionList/ActionListItemCollapsibleFeatures.stories.jsx b/docs/src/stories/ui-patterns/ActionList/ActionListItemCollapsibleFeatures.stories.jsx
deleted file mode 100644
index ea8ab19604..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/ActionListItemCollapsibleFeatures.stories.jsx
+++ /dev/null
@@ -1,158 +0,0 @@
-import React from 'react'
-import clsx from 'clsx'
-import {ActionListItemCollapsibleTemplate} from './ActionListItemCollapsible.stories'
-import {ListTemplate} from './ActionList.stories'
-
-export default {
- title: 'UI Patterns/ActionList/ActionListItemCollapsible/Features',
- decorators: [
- Story => (
-
-
-
- )
- ]
-}
-
-const leadingVisual = `
-
- `
-
-const trailingVisual = `
-
- `
-
-export const PatternTrailingCollapsible = ActionListItemCollapsibleTemplate.bind({})
-PatternTrailingCollapsible.storyName = '[Trailing] Text only'
-PatternTrailingCollapsible.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'Collapsible',
- collapsePosition: 1
-}
-
-export const PatternTrailingCollapsibleLeadingVis = ActionListItemCollapsibleTemplate.bind({})
-PatternTrailingCollapsibleLeadingVis.storyName = '[Trailing] Leading visual'
-PatternTrailingCollapsibleLeadingVis.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'Collapsible',
- collapsePosition: 1,
- leadingVisual: leadingVisual
-}
-
-export const PatternTrailingCollapsibleLeadingTrailingVis = ActionListItemCollapsibleTemplate.bind({})
-PatternTrailingCollapsibleLeadingTrailingVis.storyName = '[Trailing] Leading + trailing visual'
-PatternTrailingCollapsibleLeadingTrailingVis.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'Collapsible',
- collapsePosition: 1,
- leadingVisual: leadingVisual,
- trailingVisual: trailingVisual
-}
-
-export const PatternTrailingCollapsibleTrailingVis = ActionListItemCollapsibleTemplate.bind({})
-PatternTrailingCollapsibleTrailingVis.storyName = '[Trailing] Trailing visual'
-PatternTrailingCollapsibleTrailingVis.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'Collapsible',
- collapsePosition: 1,
- trailingVisual: trailingVisual
-}
-
-export const PatternLeadingCollapsible = ActionListItemCollapsibleTemplate.bind({})
-PatternLeadingCollapsible.storyName = '[Leading] Text only'
-PatternLeadingCollapsible.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'Collapsible',
- collapsePosition: 0
-}
-
-export const PatternLeadingCollapsibleLeadingVis = ActionListItemCollapsibleTemplate.bind({})
-PatternLeadingCollapsibleLeadingVis.storyName = '[Leading] Leading visual'
-PatternLeadingCollapsibleLeadingVis.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'Collapsible',
- collapsePosition: 0,
- leadingVisual: leadingVisual
-}
-
-export const PatternLeadingCollapsibleLeadingTrailingVis = ActionListItemCollapsibleTemplate.bind({})
-PatternLeadingCollapsibleLeadingTrailingVis.storyName = '[Leading] Leading + trailing visual'
-PatternLeadingCollapsibleLeadingTrailingVis.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'Collapsible',
- collapsePosition: 0,
- leadingVisual: leadingVisual,
- trailingVisual: trailingVisual
-}
-
-export const PatternLeadingCollapsibleTrailingVis = ActionListItemCollapsibleTemplate.bind({})
-PatternLeadingCollapsibleTrailingVis.storyName = '[Leading] Trailing visual'
-PatternLeadingCollapsibleTrailingVis.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'Collapsible',
- collapsePosition: 0,
- trailingVisual: trailingVisual
-}
-
-export const PatternSizeMedium = ActionListItemCollapsibleTemplate.bind({})
-PatternSizeMedium.storyName = '[Size] Medium'
-PatternSizeMedium.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'Medium item',
- size: 'ActionList-content--sizeMedium',
- collapsePosition: 1
-}
-
-export const PatternSizeLarge = ActionListItemCollapsibleTemplate.bind({})
-PatternSizeLarge.storyName = '[Size] Large'
-PatternSizeLarge.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'Large item',
- size: 'ActionList-content--sizeLarge',
- collapsePosition: 1
-}
-
-export const PatternContainsSubItem = ActionListItemCollapsibleTemplate.bind({})
-PatternContainsSubItem.storyName = 'Has sub item (render css class)'
-PatternContainsSubItem.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'I am collapsible',
- collapsePosition: 1,
- containsSubItem: true
-}
-
-export const PatternContainsActiveSubItem = ActionListItemCollapsibleTemplate.bind({})
-PatternContainsActiveSubItem.storyName = 'Has active sub item'
-PatternContainsActiveSubItem.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'I have an active child',
- collapsePosition: 1,
- containsActiveSubItem: true
-}
-
-export const PatternTruncateText = ActionListItemCollapsibleTemplate.bind({})
-PatternTruncateText.storyName = 'Truncate text'
-PatternTruncateText.args = {
- ...ActionListItemCollapsibleTemplate.args,
- truncateItem: true,
- text: 'This is a very long string of text that will wrap to another line on smaller screens',
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual,
- collapsePosition: 1
-}
-
-export const PatternWrapText = ActionListItemCollapsibleTemplate.bind({})
-PatternWrapText.storyName = 'Wrap text'
-PatternWrapText.args = {
- ...ActionListItemCollapsibleTemplate.args,
- text: 'This is a very long string of text that will wrap to another line on smaller screens',
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual,
- collapsePosition: 1
-}
diff --git a/docs/src/stories/ui-patterns/ActionList/ActionListItemFeatures.stories.jsx b/docs/src/stories/ui-patterns/ActionList/ActionListItemFeatures.stories.jsx
deleted file mode 100644
index 51ba0ba329..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/ActionListItemFeatures.stories.jsx
+++ /dev/null
@@ -1,356 +0,0 @@
-import React from 'react'
-import {ListItemTemplate} from './ActionListItem.stories'
-import {ListTemplate} from './ActionList.stories'
-
-export default {
- title: 'UI Patterns/ActionList/ActionListItem/Features',
- decorators: [
- Story => (
-
-
-
- )
- ]
-}
-
-const leadingVisual = `
-
- `
-
-const trailingVisual = `
-
- `
-
-export const PatternTextOnly = ListItemTemplate.bind({})
-PatternTextOnly.storyName = 'Text only'
-PatternTextOnly.args = {
- text: 'Basic item label'
-}
-
-export const PatternSizeMedium = ListItemTemplate.bind({})
-PatternSizeMedium.storyName = '[Size] Medium'
-PatternSizeMedium.args = {
- ...ListItemTemplate.args,
- text: 'Medium item',
- size: 'ActionList-content--sizeMedium'
-}
-
-export const PatternSizeMediumWithDescription = ListItemTemplate.bind({})
-PatternSizeMediumWithDescription.storyName = '[Size] Medium with description'
-PatternSizeMediumWithDescription.args = {
- ...ListItemTemplate.args,
- text: 'Medium item',
- description: 'Some descriptive text',
- size: 'ActionList-content--sizeMedium'
-}
-
-export const PatternSizeLarge = ListItemTemplate.bind({})
-PatternSizeLarge.storyName = '[Size] Large'
-PatternSizeLarge.args = {
- ...ListItemTemplate.args,
- text: 'Large item',
- size: 'ActionList-content--sizeLarge'
-}
-
-export const PatternSizeLargeWithDescription = ListItemTemplate.bind({})
-PatternSizeLargeWithDescription.storyName = '[Size] Large with description'
-PatternSizeLargeWithDescription.args = {
- ...ListItemTemplate.args,
- text: 'Large item',
- description: 'Some descriptive text',
- size: 'ActionList-content--sizeLarge'
-}
-
-export const PatternVisualLeading = ListItemTemplate.bind({})
-PatternVisualLeading.storyName = '[Visuals] Leading'
-PatternVisualLeading.args = {
- ...ListItemTemplate.args,
- text: 'Item with leading visual',
- leadingVisual: leadingVisual
-}
-
-export const PatternVisualTrailing = ListItemTemplate.bind({})
-PatternVisualTrailing.storyName = '[Visuals] Trailing'
-PatternVisualTrailing.args = {
- ...ListItemTemplate.args,
- text: 'Item with trailing visual',
- trailingVisual: trailingVisual
-}
-
-export const PatternVisualTrailingText = ListItemTemplate.bind({})
-PatternVisualTrailingText.storyName = '[Visuals] Trailing text'
-PatternVisualTrailingText.args = {
- ...ListItemTemplate.args,
- text: 'Item with trailing text',
- trailingVisual: `⌘N`
-}
-
-export const PatternVisualLeadingAndTrailing = ListItemTemplate.bind({})
-PatternVisualLeadingAndTrailing.storyName = '[Visuals] Leading & trailing'
-PatternVisualLeadingAndTrailing.args = {
- ...ListItemTemplate.args,
- text: 'Item with trailing visual',
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual
-}
-
-export const PatternDescriptionBlock = ListItemTemplate.bind({})
-PatternDescriptionBlock.storyName = '[Description] block'
-PatternDescriptionBlock.args = {
- ...ListItemTemplate.args,
- text: 'Item label',
- description: 'This is a description',
- descriptionVariant: 'ActionList-item-blockDescription'
-}
-
-export const PatternDescriptionBlockWithLeadingVisual = ListItemTemplate.bind({})
-PatternDescriptionBlockWithLeadingVisual.storyName = '[Description] block + leading visual'
-PatternDescriptionBlockWithLeadingVisual.args = {
- ...ListItemTemplate.args,
- text: 'Item label',
- description: 'This is a description',
- descriptionVariant: 'ActionList-item-blockDescription',
- leadingVisual: leadingVisual
-}
-
-export const PatternDescriptionBlockWithTrailingVisual = ListItemTemplate.bind({})
-PatternDescriptionBlockWithTrailingVisual.storyName = '[Description] block + trailing visual'
-PatternDescriptionBlockWithTrailingVisual.args = {
- ...ListItemTemplate.args,
- text: 'Item label',
- description: 'This is a description',
- descriptionVariant: 'ActionList-item-blockDescription',
- trailingVisual: trailingVisual
-}
-
-export const PatternDescriptionBlockWithLeadingAndTrailingVisual = ListItemTemplate.bind({})
-PatternDescriptionBlockWithLeadingAndTrailingVisual.storyName = '[Description] block + leading/trailing visual'
-PatternDescriptionBlockWithLeadingAndTrailingVisual.args = {
- ...ListItemTemplate.args,
- text: 'Item label',
- description: 'This is a description',
- descriptionVariant: 'ActionList-item-blockDescription',
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual
-}
-
-export const PatternDescriptionInline = ListItemTemplate.bind({})
-PatternDescriptionInline.storyName = '[Description] inline'
-PatternDescriptionInline.args = {
- ...ListItemTemplate.args,
- text: 'Item label',
- description: 'This is a description',
- descriptionVariant: 'ActionList-item-descriptionWrap--inline'
-}
-
-export const PatternDescriptionInlineWithLeadingVisual = ListItemTemplate.bind({})
-PatternDescriptionInlineWithLeadingVisual.storyName = '[Description] inline + leading visual'
-PatternDescriptionInlineWithLeadingVisual.args = {
- ...ListItemTemplate.args,
- text: 'Item label',
- description: 'This is a description',
- descriptionVariant: 'ActionList-item-descriptionWrap--inline',
- leadingVisual: leadingVisual
-}
-
-export const PatternDescriptionInlineWithTrailingVisual = ListItemTemplate.bind({})
-PatternDescriptionInlineWithTrailingVisual.storyName = '[Description] inline + trailing visual'
-PatternDescriptionInlineWithTrailingVisual.args = {
- ...ListItemTemplate.args,
- text: 'Item label',
- description: 'This is a description',
- descriptionVariant: 'ActionList-item-descriptionWrap--inline',
- trailingVisual: trailingVisual
-}
-
-export const PatternDescriptionInlineWithLeadingAndTrailingVisual = ListItemTemplate.bind({})
-PatternDescriptionInlineWithLeadingAndTrailingVisual.storyName = '[Description] inline + leading/trailing visual'
-PatternDescriptionInlineWithLeadingAndTrailingVisual.args = {
- ...ListItemTemplate.args,
- text: 'Item label',
- description: 'This is a description',
- descriptionVariant: 'ActionList-item-descriptionWrap--inline',
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual
-}
-
-export const PatternNavActiveAnchor = ListItemTemplate.bind({})
-PatternNavActiveAnchor.storyName = '[Nav] Active anchor'
-PatternNavActiveAnchor.args = {
- ...ListItemTemplate.args,
- text: 'Im an anchor link',
- href: '#someid',
- ariaCurrent: 'location',
- activeNavItem: true
-}
-
-export const PatternNavActivePage = ListItemTemplate.bind({})
-PatternNavActivePage.storyName = '[Nav] Active page'
-PatternNavActivePage.args = {
- ...ListItemTemplate.args,
- text: 'Im a page level link',
- href: '/',
- ariaCurrent: 'page',
- activeNavItem: true
-}
-
-export const PatternVariantDangerItem = ListItemTemplate.bind({})
-PatternVariantDangerItem.storyName = '[Variant] Danger'
-PatternVariantDangerItem.args = {
- ...ListItemTemplate.args,
- text: 'Danger danger',
- variant: 'ActionList-item--danger'
-}
-
-export const PatternVariantDangerItemLeading = ListItemTemplate.bind({})
-PatternVariantDangerItemLeading.storyName = '[Variant] Danger + leading visual'
-PatternVariantDangerItemLeading.args = {
- ...ListItemTemplate.args,
- text: 'Danger danger',
- variant: 'ActionList-item--danger',
- leadingVisual: leadingVisual
-}
-
-export const PatternVariantDangerItemTrailing = ListItemTemplate.bind({})
-PatternVariantDangerItemTrailing.storyName = '[Variant] Danger + trailing visual'
-PatternVariantDangerItemTrailing.args = {
- ...ListItemTemplate.args,
- text: 'Danger danger',
- variant: 'ActionList-item--danger',
- trailingVisual: trailingVisual
-}
-
-export const PatternVariantDangerItemLeadingTrailing = ListItemTemplate.bind({})
-PatternVariantDangerItemLeadingTrailing.storyName = '[Variant] Danger + leading/trailing visual'
-PatternVariantDangerItemLeadingTrailing.args = {
- ...ListItemTemplate.args,
- text: 'Danger danger',
- variant: 'ActionList-item--danger',
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual
-}
-
-export const PatternVariantDisabledItem = ListItemTemplate.bind({})
-PatternVariantDisabledItem.storyName = '[Variant] Disabled'
-PatternVariantDisabledItem.args = {
- ...ListItemTemplate.args,
- text: 'Disabled',
- ariaDisabled: true
-}
-
-export const PatternVariantDisabledItemLeading = ListItemTemplate.bind({})
-PatternVariantDisabledItemLeading.storyName = '[Variant] Disabled + leading visual'
-PatternVariantDisabledItemLeading.args = {
- ...ListItemTemplate.args,
- text: 'Disabled',
- ariaDisabled: true,
- leadingVisual: leadingVisual
-}
-
-export const PatternVariantDisabledItemTrailing = ListItemTemplate.bind({})
-PatternVariantDisabledItemTrailing.storyName = '[Variant] Disabled + trailing visual'
-PatternVariantDisabledItemTrailing.args = {
- ...ListItemTemplate.args,
- text: 'Disabled',
- ariaDisabled: true,
- trailingVisual: trailingVisual
-}
-
-export const PatternVariantDisabledItemLeadingTrailing = ListItemTemplate.bind({})
-PatternVariantDisabledItemLeadingTrailing.storyName = '[Variant] Disabled + leading/trailing visual'
-PatternVariantDisabledItemLeadingTrailing.args = {
- ...ListItemTemplate.args,
- text: 'Disabled',
- ariaDisabled: true,
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual
-}
-
-export const PatternSingleSelectItem = ListItemTemplate.bind({})
-PatternSingleSelectItem.storyName = '[Actions] Single select'
-PatternSingleSelectItem.args = {
- text: 'Single select item',
- singleSelect: true
-}
-
-export const PatternSingleSelectItemWithLeadingVisual = ListItemTemplate.bind({})
-PatternSingleSelectItemWithLeadingVisual.storyName = '[Actions] Single select + leading visual'
-PatternSingleSelectItemWithLeadingVisual.args = {
- text: 'Single select item',
- singleSelect: true,
- leadingVisual: leadingVisual
-}
-
-export const PatternSingleSelectItemWithTrailingVisual = ListItemTemplate.bind({})
-PatternSingleSelectItemWithTrailingVisual.storyName = '[Actions] Single select + trailing visual'
-PatternSingleSelectItemWithTrailingVisual.args = {
- text: 'Single select item',
- singleSelect: true,
- trailingVisual: trailingVisual
-}
-
-export const PatternSingleSelectItemWithLeadingAndTrailingVisual = ListItemTemplate.bind({})
-PatternSingleSelectItemWithLeadingAndTrailingVisual.storyName = '[Actions] Single select + leading/trailing visual'
-PatternSingleSelectItemWithLeadingAndTrailingVisual.args = {
- text: 'Single select item',
- singleSelect: true,
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual
-}
-
-export const PatternMultiSelectItem = ListItemTemplate.bind({})
-PatternMultiSelectItem.storyName = '[Actions] Multi select'
-PatternMultiSelectItem.args = {
- text: 'Multi select item',
- multiSelect: true
-}
-
-export const PatternMultiSelectItemWithLeadingVisual = ListItemTemplate.bind({})
-PatternMultiSelectItemWithLeadingVisual.storyName = '[Actions] Multi select + leading visual'
-PatternMultiSelectItemWithLeadingVisual.args = {
- text: 'Multi select item',
- multiSelect: true,
- leadingVisual: leadingVisual
-}
-
-export const PatternMultiSelectItemWithTrailingVisual = ListItemTemplate.bind({})
-PatternMultiSelectItemWithTrailingVisual.storyName = '[Actions] Multi select + trailing visual'
-PatternMultiSelectItemWithTrailingVisual.args = {
- text: 'Multi select item',
- multiSelect: true,
- trailingVisual: trailingVisual
-}
-
-export const PatternMultiSelectItemWithLeadingAndTrailingVisual = ListItemTemplate.bind({})
-PatternMultiSelectItemWithLeadingAndTrailingVisual.storyName = '[Actions] Multi select + leading/trailing visual'
-PatternMultiSelectItemWithLeadingAndTrailingVisual.args = {
- text: 'Multi select item',
- multiSelect: true,
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual
-}
-
-export const PatternTruncateText = ListItemTemplate.bind({})
-PatternTruncateText.storyName = 'Truncate text'
-PatternTruncateText.args = {
- ...ListItemTemplate.args,
- truncateItem: true,
- text: 'This is a very long string of text that will wrap to another line on smaller screens',
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual
-}
-
-export const PatternWrapText = ListItemTemplate.bind({})
-PatternWrapText.storyName = 'Wrap text'
-PatternWrapText.args = {
- ...ListItemTemplate.args,
- text: 'This is a very long string of text that will wrap to another line on smaller screens',
- trailingVisual: trailingVisual,
- leadingVisual: leadingVisual
-}
diff --git a/docs/src/stories/ui-patterns/ActionList/ActionListTree.stories.jsx b/docs/src/stories/ui-patterns/ActionList/ActionListTree.stories.jsx
deleted file mode 100644
index 99f75533f7..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/ActionListTree.stories.jsx
+++ /dev/null
@@ -1,160 +0,0 @@
-import React from 'react'
-import {ListTemplate} from './ActionList.stories'
-import {ListItemTemplate} from './ActionListItem.stories'
-import {ActionListItemCollapsibleTemplate} from '../../ui-patterns/ActionList/ActionListItemCollapsible.stories.jsx'
-
-export default {
- title: 'UI Patterns/ActionList/ActionTreeView',
- excludeStories: ['ActionListTreeViewTemplate'],
- layout: 'padded',
- argTypes: {
- showGroupIcon: {
- control: {type: 'boolean'},
- description: 'show subgroup leading icon',
- table: {
- category: 'Interactive'
- }
- },
- showSubItemIcon: {
- control: {type: 'boolean'},
- description: 'show subgroup item leading icon',
- table: {
- category: 'Interactive'
- }
- },
- text: {
- defaultValue: '',
- type: 'string',
- name: 'title',
- description: 'string',
- table: {
- category: 'HTML'
- }
- },
- truncateItem: {
- defaultValue: false,
- control: {type: 'boolean'},
- table: {
- category: 'CSS'
- }
- }
- }
-}
-
-const folder = ` `
-
-const file = ` `
-
-const trailingVisual = ` `
-
-export const ActionListTreeViewTemplate = ({showGroupIcon, showSubItemIcon, text, truncateItem}) => (
-
- <>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- >
-
-)
-
-export const Playground = ActionListTreeViewTemplate.bind({})
-Playground.args = {
- showSubItemIcon: true,
- showGroupIcon: true,
- text: 'item'
-}
diff --git a/docs/src/stories/ui-patterns/ActionList/ActionListTreeFeatures.stories.jsx b/docs/src/stories/ui-patterns/ActionList/ActionListTreeFeatures.stories.jsx
deleted file mode 100644
index 0b24d5ae0a..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/ActionListTreeFeatures.stories.jsx
+++ /dev/null
@@ -1,17 +0,0 @@
-import React from 'react'
-import {ActionListTreeViewTemplate} from './ActionListTree.stories'
-
-export default {
- title: 'UI Patterns/ActionList/ActionTreeView/Features'
-}
-
-export const TruncateText = ActionListTreeViewTemplate.bind({})
-TruncateText.args = {
- truncateItem: true,
- text: 'Super duper long text that will truncate on smaller width rows'
-}
-
-export const WrapText = ActionListTreeViewTemplate.bind({})
-WrapText.args = {
- text: 'Super duper long text that will wrap on smaller width rows'
-}
diff --git a/docs/src/stories/ui-patterns/ActionList/uipatterns.stories.mdx b/docs/src/stories/ui-patterns/ActionList/uipatterns.stories.mdx
deleted file mode 100644
index 19b8500158..0000000000
--- a/docs/src/stories/ui-patterns/ActionList/uipatterns.stories.mdx
+++ /dev/null
@@ -1,11 +0,0 @@
-import {Meta} from '@storybook/addon-docs'
-
-
-
-## UI Patterns
-
-This directory contains pattern level stories that are used to compose component level stories. In general these stories consist of all markup/css that make up an overall "pattern" while component stories are more refined and focused on their own features and intent.
-
-As an example, Overlay is a pattern used by Dialog, Anchored overlay, and "dropdown" type scenarios. Overlay is a set of styles reused for those core components, and provides its own set of stories to be inherited from the UI Patterns directory.
-
-Consider these stories "private API" and use the stories within the `Components` directory as an official API reference.
diff --git a/docs/src/stories/ui-patterns/Overlay/Overlay.stories.jsx b/docs/src/stories/ui-patterns/Overlay/Overlay.stories.jsx
index b5a33ee15a..069d9c4935 100644
--- a/docs/src/stories/ui-patterns/Overlay/Overlay.stories.jsx
+++ b/docs/src/stories/ui-patterns/Overlay/Overlay.stories.jsx
@@ -1,7 +1,6 @@
import clsx from 'clsx'
import React from 'react'
import ConditionalWrapper from '../../helpers/ConditionalWrapper'
-import {PatternFullBleed} from '../ActionList/ActionListFeatures.stories.jsx'
const variant = {}
export default {
title: 'UI Patterns/Overlay',
diff --git a/src/actionlist/action-list-item-divider.scss b/src/actionlist/action-list-item-divider.scss
deleted file mode 100644
index 43bd74efc3..0000000000
--- a/src/actionlist/action-list-item-divider.scss
+++ /dev/null
@@ -1,48 +0,0 @@
-// empty divider
-
-.ActionList-sectionDivider {
- // has children
- &:not(:empty) {
- display: flex;
- padding: ($spacer-1 * 1.5) $spacer-2;
- font-size: $font-size-small;
- font-weight: $font-weight-bold;
- color: var(--color-fg-muted);
- flex-direction: column;
- }
-
- // no children
- &:empty {
- display: block;
- height: 1px;
- padding: 0;
- // stylelint-disable-next-line primer/spacing
- margin: ($spacer-2 - 1px) ($spacer-2 * -1) $spacer-2;
- list-style: none;
- background: var(--color-action-list-item-inline-divider);
- border: 0;
- }
-
- .ActionList-sectionDivider-title {
- font-size: $font-size-small;
- font-weight: $font-weight-bold;
- color: var(--color-fg-muted);
- }
-}
-
-.ActionList-sectionDivider--filled {
- margin: $spacer-2 ($spacer-2 * -1);
- background: var(--color-canvas-subtle);
- border-top: $border-width $border-style var(--color-action-list-item-inline-divider);
- border-bottom: $border-width $border-style var(--color-action-list-item-inline-divider);
-
- // if no children, treat as divider
- &:empty {
- height: $spacer-2;
- box-sizing: border-box;
- }
-
- &:first-child {
- margin-top: 0;
- }
-}
diff --git a/src/actionlist/action-list-item.scss b/src/actionlist/action-list-item.scss
deleted file mode 100644
index 76f2f9027b..0000000000
--- a/src/actionlist/action-list-item.scss
+++ /dev/null
@@ -1,593 +0,0 @@
-// stylelint-disable max-nesting-depth, selector-max-specificity, selector-max-compound-selectors
-
-@mixin activeIndicatorLine($padding-left: -$actionList-item-padding-horizontal) {
- position: absolute;
- top: calc(50% - 12px);
- left: $padding-left;
- width: $spacer-1;
- height: $spacer-4;
- content: '';
- background: var(--color-accent-fg);
- border-radius: $border-radius;
-}
-
-//
-.ActionList-item {
- position: relative;
- list-style: none;
- background-color: transparent;
- border-radius: $border-radius;
-
- &:hover,
- &:active {
- cursor: pointer;
- }
-
- // only hover li without list as children
- &:not(.ActionList-item--hasSubItem),
- // target contents of first child li if sub-item (li wraps item label + nested ul)
- &.ActionList-item--hasSubItem > .ActionList-content {
- @media (hover: hover) {
- &:hover {
- cursor: pointer;
- background-color: var(--color-action-list-item-default-hover-bg);
-
- &:not(.ActionList-item--navActive):not(:focus-visible) {
- // Support for "Windows high contrast mode"
- outline: $border-style $border-width transparent;
- outline-offset: -$border-width;
- // stylelint-disable-next-line primer/box-shadow
- box-shadow: inset 0 0 0 $border-width var(--color-action-list-item-default-active-border);
- }
- }
- }
-
- &:active {
- background: var(--color-action-list-item-default-active-bg);
-
- &:not(.ActionList-item--navActive) {
- // Support for "Windows high contrast mode" https://sarahmhigley.com/writing/whcm-quick-tips/
- outline: $border-style $border-width transparent;
- outline-offset: -$border-width;
- // stylelint-disable-next-line primer/box-shadow
- box-shadow: inset 0 0 0 $border-width var(--color-action-list-item-default-active-border);
- }
- }
-
- // hide dividers
-
- @media (hover: hover) {
- &:hover {
- .ActionList-item-label::before,
- + .ActionList-item .ActionList-item-label::before {
- visibility: hidden;
- }
-
- .ActionList-item-descriptionWrap--inline::before,
- + .ActionList-item .ActionList-item-descriptionWrap--inline::before {
- visibility: hidden;
- }
- }
- }
- // stylelint-disable-next-line no-duplicate-selectors
- &:active {
- .ActionList-item-label::before,
- + .ActionList-item .ActionList-item-label::before {
- visibility: hidden;
- }
- }
- }
-
- // target contents of li if sub-item (li wraps item label + nested ul)
- // collapse styles here
- &.ActionList-item--hasSubItem {
- // first child
- > .ActionList-content {
- z-index: 1;
-
- @media (hover: hover) {
- &:hover {
- background-color: var(--color-action-list-item-default-hover-bg);
- }
- }
-
- &:active {
- background-color: var(--color-action-list-item-default-active-bg);
- }
- }
- }
-
- // Make sure that the first visible item isn't a divider
- &[hidden] + .ActionList-sectionDivider {
- display: none;
- }
-
- // Autocomplete [aria-selected] items
-
- &[aria-selected='true'] {
- font-weight: $font-weight-normal;
- background: var(--color-action-list-item-default-selected-bg);
-
- @media (hover: hover) {
- &:hover {
- background-color: var(--color-action-list-item-default-hover-bg);
- }
- }
-
- &::before,
- + .ActionList-item::before {
- visibility: hidden;
- }
-
- // blue accent line
- &::after {
- @include activeIndicatorLine(-$spacer-1);
- }
- }
-
- // active state [aria-current]
-
- &.ActionList-item--navActive {
- &:not(.ActionList-item--subItem) {
- .ActionList-item-label {
- font-weight: $font-weight-bold;
- }
- }
-
- &:not(.ActionList-item--danger) {
- background: var(--color-action-list-item-default-selected-bg);
-
- @media (hover: hover) {
- &:hover {
- background-color: var(--color-action-list-item-default-hover-bg);
- }
- }
-
- &::before,
- + .ActionList-item::before {
- visibility: hidden;
- }
-
- // blue accent line
- &::after {
- @include activeIndicatorLine;
- }
- }
- }
-
- // checkbox item [aria-checked]
- // listbox [aria-selected]
-
- &[aria-checked='true'],
- &[aria-selected='true'] {
- // multiselect checkmark
- .ActionList-item-multiSelectCheckmark {
- visibility: visible;
- opacity: 1;
- transition: visibility 0 linear 0, opacity $actionList-item-checkmark-transition-timing;
- }
-
- // singleselect checkmark
- .ActionList-item-singleSelectCheckmark {
- visibility: visible;
-
- @media screen and (prefers-reduced-motion: no-preference) {
- animation: checkmarkIn 200ms cubic-bezier(0.11, 0, 0.5, 0) forwards;
- }
- }
-
- // checkbox
- .ActionList-item-multiSelectIcon {
- .ActionList-item-multiSelectIconRect {
- fill: var(--color-accent-fg);
- stroke: var(--color-accent-fg);
- stroke-width: $border-width;
- }
-
- .ActionList-item-multiSelectCheckmark {
- fill: var(--color-fg-on-emphasis);
- }
- }
- }
-
- &[aria-checked='false'],
- &[aria-selected='false'] {
- // multiselect checkmark
- .ActionList-item-multiSelectCheckmark {
- visibility: hidden;
- opacity: 0;
- transition:
- visibility 0 linear $actionList-item-checkmark-transition-timing,
- opacity $actionList-item-checkmark-transition-timing;
- }
-
- // singleselect checkmark
- .ActionList-item-singleSelectCheckmark {
- visibility: hidden;
- transition: visibility 0s linear 200ms;
- clip-path: inset(16px 0 0 0);
-
- @media screen and (prefers-reduced-motion: no-preference) {
- animation: checkmarkOut 200ms cubic-bezier(0.11, 0, 0.5, 0) forwards;
- }
- }
-
- // checkbox
- .ActionList-item-multiSelectIcon {
- .ActionList-item-multiSelectIconRect {
- fill: var(--color-canvas-default);
- stroke: var(--color-border-default);
- stroke-width: $border-width;
- }
- }
-
- .ActionList-item-multiSelectIconRect {
- fill: var(--color-canvas-default);
- border: $border-width $border-style var(--color-border-default);
- }
- }
-
- @keyframes checkmarkIn {
- from {
- clip-path: inset(16px 0 0 0);
- }
-
- to {
- clip-path: inset(0 0 0 0);
- }
- }
-
- @keyframes checkmarkOut {
- from {
- clip-path: inset(0 0 0 0);
- }
-
- to {
- clip-path: inset(16px 0 0 0);
- }
- }
-
- // disabled
- &[aria-disabled='true'] {
- .ActionList-content {
- .ActionList-item-label,
- .ActionList-item-description {
- color: var(--color-primer-fg-disabled);
- }
-
- .ActionList-item-visual {
- fill: var(--color-primer-fg-disabled);
- }
- }
-
- @media (hover: hover) {
- &:hover {
- cursor: not-allowed;
- background-color: transparent;
- }
- }
- }
-
- // variants
-
- // danger
- &.ActionList-item--danger {
- .ActionList-item-label {
- color: var(--color-danger-fg);
- }
-
- .ActionList-item-visual {
- color: var(--color-danger-fg);
- }
-
- @media (hover: hover) {
- &:hover {
- background: var(--color-action-list-item-danger-hover-bg);
-
- .ActionList-item-label {
- color: var(--color-action-list-item-danger-hover-text);
- }
- }
- }
-
- .ActionList-content {
- &:active {
- background: var(--color-action-list-item-danger-active-bg);
- }
- }
- }
-
- // if nested list exists, remove default padding
- .ActionList {
- // stylelint-disable-next-line primer/spacing
- padding: unset;
- }
-}
-
-// button or a href
-.ActionList-content {
- position: relative;
- display: grid;
- width: 100%;
- // stylelint-disable-next-line primer/spacing
- padding: $actionList-item-padding-vertical $actionList-item-padding-horizontal;
- font-size: $body-font-size;
- font-weight: $font-weight-normal;
- color: var(--color-fg-default);
- text-align: left;
- user-select: none;
- background-color: transparent;
- // stylelint-disable-next-line declaration-property-value-disallowed-list
- border: none;
- border-radius: $border-radius;
- transition: $actionList-item-bg-transition;
- touch-action: manipulation;
- touch-action: manipulation;
- -webkit-tap-highlight-color: transparent;
- grid-template-rows: min-content;
- grid-template-areas: 'leadingAction leadingVisual label trailingVisual trailingAction';
- grid-template-columns: min-content min-content minmax(0, auto) min-content min-content;
- align-items: start;
-
- // column-gap persists with empty grid-areas, margin applies only when children exist
- > :not(:last-child) {
- margin-right: $spacer-2;
- }
-
- // state
-
- &:hover {
- text-decoration: none;
- }
-
- &:focus {
- @include focusOutline;
-
- // remove fallback :focus if :focus-visible is supported
- &:not(:focus-visible) {
- outline: solid 1px transparent;
- }
- }
-
- // default focus state
- &:focus-visible {
- @include focusOutline;
- }
-
- // disabled
- &[aria-disabled='true'] {
- .ActionList-item-label,
- .ActionList-item-description {
- color: var(--color-primer-fg-disabled);
- }
-
- .ActionList-item-visual {
- fill: var(--color-primer-fg-disabled);
- }
-
- @media (hover: hover) {
- &:hover {
- cursor: not-allowed;
- background-color: transparent;
- }
- }
- }
-
- // collapsible item [aria-expanded]
-
- // nesting (single level)
- // target items inside expanded subgroups
- &[aria-expanded] {
- + .ActionList--subGroup {
- @media screen and (prefers-reduced-motion: no-preference) {
- transition: opacity 160ms cubic-bezier(0.25, 1, 0.5, 1), transform 160ms cubic-bezier(0.25, 1, 0.5, 1);
- }
-
- .ActionList-content {
- padding-left: $spacer-4;
- }
- }
-
- // has 16px leading visual
- &.ActionList-content--visual16 + .ActionList--subGroup {
- .ActionList-content {
- padding-left: $spacer-5;
- }
- }
-
- // has 20px leading visual
- &.ActionList-content--visual20 + .ActionList--subGroup {
- .ActionList-content {
- padding-left: $spacer-2 * 4.5; // 36px
- }
- }
-
- // has 24px leading visual
- &.ActionList-content--visual24 + .ActionList--subGroup {
- .ActionList-content {
- padding-left: $spacer-6;
- }
- }
- }
-
- &[aria-expanded='true'] {
- .ActionList-item-collapseIcon {
- transition: transform 120ms linear;
- transform: scaleY(-1);
- }
-
- + .ActionList--subGroup {
- height: auto;
- overflow: visible;
- visibility: visible;
- opacity: 1;
- transform: translateY(0);
- }
-
- &.ActionList-content--hasActiveSubItem {
- > .ActionList-item-label {
- font-weight: $font-weight-bold;
- }
- }
- }
-
- &[aria-expanded='false'] {
- .ActionList-item-collapseIcon {
- transition: transform 120ms linear;
- transform: scaleY(1);
- }
-
- + .ActionList--subGroup {
- height: 0;
- overflow: hidden;
- visibility: hidden;
- opacity: 0;
- transform: translateY(-$spacer-3);
- }
-
- // show active indicator on parent collapse if child is active
- &.ActionList-content--hasActiveSubItem {
- background: var(--color-action-list-item-default-selected-bg);
-
- .ActionList-item-label {
- font-weight: $font-weight-bold;
- }
-
- &::before,
- + .ActionList-item::before {
- visibility: hidden;
- }
-
- // blue accent line
- &::after {
- @include activeIndicatorLine;
- }
- }
- }
-
- // sizes
-
- &.ActionList-content--sizeMedium {
- // 44px total height
- // stylelint-disable-next-line primer/spacing
- padding: $actionList-item-padding-vertical-md $actionList-item-padding-horizontal;
- }
-
- &.ActionList-content--sizeLarge {
- // 48px total height
- // stylelint-disable-next-line primer/spacing
- padding: $actionList-item-padding-vertical-lg $actionList-item-padding-horizontal;
- }
-
- &.ActionList-content--fontSmall {
- font-size: $font-size-small;
- }
-
- // On pointer:coarse (mobile), all list items are large
- @media (pointer: coarse) {
- // stylelint-disable-next-line primer/spacing
- padding: $actionList-item-padding-vertical-lg $actionList-item-padding-horizontal;
- }
-
- &.ActionList-content--blockDescription {
- // if leading/trailing visual, align with first line of content
- .ActionList-item-visual {
- place-self: start;
- }
- }
-}
-
-// place children on grid
-
-.ActionList-item-action--leading {
- grid-area: leadingAction;
-}
-
-.ActionList-item-visual--leading {
- grid-area: leadingVisual;
-}
-
-.ActionList-item-label {
- grid-area: label;
-}
-
-.ActionList-item-visual--trailing {
- grid-area: trailingVisual;
-}
-
-.ActionList-item-action--trailing {
- grid-area: trailingAction;
-}
-
-// wrapper span
-// default block
-.ActionList-item-descriptionWrap {
- grid-area: label;
- display: flex;
- flex-direction: column;
-
- .ActionList-item-description {
- margin-top: $spacer-1;
- }
-
- .ActionList-item-label {
- font-weight: $font-weight-bold;
- }
-}
-
-// inline
-.ActionList-item-descriptionWrap--inline {
- position: relative;
- flex-direction: row;
- align-items: baseline;
-
- .ActionList-item-description {
- // stylelint-disable-next-line primer/spacing
- margin-left: $actionList-item-padding-horizontal;
- }
-}
-
-// description
-.ActionList-item-description {
- font-size: $font-size-small;
- font-weight: $font-weight-normal;
- line-height: $lh-default;
- color: var(--color-fg-muted);
-}
-
-// helper for grid alignment with multi-line content
-// span wrapping svg or text
-.ActionList-item-visual,
-.ActionList-item-action {
- display: flex;
- min-height: $actionList-item-height-sm;
- color: var(--color-fg-muted); // if visual is text
- pointer-events: none;
- fill: var(--color-fg-muted);
- align-items: center;
-}
-
-// text
-// stylelint-disable-next-line no-duplicate-selectors
-.ActionList-item-label {
- position: relative; // for pseudo dividers
- font-weight: $font-weight-normal;
- // we need a strict value here for grid alignment
- // stylelint-disable-next-line primer/typography
- line-height: $actionList-item-label-line-height;
- color: var(--color-fg-default);
-}
-
-.ActionList-item-label--truncate {
- overflow: hidden;
- text-overflow: ellipsis;
- white-space: nowrap;
-}
-
-// nested lists (only supports 1 level currently)
-// target ActionList-item--subItem for padding-left to maintain :active :after state
-
-// TODO: remove with PVC implementation
-.ActionList-item--subItem > .ActionList-content {
- font-size: $font-size-small;
-}
diff --git a/src/actionlist/action-list-tree.scss b/src/actionlist/action-list-tree.scss
deleted file mode 100644
index 445b27923c..0000000000
--- a/src/actionlist/action-list-tree.scss
+++ /dev/null
@@ -1,118 +0,0 @@
-// stylelint-disable max-nesting-depth, selector-max-compound-selectors, selector-max-specificity, selector-max-type, primer/spacing
-// tree-view variant
-// renders ActionList with default styling for tree-view
-// collapse/expand icons presents as leadingActions, rotate 90deg
-// connecting vertical lines between collapse groups
-// consistent font-size between nested groups
-
-@mixin treeConnectingLine($left) {
- position: absolute;
- left: $left;
- width: 1px;
- height: 100%;
- content: '';
- background: var(--color-action-list-item-inline-divider);
-}
-
-.ActionList--tree {
- --ActionList-tree-depth: 1;
- // TODO: remove with PVC implementation
- .ActionList-item--subItem > .ActionList-content {
- font-size: $body-font-size;
- }
-
- .ActionList-item {
- // class for single tree items not within a group
- &.ActionList-item--singleton {
- .ActionList-content {
- padding-left: $spacer-5;
- }
- }
-
- // normal font-weight for any active item
- &.ActionList-item--navActive {
- &:not(.ActionList-item--subItem) {
- .ActionList-item-label {
- font-weight: $font-weight-normal;
- }
- }
- }
- }
-
- .ActionList-content {
- // nesting (infinite levels)
- // target items inside expanded subgroup
- &[aria-expanded] {
- + .ActionList--subGroup {
- position: relative;
-
- // --ActionList-tree-depth is defined as an inline style referencing the aria-level of each item ie: aria-level="2"
- .ActionList-content {
- padding-left: calc(#{$spacer-2} * var(--ActionList-tree-depth));
- }
- }
- }
-
- // tree-view specific collapse icon positioning/animation
- &[aria-expanded='true'] {
- .ActionList-item-collapseIcon {
- transition: transform 120ms linear;
- transform: rotate(0deg);
- }
-
- // normal weight for parent folder containing active child
- &.ActionList-content--hasActiveSubItem {
- > .ActionList-item-label {
- font-weight: $font-weight-normal;
- }
- }
- }
-
- &[aria-expanded='false'] {
- .ActionList-item-collapseIcon {
- transition: transform 120ms linear;
- transform: rotate(-90deg);
- }
-
- &.ActionList-content--hasActiveSubItem {
- > .ActionList-item-label {
- font-weight: $font-weight-normal;
- }
- }
- }
- }
-
- // expand/collapse group
- .ActionList-item--hasSubItem {
- .ActionList-item--subItem:not(.ActionList-item--hasSubItem) {
- .ActionList-content {
- // increase child padding by targeting content first child span (add to ActionList-content padding, not replace)
- // creates a slight indent of child items
- > span:first-child {
- padding-left: $spacer-4;
- }
- }
- }
- }
-
- // first subitem
- > [aria-level='1'].ActionList-item--hasSubItem {
- > .ActionList--subGroup {
- &::before {
- @include treeConnectingLine($left: $spacer-3);
- }
- }
- }
-
- // all other subitems
- // center connecting line with parent (line is 1px (8px - 1px)
- .ActionList-item--hasSubItem:not([aria-level='1']) {
- > .ActionList--subGroup {
- &::before {
- @include treeConnectingLine(
- $left: calc(#{$spacer-2} * (var(--ActionList-tree-depth)) + #{$spacer-2 - $border-width})
- );
- }
- }
- }
-}
diff --git a/src/actionlist/action-list-variables.scss b/src/actionlist/action-list-variables.scss
deleted file mode 100644
index 1fa8f32fbc..0000000000
--- a/src/actionlist/action-list-variables.scss
+++ /dev/null
@@ -1,8 +0,0 @@
-$actionList-item-height-sm: $spacer-2 * 2.5 !default;
-$actionList-item-label-line-height: $spacer-2 * 2.5 !default;
-$actionList-item-padding-vertical-md: $spacer-2 * 1.25 !default;
-$actionList-item-padding-vertical-lg: $spacer-2 * 1.75 !default;
-$actionList-item-padding-vertical: $spacer-1 * 1.5 !default;
-$actionList-item-padding-horizontal: $spacer-2 !default;
-$actionList-item-bg-transition: background 33.333ms linear !default; // 2 frames on a 60hz monitor
-$actionList-item-checkmark-transition-timing: 50ms !default;
diff --git a/src/actionlist/action-list.scss b/src/actionlist/action-list.scss
deleted file mode 100644
index df4515287a..0000000000
--- a/src/actionlist/action-list.scss
+++ /dev/null
@@ -1,67 +0,0 @@
-//
-.ActionList {
- padding: $spacer-2;
-}
-
-// full bleed
-.ActionList--full {
- padding: 0;
-}
-
-// nested list within main ActionList
-.ActionList--subGroup {
- padding: 0;
-}
-
-// dividers
-
-.ActionList--divided {
- .ActionList-item-label::before {
- position: absolute;
- top: -$actionList-item-padding-vertical;
- display: block;
- width: 100%;
- height: 1px;
- content: '';
- background: var(--color-action-list-item-inline-divider);
- }
-
- // if descriptionWrap--inline exists, move pseudo divider to wrapper
- .ActionList-item-descriptionWrap--inline {
- &::before {
- position: absolute;
- top: -$actionList-item-padding-vertical;
- display: block;
- width: 100%;
- height: $border-width;
- content: '';
- background: var(--color-action-list-item-inline-divider);
- }
-
- // unset the default label pseudo
- .ActionList-item-label::before {
- content: unset;
- }
- }
-
- // hide divider if item is active
- .ActionList-item--navActive {
- // stylelint-disable-next-line selector-max-specificity, selector-max-compound-selectors
- .ActionList-item-label::before,
- + .ActionList-item .ActionList-item-label::before {
- visibility: hidden;
- }
- }
-}
-
-// hide if item is first of type with label::before, or is the first item after a sectionDivider
-.ActionList-item:first-of-type .ActionList-item-label::before,
-.ActionList-sectionDivider + .ActionList-item .ActionList-item-label::before {
- visibility: hidden;
-}
-
-// hide if item is first of type with label::before, or is the first item after a sectionDivider
-.ActionList-item:first-of-type .ActionList-item-descriptionWrap--inline::before,
-.ActionList-sectionDivider + .ActionList-item .ActionList-item-descriptionWrap--inline::before {
- visibility: hidden;
-}
diff --git a/src/actionlist/index.scss b/src/actionlist/index.scss
deleted file mode 100644
index 1430b432d6..0000000000
--- a/src/actionlist/index.scss
+++ /dev/null
@@ -1,6 +0,0 @@
-@import '../support/index.scss';
-@import './action-list-variables.scss';
-@import './action-list.scss';
-@import './action-list-tree.scss';
-@import './action-list-item.scss';
-@import './action-list-item-divider.scss';
diff --git a/src/core/index.scss b/src/core/index.scss
index bc704ee041..f0ea356f97 100644
--- a/src/core/index.scss
+++ b/src/core/index.scss
@@ -11,7 +11,6 @@
// Color modes
// Core modules
-@import '../actionlist/index.scss';
@import '../base/index.scss';
@import '../box/index.scss';
@import '../breadcrumb/index.scss';