testaro-issues 0.2.1 → 0.4.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/index.mjs CHANGED
@@ -8,7 +8,7 @@ const issuesData = {
8
8
  },
9
9
  "duplicateAttribute": {
10
10
  "summary": "duplicate attribute",
11
- "why": "Browser processes the document improperly",
11
+ "why": "Browser processes the page improperly",
12
12
  "wcag": "4.1.1",
13
13
  "weight": 2
14
14
  },
@@ -38,7 +38,7 @@ const issuesData = {
38
38
  },
39
39
  "regionNoText": {
40
40
  "summary": "region not named",
41
- "why": "User cannot get help surveying the parts of the document",
41
+ "why": "User cannot get help surveying the parts of the page",
42
42
  "wcag": "4.1.2",
43
43
  "weight": 4
44
44
  },
@@ -151,7 +151,7 @@ const issuesData = {
151
151
  "weight": 4
152
152
  },
153
153
  "gapBad": {
154
- "summary": "CSS padding invalid",
154
+ "summary": "CSS gap invalid",
155
155
  "why": "Content is displayed improperly",
156
156
  "wcag": "4.1",
157
157
  "weight": 4
@@ -212,14 +212,14 @@ const issuesData = {
212
212
  },
213
213
  "pageLanguage": {
214
214
  "summary": "page language missing",
215
- "why": "Speaking helper may mispronounce the document text",
215
+ "why": "Speaking helper may mispronounce the page text",
216
216
  "wcag": "3.1.1",
217
217
  "weight": 4,
218
218
  "max": 1
219
219
  },
220
220
  "pageLanguageBad": {
221
221
  "summary": "page language invalid",
222
- "why": "Speaking helper may mispronounce the document text",
222
+ "why": "Speaking helper may mispronounce the page text",
223
223
  "wcag": "3.1.1",
224
224
  "weight": 4,
225
225
  "max": 1
@@ -298,7 +298,7 @@ const issuesData = {
298
298
  },
299
299
  "internalLinkBroken": {
300
300
  "summary": "internal link broken",
301
- "why": "User cannot reach a promised document location",
301
+ "why": "User cannot reach a promised page location",
302
302
  "wcag": "1.3.1",
303
303
  "weight": 4
304
304
  },
@@ -496,7 +496,7 @@ const issuesData = {
496
496
  },
497
497
  "pageNewWindow": {
498
498
  "summary": "page immediately opens window",
499
- "why": "User promised a document gets another document, too",
499
+ "why": "User promised a page gets another page, too",
500
500
  "wcag": "3.2.5",
501
501
  "weight": 3,
502
502
  "max": 1
@@ -606,7 +606,7 @@ const issuesData = {
606
606
  },
607
607
  "metaBansZoom": {
608
608
  "summary": "meta bans zoom",
609
- "why": "User cannot adjust the document size for readability",
609
+ "why": "User cannot adjust the page size for readability",
610
610
  "wcag": "1.4.4",
611
611
  "weight": 4,
612
612
  "max": 1
@@ -690,7 +690,7 @@ const issuesData = {
690
690
  "weight": 4
691
691
  },
692
692
  "linkElementMisplaced": {
693
- "summary": "link element invalid",
693
+ "summary": "link element misplaced",
694
694
  "why": "Document fails to get a needed external resource",
695
695
  "wcag": "1.3.1",
696
696
  "weight": 4
@@ -701,39 +701,63 @@ const issuesData = {
701
701
  "wcag": "1.3.1",
702
702
  "weight": 4
703
703
  },
704
- "metaBad": {
705
- "summary": "meta invalid",
706
- "why": "Document fails to include needed data",
707
- "wcag": "1.3.1",
704
+ "metaAttributesWrong": {
705
+ "summary": "prohibited or missing meta attributes",
706
+ "why": "Browser processes the page incorrectly",
707
+ "wcag": "4.1",
708
+ "weight": 3
709
+ },
710
+ "metaAttributeBad": {
711
+ "summary": "meta attribute value invalid",
712
+ "why": "Browser processes the page incorrectly",
713
+ "wcag": "4.1",
714
+ "weight": 3
715
+ },
716
+ "metaDuplicated": {
717
+ "summary": "meta element duplicated",
718
+ "why": "Browser may process the page incorrectly",
719
+ "wcag": "4.1",
720
+ "weight": 3
721
+ },
722
+ "metaCharsetLate": {
723
+ "summary": "meta charset declared too late",
724
+ "why": "Browser may display incorrect text",
725
+ "wcag": "4.1",
726
+ "weight": 4
727
+ },
728
+ "metaXUACompatible": {
729
+ "summary": "meta X-UA-Compatible incomplete",
730
+ "why": "Internet Explorer may display the page incorrectly",
731
+ "wcag": "4.1",
708
732
  "weight": 3
709
733
  },
710
734
  "metaMisplaced": {
711
735
  "summary": "meta element in invalid location",
712
- "why": "Document fails to provide needed data",
713
- "wcag": "1.3.1",
736
+ "why": "Browser may process the page incorrectly",
737
+ "wcag": "4.1",
714
738
  "weight": 4
715
739
  },
716
740
  "stylesheetBanned": {
717
741
  "summary": "stylesheet prohibited",
718
- "why": "Browser displays the document improperly",
742
+ "why": "Browser displays the page improperly",
719
743
  "wcag": "1.4",
720
744
  "weight": 3
721
745
  },
722
746
  "scriptNotDeferrable": {
723
747
  "summary": "script element invalidly deferred",
724
- "why": "Browser processes the document improperly",
748
+ "why": "Browser processes the page improperly",
725
749
  "wcag": "1.3.1",
726
750
  "weight": 4
727
751
  },
728
752
  "scriptBanned": {
729
753
  "summary": "script prohibited",
730
- "why": "Browser processes the document improperly",
754
+ "why": "Browser processes the page improperly",
731
755
  "wcag": "4.1",
732
756
  "weight": 3
733
757
  },
734
758
  "scriptElementBad": {
735
759
  "summary": "script element invalid",
736
- "why": "Browser processes the document improperly",
760
+ "why": "Browser processes the page improperly",
737
761
  "wcag": "1.3.1",
738
762
  "weight": 4
739
763
  },
@@ -757,7 +781,7 @@ const issuesData = {
757
781
  },
758
782
  "iframeTitleBad": {
759
783
  "summary": "iframe not named",
760
- "why": "User cannot get help on the topic of an embedded document",
784
+ "why": "User cannot get help on the topic of an embedded page",
761
785
  "wcag": "4.1.2",
762
786
  "weight": 4
763
787
  },
@@ -955,13 +979,13 @@ const issuesData = {
955
979
  },
956
980
  "headingEmpty": {
957
981
  "summary": "heading empty",
958
- "why": "User cannot get help on the topic of a part of the document",
982
+ "why": "User cannot get help on the topic of a part of the page",
959
983
  "wcag": "2.4.6",
960
984
  "weight": 3
961
985
  },
962
986
  "headingOfNothing": {
963
987
  "summary": "heading heads nothing",
964
- "why": "Helper misdescribes the document",
988
+ "why": "Helper misdescribes the page",
965
989
  "wcag": "1.3.1",
966
990
  "weight": 2
967
991
  },
@@ -1003,112 +1027,112 @@ const issuesData = {
1003
1027
  },
1004
1028
  "docTypeMissing": {
1005
1029
  "summary": "DOCTYPE missing",
1006
- "why": "Browser processes the document improperly",
1030
+ "why": "Browser processes the page improperly",
1007
1031
  "wcag": "1.3.1",
1008
1032
  "weight": 4,
1009
1033
  "max": 1
1010
1034
  },
1011
1035
  "docTypeMisplaced": {
1012
1036
  "summary": "DOCTYPE in invalid location",
1013
- "why": "Browser processes the document improperly",
1037
+ "why": "Browser processes the page improperly",
1014
1038
  "wcag": "1.3.1",
1015
1039
  "weight": 4,
1016
1040
  "max": 1
1017
1041
  },
1018
1042
  "docTypeBad": {
1019
1043
  "summary": "DOCTYPE invalid",
1020
- "why": "Browser processes the document improperly",
1044
+ "why": "Browser processes the page improperly",
1021
1045
  "wcag": "1.3.1",
1022
1046
  "weight": 3,
1023
1047
  "max": 1
1024
1048
  },
1025
1049
  "pageTitleBad": {
1026
1050
  "summary": "page title invalid",
1027
- "why": "Browser processes the document improperly",
1051
+ "why": "Browser processes the page improperly",
1028
1052
  "wcag": "1.3.1",
1029
1053
  "weight": 3,
1030
1054
  "max": 1
1031
1055
  },
1032
1056
  "pageTitle": {
1033
1057
  "summary": "page title missing",
1034
- "why": "User is not informed of the topic of the document",
1058
+ "why": "User is not informed of the topic of the page",
1035
1059
  "wcag": "2.4.2",
1036
1060
  "weight": 4,
1037
1061
  "max": 1
1038
1062
  },
1039
1063
  "headElementsBad": {
1040
1064
  "summary": "element in head invalid",
1041
- "why": "Browser processes the document improperly",
1065
+ "why": "Browser processes the page improperly",
1042
1066
  "wcag": "4.1.1",
1043
1067
  "weight": 3
1044
1068
  },
1045
1069
  "headingLevelSkip": {
1046
1070
  "summary": "heading level skipped",
1047
- "why": "Helper misdescribes the document",
1071
+ "why": "Helper misdescribes the page",
1048
1072
  "wcag": "1.3.1",
1049
1073
  "weight": 2
1050
1074
  },
1051
1075
  "headingStructure": {
1052
1076
  "summary": "heading structure illogical",
1053
- "why": "Helper misdescribes the document",
1077
+ "why": "Helper misdescribes the page",
1054
1078
  "wcag": "1.3.1",
1055
1079
  "weight": 2
1056
1080
  },
1057
1081
  "headingConfusion": {
1058
1082
  "summary": "heading names repeated",
1059
- "why": "User cannot differentiate parts of the document",
1083
+ "why": "User cannot differentiate parts of the page",
1060
1084
  "wcag": "1.3.1",
1061
1085
  "weight": 2
1062
1086
  },
1063
1087
  "headingMisuseRisk": {
1064
1088
  "summary": "heading used for styling?",
1065
- "why": "User cannot understand the document structure",
1089
+ "why": "User cannot understand the page structure",
1066
1090
  "wcag": "1.3.1",
1067
1091
  "weight": 2
1068
1092
  },
1069
1093
  "headingNone": {
1070
1094
  "summary": "headings missing",
1071
- "why": "User cannot survey parts of the document",
1095
+ "why": "User cannot survey parts of the page",
1072
1096
  "wcag": "1.3.1",
1073
1097
  "weight": 3,
1074
1098
  "max": 1
1075
1099
  },
1076
1100
  "h1Not1": {
1077
1101
  "summary": "not exactly 1 h1 heading",
1078
- "why": "User cannot understand the topic of the document",
1102
+ "why": "User cannot understand the topic of the page",
1079
1103
  "wcag": "1.3.1",
1080
1104
  "weight": 2,
1081
1105
  "max": 1
1082
1106
  },
1083
1107
  "h1Not1st": {
1084
1108
  "summary": "h1 not 1st heading",
1085
- "why": "User cannot understand the topic of the document",
1109
+ "why": "User cannot understand the topic of the page",
1086
1110
  "wcag": "1.3.1",
1087
1111
  "weight": 3,
1088
1112
  "max": 1
1089
1113
  },
1090
1114
  "docHeadingNotH1": {
1091
1115
  "summary": "primary heading not h1",
1092
- "why": "User cannot understand the topic of the document",
1116
+ "why": "User cannot understand the topic of the page",
1093
1117
  "wcag": "1.3.1",
1094
1118
  "weight": 2,
1095
1119
  "max": 1
1096
1120
  },
1097
1121
  "articleHeadingless": {
1098
1122
  "summary": "article heading missing",
1099
- "why": "User cannot understand the topic of a part of the document",
1123
+ "why": "User cannot understand the topic of a part of the page",
1100
1124
  "wcag": "1.3.1",
1101
1125
  "weight": 1
1102
1126
  },
1103
1127
  "sectionHeadingless": {
1104
1128
  "summary": "section heading missing",
1105
- "why": "User cannot understand the topic of a part of the document",
1129
+ "why": "User cannot understand the topic of a part of the page",
1106
1130
  "wcag": "1.3.1",
1107
1131
  "weight": 1
1108
1132
  },
1109
1133
  "headingLength": {
1110
1134
  "summary": "heading abnormally long",
1111
- "why": "User has difficulty understanding the topic of a part of the document",
1135
+ "why": "User has difficulty understanding the topic of a part of the page",
1112
1136
  "wcag": "1.3.1",
1113
1137
  "weight": 1
1114
1138
  },
@@ -1138,7 +1162,7 @@ const issuesData = {
1138
1162
  },
1139
1163
  "hrConfusionRisk": {
1140
1164
  "summary": "hr misused",
1141
- "why": "User cannot get help on the nature of segments of the document",
1165
+ "why": "User cannot get help on the nature of segments of the page",
1142
1166
  "wcag": "1.3.1",
1143
1167
  "weight": 1
1144
1168
  },
@@ -1156,7 +1180,7 @@ const issuesData = {
1156
1180
  },
1157
1181
  "pseudoHeadingRisk": {
1158
1182
  "summary": "heading-like styles dubious",
1159
- "why": "User may be unable to understand the topic of a part of the document",
1183
+ "why": "User may be unable to understand the topic of a part of the page",
1160
1184
  "wcag": "1.3.1",
1161
1185
  "weight": 1
1162
1186
  },
@@ -1486,7 +1510,7 @@ const issuesData = {
1486
1510
  },
1487
1511
  "visibleBulk": {
1488
1512
  "summary": "large visible-element count",
1489
- "why": "User cannot easily find items in the document",
1513
+ "why": "User cannot easily find items in the page",
1490
1514
  "wcag": "2.4",
1491
1515
  "weight": 1,
1492
1516
  "max": 1
@@ -1553,90 +1577,90 @@ const issuesData = {
1553
1577
  },
1554
1578
  "noLandmarks": {
1555
1579
  "summary": "no landmarks",
1556
- "why": "User cannot get help on how the document is organized",
1580
+ "why": "User cannot get help on how the page is organized",
1557
1581
  "wcag": "1.3.6",
1558
1582
  "weight": 2,
1559
1583
  "max": 1
1560
1584
  },
1561
1585
  "contentBeyondLandmarks": {
1562
1586
  "summary": "content beyond landmarks",
1563
- "why": "User cannot get help on how some of the document is organized",
1587
+ "why": "User cannot get help on how some of the page is organized",
1564
1588
  "wcag": "1.3.6",
1565
1589
  "weight": 1
1566
1590
  },
1567
1591
  "footerNotTop": {
1568
1592
  "summary": "footer child of landmark",
1569
- "why": "User cannot get help on how some of the document is organized",
1593
+ "why": "User cannot get help on how some of the page is organized",
1570
1594
  "wcag": "1.3.6",
1571
1595
  "weight": 1
1572
1596
  },
1573
1597
  "asideNotTop": {
1574
1598
  "summary": "aside child of landmark",
1575
- "why": "User cannot get help on how some of the document is organized",
1599
+ "why": "User cannot get help on how some of the page is organized",
1576
1600
  "wcag": "1.3.6",
1577
1601
  "weight": 2
1578
1602
  },
1579
1603
  "mainNotTop": {
1580
1604
  "summary": "main child of landmark",
1581
- "why": "User cannot get help on how some of the document is organized",
1605
+ "why": "User cannot get help on how some of the page is organized",
1582
1606
  "wcag": "1.3.6",
1583
1607
  "weight": 2
1584
1608
  },
1585
1609
  "mainConfusion": {
1586
1610
  "summary": "mains not distinctly named",
1587
- "why": "User cannot get help on how some of the document is organized",
1611
+ "why": "User cannot get help on how some of the page is organized",
1588
1612
  "wcag": "1.3.6",
1589
1613
  "weight": 3
1590
1614
  },
1591
1615
  "mainNone": {
1592
1616
  "summary": "main missing",
1593
- "why": "User cannot get help on how some of the document is organized",
1617
+ "why": "User cannot get help on how some of the page is organized",
1594
1618
  "wcag": "1.3.6",
1595
1619
  "weight": 2,
1596
1620
  "max": 1
1597
1621
  },
1598
1622
  "mainNot1": {
1599
1623
  "summary": "multiple mains",
1600
- "why": "User cannot get help on how some of the document is organized",
1624
+ "why": "User cannot get help on how some of the page is organized",
1601
1625
  "wcag": "1.3.6",
1602
1626
  "weight": 2,
1603
1627
  "max": 1
1604
1628
  },
1605
1629
  "bannerNot1": {
1606
1630
  "summary": "multiple banners",
1607
- "why": "User cannot get help on how some of the document is organized",
1631
+ "why": "User cannot get help on how some of the page is organized",
1608
1632
  "wcag": "1.3.6",
1609
1633
  "weight": 2,
1610
1634
  "max": 1
1611
1635
  },
1612
1636
  "bannerNotTop": {
1613
1637
  "summary": "banner child of landmark",
1614
- "why": "User cannot get help on how some of the document is organized",
1638
+ "why": "User cannot get help on how some of the page is organized",
1615
1639
  "wcag": "1.3.6",
1616
1640
  "weight": 2
1617
1641
  },
1618
1642
  "footerConfusion": {
1619
1643
  "summary": "contentinfos not distinctly named",
1620
- "why": "User cannot get help on how some of the document is organized",
1644
+ "why": "User cannot get help on how some of the page is organized",
1621
1645
  "wcag": "1.3.6",
1622
1646
  "weight": 3
1623
1647
  },
1624
1648
  "footerNot1": {
1625
1649
  "summary": "multiple contentinfos",
1626
- "why": "User cannot get help on how some of the document is organized",
1650
+ "why": "User cannot get help on how some of the page is organized",
1627
1651
  "wcag": "1.3.6",
1628
1652
  "weight": 2,
1629
1653
  "max": 1
1630
1654
  },
1631
1655
  "landmarkConfusion": {
1632
1656
  "summary": "landmarks not distinctly named",
1633
- "why": "User cannot get help on how some of the document is organized",
1657
+ "why": "User cannot get help on how some of the page is organized",
1634
1658
  "wcag": "1.3.6",
1635
1659
  "weight": 3
1636
1660
  },
1637
1661
  "documentConfusion": {
1638
- "summary": "document elements not distinctly named",
1639
- "why": "User cannot get help on how some of the document is organized",
1662
+ "summary": "page elements not distinctly named",
1663
+ "why": "User cannot get help on how some of the page is organized",
1640
1664
  "wcag": "1.3.6",
1641
1665
  "weight": 3
1642
1666
  },
@@ -1648,61 +1672,61 @@ const issuesData = {
1648
1672
  },
1649
1673
  "formConfusion": {
1650
1674
  "summary": "forms not distinctly named",
1651
- "why": "User cannot get help on how some of the document is organized",
1675
+ "why": "User cannot get help on how some of the page is organized",
1652
1676
  "wcag": "1.3.6",
1653
1677
  "weight": 3
1654
1678
  },
1655
1679
  "applicationNoText": {
1656
1680
  "summary": "application not named",
1657
- "why": "User cannot get help on how some of the document is organized",
1681
+ "why": "User cannot get help on how some of the page is organized",
1658
1682
  "wcag": "1.3.6",
1659
1683
  "weight": 4
1660
1684
  },
1661
1685
  "applicationConfusion": {
1662
1686
  "summary": "applications not distinctly named",
1663
- "why": "User cannot get help on how some of the document is organized",
1687
+ "why": "User cannot get help on how some of the page is organized",
1664
1688
  "wcag": "1.3.6",
1665
1689
  "weight": 3
1666
1690
  },
1667
1691
  "asideConfusion": {
1668
1692
  "summary": "asides not distinctly named",
1669
- "why": "User cannot get help on how some of the document is organized",
1693
+ "why": "User cannot get help on how some of the page is organized",
1670
1694
  "wcag": "1.3.6",
1671
1695
  "weight": 3
1672
1696
  },
1673
1697
  "bannerConfusion": {
1674
1698
  "summary": "banners not distinctly named",
1675
- "why": "User cannot get help on how some of the document is organized",
1699
+ "why": "User cannot get help on how some of the page is organized",
1676
1700
  "wcag": "1.3.6",
1677
1701
  "weight": 3
1678
1702
  },
1679
1703
  "navConfusion": {
1680
1704
  "summary": "navigations not distinctly named",
1681
- "why": "User cannot get help on how some of the document is organized",
1705
+ "why": "User cannot get help on how some of the page is organized",
1682
1706
  "wcag": "1.3.6",
1683
1707
  "weight": 3
1684
1708
  },
1685
1709
  "landmarkInNav": {
1686
1710
  "summary": "invalid landmark child of navigation role",
1687
- "why": "User cannot get help on how some of the document is organized",
1711
+ "why": "User cannot get help on how some of the page is organized",
1688
1712
  "wcag": "1.3.6",
1689
1713
  "weight": 4
1690
1714
  },
1691
1715
  "regionConfusion": {
1692
1716
  "summary": "regions not distinctly named",
1693
- "why": "User cannot get help on how some of the document is organized",
1717
+ "why": "User cannot get help on how some of the page is organized",
1694
1718
  "wcag": "1.3.6",
1695
1719
  "weight": 3
1696
1720
  },
1697
1721
  "searchConfusion": {
1698
1722
  "summary": "searches not distinctly named",
1699
- "why": "User cannot get help on how some of the document is organized",
1723
+ "why": "User cannot get help on how some of the page is organized",
1700
1724
  "wcag": "1.3.6",
1701
1725
  "weight": 3
1702
1726
  },
1703
1727
  "complementaryNoText": {
1704
1728
  "summary": "complementary not named",
1705
- "why": "User cannot get help on how some of the document is organized",
1729
+ "why": "User cannot get help on how some of the page is organized",
1706
1730
  "wcag": "1.3.6",
1707
1731
  "weight": 1
1708
1732
  },
@@ -1762,14 +1786,14 @@ const issuesData = {
1762
1786
  },
1763
1787
  "contentHidden": {
1764
1788
  "summary": "page hidden",
1765
- "why": "User cannot get the document content",
1789
+ "why": "User cannot get the page content",
1766
1790
  "wcag": "2.4.7",
1767
1791
  "weight": 4,
1768
1792
  "max": 1
1769
1793
  },
1770
1794
  "hideFailureRisk": {
1771
1795
  "summary": "false aria-hidden value risky",
1772
- "why": "User may be misled by erroneously hidden or revealed document content",
1796
+ "why": "User may be misled by erroneously hidden or revealed page content",
1773
1797
  "wcag": "2.4.6",
1774
1798
  "weight": 1
1775
1799
  },
@@ -1787,19 +1811,19 @@ const issuesData = {
1787
1811
  },
1788
1812
  "hoverIndication": {
1789
1813
  "summary": "hover indication poor",
1790
- "why": "User cannot explore the document reliably with a mouse",
1814
+ "why": "User cannot explore the page reliably with a mouse",
1791
1815
  "wcag": "3.3.2",
1792
1816
  "weight": 3
1793
1817
  },
1794
1818
  "hoverSurprise": {
1795
1819
  "summary": "hovering changes content",
1796
- "why": "User cannot explore the document reliably with a mouse",
1820
+ "why": "User cannot explore the page reliably with a mouse",
1797
1821
  "wcag": "3.2.5",
1798
1822
  "weight": 1
1799
1823
  },
1800
1824
  "formSurpriseRisk": {
1801
1825
  "summary": "form interaction changes content?",
1802
- "why": "User experiences unexpected document change when using a form",
1826
+ "why": "User experiences unexpected page change when using a form",
1803
1827
  "wcag": "3.2.5",
1804
1828
  "weight": 1
1805
1829
  },
@@ -2046,14 +2070,14 @@ const issuesData = {
2046
2070
  },
2047
2071
  "skipRepeatedContent": {
2048
2072
  "summary": "skip method missing or invalid",
2049
- "why": "Keyboard-only user cannot easily reach the specific content of the document",
2073
+ "why": "Keyboard-only user cannot easily reach the specific content of the page",
2050
2074
  "wcag": "2.4.1",
2051
2075
  "weight": 3,
2052
2076
  "max": 2
2053
2077
  },
2054
2078
  "repeatedContentRisk": {
2055
2079
  "summary": "skip method missing or invalid?",
2056
- "why": "Keyboard-only user may be unable easily to reach the specific content of the document",
2080
+ "why": "Keyboard-only user may be unable easily to reach the specific content of the page",
2057
2081
  "wcag": "2.4.1",
2058
2082
  "weight": 1,
2059
2083
  "max": 2
@@ -2145,25 +2169,25 @@ const issuesData = {
2145
2169
  },
2146
2170
  "characterBad": {
2147
2171
  "summary": "invalid character",
2148
- "why": "Invalid character makes the document behave incorrectly",
2172
+ "why": "Invalid character makes the page behave incorrectly",
2149
2173
  "wcag": "4.1",
2150
2174
  "weight": 3
2151
2175
  },
2152
2176
  "entityBad": {
2153
2177
  "summary": "named character reference invalid",
2154
- "why": "User may be unable to read all the document text",
2178
+ "why": "User may be unable to read all the page text",
2155
2179
  "wcag": "4.1",
2156
2180
  "weight": 4
2157
2181
  },
2158
2182
  "textContentBad": {
2159
2183
  "summary": "element text content invalid",
2160
- "why": "User may be unable to read all the document text",
2184
+ "why": "User may be unable to read all the page text",
2161
2185
  "wcag": "4.1",
2162
2186
  "weight": 3
2163
2187
  },
2164
2188
  "parseError": {
2165
2189
  "summary": "code invalid",
2166
- "why": "Invalid code in the document may prevent a helper from working",
2190
+ "why": "Invalid code in the page may prevent a helper from working",
2167
2191
  "wcag": "4.1",
2168
2192
  "weight": 3
2169
2193
  },
@@ -2189,7 +2213,7 @@ const issuesData = {
2189
2213
  },
2190
2214
  "captcha2": {
2191
2215
  "summary": "captcha2",
2192
- "why": "User is prevented from consuming the document",
2216
+ "why": "User is prevented from consuming the page",
2193
2217
  "wcag": "1.1.1",
2194
2218
  "weight": 1,
2195
2219
  "max": 1
@@ -5507,32 +5531,32 @@ const rulesData = {
5507
5531
  "what": "Element has a color attribute but no rel attribute with mask-icon as its value"
5508
5532
  },
5509
5533
  "A document must not include more than one meta element with its name attribute set to the value description.": {
5510
- "issueID": "metaBad",
5534
+ "issueID": "metaDuplicated",
5511
5535
  "quality": 1,
5512
5536
  "what": "Element with name=\"description\" is not the only meta element with that name"
5513
5537
  },
5514
5538
  "A document must not include both a meta element with an http-equiv attribute whose value is content-type, and a meta element with a charset attribute.": {
5515
- "issueID": "metaBad",
5539
+ "issueID": "metaDuplicated",
5516
5540
  "quality": 1,
5517
5541
  "what": "Element with http-equiv=\"content-type\" is incompatible with the meta element with a charset attribute"
5518
5542
  },
5519
5543
  "A document must not include more than one meta element with a http-equiv attribute whose value is content-type.": {
5520
- "issueID": "metaBad",
5544
+ "issueID": "metaDuplicated",
5521
5545
  "quality": 1,
5522
5546
  "what": "Page has more than 1 meta element with http-equiv=\"content-type\""
5523
5547
  },
5524
5548
  "A meta element with an http-equiv attribute whose value is X-UA-Compatible must have a content attribute with the value IE=edge.": {
5525
- "issueID": "metaBad",
5549
+ "issueID": "metaXUACompatible",
5526
5550
  "quality": 1,
5527
5551
  "what": "Element with http-equiv=\"X-UA-Compatible\" has no content=\"IE=edge\""
5528
5552
  },
5529
5553
  "A document must not include more than one meta element with a charset attribute.": {
5530
- "issueID": "metaBad",
5554
+ "issueID": "metaDuplicated",
5531
5555
  "quality": 1,
5532
5556
  "what": "More than 1 meta element has a charset attribute"
5533
5557
  },
5534
5558
  "A charset attribute on a meta element found after the first 1024 bytes.": {
5535
- "issueID": "metaBad",
5559
+ "issueID": "metaCharsetLate",
5536
5560
  "quality": 1,
5537
5561
  "what": "charset attribute on a meta element appears after 1024 bytes"
5538
5562
  },
@@ -6359,17 +6383,17 @@ const rulesData = {
6359
6383
  "what": "Element does not exist in HTML"
6360
6384
  },
6361
6385
  "Attribute .+ not allowed on element meta at this point.*": {
6362
- "issueID": "metaBad",
6386
+ "issueID": "metaAttributesWrong",
6363
6387
  "quality": 1,
6364
6388
  "what": "Attribute is not allowed on a meta element here"
6365
6389
  },
6366
6390
  "Element meta is missing one or more of the following attributes: .+": {
6367
- "issueID": "metaBad",
6391
+ "issueID": "metaAttributesWrong",
6368
6392
  "quality": 1,
6369
6393
  "what": "Element is missing a required attribute"
6370
6394
  },
6371
6395
  "Bad value .+ for attribute .+ on element meta.*": {
6372
- "issueID": "metaBad",
6396
+ "issueID": "metaAttributeBad",
6373
6397
  "quality": 1,
6374
6398
  "what": "Attribute of a meta element has an invalid value"
6375
6399
  },
@@ -7053,32 +7077,32 @@ const rulesData = {
7053
7077
  "what": "Element has a color attribute but no rel attribute with mask-icon as its value"
7054
7078
  },
7055
7079
  "A document must not include more than one meta element with its name attribute set to the value description.": {
7056
- "issueID": "metaBad",
7080
+ "issueID": "metaDuplicated",
7057
7081
  "quality": 1,
7058
7082
  "what": "Element with name=\"description\" is not the only meta element with that name"
7059
7083
  },
7060
7084
  "A document must not include both a meta element with an http-equiv attribute whose value is content-type, and a meta element with a charset attribute.": {
7061
- "issueID": "metaBad",
7085
+ "issueID": "metaDuplicated",
7062
7086
  "quality": 1,
7063
7087
  "what": "Element with http-equiv=\"content-type\" is incompatible with the meta element with a charset attribute"
7064
7088
  },
7065
7089
  "A document must not include more than one meta element with a http-equiv attribute whose value is content-type.": {
7066
- "issueID": "metaBad",
7090
+ "issueID": "metaDuplicated",
7067
7091
  "quality": 1,
7068
7092
  "what": "Page has more than 1 meta element with http-equiv=\"content-type\""
7069
7093
  },
7070
7094
  "A meta element with an http-equiv attribute whose value is X-UA-Compatible must have a content attribute with the value IE=edge.": {
7071
- "issueID": "metaBad",
7095
+ "issueID": "metaXUACompatible",
7072
7096
  "quality": 1,
7073
7097
  "what": "Element with http-equiv=\"X-UA-Compatible\" has no content=\"IE=edge\""
7074
7098
  },
7075
7099
  "A document must not include more than one meta element with a charset attribute.": {
7076
- "issueID": "metaBad",
7100
+ "issueID": "metaDuplicated",
7077
7101
  "quality": 1,
7078
7102
  "what": "More than 1 meta element has a charset attribute"
7079
7103
  },
7080
7104
  "A charset attribute on a meta element found after the first 1024 bytes.": {
7081
- "issueID": "metaBad",
7105
+ "issueID": "metaCharsetLate",
7082
7106
  "quality": 1,
7083
7107
  "what": "charset attribute on a meta element appears after 1024 bytes"
7084
7108
  },
@@ -7905,17 +7929,17 @@ const rulesData = {
7905
7929
  "what": "Element does not exist in HTML"
7906
7930
  },
7907
7931
  "Attribute .+ not allowed on element meta at this point.*": {
7908
- "issueID": "metaBad",
7932
+ "issueID": "metaAttributesWrong",
7909
7933
  "quality": 1,
7910
7934
  "what": "Attribute is not allowed on a meta element here"
7911
7935
  },
7912
7936
  "Element meta is missing one or more of the following attributes: .+": {
7913
- "issueID": "metaBad",
7937
+ "issueID": "metaAttributesWrong",
7914
7938
  "quality": 1,
7915
7939
  "what": "Element is missing a required attribute"
7916
7940
  },
7917
7941
  "Bad value .+ for attribute .+ on element meta.*": {
7918
- "issueID": "metaBad",
7942
+ "issueID": "metaAttributeBad",
7919
7943
  "quality": 1,
7920
7944
  "what": "Attribute of a meta element has an invalid value"
7921
7945
  },
@@ -9723,6 +9747,43 @@ const getEditableData = () => ({
9723
9747
  rules: structuredClone(rules),
9724
9748
  issueRules: structuredClone(issueRules)
9725
9749
  });
9750
+ const makeIssueStats = (issueRuleTable = issueRules) => {
9751
+ const stats = {};
9752
+ Object.entries(issueRuleTable).forEach(([issueID, engineData]) => {
9753
+ stats[issueID] = {};
9754
+ Object.entries(engineData).forEach(([engineID, { invariant, variable }]) => {
9755
+ stats[issueID][engineID] = invariant.length + variable.length;
9756
+ });
9757
+ });
9758
+ return stats;
9759
+ };
9760
+ const getSingleEngineIssues = (stats = issueStats) => Object.entries(stats).filter(([, engineCounts]) => Object.keys(engineCounts).filter((engineID) => engineID !== `nuVnu`).length === 1).map(([issueID, engineCounts]) => {
9761
+ const [engineID, ruleCount] = Object.entries(engineCounts)[0];
9762
+ return {
9763
+ issueID,
9764
+ engineID,
9765
+ ruleCount
9766
+ };
9767
+ }).sort((a, b) => b.ruleCount - a.ruleCount);
9768
+ const getEngineRuleCounts = (ruleTable = rules) => {
9769
+ const counts = {};
9770
+ Object.keys(ruleTable).forEach((engineID) => {
9771
+ counts[engineID] = Object.keys(ruleTable[engineID].invariant).length + Object.keys(ruleTable[engineID].variable).length;
9772
+ });
9773
+ return counts;
9774
+ };
9775
+ const checkIssuesData = (issueTable) => {
9776
+ const errors = [];
9777
+ const issueIDsBySummary = {};
9778
+ Object.entries(issueTable).forEach(([issueID, { summary }]) => {
9779
+ const ownerID = issueIDsBySummary[summary];
9780
+ if (ownerID) errors.push(`issues.${issueID} has the summary "${summary}", already used by issues.${ownerID}`);
9781
+ else issueIDsBySummary[summary] = issueID;
9782
+ });
9783
+ if (errors.length) throw new Error(`${errors[0]} (1 of ${errors.length} problems found)`);
9784
+ };
9726
9785
  const issueRules = makeIssueRules(rules);
9786
+ const issueStats = makeIssueStats(issueRules);
9787
+ checkIssuesData(issues);
9727
9788
  //#endregion
9728
- export { getEditableData, issueRules, issues, makeIssueRules, rules };
9789
+ export { getEditableData, getEngineRuleCounts, getSingleEngineIssues, issueRules, issueStats, issues, makeIssueRules, makeIssueStats, rules };