@govtechsg/oobee 0.10.76 → 0.10.77

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.
Files changed (134) hide show
  1. package/.github/workflows/publish.yml +8 -1
  2. package/INTEGRATION.md +7 -3
  3. package/dist/cli.js +252 -0
  4. package/dist/combine.js +221 -0
  5. package/dist/constants/cliFunctions.js +306 -0
  6. package/dist/constants/common.js +1669 -0
  7. package/dist/constants/constants.js +913 -0
  8. package/dist/constants/errorMeta.json +319 -0
  9. package/dist/constants/itemTypeDescription.js +7 -0
  10. package/dist/constants/oobeeAi.js +121 -0
  11. package/dist/constants/questions.js +151 -0
  12. package/dist/constants/sampleData.js +176 -0
  13. package/dist/crawlers/commonCrawlerFunc.js +428 -0
  14. package/dist/crawlers/crawlDomain.js +613 -0
  15. package/dist/crawlers/crawlIntelligentSitemap.js +135 -0
  16. package/dist/crawlers/crawlLocalFile.js +151 -0
  17. package/dist/crawlers/crawlSitemap.js +303 -0
  18. package/dist/crawlers/custom/escapeCssSelector.js +10 -0
  19. package/dist/crawlers/custom/evaluateAltText.js +11 -0
  20. package/dist/crawlers/custom/extractAndGradeText.js +44 -0
  21. package/dist/crawlers/custom/extractText.js +27 -0
  22. package/dist/crawlers/custom/findElementByCssSelector.js +36 -0
  23. package/dist/crawlers/custom/flagUnlabelledClickableElements.js +963 -0
  24. package/dist/crawlers/custom/framesCheck.js +37 -0
  25. package/dist/crawlers/custom/getAxeConfiguration.js +111 -0
  26. package/dist/crawlers/custom/gradeReadability.js +23 -0
  27. package/dist/crawlers/custom/utils.js +1024 -0
  28. package/dist/crawlers/custom/xPathToCss.js +147 -0
  29. package/dist/crawlers/guards/urlGuard.js +71 -0
  30. package/dist/crawlers/pdfScanFunc.js +276 -0
  31. package/dist/crawlers/runCustom.js +89 -0
  32. package/dist/exclusions.txt +7 -0
  33. package/dist/generateHtmlReport.js +144 -0
  34. package/dist/index.js +62 -0
  35. package/dist/logs.js +84 -0
  36. package/dist/mergeAxeResults.js +1571 -0
  37. package/dist/npmIndex.js +429 -0
  38. package/dist/proxyService.js +360 -0
  39. package/dist/runGenerateJustHtmlReport.js +16 -0
  40. package/dist/screenshotFunc/htmlScreenshotFunc.js +355 -0
  41. package/dist/screenshotFunc/pdfScreenshotFunc.js +645 -0
  42. package/dist/services/s3Uploader.js +127 -0
  43. package/dist/static/ejs/partials/components/allIssues/AllIssues.ejs +9 -0
  44. package/dist/static/ejs/partials/components/allIssues/CategoryBadges.ejs +82 -0
  45. package/dist/static/ejs/partials/components/allIssues/FilterBar.ejs +33 -0
  46. package/dist/static/ejs/partials/components/allIssues/IssuesTable.ejs +41 -0
  47. package/dist/static/ejs/partials/components/header/SiteInfo.ejs +119 -0
  48. package/dist/static/ejs/partials/components/header/aboutScanModal/AboutScanModal.ejs +15 -0
  49. package/dist/static/ejs/partials/components/header/aboutScanModal/ScanConfiguration.ejs +44 -0
  50. package/dist/static/ejs/partials/components/header/aboutScanModal/ScanDetails.ejs +142 -0
  51. package/dist/static/ejs/partials/components/prioritiseIssues/IssueDetailCard.ejs +36 -0
  52. package/dist/static/ejs/partials/components/prioritiseIssues/PrioritiseIssues.ejs +47 -0
  53. package/dist/static/ejs/partials/components/ruleModal/ruleOffcanvas.ejs +196 -0
  54. package/dist/static/ejs/partials/components/scannedPagesSegmentedTabs.ejs +48 -0
  55. package/dist/static/ejs/partials/components/screenshotLightbox.ejs +13 -0
  56. package/dist/static/ejs/partials/components/shared/InfoAlert.ejs +3 -0
  57. package/dist/static/ejs/partials/components/summaryScanAbout.ejs +141 -0
  58. package/dist/static/ejs/partials/components/summaryScanResults.ejs +16 -0
  59. package/dist/static/ejs/partials/components/summaryTable.ejs +20 -0
  60. package/dist/static/ejs/partials/components/summaryWcagCompliance.ejs +94 -0
  61. package/dist/static/ejs/partials/components/topTen.ejs +6 -0
  62. package/dist/static/ejs/partials/components/wcagCompliance/FailedCriteria.ejs +47 -0
  63. package/dist/static/ejs/partials/components/wcagCompliance/WcagCompliance.ejs +16 -0
  64. package/dist/static/ejs/partials/components/wcagCompliance/WcagGaugeBar.ejs +16 -0
  65. package/dist/static/ejs/partials/components/wcagCoverageDetails.ejs +18 -0
  66. package/dist/static/ejs/partials/footer.ejs +24 -0
  67. package/dist/static/ejs/partials/header.ejs +14 -0
  68. package/dist/static/ejs/partials/main.ejs +29 -0
  69. package/dist/static/ejs/partials/scripts/allIssues/AllIssues.ejs +376 -0
  70. package/dist/static/ejs/partials/scripts/bootstrap.ejs +8 -0
  71. package/dist/static/ejs/partials/scripts/categorySummary.ejs +141 -0
  72. package/dist/static/ejs/partials/scripts/decodeUnzipParse.ejs +3 -0
  73. package/dist/static/ejs/partials/scripts/header/SiteInfo.ejs +44 -0
  74. package/dist/static/ejs/partials/scripts/header/aboutScanModal/AboutScanModal.ejs +51 -0
  75. package/dist/static/ejs/partials/scripts/header/aboutScanModal/ScanConfiguration.ejs +127 -0
  76. package/dist/static/ejs/partials/scripts/header/aboutScanModal/ScanDetails.ejs +60 -0
  77. package/dist/static/ejs/partials/scripts/highlightjs.ejs +335 -0
  78. package/dist/static/ejs/partials/scripts/popper.ejs +7 -0
  79. package/dist/static/ejs/partials/scripts/prioritiseIssues/IssueDetailCard.ejs +137 -0
  80. package/dist/static/ejs/partials/scripts/prioritiseIssues/PrioritiseIssues.ejs +214 -0
  81. package/dist/static/ejs/partials/scripts/prioritiseIssues/wcagSvgMap.ejs +861 -0
  82. package/dist/static/ejs/partials/scripts/ruleModal/constants.ejs +957 -0
  83. package/dist/static/ejs/partials/scripts/ruleModal/itemCardRenderer.ejs +353 -0
  84. package/dist/static/ejs/partials/scripts/ruleModal/pageAccordionBuilder.ejs +468 -0
  85. package/dist/static/ejs/partials/scripts/ruleModal/ruleOffcanvas.ejs +306 -0
  86. package/dist/static/ejs/partials/scripts/ruleModal/utilities.ejs +483 -0
  87. package/dist/static/ejs/partials/scripts/scannedPagesSegmentedTabs.ejs +35 -0
  88. package/dist/static/ejs/partials/scripts/screenshotLightbox.ejs +75 -0
  89. package/dist/static/ejs/partials/scripts/summaryScanResults.ejs +14 -0
  90. package/dist/static/ejs/partials/scripts/summaryTable.ejs +78 -0
  91. package/dist/static/ejs/partials/scripts/topTen.ejs +61 -0
  92. package/dist/static/ejs/partials/scripts/utils.ejs +453 -0
  93. package/dist/static/ejs/partials/scripts/wcagCompliance/FailedCriteria.ejs +103 -0
  94. package/dist/static/ejs/partials/scripts/wcagCompliance/WcagGaugeBar.ejs +47 -0
  95. package/dist/static/ejs/partials/scripts/wcagCompliance.ejs +15 -0
  96. package/dist/static/ejs/partials/scripts/wcagCoverageDetails.ejs +75 -0
  97. package/dist/static/ejs/partials/styles/allIssues/AllIssues.ejs +384 -0
  98. package/dist/static/ejs/partials/styles/bootstrap.ejs +12391 -0
  99. package/dist/static/ejs/partials/styles/header/SiteInfo.ejs +121 -0
  100. package/dist/static/ejs/partials/styles/header/aboutScanModal/AboutScanModal.ejs +82 -0
  101. package/dist/static/ejs/partials/styles/header/aboutScanModal/ScanConfiguration.ejs +50 -0
  102. package/dist/static/ejs/partials/styles/header/aboutScanModal/ScanDetails.ejs +149 -0
  103. package/dist/static/ejs/partials/styles/header.ejs +7 -0
  104. package/dist/static/ejs/partials/styles/highlightjs.ejs +54 -0
  105. package/dist/static/ejs/partials/styles/prioritiseIssues/IssueDetailCard.ejs +141 -0
  106. package/dist/static/ejs/partials/styles/prioritiseIssues/PrioritiseIssues.ejs +204 -0
  107. package/dist/static/ejs/partials/styles/ruleModal/ruleOffcanvas.ejs +456 -0
  108. package/dist/static/ejs/partials/styles/scannedPagesSegmentedTabs.ejs +46 -0
  109. package/dist/static/ejs/partials/styles/shared/InfoAlert.ejs +12 -0
  110. package/dist/static/ejs/partials/styles/styles.ejs +1607 -0
  111. package/dist/static/ejs/partials/styles/summaryBootstrap.ejs +12458 -0
  112. package/dist/static/ejs/partials/styles/topTenCard.ejs +44 -0
  113. package/dist/static/ejs/partials/styles/wcagCompliance/FailedCriteria.ejs +59 -0
  114. package/dist/static/ejs/partials/styles/wcagCompliance/WcagGaugeBar.ejs +62 -0
  115. package/dist/static/ejs/partials/styles/wcagCompliance.ejs +36 -0
  116. package/dist/static/ejs/partials/styles/wcagCoverageDetails.ejs +33 -0
  117. package/dist/static/ejs/partials/summaryHeader.ejs +70 -0
  118. package/dist/static/ejs/partials/summaryMain.ejs +49 -0
  119. package/dist/static/ejs/report.ejs +226 -0
  120. package/dist/static/ejs/summary.ejs +47 -0
  121. package/dist/types/types.js +1 -0
  122. package/dist/utils.js +1070 -0
  123. package/examples/oobee-cypress-integration-js/cypress/support/e2e.js +36 -6
  124. package/examples/oobee-cypress-integration-js/cypress.config.js +45 -1
  125. package/examples/oobee-cypress-integration-ts/cypress.config.ts +47 -1
  126. package/examples/oobee-cypress-integration-ts/src/cypress/support/e2e.ts +36 -6
  127. package/examples/oobee-playwright-integration-js/oobee-playwright-demo.js +2 -1
  128. package/examples/oobee-playwright-integration-ts/src/oobee-playwright-demo.ts +2 -1
  129. package/package.json +9 -3
  130. package/src/constants/common.ts +2 -2
  131. package/src/constants/constants.ts +3 -1
  132. package/src/crawlers/crawlDomain.ts +1 -0
  133. package/src/crawlers/runCustom.ts +0 -1
  134. package/src/npmIndex.ts +42 -24
@@ -0,0 +1,47 @@
1
+ <div id="prioritiseIssuesCard" class="card rounded mt-4">
2
+ <div class="card-body">
3
+ <div class="d-flex align-items-center gap-2 mb-3">
4
+ <svg
5
+ width="40"
6
+ height="40"
7
+ viewBox="0 0 40 40"
8
+ fill="none"
9
+ xmlns="http://www.w3.org/2000/svg"
10
+ >
11
+ <g clip-path="url(#clip0_281_401)">
12
+ <path
13
+ d="M15.0002 34.9997C15.0002 35.9163 15.7502 36.6663 16.6668 36.6663H23.3335C24.2502 36.6663 25.0002 35.9163 25.0002 34.9997V33.333H15.0002V34.9997ZM20.0002 3.33301C13.5668 3.33301 8.3335 8.56634 8.3335 14.9997C8.3335 18.9663 10.3168 22.4497 13.3335 24.5663V28.333C13.3335 29.2497 14.0835 29.9997 15.0002 29.9997H25.0002C25.9168 29.9997 26.6668 29.2497 26.6668 28.333V24.5663C29.6835 22.4497 31.6668 18.9663 31.6668 14.9997C31.6668 8.56634 26.4335 3.33301 20.0002 3.33301ZM23.3335 22.833V26.6663H16.6668V22.833C14.1335 21.0497 11.6668 19.2163 11.6668 14.9997C11.6668 10.3997 15.4002 6.66634 20.0002 6.66634C24.6002 6.66634 28.3335 10.3997 28.3335 14.9997C28.3335 19.1497 25.8168 21.083 23.3335 22.833Z"
14
+ fill="#4D34BF"
15
+ />
16
+ <path
17
+ d="M19 10.5C19 10.2239 19.2239 10 19.5 10H20.5C20.7761 10 21 10.2239 21 10.5V17.5C21 17.7761 20.7761 18 20.5 18H19.5C19.2239 18 19 17.7761 19 17.5V10.5Z"
18
+ fill="#4D34BF"
19
+ />
20
+ <path
21
+ d="M19 20.5C19 20.2239 19.2239 20 19.5 20H20.5C20.7761 20 21 20.2239 21 20.5V21.5C21 21.7761 20.7761 22 20.5 22H19.5C19.2239 22 19 21.7761 19 21.5V20.5Z"
22
+ fill="#4D34BF"
23
+ />
24
+ </g>
25
+ <defs>
26
+ <clipPath id="clip0_281_401">
27
+ <rect width="40" height="40" fill="white" />
28
+ </clipPath>
29
+ </defs>
30
+ </svg>
31
+ <h2 class="mb-0">Prioritise these issues first</h2>
32
+ </div>
33
+
34
+ <div class="prioritise-issues-container">
35
+ <div class="prioritise-issues-main">
36
+ <div class="fw-semibold mb-3">
37
+ <%- include('../shared/InfoAlert', { text: 'Resolving each Must Fix issue within a criteria increases your WCAG score by 1.' }) %>
38
+ </div>
39
+ <div id="prioritiseIssuesAccordion" class="prioritise-issues-accordion">
40
+ <!-- Dynamically populated by script -->
41
+ </div>
42
+ </div>
43
+
44
+ <%- include('./IssueDetailCard') %>
45
+ </div>
46
+ </div>
47
+ </div>
@@ -0,0 +1,196 @@
1
+ <%# this is a template; content will be populated using js %>
2
+ <div
3
+ class="modal fade"
4
+ id="expandedRule"
5
+ tabindex="-1"
6
+ aria-labelledby="expandedRuleName"
7
+ aria-hidden="true"
8
+ data-bs-backdrop="true"
9
+ data-bs-keyboard="true"
10
+ >
11
+ <div class="modal-dialog modal-dialog-centered rule-modal-dialog">
12
+ <div class="modal-content">
13
+ <div class="modal-body rule-modal-body p-0">
14
+ <div class="d-flex w-100 modal-view">
15
+ <!-- Left Side -->
16
+ <div class="w-70 left-side-modal">
17
+ <div class="d-flex justify-content-end pt-3 pe-3">
18
+ <button
19
+ type="button"
20
+ class="btn-close modal-button-right"
21
+ data-bs-dismiss="modal"
22
+ aria-label="Close this popup"
23
+ ></button>
24
+ </div>
25
+ <!-- SVG Image -->
26
+ <div id="expandedRuleImageContainer" class="rule-modal-image-container">
27
+ <img
28
+ id="expandedRuleImage"
29
+ src=""
30
+ alt="Issue illustration"
31
+ class="rule-modal-image"
32
+ />
33
+ </div>
34
+
35
+ <div class="d-flex flex-column gap-3 p-4">
36
+ <h1 id="expandedRuleName">Loading...</h1>
37
+
38
+ <!-- Conformance badges -->
39
+ <div class="rule-modal-conformance">
40
+ <span id="expandedRuleCategoryBadge" class="mustfix-badge-label">Must Fix</span>
41
+ <div id="expandedRuleConformance" class="rule-modal-conformance-badges"></div>
42
+ </div>
43
+
44
+ <!-- Long description (from a11yRuleLongDescriptionMap) -->
45
+ <p id="expandedRuleDescription" class="rule-modal-description"></p>
46
+
47
+ <div id="expandedRuleManualTestSection" style="display: none">
48
+ <div>
49
+ This occurrence might be a false positive that needs to be verified by a human.
50
+ </div>
51
+ </div>
52
+
53
+ <!-- Disability impact -->
54
+ <div
55
+ id="expandedRuleDisabilitySection"
56
+ class="rule-modal-disability"
57
+ style="display: none"
58
+ >
59
+ <div id="expandedRuleDisabilityMessage" class="info-alert mb-0" role="alert"></div>
60
+ </div>
61
+
62
+ <!-- AI Feedback Section -->
63
+ <div id="expandedRuleAiFeedback" class="rule-modal-ai-feedback" style="display: none">
64
+ <svg
65
+ width="14"
66
+ height="16"
67
+ viewBox="0 0 14 16"
68
+ fill="none"
69
+ xmlns="http://www.w3.org/2000/svg"
70
+ >
71
+ <path
72
+ d="M6.45906 3.34063C5.68875 2.57003 5.1615 1.22438 4.89984 0C4.63778 1.22462 4.11109 2.57056 3.3405 3.34116C2.57019 4.11122 1.22413 4.63847 0 4.90066C1.22462 5.16231 2.57044 5.68925 3.34075 6.45988C4.11106 7.23019 4.63831 8.57613 4.90038 9.8005C5.16203 8.57588 5.68913 7.22994 6.45931 6.45934C7.22962 5.68903 8.57569 5.16203 9.79981 4.89984C8.57547 4.63819 7.22966 4.11097 6.45906 3.34063Z"
73
+ fill="#5735DF"
74
+ />
75
+ <path
76
+ d="M11.4627 9.5104C11.0029 9.05037 10.6874 8.24602 10.5311 7.51465C10.3745 8.24602 10.0601 9.05034 9.59975 9.51065C9.13944 9.97046 8.33525 10.2857 7.604 10.4423C8.3355 10.5988 9.13944 10.9136 9.59975 11.3739C10.0601 11.8339 10.3751 12.6382 10.5316 13.3696C10.6879 12.638 11.0029 11.8339 11.4629 11.3736C11.923 10.9136 12.7273 10.5986 13.4584 10.4417C12.7273 10.2854 11.923 9.97046 11.4627 9.5104Z"
77
+ fill="#5735DF"
78
+ />
79
+ <path
80
+ d="M3.30271 11.084C3.17124 11.698 2.90724 12.3735 2.52087 12.7598C2.13455 13.1459 1.45937 13.4104 0.845459 13.5419C1.45937 13.6736 2.13455 13.9374 2.52087 14.324C2.90724 14.7103 3.17177 15.3852 3.30324 15.9995C3.43458 15.3852 3.69871 14.7103 4.08521 14.3237C4.47127 13.9374 5.14658 13.6731 5.76037 13.5414C5.14662 13.4101 4.47127 13.1459 4.08496 12.7595C3.69871 12.3735 3.43405 11.698 3.30271 11.084Z"
81
+ fill="#5735DF"
82
+ />
83
+ </svg>
84
+ <span>This issue might benefit from AI suggested fixes.</span>
85
+ </div>
86
+ </div>
87
+
88
+ <div class="d-flex flex-column rule-modal-pages-section">
89
+ <!-- Pages Affected Section -->
90
+ <div id="expandedRulePagesSection">
91
+ <div class="accordion" id="pagesAccordion">
92
+ <div class="accordion-item">
93
+ <h2 class="accordion-header" id="pagesAccordionHeader">
94
+ <button
95
+ class="accordion-button collapsed accordion-title"
96
+ type="button"
97
+ data-bs-toggle="collapse"
98
+ data-bs-target="#pagesAccordionContent"
99
+ aria-expanded="false"
100
+ aria-controls="pagesAccordionContent"
101
+ >
102
+ <svg
103
+ class="accordion-arrow"
104
+ width="24"
105
+ height="24"
106
+ viewBox="0 0 24 24"
107
+ fill="none"
108
+ xmlns="http://www.w3.org/2000/svg"
109
+ >
110
+ <path
111
+ d="M7.41 8.58984L12 13.1698L16.59 8.58984L18 9.99984L12 15.9998L6 9.99984L7.41 8.58984Z"
112
+ fill="#5735DF"
113
+ />
114
+ </svg>
115
+ <div class="d-flex justify-content-between align-items-center w-100">
116
+ <h3 id="expandedRuleDropdownTitle" class="mb-0">
117
+ Pages affected by this issue (#)
118
+ </h3>
119
+ <div class="d-flex align-items-center gap-3">
120
+ <span
121
+ id="expandedRuleDropdownToggleCategoryInfo"
122
+ class="rule-occurrence-count"
123
+ ># Total occ.</span
124
+ >
125
+ </div>
126
+ </div>
127
+ </button>
128
+ </h2>
129
+ <div
130
+ id="pagesAccordionContent"
131
+ class="accordion-collapse collapse"
132
+ aria-labelledby="pagesAccordionHeader"
133
+ data-bs-parent="#pagesAccordion"
134
+ >
135
+ <div class="accordion-body">
136
+ <div class="group-by-toggle">
137
+ <span class="group-by-label">Group by</span>
138
+ <div class="group-by-options">
139
+ <div class="form-check form-check-inline">
140
+ <input
141
+ type="radio"
142
+ class="form-check-input"
143
+ name="groupByOptions"
144
+ id="groupByPage"
145
+ value="page"
146
+ checked
147
+ />
148
+ <label class="form-check-label" for="groupByPage">Page</label>
149
+ </div>
150
+
151
+ <div class="form-check form-check-inline">
152
+ <input
153
+ type="radio"
154
+ class="form-check-input"
155
+ name="groupByOptions"
156
+ id="groupByHtmlElement"
157
+ value="html"
158
+ />
159
+ <label class="form-check-label" for="groupByHtmlElement"
160
+ >HTML Element</label
161
+ >
162
+ </div>
163
+ </div>
164
+ </div>
165
+ <div id="expandedRuleCategoryContent"></div>
166
+ <div id="expandedRulePageContent">Total # affected pages</div>
167
+ </div>
168
+ </div>
169
+ </div>
170
+ </div>
171
+ </div>
172
+ </div>
173
+ </div>
174
+
175
+ <!-- Right Side -->
176
+ <div class="w-30 d-flex flex-column right-side-modal p-4">
177
+ <div class="d-flex align-self-end">
178
+ <button
179
+ type="button"
180
+ class="btn-close modal-button"
181
+ data-bs-dismiss="modal"
182
+ aria-label="Close"
183
+ ></button>
184
+ </div>
185
+ <h2 class="rule-modal-section-title">Step by step plan</h2>
186
+ <h3>How to Fix</h3>
187
+ <!-- How to Fix Section -->
188
+ <div id="stepByStepContainer" class="rule-modal-how-to-fix">
189
+ <!-- Steps will be populated dynamically -->
190
+ </div>
191
+ </div>
192
+ </div>
193
+ </div>
194
+ </div>
195
+ </div>
196
+ </div>
@@ -0,0 +1,48 @@
1
+ <div class="segmented-tabs" role="tablist" aria-label="Crawl views">
2
+ <button
3
+ type="button"
4
+ class="seg-pill"
5
+ aria-controls="pages-scanned"
6
+ aria-selected="true"
7
+ data-tab-target="#pages-scanned"
8
+ >
9
+ <span id="totalPagesScannedLabel">
10
+ N/A
11
+ </span>
12
+ <span>
13
+ &nbsp;Pages Scanned
14
+ </span>
15
+ </button>
16
+
17
+ <button
18
+ type="button"
19
+ id="seg-not-scanned"
20
+ class="seg-pill"
21
+ aria-controls="pages-not-scanned"
22
+ aria-selected="false"
23
+ data-tab-target="#pages-not-scanned"
24
+ >
25
+ <span id="totalPagesNotScannedLabel">
26
+ N/A
27
+ </span>
28
+ <span>
29
+ &nbsp;Pages Not Scanned
30
+ </span>
31
+ </button>
32
+
33
+ <button
34
+ type="button"
35
+ id="seg-unsupported"
36
+ class="seg-pill"
37
+ aria-controls="pages-unsupported"
38
+ aria-selected="false"
39
+ data-tab-target="#pages-unsupported"
40
+ >
41
+ <span id="totalUnsupportedDocsLabel">
42
+ N/A
43
+ </span>
44
+ <span>
45
+ &nbsp;Unsupported Documents
46
+ </span>
47
+ </button>
48
+ </div>
@@ -0,0 +1,13 @@
1
+ <div class="screenshot-lightbox">
2
+ <div class="lightbox-header">
3
+ <h5 class="mb-0"></h5>
4
+ <button onclick="closeLightbox()" aria-label="Close lightbox">
5
+ <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
6
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M0.549622 0.549531C0.713716 0.385436 0.936276 0.293249 1.16834 0.293249C1.4004 0.293249 1.62296 0.385436 1.78706 0.549531L7.97424 6.73671L14.1614 0.549531C14.3255 0.385437 14.5481 0.293249 14.7801 0.293249C15.0122 0.293249 15.2348 0.385436 15.3989 0.549531C15.563 0.713625 15.6551 0.936185 15.6551 1.16825C15.6551 1.40031 15.563 1.62287 15.3989 1.78697L9.21168 7.97415L15.3989 14.1613C15.563 14.3254 15.6551 14.548 15.6551 14.7801C15.6551 15.0121 15.563 15.2347 15.3989 15.3988C15.2348 15.5629 15.0122 15.6551 14.7801 15.6551C14.5481 15.6551 14.3255 15.5629 14.1614 15.3988L7.97424 9.21159L1.78706 15.3988C1.62296 15.5629 1.4004 15.6551 1.16834 15.6551C0.936276 15.6551 0.713716 15.5629 0.549622 15.3988C0.385527 15.2347 0.29334 15.0121 0.29334 14.7801C0.29334 14.548 0.385527 14.3254 0.549622 14.1613L6.73681 7.97415L0.549622 1.78697C0.385527 1.62287 0.29334 1.40031 0.29334 1.16825C0.29334 0.936185 0.385527 0.713625 0.549622 0.549531Z" fill="white"/>
7
+ </svg>
8
+ </button>
9
+ </div>
10
+ <div class="lightbox-content">
11
+ <img id="lightbox-image"></img>
12
+ </div>
13
+ </div>
@@ -0,0 +1,3 @@
1
+ <div class="info-alert" role="alert">
2
+ <%= text %>
3
+ </div>
@@ -0,0 +1,141 @@
1
+ <h2>About this scan</h2>
2
+ <ul class="p-0" style="list-style: none">
3
+ <li class="svg-container">
4
+ <svg
5
+ aria-label="Start time"
6
+ width="18px"
7
+ viewBox="0 0 18 17"
8
+ fill="none"
9
+ xmlns="http://www.w3.org/2000/svg"
10
+ class="svg-aboutscan"
11
+ >
12
+ <path
13
+ fill-rule="evenodd"
14
+ clip-rule="evenodd"
15
+ d="M3.69863 0.927936C3.69863 0.41626 4.11262 0.00146484 4.62329 0.00146484C5.13396 0.00146484 5.54795 0.41626 5.54795 0.927936V1.85441H9.24658V0.927936C9.24658 0.41626 9.66056 0.00146484 10.1712 0.00146484C10.6819 0.00146484 11.0959 0.41626 11.0959 0.927936V1.85441H12.0205C13.5526 1.85441 14.7945 3.09879 14.7945 4.63382V8.51434C14.6723 8.5058 14.549 8.50146 14.4247 8.50146C14.0768 8.50146 13.7367 8.53544 13.4075 8.60029V7.41323H1.38699V12.9721C1.38699 13.7396 2.00795 14.3618 2.77397 14.3618H9.1446C9.18737 14.8464 9.29359 15.3125 9.45476 15.7515H2.77397C1.24195 15.7515 0 14.5071 0 12.9721V4.63382C0 3.09879 1.24195 1.85441 2.77397 1.85441H3.69863V0.927936ZM9.24658 3.24411V3.70735C9.24658 4.21902 9.66056 4.63382 10.1712 4.63382C10.6819 4.63382 11.0959 4.21902 11.0959 3.70735V3.24411H12.0205C12.7866 3.24411 13.4075 3.8663 13.4075 4.63382V6.48676H1.38699V4.63382C1.38699 3.8663 2.00795 3.24411 2.77397 3.24411H3.69863V3.70735C3.69863 4.21902 4.11262 4.63382 4.62329 4.63382C5.13396 4.63382 5.54795 4.21902 5.54795 3.70735V3.24411H9.24658ZM17.0959 14.0015C17.0959 15.7043 15.7343 17.0848 14.0548 17.0848C12.3752 17.0848 11.0137 15.7043 11.0137 14.0015C11.0137 12.2986 12.3752 10.9181 14.0548 10.9181C15.7343 10.9181 17.0959 12.2986 17.0959 14.0015ZM18 14.0015C18 16.2106 16.2337 18.0015 14.0548 18.0015C11.8759 18.0015 10.1096 16.2106 10.1096 14.0015C10.1096 11.7923 11.8759 10.0015 14.0548 10.0015C16.2337 10.0015 18 11.7923 18 14.0015ZM14.0548 11.5015C13.8732 11.5015 13.726 11.6507 13.726 11.8348V13.9181C13.726 14.0241 13.7748 14.1185 13.8507 14.1795C13.8597 14.191 13.8696 14.2021 13.8803 14.2125L14.8486 15.161C14.9791 15.2889 15.1873 15.2853 15.3134 15.1529C15.4396 15.0205 15.436 14.8095 15.3054 14.6816L14.3836 13.7785V11.8348C14.3836 11.6507 14.2364 11.5015 14.0548 11.5015Z"
16
+ fill="#93928d"
17
+ />
18
+ </svg>
19
+ <span><%- unescape(formatAboutStartTime(startTime)) %></span>
20
+ </li>
21
+ <li class="svg-container" style="word-break: break-all;">
22
+ <svg
23
+ aria-label="URL scanned"
24
+ width="18px"
25
+ viewBox="0 0 18 17"
26
+ fill="none"
27
+ xmlns="http://www.w3.org/2000/svg"
28
+ class="svg-aboutscan"
29
+ >
30
+ <path
31
+ fill-rule="evenodd"
32
+ clip-rule="evenodd"
33
+ d="M16.5789 2.80146H1.42105V12.6015H16.5789V2.80146ZM18 0.934798V2.80146V13.0681C18 13.5836 17.5758 14.0015 17.0526 14.0015H0.947369C0.42415 14.0015 0 13.5836 0 13.0681V2.80146V0.934798C0 0.419332 0.42415 0.00146484 0.947369 0.00146484H17.0526C17.5758 0.00146484 18 0.419332 18 0.934798ZM3.07895 2.3348C2.68653 2.3348 2.36842 2.0214 2.36842 1.6348C2.36842 1.2482 2.68653 0.934798 3.07895 0.934798C3.47136 0.934798 3.78947 1.2482 3.78947 1.6348C3.78947 2.0214 3.47136 2.3348 3.07895 2.3348ZM4.26316 1.6348C4.26316 2.0214 4.58127 2.3348 4.97368 2.3348C5.3661 2.3348 5.68421 2.0214 5.68421 1.6348C5.68421 1.2482 5.3661 0.934798 4.97368 0.934798C4.58127 0.934798 4.26316 1.2482 4.26316 1.6348ZM6.86842 2.3348C6.47601 2.3348 6.15789 2.0214 6.15789 1.6348C6.15789 1.2482 6.47601 0.934798 6.86842 0.934798C7.26083 0.934798 7.57895 1.2482 7.57895 1.6348C7.57895 2.0214 7.26083 2.3348 6.86842 2.3348Z"
34
+ fill="#93928d"
35
+ />
36
+ </svg>
37
+ <a aria-label="URL scanned" href="<%= urlScanned %>" target="_blank"><%= urlScanned %></a>
38
+ </li>
39
+ <% if (viewport !== null) { %>
40
+ <li class="svg-container">
41
+ <% if (viewport.startsWith('Desktop')) { %>
42
+ <svg
43
+ aria-label="Viewport"
44
+ width="18px"
45
+ viewBox="0 0 18 17"
46
+ fill="none"
47
+ xmlns="http://www.w3.org/2000/svg"
48
+ class="svg-aboutscan"
49
+ >
50
+ <path
51
+ d="M16.56 0.19H1.44A1.26 1.26 0 0 0 0.18 1.452v10.092a1.26 1.26 0 0 0 1.26 1.262h5.67v1.242H5.85c-0.347 0 -0.63 0.282 -0.63 0.63 0 0.349 0.282 0.63 0.63 0.63h6.3c0.347 0 0.63 -0.282 0.63 -0.63 0 -0.349 -0.282 -0.63 -0.63 -0.63h-1.26v-1.242h5.67c0.697 0 1.26 -0.565 1.26 -1.262V1.452A1.26 1.26 0 0 0 16.56 0.19Zm0 10.98c0 0.218 -0.176 0.394 -0.394 0.394H1.834A0.394 0.394 0 0 1 1.44 11.17V1.866c0 -0.218 0.176 -0.394 0.394 -0.394H16.168c0.218 0 0.394 0.176 0.394 0.394L16.56 11.17Z"
52
+ fill="#93928d"
53
+ />
54
+ </svg>
55
+ <% } else if (viewport.startsWith('CustomWidth')) { %>
56
+ <svg
57
+ aria-label="Viewport"
58
+ width="18px"
59
+ viewBox="0 0 18 17"
60
+ fill="none"
61
+ xmlns="http://www.w3.org/2000/svg"
62
+ class="svg-aboutscan"
63
+ >
64
+ <path
65
+ fill-rule="evenodd"
66
+ clip-rule="evenodd"
67
+ d="M0 3.6a3.6 3.6 0 0 1 3.6 -3.6h10.8a3.6 3.6 0 0 1 3.6 3.6v10.8a3.6 3.6 0 0 1 -3.6 3.6H3.6a3.6 3.6 0 0 1 -3.6 -3.6V3.6Zm3.329 6.263a0.863 0.863 0 0 0 -0.863 0.863v3.945a0.863 0.863 0 0 0 0.986 0.854c0.041 0.006 0.081 0.009 0.123 0.009h3.945a0.863 0.863 0 1 0 0 -1.726H4.192v-3.083a0.863 0.863 0 0 0 -0.863 -0.863Zm12.452 -2.588a0.863 0.863 0 1 1 -1.726 0V4.192h-3.328a0.863 0.863 0 0 1 0 -1.726h3.945c0.042 0 0.083 0.004 0.123 0.009a0.863 0.863 0 0 1 0.986 0.854v3.946Z"
68
+ fill="#93928d"
69
+ />
70
+ </svg>
71
+ <% } else { %>
72
+ <svg
73
+ aria-label="Viewport"
74
+ width="18px"
75
+ viewBox="0 0 18 17"
76
+ fill="none"
77
+ xmlns="http://www.w3.org/2000/svg"
78
+ class="svg-aboutscan"
79
+ >
80
+ <path
81
+ fill-rule="evenodd"
82
+ clip-rule="evenodd"
83
+ d="M1.94595 0.00146484C0.87123 0.00146484 0 0.856193 0 1.91056V19.0924C0 20.1467 0.87123 21.0015 1.94595 21.0015H10.0541C11.1288 21.0015 12 20.1467 12 19.0924V1.91056C12 0.856194 11.1288 0.00146484 10.0541 0.00146484H1.94595ZM10.7027 2.54692H1.2973V17.8196H10.7027V2.54692ZM4.21622 1.1151C4.21622 1.02724 4.28882 0.95601 4.37838 0.95601H7.94595C8.03551 0.95601 8.10811 1.02724 8.10811 1.1151C8.10811 1.20296 8.03551 1.27419 7.94595 1.27419H4.37838C4.28882 1.27419 4.21622 1.20296 4.21622 1.1151ZM6.16216 20.3651C6.69952 20.3651 7.13514 19.9377 7.13514 19.4106C7.13514 18.8834 6.69952 18.456 6.16216 18.456C5.6248 18.456 5.18919 18.8834 5.18919 19.4106C5.18919 19.9377 5.6248 20.3651 6.16216 20.3651Z"
84
+ fill="#93928d"
85
+ />
86
+ </svg>
87
+ <% } %>
88
+ <span>
89
+ <%= viewport.startsWith("CustomWidth") ? `${viewport.split("_")[1]} width` : viewport %> viewport
90
+ </span>
91
+ </li>
92
+ <% } %>
93
+ <li class="svg-container">
94
+ <svg
95
+ aria-label="Pages scanned"
96
+ width="18px"
97
+ viewBox="0 0 18 17"
98
+ fill="none"
99
+ xmlns="http://www.w3.org/2000/svg"
100
+ class="svg-aboutscan"
101
+ >
102
+ <g clip-path="url(#clip0_1630_1547)">
103
+ <path
104
+ d="M14.0299 1.09229H2.97102C2.59546 1.09229 2.29102 1.39673 2.29102 1.77228V16.231C2.29102 16.6065 2.59546 16.911 2.97102 16.911H14.0299C14.4054 16.911 14.7099 16.6065 14.7099 16.231V1.77228C14.7099 1.39673 14.4054 1.09229 14.0299 1.09229Z"
105
+ stroke="#93928d"
106
+ stroke-width="1.7369"
107
+ />
108
+ <path
109
+ d="M5.03369 4.92139H11.9663"
110
+ stroke="#93928d"
111
+ stroke-width="1.189"
112
+ stroke-linecap="round"
113
+ />
114
+ <path
115
+ d="M5.03369 7.64136H11.9663"
116
+ stroke="#93928d"
117
+ stroke-width="1.189"
118
+ stroke-linecap="round"
119
+ />
120
+ <path
121
+ d="M5.03369 10.3613H11.9663"
122
+ stroke="#93928d"
123
+ stroke-width="1.189"
124
+ stroke-linecap="round"
125
+ />
126
+ <path
127
+ d="M5.03369 13.0813H11.9663"
128
+ stroke="#93928d"
129
+ stroke-width="1.189"
130
+ stroke-linecap="round"
131
+ />
132
+ </g>
133
+ <defs>
134
+ <clipPath id="clip0_1630_1547">
135
+ <rect width="17" height="17" fill="white" transform="translate(0 0.501465)" />
136
+ </clipPath>
137
+ </defs>
138
+ </svg>
139
+ <span><%= isCustomFlow ? 'Custom Flow (' + totalPagesScanned + ' pages)' : totalPagesScanned + ' pages' %></span>
140
+ </li>
141
+ </ul>
@@ -0,0 +1,16 @@
1
+ <% const formattedCategoryTitles = {
2
+ mustFix: "Must Fix",
3
+ goodToFix: "Good to Fix",
4
+ needsReview: "Manual Review Required",
5
+ passed: "Passed"
6
+ } %>
7
+ <li class="d-flex align-items-center mb-3 justify-content-between">
8
+ <span class="d-flex align-items-center d-inline mb-0"
9
+ ><img alt="<%= category %>Icon" id="summary<%= category %>Icon"><%= formattedCategoryTitles[category] %></span
10
+ >
11
+ <span><%= items[category].rules.length %></span>
12
+ </li>
13
+ <% if (category !== 'passed') { %>
14
+ <hr/>
15
+ <% } %>
16
+
@@ -0,0 +1,20 @@
1
+ <div class="pb-4 mx-3">
2
+ <table id="summary-table" style="table-layout:fixed;width:100%;">
3
+ <col style="width:10%">
4
+ <col style="width:30%">
5
+ <col style="width:20%">
6
+ <col style="width:20%">
7
+ <col style="width:20%">
8
+ <thead id="summary-table-header">
9
+ <tr id="summary-table-row" style="font-weight: 600">
10
+ <td id="summary-table-icon">Icon</td>
11
+ <td id="summary-table-issue-description" class="py-4">Issue description</td>
12
+ <td id="summary-table-occurrences">Occurrences</td>
13
+ <td id="summary-table-pages">Pages</td>
14
+ <td id="summary-table-helpUrl">Help URL</td>
15
+ </tr>
16
+ </thead>
17
+ <tbody id="summary-table-contents">
18
+ </tbody>
19
+ </table>
20
+ </div>
@@ -0,0 +1,94 @@
1
+ <div id="wcag-compliance-card" class="card h-100 p-3">
2
+ <h2 class="mb-0">WCAG Compliance</h2>
3
+ <div class="wcag-compliance-passes-panel">
4
+ <div class="d-flex justify-content-between align-items-center">
5
+ <div class="d-flex align-items-center">
6
+ <span class="fw-bold">WCAG (A & AA) Passes</span>
7
+ <button
8
+ aria-label="More on automated testing WCAG coverage"
9
+ id="wcagModalToggle"
10
+ class="ms-2"
11
+ data-bs-toggle="modal"
12
+ data-bs-target="#wcagModal"
13
+ >
14
+ <svg
15
+ width="14"
16
+ height="14"
17
+ viewBox="0 0 14 14"
18
+ fill="none"
19
+ xmlns="http://www.w3.org/2000/svg"
20
+ >
21
+ <path
22
+ d="M11.9528 2.05329C9.22079 -0.68205 4.78867 -0.68477 2.0533 2.04718C-0.682042 4.7792 -0.684795 9.21135 2.04722 11.9467C4.77917 14.6821 9.21135 14.6848 11.9467 11.9528C14.682 9.22085 14.6848 4.78863 11.9528 2.05329ZM7.00216 11.2406C6.6319 11.2406 6.33174 10.9405 6.33174 10.5702C6.33174 10.1999 6.63187 9.89976 7.00216 9.89976C7.37243 9.89976 7.67259 10.1999 7.67259 10.5702C7.67255 10.9405 7.37243 11.2406 7.00216 11.2406ZM8.09214 7.20401C7.70918 7.42788 7.67645 7.7033 7.6748 8.49691C7.6747 8.54938 7.67453 8.60233 7.67423 8.65558C7.67185 9.03068 7.36712 9.33312 6.99253 9.33312C6.99105 9.33312 6.98957 9.33312 6.98813 9.33312C6.61159 9.33074 6.3083 9.02356 6.31066 8.64699C6.31099 8.59568 6.31109 8.54468 6.31119 8.49415C6.31287 7.67852 6.31492 6.66352 7.40395 6.02694C8.27777 5.51613 8.3879 5.18059 8.28543 4.74029C8.16503 4.2231 7.69273 4.08907 7.32418 4.1312C7.20042 4.14541 6.58322 4.24724 6.58322 4.85783C6.58322 5.23431 6.27795 5.5396 5.90141 5.5396C5.52487 5.5396 5.21964 5.23431 5.21964 4.85783C5.21964 3.76416 6.02107 2.90831 7.16859 2.77656C8.35043 2.64099 9.35515 3.32135 9.61338 4.4312C9.99939 6.08915 8.61379 6.89911 8.09214 7.20401Z"
23
+ fill="#c9c8c6"
24
+ />
25
+ </svg>
26
+ </button>
27
+ </div>
28
+ <span aria-label="Pass percentage" class="ms-2"><%= wcagPassPercentage %>%</span>
29
+ </div>
30
+ <div class="wcag-compliance-passes-bar">
31
+ <div
32
+ class="wcag-compliance-passes-bar-progress"
33
+ style="width: <%= wcagPassPercentage %>%"
34
+ ></div>
35
+ </div>
36
+ </div>
37
+ </div>
38
+ <div
39
+ id="wcagModal"
40
+ class="modal fade"
41
+ tabindex="-1"
42
+ aria-labelledby="wcagModalLabel"
43
+ aria-hidden="true"
44
+ >
45
+ <div class="modal-dialog">
46
+ <div class="modal-content">
47
+ <div class="modal-header">
48
+ <h3 class="modal-title fw-bold" id="wcagModalLabel">Automated Testing WCAG Coverage</h3>
49
+ <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
50
+ </div>
51
+ <div class="modal-body">
52
+ <div>
53
+ Only 19 WCAG 2.2 Success Criteria can be checked reasonably through automated testing:
54
+ </div>
55
+ <div class="accordion my-3" id="wcagLinksAccordion">
56
+ <div class="accordion-item">
57
+ <div class="accordion-header" id="wcagLinksAccordionTitle">
58
+ <button
59
+ class="accordion-button collapsed"
60
+ type="button"
61
+ data-bs-toggle="collapse"
62
+ data-bs-target="#wcagLinksAccordionContent"
63
+ aria-expanded="false"
64
+ aria-controls="wcagLinksAccordionContent"
65
+ >
66
+ 19 WCAG Success Criteria (A & AA)
67
+ </button>
68
+ </div>
69
+ <div
70
+ id="wcagLinksAccordionContent"
71
+ class="accordion-collapse collapse"
72
+ aria-labelledby="wcagLinksAccordionTitle"
73
+ data-bs-parent="#accordionExample"
74
+ >
75
+ <div class="accordion-body">
76
+ <ul id="wcagLinksList">
77
+ <% Object.entries(wcagLinks).forEach(link => { %>
78
+ <li>
79
+ <a href="<%= link[1] %>" target="_blank"><%= link[0] %></a>
80
+ </li>
81
+ <% }) %>
82
+ </ul>
83
+ </div>
84
+ </div>
85
+ </div>
86
+ </div>
87
+ <div>
88
+ <strong>Manual testing is still recommended</strong> as they involve subjective judgements
89
+ and human interpretation, which cannot be fully automated.
90
+ </div>
91
+ </div>
92
+ </div>
93
+ </div>
94
+ </div>
@@ -0,0 +1,6 @@
1
+ <div id="top-ten-card" class="h-100">
2
+ <div class="card-body">
3
+ <h3>Pages with the most issues</h3>
4
+ <ul class="unbulleted-list" id="top-issues-list"></ul>
5
+ </div>
6
+ </div>
@@ -0,0 +1,47 @@
1
+ <div id="failedCriteriaCard" class="mt-3">
2
+ <div class="wcag-row-column">
3
+ <div>
4
+ <h3 class="wcag-title">Failed Criteria (<span id="failedCriteriaCount">0</span>)</h3>
5
+ </div>
6
+
7
+ <ul id="failedCriteriaList" class="unbulleted-list">
8
+ <!-- dynamically populated -->
9
+ </ul>
10
+
11
+ <button
12
+ id="viewAllFailedCriteria"
13
+ type="button"
14
+ class="view-all-link"
15
+ data-bs-toggle="modal"
16
+ data-bs-target="#failedCriteriaModal"
17
+ hidden
18
+ >
19
+ View all failed criteria
20
+ <svg width="8" height="10" viewBox="0 0 6 10" aria-hidden="true" focusable="false">
21
+ <path
22
+ d="M0.726562 7.06L3.7799 4L0.726562 0.94L1.66656 0L5.66656 4L1.66656 8L0.726562 7.06Z"
23
+ fill="#5735DF"
24
+ />
25
+ </svg>
26
+ </button>
27
+ </div>
28
+ </div>
29
+
30
+ <!-- Failed Criteria Modal -->
31
+ <div id="failedCriteriaModal" class="modal fade" tabindex="-1" aria-labelledby="failedCriteriaModalLabel" aria-hidden="true">
32
+ <div class="modal-dialog modal-dialog-centered modal-dialog-scrollable">
33
+ <div class="modal-content">
34
+ <div class="modal-header modal-title mt-2">
35
+ <h1 class="modal-title fw-bold" id="failedCriteriaModalLabel">
36
+ Failed Criteria (<span id="failedCriteriaModalCount">0</span>)
37
+ </h1>
38
+ <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
39
+ </div>
40
+ <div class="modal-body">
41
+ <ul id="failedCriteriaModalList" class="unbulleted-list">
42
+ <!-- dynamically populated -->
43
+ </ul>
44
+ </div>
45
+ </div>
46
+ </div>
47
+ </div>