|
| 1 | +<article role="article"> |
| 2 | + <header class="row well"> |
| 3 | + <h2>Accessible form control labels</h2> |
| 4 | + </header> |
| 5 | + <section class="row well"> |
| 6 | + <header> |
| 7 | + <h3>Implicit labeling</h3> |
| 8 | + <hr> |
| 9 | + </header> |
| 10 | + |
| 11 | + <!-- #docregion cb-a11y-form-controls-input-usage --> |
| 12 | + <a11y-input>Type something:</a11y-input> |
| 13 | + <!--#enddocregion--> |
| 14 | + |
| 15 | + <!-- #docregion cb-a11y-form-controls-textarea-usage --> |
| 16 | + <a11y-textarea>Type some text:</a11y-textarea> |
| 17 | + <!--#enddocregion--> |
| 18 | + |
| 19 | + <!-- #docregion cb-a11y-form-controls-checkboxes-usage --> |
| 20 | + <a11y-checkboxes [checkboxModel]="checkBoxes" [checkboxName]="'likes'"> |
| 21 | + What do you like most about Angular 2? |
| 22 | + </a11y-checkboxes> |
| 23 | + <!--#enddocregion--> |
| 24 | + |
| 25 | + <!-- #docregion cb-a11y-form-controls-radiobuttons-usage --> |
| 26 | + <a11y-radiobuttons [radiobuttonModel]="radioButtons" [radiobuttonName]="'language'"> |
| 27 | + Choose your favourite Angular 2 language: |
| 28 | + </a11y-radiobuttons> |
| 29 | + <!--#enddocregion--> |
| 30 | + |
| 31 | + <!-- #docregion cb-a11y-form-controls-select-usage --> |
| 32 | + <a11y-select [optionsModel]="selectOptions">Why are you interested in a11y?</a11y-select> |
| 33 | + <!--#enddocregion--> |
| 34 | + |
| 35 | + </section> |
| 36 | + <section class="row well"> |
| 37 | + <header> |
| 38 | + <h3>Explicit labeling</h3> |
| 39 | + <hr> |
| 40 | + </header> |
| 41 | + |
| 42 | + <!-- #docregion cb-a11y-form-controls-input-explicit-usage --> |
| 43 | + <a11y-input-explicit> Label for input:</a11y-input-explicit> |
| 44 | + <!--#enddocregion--> |
| 45 | + |
| 46 | + </section> |
| 47 | + <section class="row well"> |
| 48 | + <header> |
| 49 | + <h3>Hiding labels</h3> |
| 50 | + <hr> |
| 51 | + </header> |
| 52 | + |
| 53 | + <!-- #docregion cb-a11y-form-controls-hidden-labels-usage --> |
| 54 | + <a11y-hidden-labels [label1]="'Search:'" |
| 55 | + [label2]="'Filter:'"> |
| 56 | + </a11y-hidden-labels> |
| 57 | + <!--#enddocregion--> |
| 58 | + |
| 59 | + </section> |
| 60 | + <section class="row well"> |
| 61 | + <header> |
| 62 | + <h3>Labeling custom controls</h3> |
| 63 | + <hr> |
| 64 | + </header> |
| 65 | + </section> |
| 66 | + <a href="" [routerLink]="['Index']">Back to index...</a> |
| 67 | +</article> |
| 68 | + |
| 69 | + |
0 commit comments