OLD | NEW |
---|---|
1 // Copyright 2017 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
1 Accessibility.ARIAMetadata._config = { | 5 Accessibility.ARIAMetadata._config = { |
2 'attributes': { | 6 'attributes': { |
3 'aria-activedescendant': {'type': 'IDREF'}, | 7 'aria-activedescendant': {'type': 'IDREF'}, |
4 'aria-atomic': {'default': 'false', 'type': 'boolean'}, | 8 'aria-atomic': {'default': 'false', 'type': 'boolean'}, |
5 'aria-autocomplete': {'default': 'none', 'enum': ['inline', 'list', 'both', 'none'], 'type': 'token'}, | 9 'aria-autocomplete': {'default': 'none', 'enum': ['inline', 'list', 'both', 'none'], 'type': 'token'}, |
6 'aria-busy': {'default': 'false', 'type': 'boolean'}, | 10 'aria-busy': {'default': 'false', 'type': 'boolean'}, |
7 'aria-checked': {'default': 'undefined', 'enum': ['true', 'false', 'mixed', 'undefined'], 'type': 'token'}, | 11 'aria-checked': {'default': 'undefined', 'enum': ['true', 'false', 'mixed', 'undefined'], 'type': 'token'}, |
12 'aria-colcount': {'type': 'integer'}, | |
13 'aria-colindex': {'type': 'integer'}, | |
14 'aria-colspan': {'type': 'integer'}, | |
8 'aria-controls': {'type': 'IDREF_list'}, | 15 'aria-controls': {'type': 'IDREF_list'}, |
16 'aria-current': | |
17 {'default': 'false', 'enum': ['page', 'step', 'location', 'date', 'time' , 'true', 'false'], 'type': 'token'}, | |
9 'aria-describedby': {'type': 'IDREF_list'}, | 18 'aria-describedby': {'type': 'IDREF_list'}, |
19 'aria-details': {'type': 'IDREF'}, | |
10 'aria-disabled': {'default': 'false', 'type': 'boolean'}, | 20 'aria-disabled': {'default': 'false', 'type': 'boolean'}, |
11 'aria-dropeffect': | 21 'aria-dropeffect': |
12 {'default': 'none', 'enum': ['copy', 'move', 'link', 'execute', 'popup', 'none'], 'type': 'token_list'}, | 22 {'default': 'none', 'enum': ['copy', 'move', 'link', 'execute', 'popup', 'none'], 'type': 'token_list'}, |
23 'aria-errormessage': {'type': 'IDREF'}, | |
13 'aria-expanded': {'default': 'undefined', 'enum': ['true', 'false', 'undefin ed'], 'type': 'token'}, | 24 'aria-expanded': {'default': 'undefined', 'enum': ['true', 'false', 'undefin ed'], 'type': 'token'}, |
14 'aria-flowto': {'type': 'IDREF_list'}, | 25 'aria-flowto': {'type': 'IDREF_list'}, |
15 'aria-grabbed': {'default': 'undefined', 'enum': ['true', 'false', 'undefine d'], 'type': 'token'}, | 26 'aria-grabbed': {'default': 'undefined', 'enum': ['true', 'false', 'undefine d'], 'type': 'token'}, |
16 'aria-haspopup': {'default': 'false', 'type': 'boolean'}, | 27 'aria-haspopup': |
17 'aria-hidden': {'default': 'false', 'type': 'boolean'}, | 28 {'default': 'false', 'enum': ['false', 'true', 'menu', 'listbox', 'tree' , 'grid', 'dialog'], 'type': 'token'}, |
29 'aria-hidden': {'default': 'undefined', 'enum': ['true', 'false', 'undefined '], 'type': 'token'}, | |
18 'aria-invalid': {'default': 'false', 'enum': ['grammar', 'false', 'spelling' , 'true'], 'type': 'token'}, | 30 'aria-invalid': {'default': 'false', 'enum': ['grammar', 'false', 'spelling' , 'true'], 'type': 'token'}, |
31 'aria-keyshortcuts': {'type': 'string'}, | |
19 'aria-label': {'type': 'string'}, | 32 'aria-label': {'type': 'string'}, |
20 'aria-labelledby': {'type': 'IDREF_list'}, | 33 'aria-labelledby': {'type': 'IDREF_list'}, |
21 'aria-level': {'type': 'integer'}, | 34 'aria-level': {'type': 'integer'}, |
22 'aria-live': {'default': 'off', 'enum': ['off', 'polite', 'assertive'], 'typ e': 'token'}, | 35 'aria-live': {'default': 'off', 'enum': ['off', 'polite', 'assertive'], 'typ e': 'token'}, |
36 'aria-modal': {'default': 'false', 'type': 'boolean'}, | |
23 'aria-multiline': {'default': 'false', 'type': 'boolean'}, | 37 'aria-multiline': {'default': 'false', 'type': 'boolean'}, |
24 'aria-multiselectable': {'default': 'false', 'type': 'boolean'}, | 38 'aria-multiselectable': {'default': 'false', 'type': 'boolean'}, |
25 'aria-orientation': {'default': 'vertical', 'enum': ['horizontal', 'vertical '], 'type': 'token'}, | 39 'aria-orientation': {'default': 'undefined', 'enum': ['horizontal', 'undefin ed', 'vertical'], 'type': 'token'}, |
26 'aria-owns': {'type': 'IDREF_list'}, | 40 'aria-owns': {'type': 'IDREF_list'}, |
41 'aria-placeholder': {'type': 'string'}, | |
27 'aria-posinset': {'type': 'integer'}, | 42 'aria-posinset': {'type': 'integer'}, |
28 'aria-pressed': {'default': 'undefined', 'enum': ['true', 'false', 'mixed', 'undefined'], 'type': 'token'}, | 43 'aria-pressed': {'default': 'undefined', 'enum': ['true', 'false', 'mixed', 'undefined'], 'type': 'token'}, |
29 'aria-readonly': {'default': 'false', 'type': 'boolean'}, | 44 'aria-readonly': {'default': 'false', 'type': 'boolean'}, |
30 'aria-relevant': | 45 'aria-relevant': |
31 {'default': 'additions text', 'enum': ['additions', 'removals', 'text', 'all'], 'type': 'token_list'}, | 46 {'default': 'additions text', 'enum': ['additions', 'removals', 'text', 'all'], 'type': 'token_list'}, |
32 'aria-required': {'default': 'false', 'type': 'boolean'}, | 47 'aria-required': {'default': 'false', 'type': 'boolean'}, |
48 'aria-roledescription': {'type': 'string'}, | |
49 'aria-rowcount': {'type': 'integer'}, | |
50 'aria-rowindex': {'type': 'integer'}, | |
51 'aria-rowspan': {'type': 'integer'}, | |
33 'aria-selected': {'default': 'undefined', 'enum': ['true', 'false', 'undefin ed'], 'type': 'token'}, | 52 'aria-selected': {'default': 'undefined', 'enum': ['true', 'false', 'undefin ed'], 'type': 'token'}, |
34 'aria-setsize': {'type': 'integer'}, | 53 'aria-setsize': {'type': 'integer'}, |
35 'aria-sort': {'default': 'none', 'enum': ['ascending', 'descending', 'none', 'other'], 'type': 'token'}, | 54 'aria-sort': {'default': 'none', 'enum': ['ascending', 'descending', 'none', 'other'], 'type': 'token'}, |
36 'aria-valuemax': {'type': 'decimal'}, | 55 'aria-valuemax': {'type': 'decimal'}, |
37 'aria-valuemin': {'type': 'decimal'}, | 56 'aria-valuemin': {'type': 'decimal'}, |
38 'aria-valuenow': {'type': 'decimal'}, | 57 'aria-valuenow': {'type': 'decimal'}, |
39 'aria-valuetext': {'type': 'string'}, | 58 'aria-valuetext': {'type': 'string'}, |
40 'tabindex': {'type': 'integer'} | 59 'tabindex': {'type': 'integer'} |
41 }, | 60 }, |
42 'roles': { | 61 'roles': { |
43 'alert': {'nameFrom': ['author'], 'superclasses': ['region']}, | 62 'alert': { |
44 'alertdialog': {'nameFrom': ['author'], 'superclasses': ['alert', 'dialog']} , | 63 'nameFrom': ['author'], |
45 'application': {'nameFrom': ['author'], 'superclasses': ['landmark']}, | 64 'superclasses': ['section'], |
46 'article': {'nameFrom': ['author'], 'superclasses': ['document', 'region']}, | 65 'implicitValues': {'aria-live': 'assertive', 'aria-atomic': 'true'} |
66 }, | |
67 'alertdialog': {'nameFrom': ['author'], 'superclasses': ['alert', 'dialog'], 'nameRequired': true}, | |
68 'application': {'nameFrom': ['author'], 'superclasses': ['structure'], 'name Required': true}, | |
69 'article': { | |
70 'nameFrom': ['author'], | |
71 'superclasses': ['document'], | |
72 'supportedAttributes': ['aria-posinset', 'aria-setsize'] | |
73 }, | |
47 'banner': {'nameFrom': ['author'], 'superclasses': ['landmark']}, | 74 'banner': {'nameFrom': ['author'], 'superclasses': ['landmark']}, |
48 'button': { | 75 'button': { |
49 'nameFrom': ['contents', 'author'], | 76 'nameFrom': ['contents', 'author'], |
50 'superclasses': ['command'], | 77 'superclasses': ['command'], |
51 'supportedAttributes': ['aria-expanded', 'aria-pressed'] | 78 'supportedAttributes': ['aria-expanded', 'aria-pressed'], |
79 'nameRequired': true, | |
80 'childrenPresentational': true | |
52 }, | 81 }, |
53 'checkbox': {'nameFrom': ['contents', 'author'], 'requiredAttributes': ['ari a-checked'], 'superclasses': ['input']}, | 82 'cell': { |
aleventhal
2017/06/30 20:30:19
FYI only, I just sent the following email to publi
aboxhall
2017/07/06 01:58:52
Ah, noted. I'll take it out for now.
| |
83 'namefrom': ['contents', 'author'], | |
84 'scope': 'row', | |
85 'superclasses': ['section'], | |
86 'supportedAttributes': ['aria-colindex', 'aria-colspan', 'aria-rowindex', 'aria-rowspan'] | |
87 }, | |
88 'checkbox': { | |
89 'nameFrom': ['contents', 'author'], | |
90 'requiredAttributes': ['aria-checked'], | |
91 'superclasses': ['input'], | |
92 'supportedAttributes': ['aria-readonly'], | |
93 'nameRequired': true, | |
94 'childrenPresentational': true, | |
95 'implicitValues': {'aria-checked': false} | |
96 }, | |
54 'columnheader': { | 97 'columnheader': { |
55 'nameFrom': ['contents', 'author'], | 98 'nameFrom': ['contents', 'author'], |
56 'scope': ['row'], | 99 'scope': ['row'], |
57 'superclasses': ['gridcell', 'sectionhead', 'widget'], | 100 'superclasses': ['gridcell', 'sectionhead', 'widget'], |
58 'supportedAttributes': ['aria-sort'] | 101 'supportedAttributes': ['aria-sort'], |
102 'nameRequired': true | |
59 }, | 103 }, |
60 'combobox': { | 104 'combobox': { |
61 'mustContain': ['listbox', 'textbox'], | 105 // TODO(aboxhall): Follow up with Nektarios and Aaron regarding role on te xtbox |
106 'mustContain': ['textbox'], | |
62 'nameFrom': ['author'], | 107 'nameFrom': ['author'], |
63 'requiredAttributes': ['aria-expanded'], | 108 'requiredAttributes': ['aria-controls', 'aria-expanded'], |
64 'superclasses': ['select'], | 109 'superclasses': ['select'], |
65 'supportedAttributes': ['aria-autocomplete', 'aria-required'] | 110 'supportedAttributes': ['aria-autocomplete', 'aria-readonly', 'aria-requir ed'], |
111 'nameRequired': true, | |
112 'implicitValues': {'aria-expanded': 'false', 'aria-haspopup': 'listbox'} | |
66 }, | 113 }, |
67 'command': {'abstract': true, 'nameFrom': ['author'], 'superclasses': ['widg et']}, | 114 'command': {'abstract': true, 'nameFrom': ['author'], 'superclasses': ['widg et']}, |
68 'complementary': {'nameFrom': ['author'], 'superclasses': ['landmark']}, | 115 'complementary': {'nameFrom': ['author'], 'superclasses': ['landmark']}, |
69 'composite': { | 116 'composite': { |
70 'abstract': true, | 117 'abstract': true, |
71 'nameFrom': ['author'], | 118 'nameFrom': ['author'], |
72 'superclasses': ['widget'], | 119 'superclasses': ['widget'], |
73 'supportedAttributes': ['aria-activedescendant'], | 120 'supportedAttributes': ['aria-activedescendant'], |
74 }, | 121 }, |
75 'contentinfo': {'nameFrom': ['author'], 'superclasses': ['landmark']}, | 122 'contentinfo': {'nameFrom': ['author'], 'superclasses': ['landmark']}, |
76 'definition': {'nameFrom': ['author'], 'superclasses': ['section']}, | 123 'definition': {'nameFrom': ['author'], 'superclasses': ['section']}, |
77 'dialog': {'nameFrom': ['author'], 'superclasses': ['window']}, | 124 'dialog': {'nameFrom': ['author'], 'superclasses': ['window'], 'nameRequired ': true}, |
78 'directory': {'nameFrom': ['contents', 'author'], 'superclasses': ['list']}, | 125 'directory': {'nameFrom': ['author'], 'superclasses': ['list']}, |
79 'document': {'nameFrom': ['author'], 'superclasses': ['structure'], 'support edAttributes': ['aria-expanded']}, | 126 'document': { |
aleventhal
2017/06/30 20:30:20
Document has nameRequired: false, believe or not
aboxhall
2017/07/06 01:58:52
Good catch, thanks. Fixed.
| |
127 'nameFrom': ['author'], | |
128 'superclasses': ['structure'], | |
129 'supportedAttributes': ['aria-expanded'], | |
130 'nameRequired': true | |
131 }, | |
132 'feed': {'nameFrom': ['author'], 'superclasses': ['list'], 'mustContain': [' article'], 'nameRequired': false}, | |
133 'figure': {'namefrom': ['author'], 'superclasses': ['section'], 'nameRequire d': false}, | |
80 'form': {'nameFrom': ['author'], 'superclasses': ['landmark']}, | 134 'form': {'nameFrom': ['author'], 'superclasses': ['landmark']}, |
81 'grid': { | 135 'grid': { |
82 'mustContain': ['row', 'rowgroup', 'row'], | |
83 'nameFrom': ['author'], | 136 'nameFrom': ['author'], |
84 'superclasses': ['composite', 'region'], | 137 'superclasses': ['composite', 'table'], |
85 'supportedAttributes': ['aria-level', 'aria-multiselectable', 'aria-readon ly'] | 138 'mustContain': ['row'], |
aleventhal
2017/06/30 20:30:19
Spec says required owned elements are:
row
rowgrou
aboxhall
2017/07/06 01:58:52
Yeah, I punted on that for this CL, and for all si
| |
139 'supportedAttributes': ['aria-level', 'aria-multiselectable', 'aria-readon ly'], | |
140 'nameRequired': true | |
86 }, | 141 }, |
87 'gridcell': { | 142 'gridcell': { |
88 'nameFrom': ['contents', 'author'], | 143 'nameFrom': ['contents', 'author'], |
89 'scope': ['row'], | 144 'scope': ['row'], |
90 'superclasses': ['section', 'widget'], | 145 'superclasses': ['cell', 'widget'], |
91 'supportedAttributes': ['aria-readonly', 'aria-required', 'aria-selected'] | 146 'supportedAttributes': ['aria-readonly', 'aria-required', 'aria-selected'] , |
147 'nameRequired': true | |
92 }, | 148 }, |
93 'group': {'nameFrom': ['author'], 'superclasses': ['section'], 'supportedAtt ributes': ['aria-activedescendant']}, | 149 'group': {'nameFrom': ['author'], 'superclasses': ['section'], 'supportedAtt ributes': ['aria-activedescendant']}, |
94 'heading': {'superclasses': ['sectionhead'], 'supportedAttributes': ['aria-l evel']}, | 150 'heading': { |
95 'img': {'nameFrom': ['author'], 'superclasses': ['section']}, | 151 'namefrom': ['contents', 'author'], |
152 'superclasses': ['sectionhead'], | |
153 'supportedAttributes': ['aria-level'], | |
154 'nameRequired': true, | |
155 'implicitValues': {'aria-level': '2'} | |
156 }, | |
157 'img': {'nameFrom': ['author'], 'superclasses': ['section'], 'nameRequired': true, 'childrenPresentational': true}, | |
96 'input': {'abstract': true, 'nameFrom': ['author'], 'superclasses': ['widget ']}, | 158 'input': {'abstract': true, 'nameFrom': ['author'], 'superclasses': ['widget ']}, |
97 'landmark': {'abstract': true, 'nameFrom': ['contents', 'author'], 'supercla sses': ['region']}, | 159 'landmark': |
aleventhal
2017/06/30 20:30:19
landmark should be only nameFrom 'author'
aboxhall
2017/07/06 01:58:51
Done.
| |
98 'link': {'nameFrom': ['contents', 'author'], 'superclasses': ['command'], 's upportedAttributes': ['aria-expanded']}, | 160 {'abstract': true, 'nameFrom': ['contents', 'author'], 'superclasses': [ 'section'], 'nameRequired': false}, |
99 'list': {'mustContain': ['group', 'listitem', 'listitem'], 'nameFrom': ['aut hor'], 'superclasses': ['region']}, | 161 'link': { |
162 'nameFrom': ['contents', 'author'], | |
163 'superclasses': ['command'], | |
164 'supportedAttributes': ['aria-expanded'], | |
165 'nameRequired': true | |
166 }, | |
167 'list': { | |
168 'mustContain': ['listitem'], | |
aleventhal
2017/06/30 20:30:20
Can contain a group
group → listitem
listitem
aboxhall
2017/07/06 01:58:52
TODO added.
| |
169 'nameFrom': ['author'], | |
170 'superclasses': ['section'], | |
171 'nameRequired': true, | |
172 'implicitValues': {'aria-orientation': 'vertical'} | |
aleventhal
2017/06/30 20:30:20
No name required for list.
aboxhall
2017/07/06 01:58:52
Done.
| |
173 }, | |
100 'listbox': { | 174 'listbox': { |
175 'nameFrom': ['author'], | |
176 'superclasses': ['select'], | |
101 'mustContain': ['option'], | 177 'mustContain': ['option'], |
102 'nameFrom': ['author'], | 178 'supportedAttributes': ['aria-multiselectable', 'aria-readonly', 'aria-req uired'], |
103 'superclasses': ['list', 'select'], | 179 'nameRequired': true, |
104 'supportedAttributes': ['aria-multiselectable', 'aria-required'] | 180 'implicitValues': {'aria-orientation': 'vertical'}, |
105 }, | 181 }, |
106 'listitem': { | 182 'listitem': { |
107 'nameFrom': ['contents', 'author'], | 183 'nameFrom': ['author'], |
108 'scope': ['list'], | |
109 'superclasses': ['section'], | 184 'superclasses': ['section'], |
185 'scope': ['group', 'list'], | |
110 'supportedAttributes': ['aria-level', 'aria-posinset', 'aria-setsize'] | 186 'supportedAttributes': ['aria-level', 'aria-posinset', 'aria-setsize'] |
111 }, | 187 }, |
112 'log': {'nameFrom': ['author'], 'superclasses': ['region']}, | 188 'log': { |
189 'nameFrom': ['author'], | |
190 'superclasses': ['region'], | |
aleventhal
2017/06/30 20:30:20
superclass is section
aboxhall
2017/07/06 01:58:52
Done.
| |
191 'nameRequired': true, | |
192 'implicitValues': {'aria-live': 'polite'} | |
193 }, | |
113 'main': {'nameFrom': ['author'], 'superclasses': ['landmark']}, | 194 'main': {'nameFrom': ['author'], 'superclasses': ['landmark']}, |
114 'marquee': {'superclasses': ['section']}, | 195 'marquee': {'nameFrom': ['author'], 'superclasses': ['section'], 'nameRequir ed': true}, |
115 'math': {'nameFrom': ['author'], 'superclasses': ['section']}, | 196 'math': {'nameFrom': ['author'], 'superclasses': ['section'], 'nameRequired' : true}, |
aleventhal
2017/06/30 20:30:20
math is childrenPresentational: true, although I h
aboxhall
2017/07/06 01:58:52
Hm, yeah, it does. Added with a TODO.
| |
116 'menu': { | 197 'menu': { |
117 'mustContain': ['group', 'menuitemradio', 'menuitem', 'menuitemcheckbox', 'menuitemradio'], | 198 'mustContain': ['group', 'menuitemradio', 'menuitem', 'menuitemcheckbox', 'menuitemradio'], |
118 'nameFrom': ['author'], | 199 'nameFrom': ['author'], |
119 'superclasses': ['list', 'select'] | 200 'superclasses': ['select'], |
201 'implicitValues': {'aria-orientation': 'vertical'} | |
120 }, | 202 }, |
121 'menubar': {'nameFrom': ['author'], 'superclasses': ['menu']}, | 203 'menubar': { |
122 'menuitem': {'nameFrom': ['contents', 'author'], 'scope': ['menu', 'menubar' ], 'superclasses': ['command']}, | 204 'nameFrom': ['author'], |
123 'menuitemcheckbox': | 205 'superclasses': ['menu'], |
124 {'nameFrom': ['contents', 'author'], 'scope': ['menu', 'menubar'], 'supe rclasses': ['checkbox', 'menuitem']}, | 206 'mustContain': ['group', 'menuitem', 'menuitemradio', 'menuitemcheckbox'], |
aleventhal
2017/06/30 20:30:20
This looks correct, but I want to point out that h
aboxhall
2017/07/06 01:58:52
Removed and added TODO, thanks.
| |
207 'implicitValues': {'aria-orientation': 'horizontal'} | |
208 }, | |
209 'menuitem': { | |
210 'nameFrom': ['contents', 'author'], | |
211 'scope': ['group', 'menu', 'menubar'], | |
212 'superclasses': ['command'], | |
213 'nameRequired': true | |
214 }, | |
215 'menuitemcheckbox': { | |
216 'nameFrom': ['contents', 'author'], | |
217 'scope': ['menu', 'menubar'], | |
218 'superclasses': ['checkbox', 'menuitem'], | |
219 'nameRequired': true, | |
220 'childrenPresentational': true, | |
221 'implicitValues': {'aria-checked': false} | |
222 }, | |
125 'menuitemradio': { | 223 'menuitemradio': { |
126 'nameFrom': ['contents', 'author'], | 224 'nameFrom': ['contents', 'author'], |
127 'scope': ['menu', 'menubar'], | 225 'scope': ['menu', 'menubar', 'group'], |
128 'superclasses': ['menuitemcheckbox', 'radio'] | 226 'superclasses': ['menuitemcheckbox', 'radio'], |
227 'nameRequired': true, | |
228 'childrenPresentational': true, | |
229 'implicitValues': {'aria-checked': false} | |
129 }, | 230 }, |
130 'navigation': {'nameFrom': ['author'], 'superclasses': ['landmark']}, | 231 'navigation': {'nameFrom': ['author'], 'superclasses': ['landmark']}, |
232 'none': {'superclasses': ['structure']}, | |
131 'note': {'nameFrom': ['author'], 'superclasses': ['section']}, | 233 'note': {'nameFrom': ['author'], 'superclasses': ['section']}, |
132 'option': { | 234 'option': { |
133 'nameFrom': ['contents', 'author'], | 235 'nameFrom': ['contents', 'author'], |
236 'scope': ['listbox'], | |
134 'superclasses': ['input'], | 237 'superclasses': ['input'], |
135 'supportedAttributes': ['aria-checked', 'aria-posinset', 'aria-selected', 'aria-setsize'] | 238 'requiredAttributes': ['aria-selected'], |
239 'supportedAttributes': ['aria-checked', 'aria-posinset', 'aria-setsize'], | |
240 'nameRequired': true, | |
241 'childrenPresentational': true, | |
242 'implicitValues': {'aria-selected': 'false'} | |
136 }, | 243 }, |
137 'presentation': {'superclasses': ['structure']}, | 244 'presentation': {'superclasses': ['structure']}, |
138 'progressbar': {'nameFrom': ['author'], 'superclasses': ['range']}, | 245 'progressbar': |
139 'radio': {'nameFrom': ['contents', 'author'], 'superclasses': ['checkbox', ' option']}, | 246 {'nameFrom': ['author'], 'superclasses': ['range'], 'nameRequired': true , 'childrenPresentational': true}, |
247 'radio': { | |
248 'nameFrom': ['contents', 'author'], | |
249 'superclasses': ['input'], | |
250 'requiredAttributes': ['aria-checked'], | |
251 'supportedAttributes': ['aria-posinset', 'aria-setsize'], | |
252 'nameRequired': true, | |
253 'childrenPresentational': true, | |
254 'implicitValues': {'aria-checked': 'false'} | |
255 }, | |
140 'radiogroup': { | 256 'radiogroup': { |
141 'mustContain': ['radio'], | |
142 'nameFrom': ['author'], | 257 'nameFrom': ['author'], |
143 'superclasses': ['select'], | 258 'superclasses': ['select'], |
144 'supportedAttributes': ['aria-required'] | 259 'mustContain': ['radio'], |
260 'supportedAttributes': ['aria-readonly', 'aria-required'], | |
261 'nameRequired': true | |
145 }, | 262 }, |
146 'range': { | 263 'range': { |
147 'abstract': true, | 264 'abstract': true, |
148 'nameFrom': ['author'], | 265 'nameFrom': ['author'], |
149 'superclasses': ['widget'], | 266 'superclasses': ['widget'], |
150 'supportedAttributes': ['aria-valuemax', 'aria-valuemin', 'aria-valuenow', 'aria-valuetext'] | 267 'supportedAttributes': ['aria-valuemax', 'aria-valuemin', 'aria-valuenow', 'aria-valuetext'] |
151 }, | 268 }, |
152 'region': {'nameFrom': ['author'], 'superclasses': ['section']}, | 269 'region': {'nameFrom': ['author'], 'superclasses': ['landmark'], 'nameRequir ed': true}, |
153 'roletype': { | 270 'roletype': { |
154 'abstract': true, | 271 'abstract': true, |
155 'supportedAttributes': [ | 272 'supportedAttributes': [ |
156 'aria-atomic', 'aria-busy', 'aria-controls', 'aria-describedby', 'aria-d isabled', 'aria-dropeffect', | 273 'aria-atomic', 'aria-busy', 'aria-controls', 'aria-current ', 'aria-describedby', 'aria-details', |
157 'aria-flowto', 'aria-grabbed', 'aria-haspopup', 'aria-hidden', 'aria-inv alid', 'aria-label', 'aria-labelledby', | 274 'aria-disabled', 'aria-dropeffect', 'aria-errormessage', 'aria-flowto' , 'aria-grabbed', 'aria-haspopup', |
158 'aria-live', 'aria-owns', 'aria-relevant' | 275 'aria-hidden', 'aria-invalid', 'aria-keyshortcuts', 'aria-label', 'aria-labelledby', 'aria-live', |
276 'aria-owns', 'aria-relevant', 'aria-roledescription' | |
159 ] | 277 ] |
160 }, | 278 }, |
161 'row': { | 279 'row': { |
162 'mustContain': ['columnheader', 'gridcell', 'rowheader'], | |
163 'nameFrom': ['contents', 'author'], | 280 'nameFrom': ['contents', 'author'], |
164 'scope': ['grid', 'rowgroup', 'treegrid'], | |
165 'superclasses': ['group', 'widget'], | 281 'superclasses': ['group', 'widget'], |
166 'supportedAttributes': ['aria-level', 'aria-selected'] | 282 'mustContain': ['cell', 'columnheader', 'gridcell', 'rowheader'], |
283 'scope': ['grid', 'rowgroup', 'table', 'treegrid'], | |
284 'supportedAttributes': | |
285 ['aria-colindex', 'aria-level', 'aria-rowindex', 'aria-selected', 'ari a-setsize', 'aria-posinset'] | |
aleventhal
2017/06/30 20:30:19
We can't add a comment in this JSON, correct?
Othe
aboxhall
2017/07/06 01:58:52
Luckily this is JavaScript (for now) :P
Comment a
| |
167 }, | 286 }, |
168 'rowgroup': | 287 'rowgroup': { |
169 {'mustContain': ['row'], 'nameFrom': ['contents', 'author'], 'scope': [' grid'], 'superclasses': ['group']}, | 288 'nameFrom': ['contents', 'author'], |
289 'superclasses': ['structure'], | |
290 'mustContain': ['row'], | |
291 'scope': ['grid', 'table', 'treegrid'], | |
292 }, | |
170 'rowheader': { | 293 'rowheader': { |
171 'nameFrom': ['contents', 'author'], | 294 'nameFrom': ['contents', 'author'], |
172 'scope': ['row'], | 295 'scope': ['row'], |
173 'superclasses': ['gridcell', 'sectionhead', 'widget'], | 296 'superclasses': ['cell', 'gridcell', 'sectionhead'], |
174 'supportedAttributes': ['aria-sort'] | 297 'supportedAttributes': ['aria-sort'], |
298 'nameRequired': true | |
175 }, | 299 }, |
176 'scrollbar': { | 300 'scrollbar': { |
177 'nameFrom': ['author'], | 301 'nameFrom': ['author'], |
178 'requiredAttributes': ['aria-controls', 'aria-orientation', 'aria-valuemax ', 'aria-valuemin', 'aria-valuenow'], | 302 'requiredAttributes': ['aria-controls', 'aria-orientation', 'aria-valuemax ', 'aria-valuemin', 'aria-valuenow'], |
179 'superclasses': ['input', 'range'] | 303 'superclasses': ['range'], |
304 'nameRequired': false, | |
305 'childrenPresentational': true, | |
306 'implicitValues': {'aria-orientation': 'vertical', 'aria-valuemin': '0', ' aria-valuemax': '100'} | |
180 }, | 307 }, |
181 'search': {'nameFrom': ['author'], 'superclasses': ['landmark']}, | 308 'search': {'nameFrom': ['author'], 'superclasses': ['landmark']}, |
182 'section': { | 309 'searchbox': {'nameFrom': ['author'], 'superclasses': ['textbox'], 'nameRequ ired': true}, |
183 'abstract': true, | 310 'section': {'abstract': true, 'superclasses': ['structure'], 'supportedAttri butes': ['aria-expanded']}, |
184 'nameFrom': ['contents', 'author'], | |
185 'superclasses': ['structure'], | |
186 'supportedAttributes': ['aria-expanded'] | |
187 }, | |
188 'sectionhead': { | 311 'sectionhead': { |
189 'abstract': true, | 312 'abstract': true, |
190 'nameFrom': ['contents', 'author'], | 313 'nameFrom': ['contents', 'author'], |
191 'superclasses': ['structure'], | 314 'superclasses': ['structure'], |
192 'supportedAttributes': ['aria-expanded'] | 315 'supportedAttributes': ['aria-expanded'] |
193 }, | 316 }, |
194 'select': {'abstract': true, 'nameFrom': ['author'], 'superclasses': ['compo site', 'group', 'input']}, | 317 'select': {'abstract': true, 'nameFrom': ['author'], 'superclasses': ['compo site', 'group']}, |
195 'separator': { | 318 // TODO(aboxhall): separator properties depend on focusability |
aleventhal
2017/06/30 20:30:20
Maybe for now put aria-value* as supported instead
aboxhall
2017/07/06 01:58:52
Good idea, done.
| |
196 'nameFrom': ['author'], | 319 'separator': {'nameFrom': ['author'], 'superclasses': ['structure'], 'suppor tedAttributes': ['aria-orientation']}, |
197 'superclasses': ['structure'], | |
198 'supportedAttributes': ['aria-expanded', 'aria-orientation'] | |
199 }, | |
200 'slider': { | 320 'slider': { |
201 'nameFrom': ['author'], | 321 'nameFrom': ['author'], |
202 'requiredAttributes': ['aria-valuemax', 'aria-valuemin', 'aria-valuenow'], | 322 'requiredAttributes': ['aria-valuemax', 'aria-valuemin', 'aria-valuenow'], |
203 'superclasses': ['input', 'range'], | 323 'superclasses': ['input', 'range'], |
204 'supportedAttributes': ['aria-orientation'] | 324 'supportedAttributes': ['aria-orientation'], |
325 'nameRequired': true, | |
326 'childrenPresentational': true, | |
327 // TODO(aboxhall): aria-valuenow default is halfway between aria-valuemin and aria-valuemax | |
328 'implicitValues': {'aria-orientation': 'horizontal', 'aria-valuemin': '0', 'aria-valuemax': '100'} | |
aleventhal
2017/06/30 20:30:19
Well! You learn something new every day. Creating
aboxhall
2017/07/06 01:58:52
:)
| |
205 }, | 329 }, |
206 'spinbutton': { | 330 'spinbutton': { |
207 'nameFrom': ['author'], | 331 'nameFrom': ['author'], |
208 'requiredAttributes': ['aria-valuemax', 'aria-valuemin', 'aria-valuenow'], | 332 'requiredAttributes': ['aria-valuemax', 'aria-valuemin', 'aria-valuenow'], |
209 'superclasses': ['input', 'range'], | 333 'superclasses': ['composite', 'input', 'range'], |
210 'supportedAttributes': ['aria-required'] | 334 'supportedAttributes': ['aria-required'], |
aleventhal
2017/06/30 20:30:20
Needs aria-readonly
aboxhall
2017/07/06 01:58:52
Done.
| |
335 'nameRequired': true, | |
336 'implicitValues': {'aria-valuenow': '0'} | |
211 }, | 337 }, |
212 'status': {'superclasses': ['region']}, | 338 'status': { |
339 'nameFrom': ['author'], | |
340 'superclasses': ['section'], | |
341 'implicitValues': {'aria-live': 'polite', 'aria-atomic': 'true'} | |
342 }, | |
213 'structure': {'abstract': true, 'superclasses': ['roletype']}, | 343 'structure': {'abstract': true, 'superclasses': ['roletype']}, |
344 'switch': { | |
345 'nameFrom': ['contents', 'author'], | |
346 'superclasses': ['checkbox'], | |
347 'requiredAttributes': ['aria-checked'], | |
348 'nameRequired': true, | |
349 'childrenPresentational': true, | |
350 'implicitValues': {'aria-checked': 'false'} | |
351 }, | |
214 'tab': { | 352 'tab': { |
215 'nameFrom': ['contents', 'author'], | 353 'nameFrom': ['contents', 'author'], |
216 'scope': ['tablist'], | 354 'scope': ['tablist'], |
217 'superclasses': ['sectionhead', 'widget'], | 355 'superclasses': ['sectionhead', 'widget'], |
218 'supportedAttributes': ['aria-selected'] | 356 'supportedAttributes': ['aria-selected'], |
357 'childrenPresentational': true, | |
358 'implicitValues': {'aria-selected': 'false'} | |
359 }, | |
360 'table': { | |
361 'nameFrom': ['author'], | |
362 'superclasses': ['section'], | |
363 'mustContain': ['row'], | |
aleventhal
2017/06/30 20:30:20
rowgroup?
aboxhall
2017/07/06 01:58:52
TODO added.
| |
364 'supportedAttributes': ['aria-colcount', 'aria-rowcount'], | |
365 'nameRequired': true | |
219 }, | 366 }, |
220 'tablist': { | 367 'tablist': { |
368 'nameFrom': ['author'], | |
369 'superclasses': ['composite'], | |
221 'mustContain': ['tab'], | 370 'mustContain': ['tab'], |
222 'nameFrom': ['author'], | 371 'supportedAttributes': ['aria-level', 'aria-multiselectable', 'aria-orient ation'], |
223 'superclasses': ['composite', 'directory'], | 372 'implicitValues': {'aria-orientation': 'horizontal'} |
224 'supportedAttributes': ['aria-level'] | |
225 }, | 373 }, |
226 'tabpanel': {'nameFrom': ['author'], 'superclasses': ['region']}, | 374 'tabpanel': {'nameFrom': ['author'], 'superclasses': ['section'], 'nameRequi red': true}, |
375 'term': {'nameFrom': ['author'], 'superclasses': ['section']}, | |
227 'textbox': { | 376 'textbox': { |
228 'nameFrom': ['author'], | 377 'nameFrom': ['author'], |
229 'superclasses': ['input'], | 378 'superclasses': ['input'], |
230 'supportedAttributes': | 379 'supportedAttributes': [ |
231 ['aria-activedescendant', 'aria-autocomplete', 'aria-multiline', 'aria -readonly', 'aria-required'] | 380 'aria-activedescendant', 'aria-autocomplete', 'aria-multiline', 'aria-pl aceholder', 'aria-readonly', |
381 'aria-required' | |
382 ], | |
383 'nameRequired': true | |
232 }, | 384 }, |
233 'timer': {'nameFrom': ['author'], 'superclasses': ['status']}, | 385 'timer': {'nameFrom': ['author'], 'superclasses': ['status']}, |
234 'toolbar': {'nameFrom': ['author'], 'superclasses': ['group']}, | 386 'toolbar': { |
235 'tooltip': {'superclasses': ['section']}, | 387 'nameFrom': ['author'], |
388 'superclasses': ['group'], | |
389 'supportedAttributes': ['aria-orientation'], | |
390 'implicitValues': {'aria-orientation': 'horizontal'} | |
391 }, | |
392 'tooltip': {'nameFrom': ['contents', 'author'], 'superclasses': ['section'], 'nameRequired': true}, | |
236 'tree': { | 393 'tree': { |
237 'mustContain': ['group', 'treeitem', 'treeitem'], | |
238 'nameFrom': ['author'], | 394 'nameFrom': ['author'], |
395 'mustContain': ['group', 'treeitem'], | |
239 'superclasses': ['select'], | 396 'superclasses': ['select'], |
240 'supportedAttributes': ['aria-multiselectable', 'aria-required'] | 397 'supportedAttributes': ['aria-multiselectable', 'aria-required'], |
398 'nameRequired': true, | |
399 'implicitValues': {'aria-orientation': 'vertical'} | |
241 }, | 400 }, |
242 'treegrid': {'mustContain': ['row'], 'nameFrom': ['author'], 'superclasses': ['grid', 'tree']}, | 401 'treegrid': |
243 'treeitem': | 402 {'mustContain': ['row'], 'nameFrom': ['author'], 'superclasses': ['grid' , 'tree'], 'nameRequired': true}, |
aleventhal
2017/06/30 20:30:19
treegrid can contain rowgroup
aboxhall
2017/07/06 01:58:52
TODO added.
| |
244 {'nameFrom': ['contents', 'author'], 'scope': ['group', 'tree'], 'superc lasses': ['listitem', 'option']}, | 403 'treeitem': { |
404 'nameFrom': ['contents', 'author'], | |
405 'scope': ['group', 'tree'], | |
406 'superclasses': ['listitem', 'option'], | |
407 'nameRequired': true | |
408 }, | |
245 'widget': {'abstract': true, 'superclasses': ['roletype']}, | 409 'widget': {'abstract': true, 'superclasses': ['roletype']}, |
246 'window': { | 410 'window': { |
247 'abstract': true, | 411 'abstract': true, |
248 'nameFrom': ['author'], | 412 'nameFrom': ['author'], |
249 'superclasses': ['roletype'], | 413 'superclasses': ['roletype'], |
250 'supportedAttributes': ['aria-expanded'] | 414 'supportedAttributes': ['aria-expanded', 'aria-modal'] |
251 } | 415 } |
252 } | 416 } |
253 }; | 417 }; |
OLD | NEW |