Uh oh!
There was an error while loading. Please reload this page.
feat(stepper): Add documentation for stepper - #6533
Conversation
| @@ -0,0 +1,128 @@ | |||
| Angular Material stepper walks users through multi-step processes by breaking them up | |||
There was a problem hiding this comment.
The docs pattern I've been trying to keep is something like
- One-sentence summary of the component (tabs docs seem to be the exception)
- Live overview example
- Individual sections specific to the component
- Accessibility section
The live example can go in a follow up PR
There was a problem hiding this comment.
I'd make the first sentence tagline something like
Angular Material's stepper provides a wizard-like workflow by dividing content into logical steps.| that drives a stepped workflow. Material stepper extends the CDK stepper and has Material Design | ||
| styling. | ||
| There are two stepper components: `md-horizontal-stepper` and `md-vertical-stepper`. They |
There was a problem hiding this comment.
I'd put this under a header like ### Stepper variants
| ### Event | ||
| The `selectionChange` output event is emitted when the selected step changes. |
There was a problem hiding this comment.
I'd omit the events section since the information is covered in the generated API docs (we should remove this from the tabs docs as well)
| - <kbd>RIGHT_ARROW</kbd>: Focuses the next step header | ||
| - <kbd>ENTER</kbd>, <kbd>SPACE</kbd>: Selects the step that the focus is currently on | ||
| - <kbd>TAB</kbd>: Focuses the next tabbable element | ||
| - <kbd>TAB</kbd>+<kbd>SHIFT</kbd>: Focuses the previous tabbable element No newline at end of file |
There was a problem hiding this comment.
Need an Accessibility section at the end that describes the a11y aspects of the component. In this case it should mention that the stepper is treated as a tabbed view for a11y purposes. Should also mention any required labels, etc.
| The `selectionChange` output event is emitted when the selected step changes. | ||
| ### Labels | ||
| If a step's label is only text then `label` attribute can be used. |
There was a problem hiding this comment.
"If a step's label is only text, then the label attribute can be used."
| ``` | ||
| ### Linear stepper | ||
| `linear` attribute can be set on `md-horizontal-stepper` and `md-vertical-stepper` to create |
There was a problem hiding this comment.
linear attribute -> The linear attribute
| ### Linear stepper | ||
| `linear` attribute can be set on `md-horizontal-stepper` and `md-vertical-stepper` to create | ||
| a linear stepper that requires the user to complete previous steps before proceeding | ||
| to following steps. For each `md-step`, `stepControl` attribute can be set to the top level |
There was a problem hiding this comment.
stepControl attribute -> the stepControl attribute
| using a different form for each step. | ||
| #### Using a single form | ||
| When using a single form for the stepper, `mdStepperPrevious` and `mdStepperNext` has to be |
| ### Types of steps | ||
| #### Optional step | ||
| If completion of a step in linear stepper is not required, then `optional` attribute can be set |
There was a problem hiding this comment.
optional attribute -> the optional attribute
| #### Editable step | ||
| By default, steps are editable, which means users can return to previously completed steps and | ||
| edit their responses. `editable="true"` can be set on `md-step` to change the default |
| edit their responses. `editable="true"` can be set on `md-step` to change the default | ||
| #### Completed step | ||
| By default, `completed` attribute of a step returns `true` if the step is valid (in case of |
There was a problem hiding this comment.
completed attribute -> the completed attribute
g1shin
commented
Aug 18, 2017
Revised based on review. Ready for review again 👍 |
jelbourn
commented
Aug 18, 2017
mmalerba
commented
Aug 21, 2017
lgtm |
* Documentation for stepper * Revision based on review + add accessibility section
* Documentation for stepper * Revision based on review + add accessibility section
* Documentation for stepper * Revision based on review + add accessibility section
commented
Sep 6, 2019
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
No description provided.