-
Notifications
You must be signed in to change notification settings - Fork 195
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs(accordion,actionbar,actionmenu,alertdialog): site docs to storyb…
…ook (#2770) * docs(accordion, actionbar, actionmenu, alertdialog): docs site details now in storybook Action menu doesn't require it's own MDX page since the DocumentationTemplate already covers the only variant. This is just an update to the description to include some additional details.
- Loading branch information
Showing
10 changed files
with
197 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
import { Canvas, ArgTypes, Meta, Description, Title } from '@storybook/blocks'; | ||
|
||
import * as AccordionStories from './accordion.stories'; | ||
|
||
<Meta of={AccordionStories} title="Docs" /> | ||
|
||
<Title of={AccordionStories} /> | ||
<Description of={AccordionStories} /> | ||
|
||
## Density options | ||
|
||
Accordion has three density options and requires that you specify one of the density types: compact, regular, or spacious. | ||
|
||
### Regular | ||
|
||
<Canvas of={AccordionStories.Regular} /> | ||
|
||
### Compact | ||
|
||
<Canvas of={AccordionStories.Compact} /> | ||
|
||
### Spacious | ||
|
||
<Canvas of={AccordionStories.Spacious} /> | ||
|
||
## Properties | ||
|
||
<ArgTypes /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import { Canvas, ArgTypes, Meta, Description, Title } from '@storybook/blocks'; | ||
|
||
import * as ActionBarStories from './actionbar.stories'; | ||
|
||
<Meta of={ActionBarStories} title="Docs" /> | ||
|
||
<Title of={ActionBarStories} /> | ||
<Description of={ActionBarStories} /> | ||
|
||
## Standard | ||
|
||
<Canvas of={ActionBarStories.Default} /> | ||
|
||
## Emphasized | ||
|
||
<Canvas of={ActionBarStories.Emphasized} /> | ||
|
||
## Behavioral variants | ||
|
||
- Standard - Action bars fill the width of their container. | ||
- Flexible - Action bars fit the width of their content. | ||
- Sticky - Action bars will sit on top of content until dismissed. | ||
|
||
## Popover Dependency | ||
Action bar requires Popover, which is nested within Action bar. Action bar background, border, and corner radius are applied to the nested Popover component and can be overriden by Action bar using `--mod-*` prefixed custom properties. A [list of the properties](https://github.com/adobe/spectrum-css/blob/main/components/actionbar/metadata/mods.md) can be found in the repo. | ||
|
||
## Properties | ||
|
||
<ArgTypes /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import { Canvas, ArgTypes, Meta, Description, Title } from '@storybook/blocks'; | ||
|
||
import * as AlertDialogStories from './alertdialog.stories'; | ||
|
||
<Meta of={AlertDialogStories} title="Docs" /> | ||
|
||
<Title of={AlertDialogStories} /> | ||
<Description of={AlertDialogStories} /> | ||
|
||
## Confirmation | ||
This is the default variant for alert dialogs. Use a confirmation variant for asking a user to confirm a choice. | ||
|
||
<Canvas of={AlertDialogStories.Default} /> | ||
|
||
## Information | ||
Information alert dialogs communicate important information that a user needs to acknowledge. Before using this kind of alert dialog, make sure it’s the appropriate communication channel for the message instead of a toast or a more lightweight messaging option. | ||
|
||
Note that an alert dialog can have a total of 3 buttons if the secondary outline button label is defined. | ||
|
||
<Canvas of={AlertDialogStories.Information} /> | ||
|
||
## Warning | ||
Warning alert dialogs communicate important information to users in relation to an issue that needs to be acknowledged, but does not block the user from moving forward. | ||
|
||
<Canvas of={AlertDialogStories.Warning} /> | ||
|
||
## Error | ||
Error alert dialogs communicate critical information about an issue that a user needs to acknowledge. | ||
|
||
<Canvas of={AlertDialogStories.Error} /> | ||
|
||
## Destructive | ||
Destructive alert dialogs are for when a user needs to confirm an action that will impact their data or experience in a potentially negative way, such as deleting files or contacts. | ||
|
||
<Canvas of={AlertDialogStories.Destructive} /> | ||
|
||
## Scroll | ||
|
||
<Canvas of={AlertDialogStories.Scroll} /> | ||
|
||
## Properties | ||
|
||
<ArgTypes /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters