html-validate 8.9.1 → 8.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/browser.js +1 -0
- package/dist/cjs/browser.js.map +1 -1
- package/dist/cjs/cli.js.map +1 -1
- package/dist/cjs/core.js +199 -23
- package/dist/cjs/core.js.map +1 -1
- package/dist/cjs/elements.js +496 -236
- package/dist/cjs/elements.js.map +1 -1
- package/dist/cjs/index.js +1 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/matchers.js.map +1 -1
- package/dist/cjs/tsdoc-metadata.json +1 -1
- package/dist/es/browser.js +1 -1
- package/dist/es/cli.js +1 -1
- package/dist/es/cli.js.map +1 -1
- package/dist/es/core-browser.js +1 -1
- package/dist/es/core-nodejs.js +1 -1
- package/dist/es/core.js +199 -24
- package/dist/es/core.js.map +1 -1
- package/dist/es/elements.js +496 -236
- package/dist/es/elements.js.map +1 -1
- package/dist/es/html-validate.js +1 -1
- package/dist/es/index.js +1 -1
- package/dist/es/matchers-jestonly.js +1 -1
- package/dist/es/matchers.js.map +1 -1
- package/dist/schema/elements.json +22 -0
- package/dist/tsdoc-metadata.json +1 -1
- package/dist/types/browser.d.ts +78 -1
- package/dist/types/index.d.ts +78 -1
- package/package.json +28 -26
package/dist/cjs/elements.js
CHANGED
|
@@ -20,6 +20,21 @@ const ReferrerPolicy = [
|
|
|
20
20
|
"strict-origin-when-cross-origin",
|
|
21
21
|
"unsafe-url"
|
|
22
22
|
];
|
|
23
|
+
function isInsideLandmark(node) {
|
|
24
|
+
const selectors = [
|
|
25
|
+
"article",
|
|
26
|
+
"aside",
|
|
27
|
+
"main",
|
|
28
|
+
"nav",
|
|
29
|
+
"section",
|
|
30
|
+
'[role="article"]',
|
|
31
|
+
'[role="complementary"]',
|
|
32
|
+
'[role="main"]',
|
|
33
|
+
'[role="navigation"]',
|
|
34
|
+
'[role="region"]'
|
|
35
|
+
];
|
|
36
|
+
return Boolean(node.closest(selectors.join(",")));
|
|
37
|
+
}
|
|
23
38
|
var html5 = metaHelper.defineMetadata({
|
|
24
39
|
"*": {
|
|
25
40
|
attributes: {
|
|
@@ -113,14 +128,22 @@ var html5 = metaHelper.defineMetadata({
|
|
|
113
128
|
}
|
|
114
129
|
},
|
|
115
130
|
permittedDescendants: [{ exclude: "@interactive" }],
|
|
116
|
-
|
|
117
|
-
|
|
131
|
+
aria: {
|
|
132
|
+
implicitRole(node) {
|
|
133
|
+
return node.hasAttribute("href") ? "link" : "generic";
|
|
134
|
+
},
|
|
135
|
+
naming(node) {
|
|
136
|
+
return node.hasAttribute("href") ? "allowed" : "prohibited";
|
|
137
|
+
}
|
|
118
138
|
}
|
|
119
139
|
},
|
|
120
140
|
abbr: {
|
|
121
141
|
flow: true,
|
|
122
142
|
phrasing: true,
|
|
123
|
-
permittedContent: ["@phrasing"]
|
|
143
|
+
permittedContent: ["@phrasing"],
|
|
144
|
+
aria: {
|
|
145
|
+
naming: "prohibited"
|
|
146
|
+
}
|
|
124
147
|
},
|
|
125
148
|
acronym: {
|
|
126
149
|
deprecated: {
|
|
@@ -131,8 +154,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
131
154
|
},
|
|
132
155
|
address: {
|
|
133
156
|
flow: true,
|
|
134
|
-
|
|
135
|
-
|
|
157
|
+
aria: {
|
|
158
|
+
implicitRole: "group"
|
|
136
159
|
},
|
|
137
160
|
permittedContent: ["@flow"],
|
|
138
161
|
permittedDescendants: [{ exclude: ["address", "header", "footer", "@heading", "@sectioning"] }]
|
|
@@ -210,8 +233,13 @@ var html5 = metaHelper.defineMetadata({
|
|
|
210
233
|
enum: ["/[^_].*/", "_blank", "_self", "_parent", "_top"]
|
|
211
234
|
}
|
|
212
235
|
},
|
|
213
|
-
|
|
214
|
-
|
|
236
|
+
aria: {
|
|
237
|
+
implicitRole(node) {
|
|
238
|
+
return node.hasAttribute("href") ? "link" : "generic";
|
|
239
|
+
},
|
|
240
|
+
naming(node) {
|
|
241
|
+
return node.hasAttribute("href") ? "allowed" : "prohibited";
|
|
242
|
+
}
|
|
215
243
|
},
|
|
216
244
|
requiredAncestors: ["map"]
|
|
217
245
|
},
|
|
@@ -220,8 +248,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
220
248
|
sectioning: true,
|
|
221
249
|
permittedContent: ["@flow"],
|
|
222
250
|
permittedDescendants: [{ exclude: ["main"] }],
|
|
223
|
-
|
|
224
|
-
|
|
251
|
+
aria: {
|
|
252
|
+
implicitRole: "article"
|
|
225
253
|
}
|
|
226
254
|
},
|
|
227
255
|
aside: {
|
|
@@ -229,8 +257,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
229
257
|
sectioning: true,
|
|
230
258
|
permittedContent: ["@flow"],
|
|
231
259
|
permittedDescendants: [{ exclude: ["main"] }],
|
|
232
|
-
|
|
233
|
-
|
|
260
|
+
aria: {
|
|
261
|
+
implicitRole: "complementary"
|
|
234
262
|
}
|
|
235
263
|
},
|
|
236
264
|
audio: {
|
|
@@ -262,12 +290,19 @@ var html5 = metaHelper.defineMetadata({
|
|
|
262
290
|
b: {
|
|
263
291
|
flow: true,
|
|
264
292
|
phrasing: true,
|
|
265
|
-
permittedContent: ["@phrasing"]
|
|
293
|
+
permittedContent: ["@phrasing"],
|
|
294
|
+
aria: {
|
|
295
|
+
implicitRole: "generic",
|
|
296
|
+
naming: "prohibited"
|
|
297
|
+
}
|
|
266
298
|
},
|
|
267
299
|
base: {
|
|
268
300
|
metadata: true,
|
|
269
301
|
void: true,
|
|
270
|
-
permittedParent: ["head"]
|
|
302
|
+
permittedParent: ["head"],
|
|
303
|
+
aria: {
|
|
304
|
+
naming: "prohibited"
|
|
305
|
+
}
|
|
271
306
|
},
|
|
272
307
|
basefont: {
|
|
273
308
|
deprecated: {
|
|
@@ -279,12 +314,20 @@ var html5 = metaHelper.defineMetadata({
|
|
|
279
314
|
bdi: {
|
|
280
315
|
flow: true,
|
|
281
316
|
phrasing: true,
|
|
282
|
-
permittedContent: ["@phrasing"]
|
|
317
|
+
permittedContent: ["@phrasing"],
|
|
318
|
+
aria: {
|
|
319
|
+
implicitRole: "generic",
|
|
320
|
+
naming: "prohibited"
|
|
321
|
+
}
|
|
283
322
|
},
|
|
284
323
|
bdo: {
|
|
285
324
|
flow: true,
|
|
286
325
|
phrasing: true,
|
|
287
|
-
permittedContent: ["@phrasing"]
|
|
326
|
+
permittedContent: ["@phrasing"],
|
|
327
|
+
aria: {
|
|
328
|
+
implicitRole: "generic",
|
|
329
|
+
naming: "prohibited"
|
|
330
|
+
}
|
|
288
331
|
},
|
|
289
332
|
bgsound: {
|
|
290
333
|
deprecated: {
|
|
@@ -309,8 +352,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
309
352
|
blockquote: {
|
|
310
353
|
flow: true,
|
|
311
354
|
sectioning: true,
|
|
312
|
-
|
|
313
|
-
|
|
355
|
+
aria: {
|
|
356
|
+
implicitRole: "blockquote"
|
|
314
357
|
},
|
|
315
358
|
permittedContent: ["@flow"]
|
|
316
359
|
},
|
|
@@ -354,6 +397,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
354
397
|
vlink: {
|
|
355
398
|
deprecated: true
|
|
356
399
|
}
|
|
400
|
+
},
|
|
401
|
+
aria: {
|
|
402
|
+
implicitRole: "generic",
|
|
403
|
+
naming: "prohibited"
|
|
357
404
|
}
|
|
358
405
|
},
|
|
359
406
|
br: {
|
|
@@ -364,6 +411,9 @@ var html5 = metaHelper.defineMetadata({
|
|
|
364
411
|
clear: {
|
|
365
412
|
deprecated: true
|
|
366
413
|
}
|
|
414
|
+
},
|
|
415
|
+
aria: {
|
|
416
|
+
naming: "prohibited"
|
|
367
417
|
}
|
|
368
418
|
},
|
|
369
419
|
button: {
|
|
@@ -413,8 +463,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
413
463
|
enum: ["submit", "reset", "button"]
|
|
414
464
|
}
|
|
415
465
|
},
|
|
416
|
-
|
|
417
|
-
|
|
466
|
+
aria: {
|
|
467
|
+
implicitRole: "button"
|
|
418
468
|
},
|
|
419
469
|
permittedContent: ["@phrasing"],
|
|
420
470
|
permittedDescendants: [{ exclude: ["@interactive"] }],
|
|
@@ -433,6 +483,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
433
483
|
align: {
|
|
434
484
|
deprecated: true
|
|
435
485
|
}
|
|
486
|
+
},
|
|
487
|
+
aria: {
|
|
488
|
+
implicitRole: "caption",
|
|
489
|
+
naming: "prohibited"
|
|
436
490
|
}
|
|
437
491
|
},
|
|
438
492
|
center: {
|
|
@@ -445,12 +499,19 @@ var html5 = metaHelper.defineMetadata({
|
|
|
445
499
|
cite: {
|
|
446
500
|
flow: true,
|
|
447
501
|
phrasing: true,
|
|
448
|
-
permittedContent: ["@phrasing"]
|
|
502
|
+
permittedContent: ["@phrasing"],
|
|
503
|
+
aria: {
|
|
504
|
+
naming: "prohibited"
|
|
505
|
+
}
|
|
449
506
|
},
|
|
450
507
|
code: {
|
|
451
508
|
flow: true,
|
|
452
509
|
phrasing: true,
|
|
453
|
-
permittedContent: ["@phrasing"]
|
|
510
|
+
permittedContent: ["@phrasing"],
|
|
511
|
+
aria: {
|
|
512
|
+
implicitRole: "code",
|
|
513
|
+
naming: "prohibited"
|
|
514
|
+
}
|
|
454
515
|
},
|
|
455
516
|
col: {
|
|
456
517
|
attributes: {
|
|
@@ -473,7 +534,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
473
534
|
deprecated: true
|
|
474
535
|
}
|
|
475
536
|
},
|
|
476
|
-
void: true
|
|
537
|
+
void: true,
|
|
538
|
+
aria: {
|
|
539
|
+
naming: "prohibited"
|
|
540
|
+
}
|
|
477
541
|
},
|
|
478
542
|
colgroup: {
|
|
479
543
|
implicitClosed: ["colgroup"],
|
|
@@ -482,18 +546,26 @@ var html5 = metaHelper.defineMetadata({
|
|
|
482
546
|
enum: ["/\\d+/"]
|
|
483
547
|
}
|
|
484
548
|
},
|
|
485
|
-
permittedContent: ["col", "template"]
|
|
549
|
+
permittedContent: ["col", "template"],
|
|
550
|
+
aria: {
|
|
551
|
+
naming: "prohibited"
|
|
552
|
+
}
|
|
486
553
|
},
|
|
487
554
|
data: {
|
|
488
555
|
flow: true,
|
|
489
556
|
phrasing: true,
|
|
490
|
-
permittedContent: ["@phrasing"]
|
|
557
|
+
permittedContent: ["@phrasing"],
|
|
558
|
+
aria: {
|
|
559
|
+
implicitRole: "generic",
|
|
560
|
+
naming: "prohibited"
|
|
561
|
+
}
|
|
491
562
|
},
|
|
492
563
|
datalist: {
|
|
493
564
|
flow: true,
|
|
494
565
|
phrasing: true,
|
|
495
|
-
|
|
496
|
-
|
|
566
|
+
aria: {
|
|
567
|
+
implicitRole: "listbox",
|
|
568
|
+
naming: "prohibited"
|
|
497
569
|
},
|
|
498
570
|
permittedContent: ["@phrasing", "option"]
|
|
499
571
|
},
|
|
@@ -505,7 +577,11 @@ var html5 = metaHelper.defineMetadata({
|
|
|
505
577
|
del: {
|
|
506
578
|
flow: true,
|
|
507
579
|
phrasing: true,
|
|
508
|
-
transparent: true
|
|
580
|
+
transparent: true,
|
|
581
|
+
aria: {
|
|
582
|
+
implicitRole: "deletion",
|
|
583
|
+
naming: "prohibited"
|
|
584
|
+
}
|
|
509
585
|
},
|
|
510
586
|
details: {
|
|
511
587
|
flow: true,
|
|
@@ -516,8 +592,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
516
592
|
boolean: true
|
|
517
593
|
}
|
|
518
594
|
},
|
|
519
|
-
|
|
520
|
-
|
|
595
|
+
aria: {
|
|
596
|
+
implicitRole: "group"
|
|
521
597
|
},
|
|
522
598
|
permittedContent: ["summary", "@flow"],
|
|
523
599
|
permittedOrder: ["summary", "@flow"],
|
|
@@ -526,8 +602,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
526
602
|
dfn: {
|
|
527
603
|
flow: true,
|
|
528
604
|
phrasing: true,
|
|
529
|
-
|
|
530
|
-
|
|
605
|
+
aria: {
|
|
606
|
+
implicitRole: "term"
|
|
531
607
|
},
|
|
532
608
|
permittedContent: ["@phrasing"],
|
|
533
609
|
permittedDescendants: [{ exclude: ["dfn"] }]
|
|
@@ -540,8 +616,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
540
616
|
boolean: true
|
|
541
617
|
}
|
|
542
618
|
},
|
|
543
|
-
|
|
544
|
-
|
|
619
|
+
aria: {
|
|
620
|
+
implicitRole: "dialog"
|
|
545
621
|
}
|
|
546
622
|
},
|
|
547
623
|
dir: {
|
|
@@ -566,6 +642,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
566
642
|
datasrc: {
|
|
567
643
|
deprecated: true
|
|
568
644
|
}
|
|
645
|
+
},
|
|
646
|
+
aria: {
|
|
647
|
+
implicitRole: "generic",
|
|
648
|
+
naming: "prohibited"
|
|
569
649
|
}
|
|
570
650
|
},
|
|
571
651
|
dl: {
|
|
@@ -586,7 +666,11 @@ var html5 = metaHelper.defineMetadata({
|
|
|
586
666
|
em: {
|
|
587
667
|
flow: true,
|
|
588
668
|
phrasing: true,
|
|
589
|
-
permittedContent: ["@phrasing"]
|
|
669
|
+
permittedContent: ["@phrasing"],
|
|
670
|
+
aria: {
|
|
671
|
+
implicitRole: "emphasis",
|
|
672
|
+
naming: "prohibited"
|
|
673
|
+
}
|
|
590
674
|
},
|
|
591
675
|
embed: {
|
|
592
676
|
flow: true,
|
|
@@ -617,19 +701,22 @@ var html5 = metaHelper.defineMetadata({
|
|
|
617
701
|
boolean: true
|
|
618
702
|
}
|
|
619
703
|
},
|
|
620
|
-
|
|
621
|
-
|
|
704
|
+
aria: {
|
|
705
|
+
implicitRole: "group"
|
|
622
706
|
},
|
|
623
707
|
permittedContent: ["@flow", "legend?"],
|
|
624
708
|
permittedOrder: ["legend", "@flow"]
|
|
625
709
|
},
|
|
626
710
|
figcaption: {
|
|
627
|
-
permittedContent: ["@flow"]
|
|
711
|
+
permittedContent: ["@flow"],
|
|
712
|
+
aria: {
|
|
713
|
+
naming: "prohibited"
|
|
714
|
+
}
|
|
628
715
|
},
|
|
629
716
|
figure: {
|
|
630
717
|
flow: true,
|
|
631
|
-
|
|
632
|
-
|
|
718
|
+
aria: {
|
|
719
|
+
implicitRole: "figure"
|
|
633
720
|
},
|
|
634
721
|
permittedContent: ["@flow", "figcaption?"],
|
|
635
722
|
permittedOrder: ["figcaption", "@flow", "figcaption"]
|
|
@@ -643,23 +730,20 @@ var html5 = metaHelper.defineMetadata({
|
|
|
643
730
|
},
|
|
644
731
|
footer: {
|
|
645
732
|
flow: true,
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
return null;
|
|
661
|
-
} else {
|
|
662
|
-
return "contentinfo";
|
|
733
|
+
aria: {
|
|
734
|
+
implicitRole(node) {
|
|
735
|
+
if (isInsideLandmark(node)) {
|
|
736
|
+
return "generic";
|
|
737
|
+
} else {
|
|
738
|
+
return "contentinfo";
|
|
739
|
+
}
|
|
740
|
+
},
|
|
741
|
+
naming(node) {
|
|
742
|
+
if (isInsideLandmark(node)) {
|
|
743
|
+
return "prohibited";
|
|
744
|
+
} else {
|
|
745
|
+
return "allowed";
|
|
746
|
+
}
|
|
663
747
|
}
|
|
664
748
|
},
|
|
665
749
|
permittedContent: ["@flow"],
|
|
@@ -688,8 +772,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
688
772
|
enum: ["/[^_].*/", "_blank", "_self", "_parent", "_top"]
|
|
689
773
|
}
|
|
690
774
|
},
|
|
691
|
-
|
|
692
|
-
|
|
775
|
+
aria: {
|
|
776
|
+
implicitRole: "form"
|
|
693
777
|
},
|
|
694
778
|
permittedContent: ["@flow"],
|
|
695
779
|
permittedDescendants: [{ exclude: ["@form"] }]
|
|
@@ -726,8 +810,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
726
810
|
deprecated: true
|
|
727
811
|
}
|
|
728
812
|
},
|
|
729
|
-
|
|
730
|
-
|
|
813
|
+
aria: {
|
|
814
|
+
implicitRole: "heading"
|
|
731
815
|
}
|
|
732
816
|
},
|
|
733
817
|
h2: {
|
|
@@ -739,8 +823,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
739
823
|
deprecated: true
|
|
740
824
|
}
|
|
741
825
|
},
|
|
742
|
-
|
|
743
|
-
|
|
826
|
+
aria: {
|
|
827
|
+
implicitRole: "heading"
|
|
744
828
|
}
|
|
745
829
|
},
|
|
746
830
|
h3: {
|
|
@@ -752,8 +836,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
752
836
|
deprecated: true
|
|
753
837
|
}
|
|
754
838
|
},
|
|
755
|
-
|
|
756
|
-
|
|
839
|
+
aria: {
|
|
840
|
+
implicitRole: "heading"
|
|
757
841
|
}
|
|
758
842
|
},
|
|
759
843
|
h4: {
|
|
@@ -765,8 +849,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
765
849
|
deprecated: true
|
|
766
850
|
}
|
|
767
851
|
},
|
|
768
|
-
|
|
769
|
-
|
|
852
|
+
aria: {
|
|
853
|
+
implicitRole: "heading"
|
|
770
854
|
}
|
|
771
855
|
},
|
|
772
856
|
h5: {
|
|
@@ -778,8 +862,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
778
862
|
deprecated: true
|
|
779
863
|
}
|
|
780
864
|
},
|
|
781
|
-
|
|
782
|
-
|
|
865
|
+
aria: {
|
|
866
|
+
implicitRole: "heading"
|
|
783
867
|
}
|
|
784
868
|
},
|
|
785
869
|
h6: {
|
|
@@ -791,8 +875,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
791
875
|
deprecated: true
|
|
792
876
|
}
|
|
793
877
|
},
|
|
794
|
-
|
|
795
|
-
|
|
878
|
+
aria: {
|
|
879
|
+
implicitRole: "heading"
|
|
796
880
|
}
|
|
797
881
|
},
|
|
798
882
|
head: {
|
|
@@ -803,27 +887,27 @@ var html5 = metaHelper.defineMetadata({
|
|
|
803
887
|
profile: {
|
|
804
888
|
deprecated: true
|
|
805
889
|
}
|
|
890
|
+
},
|
|
891
|
+
aria: {
|
|
892
|
+
naming: "prohibited"
|
|
806
893
|
}
|
|
807
894
|
},
|
|
808
895
|
header: {
|
|
809
896
|
flow: true,
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
return null;
|
|
825
|
-
} else {
|
|
826
|
-
return "banner";
|
|
897
|
+
aria: {
|
|
898
|
+
implicitRole(node) {
|
|
899
|
+
if (isInsideLandmark(node)) {
|
|
900
|
+
return "generic";
|
|
901
|
+
} else {
|
|
902
|
+
return "banner";
|
|
903
|
+
}
|
|
904
|
+
},
|
|
905
|
+
naming(node) {
|
|
906
|
+
if (isInsideLandmark(node)) {
|
|
907
|
+
return "prohibited";
|
|
908
|
+
} else {
|
|
909
|
+
return "allowed";
|
|
910
|
+
}
|
|
827
911
|
}
|
|
828
912
|
},
|
|
829
913
|
permittedContent: ["@flow"],
|
|
@@ -834,7 +918,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
834
918
|
heading: true,
|
|
835
919
|
permittedContent: ["p", "@heading?"],
|
|
836
920
|
permittedDescendants: [{ exclude: ["hgroup"] }],
|
|
837
|
-
requiredContent: ["@heading"]
|
|
921
|
+
requiredContent: ["@heading"],
|
|
922
|
+
aria: {
|
|
923
|
+
implicitRole: "group"
|
|
924
|
+
}
|
|
838
925
|
},
|
|
839
926
|
hr: {
|
|
840
927
|
flow: true,
|
|
@@ -856,8 +943,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
856
943
|
deprecated: true
|
|
857
944
|
}
|
|
858
945
|
},
|
|
859
|
-
|
|
860
|
-
|
|
946
|
+
aria: {
|
|
947
|
+
implicitRole: "separator"
|
|
861
948
|
}
|
|
862
949
|
},
|
|
863
950
|
html: {
|
|
@@ -872,14 +959,19 @@ var html5 = metaHelper.defineMetadata({
|
|
|
872
959
|
deprecated: true
|
|
873
960
|
}
|
|
874
961
|
},
|
|
875
|
-
|
|
876
|
-
|
|
962
|
+
aria: {
|
|
963
|
+
implicitRole: "document",
|
|
964
|
+
naming: "prohibited"
|
|
877
965
|
}
|
|
878
966
|
},
|
|
879
967
|
i: {
|
|
880
968
|
flow: true,
|
|
881
969
|
phrasing: true,
|
|
882
|
-
permittedContent: ["@phrasing"]
|
|
970
|
+
permittedContent: ["@phrasing"],
|
|
971
|
+
aria: {
|
|
972
|
+
implicitRole: "generic",
|
|
973
|
+
naming: "prohibited"
|
|
974
|
+
}
|
|
883
975
|
},
|
|
884
976
|
iframe: {
|
|
885
977
|
flow: true,
|
|
@@ -981,12 +1073,28 @@ var html5 = metaHelper.defineMetadata({
|
|
|
981
1073
|
deprecated: true
|
|
982
1074
|
}
|
|
983
1075
|
},
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
1076
|
+
aria: {
|
|
1077
|
+
implicitRole(node) {
|
|
1078
|
+
const alt = node.getAttribute("alt");
|
|
1079
|
+
const ariaLabel = node.getAttribute("aria-label");
|
|
1080
|
+
const ariaLabelledBy = node.getAttribute("aria-labelledby");
|
|
1081
|
+
const title = node.getAttribute("title");
|
|
1082
|
+
if (alt === "" && !ariaLabel && !ariaLabelledBy && !title) {
|
|
1083
|
+
return "none";
|
|
1084
|
+
} else {
|
|
1085
|
+
return "img";
|
|
1086
|
+
}
|
|
1087
|
+
},
|
|
1088
|
+
naming(node) {
|
|
1089
|
+
const alt = node.getAttribute("alt");
|
|
1090
|
+
const ariaLabel = node.getAttribute("aria-label");
|
|
1091
|
+
const ariaLabelledBy = node.getAttribute("aria-labelledby");
|
|
1092
|
+
const title = node.getAttribute("title");
|
|
1093
|
+
if (!alt && !ariaLabel && !ariaLabelledBy && !title) {
|
|
1094
|
+
return "prohibited";
|
|
1095
|
+
} else {
|
|
1096
|
+
return "allowed";
|
|
1097
|
+
}
|
|
990
1098
|
}
|
|
991
1099
|
}
|
|
992
1100
|
},
|
|
@@ -1078,7 +1186,6 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1078
1186
|
enum: ["default", "false", "true"]
|
|
1079
1187
|
},
|
|
1080
1188
|
type: {
|
|
1081
|
-
required: true,
|
|
1082
1189
|
enum: [
|
|
1083
1190
|
"button",
|
|
1084
1191
|
"checkbox",
|
|
@@ -1111,49 +1218,76 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1111
1218
|
deprecated: true
|
|
1112
1219
|
}
|
|
1113
1220
|
},
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1221
|
+
aria: {
|
|
1222
|
+
/* eslint-disable-next-line complexity -- the standard is complicated */
|
|
1223
|
+
implicitRole(node) {
|
|
1224
|
+
const list = node.hasAttribute("list");
|
|
1225
|
+
if (list) {
|
|
1226
|
+
return "combobox";
|
|
1227
|
+
}
|
|
1228
|
+
const type = node.getAttribute("type");
|
|
1229
|
+
switch (type) {
|
|
1230
|
+
case "button":
|
|
1231
|
+
return "button";
|
|
1232
|
+
case "checkbox":
|
|
1233
|
+
return "checkbox";
|
|
1234
|
+
case "color":
|
|
1235
|
+
return null;
|
|
1236
|
+
case "date":
|
|
1237
|
+
return null;
|
|
1238
|
+
case "datetime-local":
|
|
1239
|
+
return null;
|
|
1240
|
+
case "email":
|
|
1241
|
+
return "textbox";
|
|
1242
|
+
case "file":
|
|
1243
|
+
return null;
|
|
1244
|
+
case "hidden":
|
|
1245
|
+
return null;
|
|
1246
|
+
case "image":
|
|
1247
|
+
return "button";
|
|
1248
|
+
case "month":
|
|
1249
|
+
return null;
|
|
1250
|
+
case "number":
|
|
1251
|
+
return "spinbutton";
|
|
1252
|
+
case "password":
|
|
1253
|
+
return null;
|
|
1254
|
+
case "radio":
|
|
1255
|
+
return "radio";
|
|
1256
|
+
case "range":
|
|
1257
|
+
return "slider";
|
|
1258
|
+
case "reset":
|
|
1259
|
+
return "button";
|
|
1260
|
+
case "search":
|
|
1261
|
+
return "searchbox";
|
|
1262
|
+
case "submit":
|
|
1263
|
+
return "button";
|
|
1264
|
+
case "tel":
|
|
1265
|
+
return "textbox";
|
|
1266
|
+
case "text":
|
|
1267
|
+
return "textbox";
|
|
1268
|
+
case "time":
|
|
1269
|
+
return null;
|
|
1270
|
+
case "url":
|
|
1271
|
+
return "textbox";
|
|
1272
|
+
case "week":
|
|
1273
|
+
return null;
|
|
1274
|
+
default:
|
|
1275
|
+
return "textbox";
|
|
1276
|
+
}
|
|
1277
|
+
},
|
|
1278
|
+
naming(node) {
|
|
1279
|
+
return node.getAttribute("type") !== "hidden" ? "allowed" : "prohibited";
|
|
1150
1280
|
}
|
|
1151
1281
|
}
|
|
1152
1282
|
},
|
|
1153
1283
|
ins: {
|
|
1154
1284
|
flow: true,
|
|
1155
1285
|
phrasing: true,
|
|
1156
|
-
transparent: true
|
|
1286
|
+
transparent: true,
|
|
1287
|
+
aria: {
|
|
1288
|
+
implicitRole: "insertion",
|
|
1289
|
+
naming: "prohibited"
|
|
1290
|
+
}
|
|
1157
1291
|
},
|
|
1158
1292
|
isindex: {
|
|
1159
1293
|
deprecated: {
|
|
@@ -1163,7 +1297,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1163
1297
|
kbd: {
|
|
1164
1298
|
flow: true,
|
|
1165
1299
|
phrasing: true,
|
|
1166
|
-
permittedContent: ["@phrasing"]
|
|
1300
|
+
permittedContent: ["@phrasing"],
|
|
1301
|
+
aria: {
|
|
1302
|
+
naming: "prohibited"
|
|
1303
|
+
}
|
|
1167
1304
|
},
|
|
1168
1305
|
keygen: {
|
|
1169
1306
|
flow: true,
|
|
@@ -1192,6 +1329,9 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1192
1329
|
for: {
|
|
1193
1330
|
enum: [validId]
|
|
1194
1331
|
}
|
|
1332
|
+
},
|
|
1333
|
+
aria: {
|
|
1334
|
+
naming: "prohibited"
|
|
1195
1335
|
}
|
|
1196
1336
|
},
|
|
1197
1337
|
legend: {
|
|
@@ -1209,6 +1349,9 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1209
1349
|
datasrc: {
|
|
1210
1350
|
deprecated: true
|
|
1211
1351
|
}
|
|
1352
|
+
},
|
|
1353
|
+
aria: {
|
|
1354
|
+
naming: "prohibited"
|
|
1212
1355
|
}
|
|
1213
1356
|
},
|
|
1214
1357
|
li: {
|
|
@@ -1220,8 +1363,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1220
1363
|
deprecated: true
|
|
1221
1364
|
}
|
|
1222
1365
|
},
|
|
1223
|
-
|
|
1224
|
-
|
|
1366
|
+
aria: {
|
|
1367
|
+
implicitRole(node) {
|
|
1368
|
+
return node.closest("ul, ol, menu") ? "listitem" : "generic";
|
|
1369
|
+
}
|
|
1225
1370
|
}
|
|
1226
1371
|
},
|
|
1227
1372
|
link: {
|
|
@@ -1291,6 +1436,9 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1291
1436
|
urn: {
|
|
1292
1437
|
deprecated: true
|
|
1293
1438
|
}
|
|
1439
|
+
},
|
|
1440
|
+
aria: {
|
|
1441
|
+
naming: "prohibited"
|
|
1294
1442
|
}
|
|
1295
1443
|
},
|
|
1296
1444
|
listing: {
|
|
@@ -1300,8 +1448,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1300
1448
|
},
|
|
1301
1449
|
main: {
|
|
1302
1450
|
flow: true,
|
|
1303
|
-
|
|
1304
|
-
|
|
1451
|
+
aria: {
|
|
1452
|
+
implicitRole: "main"
|
|
1305
1453
|
}
|
|
1306
1454
|
},
|
|
1307
1455
|
map: {
|
|
@@ -1313,12 +1461,18 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1313
1461
|
required: true,
|
|
1314
1462
|
enum: ["/\\S+/"]
|
|
1315
1463
|
}
|
|
1464
|
+
},
|
|
1465
|
+
aria: {
|
|
1466
|
+
naming: "prohibited"
|
|
1316
1467
|
}
|
|
1317
1468
|
},
|
|
1318
1469
|
mark: {
|
|
1319
1470
|
flow: true,
|
|
1320
1471
|
phrasing: true,
|
|
1321
|
-
permittedContent: ["@phrasing"]
|
|
1472
|
+
permittedContent: ["@phrasing"],
|
|
1473
|
+
aria: {
|
|
1474
|
+
naming: "prohibited"
|
|
1475
|
+
}
|
|
1322
1476
|
},
|
|
1323
1477
|
marquee: {
|
|
1324
1478
|
deprecated: {
|
|
@@ -1365,14 +1519,14 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1365
1519
|
deprecated: true
|
|
1366
1520
|
}
|
|
1367
1521
|
},
|
|
1368
|
-
|
|
1369
|
-
|
|
1522
|
+
aria: {
|
|
1523
|
+
implicitRole: "math"
|
|
1370
1524
|
}
|
|
1371
1525
|
},
|
|
1372
1526
|
menu: {
|
|
1373
1527
|
flow: true,
|
|
1374
|
-
|
|
1375
|
-
|
|
1528
|
+
aria: {
|
|
1529
|
+
implicitRole: "list"
|
|
1376
1530
|
},
|
|
1377
1531
|
permittedContent: ["@script", "li"]
|
|
1378
1532
|
},
|
|
@@ -1400,14 +1554,17 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1400
1554
|
scheme: {
|
|
1401
1555
|
deprecated: true
|
|
1402
1556
|
}
|
|
1557
|
+
},
|
|
1558
|
+
aria: {
|
|
1559
|
+
naming: "prohibited"
|
|
1403
1560
|
}
|
|
1404
1561
|
},
|
|
1405
1562
|
meter: {
|
|
1406
1563
|
flow: true,
|
|
1407
1564
|
phrasing: true,
|
|
1408
1565
|
labelable: true,
|
|
1409
|
-
|
|
1410
|
-
|
|
1566
|
+
aria: {
|
|
1567
|
+
implicitRole: "meter"
|
|
1411
1568
|
},
|
|
1412
1569
|
permittedContent: ["@phrasing"],
|
|
1413
1570
|
permittedDescendants: [{ exclude: "meter" }]
|
|
@@ -1422,8 +1579,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1422
1579
|
nav: {
|
|
1423
1580
|
flow: true,
|
|
1424
1581
|
sectioning: true,
|
|
1425
|
-
|
|
1426
|
-
|
|
1582
|
+
aria: {
|
|
1583
|
+
implicitRole: "navigation"
|
|
1427
1584
|
},
|
|
1428
1585
|
permittedContent: ["@flow"],
|
|
1429
1586
|
permittedDescendants: [{ exclude: "main" }]
|
|
@@ -1455,7 +1612,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1455
1612
|
flow: true,
|
|
1456
1613
|
phrasing: true,
|
|
1457
1614
|
transparent: true,
|
|
1458
|
-
permittedDescendants: [{ exclude: "noscript" }]
|
|
1615
|
+
permittedDescendants: [{ exclude: "noscript" }],
|
|
1616
|
+
aria: {
|
|
1617
|
+
naming: "prohibited"
|
|
1618
|
+
}
|
|
1459
1619
|
},
|
|
1460
1620
|
object: {
|
|
1461
1621
|
flow: true,
|
|
@@ -1537,8 +1697,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1537
1697
|
enum: ["a", "A", "i", "I", "1"]
|
|
1538
1698
|
}
|
|
1539
1699
|
},
|
|
1540
|
-
|
|
1541
|
-
|
|
1700
|
+
aria: {
|
|
1701
|
+
implicitRole: "list"
|
|
1542
1702
|
},
|
|
1543
1703
|
permittedContent: ["@script", "li"]
|
|
1544
1704
|
},
|
|
@@ -1549,8 +1709,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1549
1709
|
boolean: true
|
|
1550
1710
|
}
|
|
1551
1711
|
},
|
|
1552
|
-
|
|
1553
|
-
|
|
1712
|
+
aria: {
|
|
1713
|
+
implicitRole: "group"
|
|
1554
1714
|
},
|
|
1555
1715
|
permittedContent: ["@script", "option"]
|
|
1556
1716
|
},
|
|
@@ -1573,8 +1733,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1573
1733
|
boolean: true
|
|
1574
1734
|
}
|
|
1575
1735
|
},
|
|
1576
|
-
|
|
1577
|
-
|
|
1736
|
+
aria: {
|
|
1737
|
+
implicitRole: "option"
|
|
1578
1738
|
},
|
|
1579
1739
|
permittedContent: []
|
|
1580
1740
|
},
|
|
@@ -1585,8 +1745,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1585
1745
|
listed: true
|
|
1586
1746
|
},
|
|
1587
1747
|
labelable: true,
|
|
1588
|
-
|
|
1589
|
-
|
|
1748
|
+
aria: {
|
|
1749
|
+
implicitRole: "status"
|
|
1590
1750
|
},
|
|
1591
1751
|
permittedContent: ["@phrasing"]
|
|
1592
1752
|
},
|
|
@@ -1625,6 +1785,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1625
1785
|
align: {
|
|
1626
1786
|
deprecated: true
|
|
1627
1787
|
}
|
|
1788
|
+
},
|
|
1789
|
+
aria: {
|
|
1790
|
+
implicitRole: "paragraph",
|
|
1791
|
+
naming: "prohibited"
|
|
1628
1792
|
}
|
|
1629
1793
|
},
|
|
1630
1794
|
param: {
|
|
@@ -1639,6 +1803,9 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1639
1803
|
valuetype: {
|
|
1640
1804
|
deprecated: true
|
|
1641
1805
|
}
|
|
1806
|
+
},
|
|
1807
|
+
aria: {
|
|
1808
|
+
naming: "prohibited"
|
|
1642
1809
|
}
|
|
1643
1810
|
},
|
|
1644
1811
|
picture: {
|
|
@@ -1646,7 +1813,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1646
1813
|
phrasing: true,
|
|
1647
1814
|
embedded: true,
|
|
1648
1815
|
permittedContent: ["@script", "source", "img"],
|
|
1649
|
-
permittedOrder: ["source", "img"]
|
|
1816
|
+
permittedOrder: ["source", "img"],
|
|
1817
|
+
aria: {
|
|
1818
|
+
naming: "prohibited"
|
|
1819
|
+
}
|
|
1650
1820
|
},
|
|
1651
1821
|
plaintext: {
|
|
1652
1822
|
deprecated: {
|
|
@@ -1662,14 +1832,18 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1662
1832
|
width: {
|
|
1663
1833
|
deprecated: true
|
|
1664
1834
|
}
|
|
1835
|
+
},
|
|
1836
|
+
aria: {
|
|
1837
|
+
implicitRole: "generic",
|
|
1838
|
+
naming: "prohibited"
|
|
1665
1839
|
}
|
|
1666
1840
|
},
|
|
1667
1841
|
progress: {
|
|
1668
1842
|
flow: true,
|
|
1669
1843
|
phrasing: true,
|
|
1670
1844
|
labelable: true,
|
|
1671
|
-
|
|
1672
|
-
|
|
1845
|
+
aria: {
|
|
1846
|
+
implicitRole: "progressbar"
|
|
1673
1847
|
},
|
|
1674
1848
|
permittedContent: ["@phrasing"],
|
|
1675
1849
|
permittedDescendants: [{ exclude: "progress" }]
|
|
@@ -1677,7 +1851,11 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1677
1851
|
q: {
|
|
1678
1852
|
flow: true,
|
|
1679
1853
|
phrasing: true,
|
|
1680
|
-
permittedContent: ["@phrasing"]
|
|
1854
|
+
permittedContent: ["@phrasing"],
|
|
1855
|
+
aria: {
|
|
1856
|
+
implicitRole: "generic",
|
|
1857
|
+
naming: "prohibited"
|
|
1858
|
+
}
|
|
1681
1859
|
},
|
|
1682
1860
|
rb: {
|
|
1683
1861
|
implicitClosed: ["rb", "rt", "rtc", "rp"],
|
|
@@ -1685,11 +1863,17 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1685
1863
|
},
|
|
1686
1864
|
rp: {
|
|
1687
1865
|
implicitClosed: ["rb", "rt", "rtc", "rp"],
|
|
1688
|
-
permittedContent: ["@phrasing"]
|
|
1866
|
+
permittedContent: ["@phrasing"],
|
|
1867
|
+
aria: {
|
|
1868
|
+
naming: "prohibited"
|
|
1869
|
+
}
|
|
1689
1870
|
},
|
|
1690
1871
|
rt: {
|
|
1691
1872
|
implicitClosed: ["rb", "rt", "rtc", "rp"],
|
|
1692
|
-
permittedContent: ["@phrasing"]
|
|
1873
|
+
permittedContent: ["@phrasing"],
|
|
1874
|
+
aria: {
|
|
1875
|
+
naming: "prohibited"
|
|
1876
|
+
}
|
|
1693
1877
|
},
|
|
1694
1878
|
rtc: {
|
|
1695
1879
|
implicitClosed: ["rb", "rtc", "rp"],
|
|
@@ -1703,12 +1887,20 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1703
1887
|
s: {
|
|
1704
1888
|
flow: true,
|
|
1705
1889
|
phrasing: true,
|
|
1706
|
-
permittedContent: ["@phrasing"]
|
|
1890
|
+
permittedContent: ["@phrasing"],
|
|
1891
|
+
aria: {
|
|
1892
|
+
implicitRole: "deletion",
|
|
1893
|
+
naming: "prohibited"
|
|
1894
|
+
}
|
|
1707
1895
|
},
|
|
1708
1896
|
samp: {
|
|
1709
1897
|
flow: true,
|
|
1710
1898
|
phrasing: true,
|
|
1711
|
-
permittedContent: ["@phrasing"]
|
|
1899
|
+
permittedContent: ["@phrasing"],
|
|
1900
|
+
aria: {
|
|
1901
|
+
implicitRole: "generic",
|
|
1902
|
+
naming: "prohibited"
|
|
1903
|
+
}
|
|
1712
1904
|
},
|
|
1713
1905
|
script: {
|
|
1714
1906
|
metadata: true,
|
|
@@ -1748,19 +1940,25 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1748
1940
|
src: {
|
|
1749
1941
|
enum: ["/.+/"]
|
|
1750
1942
|
}
|
|
1943
|
+
},
|
|
1944
|
+
aria: {
|
|
1945
|
+
naming: "prohibited"
|
|
1751
1946
|
}
|
|
1752
1947
|
},
|
|
1753
1948
|
search: {
|
|
1754
1949
|
flow: true,
|
|
1755
|
-
|
|
1756
|
-
|
|
1950
|
+
aria: {
|
|
1951
|
+
implicitRole: "search"
|
|
1757
1952
|
}
|
|
1758
1953
|
},
|
|
1759
1954
|
section: {
|
|
1760
1955
|
flow: true,
|
|
1761
1956
|
sectioning: true,
|
|
1762
|
-
|
|
1763
|
-
|
|
1957
|
+
aria: {
|
|
1958
|
+
implicitRole(node) {
|
|
1959
|
+
const name = node.hasAttribute("aria-label") || node.hasAttribute("aria-labelledby");
|
|
1960
|
+
return name ? "region" : "generic";
|
|
1961
|
+
}
|
|
1764
1962
|
},
|
|
1765
1963
|
permittedContent: ["@flow"]
|
|
1766
1964
|
},
|
|
@@ -1790,31 +1988,40 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1790
1988
|
enum: ["/\\d+/"]
|
|
1791
1989
|
}
|
|
1792
1990
|
},
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
}
|
|
1798
|
-
const size = node.getAttribute("size");
|
|
1799
|
-
if (typeof size === "string") {
|
|
1800
|
-
const parsed = parseInt(size, 10);
|
|
1801
|
-
if (parsed > 1) {
|
|
1991
|
+
aria: {
|
|
1992
|
+
implicitRole(node) {
|
|
1993
|
+
const multiple = node.hasAttribute("multiple");
|
|
1994
|
+
if (multiple) {
|
|
1802
1995
|
return "listbox";
|
|
1803
1996
|
}
|
|
1997
|
+
const size = node.getAttribute("size");
|
|
1998
|
+
if (typeof size === "string") {
|
|
1999
|
+
const parsed = parseInt(size, 10);
|
|
2000
|
+
if (parsed > 1) {
|
|
2001
|
+
return "listbox";
|
|
2002
|
+
}
|
|
2003
|
+
}
|
|
2004
|
+
return "combobox";
|
|
1804
2005
|
}
|
|
1805
|
-
return "combobox";
|
|
1806
2006
|
},
|
|
1807
2007
|
permittedContent: ["@script", "datasrc", "datafld", "dataformatas", "option", "optgroup"]
|
|
1808
2008
|
},
|
|
1809
2009
|
slot: {
|
|
1810
2010
|
flow: true,
|
|
1811
2011
|
phrasing: true,
|
|
1812
|
-
transparent: true
|
|
2012
|
+
transparent: true,
|
|
2013
|
+
aria: {
|
|
2014
|
+
naming: "prohibited"
|
|
2015
|
+
}
|
|
1813
2016
|
},
|
|
1814
2017
|
small: {
|
|
1815
2018
|
flow: true,
|
|
1816
2019
|
phrasing: true,
|
|
1817
|
-
permittedContent: ["@phrasing"]
|
|
2020
|
+
permittedContent: ["@phrasing"],
|
|
2021
|
+
aria: {
|
|
2022
|
+
implicitRole: "generic",
|
|
2023
|
+
naming: "prohibited"
|
|
2024
|
+
}
|
|
1818
2025
|
},
|
|
1819
2026
|
source: {
|
|
1820
2027
|
void: true,
|
|
@@ -1838,6 +2045,9 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1838
2045
|
allowed: allowedIfParentIsPresent("picture"),
|
|
1839
2046
|
enum: ["/\\d+/"]
|
|
1840
2047
|
}
|
|
2048
|
+
},
|
|
2049
|
+
aria: {
|
|
2050
|
+
naming: "prohibited"
|
|
1841
2051
|
}
|
|
1842
2052
|
},
|
|
1843
2053
|
spacer: {
|
|
@@ -1861,6 +2071,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1861
2071
|
datasrc: {
|
|
1862
2072
|
deprecated: true
|
|
1863
2073
|
}
|
|
2074
|
+
},
|
|
2075
|
+
aria: {
|
|
2076
|
+
implicitRole: "generic",
|
|
2077
|
+
naming: "prohibited"
|
|
1864
2078
|
}
|
|
1865
2079
|
},
|
|
1866
2080
|
strike: {
|
|
@@ -1873,29 +2087,50 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1873
2087
|
strong: {
|
|
1874
2088
|
flow: true,
|
|
1875
2089
|
phrasing: true,
|
|
1876
|
-
permittedContent: ["@phrasing"]
|
|
2090
|
+
permittedContent: ["@phrasing"],
|
|
2091
|
+
aria: {
|
|
2092
|
+
implicitRole: "strong",
|
|
2093
|
+
naming: "prohibited"
|
|
2094
|
+
}
|
|
1877
2095
|
},
|
|
1878
2096
|
style: {
|
|
1879
|
-
metadata: true
|
|
2097
|
+
metadata: true,
|
|
2098
|
+
aria: {
|
|
2099
|
+
naming: "prohibited"
|
|
2100
|
+
}
|
|
1880
2101
|
},
|
|
1881
2102
|
sub: {
|
|
1882
2103
|
flow: true,
|
|
1883
2104
|
phrasing: true,
|
|
1884
|
-
permittedContent: ["@phrasing"]
|
|
2105
|
+
permittedContent: ["@phrasing"],
|
|
2106
|
+
aria: {
|
|
2107
|
+
implicitRole: "subscript",
|
|
2108
|
+
naming: "prohibited"
|
|
2109
|
+
}
|
|
1885
2110
|
},
|
|
1886
2111
|
summary: {
|
|
1887
|
-
permittedContent: ["@phrasing", "@heading"]
|
|
2112
|
+
permittedContent: ["@phrasing", "@heading"],
|
|
2113
|
+
aria: {
|
|
2114
|
+
implicitRole: "button"
|
|
2115
|
+
}
|
|
1888
2116
|
},
|
|
1889
2117
|
sup: {
|
|
1890
2118
|
flow: true,
|
|
1891
2119
|
phrasing: true,
|
|
1892
|
-
permittedContent: ["@phrasing"]
|
|
2120
|
+
permittedContent: ["@phrasing"],
|
|
2121
|
+
aria: {
|
|
2122
|
+
implicitRole: "superscript",
|
|
2123
|
+
naming: "prohibited"
|
|
2124
|
+
}
|
|
1893
2125
|
},
|
|
1894
2126
|
svg: {
|
|
1895
2127
|
flow: true,
|
|
1896
2128
|
foreign: true,
|
|
1897
2129
|
phrasing: true,
|
|
1898
|
-
embedded: true
|
|
2130
|
+
embedded: true,
|
|
2131
|
+
aria: {
|
|
2132
|
+
implicitRole: "graphics-document"
|
|
2133
|
+
}
|
|
1899
2134
|
},
|
|
1900
2135
|
/* while not part of HTML 5 specification these two elements are handled as
|
|
1901
2136
|
* special cases to allow them as accessible text and to avoid issues with
|
|
@@ -1947,8 +2182,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1947
2182
|
deprecated: true
|
|
1948
2183
|
}
|
|
1949
2184
|
},
|
|
1950
|
-
|
|
1951
|
-
|
|
2185
|
+
aria: {
|
|
2186
|
+
implicitRole: "table"
|
|
1952
2187
|
}
|
|
1953
2188
|
},
|
|
1954
2189
|
tbody: {
|
|
@@ -1971,8 +2206,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
1971
2206
|
deprecated: true
|
|
1972
2207
|
}
|
|
1973
2208
|
},
|
|
1974
|
-
|
|
1975
|
-
|
|
2209
|
+
aria: {
|
|
2210
|
+
implicitRole: "rowgroup"
|
|
1976
2211
|
}
|
|
1977
2212
|
},
|
|
1978
2213
|
td: {
|
|
@@ -2019,13 +2254,19 @@ var html5 = metaHelper.defineMetadata({
|
|
|
2019
2254
|
deprecated: true
|
|
2020
2255
|
}
|
|
2021
2256
|
},
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2257
|
+
aria: {
|
|
2258
|
+
implicitRole(node) {
|
|
2259
|
+
const table = node.closest("table");
|
|
2260
|
+
const tableRole = (table == null ? void 0 : table.getAttribute("role")) ?? "table";
|
|
2261
|
+
switch (tableRole) {
|
|
2262
|
+
case "table":
|
|
2263
|
+
return "cell";
|
|
2264
|
+
case "grid":
|
|
2265
|
+
case "treegrid":
|
|
2266
|
+
return "gridcell";
|
|
2267
|
+
default:
|
|
2268
|
+
return null;
|
|
2269
|
+
}
|
|
2029
2270
|
}
|
|
2030
2271
|
},
|
|
2031
2272
|
permittedContent: ["@flow"]
|
|
@@ -2034,7 +2275,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
2034
2275
|
metadata: true,
|
|
2035
2276
|
flow: true,
|
|
2036
2277
|
phrasing: true,
|
|
2037
|
-
scriptSupporting: true
|
|
2278
|
+
scriptSupporting: true,
|
|
2279
|
+
aria: {
|
|
2280
|
+
naming: "prohibited"
|
|
2281
|
+
}
|
|
2038
2282
|
},
|
|
2039
2283
|
textarea: {
|
|
2040
2284
|
flow: true,
|
|
@@ -2086,8 +2330,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
2086
2330
|
enum: ["hard", "soft"]
|
|
2087
2331
|
}
|
|
2088
2332
|
},
|
|
2089
|
-
|
|
2090
|
-
|
|
2333
|
+
aria: {
|
|
2334
|
+
implicitRole: "textbox"
|
|
2091
2335
|
},
|
|
2092
2336
|
permittedContent: []
|
|
2093
2337
|
},
|
|
@@ -2111,8 +2355,8 @@ var html5 = metaHelper.defineMetadata({
|
|
|
2111
2355
|
deprecated: true
|
|
2112
2356
|
}
|
|
2113
2357
|
},
|
|
2114
|
-
|
|
2115
|
-
|
|
2358
|
+
aria: {
|
|
2359
|
+
implicitRole: "rowgroup"
|
|
2116
2360
|
}
|
|
2117
2361
|
},
|
|
2118
2362
|
th: {
|
|
@@ -2159,23 +2403,22 @@ var html5 = metaHelper.defineMetadata({
|
|
|
2159
2403
|
deprecated: true
|
|
2160
2404
|
}
|
|
2161
2405
|
},
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
return tableRole === "table" ? "cell" : "gridcell";
|
|
2406
|
+
aria: {
|
|
2407
|
+
implicitRole(node) {
|
|
2408
|
+
const table = node.closest("table");
|
|
2409
|
+
const tableRole = (table == null ? void 0 : table.getAttribute("role")) ?? "table";
|
|
2410
|
+
if (typeof tableRole !== "string" || !["table", "grid", "treegrid"].includes(tableRole)) {
|
|
2411
|
+
return null;
|
|
2412
|
+
}
|
|
2413
|
+
const scope = node.getAttribute("scope");
|
|
2414
|
+
switch (scope) {
|
|
2415
|
+
case "col":
|
|
2416
|
+
return "columnheader";
|
|
2417
|
+
case "row":
|
|
2418
|
+
return "rowheader";
|
|
2419
|
+
default:
|
|
2420
|
+
return tableRole === "table" ? "cell" : "gridcell";
|
|
2421
|
+
}
|
|
2179
2422
|
}
|
|
2180
2423
|
},
|
|
2181
2424
|
permittedContent: ["@flow"],
|
|
@@ -2201,22 +2444,26 @@ var html5 = metaHelper.defineMetadata({
|
|
|
2201
2444
|
deprecated: true
|
|
2202
2445
|
}
|
|
2203
2446
|
},
|
|
2204
|
-
|
|
2205
|
-
|
|
2447
|
+
aria: {
|
|
2448
|
+
implicitRole: "rowgroup"
|
|
2206
2449
|
}
|
|
2207
2450
|
},
|
|
2208
2451
|
time: {
|
|
2209
2452
|
flow: true,
|
|
2210
2453
|
phrasing: true,
|
|
2211
|
-
|
|
2212
|
-
|
|
2454
|
+
aria: {
|
|
2455
|
+
implicitRole: "time",
|
|
2456
|
+
naming: "prohibited"
|
|
2213
2457
|
},
|
|
2214
2458
|
permittedContent: ["@phrasing"]
|
|
2215
2459
|
},
|
|
2216
2460
|
title: {
|
|
2217
2461
|
metadata: true,
|
|
2218
2462
|
permittedContent: [],
|
|
2219
|
-
permittedParent: ["head"]
|
|
2463
|
+
permittedParent: ["head"],
|
|
2464
|
+
aria: {
|
|
2465
|
+
naming: "prohibited"
|
|
2466
|
+
}
|
|
2220
2467
|
},
|
|
2221
2468
|
tr: {
|
|
2222
2469
|
implicitClosed: ["tr"],
|
|
@@ -2241,12 +2488,15 @@ var html5 = metaHelper.defineMetadata({
|
|
|
2241
2488
|
deprecated: true
|
|
2242
2489
|
}
|
|
2243
2490
|
},
|
|
2244
|
-
|
|
2245
|
-
|
|
2491
|
+
aria: {
|
|
2492
|
+
implicitRole: "row"
|
|
2246
2493
|
}
|
|
2247
2494
|
},
|
|
2248
2495
|
track: {
|
|
2249
|
-
void: true
|
|
2496
|
+
void: true,
|
|
2497
|
+
aria: {
|
|
2498
|
+
naming: "prohibited"
|
|
2499
|
+
}
|
|
2250
2500
|
},
|
|
2251
2501
|
tt: {
|
|
2252
2502
|
deprecated: {
|
|
@@ -2257,7 +2507,11 @@ var html5 = metaHelper.defineMetadata({
|
|
|
2257
2507
|
u: {
|
|
2258
2508
|
flow: true,
|
|
2259
2509
|
phrasing: true,
|
|
2260
|
-
permittedContent: ["@phrasing"]
|
|
2510
|
+
permittedContent: ["@phrasing"],
|
|
2511
|
+
aria: {
|
|
2512
|
+
implicitRole: "generic",
|
|
2513
|
+
naming: "prohibited"
|
|
2514
|
+
}
|
|
2261
2515
|
},
|
|
2262
2516
|
ul: {
|
|
2263
2517
|
flow: true,
|
|
@@ -2270,14 +2524,17 @@ var html5 = metaHelper.defineMetadata({
|
|
|
2270
2524
|
deprecated: true
|
|
2271
2525
|
}
|
|
2272
2526
|
},
|
|
2273
|
-
|
|
2274
|
-
|
|
2527
|
+
aria: {
|
|
2528
|
+
implicitRole: "list"
|
|
2275
2529
|
}
|
|
2276
2530
|
},
|
|
2277
2531
|
var: {
|
|
2278
2532
|
flow: true,
|
|
2279
2533
|
phrasing: true,
|
|
2280
|
-
permittedContent: ["@phrasing"]
|
|
2534
|
+
permittedContent: ["@phrasing"],
|
|
2535
|
+
aria: {
|
|
2536
|
+
naming: "prohibited"
|
|
2537
|
+
}
|
|
2281
2538
|
},
|
|
2282
2539
|
video: {
|
|
2283
2540
|
flow: true,
|
|
@@ -2308,7 +2565,10 @@ var html5 = metaHelper.defineMetadata({
|
|
|
2308
2565
|
wbr: {
|
|
2309
2566
|
flow: true,
|
|
2310
2567
|
phrasing: true,
|
|
2311
|
-
void: true
|
|
2568
|
+
void: true,
|
|
2569
|
+
aria: {
|
|
2570
|
+
naming: "prohibited"
|
|
2571
|
+
}
|
|
2312
2572
|
},
|
|
2313
2573
|
xmp: {
|
|
2314
2574
|
deprecated: {
|