Commit 09b25a1
authored
fix(material/chips): adds default placeholder for chips input (#30452)
* fix(material/chips): creates default aria-placeholder for chips input
Updates Angular Components Chips input so that if no placeholder value
is provided and if no ariaPlaceholder value is provided, that a default
value will be used. This improves accessibility by providing an
aria-placeholder value for VoiceControl to use as a name for the input.
Fixes b/380092814
* refactor(material/chips): fix lint errors
Updates to fix lint errors.
* build(material/chips): updates build for chips.md
Ran command to update chips.md.
* fix(material/chips): fixes chips input demo moving input out of chip-grid
Updates previous chips-demo.html so that the input element is not a child
of chip-grid, but rather a sibling. When mat-chip-grid contains the input,
it hides this as an interactive element from mobile Voice Controls making
it inaccessible.
Fixes b/380092814
* docs(material/chips): update chips docs based on aria-placeholder addition
Updates documentation on chips.md regarding proper placement of the input
element as a sibiling of as opposed to being a child. Also
adds an explanation of the new implementation of ariaPlaceholder on mat-chip
input.
* refactor(material/chips): convert ariaPlaceholder to ariaLabel for chips input
Updates previous fix to Angular Components chips input for using aria-placeholder
and converts it to ariaLabel instead. For the chips-demo moved the input related
to chip-grid to outside of chip-grid so that Voice Control is able to recognize
input as an interactive element. If inside, the input is hidden from Voice
Control making it not fully accessible.
* refactor(material/chips): testing ariaLabel with input inside chip-grid
Updating previous fix to see if ariaLabel will be read even if input is
inside chip-grid.
* refactor(material/chips): make recommended changes after review
Updates previous fix by implementing recommended changes by reviewer.
* refactor(material/chips): updates chips demo to use aria-label
Updates previous change to Chips demo to use aria-label.
* refactor(material/chips): removes commented out code
Cleans up previous changes and removes unused code.
* docs(material/chips): updates chips input accesibility recommendation
Updates example which previously used ariaPlaceholder and instead uses
an aria-label.
* build(material/chips): updates build for chips.md
Ran command to update chips.md api guard.1 parent 43b0860 commit 09b25a1
2 files changed
+18
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
32 | | - | |
33 | 32 | | |
| 33 | + | |
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| |||
185 | 185 | | |
186 | 186 | | |
187 | 187 | | |
188 | | - | |
189 | | - | |
190 | | - | |
191 | | - | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
192 | 193 | | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
193 | 199 | | |
194 | 200 | | |
195 | 201 | | |
| |||
209 | 215 | | |
210 | 216 | | |
211 | 217 | | |
212 | | - | |
| 218 | + | |
213 | 219 | | |
214 | 220 | | |
215 | 221 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
141 | 141 | | |
142 | 142 | | |
143 | 143 | | |
| 144 | + | |
| 145 | + | |
144 | 146 | | |
145 | 147 | | |
146 | 148 | | |
| |||
153 | 155 | | |
154 | 156 | | |
155 | 157 | | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | 158 | | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
160 | 163 | | |
161 | 164 | | |
162 | 165 | | |
| |||
0 commit comments