From 15cc07dff7ec0d89a38e88188f48c5f2eacd2537 Mon Sep 17 00:00:00 2001 From: Jason Morris Date: Wed, 31 Dec 2025 14:16:15 -0500 Subject: [PATCH 01/17] Add plan --- PLAN.md | 226 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 226 insertions(+) create mode 100644 PLAN.md diff --git a/PLAN.md b/PLAN.md new file mode 100644 index 0000000..c2728c5 --- /dev/null +++ b/PLAN.md @@ -0,0 +1,226 @@ +# Bookmarklet Codebase Improvement Plan + +## Current State Analysis + +### What Works Well +- **Clean build pipeline**: `build.js` handles minification, encoding, and Netscape HTML generation effectively +- **Modern tooling**: ESBuild for bundling, Eleventy for static site generation, ESLint/Prettier for quality +- **Good CI/CD**: Automated testing on PR, deployment to GitHub Pages on merge +- **Test pages**: 59 of 63 bookmarklets have test/demo HTML pages + +### Current Pain Points + +1. **Dual-File Maintenance**: Adding a new bookmarklet requires editing TWO files: + - Create `bookmarklets/my-bookmarklet.js` + - Manually add entry to `data/bookmarklets.json` + +2. **Disconnected Metadata**: Bookmarklet metadata lives in JSON, separate from the source file. Easy to get out of sync. + +3. **Test Page Boilerplate**: Each test page requires YAML frontmatter that partially duplicates JSON data: + ```yaml + permalink: "are-ya-hidden/" + file: "are-ya-hidden.js" # Must match JSON + layout: test + title: are ya hidden # Duplicates bookmarklet name + ``` + +4. **No Auto-Discovery**: New JS files aren't detected; must manually add to JSON. + +5. **No Validation**: No build-time checks that: + - Every JS file has a corresponding JSON entry + - Every JSON entry points to an existing JS file + - Test pages match their expected bookmarklets + +6. **No Scaffolding**: No easy way to create a new bookmarklet with all required files. + +--- + +## Proposed Improvements + +### Phase 1: Single Source of Truth (Metadata in JS Files) + +**Goal**: Move bookmarklet metadata into the JS source files as structured comments, eliminating the need to edit two files. + +#### Implementation + +Add JSDoc-style metadata block to each bookmarklet: + +```javascript +/** + * @bookmarklet Are ya hidden? + * @description Display hidden content + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags accessibility + * @auditing false + * @pageTest true + */ +(function() { + // bookmarklet code... +})(); +``` + +**Build process changes** (`build.js`): +1. Scan `bookmarklets/*.js` for files (auto-discovery) +2. Parse metadata from JSDoc comment block in each file +3. Generate `data/bookmarklets.json` from extracted metadata +4. Continue with existing minification/encoding pipeline + +**Benefits**: +- Single file to edit when adding/updating a bookmarklet +- Metadata stays with code - harder to get out of sync +- Self-documenting source files +- Easier code review (all context in one place) + +--- + +### Phase 2: Auto-Generated Test Page Stubs + +**Goal**: Reduce boilerplate for test pages by auto-generating the frontmatter. + +#### Option A: Simplified Frontmatter (Recommended) +Test pages only need to specify the file reference: + +```yaml +--- +file: are-ya-hidden.js +--- +
+ +
+``` + +The layout template derives all other data (`permalink`, `title`, `description`) from the bookmarklets data. + +**Layout change** (`_includes/layouts/test.html`): +```liquid +--- +layout: page +permalink: "{{ file | replace: '.js', '/' }}" +--- +{% assign bm = bookmarklets | where: "file", file | first %} +

{{ bm.bookmarklet }}

+... +``` + +#### Option B: Convention-Based (No Frontmatter Needed) +Use Eleventy's computed data to auto-match HTML files to their JS counterparts by filename convention: +- `bookmarklets/foo.js` → auto-matched by `bookmarklets/foo.html` + +--- + +### Phase 3: Scaffolding Script + +**Goal**: Make adding new bookmarklets trivially easy. + +Create `scripts/new-bookmarklet.js`: + +```bash +npm run new -- --name "My Bookmarklet" --author "Your Name" +``` + +This generates: +1. `bookmarklets/my-bookmarklet.js` with metadata template +2. `bookmarklets/my-bookmarklet.html` test page stub + +**package.json addition**: +```json +"scripts": { + "new": "node scripts/new-bookmarklet.js" +} +``` + +--- + +### Phase 4: Build-Time Validation + +**Goal**: Catch errors early in CI. + +Add validation step to `build.js`: + +1. **Orphan detection**: + - JS files without metadata → error + - JSON entries pointing to missing JS files → error + +2. **Test page validation**: + - If `pageTest: true`, verify HTML file exists + - Warn about bookmarklets without test pages + +3. **Metadata completeness**: + - Required fields: `bookmarklet`, `description`, `file` + - Warn on missing optional fields: `author`, `authorUrl`, `tags` + +--- + +### Phase 5: Documentation + +**Goal**: Clear onboarding for contributors. + +Create/update `CONTRIBUTING.md`: + +```markdown +# Adding a New Bookmarklet + +1. Run the scaffolding script: + ```bash + npm run new -- --name "My Tool" --author "Your Name" + ``` + +2. Edit the generated JS file in `bookmarklets/` + +3. Add test content to the generated HTML file + +4. Run `npm start` to test locally + +5. Submit a PR +``` + +--- + +## Proposed File Structure (After Improvements) + +``` +bookmarklets/ +├── bookmarklets/ +│ ├── my-bookmarklet.js # Source + metadata in comments +│ └── my-bookmarklet.html # Test page (minimal frontmatter) +├── scripts/ +│ └── new-bookmarklet.js # Scaffolding tool +├── data/ +│ ├── bookmarklets.json # Auto-generated from JS metadata +│ ├── auditing.json # Auto-generated (filtered) +│ ├── bookmarks.html # Netscape format (all) +│ └── auditing.html # Netscape format (favorites) +├── build.js # Enhanced with metadata extraction +├── CONTRIBUTING.md # Clear process documentation +└── ... +``` + +--- + +## Implementation Priority + +| Phase | Effort | Impact | Recommendation | +|-------|--------|--------|----------------| +| Phase 1: Metadata in JS | Medium | High | **Do first** - biggest maintenance win | +| Phase 2: Simpler test pages | Low | Medium | Quick follow-up | +| Phase 3: Scaffolding | Low | Medium | Nice to have | +| Phase 4: Validation | Medium | High | Important for CI | +| Phase 5: Documentation | Low | High | Essential | + +--- + +## Backward Compatibility + +- The JSON structure and Netscape HTML output remain identical +- External consumers of `bookmarklets.json` are unaffected +- Test page URLs stay the same + +--- + +## Questions for Consideration + +1. **Metadata format**: JSDoc-style (`@tag`) vs JSON5 block vs YAML frontmatter in JS comments? +2. **Test page generation**: Should test pages be fully auto-generated for simple cases (just showing the button)? +3. **Categories/tags**: Current tags are inconsistent. Should there be a defined taxonomy? +4. **`pageTest: "self"`**: Keep this convention or handle differently? From 45fd745a6550324ef8bdacbab5470b1e572b6c21 Mon Sep 17 00:00:00 2001 From: Jason Morris Date: Wed, 31 Dec 2025 14:22:42 -0500 Subject: [PATCH 02/17] Implement Phase 1: Single source of truth for metadata Move bookmarklet metadata from data/bookmarklets.json into the source JS files as JSDoc-style comment blocks. The build process now: - Auto-discovers JS files in bookmarklets/ directory - Parses @bookmarklet, @description, @author, @authorUrl, @tags, @auditing, and @pageTest metadata from JSDoc comments - Generates bookmarklets.json from extracted metadata - Continues with existing minification/encoding pipeline This eliminates the need to edit two files when adding or updating a bookmarklet. Metadata stays with code, reducing sync issues. --- bookmarklets/are-ya-hidden.js | 20 +- bookmarklets/auto-complete.js | 9 + bookmarklets/background-images.js | 8 + bookmarklets/blur-page.js | 8 + bookmarklets/buttons.js | 9 + bookmarklets/character-keys.js | 9 + bookmarklets/color-scheme.js | 8 + bookmarklets/complex-table.js | 8 + bookmarklets/cursor-24x24.js | 8 + bookmarklets/cursor-44x44.js | 8 + bookmarklets/design-mode-toggle.js | 8 + bookmarklets/disable-css.js | 8 + bookmarklets/duplicate-ids.js | 8 + bookmarklets/find-duplicate-aria-roles.js | 9 + bookmarklets/focus-everything.js | 9 + bookmarklets/force-focus.js | 9 + bookmarklets/grayscale.js | 8 + bookmarklets/grouped-fields.js | 31 ++- bookmarklets/headings-console.js | 9 + bookmarklets/headings.js | 9 + bookmarklets/hide-cursor.js | 8 + bookmarklets/horizontal-scroll.js | 9 + bookmarklets/html-link.js | 8 + bookmarklets/image-info.js | 8 + bookmarklets/images.js | 9 + bookmarklets/inline-styles.js | 8 + bookmarklets/isolator.js | 42 +-- bookmarklets/keyboard-visualizer.js | 8 + bookmarklets/language.js | 9 + bookmarklets/links.js | 9 + bookmarklets/markdown-link.js | 8 + bookmarklets/non-underlined-links.js | 34 ++- bookmarklets/page-link.js | 9 + bookmarklets/parsing-only.js | 9 + bookmarklets/placeholder-contrast.js | 9 + bookmarklets/re-enable-selection.js | 8 + bookmarklets/service-html-validator.js | 9 + bookmarklets/service-internet-archive.js | 8 + bookmarklets/service-lighthouse.js | 8 + bookmarklets/service-wave.js | 8 + bookmarklets/show-focus-styles.js | 20 +- bookmarklets/strip-onpaste.js | 8 + bookmarklets/test-csp.js | 8 + bookmarklets/test-js-local.js | 8 + bookmarklets/text-spacing.js | 9 + bookmarklets/text-zoom.js | 8 + bookmarklets/titles.js | 9 + bookmarklets/tool-a11y-css.js | 8 + bookmarklets/tool-andi.js | 9 + bookmarklets/tool-aria-usage.js | 7 + bookmarklets/tool-aria.js | 7 + bookmarklets/tool-contrast-checker.js | 8 + bookmarklets/tool-html-codesniffer.js | 8 + bookmarklets/tool-label-in-name.js | 8 + bookmarklets/tool-sa11y.js | 8 + bookmarklets/truncation.js | 8 + bookmarklets/user-agent.js | 8 + bookmarklets/viewport.js | 8 + bookmarklets/window-1280x1024.js | 9 + bookmarklets/window-320x256.js | 8 + bookmarklets/wtfocus.js | 98 ++++--- bookmarklets/youtube-uc-id.js | 8 + build.js | 104 +++++++- data/auditing.html | 6 +- data/auditing.json | 146 +++++----- data/bookmarklets.json | 312 +++++++++++----------- data/bookmarks.html | 8 +- 67 files changed, 949 insertions(+), 338 deletions(-) diff --git a/bookmarklets/are-ya-hidden.js b/bookmarklets/are-ya-hidden.js index fef6fe4..1fb3082 100644 --- a/bookmarklets/are-ya-hidden.js +++ b/bookmarklets/are-ya-hidden.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Are ya hidden? + * @description Display hidden content + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags accessibility + * @pageTest true + */ (function () { var allElements = document.querySelectorAll("*"); function findAllVisuallyHiddenElements() { @@ -16,7 +24,7 @@ o < cs.length; o++ ) - ((cssProperty = cs[o]), + (cssProperty = cs[o]), (cssValue = cs.getPropertyValue(cssProperty)), "clip" === cssProperty && "rect(1px, 1px, 1px, 1px)" === cssValue && @@ -27,7 +35,7 @@ "overflow-y" === cssProperty && "hidden" === cssValue && (l = !0), "position" === cssProperty && "absolute" === cssValue && (s = !0), "white-space" === cssProperty && "nowrap" === cssValue && (r = !0), - "width" === cssProperty && "1px" === cssValue && (d = !0)); + "width" === cssProperty && "1px" === cssValue && (d = !0); !0 === a && !0 === t && !0 === e && @@ -38,7 +46,7 @@ !0 === d && i.classList.add("was-visually-hidden"); let c = i.classList; - (c.forEach((a) => { + c.forEach((a) => { -1 !== a.indexOf("-offscreen") && i.classList.add("was-visually-hidden"); }), @@ -46,14 +54,14 @@ i.classList.contains("screenreader-only") || i.classList.contains("visually-hidden") || i.classList.contains("visuallyhidden")) && - i.classList.add("was-visually-hidden")); + i.classList.add("was-visually-hidden"); }); } function indicateAriaHiddenElements(i) { findAllVisuallyHiddenElements(); var a, t = i.createElement("style"); - (i.head.appendChild(t), + i.head.appendChild(t), (a = t.sheet).insertRule( "[aria-hidden=true] {background:black;color:black;}", 0 @@ -62,7 +70,7 @@ a.insertRule( ".was-visually-hidden {clip-path: initial!important;clip: initial!important;height: auto!important;overflow: initial!important;position: initial!important;white-space: initial!important;width: auto!important;opacity:initial!important;z-index:initial!important;background:black!important;color:lime!important;}", 0 - )); + ); } indicateAriaHiddenElements(document); var iframes = document.querySelectorAll("iframe"); diff --git a/bookmarklets/auto-complete.js b/bookmarklets/auto-complete.js index 1e6f455..5efafa9 100644 --- a/bookmarklets/auto-complete.js +++ b/bookmarklets/auto-complete.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Autocomplete + * @description Display all fields with autocomplete + * @author Rachele DiTullio + * @authorUrl https://racheleditullio.com/blog/2023/11/autocomplete-accessibility-bookmarklet/ + * @tags 1.3.5 Identify Input Purpose (AA) + * @auditing true + * @pageTest true + */ (function () { let divs = document.querySelectorAll(".autocomplete-info"); if (divs.length > 0) { diff --git a/bookmarklets/background-images.js b/bookmarklets/background-images.js index 8d0bfe7..6fe18f9 100644 --- a/bookmarklets/background-images.js +++ b/bookmarklets/background-images.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Background images + * @description Highlight all CSS background images + * @author Zoe Mickley Gillenwater + * @authorUrl https://zomigi.com/blog/bookmarklets-for-accessibility-testing/ + * @tags utility + * @pageTest true + */ (function () { var tags = document.getElementsByTagName("*"); var element; diff --git a/bookmarklets/blur-page.js b/bookmarklets/blur-page.js index e8962d0..53c80b8 100644 --- a/bookmarklets/blur-page.js +++ b/bookmarklets/blur-page.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Blur page + * @description Blur entire page + * @author Thomas Park + * @authorUrl https://thomaspark.co/2013/11/3-simple-design-bookmarklets-to-improve-your-aesthetics/ + * @tags diagnostic + * @pageTest false + */ (function () { document.body.setAttribute( "style", diff --git a/bookmarklets/buttons.js b/bookmarklets/buttons.js index 070295b..17399c5 100644 --- a/bookmarklets/buttons.js +++ b/bookmarklets/buttons.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Buttons + * @description Display all buttons + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags accessibility + * @auditing true + * @pageTest false + */ (function () { "use strict"; function listButtons() { diff --git a/bookmarklets/character-keys.js b/bookmarklets/character-keys.js index ccdb154..7bdfb8d 100644 --- a/bookmarklets/character-keys.js +++ b/bookmarklets/character-keys.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Character key shortcuts + * @description Test all printable character shortcut keys + * @author Detlev Fischer + * @authorUrl http://3needs.org/en/testing/code/kb-shortcuts.html + * @tags 2.1.4 Character Key Shortcuts (A) + * @auditing true + * @pageTest true + */ (function () { var e; var n = 32; diff --git a/bookmarklets/color-scheme.js b/bookmarklets/color-scheme.js index 0b1e270..2ed8643 100644 --- a/bookmarklets/color-scheme.js +++ b/bookmarklets/color-scheme.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Toggle color scheme + * @description Switch between light and dark color scheme + * @author Thomas Orlita + * @authorUrl https://github.com/ThomasOrlita/awesome-bookmarklets#dark-color-scheme + * @tags css + * @pageTest self + */ document.documentElement.style.colorScheme = document.documentElement.style.colorScheme == "dark" ? "light" : "dark"; void 0; diff --git a/bookmarklets/complex-table.js b/bookmarklets/complex-table.js index 39e09a2..fb03ecc 100644 --- a/bookmarklets/complex-table.js +++ b/bookmarklets/complex-table.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Complex table + * @description Visualize headers and IDs in a complex table + * @author Jonathan Avila + * @authorUrl https://labs.levelaccess.com/index.php/Complex_Tables_Favlet + * @tags accessibility + * @pageTest true + */ (function () { var el = document.querySelectorAll("td, th"); diff --git a/bookmarklets/cursor-24x24.js b/bookmarklets/cursor-24x24.js index 02eaefe..06c4ad8 100644 --- a/bookmarklets/cursor-24x24.js +++ b/bookmarklets/cursor-24x24.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Cursor 24x24 + * @description Change cursor to 24px by 24px circle + * @author Adrian Roselli + * @authorUrl https://adrianroselli.com/2022/05/24x24-pixel-cursor-bookmarklet.html#Update01 + * @tags 2.5.8 Target Size (Minimum) (2.2 AA) + * @pageTest self + */ (function () { var d = document, id = "AAR24pxBkmklt1", diff --git a/bookmarklets/cursor-44x44.js b/bookmarklets/cursor-44x44.js index 219a3ea..26cbd9d 100644 --- a/bookmarklets/cursor-44x44.js +++ b/bookmarklets/cursor-44x44.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Cursor 44x44 + * @description Change cursor to 44px by 44px square + * @author Adrian Roselli + * @authorUrl https://adrianroselli.com/2019/06/target-size-and-2-5-5.html#Update04 + * @tags 2.5.5 Target Size (AAA) + * @pageTest self + */ (function () { var style = document.createElement("style"), styleContent = document.createTextNode( diff --git a/bookmarklets/design-mode-toggle.js b/bookmarklets/design-mode-toggle.js index 2c4b43c..c3f8c80 100644 --- a/bookmarklets/design-mode-toggle.js +++ b/bookmarklets/design-mode-toggle.js @@ -1,2 +1,10 @@ +/** + * @bookmarklet Design mode toggle + * @description Make all of the text on page editable + * @author Christoph Wagner + * @authorUrl https://developer.mozilla.org/en-US/docs/Web/API/SecurityPolicyViolationEvent#examples + * @tags diagnostic + * @pageTest false + */ document.designMode = document.designMode == "on" ? "off" : "on"; void 0; diff --git a/bookmarklets/disable-css.js b/bookmarklets/disable-css.js index 387198d..5b98828 100644 --- a/bookmarklets/disable-css.js +++ b/bookmarklets/disable-css.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Disable CSS + * @description Drop all page styles + * @author Sarah Higley + * @authorUrl https://dorward.uk/software/disablecss/ + * @tags diagnostic, accessibility, css + * @pageTest false + */ for (var i = 0; i < document.styleSheets.length; i++) { void (document.styleSheets.item(i).disabled = true); } diff --git a/bookmarklets/duplicate-ids.js b/bookmarklets/duplicate-ids.js index f12a307..11a43f8 100644 --- a/bookmarklets/duplicate-ids.js +++ b/bookmarklets/duplicate-ids.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Duplicate IDs + * @description Display duplicated ID values + * @author Jonathan Avila + * @authorUrl https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/duplicateIds.js + * @tags accessibility + * @pageTest true + */ function runDuplicateIds() { var clone = document.cloneNode(true); var col = clone.querySelectorAll("[id]"); diff --git a/bookmarklets/find-duplicate-aria-roles.js b/bookmarklets/find-duplicate-aria-roles.js index 07bc179..f9dff0c 100644 --- a/bookmarklets/find-duplicate-aria-roles.js +++ b/bookmarklets/find-duplicate-aria-roles.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Find Duplicate ARIA Roles + * @description Roles appearing more than once for banner, contentinfo, and main + * @author Adrian Roselli + * @authorUrl https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#ARIAdupes + * @tags accessibility, HTML + * @auditing true + * @pageTest true + */ (function () { var a = document.createElement("style"), b; diff --git a/bookmarklets/focus-everything.js b/bookmarklets/focus-everything.js index 624a8f5..a97e216 100644 --- a/bookmarklets/focus-everything.js +++ b/bookmarklets/focus-everything.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Focus everything + * @description A technique for testing 1.3.2 Meaningful Sequence a tab path visualizer + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags 1.3.2 Meaningful Sequence (A) + * @auditing true + * @pageTest true + */ document.querySelectorAll("body *").forEach(function (el) { el.setAttribute("tabindex", "0"); }); diff --git a/bookmarklets/force-focus.js b/bookmarklets/force-focus.js index c6103af..356ca7a 100644 --- a/bookmarklets/force-focus.js +++ b/bookmarklets/force-focus.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Force focus indicator + * @description Adds a 4 pixel solid orange outline around all focusable elements + * @author Paul J. Adam + * @authorUrl https://pauljadam.com/bookmarklets/focus.html + * @tags accessibility + * @auditing true + * @pageTest false + */ var style = document.createElement("style"), styleContent = document.createTextNode( "a:focus, *:focus { outline: 4px solid orange !important; outline-offset:1px !important; }" diff --git a/bookmarklets/grayscale.js b/bookmarklets/grayscale.js index a38b352..894f2ad 100644 --- a/bookmarklets/grayscale.js +++ b/bookmarklets/grayscale.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Grayscale + * @description Show entire page in gray scale (no color) + * @author Level Access + * @authorUrl https://labs.levelaccess.com/index.php/Grayscale_Favlet + * @tags accessibility + * @pageTest false + */ (function () { let style = document.createElement("style"); style.type = "text/css"; diff --git a/bookmarklets/grouped-fields.js b/bookmarklets/grouped-fields.js index c7da905..0889f54 100644 --- a/bookmarklets/grouped-fields.js +++ b/bookmarklets/grouped-fields.js @@ -1,16 +1,23 @@ +/** + * @bookmarklet Grouped fields + * @description Display grouped fields + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags accessibility + */ (function () { function outlineGroupedFIelds() { let e = "#662e2e", l = 0; function r(e, r) { - ((e.style.boxShadow = "0px 0px 0px 10px white"), + (e.style.boxShadow = "0px 0px 0px 10px white"), (e.style.outline = "5px solid " + r), (e.style.outlineOffset = "5px"), - l++); + l++; } function t(e, l, r) { let t = document.createElement("span"); - ((t.innerHTML = l), + (t.innerHTML = l), (t.style.display = "inline-block"), (t.style.margin = "20px 0 5px -10px"), (t.style.padding = "5px"), @@ -18,15 +25,15 @@ (t.style.fontWeight = "bold"), (t.style.fontSize = "18px"), (t.style.color = "white"), - t.classList.add("group-description")); + t.classList.add("group-description"); let o = e.parentNode; o.insertBefore(t, e); } var o, a = document.querySelectorAll("fieldset"); - (console.log(a), + console.log(a), Array.from(a).forEach((l) => { - (console.log(l), + console.log(l), r(l, e), l.querySelector("legend") && t( @@ -35,7 +42,7 @@ l.querySelector("legend").textContent + '"', e - )); + ); }), (e = "#66482e"), Array.from( @@ -45,7 +52,7 @@ ).forEach((l) => { console.log(l); let o = l.getAttribute("role").toLowerCase(); - (r(l, e), + r(l, e), t( l, "Group label (from [role=" + @@ -54,7 +61,7 @@ l.getAttribute("aria-label") + '"', e - )); + ); }), (e = "#662e43"), Array.from( @@ -66,7 +73,7 @@ let o = l.getAttribute("role").toLowerCase(); r(l, e); let a = "Source for aria-labelledby is missing/broken"; - (document.querySelector("#" + l.getAttribute("aria-labelledby")) && + document.querySelector("#" + l.getAttribute("aria-labelledby")) && (a = document.querySelector( "#" + l.getAttribute("aria-labelledby") ).textContent), @@ -78,9 +85,9 @@ a + '"', e - )); + ); }), - 0 === l && alert("No grouped fields found on this page")); + 0 === l && alert("No grouped fields found on this page"); } outlineGroupedFIelds(); })(); diff --git a/bookmarklets/headings-console.js b/bookmarklets/headings-console.js index 94e5a2f..addc53d 100644 --- a/bookmarklets/headings-console.js +++ b/bookmarklets/headings-console.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Document outline in console + * @description Display level of all page headings in console + * @author Mu-An Chiou + * @authorUrl https://github.com/muan/headings + * @tags accessibility + * @auditing true + * @pageTest self + */ let map = ""; for (const heading of document.querySelectorAll("h1, h2, h3, h4, h5, h6")) { diff --git a/bookmarklets/headings.js b/bookmarklets/headings.js index dc65006..443436d 100644 --- a/bookmarklets/headings.js +++ b/bookmarklets/headings.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Headings + * @description Display level of all page headings + * @author Jonathan Avila + * @authorUrl https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/headings.js + * @tags 1.3.1 Info and Relationships (A), 2.4.6 Headings and Labels (AA) + * @auditing true + * @pageTest self + */ // *********************************************** function traverseFrames(doc) { showHeading(doc); diff --git a/bookmarklets/hide-cursor.js b/bookmarklets/hide-cursor.js index 29a7e72..decec0b 100644 --- a/bookmarklets/hide-cursor.js +++ b/bookmarklets/hide-cursor.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Hide cursor + * @description Hides cursor from window to encourage keyboard use + * @author Iain Bean + * @authorUrl https://iainbean.com/posts/2020/an-opinionated-guide-to-accessibility-testing/ + * @tags accessibility, 2.1, 2.1.1 (A), 2.1.2 (A), 2.1.4 (A), WCAG, cursor + * @pageTest false + */ var style = document.createElement("style"), styleContent = document.createTextNode( '* { cursor: none !important; } body::after{ position: absolute; top: 0; right: 4px; background-color: #000; color: #01ff70; z-index: 9999; font-size: 16px; font-weight: 400; padding: 3px 9px; outline: 4px solid #01ff70 !important; content: "hiding cursor";}' diff --git a/bookmarklets/horizontal-scroll.js b/bookmarklets/horizontal-scroll.js index 9163038..795a780 100644 --- a/bookmarklets/horizontal-scroll.js +++ b/bookmarklets/horizontal-scroll.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Horizontal scroll + * @description Alert when a horizontal scrollbar appears + * @author Jason Morris + * @authorUrl https://jasonmorris.com + * @tags accessibility + * @auditing true + * @pageTest true + */ (function () { let prevWidth = document.documentElement.clientWidth; let scrollbarAppeared = false; diff --git a/bookmarklets/html-link.js b/bookmarklets/html-link.js index 4c74940..3b5e275 100644 --- a/bookmarklets/html-link.js +++ b/bookmarklets/html-link.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet HTML link + * @description Copy page title and URL in an HTML anchor + * @author Jason Morris + * @authorUrl https://jasonmorris.com + * @tags utility + * @pageTest self + */ var text = '' + document.title + ""; window.prompt("HTML link:", text); void 0; diff --git a/bookmarklets/image-info.js b/bookmarklets/image-info.js index 370df40..6b92b2a 100644 --- a/bookmarklets/image-info.js +++ b/bookmarklets/image-info.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Image info + * @description Display image alt, role, title, aria-label, aria-labelledby + * @author Jonathan Avila + * @authorUrl https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/images.js + * @tags 1.1.1 Non-text Content (A), 1.4.5 Images of Text (A), 2.4.4 Link Purpose (In Context) (A) + * @pageTest true + */ // *********************************** // function traverseFrames(doc, _framesObj) { // check for alt, aria-label,title, or aria-labelledby attribute in current document and then check it's frames diff --git a/bookmarklets/images.js b/bookmarklets/images.js index 09e36b3..3b829a5 100644 --- a/bookmarklets/images.js +++ b/bookmarklets/images.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Images + * @description Display all images + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags 1.1.1 Non-text Content (A), 1.4.5 Images of Text (A), 2.4.4 Link Purpose (In Context) (A) + * @auditing true + * @pageTest true + */ (function () { "use strict"; function listImages() { diff --git a/bookmarklets/inline-styles.js b/bookmarklets/inline-styles.js index d97f25e..8df0164 100644 --- a/bookmarklets/inline-styles.js +++ b/bookmarklets/inline-styles.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Inline styles + * @description Highlight all elements with style attributes + * @author Adrian Roselli + * @authorUrl https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#inline + * @tags utility + * @pageTest true + */ var style = document.createElement("style"), styleContent = document.createTextNode( '[style]{ position: relative; outline: 4px solid #01ff70 !important;} [style]:after{ content: "inline style"; position: absolute; top: 0; right: 0; background-color: #000; color: #01ff70; z-index: 9999; font-size: 12px; font-weight: 400; padding: 1px 3px;} body::after{ position: absolute; top: 0; right: 4px; background-color: #000; color: #01ff70; z-index: 9999; font-size: 16px; font-weight: 400; padding: 3px 9px; outline: 4px solid #01ff70 !important; content: "inline styles";}}' diff --git a/bookmarklets/isolator.js b/bookmarklets/isolator.js index 561ba74..afa7eab 100644 --- a/bookmarklets/isolator.js +++ b/bookmarklets/isolator.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Isolator + * @description Isolate a portion of the page + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags accessibility + * @pageTest false + */ (function () { "use strict"; function getXpath(e) { @@ -12,16 +20,16 @@ if ((t = o.parentNode).tagName) { i = t.tagName.toLowerCase(); const e = t.querySelectorAll(":scope > " + o.tagName); - ((r = + (r = e.length > 1 ? "[" + parseInt(Array.from(e).indexOf(o) + 1) + "]" : ""), (a = (n = o.tagName.toLowerCase()) + r + l + a), - (l = "/")); + (l = "/"); } o = t; } - return ("" === i && (i = n), (a = "//" + i + r + l + a)); + return "" === i && (i = n), (a = "//" + i + r + l + a); } function isolate() { let e, @@ -31,7 +39,7 @@ i = !1; const a = document.querySelectorAll("*"); function r(t, o) { - ((e = t), o.stopPropagation(), i || s(t), d(e)); + (e = t), o.stopPropagation(), i || s(t), d(e); } function l(e) { e.classList.remove("isolatorHighlight"); @@ -40,14 +48,14 @@ e.classList.add("isolatorHighlight"); } function d(e) { - (console.clear(), console.log(getXpath(e)), (o.innerHTML = getXpath(e))); + console.clear(), console.log(getXpath(e)), (o.innerHTML = getXpath(e)); } - (Array.from(a).forEach((t) => { - (t.addEventListener("click", (o) => { - (console.log("preventClicks = ", n), + Array.from(a).forEach((t) => { + t.addEventListener("click", (o) => { + console.log("preventClicks = ", n), n && (!(function (t, o) { - ((e = t), "HTML" === t.tagName && (n = !1)); + (e = t), "HTML" === t.tagName && (n = !1); !(function (e) { if (!i) { const t = e.parentNode, @@ -60,20 +68,20 @@ } })(t); })(t), - o.preventDefault())); + o.preventDefault()); }), t.addEventListener("mouseover", (o) => { - ((e = t), o.stopPropagation(), i || s(t), d(e)); + (e = t), o.stopPropagation(), i || s(t), d(e); }), t.addEventListener("mouseout", (e) => { l(t); - })); + }); }), (function () { const e = document.createElement("style"); - ((e.textContent = + (e.textContent = ".isolatorHighlight{outline:4px solid black!important;outline-offset:-4px!important;-webkit-box-shadow: 0px 0px 0px 4px #fff; box-shadow: 0px 0px 0px 4px #fff;}#infoPanel {z-index:1000;font-size:20px;background:rgba(0,0,0,0.8);color:#fff;font-weight:bold;padding:10px;position:fixed;bottom:20px;left:20px;font-family:sans-serif;} #infoPanel:empty {visibility:hidden;} #infoPanel code {color:lime}"), - document.head.appendChild(e)); + document.head.appendChild(e); })(), (o = document.createElement("div")).setAttribute("id", "infoPanel"), o.setAttribute("role", "status"), @@ -104,14 +112,14 @@ l(e); let t, o = !1; - (Array.from(e.childNodes).forEach((e) => { + Array.from(e.childNodes).forEach((e) => { 1 !== e.nodeType || o || ((o = !0), (t = e)); }), - t && r((e = t), n)); + t && r((e = t), n); } "Enter" === n.key && (n.preventDefault(), e.click()); }), - d("Isolator started. Click on element you want to isolate in the DOM")); + d("Isolator started. Click on element you want to isolate in the DOM"); } isolate(); })(); diff --git a/bookmarklets/keyboard-visualizer.js b/bookmarklets/keyboard-visualizer.js index 5946356..b32cc2f 100644 --- a/bookmarklets/keyboard-visualizer.js +++ b/bookmarklets/keyboard-visualizer.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Keyboard visualizer + * @description Creates an overlay to display typed keys on the underlying page + * @author Sarah Higley + * @authorUrl https://codepen.io/smhigley/pen/eYEjKQz + * @tags utility + * @pageTest self + */ const visualizerStyles = ` .sh-keyboard-viz { position: fixed; diff --git a/bookmarklets/language.js b/bookmarklets/language.js index 5507f7f..0c1a1f7 100644 --- a/bookmarklets/language.js +++ b/bookmarklets/language.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Language of page/parts + * @description Display all lang attributes on page + * @author Jason Morris + * @authorUrl https://jasonmorris.com + * @tags 3.1.1 Language of Page (A), 3.1.2 Language of Parts (AA) + * @auditing true + * @pageTest true + */ var el = document.querySelectorAll("[lang]"), page = document.querySelector("html[lang]"), msg = ""; diff --git a/bookmarklets/links.js b/bookmarklets/links.js index 81edd76..7c218cc 100644 --- a/bookmarklets/links.js +++ b/bookmarklets/links.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Links + * @description Display all links + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags accessibility + * @auditing true + * @pageTest false + */ (function () { "use strict"; function listLinks() { diff --git a/bookmarklets/markdown-link.js b/bookmarklets/markdown-link.js index 6500760..5d05b30 100644 --- a/bookmarklets/markdown-link.js +++ b/bookmarklets/markdown-link.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Markdown link + * @description Copy page title and URL in markdown link format + * @author Brian Cantoni + * @authorUrl http://www.cantoni.org/2013/11/08/bookmarklet-copy-markdown-link + * @tags utility + * @pageTest self + */ var text = "[" + document.title + "](" + location.href + ")"; window.prompt("Markdown link:", text); void 0; diff --git a/bookmarklets/non-underlined-links.js b/bookmarklets/non-underlined-links.js index 8899420..7cd801b 100644 --- a/bookmarklets/non-underlined-links.js +++ b/bookmarklets/non-underlined-links.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Non-underlined links + * @description Display information about links without underlines + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags 1.4.1 Use of Color (A) + * @auditing true + * @pageTest true + */ (function () { "use strict"; var consoleOutput = ""; @@ -27,9 +36,9 @@ if ( ((function () { const e = document.createElement("style"); - ((e.textContent = + (e.textContent = ".problem-highlight {outline:5px solid darkred;outline-offset:3px;box-shadow: 0px 0px 0px 10px #fff;}"), - document.head.appendChild(e)); + document.head.appendChild(e); })(), Array.from(r).forEach((r) => { if ( @@ -40,6 +49,7 @@ ; (e = e.parentElement) && !(e.matches || e.matchesSelector).call(e, t); + ); return e; })(r, "nav,[role=navigation]")), @@ -50,24 +60,24 @@ "FIGURE" !== r.childNodes[0].tagName.toUpperCase()) || (a = !0)), !(function (n) { - ((e = !1), (t = !1), (o = !1)); + (e = !1), (t = !1), (o = !1); const r = getComputedStyle(n); for (let n = 0; n < r.length; n++) { const l = r[n], a = r.getPropertyValue(l); - ("text-decoration-line" === l && "underline" === a && (t = !0), + "text-decoration-line" === l && "underline" === a && (t = !0), "border-bottom-style" !== l || ("solid" !== a && "dotted" !== a && "dashed" !== a) || (o = !0), "border-bottom-color" === l && "transparent" === a && (o = !1), - (t || o) && (e = !0)); + (t || o) && (e = !0); } return e; })(r) && !a)) ) { - ((consoleOutput += "-------\n"), + (consoleOutput += "-------\n"), (consoleOutput += "Link text: " + r.textContent + "\n"), n || (!(function (e) { @@ -87,19 +97,19 @@ if ((t = o.parentNode).tagName) { r = t.tagName.toLowerCase(); const e = t.querySelectorAll(o.tagName); - ((a = + (a = e.length > 1 ? "[" + parseInt(Array.from(e).indexOf(o) + 1) + "]" : ""), (l = (n = o.tagName.toLowerCase()) + a + s + l), - (s = "/")); + (s = "/"); } o = t; } - return ("" === r && (r = n), (l = "//" + r + a + s + l)); + return "" === r && (r = n), (l = "//" + r + a + s + l); })(r) + "\n"), - l++)); + l++); const e = (function (e, t) { const o = i(e[0], e[1], e[2]), n = i(t[0], t[1], t[2]); @@ -123,8 +133,8 @@ l > 0) ) { const e = l + " possible issues with non-underlined links found"; - ((consoleOutput = e + "\n" + consoleOutput), - alert(e + " (check console for more details)")); + (consoleOutput = e + "\n" + consoleOutput), + alert(e + " (check console for more details)"); } else alert("No non-underlined links found (outside of a navigation area)"); console.log(consoleOutput); diff --git a/bookmarklets/page-link.js b/bookmarklets/page-link.js index a2302c8..f69d8ed 100644 --- a/bookmarklets/page-link.js +++ b/bookmarklets/page-link.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Page link + * @description Copy page title and URL, separated by hyphens + * @author Jason Morris + * @authorUrl https://jasonmorris.com + * @tags utility + * @auditing true + * @pageTest self + */ var text = document.title + " — " + location.href; window.prompt("Plain text link:", text); void 0; diff --git a/bookmarklets/parsing-only.js b/bookmarklets/parsing-only.js index 068c9bf..59ff909 100644 --- a/bookmarklets/parsing-only.js +++ b/bookmarklets/parsing-only.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Parsing only + * @description Reduce HTML validation results to 4.1.1 Parsing (A) only + * @author Steve Faulkner + * @authorUrl https://cdpn.io/stevef/debug/dyGeywr + * @tags 4.1.1 Parsing (A) + * @auditing true + * @pageTest self + */ (function () { var removeNg = true; var filterStrings = [ diff --git a/bookmarklets/placeholder-contrast.js b/bookmarklets/placeholder-contrast.js index 4708bcc..be43b37 100644 --- a/bookmarklets/placeholder-contrast.js +++ b/bookmarklets/placeholder-contrast.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Placeholder contrast checker + * @description Measure contrast of placeholder text + * @author Jason Morris + * @authorUrl https://jasonmorris.com + * @tags accessibility, 1.4.3 Contrast (Minimum) (AA) + * @auditing true + * @pageTest true + */ javascript: (function () { // Helper function to convert RGB to relative luminance function getLuminance(r, g, b) { diff --git a/bookmarklets/re-enable-selection.js b/bookmarklets/re-enable-selection.js index efc8d33..8c2f27f 100644 --- a/bookmarklets/re-enable-selection.js +++ b/bookmarklets/re-enable-selection.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Re-enable selection + * @description Unset user-select CSS property + * @author Adrian Roselli + * @authorUrl https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#Selection + * @tags diagnostic + * @pageTest true + */ (function () { var a = document.createElement("style"), b; diff --git a/bookmarklets/service-html-validator.js b/bookmarklets/service-html-validator.js index b81d31e..7eedf1c 100644 --- a/bookmarklets/service-html-validator.js +++ b/bookmarklets/service-html-validator.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Validate + * @description Validate HTML of DOM + * @author Deque + * @authorUrl https://dequeuniversity.com/validator + * @tags 4.1.1 Parsing (A) + * @auditing true + * @pageTest self + */ (function () { (function () { var doctypeNode = document.doctype; diff --git a/bookmarklets/service-internet-archive.js b/bookmarklets/service-internet-archive.js index 51e89a4..3c9a11b 100644 --- a/bookmarklets/service-internet-archive.js +++ b/bookmarklets/service-internet-archive.js @@ -1 +1,9 @@ +/** + * @bookmarklet Save to Internet Archive + * @description Submit current URL to the Internet Archive + * @author Jesse Gardner + * @authorUrl https://plasticmind.com/0s-and-1s/bookmarklet-archive-to-wayback-machine/ + * @tags utility + * @pageTest self + */ void window.open("https://web.archive.org/save/" + escape(window.location)); diff --git a/bookmarklets/service-lighthouse.js b/bookmarklets/service-lighthouse.js index b4c89b7..e04d7ee 100644 --- a/bookmarklets/service-lighthouse.js +++ b/bookmarklets/service-lighthouse.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Lighthouse report + * @description Run a Lighthouse scan on current URL (regardless of broswer) + * @author Jeremy Keith + * @authorUrl https://adactio.com/journal/16523 + * @tags performance + * @pageTest self + */ void window.open( "https://googlechrome.github.io/lighthouse/viewer/?psiurl=" + escape(window.location) + diff --git a/bookmarklets/service-wave.js b/bookmarklets/service-wave.js index a1db74c..f331266 100644 --- a/bookmarklets/service-wave.js +++ b/bookmarklets/service-wave.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet WAVE report + * @description Run WebAIM WAVE on the current URL + * @author WebAIM + * @authorUrl https://wave.webaim.org/help + * @tags 1.1.1 Non-text Content (A), 1.3.1 Info and Relationships (A), 1.4.3 Contrast (Minimum) (AA), 2.1.1 Keyboard (A), 2.2.1 Timing Adjustable (A), 2.2.2 Pause, Stop, Hide (A), 2.4.1 Bypass Blocks (A), 2.4.2 Page Titled (A), 2.4.4 Link Purpose (In Context) (A), 2.4.6 Headings and Labels (AA), 3.1.1 Language of Page (A), 3.3.2 Labels or Instructions (A), 4.1.2 Name, Role, Value (A) + * @pageTest false + */ void window.open( "https://wave.webaim.org/report?url=" + escape(window.location) ); diff --git a/bookmarklets/show-focus-styles.js b/bookmarklets/show-focus-styles.js index 6a221fa..3bc9257 100644 --- a/bookmarklets/show-focus-styles.js +++ b/bookmarklets/show-focus-styles.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Show focus styles + * @description Force visibility of all focus styles at the same time + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags 2.4.7 Focus Visible (2.2 A), 2.4.11 Focus Appearance (2.2 AA), 2.4.12 Focus Not Obscured (2.2 AA, 2.4.13 Focus Not Obscured (2.2 AAA) + * @pageTest true + */ (function () { function showAllFocusStyles() { const e = document.querySelectorAll( @@ -5,18 +13,18 @@ ); let t, o = ""; - (console.clear(), + console.clear(), Array.from(e).forEach(function (e) { - ((e.style.transition = "none"), + (e.style.transition = "none"), e.focus(), (t = getComputedStyle(e)), - (o = "")); + (o = ""); for (var s = 0; s < t.length; s++) - ((cssProperty = t[s]), + (cssProperty = t[s]), (cssValue = t.getPropertyValue(cssProperty)), - (o += cssProperty + ":" + cssValue + ";")); + (o += cssProperty + ":" + cssValue + ";"); e.setAttribute("style", o); - })); + }); } showAllFocusStyles(); })(); diff --git a/bookmarklets/strip-onpaste.js b/bookmarklets/strip-onpaste.js index 0acce40..d10ace3 100644 --- a/bookmarklets/strip-onpaste.js +++ b/bookmarklets/strip-onpaste.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Remove onpaste + * @description Remove onpaste attributes from password inputs which fixes security theatre of preventing paste + * @author Jason Morris + * @authorUrl https://jasonmorris.com + * @tags utility + * @pageTest true + */ document.querySelectorAll("input[type=password]").forEach(function (el) { return el.removeAttribute("onpaste"); }); diff --git a/bookmarklets/test-csp.js b/bookmarklets/test-csp.js index 6efea89..06ae99a 100644 --- a/bookmarklets/test-csp.js +++ b/bookmarklets/test-csp.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Test CSP + * @description Test for errors related Content Security Policy (CSP) + * @author SecurityPolicyViolationEvent on MDN + * @authorUrl https://developer.mozilla.org/en-US/docs/Web/API/SecurityPolicyViolationEvent#examples + * @tags diagnostic + * @pageTest self + */ document.addEventListener("securitypolicyviolation", cspCheck, false); var testScript = document.createElement("script"); diff --git a/bookmarklets/test-js-local.js b/bookmarklets/test-js-local.js index 3ae3acf..b9478b1 100644 --- a/bookmarklets/test-js-local.js +++ b/bookmarklets/test-js-local.js @@ -1 +1,9 @@ +/** + * @bookmarklet Test local JS + * @description Test for local JS support via bookmark + * @author Accessible Name and Description Inspector (ANDI) help page + * @authorUrl https://www.ssa.gov/accessibility/andi/help/faq.html + * @tags diagnostic + * @pageTest self + */ alert("Your browser is not blocking JavaScript in favorites/bookmarks"); diff --git a/bookmarklets/text-spacing.js b/bookmarklets/text-spacing.js index 91c1e5d..fb54857 100644 --- a/bookmarklets/text-spacing.js +++ b/bookmarklets/text-spacing.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Text spacing + * @description Test on WCAG 1.4.12 Text Spacing + * @author Steve Faulkner + * @authorUrl https://codepen.io/stevef/pen/YLMqbo + * @tags 1.4.12 Text Spacing (AA) + * @auditing true + * @pageTest self + */ (function () { var d = document, id = "phltsbkmklt", diff --git a/bookmarklets/text-zoom.js b/bookmarklets/text-zoom.js index c9f8b2b..1b03b24 100644 --- a/bookmarklets/text-zoom.js +++ b/bookmarklets/text-zoom.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Text zoom 200% + * @description Zoom text only (not page) size to 200% + * @author Ashlee M. Boyer + * @authorUrl https://ashleemboyer.com/blog/an-accessibility-bookmarklet-for-testing-200-percent-text-size + * @tags accessibility, 1.4.4, WCAG + * @pageTest false + */ (function () { const htmlElement = document.querySelector("html"); const currentFontSize = htmlElement.style.getPropertyValue("font-size"); diff --git a/bookmarklets/titles.js b/bookmarklets/titles.js index e96ac05..a28e378 100644 --- a/bookmarklets/titles.js +++ b/bookmarklets/titles.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Titles + * @description Display all titles + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags accessibility + * @auditing true + * @pageTest false + */ (function () { "use strict"; function listThingsWithTitles() { diff --git a/bookmarklets/tool-a11y-css.js b/bookmarklets/tool-a11y-css.js index 29ad3f0..b4ac39c 100644 --- a/bookmarklets/tool-a11y-css.js +++ b/bookmarklets/tool-a11y-css.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet a11y.css + * @description Warns about possible risks and mistakes in HTML code + * @author Gaël Poupard + * @authorUrl https://ffoodd.github.io/a11y.css/ + * @tags accessibility, css, external + * @pageTest false + */ (function () { var a11ycss = document.createElement("LINK"); a11ycss.href = "https://rawgit.com/ffoodd/a11y.css/master/css/a11y-en.css"; diff --git a/bookmarklets/tool-andi.js b/bookmarklets/tool-andi.js index 442cd3d..6f58cd4 100644 --- a/bookmarklets/tool-andi.js +++ b/bookmarklets/tool-andi.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet ANDI + * @description Accessible Name & Description Inspector is a free accessibility testing tool + * @author Accessible Solutions Branch of the Social Security Administration + * @authorUrl https://www.ssa.gov/accessibility/andi/help/install.html + * @tags accessibility, external + * @auditing true + * @pageTest false + */ void (function () { var andiScript = document.createElement("script"); andiScript.setAttribute( diff --git a/bookmarklets/tool-aria-usage.js b/bookmarklets/tool-aria-usage.js index e1f8705..104aca6 100644 --- a/bookmarklets/tool-aria-usage.js +++ b/bookmarklets/tool-aria-usage.js @@ -1,3 +1,10 @@ +/** + * @bookmarklet ARIA usage + * @description Report on ARIA usage on current URL + * @author TPGi + * @authorUrl https://thepaciellogroup.github.io/WAI-ARIA-Usage/WAI-ARIA_usage.html + * @tags accessibility, external + */ void (function () { var objScript = document.createElement("script"); objScript.setAttribute( diff --git a/bookmarklets/tool-aria.js b/bookmarklets/tool-aria.js index 70e716f..e2ef82d 100644 --- a/bookmarklets/tool-aria.js +++ b/bookmarklets/tool-aria.js @@ -1,3 +1,10 @@ +/** + * @bookmarklet ARIA + * @description Display ARIA information for accessibility testing + * @author Paul J. Adam + * @authorUrl https://pauljadam.com/bookmarklets/aria.html + * @tags accessibility, external + */ (function () { document.body.appendChild(document.createElement("script")).src = "https://cdn.jsdelivr.net/gh/pauljadam/bookmarklets@master/aria.js"; diff --git a/bookmarklets/tool-contrast-checker.js b/bookmarklets/tool-contrast-checker.js index 0964bf0..d6eb953 100644 --- a/bookmarklets/tool-contrast-checker.js +++ b/bookmarklets/tool-contrast-checker.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Contrast checker + * @description Contrast checker for color combinations + * @author WebAIM + * @authorUrl https://webaim.org/resources/contrastchecker/bookmarklet + * @tags 1.4.1, 1.4.3, 1.4.11 + * @pageTest false + */ (function () { var constrastletelem = document.getElementById("contrastletdragable"); if (constrastletelem == null) { diff --git a/bookmarklets/tool-html-codesniffer.js b/bookmarklets/tool-html-codesniffer.js index bed3e51..9839c57 100644 --- a/bookmarklets/tool-html-codesniffer.js +++ b/bookmarklets/tool-html-codesniffer.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet HTML CodeSniffer + * @description Checks HTML source code and detects violations of a defined coding standard + * @author Squiz Labs + * @authorUrl https://squizlabs.github.io/HTML_CodeSniffer/ + * @tags accessibility, external + * @pageTest false + */ (function () { var _p = "//squizlabs.github.io/HTML_CodeSniffer/build/"; var _i = function (s, cb) { diff --git a/bookmarklets/tool-label-in-name.js b/bookmarklets/tool-label-in-name.js index 07386fb..61406bd 100644 --- a/bookmarklets/tool-label-in-name.js +++ b/bookmarklets/tool-label-in-name.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Label in name + * @description Display label in name + * @author Jonathan Avila + * @authorUrl https://mraccess77.github.io/favlets/Label-in-name.js + * @tags 2.5.3 Label in Name (A), external + * @pageTest true + */ // *********************************************** function traverseFrames(doc) { var src = doc.createElement("script"); diff --git a/bookmarklets/tool-sa11y.js b/bookmarklets/tool-sa11y.js index ad1ee58..0db7ea4 100644 --- a/bookmarklets/tool-sa11y.js +++ b/bookmarklets/tool-sa11y.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Sa11y + * @description The accessibility quality assurance assistant + * @author Toronto Metropolitan University + * @authorUrl https://ryersondmp.github.io/sa11y/demo/en/ + * @tags accessibility, external + * @pageTest self + */ void (function (document) { document.body.appendChild(document.createElement("script")).src = "https://cdn.jsdelivr.net/gh/ryersondmp/sa11y@latest/bookmarklet/sa11y-en.min.js"; diff --git a/bookmarklets/truncation.js b/bookmarklets/truncation.js index 096bbb5..cfe077d 100644 --- a/bookmarklets/truncation.js +++ b/bookmarklets/truncation.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Truncation + * @description Identify instances of text-overflow: ellipsis + * @author Jason Morris + * @authorUrl https://jasonmorris.com + * @tags accessibility + * @pageTest true + */ (function () { function checkRules(sheet) { var rules = sheet.cssRules || sheet.rules; diff --git a/bookmarklets/user-agent.js b/bookmarklets/user-agent.js index 1958f65..2512243 100644 --- a/bookmarklets/user-agent.js +++ b/bookmarklets/user-agent.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet User Agent + * @description Display current user agent string + * @author Thomas Orlita + * @authorUrl https://github.com/ThomasOrlita/awesome-bookmarklets#get-user-agent + * @tags diagnostic + * @pageTest self + */ void (() => { prompt("User agent:", navigator.userAgent); })(); diff --git a/bookmarklets/viewport.js b/bookmarklets/viewport.js index 6d7e32f..ca5d267 100644 --- a/bookmarklets/viewport.js +++ b/bookmarklets/viewport.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Viewport + * @description Display viewport width and height + * @author jakob-e + * @authorUrl https://codepen.io/jakob-e/pen/qEZZox/top/ + * @tags diagnostic + * @pageTest self + */ (function () { var d = document, w = window, diff --git a/bookmarklets/window-1280x1024.js b/bookmarklets/window-1280x1024.js index 80264f2..c44d425 100644 --- a/bookmarklets/window-1280x1024.js +++ b/bookmarklets/window-1280x1024.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet Open 1280x1024 + * @description Opens a new window with the current URL at 1280x1024 + * @author Mike in a CSS Tricks article comment + * @authorUrl https://css-tricks.com/snippets/javascript/1024x768-bookmarklet/#comment-1766738 + * @tags 1.4.4 Resize Text (AA), 1.4.10 Reflow (AA) + * @auditing true + * @pageTest true + */ (function () { var id = "w" + new Date().getTime(); var options = diff --git a/bookmarklets/window-320x256.js b/bookmarklets/window-320x256.js index 10161e5..5da8ed8 100644 --- a/bookmarklets/window-320x256.js +++ b/bookmarklets/window-320x256.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Open 320x256 + * @description Opens a new window with the current URL at 320x256 + * @author Mike in a CSS Tricks article comment + * @authorUrl https://css-tricks.com/snippets/javascript/1024x768-bookmarklet/#comment-1766738 + * @tags 1.4.10 Reflow (AA) + * @pageTest true + */ (function () { var id = "w" + new Date().getTime(); var options = diff --git a/bookmarklets/wtfocus.js b/bookmarklets/wtfocus.js index 3fa2790..d65a8ae 100644 --- a/bookmarklets/wtfocus.js +++ b/bookmarklets/wtfocus.js @@ -1,3 +1,12 @@ +/** + * @bookmarklet WTFocus + * @description Display information with focusable elements + * @author Ian Lloyd + * @authorUrl https://a11y-tools.com/bookmarklets/ + * @tags 2.4.4 Link Purpose (In Context) (A), 4.1.2 Name, Role, Value (A) + * @auditing true + * @pageTest self + */ (function () { "use strict"; function WTFocus() { @@ -30,10 +39,10 @@ x = !1, v = !1; function T() { - ((y = !1), (h = !1)); + (y = !1), (h = !1); } function k(e, t, o, n, a) { - (f && + f && ((t = t.split("<").join("<").split(">").join(">")), (g += " " + t + "\n")), (t = t.replace("<", "<").replace(">", ">")), - console.log("%c" + e + '"' + t + '"', o)); + console.log("%c" + e + '"' + t + '"', o); } function F() { const e = document.createElement("button"); - ((e.textContent = "Close (Esc)"), + (e.textContent = "Close (Esc)"), e.setAttribute("type", "button"), e.setAttribute("class", "panel-btn"), e.addEventListener("click", () => { W(); - })); + }); const t = document.createElement("button"); - ((t.textContent = "Change Mode (M)"), + (t.textContent = "Change Mode (M)"), t.setAttribute("type", "button"), t.setAttribute("class", "panel-btn"), t.addEventListener("click", (e) => { S(); }), r.appendChild(e), - r.appendChild(t)); + r.appendChild(t); } function S() { - (v + v ? (document .querySelector("#WTFocusPanel") .classList.remove("curtainsMode"), @@ -84,13 +93,13 @@ (v = !0), (m = "")), C(e), - e.focus()); + e.focus(); } function W() { - (document.querySelector("#WTFocusCurtain").remove(), + document.querySelector("#WTFocusCurtain").remove(), document.querySelector("#WTFocusPanel").remove(), document.querySelector("#panelStyles").remove(), - document.querySelector("#focusStyles").remove()); + document.querySelector("#focusStyles").remove(); } function C(e) { const t = e.getBoundingClientRect(), @@ -124,10 +133,10 @@ (r.style.right = "auto"), r.classList.remove("toLeft")); } - (console.clear(), + console.clear(), (function () { const e = document.createElement("style"); - (e.setAttribute("type", "text/css"), + e.setAttribute("type", "text/css"), e.setAttribute("id", "panelStyles"), (e.textContent = ".dupeAccName {outline:4px dashed #CC3300!important;outline-offset:" + @@ -137,20 +146,20 @@ "px solid black!important;outline-offset:" + u + "px!important;overflow:visible;/*background:yellow!important;color:black!important;*/} .WTFocusTempFocusStyle.dupeAccName:focus {outline-color:#CC3300!important;} .visually-hidden {clip-path: inset(100%);clip: rect(1px, 1px, 1px, 1px);height: 1px;overflow: hidden;position: absolute;white-space: nowrap;width: 1px;}#WTFocusCurtain {background:black;position: fixed;top: 0;bottom: 0;left: 0;right: 0;z-index:49999}"), - document.querySelector("body").appendChild(e)); + document.querySelector("body").appendChild(e); })(), document.querySelector("#WTFocusCurtain") && W(), (f = !0), (g = ""), (function (e) { const t = document.createElement("style"); - (t.setAttribute("type", "text/css"), + t.setAttribute("type", "text/css"), t.setAttribute("id", "focusStyles"), (t.textContent = "#WTFocusPanel.error {background:darkred;} #WTFocusPanel.warning {background:#CC3300;} #WTFocusPanel.curtainsMode.error {background:black;} #WTFocusPanel.curtainsMode {z-index:50000;position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);} #WTFocusPanel.curtainsMode.warning {background:black;} #WTFocusPanel[hidden] {display:none;} #WTFocusPanel * {text-align:left} #WTFocusPanel {border:2px solid #fff;z-index:1000;text-shadow:none;font-family:sans-serif;display:block;text-align:left;position: absolute;z-index:10000;background: black;padding: 20px 20px;width:" + e + "px;font-size:16px;} #WTFocusPanel button {font-weight:bold;background:none;color:#fff;padding:3px 10px;font-size:14px;border:1px solid #fff;display:inline-block;margin:10px 1em -10px 0;} #WTFocusPanel ul,#WTFocusPanel li {margin:0;padding:0;list-style:none} #WTFocusPanel li {margin:3px 0;background:#fff;color:#333;padding:2px} #WTFocusPanel li.outline {outline:4px solid rgb(58, 190, 58);outline-offset:-4px;padding:8px} #WTFocusPanel.error:before {background:darkred} #WTFocusPanel.warning:before {background:#CC3300} #WTFocusPanel:before {content:'';display:block;height:20px;width:20px;transform:rotate(45deg);position:absolute;background:#000;left:-12px;top:3px;border:2px solid #fff;border-right:none;border-top:none;} #WTFocusPanel.toBottom:before {top:auto;bottom:3px} #WTFocusPanel.toLeft:before {left:auto;right:-12px;border:2px solid #fff;border-left:none;border-bottom:none;} #WTFocusPanel.curtainsMode {outline:10px solid orange;} #WTFocusPanel.curtainsMode:before {display:none;} #WTFocusPanel.curtainsMode li {display:none;} #WTFocusPanel.curtainsMode li.visible {display:block;} #WTFocusPanel.curtainsMode li span {display:none!important;} "), - document.querySelector("head").appendChild(t)); + document.querySelector("head").appendChild(t); })(s), i.setAttribute("id", "WTFocusCurtain"), i.setAttribute("hidden", "hidden"), @@ -171,12 +180,12 @@ document.querySelector("#WTFocusPanel") && S(); }), - F()); + F(); let N = []; Array.from(t).forEach(function (i) { i.classList.add("WTFocusTempFocusStyle"); const c = i.querySelectorAll("style"); - (Array.from(c).forEach(function (e) { + Array.from(c).forEach(function (e) { e.remove(); }), i.addEventListener("focus", () => { @@ -212,7 +221,7 @@ "input" == s) ) { let e = i.getAttribute("type").toLowerCase(); - ("text" === e && (c = "textbox"), + "text" === e && (c = "textbox"), "range" === e && (c = "slider"), "number" === e && (c = "spinbutton"), ("checkbox" !== e && "radio" !== e) || (c = e), @@ -220,22 +229,22 @@ "image" !== e && "reset" !== e && "submit" !== e) || - (c = "button")); + (c = "button"); } - ((e = i), + (e = i), Array.from(t).forEach(function (e) { e.classList.remove("dupeAccName"); - })); + }); let u = !1; - ((y = !1), (h = !1)); + (y = !1), (h = !1); const d = i.querySelectorAll( "img, [role='image'][aria-label], [role='img'][aria-label]" ); - ((u = d.length > 0) && + (u = d.length > 0) && Array.from(d).forEach(function (e) { const t = document.createElement("SPAN"); var o, n; - (t.setAttribute("class", "visually-hidden"), + t.setAttribute("class", "visually-hidden"), t.setAttribute( "style", "clip-path: inset(100%);clip: rect(1px, 1px, 1px, 1px);height: 1px;overflow: hidden;position: absolute;white-space: nowrap;width: 1px;" @@ -247,12 +256,12 @@ e.getAttribute("aria-label") && (t.textContent = " " + e.getAttribute("aria-label") + " "), (o = t), - (n = e).parentNode.insertBefore(o, n.nextSibling)); + (n = e).parentNode.insertBefore(o, n.nextSibling); }), setTimeout(function () { i.classList.add("WTFocusTempFocusStyle"); }, 100), - (g = "")); + (g = ""); const b = i.tagName.toLowerCase(); let p = i.getAttribute("role"); p && (p = i.getAttribute("role").toLowerCase()); @@ -300,12 +309,13 @@ R = !1, V = "", D = !1; - (f && C(i), (P = P.trim())); + f && C(i), (P = P.trim()); const Y = (function (e, t) { for ( ; (e = e.parentElement) && !(e.matches || e.matchesSelector).call(e, t); + ); return e; })(i, "label"); @@ -352,7 +362,7 @@ "input" === b) ) { const e = i.getAttribute("type"); - ("submit" === e && + "submit" === e && "N/A" === z && ((H = "Submit"), (V = "Not provided (using default)")), "image" === e && @@ -360,7 +370,7 @@ ((H = "Submit"), (V = "Not provided (using default)")), "cancel" === e && "N/A" === z && - ((H = "Cancel"), (V = "Not provided (using default)"))); + ((H = "Cancel"), (V = "Not provided (using default)")); } if ( ("N/A" !== I && ((H = I), (V = "title attribute")), @@ -390,7 +400,7 @@ f && r.classList.add("warning"); const e = document.querySelectorAll("[data-accname='" + H + "']"), t = e.length; - (k(m, H, a, !1, !0), + k(m, H, a, !1, !0), x || (Array.from(e).forEach(function (e) { e.classList.add("dupeAccName"); @@ -406,13 +416,13 @@ Array.from(e).forEach(function (e) { console.log(e); }), - k("Accessible Name Source: ", V, a)); + k("Accessible Name Source: ", V, a); } } else - (f && (r.classList.remove("error"), r.classList.remove("warning")), + f && (r.classList.remove("error"), r.classList.remove("warning")), k(m, H, n, !1, !0), - k("Accessible Name Source: ", V, n)); - ((h = !1), + k("Accessible Name Source: ", V, n); + (h = !1), k("HTML Element: ", v, n), k("Role: ", c, "color:#333;background:#fff;", !1, !0), f || @@ -517,9 +527,9 @@ ((document.querySelector("#WTFocusPanel").innerHTML = '
    ' + g + "
"), document.querySelector("#WTFocusPanel").removeAttribute("hidden"), - F())); + F()); const K = document.querySelectorAll("[data-temp-node]"); - (Array.from(K).forEach(function (e) { + Array.from(K).forEach(function (e) { e.remove(); }), i.setAttribute("data-accname", H), @@ -538,29 +548,29 @@ ); o.setAttribute("data-dupe", "true"); } else N.push(e); - })(H, i)); - })); + })(H, i); + }); }); let E = !1; - (!(function () { + !(function () { if ( ((p = document.activeElement), Array.from(t).forEach(function (e) { - (document.activeElement === e && e.blur(), e.focus()); + document.activeElement === e && e.blur(), e.focus(); }), (E = !0), "BODY" === p.tagName) ) { const e = document.querySelector("body"); - (e.setAttribute("tabindex", "-1"), + e.setAttribute("tabindex", "-1"), e.focus(), document .querySelector("#WTFocusPanel") - .setAttribute("hidden", "hidden")); + .setAttribute("hidden", "hidden"); } else p.focus(); console.clear(); })(), - console.log("had focus = ", e)); + console.log("had focus = ", e); } WTFocus(); })(); diff --git a/bookmarklets/youtube-uc-id.js b/bookmarklets/youtube-uc-id.js index 33912a4..1858364 100644 --- a/bookmarklets/youtube-uc-id.js +++ b/bookmarklets/youtube-uc-id.js @@ -1,3 +1,11 @@ +/** + * @bookmarklet Get YouTube UC ID + * @description Fetches UC ID while on a YouTube profile page + * @author Jason Morris + * @authorUrl https://jasonmorris.com + * @tags diagnostic, bmxfeed, YouTube + * @pageTest false + */ var result = document .querySelector("link[rel=canonical]") .getAttribute("href") diff --git a/build.js b/build.js index d90c9be..f40551a 100644 --- a/build.js +++ b/build.js @@ -1,10 +1,5 @@ -// import * as esbuild from "esbuild"; -// import { rmSync, existsSync } from "fs"; -// import { writeFile, readFile, mkdir } from "fs/promises"; -// import netscape from "netscape-bookmarks"; -// import { join } from "path"; const esbuild = require("esbuild"); -const { rmSync, existsSync } = require("fs"); +const { rmSync, existsSync, readdirSync } = require("fs"); const { writeFile, readFile, mkdir } = require("fs").promises; const netscape = require("netscape-bookmarks"); const { join } = require("path"); @@ -26,10 +21,101 @@ async function setup() { } } +/** + * Parse JSDoc-style metadata from a bookmarklet source file. + * Expected format: + * /** + * * @bookmarklet Name of bookmarklet + * * @description What it does + * * @author Author name + * * @authorUrl https://example.com + * * @tags tag1, tag2 + * * @auditing true + * * @pageTest true + * *\/ + */ +function parseMetadata(source, filename) { + const metadata = { + file: filename, + }; + + // Match the JSDoc block at the start of the file + const jsdocMatch = source.match(/^\/\*\*[\s\S]*?\*\//); + if (!jsdocMatch) { + return null; + } + + const jsdoc = jsdocMatch[0]; + + // Parse each @tag + const tagPatterns = { + bookmarklet: /@bookmarklet\s+(.+?)(?:\n|\*\/)/, + description: /@description\s+(.+?)(?:\n|\*\/)/, + author: /@author\s+(.+?)(?:\n|\*\/)/, + authorUrl: /@authorUrl\s+(.+?)(?:\n|\*\/)/, + tags: /@tags\s+(.+?)(?:\n|\*\/)/, + auditing: /@auditing\s+(.+?)(?:\n|\*\/)/, + pageTest: /@pageTest\s+(.+?)(?:\n|\*\/)/, + }; + + for (const [key, pattern] of Object.entries(tagPatterns)) { + const match = jsdoc.match(pattern); + if (match) { + let value = match[1].replace(/\s*\*\s*$/, "").trim(); + + // Convert to appropriate types + if (key === "tags") { + metadata.tags = value.split(",").map((t) => t.trim()); + } else if (key === "auditing") { + metadata.auditing = value === "true"; + } else if (key === "pageTest") { + if (value === "true") { + metadata.pageTest = true; + } else if (value === "false") { + metadata.pageTest = false; + } else { + metadata.pageTest = value; // For "self" or other string values + } + } else if (key === "author") { + metadata.source = value; + } else if (key === "authorUrl") { + metadata.sourceUrl = value; + } else { + metadata[key] = value; + } + } + } + + return metadata; +} + +/** + * Discover and parse all bookmarklet files from the bookmarklets directory. + */ +async function discoverBookmarklets() { + const bookmarkletDir = "bookmarklets"; + const files = readdirSync(bookmarkletDir).filter((f) => f.endsWith(".js")); + + const bookmarklets = []; + + for (const file of files) { + const source = await readFile(join(bookmarkletDir, file), "utf8"); + const metadata = parseMetadata(source, file); + + if (metadata && metadata.bookmarklet) { + bookmarklets.push(metadata); + } else { + console.warn(`Warning: ${file} is missing required metadata`); + } + } + + return bookmarklets; +} + async function buildBookmarklets() { - const references = JSON.parse( - await readFile("data/bookmarklets.json", "utf8") - ); + // Auto-discover bookmarklets from JS files instead of reading from JSON + const references = await discoverBookmarklets(); + const bookmarkletsJson = await Promise.all( references.map(esbuildBookMarklet) ); diff --git a/data/auditing.html b/data/auditing.html index cfda9bb..ff79e4b 100644 --- a/data/auditing.html +++ b/data/auditing.html @@ -19,14 +19,14 @@

Bookmarks Menu

Images
Language of page/parts
Links -
Non-underlined links +
Non-underlined links
Page link
Parsing only
Placeholder contrast checker
Validate
Text spacing -
Titles +
Titles
ANDI
Open 1280x1024 -
WTFocus +
WTFocus

\ No newline at end of file diff --git a/data/auditing.json b/data/auditing.json index e44e5a6..7b446a7 100644 --- a/data/auditing.json +++ b/data/auditing.json @@ -1,129 +1,127 @@ [ { + "file": "auto-complete.js", "bookmarklet": "Autocomplete", "description": "Display all fields with autocomplete", - "file": "auto-complete.js", - "auditing": true, - "pageTest": true, "source": "Rachele DiTullio", "sourceUrl": "https://racheleditullio.com/blog/2023/11/autocomplete-accessibility-bookmarklet/", "tags": [ "1.3.5 Identify Input Purpose (AA)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20o=document.querySelectorAll(%22.autocomplete-info%22);if(o.length%3E0)o.forEach(t=%3E%7Bt.remove()%7D);else%7Blet%20t=document.querySelectorAll(%22input%5Bautocomplete%5D%22);t.length%3E0?t.forEach(l=%3E%7Blet%20i=l.getAttribute(%22autocomplete%22),n=l.getBoundingClientRect(),e=document.createElement(%22div%22);e.classList.add(%22autocomplete-info%22),e.style.position=%22absolute%22,e.style.top=window.scrollY+n.top+%22px%22,e.style.left=window.scrollX+n.left+%22px%22,e.style.backgroundColor=%22yellow%22,e.style.color=%22black%22,e.style.padding=%225px%22,e.style.border=%222px%20solid%20#000%22,e.style.zIndex=%229999%22,e.innerHTML=%60autocomplete=%3Cstrong%3E$%7Bi%7D%3C/strong%3E%60,document.body.appendChild(e)%7D):alert(%22No%20input%20fields%20with%20autocomplete%20attribute%20found%20on%20this%20page.%22)%7D%7D)();%7D)();%0A" }, { + "file": "buttons.js", "bookmarklet": "Buttons", "description": "Display all buttons", - "file": "buttons.js", - "auditing": true, - "pageTest": false, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "accessibility" ], + "auditing": true, + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20k()%7Bconsole.clear();function%20B(e,i)%7Bi.parentNode.insertBefore(e,i.nextSibling)%7Dfunction%20m(e)%7Blet%20i=window.getComputedStyle(e);return%20i.display===%22none%22%7C%7Ci.opacity===0%7C%7Ci.clipPath===%22inset(100%25)%22&&i.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ci.height===%221px%22&&i.width===%221px%22&&i.overflow===%22hidden%22%7Dfunction%20C(e)%7Blet%20i=window.getComputedStyle(e);i.position===%22absolute%22&&i.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),i.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),i.display===%22none%22&&(e.style.display=%22block%22),i.opacity===0&&(e.style.opacity=1)%7Dlet%20n=%22%22,r=%22%22,S=document.querySelectorAll(%22button,%5Brole=button%5D,input%5Btype=button%5D%22),c=1,g,y=0,f=%22%22,u=%22%22;Array.from(S).forEach(function(e)%7Blet%20i=document.createElement(%22div%22);i.appendChild(e.cloneNode(!0)),f=i.innerHTML;let%20b=!1,t=%22%22,w=e.querySelectorAll(%22img%22),o=!1,h=!1;b=w.length%3E0;let%20x=e.querySelector(%22%5Baria-hidden=true%5D%22);x&&x.classList.add(%22remove-from-accname%22),b&&Array.from(w).forEach(function(s)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),s.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+s.getAttribute(%22alt%22)+%22%20%22),B(d,s)%7D),e.setAttribute(%22data-button-ref%22,c);let%20l=e.textContent,A=e.querySelector(%22.remove-from-accname%22);A&&A.remove();let%20a=e.textContent;if(e.getAttribute(%22aria-label%22)&&(a=e.getAttribute(%22aria-label%22),t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-label%3C/code%3E.%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0,a.trim().toLowerCase().indexOf(l.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-label%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')),e.getAttribute(%22aria-labelledby%22))%7Blet%20s=e.getAttribute(%22aria-labelledby%22);s=s.replace(/:/g,%22%5C%5C:%22);let%20d=s.split(%22%20%22);d.length%3E1?(a=%22%22,Array.from(d).forEach(function(v)%7Bdocument.querySelector(%22#%22+v)?a+=document.querySelector(%22#%22+v).textContent+%22%20%22:a+=%22**%20aria-labelledby%20source%20is%20missing%20**%22%7D),a=a.trim(),t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0):(s=e.getAttribute(%22aria-labelledby%22),s=s.replace(/:/g,%22%5C%5C:%22),document.querySelector(%22#%22+s)?a=document.querySelector(%22#%22+s).textContent:a+=%22**%20aria-labelledby%20source%20is%20missing%20**%22,t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0),a.trim().toLowerCase().indexOf(l.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-labelledby%20sources%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')%7Dm(e)&&(C(e),m(e)?t+=%22Button%20is%20hidden%3Cbr%3E%22:t+=%22Button%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),b&&(t+=%22%5Cu%7B1F304%7D%20Image%20button%3Cbr%3E%22),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)!==l&&(t+=%22-%20button%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20different%20from%20text%20content.%22,a!==%22%22&&(t+='This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E'),t+=%22%3Cbr%3E%22,o=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)===l&&(t+='-%20button%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20the%20same%20as%20the%20text%20content%20and%20therefore%20adds%20no%20extra%20useful%20information/context.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E',o=!0),e.tagName===%22BUTTON%22&&(e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22Button%20has%20a%20%3Ccode%3Etabindex%3C/code%3E%20but%20it%20is%20not%20needed%20because%20the%20%3Ccode%3Ebutton%3C/code%3E%20is%20natively%20focusable%3Cbr%3E%22),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Button%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',o=!0),e.getAttribute(%22role%22)===%22button%22&&(t+=%22Button%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Not%20needed%20as%20it%20is%20a%20%3Ccode%3Ebutton%3C/code%3E%20element%20that%20is%20a%20button%20by%20default%3Cbr%3E%22),e.getAttribute(%22aria-hidden%22)!==%22true%22&&e.getAttribute(%22tabindex%22)===%22-1%22&&(t+=%22-%20%3Ccode%3E<button>%3C/code%3E%20has%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%20which%20means%20it%20will%20not%20be%20keyboard-operable%3Cbr%3E%22,o=!0),e.getAttribute(%22aria-hidden%22)===%22true%22&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+='-%20%3Ccode%3E<button>%3C/code%3E%20has%20%3Ccode%3Earia-hidden=%22true%22%3C/code%3E%20but%20can%20still%20be%20focused%20by%20keyboard%20user%20as%20it%20does%20not%20have%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E',o=!0),e.getAttribute(%22role%22)&&e.getAttribute(%22role%22)!==%22button%22&&(t+='-%20%3Ccode%3E<button>%3C/code%3E%20has%20a%20%3Ccode%3Erole%3C/code%3E%20set%20that%20is%20not%20%3Ccode%3Ebutton%3C/code%3E.%20It%20is%20set%20to%20%22'+e.getAttribute(%22role%22)+'%22.%20This%20overrides%20the%20native%20role%20and%20will%20likely%20confused%20assistive%20tech%20users%3Cbr%3E',o=!0)),e.tagName===%22A%22&&(!e.getAttribute(%22href%22)&&!e.getAttribute(%22tabindex%22)&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E%20element,%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E%20or%20%3Ccode%3Etabindex%3C/code%3E,%20%20and%20therefore%20is%20not%20focusable%3Cbr%3E%22,o=!0),!e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E%20element,%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20but%20is%20focusable%20because%20it%20has%20been%20provided%20with%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E%22,o=!0),e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E.%20It%20is%20focusable%20because%20there%20is%20a%20%3Ccode%3Etabindex%3C/code%3E%20present%3Cbr%3E%22,o=!0),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Button%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',o=!0)),e.tagName!==%22BUTTON%22&&e.tagName!==%22A%22&&e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E%20but%20is%20not%20a%20%3Ccode%3Ebutton%3C/code%3E%20element.%22,e.getAttribute(%22tabindex%22)===%22-1%22?t+=%22%3Cbr%3E-%20%3Cstrong%3ENote%3C/strong%3E:%20this%20button%20has%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%20and%20will%20not%20be%20keyboard-focusable.%22:t+=%22Check%20that%20it%20is%20keyboard-operable%20(should%20activate%20with%20%3Ckbd%3EEnter%3C/kbd%3E%20and%20%3Ckbd%3ESpace%3C/kbd%3E%20key)%3Cbr%3E%22,o=!0),a===%22%22?(e.getAttribute(%22title%22)?a=e.getAttribute(%22title%22):a=%22%5Cu203C%5CuFE0F%20Empty%20button%22,l=%22%5Cu203C%5CuFE0F%20Empty%20button%22,t+=%22%5Cu203C%5CuFE0F%20Empty%20button%3Cbr%3E%22,h=!0):l.trim()===%22%22&&(l=%22%5Cu203C%5CuFE0F%20No%20visible%20text%20on%20button%22),b&&a===%22%5Cu203C%5CuFE0F%20Empty%20button%22&&(t+=%22%20-%20image%20is%20missing%20alternative%20text%20content%3Cbr%3E%22),h&&(o=!1),r+=%22%3Ctr%22,r+='%20data-button-ref=%22'+c+'%22',o&&(r+='%20class=%22issue%20warn%22'),h&&(r+='%20class=%22issue%20err%22'),r+=%22%3E%22,e.tagName===%22BUTTON%22?g=%22%3Ccode%3E<button>%3C/code%3E%22:g='%3Ccode%3Erole=%22button%22%3C/code%3E',r+=%22%3Ctd%3E%22+g+%22%3C/td%3E%22,r+=%22%3Ctd%3E%22+l+%22%3C/td%3E%22,r+=%22%3Ctd%3E%22+a,a.trim()!==l.trim()&&l.trim()!==%22%22&&(r+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),r+=%22%3C/td%3E%22,r+=%22%3Ctd%3E%22,o&&(r+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20button%3C/div%3E'),h&&(r+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20button%3C/div%3E'),u=%22Button%20'%22+l.trim()+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+f+%60%0A---------------%0A%60,r+=t+'%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+c+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+c+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+f+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',r+='%3Ctd%3E%3Cbutton%20data-button-ref=%22'+c+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',r+=%22%3C/tr%3E%22,c++,(o%7C%7Ch)&&y++,h&&(u=u.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(u))%7D),n='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkgreen;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:button,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20buttons%20on%20this%20page.%3C/h1%3E',n+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20buttons%20where%20there%20*may*%20be%20issues%20('+y+%22%20found)%3C/label%3E%22,n+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20buttons%20on%20page%3C/button%3E',n+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20buttons%20(<button>%20or%20elements%20with%20role=%22button%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3EButton%20type%3C/th%3E%3Cth%20scope=%22col%22%3EButton%20text%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+r+%22%3C/tbody%3E%3C/table%3E%22,n+=%22%3Cscript%3Efunction%20showbtns()%7B%22,n+=%22var%20refWindow=window.opener;%22,n+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20buttonToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BbuttonToHighlight=%22%5Bdata-button-ref='%22%20+%20highlightButton.getAttribute(%22data-button-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(buttonToHighlight).focus();refWindow.document.querySelector(buttonToHighlight).style.outline=%224px%20dashed%20darkgreen%22;refWindow.document.querySelector(buttonToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(buttonToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,n+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',n+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',n+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7Bshowbtns();%7D);%3C%5C/script%3E';let%20p=window.open(%22%22,%22popUpWinButtons%22,%22height=800,width=1000%22);p.document.open(),p.document.write(n),p.document.close()%7Dk()%7D)();%7D)();%0A" }, { + "file": "character-keys.js", "bookmarklet": "Character key shortcuts", "description": "Test all printable character shortcut keys", - "file": "character-keys.js", - "pageTest": true, - "auditing": true, "source": "Detlev Fischer", "sourceUrl": "http://3needs.org/en/testing/code/kb-shortcuts.html", "tags": [ "2.1.4 Character Key Shortcuts (A)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e,t=32,o=8365;n();function%20n()%7Bconsole.log(%22pressed:%20%22+t+%22:%20%22+String.fromCharCode(t)),e=document.createEvent(%22Event%22),e.initEvent(%22keydown%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),e=document.createEvent(%22Event%22),e.initEvent(%22keypress%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),e=document.createEvent(%22Event%22),e.initEvent(%22keyup%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),t++,t%3Co&&(t==127&&(t=161),t==192&&(t=8364),window.setTimeout(n,20))%7D%7D)();%7D)();%0A" }, { + "file": "find-duplicate-aria-roles.js", "bookmarklet": "Find Duplicate ARIA Roles", "description": "Roles appearing more than once for banner, contentinfo, and main", - "file": "find-duplicate-aria-roles.js", - "pageTest": true, - "auditing": true, "source": "Adrian Roselli", "sourceUrl": "https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#ARIAdupes", "tags": [ "accessibility", "HTML" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e=document.createElement(%22style%22),n;document.head.appendChild(e),n=e.sheet,n.insertRule(%22*%5Brole=main%5D:nth-of-type(n+2),*%5Brole=banner%5D:nth-of-type(n+2),*%5Brole=contentinfo%5D:nth-of-type(n+2),main:nth-of-type(n+2)%7Bborder:2px%20dotted%20#f00%20!important;background-color:#f00;%7D%22,0)%7D)();%7D)();%0A" }, { + "file": "focus-everything.js", "bookmarklet": "Focus everything", "description": "A technique for testing 1.3.2 Meaningful Sequence a tab path visualizer", - "file": "focus-everything.js", - "pageTest": true, - "auditing": true, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "1.3.2 Meaningful Sequence (A)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7Bdocument.querySelectorAll(%22body%20*%22).forEach(function(t)%7Bt.setAttribute(%22tabindex%22,%220%22)%7D);%7D)();%0A" }, { + "file": "force-focus.js", "bookmarklet": "Force focus indicator", "description": "Adds a 4 pixel solid orange outline around all focusable elements", - "file": "force-focus.js", - "pageTest": false, - "auditing": true, "source": "Paul J. Adam", "sourceUrl": "https://pauljadam.com/bookmarklets/focus.html", "tags": [ "accessibility" ], + "auditing": true, + "pageTest": false, "dist": "javascript:void%20(()=%3E%7Bvar%20e=document.createElement(%22style%22),t=document.createTextNode(%22a:focus,%20*:focus%20%7B%20outline:%204px%20solid%20orange%20!important;%20outline-offset:1px%20!important;%20%7D%22),n=document.getElementsByTagName(%22head%22);e.appendChild(t);n%5B0%5D.appendChild(e);%7D)();%0A" }, { + "file": "headings-console.js", "bookmarklet": "Document outline in console", "description": "Display level of all page headings in console", - "file": "headings-console.js", - "auditing": true, - "pageTest": "self", "source": "Mu-An Chiou", "sourceUrl": "https://github.com/muan/headings", "tags": [ "accessibility" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bvar%20a=%22%22;for(let%20t%20of%20document.querySelectorAll(%22h1,%20h2,%20h3,%20h4,%20h5,%20h6%22))%7Blet%20e=r(t);if(i(t)&&(t.offsetHeight%3E0%7C%7Ct.offsetWidth)&&e)%7Blet%20n=parseInt(t.tagName.match(/%5Cd/)%5B0%5D);a+=new%20Array((n-1)*2).fill(%22-%22).join(%22%22)+t.tagName.toLowerCase()+%22:%20%22+e+%60%0A%60%7D%7Dconsole.log(a);function%20r(t)%7Blet%20e=t.getAttribute(%22aria-labelledby%22);return(t.getAttribute(%22alt%22)%7C%7Ct.getAttribute(%22aria-label%22)%7C%7Ce&&o(document.getElementById(e))%7C%7Co(t)).trim()%7Dfunction%20o(t)%7Blet%20e=%22%22;for(let%20n%20of%20t.childNodes)e+=n%20instanceof%20HTMLElement?r(n):n.textContent%7C%7C%22%22;return%20e%7Dfunction%20i(t)%7Breturn!t.closest('%5Baria-hidden=%22%22%5D,%20%5Baria-hidden=%22true%22%5D')%7D%7D)();%0A" }, { + "file": "headings.js", "bookmarklet": "Headings", "description": "Display level of all page headings", - "file": "headings.js", - "auditing": true, - "pageTest": "self", "source": "Jonathan Avila", "sourceUrl": "https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/headings.js", "tags": [ "1.3.1 Info and Relationships (A)", "2.4.6 Headings and Labels (AA)" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bfunction%20n(o)%7Bs(o);for(var%20a=%5B%22frame%22,%22iframe%22%5D,e=0;e%3Ca.length;e++)for(var%20r=o.getElementsByTagName(a%5Be%5D),l=0;l%3Cr.length;l++)try%7Bn(r%5Bl%5D.contentWindow.document)%7Dcatch%7B%7D%7Dfunction%20s(o)%7Bfor(var%20a=o.querySelectorAll(%22h1,h2,h3,h4,h5,h6,%5Brole='heading'%5D%22),e=0;e%3Ca.length;e++)%7Bvar%20r=a%5Be%5D.tagName+%22%20%22;a%5Be%5D.hasAttribute(%22role%22)&&(r=r+%22role=%22+a%5Be%5D.getAttribute(%22role%22)+%22%20%22),a%5Be%5D.hasAttribute(%22aria-level%22)&&(r=r+%22aria-level=%22+a%5Be%5D.getAttribute(%22aria-level%22));var%20l=document.createTextNode(r),t=document.createElement(%22span%22);t.style.color=%22black%22,t.style.backgroundColor=%22gold%22,t.style.fontSize=%22small%22,t.style.border=%22thin%20solid%20black%22,t.style.position=%22absolute%22,t.appendChild(l),a%5Be%5D.parentNode.insertBefore(t,a%5Be%5D),a%5Be%5D.style.border=%22thin%20solid%20magenta%22%7D%7Dn(document);%7D)();%0A" }, { + "file": "horizontal-scroll.js", "bookmarklet": "Horizontal scroll", "description": "Alert when a horizontal scrollbar appears", - "file": "horizontal-scroll.js", - "auditing": true, - "pageTest": true, - "source": " Jason Morris", + "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "accessibility" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20e=document.documentElement.clientWidth,o=!1;function%20n()%7Blet%20t=document.documentElement.clientWidth,i=document.body.scrollWidth%3Edocument.documentElement.clientWidth;i&&!o&&t%3Ce?(console.log(%60%25cHorizontal%20scrollbar%20detected!%25c%0AWindow%20width:%20%60+t+%60px%0AContent%20width:%20%60+document.body.scrollWidth+%60px%0AOverflow:%20%60+(document.body.scrollWidth-t)+%22px%22,%22color:%20#ff0000;%20font-size:%2014px;%20font-weight:%20bold;%22,%22color:%20inherit;%20font-size:%20inherit;%22),o=!0):i%7C%7C(o=!1),e=t%7Dwindow.addEventListener(%22resize%22,n),n(),console.log(%60%25cHorizontal%20scrollbar%20detector%20activated!%25c%0AResize%20the%20window%20to%20test.%60,%22color:%20#4CAF50;%20font-size:%2014px;%20font-weight:%20bold;%22,%22color:%20inherit;%20font-size:%20inherit;%22)%7D)();%7D)();%0A" }, { + "file": "images.js", "bookmarklet": "Images", "description": "Display all images", - "file": "images.js", - "pageTest": true, - "auditing": true, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ @@ -131,167 +129,171 @@ "1.4.5 Images of Text (A)", "2.4.4 Link Purpose (In Context) (A)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20f(e)%7Blet%20r=window.getComputedStyle(e);return%20r.display===%22none%22%7C%7Cr.opacity===0%7C%7Cr.clipPath===%22inset(100%25)%22&&r.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Cr.height===%221px%22&&r.width===%221px%22&&r.overflow===%22hidden%22%7Dfunction%20T(e)%7Blet%20r=window.getComputedStyle(e);r.position===%22absolute%22&&r.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),r.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),r.display===%22none%22&&(e.style.display=%22block%22),r.opacity===0&&(e.style.opacity=1)%7Dlet%20l=%22%22,o=%22%22,k=document.querySelectorAll(%22img,%5Brole=img%5D%22),d=1,u,m=0,b=%22%22,c=%22%22;Array.from(k).forEach(function(e)%7Blet%20r=document.createElement(%22div%22);r.appendChild(e.cloneNode(!0)),b=r.innerHTML;let%20t=%22%22,p=!1,y=!1,a=!1,n=!1,w=e.querySelector(%22%5Baria-hidden=true%5D%22);w&&w.classList.add(%22remove-from-accname%22),e.setAttribute(%22data-img-ref%22,d);let%20i=e.getAttribute(%22alt%22);i===null?(i=%22NO_ALT_ATTRIBUTE%22,p=!0):i===%22%22&&(i=%22EMPTY_ALT_ATTRIBUTE%22,y=!0);let%20s=i,A=e.getAttribute(%22src%22);if(f(e)&&(T(e),f(e)?t+=%22img%20is%20hidden.%3Cbr%3E%22:t+=%22img%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page.%3Cbr%3E%22),p&&(e.getAttribute(%22role%22)===%22img%22&&e.tagName!==%22IMG%22%7C%7C(t=%22-%20img%20has%20no%20%3Ccode%3Ealt%3C/code%3E%20attribute.%3Cbr%3E%22,n=!0)),y&&(t=%22-%20img%20has%20an%20empty%20%3Ccode%3Ealt%3C/code%3E%20attribute.%20This%20will%20hide%20it%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),(e.getAttribute(%22role%22)===%22presentation%22%7C%7Ce.getAttribute(%22role%22)===%22none%22)&&(t+=%22-%20img%20has%20a%20%3Ccode%3Erole%3C/code%3E%20set%20('%22+e.getAttribute(%22role%22)+%22')%20that%20will%20hide%20it%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),e.getAttribute(%22aria-hidden%22)===%22true%22&&(t+=%22-%20img%20has%20an%20%3Ccode%3Earia-hidden=true%3C/code%3E,%20so%20it%20will%20be%20hidden%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),e.getAttribute(%22title%22)&&(i===%22EMPTY_ALT_ATTRIBUTE%22?(t+=%22-%20img%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20AND%20an%20empty%20%3Ccode%3Ealt%3C/code%3E%20attribute.%20Because%20of%20the%20empty%20alt,%20the%20image%20will%20be%20hidden%20to%20AT,%20so%20the%20title%20attribute%20is%20not%20used/exposed.%3Cbr%3E%22,a=!1,n=!0):(t+='-%20img%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20attribute.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users.%3Cbr%3E',p?n=!0:a=!0)),e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20img%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Check%20that%20it%20behaves%20like%20a%20%3Ccode%3Ebutton%3C/code%3E.%3Cbr%3E%22,a=!0),e.getAttribute(%22role%22)===%22img%22&&(t+=%22-%20Not%20an%20inline%20img,%20so%20no%20%3Ccode%3Ealt%3C/code%3E%20attribute.%3Cbr%3E%22),e.getAttribute(%22role%22)===%22img%22&&e.getAttribute(%22alt%22)!==null&&e.tagName!==%22IMG%22&&(t+=%22-%20Background%20image%20has%20an%20%3Ccode%3Ealt%3C/code%3E%20attribute%20specified,%20but%20cannot%20be%20applied%20to%20this%20element;%20can%20only%20be%20applied%20to%20%3Ccode%3Eimg%3C/code%3E%20element.%3Cbr%3E%22,a=!1,n=!0),e.tagName!==%22IMG%22&&e.getAttribute(%22role%22)===%22img%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Eimg%3C/code%3E%20but%20is%20not%20an%20%3Ccode%3Eimg%3C/code%3E%20element.%3Cbr%3E%22),e.getAttribute(%22role%22)===%22img%22)%7Blet%20h=!1;if(e.tagName!==%22IMG%22)%7Blet%20I=e.currentStyle%7C%7Cwindow.getComputedStyle(e,!1),S=I.backgroundImage.slice(4,-1).replace(/%22/g,%22%22);if(e.getAttribute(%22aria-label%22)!==null&&(h=!0,i=e.getAttribute(%22aria-label%22),s=i,t+=%22-%20Accessible%20name%20provided%20by%20an%20%3Ccode%3Earia-label%3C/code%3E%20attribute.%3Cbr%3E%22,a=!1),!h&&e.getAttribute(%22aria-labelledby%22)!==null)%7Bh=!0;let%20x=e.getAttribute(%22aria-labelledby%22).split(%22%20%22);x.length%3E1?(i=%22%22,Array.from(x).forEach(function(B)%7Bi+=document.querySelector(%22#%22+B).textContent+%22%20%22%7D),i=i.trim(),t+=%22-%20Image%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20image%20on%20screen%3Cbr%3E%22,a=!0):(i=document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22)).textContent,t+=%22-%20Image%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20image%20on%20screen%3Cbr%3E%22,a=!0),s=i%7D%7Dh%7C%7C(t+=%22-%20Image%20has%20no%20accessible%20name%20provided.%20It%20must%20be%20set%20using%20%3Ccode%3Earia-labelledby%3C/code%3E%20or%20%3Ccode%3Earia-label%3C/code%3E%20(not%20%3Ccode%3Ealt%3C/code%3E)%3Cbr%3E%22,n=!0)%7Ds===%22%22&&(e.getAttribute(%22title%22)?s=e.getAttribute(%22title%22):s=%22%5Cu203C%5CuFE0F%20No%20alt,%20no%20title%22,t+=%22%5Cu203C%5CuFE0F%20No%20alt.%3Cbr%3E%22,n=!0),n&&(a=!1),o+=%22%3Ctr%22,o+='%20data-img-ref=%22'+d+'%22',a&&(o+='%20class=%22issue%20warn%22'),n&&(o+='%20class=%22issue%20err%22'),o+=%22%3E%22,e.tagName===%22IMG%22?u=%22%3Ccode%3E<img>%3C/code%3E%22:u='%3Ccode%3Erole=%22img%22%3C/code%3E',(s===%22NO_ALT_ATTRIBUTE%22%7C%7Cs===%22EMPTY_ALT_ATTRIBUTE%22)&&(i=%22%22,s=%22%22),o+=%22%3Ctd%3E%22+u+%22%3C/td%3E%22,o+='%3Ctd%3E%3Cimg%20src=%22'+A+'%22%20alt=%22%22%20style=%22max-width:200px;max-height:200px;%22%3E%3C/td%3E',o+=%22%3Ctd%3E%22+s,s.trim()!==i.trim()&&i.trim()!==%22%22&&(o+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),o+=%22%3C/td%3E%22,s.trim()!==i.trim()&&s.trim().toLowerCase()===i.trim().toLowerCase()&&(t+=%22-%20Same%20text%20but%20case%20difference%20noted%20(likely%20not%20an%20issue)%22),o+=%22%3Ctd%3E%22,a&&(o+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20image%3C/div%3E'),n&&(o+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20image%3C/div%3E',c=%22Image%20'%22+A+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+b+%60%0A---------------%0A%60),o+=t+'%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+d+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+d+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+b+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',o+='%3Ctd%3E%3Cbutton%20data-img-ref=%22'+d+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',o+=%22%3C/tr%3E%22,d++,(a%7C%7Cn)&&(m++,c=c.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(c))%7D),l='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkred;%7D;div.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:img,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20images%20on%20this%20page.%3C/h1%3E',l+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20images%20where%20there%20*may*%20be%20issues%20('+m+%22%20found)%3C/label%3E%22,l+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20images%20on%20page%3C/button%3E',l+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20images%20(img%20elements%20or%20elements%20with%20role=%22img%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3EImage%20type%3C/th%3E%3Cth%3EImage%20thumbnail%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+o+%22%3C/tbody%3E%3C/table%3E%22,l+=%22%3Cscript%3Efunction%20showImages()%7B%22,l+=%22var%20refWindow=window.opener;%22,l+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20imgToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BimgToHighlight=%22%5Bdata-img-ref='%22%20+%20highlightButton.getAttribute(%22data-img-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(imgToHighlight).setAttribute(%22tabindex%22,%22-1%22);refWindow.document.querySelector(imgToHighlight).focus();refWindow.document.querySelector(imgToHighlight).style.outline=%2210px%20solid%20darkred%22;refWindow.document.querySelector(imgToHighlight).style.outlineOffset=%22-10px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(imgToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,l+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',l+='var%20imgsToCopy=document.querySelectorAll(%22.imgToCopy%22);Array.from(imgsToCopy).forEach(imgToCopy%20=%3E%20%7BimgToCopy.addEventListener(%22focus%22,%20e%20=%3E%20%7BimgToCopy.select();%7D);%7D);',l+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',l+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowImages();%7D);%3C%5C/script%3E';let%20g=window.open(%22%22,%22popUpWinImages%22,%22height=800,width=1000%22);g.document.open(),g.document.write(l),g.document.close()%7Dv()%7D)();%7D)();%0A" }, { + "file": "language.js", "bookmarklet": "Language of page/parts", "description": "Display all lang attributes on page", - "file": "language.js", - "auditing": true, - "pageTest": true, "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "3.1.1 Language of Page (A)", "3.1.2 Language of Parts (AA)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7Bvar%20a=document.querySelectorAll(%22%5Blang%5D%22),g=document.querySelector(%22html%5Blang%5D%22),t=%22%22;g?t+=%22The%20page%20lang%20attribute%20is%20%22+g.getAttribute(%22lang%22)+%60%0A%60:t+=%60Page%20is%20missing%20lang%20attribute%0A%60;for(e=0;e%3Ca.length;e++)t+=a%5Be%5D.tagName+%22%20tag%20has%20%22+a%5Be%5D.getAttribute(%22lang%22)+%60%0A%60;var%20e;alert(t);%7D)();%0A" }, { + "file": "links.js", "bookmarklet": "Links", "description": "Display all links", - "file": "links.js", - "auditing": true, - "pageTest": false, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "accessibility" ], + "auditing": true, + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20L(e,i)%7Bi.parentNode.insertBefore(e,i.nextSibling)%7Dfunction%20y(e)%7Blet%20i=window.getComputedStyle(e);return%20i.display===%22none%22%7C%7Ci.opacity===0%7C%7Ci.clipPath===%22inset(100%25)%22&&i.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ci.height===%221px%22&&i.width===%221px%22&&i.overflow===%22hidden%22%7Dfunction%20C(e)%7Blet%20i=window.getComputedStyle(e);i.position===%22absolute%22&&i.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),i.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),i.display===%22none%22&&(e.style.display=%22block%22),i.opacity===0&&(e.style.opacity=1)%7Dlet%20f,n=%22%22,o=%22%22,B=document.querySelectorAll(%22a,%5Brole=link%5D%22),l=1,p,w=0,g=%22%22,h=%22%22;Array.from(B).forEach(function(e)%7Blet%20i=document.createElement(%22div%22);i.appendChild(e.cloneNode(!0)),g=i.innerHTML;let%20u=!1,t=%22%22,A=e.querySelectorAll(%22img%22),a=!1,c=!1;u=A.length%3E0;let%20x=e.querySelector(%22%5Baria-hidden=true%5D%22);x&&x.classList.add(%22remove-from-accname%22),u&&Array.from(A).forEach(function(b)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),b.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+b.getAttribute(%22alt%22)+%22%20%22),L(d,b)%7D),e.setAttribute(%22data-link-ref%22,l);let%20s=e.textContent,k=e.querySelector(%22.remove-from-accname%22);k&&k.remove();let%20r=e.textContent;if(e.getAttribute(%22aria-label%22)&&(r=e.getAttribute(%22aria-label%22),t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-label%3C/code%3E%22,s.trim()!==%22%22&&(t+=%22%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22),a=!0,r.trim().toLowerCase().indexOf(s.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-label%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')),e.getAttribute(%22aria-labelledby%22))%7Blet%20d=e.getAttribute(%22aria-labelledby%22).split(%22%20%22);d.length%3E1?(r=%22%22,Array.from(d).forEach(function(S)%7Br+=document.querySelector(%22#%22+S).textContent+%22%20%22%7D),r=r.trim(),t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,a=!0):(r=document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22)).textContent,t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,a=!0),r.trim().toLowerCase().indexOf(s.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-labelledby%20sources%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')%7Dy(e)&&(C(e),y(e)?t+=%22Link%20is%20hidden%3Cbr%3E%22:t+=%22Link%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),u&&(t+=%22%5Cu%7B1F304%7D%20Image%20link%3Cbr%3E%22),e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20Link%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Check%20that%20it%20behaves%20like%20a%20%3Ccode%3Ebutton%3C/code%3E%20and%20is%20not%20used%20as%20navigation.%3Cbr%3E%22,a=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)!==s&&(t+='-%20Link%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20different%20from%20text%20content.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E',a=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)===s&&(t+='Link%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20the%20same%20as%20the%20text%20content%20and%20therefore%20adds%20no%20extra%20useful%20information/context.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E'),e.tagName===%22A%22&&(e.getAttribute(%22href%22)===null&&!e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20is%20not%20keyboard-focusable%3Cbr%3E%22,a=!0),e.getAttribute(%22href%22)!==null&&!e.getAttribute(%22href%22)&&!e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20have%20an%20%3Ccode%3Ehref%3C/code%3E%20but%20it%20has%20no%20value,%20so%20it%20is%20keyboard-focusable%3Cbr%3E%22,a=!0),!e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20but%20is%20focusable%20because%20it%20has%20been%20provided%20with%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E%22,a=!0),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Link%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',a=!0),e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22Link%20has%20a%20%3Ccode%3Etabindex%3C/code%3E%20but%20it%20is%20not%20needed%20because%20the%20%3Ccode%3Ehref%3C/code%3E%20makes%20it%20focusable%3Cbr%3E%22),e.getAttribute(%22role%22)===%22link%22&&(t+=%22Link%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Elink%3C/code%3E.%20Not%20needed%20as%20it%20is%20an%20%3Ccode%3Ea%3C/code%3E%20element%20that%20is%20a%20link%20by%20default%3Cbr%3E%22)),e.tagName!==%22A%22&&e.getAttribute(%22role%22)===%22link%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Elink%3C/code%3E%20but%20is%20not%20an%20%3Ccode%3Ea%3C/code%3E%20element.%20Check%20that%20it%20is%20keyboard-operable%20(should%20activate%20with%20%3Ckbd%3EEnter%3C/kbd%3E%20key)%3Cbr%3E%22,a=!0),r===%22%22&&(e.getAttribute(%22title%22)?r=e.getAttribute(%22title%22):r=%22%5Cu203C%5CuFE0F%20Empty%20link%22,s=%22%5Cu203C%5CuFE0F%20Empty%20link%22,t+=%22%5Cu203C%5CuFE0F%20Empty%20link%3Cbr%3E%22,c=!0),u&&r===%22%5Cu203C%5CuFE0F%20Empty%20link%22&&(t+=%22%20-%20image%20is%20missing%20alternative%20text%20content%3Cbr%3E%22),e.href&&(f=e.href),c&&(a=!1),o+=%22%3Ctr%22,o+='%20data-link-ref=%22'+l+'%22',a&&(o+='%20class=%22issue%20warn%22'),c&&(o+='%20class=%22issue%20err%22'),o+=%22%3E%22,e.tagName===%22A%22?p=%22%3Ccode%3E<a>%3C/code%3E%22:p='%3Ccode%3Erole=%22link%22%3C/code%3E',o+=%22%3Ctd%3E%22+p+%22%3C/td%3E%22,o+=%22%3Ctd%3E%22+s+%22%3C/td%3E%22,o+=%22%3Ctd%3E%22+r,r.trim()!==s.trim()&&s.trim()!==%22%22&&(o+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),o+=%22%3C/td%3E%22,r.trim()!==s.trim()&&r.trim().toLowerCase()===s.trim().toLowerCase()&&(t+=%22-%20Same%20text%20but%20case%20difference%20noted%20(likely%20not%20an%20issue)%22),o+=%22%3Ctd%3E%22,a&&(o+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20link%3C/div%3E'),c&&(o+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20link%3C/div%3E'),h=%22Link%20'%22+s.trim()+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+g+%60%0A---------------%0A%60,o+=t+'%3Ca%20href=%22'+f+'%22%20target=%22_blank%22%20aria-label=%22'+r+'%22%3E%5Cu%7B1F517%7D%3C/a%3E%20%3Clabel%20for=%22l'+l+'%22%3ELinks%20to:%3C/label%3E%3Cinput%20id=%22l'+l+'%22%20class=%22linkToCopy%22%20type=%22text%22%20value=%22'+f+'%22%3E%20%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+l+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+l+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+g+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',o+='%3Ctd%3E%3Cbutton%20data-link-ref=%22'+l+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',o+=%22%3C/tr%3E%22,l++,(a%7C%7Cc)&&w++,c&&(h=h.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(h))%7D),n='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkblue;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:link,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20links%20on%20this%20page.%3C/h1%3E',n+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20links%20where%20there%20*may*%20be%20issues%20('+w+%22%20found)%3C/label%3E%22,n+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20links%20on%20page%3C/button%3E',n+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20links%20(anchors%20or%20elements%20with%20role=%22link%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3ELink%20type%3C/th%3E%3Cth%20scope=%22col%22%3ELink%20text%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+o+%22%3C/tbody%3E%3C/table%3E%22,n+=%22%3Cscript%3Efunction%20showLinks()%7B%22,n+=%22var%20refWindow=window.opener;%22,n+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20linkToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BlinkToHighlight=%22%5Bdata-link-ref='%22%20+%20highlightButton.getAttribute(%22data-link-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(linkToHighlight).focus();refWindow.document.querySelector(linkToHighlight).style.outline=%224px%20dashed%20darkblue%22;refWindow.document.querySelector(linkToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(linkToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,n+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',n+='var%20linksToCopy=document.querySelectorAll(%22.linkToCopy%22);Array.from(linksToCopy).forEach(linkToCopy%20=%3E%20%7BlinkToCopy.addEventListener(%22focus%22,%20e%20=%3E%20%7BlinkToCopy.select();%7D);%7D);',n+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',n+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowLinks();%7D);%3C%5C/script%3E';let%20m=window.open(%22%22,%22popUpWinLinks%22,%22height=800,width=1000%22);m.document.open(),m.document.write(n),m.document.close()%7Dv()%7D)();%7D)();%0A" }, { + "file": "non-underlined-links.js", "bookmarklet": "Non-underlined links", "description": "Display information about links without underlines", - "file": "non-underlined-links.js", - "auditing": true, - "pageTest": true, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "1.4.1 Use of Color (A)" ], - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;var%20l=%22%22;function%20y()%7Bconsole.clear();let%20c=!1,u=!1,i=!1,p=!1,k=document.querySelectorAll(%22a%22),f=0,h=!1,b=!1;function%20N(e,a,o)%7Blet%20n=%5Be,a,o%5D.map(function(t)%7Breturn(t/=255)%3C=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)%7D);return%20.2126*n%5B0%5D+.7152*n%5B1%5D+.0722*n%5B2%5D%7Dfunction%20x(e)%7Breturn%20e=(e=(e=e.replace(%22rgb(%22,%22%22)).replace(%22)%22,%22%22)).split(%22,%20%22)%7Dif((function()%7Blet%20e=document.createElement(%22style%22);e.textContent=%22.problem-highlight%20%7Boutline:5px%20solid%20darkred;outline-offset:3px;box-shadow:%200px%200px%200px%2010px%20#fff;%7D%22,document.head.appendChild(e)%7D)(),Array.from(k).forEach(e=%3E%7Bif(h=!1,b=!1,p=(function(a,o)%7Bfor(;(a=a.parentElement)&&!(a.matches%7C%7Ca.matchesSelector).call(a,o););return%20a%7D)(e,%22nav,%5Brole=navigation%5D%22),e.childNodes.length%3E0&&(e.childNodes%5B0%5D.tagName&&(e.childNodes%5B0%5D.tagName.toUpperCase()!==%22IMG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22SVG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22FIGURE%22%7C%7C(h=!0)),!(function(a)%7Bc=!1,u=!1,i=!1;let%20o=getComputedStyle(a);for(let%20n=0;n%3Co.length;n++)%7Blet%20t=o%5Bn%5D,r=o.getPropertyValue(t);t===%22text-decoration-line%22&&r===%22underline%22&&(u=!0),t!==%22border-bottom-style%22%7C%7Cr!==%22solid%22&&r!==%22dotted%22&&r!==%22dashed%22%7C%7C(i=!0),t===%22border-bottom-color%22&&r===%22transparent%22&&(i=!1),(u%7C%7Ci)&&(c=!0)%7Dreturn%20c%7D)(e)&&!h))%7Bl+=%60-------%0A%60,l+=%22Link%20text:%20%22+e.textContent+%60%0A%60,p%7C%7C((function(o)%7Bo.classList.add(%22problem-highlight%22)%7D)(e),l+=%22Affected%20node%20(xpath):%20%22+(function(o)%7Blet%20n,t=o,r=o.tagName.toLowerCase(),s=%22%22,d=%22%22,m=%22%22,g=%22%22;for(;t.parentNode;)%7Bif((n=t.parentNode).tagName)%7Bs=n.tagName.toLowerCase();let%20C=n.querySelectorAll(t.tagName);m=C.length%3E1?%22%5B%22+parseInt(Array.from(C).indexOf(t)+1)+%22%5D%22:%22%22,d=(r=t.tagName.toLowerCase())+m+g+d,g=%22/%22%7Dt=n%7Dreturn%20s===%22%22&&(s=r),d=%22//%22+s+m+g+d%7D)(e)+%60%0A%60,f++);let%20a=(function(o,n)%7Blet%20t=N(o%5B0%5D,o%5B1%5D,o%5B2%5D),r=N(n%5B0%5D,n%5B1%5D,n%5B2%5D);return(Math.max(t,r)+.05)/(Math.min(t,r)+.05)%7D)(x(getComputedStyle(e).color),x(getComputedStyle(e.parentNode).color));p?l+=%60Link%20is%20inside%20a%20%3Cnav%3E%20element%20and%20therefore%20its%20position/display%20does%20not%20require%20the%20underline%20for%20it%20to%20be%20perceived%20as%20a%20link.%0A%60:(a%3C3&&(l+=%22%5Cu%7B1F6A8%7D%20Contrast%20between%20link%20text%20and%20parent%20text%20node%20is%20under%203:1.%20Ratio%20is%20%22+a.toFixed(2)+%22:1.%22),l+=%60%0A%20%20%20Very%20likely%20a%20%5BSC%201.4.1%20Use%20of%20Color%5D(https://www.w3.org/TR/WCAG21/#use-of-color)%20issue%0A%60)%7D%7D),f%3E0)%7Blet%20e=f+%22%20possible%20issues%20with%20non-underlined%20links%20found%22;l=e+%60%0A%60+l,alert(e+%22%20(check%20console%20for%20more%20details)%22)%7Delse%20alert(%22No%20non-underlined%20links%20found%20(outside%20of%20a%20navigation%20area)%22);console.log(l)%7Dy();var%20w=l%7D)();%7D)();%0A" + "auditing": true, + "pageTest": true, + "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;var%20l=%22%22;function%20y()%7Bconsole.clear();let%20c=!1,u=!1,i=!1,p=!1,k=document.querySelectorAll(%22a%22),f=0,h=!1,b=!1;function%20N(e,a,o)%7Blet%20n=%5Be,a,o%5D.map(function(t)%7Breturn(t/=255)%3C=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)%7D);return%20.2126*n%5B0%5D+.7152*n%5B1%5D+.0722*n%5B2%5D%7Dfunction%20x(e)%7Breturn%20e=(e=(e=e.replace(%22rgb(%22,%22%22)).replace(%22)%22,%22%22)).split(%22,%20%22)%7Dif(function()%7Blet%20e=document.createElement(%22style%22);e.textContent=%22.problem-highlight%20%7Boutline:5px%20solid%20darkred;outline-offset:3px;box-shadow:%200px%200px%200px%2010px%20#fff;%7D%22,document.head.appendChild(e)%7D(),Array.from(k).forEach(e=%3E%7Bif(h=!1,b=!1,p=function(a,o)%7Bfor(;(a=a.parentElement)&&!(a.matches%7C%7Ca.matchesSelector).call(a,o););return%20a%7D(e,%22nav,%5Brole=navigation%5D%22),e.childNodes.length%3E0&&(e.childNodes%5B0%5D.tagName&&(e.childNodes%5B0%5D.tagName.toUpperCase()!==%22IMG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22SVG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22FIGURE%22%7C%7C(h=!0)),!function(a)%7Bc=!1,u=!1,i=!1;let%20o=getComputedStyle(a);for(let%20n=0;n%3Co.length;n++)%7Blet%20t=o%5Bn%5D,r=o.getPropertyValue(t);t===%22text-decoration-line%22&&r===%22underline%22&&(u=!0),t!==%22border-bottom-style%22%7C%7Cr!==%22solid%22&&r!==%22dotted%22&&r!==%22dashed%22%7C%7C(i=!0),t===%22border-bottom-color%22&&r===%22transparent%22&&(i=!1),(u%7C%7Ci)&&(c=!0)%7Dreturn%20c%7D(e)&&!h))%7Bl+=%60-------%0A%60,l+=%22Link%20text:%20%22+e.textContent+%60%0A%60,p%7C%7C(function(o)%7Bo.classList.add(%22problem-highlight%22)%7D(e),l+=%22Affected%20node%20(xpath):%20%22+function(o)%7Blet%20n,t=o,r=o.tagName.toLowerCase(),s=%22%22,d=%22%22,m=%22%22,g=%22%22;for(;t.parentNode;)%7Bif((n=t.parentNode).tagName)%7Bs=n.tagName.toLowerCase();let%20C=n.querySelectorAll(t.tagName);m=C.length%3E1?%22%5B%22+parseInt(Array.from(C).indexOf(t)+1)+%22%5D%22:%22%22,d=(r=t.tagName.toLowerCase())+m+g+d,g=%22/%22%7Dt=n%7Dreturn%20s===%22%22&&(s=r),d=%22//%22+s+m+g+d%7D(e)+%60%0A%60,f++);let%20a=function(o,n)%7Blet%20t=N(o%5B0%5D,o%5B1%5D,o%5B2%5D),r=N(n%5B0%5D,n%5B1%5D,n%5B2%5D);return(Math.max(t,r)+.05)/(Math.min(t,r)+.05)%7D(x(getComputedStyle(e).color),x(getComputedStyle(e.parentNode).color));p?l+=%60Link%20is%20inside%20a%20%3Cnav%3E%20element%20and%20therefore%20its%20position/display%20does%20not%20require%20the%20underline%20for%20it%20to%20be%20perceived%20as%20a%20link.%0A%60:(a%3C3&&(l+=%22%5Cu%7B1F6A8%7D%20Contrast%20between%20link%20text%20and%20parent%20text%20node%20is%20under%203:1.%20Ratio%20is%20%22+a.toFixed(2)+%22:1.%22),l+=%60%0A%20%20%20Very%20likely%20a%20%5BSC%201.4.1%20Use%20of%20Color%5D(https://www.w3.org/TR/WCAG21/#use-of-color)%20issue%0A%60)%7D%7D),f%3E0)%7Blet%20e=f+%22%20possible%20issues%20with%20non-underlined%20links%20found%22;l=e+%60%0A%60+l,alert(e+%22%20(check%20console%20for%20more%20details)%22)%7Delse%20alert(%22No%20non-underlined%20links%20found%20(outside%20of%20a%20navigation%20area)%22);console.log(l)%7Dy();var%20w=l%7D)();%7D)();%0A" }, { + "file": "page-link.js", "bookmarklet": "Page link", "description": "Copy page title and URL, separated by hyphens", - "file": "page-link.js", - "auditing": true, - "pageTest": "self", "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "utility" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bvar%20t=document.title+%22%20%5Cu2014%20%22+location.href;window.prompt(%22Plain%20text%20link:%22,t);%7D)();%0A" }, { + "file": "parsing-only.js", "bookmarklet": "Parsing only", "description": "Reduce HTML validation results to 4.1.1 Parsing (A) only", - "file": "parsing-only.js", - "auditing": true, - "pageTest": "self", "source": "Steve Faulkner", "sourceUrl": "https://cdpn.io/stevef/debug/dyGeywr", "tags": [ "4.1.1 Parsing (A)" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20r=!0,i=%5B%22tag%20seen%22,%22Stray%20end%20tag%22,%22Bad%20start%20tag%22,%22violates%20nesting%20rules%22,%22Duplicate%20ID%22,%22first%20occurrence%20of%20ID%22,%22Unclosed%20element%22,%22not%20allowed%20as%20child%20of%20element%22,%22unclosed%20elements%22,%22not%20allowed%20on%20element%22,%22unquoted%20attribute%20value%22,%22Duplicate%20attribute%22%5D,o,l,s,e,t,n,a=0;if(o=i.join(%22%7C%22),l=document.getElementById(%22results%22),!l)%7Balert(%22No%20results%20container%20found.%22);return%7Dfor(s=l.getElementsByTagName(%22li%22),n=0;n%3Cs.length;n++)e=s%5Bn%5D,e.className!==%22%22&&(t=(e.innerText!==void%200?e.innerText:e.textContent)+%22%22,(t.match(o)===null%7C%7Cr==!0&&t.indexOf(%22not%20allowed%20on%20element%22)!==-1&&t.indexOf(%22ng-%22)!==-1)&&(e.style.display=%22none%22,e.className=e.className+%22%20steveNoLike%22,a++));alert(%22Complete.%20%22+a+%22%20items%20removed.%22)%7D)();%7D)();%0A" }, { + "file": "placeholder-contrast.js", "bookmarklet": "Placeholder contrast checker", "description": "Measure contrast of placeholder text", - "file": "placeholder-contrast.js", - "auditing": true, - "pageTest": true, - "source": " Jason Morris", + "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "accessibility", "1.4.3 Contrast (Minimum) (AA)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bfunction%20s(o,e,t)%7Blet%5Bl,r,c%5D=%5Bo,e,t%5D.map(n=%3E(n=n/255,n%3C=.03928?n/12.92:Math.pow((n+.055)/1.055,2.4)));return%20.2126*l+.7152*r+.0722*c%7Dfunction%20u(o,e)%7Blet%20t=Math.max(o,e),l=Math.min(o,e);return(t+.05)/(l+.05)%7Dfunction%20d(o)%7Breturn%20o.match(/%5Cd+/g).map(Number)%7Dfunction%20g(o)%7Blet%20e=document.createElement(%22style%22),t=%22temp-%22+Math.random().toString(36).substr(2,9);o.classList.add(t),e.textContent=%60.$%7Bt%7D::placeholder%20%7B%20background-color:%20inherit;%20%7D%60,document.head.appendChild(e);let%20r=window.getComputedStyle(o,%22::placeholder%22).color;return%20o.classList.remove(t),e.remove(),r%7Dlet%20i=document.querySelectorAll(%22input%5Bplaceholder%5D,%20textarea%5Bplaceholder%5D%22);console.group(%22Placeholder%20Contrast%20Analysis%22),console.log(%22Analyzing%20%22+i.length+%60%20form%20elements...%0A%60),i.forEach((o,e)=%3E%7Blet%20t=window.getComputedStyle(o),l=g(o),r=t.backgroundColor,c=d(l),n=d(r),p=s(...c),h=s(...n),a=u(p,h),m=o.tagName.toLowerCase()+(o.id?%22#%22+o.id:%22%22)+(o.className?%22.%22+o.className.split(%22%20%22).join(%22.%22):%22%22)+%22::placeholder%22;console.group(%60Element%20$%7Be+1%7D:%20$%7Bm%7D%60),console.log(%22Placeholder%20Text:%22,o.placeholder),console.log(%22Placeholder%20Color:%22,l),console.log(%22Background:%22,r),a%3C4.5?console.log(%22%5Cu%7B1F6D1%7D%20Contrast%20Ratio:%22,a.toFixed(2)):console.log(%22%5Cu2705%20Contrast%20Ratio:%22,a.toFixed(2)),console.groupEnd(),o.style.outline=a%3C4.5?%225px%20solid%20#ff0000%22:%222px%20solid#00ff00%22%7D),console.groupEnd()%7D)();%7D)();%0A" }, { + "file": "service-html-validator.js", "bookmarklet": "Validate", "description": "Validate HTML of DOM", - "file": "service-html-validator.js", - "auditing": true, - "pageTest": "self", "source": "Deque", "sourceUrl": "https://dequeuniversity.com/validator", "tags": [ "4.1.1 Parsing (A)" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7B(function()%7B(function()%7Bvar%20t=document.doctype,d=%22%3C!DOCTYPE%20%22+t.name+(t.publicId?'%20PUBLIC%20%22'+t.publicId+'%22':%22%22)+(!t.publicId&&t.systemId?%22%20SYSTEM%22:%22%22)+(t.systemId?'%20%22'+t.systemId+'%22':%22%22)+%22%3E%22,m=document.documentElement.outerHTML,r=d+m,a=document.getElementById(%22deque-w3c-validator-bookmarklet%22);a&&a.remove();var%20e=document.createElement(%22form%22);e.id=%22deque-w3c-validator-bookmarklet%22,e.method=%22POST%22,e.action=%22https://validator.w3.org/nu/?showsource=yes&nocache=%22+Math.random(),e.target=%22_blank%22,e.enctype=%22multipart/form-data%22;var%20o=document.createElement(%22textarea%22);o.name=%22content%22,o.value=r,e.appendChild(o),document.body.appendChild(e),e.submit(),a=document.getElementById(%22deque-w3c-validator-bookmarklet%22),a&&a.remove()%7D)()%7D)();%7D)();%0A" }, { + "file": "text-spacing.js", "bookmarklet": "Text spacing", "description": "Test on WCAG 1.4.12 Text Spacing", - "file": "text-spacing.js", - "auditing": true, - "pageTest": "self", "source": "Steve Faulkner", "sourceUrl": "https://codepen.io/stevef/pen/YLMqbo", "tags": [ "1.4.12 Text Spacing (AA)" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document,l=%22phltsbkmklt%22,c=t.getElementById(l),a=t.querySelectorAll(%22iframe%22),e=0,i=a.length;if(c)%7Blet%20o=function(n)%7Bfor(var%20d%20of%20n.querySelectorAll(%22*%22))d.shadowRoot&&(d.shadowRoot.getElementById(l).remove(),o(d.shadowRoot))%7D;var%20m=o;if(c.remove(),i)for(e=0;e%3Ci;e++)try%7Ba%5Be%5D.contentWindow.document.getElementById(l).remove(),o(a%5Be%5D.contentWindow.document)%7Dcatch(n)%7Bconsole.log(n)%7Do(t)%7Delse%7Blet%20o=function(n)%7Bfor(var%20d%20of%20n.querySelectorAll(%22*%22))d.shadowRoot&&(d.shadowRoot.appendChild(r.cloneNode(!0)),o(d.shadowRoot))%7D;var%20h=o,r=t.createElement(%22style%22);for(r.id=l,r.appendChild(t.createTextNode(%22*%7Bline-height:1.5%20!important;letter-spacing:0.12em%20!important;word-spacing:0.16em%20!important;%7Dp%7Bmargin-bottom:2em%20!important;%7D%22)),t.getElementsByTagName(%22head%22)%5B0%5D.appendChild(r),e=0;e%3Ci;e++)try%7Ba%5Be%5D.contentWindow.document.getElementsByTagName(%22head%22)%5B0%5D.appendChild(r.cloneNode(!0)),o(a%5Be%5D.contentWindow.document)%7Dcatch(n)%7Bconsole.log(n)%7Do(t)%7D%7D)();%7D)();%0A" }, { + "file": "titles.js", "bookmarklet": "Titles", "description": "Display all titles", - "file": "titles.js", - "auditing": true, - "pageTest": false, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "accessibility" ], - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20k(t,e)%7Be.parentNode.insertBefore(t,e.nextSibling)%7Dfunction%20w(t)%7Blet%20e=window.getComputedStyle(t);return%20e.display===%22none%22%7C%7Ce.opacity===0%7C%7Ce.clipPath===%22inset(100%25)%22&&e.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ce.height===%221px%22&&e.width===%221px%22&&e.overflow===%22hidden%22%7Dfunction%20B(t)%7Blet%20e=window.getComputedStyle(t);e.position===%22absolute%22&&e.overflow===%22hidden%22&&(t.style.height=%22auto%22,t.style.width=%22auto%22,t.style.position=%22relative%22,t.style.overflow=%22visible%22,t.style.display=%22block%22,t.style.opacity=1),(t.getAttribute(%22hidden%22)===%22%22%7C%7Ct.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ct.getAttribute(%22hidden%22)===%22true%22)&&t.removeAttribute(%22hidden%22),e.visibility===%22hidden%22&&(t.style.visibility=%22visible%22),e.display===%22none%22&&(t.style.display=%22block%22),e.opacity===0&&(t.style.opacity=1)%7Dlet%20o=%22%22,i=%22%22,E=document.querySelectorAll(%22body%20%5Btitle%5D,iframe%22),l=1,b=0,y=0,g=%22%22,a,c=%22%22;Array.from(E).forEach(function(t)%7Ba=%22No%22,(t.getAttribute(%22tabindex%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22%7C%7C(t.tagName===%22INPUT%22%7C%7Ct.tagName===%22BUTTON%22%7C%7Ct.tagName===%22TEXTAREA%22%7C%7Ct.tagName===%22SELECT%22%7C%7Ct.tagName===%22IFRAME%22%7C%7Ct.tagName===%22A%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22&&!t.disabled)&&(a=%22Yes%22);let%20e=document.createElement(%22div%22);e.appendChild(t.cloneNode(!0)),g=e.innerHTML;let%20s=%22%22,r=!1,n=!1;t.setAttribute(%22data-title-ref%22,l);let%20x=!1,A=t.querySelectorAll(%22img%22);x=A.length%3E0,x&&Array.from(A).forEach(function(m)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),m.getAttribute(%22alt%22)?d.textContent=%22%20%22+m.getAttribute(%22alt%22)+%22%20%22:d.textContent=%22**%20Image%20with%20empty%20or%20missing%20alt%20**%22,k(d,m)%7D);let%20p=t.textContent;t.tagName===%22IMG%22&&(p=t.getAttribute(%22alt%22));let%20u=p,h=t.getAttribute(%22title%22);u===null&&(u=%22%22),h===null&&(h=%22%22),w(t)&&(B(t),w(t)?s+=%22-%20Element%20is%20hidden%3Cbr%3E%22:s+=%22-%20Element%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),n&&(r=!1),i+=%22%3Ctr%22,i+='%20data-title-ref=%22'+l+'%22',u.trim()===h.trim()?(r=!1,n=!1):t.tagName!==%22IFRAME%22&&(r=!1,n=!0,b++,s+=%22-%20The%20title%20text%20differs%20from%20the%20on-screen%20text.%3Cbr%3E%22,a===%22Yes%22&&(s+=%22-%20This%20is%20an%20interactive%20element,%20but%20the%20title%20attribute%20*may*%20be%20ignored%20by%20assistive%20tech%20(depending%20on%20user%20settings).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20As%20this%20is%20a%20non-interactive%20element,%20the%20title%20attribute%20will%20be%20ignored%20by%20assistive%20tech.%3Cbr%3E%22)),t.tagName===%22IFRAME%22&&h.trim()===%22%22&&(r=!1,n=!0,b++,s+=%22An%20%3Ccode%3Eiframe%3C/code%3E%20MUST%20have%20a%20title%20attribute.%3Cbr%3E%22),r&&(i+='%20class=%22warn%22'),n&&(i+='%20class=%22issue%20err%22'),i+=%22%3E%22,i+=%22%3Ctd%3E%22+p+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22+h+%22%3C/td%3E%22,u.trim()===h.trim()&&u.trim()!==%22%22&&(s+=%22-%20title%20text%20is%20identical%20to%20on-screen%20text%20(superfluous,%20but%20not%20harmful).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20This%20is%20not%20an%20interactive/focusable%20element.%20The%20title%20attribute%20will%20not%20be%20available%20to%20anyone%20expect%20mouse%20users%20(touch%20screen,%20keyboard-only,%20assistive%20tech%20users%20all%20excluded).%3Cbr%3E%22),i+=%22%3Ctd%3E%22+a+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22,r&&(i+='%3Cdiv%20class=%22issues%22%3EPossible%20title%20issue%20found%20with%20this%20element%3C/div%3E'),n&&(i+='%3Cdiv%20class=%22issues%22%3EDefinite%20title%20issue%20found%20with%20this%20element%3C/div%3E'),c=%22Element%20with%20title%20'%22+p.trim()+%60':%0A%60+s+%60Markup%20with%20issue:%0A%60+g+%60%0A---------------%0A%60,i+=s+'%3Cbr%3E%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+l+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+l+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+g+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',i+='%3Ctd%3E%3Cbutton%20data-title-ref=%22'+l+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',i+=%22%3C/tr%3E%22,l++,(r%7C%7Cn)&&y++,n&&(c=c.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(c))%7D),o='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:rebeccapurple;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.checkDiffs:after%7Bcontent:%22Accessible%20name%20differs%22;color:#a50202;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:#a50202;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:elWithTitle,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20elements%20with%20titles%20on%20this%20page.%3C/h1%3E',b%3E0&&(o+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20elements%20with%20definite%20title%20issues('+y+%22).%3C/label%3E%3Cbr%3E%22),o+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20elements%20with%20%60title%60%20on%20page%3C/button%3E',o+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20things%20with%20title%20attributes%20on%20this%20page%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%20scope=%22col%22%3EOn-screen%20text%3C/th%3E%3Cth%3ETitle%20text%3C/th%3E%3Cth%3EInteractive?%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+i+%22%3C/tbody%3E%3C/table%3E%22,o+=%22%3Cscript%3Efunction%20showElsWithTitles()%7B%22,o+=%22var%20refWindow=window.opener;%22,o+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20titleToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BtitleToHighlight=%22%5Bdata-title-ref='%22%20+%20highlightButton.getAttribute(%22data-title-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(titleToHighlight).setAttribute(%22tabindex%22,%22-1%22);refWindow.document.querySelector(titleToHighlight).focus();refWindow.document.querySelector(titleToHighlight).style.outline=%224px%20dashed%20rebeccapurple%22;refWindow.document.querySelector(titleToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(titleToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,o+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',o+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',o+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowElsWithTitles();%7D);%3C%5C/script%3E';let%20f=window.open(%22%22,%22popUpWinTitles%22,%22height=800,width=1000%22);f.document.open(),f.document.write(o),f.document.close()%7Dv()%7D)();%7D)();%0A" + "auditing": true, + "pageTest": false, + "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20k(t,e)%7Be.parentNode.insertBefore(t,e.nextSibling)%7Dfunction%20w(t)%7Blet%20e=window.getComputedStyle(t);return%20e.display===%22none%22%7C%7Ce.opacity===0%7C%7Ce.clipPath===%22inset(100%25)%22&&e.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ce.height===%221px%22&&e.width===%221px%22&&e.overflow===%22hidden%22%7Dfunction%20B(t)%7Blet%20e=window.getComputedStyle(t);e.position===%22absolute%22&&e.overflow===%22hidden%22&&(t.style.height=%22auto%22,t.style.width=%22auto%22,t.style.position=%22relative%22,t.style.overflow=%22visible%22,t.style.display=%22block%22,t.style.opacity=1),(t.getAttribute(%22hidden%22)===%22%22%7C%7Ct.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ct.getAttribute(%22hidden%22)===%22true%22)&&t.removeAttribute(%22hidden%22),e.visibility===%22hidden%22&&(t.style.visibility=%22visible%22),e.display===%22none%22&&(t.style.display=%22block%22),e.opacity===0&&(t.style.opacity=1)%7Dlet%20o=%22%22,i=%22%22,E=document.querySelectorAll(%22body%20%5Btitle%5D,iframe%22),l=1,b=0,y=0,g=%22%22,a,c=%22%22;Array.from(E).forEach(function(t)%7Ba=%22No%22,(t.getAttribute(%22tabindex%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22%7C%7C(t.tagName===%22INPUT%22%7C%7Ct.tagName===%22BUTTON%22%7C%7Ct.tagName===%22TEXTAREA%22%7C%7Ct.tagName===%22SELECT%22%7C%7Ct.tagName===%22IFRAME%22%7C%7Ct.tagName===%22A%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22&&!t.disabled)&&(a=%22Yes%22);let%20e=document.createElement(%22div%22);e.appendChild(t.cloneNode(!0)),g=e.innerHTML;let%20s=%22%22,r=!1,n=!1;t.setAttribute(%22data-title-ref%22,l);let%20x=!1,A=t.querySelectorAll(%22img%22);if(x=A.length%3E0,x)%7Blet%20S=%22%22;Array.from(A).forEach(function(m)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),m.getAttribute(%22alt%22)?d.textContent=%22%20%22+m.getAttribute(%22alt%22)+%22%20%22:d.textContent=%22**%20Image%20with%20empty%20or%20missing%20alt%20**%22,k(d,m)%7D)%7Dlet%20p=t.textContent;t.tagName===%22IMG%22&&(p=t.getAttribute(%22alt%22));let%20u=p,h=t.getAttribute(%22title%22);u===null&&(u=%22%22),h===null&&(h=%22%22),w(t)&&(B(t),w(t)?s+=%22-%20Element%20is%20hidden%3Cbr%3E%22:s+=%22-%20Element%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),n&&(r=!1),i+=%22%3Ctr%22,i+='%20data-title-ref=%22'+l+'%22',u.trim()===h.trim()?(r=!1,n=!1):t.tagName!==%22IFRAME%22&&(r=!1,n=!0,b++,s+=%22-%20The%20title%20text%20differs%20from%20the%20on-screen%20text.%3Cbr%3E%22,a===%22Yes%22&&(s+=%22-%20This%20is%20an%20interactive%20element,%20but%20the%20title%20attribute%20*may*%20be%20ignored%20by%20assistive%20tech%20(depending%20on%20user%20settings).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20As%20this%20is%20a%20non-interactive%20element,%20the%20title%20attribute%20will%20be%20ignored%20by%20assistive%20tech.%3Cbr%3E%22)),t.tagName===%22IFRAME%22&&h.trim()===%22%22&&(r=!1,n=!0,b++,s+=%22An%20%3Ccode%3Eiframe%3C/code%3E%20MUST%20have%20a%20title%20attribute.%3Cbr%3E%22),r&&(i+='%20class=%22warn%22'),n&&(i+='%20class=%22issue%20err%22'),i+=%22%3E%22,i+=%22%3Ctd%3E%22+p+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22+h+%22%3C/td%3E%22,u.trim()===h.trim()&&u.trim()!==%22%22&&(s+=%22-%20title%20text%20is%20identical%20to%20on-screen%20text%20(superfluous,%20but%20not%20harmful).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20This%20is%20not%20an%20interactive/focusable%20element.%20The%20title%20attribute%20will%20not%20be%20available%20to%20anyone%20expect%20mouse%20users%20(touch%20screen,%20keyboard-only,%20assistive%20tech%20users%20all%20excluded).%3Cbr%3E%22),i+=%22%3Ctd%3E%22+a+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22,r&&(i+='%3Cdiv%20class=%22issues%22%3EPossible%20title%20issue%20found%20with%20this%20element%3C/div%3E'),n&&(i+='%3Cdiv%20class=%22issues%22%3EDefinite%20title%20issue%20found%20with%20this%20element%3C/div%3E'),c=%22Element%20with%20title%20'%22+p.trim()+%60':%0A%60+s+%60Markup%20with%20issue:%0A%60+g+%60%0A---------------%0A%60,i+=s+'%3Cbr%3E%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+l+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+l+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+g+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',i+='%3Ctd%3E%3Cbutton%20data-title-ref=%22'+l+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',i+=%22%3C/tr%3E%22,l++,(r%7C%7Cn)&&y++,n&&(c=c.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(c))%7D),o='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:rebeccapurple;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.checkDiffs:after%7Bcontent:%22Accessible%20name%20differs%22;color:#a50202;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:#a50202;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:elWithTitle,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20elements%20with%20titles%20on%20this%20page.%3C/h1%3E',b%3E0&&(o+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20elements%20with%20definite%20title%20issues('+y+%22).%3C/label%3E%3Cbr%3E%22),o+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20elements%20with%20%60title%60%20on%20page%3C/button%3E',o+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20things%20with%20title%20attributes%20on%20this%20page%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%20scope=%22col%22%3EOn-screen%20text%3C/th%3E%3Cth%3ETitle%20text%3C/th%3E%3Cth%3EInteractive?%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+i+%22%3C/tbody%3E%3C/table%3E%22,o+=%22%3Cscript%3Efunction%20showElsWithTitles()%7B%22,o+=%22var%20refWindow=window.opener;%22,o+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20titleToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BtitleToHighlight=%22%5Bdata-title-ref='%22%20+%20highlightButton.getAttribute(%22data-title-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(titleToHighlight).setAttribute(%22tabindex%22,%22-1%22);refWindow.document.querySelector(titleToHighlight).focus();refWindow.document.querySelector(titleToHighlight).style.outline=%224px%20dashed%20rebeccapurple%22;refWindow.document.querySelector(titleToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(titleToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,o+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',o+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',o+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowElsWithTitles();%7D);%3C%5C/script%3E';let%20f=window.open(%22%22,%22popUpWinTitles%22,%22height=800,width=1000%22);f.document.open(),f.document.write(o),f.document.close()%7Dv()%7D)();%7D)();%0A" }, { + "file": "tool-andi.js", "bookmarklet": "ANDI", "description": "Accessible Name & Description Inspector is a free accessibility testing tool", - "file": "tool-andi.js", - "auditing": true, - "pageTest": false, "source": "Accessible Solutions Branch of the Social Security Administration", "sourceUrl": "https://www.ssa.gov/accessibility/andi/help/install.html", "tags": [ "accessibility", "external" ], + "auditing": true, + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document.createElement(%22script%22);t.setAttribute(%22src%22,%22https://www.ssa.gov/accessibility/andi/andi.js%22),document.body.appendChild(t)%7D)();%7D)();%0A" }, { + "file": "window-1280x1024.js", "bookmarklet": "Open 1280x1024", "description": "Opens a new window with the current URL at 1280x1024", - "file": "window-1280x1024.js", - "auditing": true, - "pageTest": true, "source": "Mike in a CSS Tricks article comment", "sourceUrl": "https://css-tricks.com/snippets/javascript/1024x768-bookmarklet/#comment-1766738", "tags": [ "1.4.4 Resize Text (AA)", "1.4.10 Reflow (AA)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=%22w%22+new%20Date().getTime(),o=%22toolbar=yes,location=yes,status=yes,resizable=yes,favorites=yes,width=1280,height=1024,left=0,top=0%22,e=document.createElement(%22P%22);e.innerHTML='%3Ca%20href=%22#%22%20id=%22'+t+%60%22%20target=%22_blank%22%20onclick=%22window.open(window.location.href,%20'',%20'%60+o+%60'%20);%20return%20false;%22%3E%3C/a%3E%3C/p%3E%60,document.body.appendChild(e),document.getElementById(t).click()&&document.body.removeChild(e)%7D)();%7D)();%0A" }, { + "file": "wtfocus.js", "bookmarklet": "WTFocus", "description": "Display information with focusable elements", - "file": "wtfocus.js", - "auditing": true, - "pageTest": "self", "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "2.4.4 Link Purpose (In Context) (A)", - "4.1.2 Name, Role, Value (A)" + "4.1.2 Name", + "Role", + "Value (A)" ], - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20re()%7Blet%20z=document.activeElement,H=document.querySelectorAll('a%5Bhref%5D,button,select,input:not(%5Btype=%22hidden%22%5D),textarea,summary,area,%5Btabindex%5D:not(#WTFocusPanel):not(%5Btabindex%5E=%22-1%22%5D),%5Bcontenteditable%5D:not(%5Bcontenteditable=%22false%22%5D)'),E=%22background:#fff;color:darkgreen;font-weight:bold;text-decoration:line-through%22,j=%22font-weight:bold;color:#99f170;background:#333;display:inline-block;padding:3px;%22,h=%22color:pink;background:#333;padding:3px;%22,A=%22color:black;background:#fefbe3;font-weight:bold;%22,a=document.createElement(%22div%22),O=document.createElement(%22div%22),R=20,Y=400,w=7,ie='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F449%7D%5Cu%7B1F3FD%7D%3C/span%3E%3Cspan%20class=%22visually-hidden%22%3EAccessible%20name%20provided%20by%3C/span%3E%20',ce='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F6A8%7D%3C/span%3E%20%3Cspan%20class=%22visually-hidden%22%3EWarning%3C/span%3E',V,P=%22Accessible%20name:%20%22,k=!1,p=%22%22,m=!1,x=!1,I=!1,G=!1,L=!1;function%20W()%7Bm=!1,x=!1%7Dfunction%20l(e,r,o,n,C)%7Bk&&(r=r.split(%22%3C%22).join(%22<%22).split(%22%3E%22).join(%22>%22),p+=%22%3Cli%22,(C%7C%7Cn)&&(p+='%20class=%22',C&&(p+=%22visible%22),n&&(p+=%22outline%22),p+='%22'),p+='%20role=%22listitem%22%3E%3Cspan%20style=%22'+o+'%22%3E',m&&(p+=ie),x&&(p+=ce),p+=e+%22%3C/span%3E %22+r+%60%3C/li%3E%0A%60),r=r.replace(%22<%22,%22%3C%22).replace(%22>%22,%22%3E%22),console.log(%22%25c%22+e+'%22'+r+'%22',o)%7Dfunction%20J()%7Blet%20e=document.createElement(%22button%22);e.textContent=%22Close%20(Esc)%22,e.setAttribute(%22type%22,%22button%22),e.setAttribute(%22class%22,%22panel-btn%22),e.addEventListener(%22click%22,()=%3E%7BD()%7D);let%20r=document.createElement(%22button%22);r.textContent=%22Change%20Mode%20(M)%22,r.setAttribute(%22type%22,%22button%22),r.setAttribute(%22class%22,%22panel-btn%22),r.addEventListener(%22click%22,o=%3E%7BK()%7D),a.appendChild(e),a.appendChild(r)%7Dfunction%20K()%7BL?(document.querySelector(%22#WTFocusPanel%22).classList.remove(%22curtainsMode%22),document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22),document.querySelector(%22#WTFocusCurtain%22).setAttribute(%22hidden%22,%22hidden%22),L=!1,P=%22Accessible%20name:%20%22):(document.querySelector(%22#WTFocusPanel%22).classList.add(%22curtainsMode%22),document.querySelector(%22#WTFocusCurtain%22).removeAttribute(%22hidden%22),L=!0,P=%22%22),Q(z),z.focus()%7Dfunction%20D()%7Bdocument.querySelector(%22#WTFocusCurtain%22).remove(),document.querySelector(%22#WTFocusPanel%22).remove(),document.querySelector(%22#panelStyles%22).remove(),document.querySelector(%22#focusStyles%22).remove()%7Dfunction%20Q(e)%7Blet%20r=e.getBoundingClientRect(),o=document.documentElement.scrollTop,n=r.right+R+Y,C=a.offsetHeight,q=o+r.top+C,i=window.innerWidth,c=window.innerHeight;L?document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22):n%3Ei?(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=%22auto%22,a.style.right=i-r.left+R-w+%22px%22,a.classList.add(%22toLeft%22)):(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=r.right+R-w+%22px%22,a.style.right=%22auto%22,a.classList.remove(%22toLeft%22))%7Dconsole.clear(),(function()%7Blet%20e=document.createElement(%22style%22);e.setAttribute(%22type%22,%22text/css%22),e.setAttribute(%22id%22,%22panelStyles%22),e.textContent=%22.dupeAccName%20%7Boutline:4px%20dashed%20#CC3300!important;outline-offset:%22+w+%22px!important;overflow:visible;%7D%20.WTFocusTempFocusStyle:focus%20%7Boutline:%22+w+%22px%20solid%20black!important;outline-offset:%22+w+%22px!important;overflow:visible;/*background:yellow!important;color:black!important;*/%7D%20.WTFocusTempFocusStyle.dupeAccName:focus%20%7Boutline-color:#CC3300!important;%7D%20.visually-hidden%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D#WTFocusCurtain%20%7Bbackground:black;position:%20fixed;top:%200;bottom:%200;left:%200;right:%200;z-index:49999%7D%22,document.querySelector(%22body%22).appendChild(e)%7D)(),document.querySelector(%22#WTFocusCurtain%22)&&D(),k=!0,p=%22%22,(function(e)%7Blet%20r=document.createElement(%22style%22);r.setAttribute(%22type%22,%22text/css%22),r.setAttribute(%22id%22,%22focusStyles%22),r.textContent=%22#WTFocusPanel.error%20%7Bbackground:darkred;%7D%20#WTFocusPanel.warning%20%7Bbackground:#CC3300;%7D%20#WTFocusPanel.curtainsMode.error%20%7Bbackground:black;%7D%20#WTFocusPanel.curtainsMode%20%7Bz-index:50000;position:fixed;top:50%25;left:50%25;transform:translate(-50%25,-50%25);%7D%20#WTFocusPanel.curtainsMode.warning%20%7Bbackground:black;%7D%20#WTFocusPanel%5Bhidden%5D%20%7Bdisplay:none;%7D%20#WTFocusPanel%20*%20%7Btext-align:left%7D%20#WTFocusPanel%20%7Bborder:2px%20solid%20#fff;z-index:1000;text-shadow:none;font-family:sans-serif;display:block;text-align:left;position:%20absolute;z-index:10000;background:%20black;padding:%2020px%2020px;width:%22+e+%22px;font-size:16px;%7D%20#WTFocusPanel%20button%20%7Bfont-weight:bold;background:none;color:#fff;padding:3px%2010px;font-size:14px;border:1px%20solid%20#fff;display:inline-block;margin:10px%201em%20-10px%200;%7D%20#WTFocusPanel%20ul,#WTFocusPanel%20li%20%7Bmargin:0;padding:0;list-style:none%7D%20#WTFocusPanel%20li%20%7Bmargin:3px%200;background:#fff;color:#333;padding:2px%7D%20#WTFocusPanel%20li.outline%20%7Boutline:4px%20solid%20rgb(58,%20190,%2058);outline-offset:-4px;padding:8px%7D%20#WTFocusPanel.error:before%20%7Bbackground:darkred%7D%20#WTFocusPanel.warning:before%20%7Bbackground:#CC3300%7D%20#WTFocusPanel:before%20%7Bcontent:'';display:block;height:20px;width:20px;transform:rotate(45deg);position:absolute;background:#000;left:-12px;top:3px;border:2px%20solid%20#fff;border-right:none;border-top:none;%7D%20#WTFocusPanel.toBottom:before%20%7Btop:auto;bottom:3px%7D%20#WTFocusPanel.toLeft:before%20%7Bleft:auto;right:-12px;border:2px%20solid%20#fff;border-left:none;border-bottom:none;%7D%20#WTFocusPanel.curtainsMode%20%7Boutline:10px%20solid%20orange;%7D%20#WTFocusPanel.curtainsMode:before%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li.visible%20%7Bdisplay:block;%7D%20#WTFocusPanel.curtainsMode%20li%20span%20%7Bdisplay:none!important;%7D%20%22,document.querySelector(%22head%22).appendChild(r)%7D)(Y),O.setAttribute(%22id%22,%22WTFocusCurtain%22),O.setAttribute(%22hidden%22,%22hidden%22),document.querySelector(%22body%22).appendChild(O),a.setAttribute(%22id%22,%22WTFocusPanel%22),L&&a.setAttribute(%22class%22,%22curtainsMode%22),a.setAttribute(%22aria-live%22,%22polite%22),a.setAttribute(%22tabindex%22,%22-1%22),a.setAttribute(%22hidden%22,%22hidden%22),a.setAttribute(%22role%22,%22region%22),a.setAttribute(%22aria-label%22,%22Accessibility%20properties%20panel%22),document.querySelector(%22body%22).appendChild(a),window.addEventListener(%22keyup%22,e=%3E%7Be.key===%22Escape%22&&document.querySelector(%22#WTFocusPanel%22)&&D()%7D),window.addEventListener(%22keyup%22,e=%3E%7Be.key.toLowerCase()===%22m%22&&document.querySelector(%22#WTFocusPanel%22)&&K()%7D),J();let%20U=%5B%5D;Array.from(H).forEach(function(e)%7Be.classList.add(%22WTFocusTempFocusStyle%22);let%20r=e.querySelectorAll(%22style%22);Array.from(r).forEach(function(o)%7Bo.remove()%7D),e.addEventListener(%22focus%22,()=%3E%7Blet%20o=e.getAttribute(%22role%22),n=e.tagName.toLowerCase();if(console.clear(),!o)%7Bif(n!=%22article%22&&n!=%22button%22&&n!=%22dialog%22&&n!=%22figure%22&&n!=%22img%22&&n!=%22main%22&&n!=%22math%22%7C%7C(o=n),n==%22summary%22&&(o=%22button%22),n==%22aside%22&&(o=%22complementary%22),n==%22dd%22&&(o=%22definition%22),n==%22html%22&&(o=%22document%22),n!=%22details%22&&n!=%22fieldset%22&&n!=%22optgroup%22%7C%7C(o=%22group%22),n!=%22menu%22&&n!=%22ol%22&&n!=%22ul%22%7C%7C(o=%22list%22),n==%22datalist%22&&(o=%22listbox%22),n==%22li%22&&(o=%22listitem%22),n==%22nav%22&&(o=%22navigation%22),n==%22progress%22&&(o=%22progressbar%22),n==%22hr%22&&(o=%22separator%22),n==%22output%22&&(o=%22status%22),n!=%22dfn%22&&n!=%22dt%22%7C%7C(o=%22term%22),n==%22a%22&&(o=%22link%22),n==%22select%22&&(o=%22listbox%22),n==%22textarea%22&&(o=%22textbox%22),n==%22input%22)%7Blet%20t=e.getAttribute(%22type%22).toLowerCase();t===%22text%22&&(o=%22textbox%22),t===%22range%22&&(o=%22slider%22),t===%22number%22&&(o=%22spinbutton%22),t!==%22checkbox%22&&t!==%22radio%22%7C%7C(o=t),t!==%22button%22&&t!==%22image%22&&t!==%22reset%22&&t!==%22submit%22%7C%7C(o=%22button%22)%7D%7Dz=e,Array.from(H).forEach(function(t)%7Bt.classList.remove(%22dupeAccName%22)%7D);let%20C=!1;m=!1,x=!1;let%20q=e.querySelectorAll(%22img,%20%5Brole='image'%5D%5Baria-label%5D,%20%5Brole='img'%5D%5Baria-label%5D%22);(C=q.length%3E0)&&Array.from(q).forEach(function(t)%7Blet%20d=document.createElement(%22SPAN%22);var%20T,B;d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22data-temp-node%22,%22true%22),t.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+t.getAttribute(%22alt%22)+%22%20%22),t.getAttribute(%22role%22)&&t.getAttribute(%22aria-label%22)&&(d.textContent=%22%20%22+t.getAttribute(%22aria-label%22)+%22%20%22),T=d,(B=t).parentNode.insertBefore(T,B.nextSibling)%7D),setTimeout(function()%7Be.classList.add(%22WTFocusTempFocusStyle%22)%7D,100),p=%22%22;let%20i=e.tagName.toLowerCase(),c=e.getAttribute(%22role%22);c&&(c=e.getAttribute(%22role%22).toLowerCase());let%20Z=%22%3C%22+i+%22%3E%22,_=!1,$=!1;c&&(Z=%22%3C%22+i+'%20role=%22'+c+'%22%3E',(c===%22link%22&&i===%22a%22%7C%7Cc===%22button%22&&i===%22button%22%7C%7Cc===%22image%22&&i===%22img%22%7C%7Cc===%22img%22&&i===%22img%22%7C%7Cc===%22navigation%22&&i===%22nav%22%7C%7Cc===%22heading%22&&(i===%22h1%22%7C%7Ci===%22h2%22%7C%7Ci===%22h3%22%7C%7Ci===%22h4%22%7C%7Ci===%22h5%22%7C%7Ci===%22h6%22))&&(_=!0),(c===%22link%22&&i!==%22a%22%7C%7Cc===%22button%22&&i!==%22button%22%7C%7C(c===%22image%22%7C%7Cc===%22image%22)&&i!==%22img%22%7C%7Cc===%22navigation%22&&i!==%22nav%22%7C%7Cc===%22heading%22&&i!==%22h1%22&&i!==%22h2%22&&i!==%22h3%22&&i!==%22h4%22&&i!==%22h5%22&&i!==%22h6%22)&&($=!0));let%20ee,b=e.textContent,f=e.ariaLabel,S=e.getAttribute(%22aria-labelledby%22),N=e.getAttribute(%22placeholder%22),F=%22%22,g=e.getAttribute(%22value%22),v=e.getAttribute(%22title%22),s=%22%22,y=%22%22,te=!1,oe=!1,u=%22%22,ne=!1;k&&Q(e),b=b.trim();let%20ae=(function(t,d)%7Bfor(;(t=t.parentElement)&&!(t.matches%7C%7Ct.matchesSelector).call(t,d););return%20t%7D)(e,%22label%22);if(ae&&(te=!0,s=y=ae.textContent.trim()),e.getAttribute(%22id%22))%7Blet%20t=document.querySelector(%22%5Bfor='%22+e.getAttribute(%22id%22)+%22'%5D%22);t&&(oe=!0,y=t.textContent)%7Dif(te%7C%7Coe%7C%7C(y=%22N/A%22),b%7C%7C(b=%22N/A%22),g%7C%7C(g=%22N/A%22),v%7C%7C(v=%22N/A%22),N%7C%7C(N=%22N/A%22),f%7C%7C(f=%22N/A%22),S)%7Blet%20t=(ee=S).split(%22%20%22);t.length%3E1?(Array.from(t).forEach(function(d)%7Bdocument.querySelector(%22#%22+d)?F+=document.querySelector(%22#%22+d).textContent+%22%20%22:F+=%22%5Cu2753%5Cu2753%5Cu2753%20%22%7D),F=F.trim()):F=document.querySelector(%22#%22+ee).textContent%7Delse%20S=%22N/A%22;let%20le=e.querySelectorAll(%22%5Baria-hidden='true'%5D,%5Brole='presentation'%5D%22),M=b;if(le.length%3E0&&(ne=!0,Array.from(le).forEach(function(t)%7Blet%20d=t.textContent;d!==%22%22&&(M=M.split(d).join(%22%20%22))%7D),M=M.trim()),i===%22input%22)%7Blet%20t=e.getAttribute(%22type%22);t===%22submit%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22image%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22cancel%22&&g===%22N/A%22&&(s=%22Cancel%22,u=%22Not%20provided%20(using%20default)%22)%7Dif(v!==%22N/A%22&&(s=v,u=%22title%20attribute%22),g!==%22N/A%22&&(s=g,u=%22value%20attribute%22),N!==%22N/A%22&&(s=N,u=%22placeholder%20attribute%22),b!==%22N/A%22&&(s=M,u=%22Inner%20text%20content%22),y!==%22N/A%22&&(s=y,u=%22%3Clabel%3E%20text%22),f!==%22N/A%22&&(s=f,u=%22aria-label%22),S!==%22N/A%22&&(s=F,u=%22aria-labelledby%22),console.log(%22%25cACTIVE%20ELEMENT:%20%22,%22background:#193c10;color:white;%22),console.log(e),I=e.getAttribute(%22data-dupe%22)===%22true%22,G=I&&s===%22%22,s===%22%22%7C%7CI)%7Bif(s===%22%22&&(x=!0,k&&a.classList.add(%22error%22),l(P+%22No%20accessible%20name!%22,%22%22,h),l(%22Accessible%20Name%20Source:%20N/A%22,%22%22,h)),I&&s!==%22%22)%7Bk&&a.classList.add(%22warning%22);let%20t=document.querySelectorAll(%22%5Bdata-accname='%22+s+%22'%5D%22),d=t.length;l(P,s,h,!1,!0),G%7C%7C(Array.from(t).forEach(function(T)%7BT.classList.add(%22dupeAccName%22)%7D),l(%22Duplicate%20warning!%22,d+%22%20elements%20on%20page%20have%20the%20same%20accessible%20name%22,h)),console.log(%22Elements%20on%20page%20that%20have%20identical%20accessible%20names:%22),Array.from(t).forEach(function(T)%7Bconsole.log(T)%7D),l(%22Accessible%20Name%20Source:%20%22,u,h)%7D%7Delse%20k&&(a.classList.remove(%22error%22),a.classList.remove(%22warning%22)),l(P,s,j,!1,!0),l(%22Accessible%20Name%20Source:%20%22,u,j);x=!1,l(%22HTML%20Element:%20%22,Z,j),l(%22Role:%20%22,o,%22color:#333;background:#fff;%22,!1,!0),k%7C%7Cconsole.log(%22%25cACCESSIBLE%20NAME%20COMES%20FROM:%20%22,%22background:#193c10;color:white;%22),_&&(x=!0,l(%22Superfluous%20%60role%60%20attribute%22,%22%22,h)),$&&(x=!0,l(%22Better%20to%20use%20a%20native%20HTML%20element%22,%22%22,h)),b=b.trim(),y=y.trim(),v=v.trim(),f=f.trim(),S=S.trim(),W(),u===%22placeholder%20attribute%22?(m=!0,l(%22@placeholder:%20%22,N,A,!0)):l(%22@placeholder:%20%22,N,N===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22title%20attribute%22?(m=!0,l(%22@title:%20%22,v,A,!0)):l(%22@title:%20%22,v,v===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22value%20attribute%22?(m=!0,l(%22@value:%20%22,g,A,!0)):l(%22@value:%20%22,g,g===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22Inner%20text%20content%22?(m=!0,l(C?%22Inner%20text%20content%20(includes%20image%20alt):%20%22:%22Inner%20text%20content:%20%22,b,A,!0),ne&&l(%22!%20elements%20hidden%20to%20AT%20removed%22,%22%22,A)):l(%22Text%20Content:%20%22,b,b===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22%3Clabel%3E%20text%22?(m=!0,l(%22Visible%20%60label%60%20text:%20%22,y,A,!0)):l(%22Visible%20%60label%60%20text:%20%22,y,y===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-label%22?f===b?(x=!0,l(%22%60aria-label%60%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-label%20value:%20%22,f,A,!0)):l(%22@aria-label%20value:%20%22,f,f===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-labelledby%22?F===b?(x=!0,l(%22%60aria-labelledby%60%20source%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-labelledby%20value:%20%22,S,A,!0),l(%22@aria-labelledby%20sources:%20%22,F,A)):(l(%22@aria-labelledby%20value:%20%22,S,%22color:#333;background:#fff;%22),l(%22@aria-labelledby%20sources:%20%22,%22N/A%22,%22color:#333;background:#fff;%22)),k&&(document.querySelector(%22#WTFocusPanel%22).innerHTML='%3Cul%20role=%22list%22%3E'+p+%22%3C/ul%3E%22,document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22hidden%22),J());let%20se=document.querySelectorAll(%22%5Bdata-temp-node%5D%22);Array.from(se).forEach(function(t)%7Bt.remove()%7D),e.setAttribute(%22data-accname%22,s),X%7C%7C(function(t,d)%7Blet%20T=!1;Array.from(U).forEach(function(B)%7BB===t&&(T=!0)%7D),T?(d.setAttribute(%22data-dupe%22,%22true%22),document.querySelector(%22%5Bdata-accname='%22+t+%22'%5D%22).setAttribute(%22data-dupe%22,%22true%22)):U.push(t)%7D)(s,e)%7D)%7D);let%20X=!1;(function()%7Bif(V=document.activeElement,Array.from(H).forEach(function(e)%7Bdocument.activeElement===e&&e.blur(),e.focus()%7D),X=!0,V.tagName===%22BODY%22)%7Blet%20e=document.querySelector(%22body%22);e.setAttribute(%22tabindex%22,%22-1%22),e.focus(),document.querySelector(%22#WTFocusPanel%22).setAttribute(%22hidden%22,%22hidden%22)%7Delse%20V.focus();console.clear()%7D)(),console.log(%22had%20focus%20=%20%22,z)%7Dre()%7D)();%7D)();%0A" + "auditing": true, + "pageTest": "self", + "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20re()%7Blet%20z=document.activeElement,H=document.querySelectorAll('a%5Bhref%5D,button,select,input:not(%5Btype=%22hidden%22%5D),textarea,summary,area,%5Btabindex%5D:not(#WTFocusPanel):not(%5Btabindex%5E=%22-1%22%5D),%5Bcontenteditable%5D:not(%5Bcontenteditable=%22false%22%5D)'),E=%22background:#fff;color:darkgreen;font-weight:bold;text-decoration:line-through%22,j=%22font-weight:bold;color:#99f170;background:#333;display:inline-block;padding:3px;%22,h=%22color:pink;background:#333;padding:3px;%22,A=%22color:black;background:#fefbe3;font-weight:bold;%22,a=document.createElement(%22div%22),O=document.createElement(%22div%22),R=20,Y=400,w=7,ie='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F449%7D%5Cu%7B1F3FD%7D%3C/span%3E%3Cspan%20class=%22visually-hidden%22%3EAccessible%20name%20provided%20by%3C/span%3E%20',ce='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F6A8%7D%3C/span%3E%20%3Cspan%20class=%22visually-hidden%22%3EWarning%3C/span%3E',V,P=%22Accessible%20name:%20%22,k=!1,p=%22%22,m=!1,x=!1,I=!1,G=!1,L=!1;function%20W()%7Bm=!1,x=!1%7Dfunction%20l(e,r,o,n,C)%7Bk&&(r=r.split(%22%3C%22).join(%22<%22).split(%22%3E%22).join(%22>%22),p+=%22%3Cli%22,(C%7C%7Cn)&&(p+='%20class=%22',C&&(p+=%22visible%22),n&&(p+=%22outline%22),p+='%22'),p+='%20role=%22listitem%22%3E%3Cspan%20style=%22'+o+'%22%3E',m&&(p+=ie),x&&(p+=ce),p+=e+%22%3C/span%3E %22+r+%60%3C/li%3E%0A%60),r=r.replace(%22<%22,%22%3C%22).replace(%22>%22,%22%3E%22),console.log(%22%25c%22+e+'%22'+r+'%22',o)%7Dfunction%20J()%7Blet%20e=document.createElement(%22button%22);e.textContent=%22Close%20(Esc)%22,e.setAttribute(%22type%22,%22button%22),e.setAttribute(%22class%22,%22panel-btn%22),e.addEventListener(%22click%22,()=%3E%7BD()%7D);let%20r=document.createElement(%22button%22);r.textContent=%22Change%20Mode%20(M)%22,r.setAttribute(%22type%22,%22button%22),r.setAttribute(%22class%22,%22panel-btn%22),r.addEventListener(%22click%22,o=%3E%7BK()%7D),a.appendChild(e),a.appendChild(r)%7Dfunction%20K()%7BL?(document.querySelector(%22#WTFocusPanel%22).classList.remove(%22curtainsMode%22),document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22),document.querySelector(%22#WTFocusCurtain%22).setAttribute(%22hidden%22,%22hidden%22),L=!1,P=%22Accessible%20name:%20%22):(document.querySelector(%22#WTFocusPanel%22).classList.add(%22curtainsMode%22),document.querySelector(%22#WTFocusCurtain%22).removeAttribute(%22hidden%22),L=!0,P=%22%22),Q(z),z.focus()%7Dfunction%20D()%7Bdocument.querySelector(%22#WTFocusCurtain%22).remove(),document.querySelector(%22#WTFocusPanel%22).remove(),document.querySelector(%22#panelStyles%22).remove(),document.querySelector(%22#focusStyles%22).remove()%7Dfunction%20Q(e)%7Blet%20r=e.getBoundingClientRect(),o=document.documentElement.scrollTop,n=r.right+R+Y,C=a.offsetHeight,q=o+r.top+C,i=window.innerWidth,c=window.innerHeight;L?document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22):n%3Ei?(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=%22auto%22,a.style.right=i-r.left+R-w+%22px%22,a.classList.add(%22toLeft%22)):(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=r.right+R-w+%22px%22,a.style.right=%22auto%22,a.classList.remove(%22toLeft%22))%7Dconsole.clear(),function()%7Blet%20e=document.createElement(%22style%22);e.setAttribute(%22type%22,%22text/css%22),e.setAttribute(%22id%22,%22panelStyles%22),e.textContent=%22.dupeAccName%20%7Boutline:4px%20dashed%20#CC3300!important;outline-offset:%22+w+%22px!important;overflow:visible;%7D%20.WTFocusTempFocusStyle:focus%20%7Boutline:%22+w+%22px%20solid%20black!important;outline-offset:%22+w+%22px!important;overflow:visible;/*background:yellow!important;color:black!important;*/%7D%20.WTFocusTempFocusStyle.dupeAccName:focus%20%7Boutline-color:#CC3300!important;%7D%20.visually-hidden%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D#WTFocusCurtain%20%7Bbackground:black;position:%20fixed;top:%200;bottom:%200;left:%200;right:%200;z-index:49999%7D%22,document.querySelector(%22body%22).appendChild(e)%7D(),document.querySelector(%22#WTFocusCurtain%22)&&D(),k=!0,p=%22%22,function(e)%7Blet%20r=document.createElement(%22style%22);r.setAttribute(%22type%22,%22text/css%22),r.setAttribute(%22id%22,%22focusStyles%22),r.textContent=%22#WTFocusPanel.error%20%7Bbackground:darkred;%7D%20#WTFocusPanel.warning%20%7Bbackground:#CC3300;%7D%20#WTFocusPanel.curtainsMode.error%20%7Bbackground:black;%7D%20#WTFocusPanel.curtainsMode%20%7Bz-index:50000;position:fixed;top:50%25;left:50%25;transform:translate(-50%25,-50%25);%7D%20#WTFocusPanel.curtainsMode.warning%20%7Bbackground:black;%7D%20#WTFocusPanel%5Bhidden%5D%20%7Bdisplay:none;%7D%20#WTFocusPanel%20*%20%7Btext-align:left%7D%20#WTFocusPanel%20%7Bborder:2px%20solid%20#fff;z-index:1000;text-shadow:none;font-family:sans-serif;display:block;text-align:left;position:%20absolute;z-index:10000;background:%20black;padding:%2020px%2020px;width:%22+e+%22px;font-size:16px;%7D%20#WTFocusPanel%20button%20%7Bfont-weight:bold;background:none;color:#fff;padding:3px%2010px;font-size:14px;border:1px%20solid%20#fff;display:inline-block;margin:10px%201em%20-10px%200;%7D%20#WTFocusPanel%20ul,#WTFocusPanel%20li%20%7Bmargin:0;padding:0;list-style:none%7D%20#WTFocusPanel%20li%20%7Bmargin:3px%200;background:#fff;color:#333;padding:2px%7D%20#WTFocusPanel%20li.outline%20%7Boutline:4px%20solid%20rgb(58,%20190,%2058);outline-offset:-4px;padding:8px%7D%20#WTFocusPanel.error:before%20%7Bbackground:darkred%7D%20#WTFocusPanel.warning:before%20%7Bbackground:#CC3300%7D%20#WTFocusPanel:before%20%7Bcontent:'';display:block;height:20px;width:20px;transform:rotate(45deg);position:absolute;background:#000;left:-12px;top:3px;border:2px%20solid%20#fff;border-right:none;border-top:none;%7D%20#WTFocusPanel.toBottom:before%20%7Btop:auto;bottom:3px%7D%20#WTFocusPanel.toLeft:before%20%7Bleft:auto;right:-12px;border:2px%20solid%20#fff;border-left:none;border-bottom:none;%7D%20#WTFocusPanel.curtainsMode%20%7Boutline:10px%20solid%20orange;%7D%20#WTFocusPanel.curtainsMode:before%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li.visible%20%7Bdisplay:block;%7D%20#WTFocusPanel.curtainsMode%20li%20span%20%7Bdisplay:none!important;%7D%20%22,document.querySelector(%22head%22).appendChild(r)%7D(Y),O.setAttribute(%22id%22,%22WTFocusCurtain%22),O.setAttribute(%22hidden%22,%22hidden%22),document.querySelector(%22body%22).appendChild(O),a.setAttribute(%22id%22,%22WTFocusPanel%22),L&&a.setAttribute(%22class%22,%22curtainsMode%22),a.setAttribute(%22aria-live%22,%22polite%22),a.setAttribute(%22tabindex%22,%22-1%22),a.setAttribute(%22hidden%22,%22hidden%22),a.setAttribute(%22role%22,%22region%22),a.setAttribute(%22aria-label%22,%22Accessibility%20properties%20panel%22),document.querySelector(%22body%22).appendChild(a),window.addEventListener(%22keyup%22,e=%3E%7Be.key===%22Escape%22&&document.querySelector(%22#WTFocusPanel%22)&&D()%7D),window.addEventListener(%22keyup%22,e=%3E%7Be.key.toLowerCase()===%22m%22&&document.querySelector(%22#WTFocusPanel%22)&&K()%7D),J();let%20U=%5B%5D;Array.from(H).forEach(function(e)%7Be.classList.add(%22WTFocusTempFocusStyle%22);let%20r=e.querySelectorAll(%22style%22);Array.from(r).forEach(function(o)%7Bo.remove()%7D),e.addEventListener(%22focus%22,()=%3E%7Blet%20o=e.getAttribute(%22role%22),n=e.tagName.toLowerCase();if(console.clear(),!o)%7Bif(n!=%22article%22&&n!=%22button%22&&n!=%22dialog%22&&n!=%22figure%22&&n!=%22img%22&&n!=%22main%22&&n!=%22math%22%7C%7C(o=n),n==%22summary%22&&(o=%22button%22),n==%22aside%22&&(o=%22complementary%22),n==%22dd%22&&(o=%22definition%22),n==%22html%22&&(o=%22document%22),n!=%22details%22&&n!=%22fieldset%22&&n!=%22optgroup%22%7C%7C(o=%22group%22),n!=%22menu%22&&n!=%22ol%22&&n!=%22ul%22%7C%7C(o=%22list%22),n==%22datalist%22&&(o=%22listbox%22),n==%22li%22&&(o=%22listitem%22),n==%22nav%22&&(o=%22navigation%22),n==%22progress%22&&(o=%22progressbar%22),n==%22hr%22&&(o=%22separator%22),n==%22output%22&&(o=%22status%22),n!=%22dfn%22&&n!=%22dt%22%7C%7C(o=%22term%22),n==%22a%22&&(o=%22link%22),n==%22select%22&&(o=%22listbox%22),n==%22textarea%22&&(o=%22textbox%22),n==%22input%22)%7Blet%20t=e.getAttribute(%22type%22).toLowerCase();t===%22text%22&&(o=%22textbox%22),t===%22range%22&&(o=%22slider%22),t===%22number%22&&(o=%22spinbutton%22),t!==%22checkbox%22&&t!==%22radio%22%7C%7C(o=t),t!==%22button%22&&t!==%22image%22&&t!==%22reset%22&&t!==%22submit%22%7C%7C(o=%22button%22)%7D%7Dz=e,Array.from(H).forEach(function(t)%7Bt.classList.remove(%22dupeAccName%22)%7D);let%20C=!1;m=!1,x=!1;let%20q=e.querySelectorAll(%22img,%20%5Brole='image'%5D%5Baria-label%5D,%20%5Brole='img'%5D%5Baria-label%5D%22);(C=q.length%3E0)&&Array.from(q).forEach(function(t)%7Blet%20d=document.createElement(%22SPAN%22);var%20T,B;d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22data-temp-node%22,%22true%22),t.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+t.getAttribute(%22alt%22)+%22%20%22),t.getAttribute(%22role%22)&&t.getAttribute(%22aria-label%22)&&(d.textContent=%22%20%22+t.getAttribute(%22aria-label%22)+%22%20%22),T=d,(B=t).parentNode.insertBefore(T,B.nextSibling)%7D),setTimeout(function()%7Be.classList.add(%22WTFocusTempFocusStyle%22)%7D,100),p=%22%22;let%20i=e.tagName.toLowerCase(),c=e.getAttribute(%22role%22);c&&(c=e.getAttribute(%22role%22).toLowerCase());let%20Z=%22%3C%22+i+%22%3E%22,_=!1,$=!1;c&&(Z=%22%3C%22+i+'%20role=%22'+c+'%22%3E',(c===%22link%22&&i===%22a%22%7C%7Cc===%22button%22&&i===%22button%22%7C%7Cc===%22image%22&&i===%22img%22%7C%7Cc===%22img%22&&i===%22img%22%7C%7Cc===%22navigation%22&&i===%22nav%22%7C%7Cc===%22heading%22&&(i===%22h1%22%7C%7Ci===%22h2%22%7C%7Ci===%22h3%22%7C%7Ci===%22h4%22%7C%7Ci===%22h5%22%7C%7Ci===%22h6%22))&&(_=!0),(c===%22link%22&&i!==%22a%22%7C%7Cc===%22button%22&&i!==%22button%22%7C%7C(c===%22image%22%7C%7Cc===%22image%22)&&i!==%22img%22%7C%7Cc===%22navigation%22&&i!==%22nav%22%7C%7Cc===%22heading%22&&i!==%22h1%22&&i!==%22h2%22&&i!==%22h3%22&&i!==%22h4%22&&i!==%22h5%22&&i!==%22h6%22)&&($=!0));let%20ee,b=e.textContent,f=e.ariaLabel,S=e.getAttribute(%22aria-labelledby%22),N=e.getAttribute(%22placeholder%22),F=%22%22,g=e.getAttribute(%22value%22),v=e.getAttribute(%22title%22),s=%22%22,y=%22%22,te=!1,oe=!1,u=%22%22,ne=!1;k&&Q(e),b=b.trim();let%20ae=function(t,d)%7Bfor(;(t=t.parentElement)&&!(t.matches%7C%7Ct.matchesSelector).call(t,d););return%20t%7D(e,%22label%22);if(ae&&(te=!0,s=y=ae.textContent.trim()),e.getAttribute(%22id%22))%7Blet%20t=document.querySelector(%22%5Bfor='%22+e.getAttribute(%22id%22)+%22'%5D%22);t&&(oe=!0,y=t.textContent)%7Dif(te%7C%7Coe%7C%7C(y=%22N/A%22),b%7C%7C(b=%22N/A%22),g%7C%7C(g=%22N/A%22),v%7C%7C(v=%22N/A%22),N%7C%7C(N=%22N/A%22),f%7C%7C(f=%22N/A%22),S)%7Blet%20t=(ee=S).split(%22%20%22);t.length%3E1?(Array.from(t).forEach(function(d)%7Bdocument.querySelector(%22#%22+d)?F+=document.querySelector(%22#%22+d).textContent+%22%20%22:F+=%22%5Cu2753%5Cu2753%5Cu2753%20%22%7D),F=F.trim()):F=document.querySelector(%22#%22+ee).textContent%7Delse%20S=%22N/A%22;let%20le=e.querySelectorAll(%22%5Baria-hidden='true'%5D,%5Brole='presentation'%5D%22),M=b;if(le.length%3E0&&(ne=!0,Array.from(le).forEach(function(t)%7Blet%20d=t.textContent;d!==%22%22&&(M=M.split(d).join(%22%20%22))%7D),M=M.trim()),i===%22input%22)%7Blet%20t=e.getAttribute(%22type%22);t===%22submit%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22image%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22cancel%22&&g===%22N/A%22&&(s=%22Cancel%22,u=%22Not%20provided%20(using%20default)%22)%7Dif(v!==%22N/A%22&&(s=v,u=%22title%20attribute%22),g!==%22N/A%22&&(s=g,u=%22value%20attribute%22),N!==%22N/A%22&&(s=N,u=%22placeholder%20attribute%22),b!==%22N/A%22&&(s=M,u=%22Inner%20text%20content%22),y!==%22N/A%22&&(s=y,u=%22%3Clabel%3E%20text%22),f!==%22N/A%22&&(s=f,u=%22aria-label%22),S!==%22N/A%22&&(s=F,u=%22aria-labelledby%22),console.log(%22%25cACTIVE%20ELEMENT:%20%22,%22background:#193c10;color:white;%22),console.log(e),I=e.getAttribute(%22data-dupe%22)===%22true%22,G=I&&s===%22%22,s===%22%22%7C%7CI)%7Bif(s===%22%22&&(x=!0,k&&a.classList.add(%22error%22),l(P+%22No%20accessible%20name!%22,%22%22,h),l(%22Accessible%20Name%20Source:%20N/A%22,%22%22,h)),I&&s!==%22%22)%7Bk&&a.classList.add(%22warning%22);let%20t=document.querySelectorAll(%22%5Bdata-accname='%22+s+%22'%5D%22),d=t.length;l(P,s,h,!1,!0),G%7C%7C(Array.from(t).forEach(function(T)%7BT.classList.add(%22dupeAccName%22)%7D),l(%22Duplicate%20warning!%22,d+%22%20elements%20on%20page%20have%20the%20same%20accessible%20name%22,h)),console.log(%22Elements%20on%20page%20that%20have%20identical%20accessible%20names:%22),Array.from(t).forEach(function(T)%7Bconsole.log(T)%7D),l(%22Accessible%20Name%20Source:%20%22,u,h)%7D%7Delse%20k&&(a.classList.remove(%22error%22),a.classList.remove(%22warning%22)),l(P,s,j,!1,!0),l(%22Accessible%20Name%20Source:%20%22,u,j);x=!1,l(%22HTML%20Element:%20%22,Z,j),l(%22Role:%20%22,o,%22color:#333;background:#fff;%22,!1,!0),k%7C%7Cconsole.log(%22%25cACCESSIBLE%20NAME%20COMES%20FROM:%20%22,%22background:#193c10;color:white;%22),_&&(x=!0,l(%22Superfluous%20%60role%60%20attribute%22,%22%22,h)),$&&(x=!0,l(%22Better%20to%20use%20a%20native%20HTML%20element%22,%22%22,h)),b=b.trim(),y=y.trim(),v=v.trim(),f=f.trim(),S=S.trim(),W(),u===%22placeholder%20attribute%22?(m=!0,l(%22@placeholder:%20%22,N,A,!0)):l(%22@placeholder:%20%22,N,N===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22title%20attribute%22?(m=!0,l(%22@title:%20%22,v,A,!0)):l(%22@title:%20%22,v,v===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22value%20attribute%22?(m=!0,l(%22@value:%20%22,g,A,!0)):l(%22@value:%20%22,g,g===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22Inner%20text%20content%22?(m=!0,l(C?%22Inner%20text%20content%20(includes%20image%20alt):%20%22:%22Inner%20text%20content:%20%22,b,A,!0),ne&&l(%22!%20elements%20hidden%20to%20AT%20removed%22,%22%22,A)):l(%22Text%20Content:%20%22,b,b===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22%3Clabel%3E%20text%22?(m=!0,l(%22Visible%20%60label%60%20text:%20%22,y,A,!0)):l(%22Visible%20%60label%60%20text:%20%22,y,y===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-label%22?f===b?(x=!0,l(%22%60aria-label%60%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-label%20value:%20%22,f,A,!0)):l(%22@aria-label%20value:%20%22,f,f===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-labelledby%22?F===b?(x=!0,l(%22%60aria-labelledby%60%20source%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-labelledby%20value:%20%22,S,A,!0),l(%22@aria-labelledby%20sources:%20%22,F,A)):(l(%22@aria-labelledby%20value:%20%22,S,%22color:#333;background:#fff;%22),l(%22@aria-labelledby%20sources:%20%22,%22N/A%22,%22color:#333;background:#fff;%22)),k&&(document.querySelector(%22#WTFocusPanel%22).innerHTML='%3Cul%20role=%22list%22%3E'+p+%22%3C/ul%3E%22,document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22hidden%22),J());let%20se=document.querySelectorAll(%22%5Bdata-temp-node%5D%22);Array.from(se).forEach(function(t)%7Bt.remove()%7D),e.setAttribute(%22data-accname%22,s),X%7C%7Cfunction(t,d)%7Blet%20T=!1;Array.from(U).forEach(function(B)%7BB===t&&(T=!0)%7D),T?(d.setAttribute(%22data-dupe%22,%22true%22),document.querySelector(%22%5Bdata-accname='%22+t+%22'%5D%22).setAttribute(%22data-dupe%22,%22true%22)):U.push(t)%7D(s,e)%7D)%7D);let%20X=!1;(function()%7Bif(V=document.activeElement,Array.from(H).forEach(function(e)%7Bdocument.activeElement===e&&e.blur(),e.focus()%7D),X=!0,V.tagName===%22BODY%22)%7Blet%20e=document.querySelector(%22body%22);e.setAttribute(%22tabindex%22,%22-1%22),e.focus(),document.querySelector(%22#WTFocusPanel%22).setAttribute(%22hidden%22,%22hidden%22)%7Delse%20V.focus();console.clear()%7D)(),console.log(%22had%20focus%20=%20%22,z)%7Dre()%7D)();%7D)();%0A" } ] \ No newline at end of file diff --git a/data/bookmarklets.json b/data/bookmarklets.json index 20f083c..c224a38 100644 --- a/data/bookmarklets.json +++ b/data/bookmarklets.json @@ -1,144 +1,143 @@ [ { + "file": "are-ya-hidden.js", "bookmarklet": "Are ya hidden?", "description": "Display hidden content", - "file": "are-ya-hidden.js", - "pageTest": true, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "accessibility" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20p=document.querySelectorAll(%22*%22);function%20u()%7BArray.from(p).forEach(t=%3E%7Bcs=getComputedStyle(t);for(var%20e=!1,s=!1,r=!1,l=!1,n=!1,c=!1,o=!1,d=!1,a=0;a%3Ccs.length;a++)cssProperty=cs%5Ba%5D,cssValue=cs.getPropertyValue(cssProperty),cssProperty===%22clip%22&&cssValue===%22rect(1px,%201px,%201px,%201px)%22&&(e=!0),cssProperty===%22clip-path%22&&cssValue===%22inset(100%25)%22&&(s=!0),cssProperty===%22height%22&&cssValue===%221px%22&&(r=!0),cssProperty===%22overflow-x%22&&cssValue===%22hidden%22&&(l=!0),cssProperty===%22overflow-y%22&&cssValue===%22hidden%22&&(n=!0),cssProperty===%22position%22&&cssValue===%22absolute%22&&(c=!0),cssProperty===%22white-space%22&&cssValue===%22nowrap%22&&(o=!0),cssProperty===%22width%22&&cssValue===%221px%22&&(d=!0);e===!0&&s===!0&&r===!0&&l===!0&&n===!0&&c===!0&&o===!0&&d===!0&&t.classList.add(%22was-visually-hidden%22),t.classList.forEach(h=%3E%7Bh.indexOf(%22-offscreen%22)!==-1&&t.classList.add(%22was-visually-hidden%22)%7D),(t.classList.contains(%22sr-only%22)%7C%7Ct.classList.contains(%22screenreader-only%22)%7C%7Ct.classList.contains(%22visually-hidden%22)%7C%7Ct.classList.contains(%22visuallyhidden%22))&&t.classList.add(%22was-visually-hidden%22)%7D)%7Dfunction%20i(t)%7Bu();var%20e,s=t.createElement(%22style%22);t.head.appendChild(s),(e=s.sheet).insertRule(%22%5Baria-hidden=true%5D%20%7Bbackground:black;color:black;%7D%22,0),e.insertRule(%22%5Baria-hidden=true%5D%20%5Baria-hidden=true%5D%20%7Bopacity:1%7D%22,0),e.insertRule(%22.was-visually-hidden%20%7Bclip-path:%20initial!important;clip:%20initial!important;height:%20auto!important;overflow:%20initial!important;position:%20initial!important;white-space:%20initial!important;width:%20auto!important;opacity:initial!important;z-index:initial!important;background:black!important;color:lime!important;%7D%22,0)%7Di(document);var%20y=document.querySelectorAll(%22iframe%22);Array.from(y).forEach(t=%3E%7Bi(t.contentWindow.document)%7D)%7D)();%7D)();%0A" }, { + "file": "auto-complete.js", "bookmarklet": "Autocomplete", "description": "Display all fields with autocomplete", - "file": "auto-complete.js", - "auditing": true, - "pageTest": true, "source": "Rachele DiTullio", "sourceUrl": "https://racheleditullio.com/blog/2023/11/autocomplete-accessibility-bookmarklet/", "tags": [ "1.3.5 Identify Input Purpose (AA)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20o=document.querySelectorAll(%22.autocomplete-info%22);if(o.length%3E0)o.forEach(t=%3E%7Bt.remove()%7D);else%7Blet%20t=document.querySelectorAll(%22input%5Bautocomplete%5D%22);t.length%3E0?t.forEach(l=%3E%7Blet%20i=l.getAttribute(%22autocomplete%22),n=l.getBoundingClientRect(),e=document.createElement(%22div%22);e.classList.add(%22autocomplete-info%22),e.style.position=%22absolute%22,e.style.top=window.scrollY+n.top+%22px%22,e.style.left=window.scrollX+n.left+%22px%22,e.style.backgroundColor=%22yellow%22,e.style.color=%22black%22,e.style.padding=%225px%22,e.style.border=%222px%20solid%20#000%22,e.style.zIndex=%229999%22,e.innerHTML=%60autocomplete=%3Cstrong%3E$%7Bi%7D%3C/strong%3E%60,document.body.appendChild(e)%7D):alert(%22No%20input%20fields%20with%20autocomplete%20attribute%20found%20on%20this%20page.%22)%7D%7D)();%7D)();%0A" }, { + "file": "background-images.js", "bookmarklet": "Background images", "description": "Highlight all CSS background images", - "file": "background-images.js", - "pageTest": true, "source": "Zoe Mickley Gillenwater", "sourceUrl": "https://zomigi.com/blog/bookmarklets-for-accessibility-testing/", "tags": [ "utility" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bfor(var%20n=document.getElementsByTagName(%22*%22),e,t=0;t%3Cn.length;t++)e=n%5Bt%5D,e.currentStyle?e.currentStyle.backgroundImage!==%22none%22&&(e.style.outline=%222px%20solid%20#f00%22):window.getComputedStyle&&document.defaultView.getComputedStyle(e,null).getPropertyValue(%22background-image%22)!==%22none%22&&(e.style.outline=%224px%20solid%20#f00%22)%7D)();%7D)();%0A" }, { + "file": "blur-page.js", "bookmarklet": "Blur page", "description": "Blur entire page", - "file": "blur-page.js", - "pageTest": false, "source": "Thomas Park", "sourceUrl": "https://thomaspark.co/2013/11/3-simple-design-bookmarklets-to-improve-your-aesthetics/", "tags": [ "diagnostic" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7Bdocument.body.setAttribute(%22style%22,'filter:url(%22data:image/svg+xml;utf8,%3Csvg%20xmlns=%22http://www.w3.org/2000/svg%22%3E%3Cfilter%20id=%22blur%22%3E%3CfeGaussianBlur%20stdDeviation=%2210%22%20/%3E%3C/filter%3E%3C/svg%3E#blur%22);%20-webkit-filter:blur(10px);%20filter:blur(10px);')%7D)();%7D)();%0A" }, { + "file": "buttons.js", "bookmarklet": "Buttons", "description": "Display all buttons", - "file": "buttons.js", - "auditing": true, - "pageTest": false, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "accessibility" ], + "auditing": true, + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20k()%7Bconsole.clear();function%20B(e,i)%7Bi.parentNode.insertBefore(e,i.nextSibling)%7Dfunction%20m(e)%7Blet%20i=window.getComputedStyle(e);return%20i.display===%22none%22%7C%7Ci.opacity===0%7C%7Ci.clipPath===%22inset(100%25)%22&&i.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ci.height===%221px%22&&i.width===%221px%22&&i.overflow===%22hidden%22%7Dfunction%20C(e)%7Blet%20i=window.getComputedStyle(e);i.position===%22absolute%22&&i.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),i.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),i.display===%22none%22&&(e.style.display=%22block%22),i.opacity===0&&(e.style.opacity=1)%7Dlet%20n=%22%22,r=%22%22,S=document.querySelectorAll(%22button,%5Brole=button%5D,input%5Btype=button%5D%22),c=1,g,y=0,f=%22%22,u=%22%22;Array.from(S).forEach(function(e)%7Blet%20i=document.createElement(%22div%22);i.appendChild(e.cloneNode(!0)),f=i.innerHTML;let%20b=!1,t=%22%22,w=e.querySelectorAll(%22img%22),o=!1,h=!1;b=w.length%3E0;let%20x=e.querySelector(%22%5Baria-hidden=true%5D%22);x&&x.classList.add(%22remove-from-accname%22),b&&Array.from(w).forEach(function(s)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),s.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+s.getAttribute(%22alt%22)+%22%20%22),B(d,s)%7D),e.setAttribute(%22data-button-ref%22,c);let%20l=e.textContent,A=e.querySelector(%22.remove-from-accname%22);A&&A.remove();let%20a=e.textContent;if(e.getAttribute(%22aria-label%22)&&(a=e.getAttribute(%22aria-label%22),t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-label%3C/code%3E.%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0,a.trim().toLowerCase().indexOf(l.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-label%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')),e.getAttribute(%22aria-labelledby%22))%7Blet%20s=e.getAttribute(%22aria-labelledby%22);s=s.replace(/:/g,%22%5C%5C:%22);let%20d=s.split(%22%20%22);d.length%3E1?(a=%22%22,Array.from(d).forEach(function(v)%7Bdocument.querySelector(%22#%22+v)?a+=document.querySelector(%22#%22+v).textContent+%22%20%22:a+=%22**%20aria-labelledby%20source%20is%20missing%20**%22%7D),a=a.trim(),t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0):(s=e.getAttribute(%22aria-labelledby%22),s=s.replace(/:/g,%22%5C%5C:%22),document.querySelector(%22#%22+s)?a=document.querySelector(%22#%22+s).textContent:a+=%22**%20aria-labelledby%20source%20is%20missing%20**%22,t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0),a.trim().toLowerCase().indexOf(l.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-labelledby%20sources%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')%7Dm(e)&&(C(e),m(e)?t+=%22Button%20is%20hidden%3Cbr%3E%22:t+=%22Button%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),b&&(t+=%22%5Cu%7B1F304%7D%20Image%20button%3Cbr%3E%22),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)!==l&&(t+=%22-%20button%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20different%20from%20text%20content.%22,a!==%22%22&&(t+='This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E'),t+=%22%3Cbr%3E%22,o=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)===l&&(t+='-%20button%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20the%20same%20as%20the%20text%20content%20and%20therefore%20adds%20no%20extra%20useful%20information/context.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E',o=!0),e.tagName===%22BUTTON%22&&(e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22Button%20has%20a%20%3Ccode%3Etabindex%3C/code%3E%20but%20it%20is%20not%20needed%20because%20the%20%3Ccode%3Ebutton%3C/code%3E%20is%20natively%20focusable%3Cbr%3E%22),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Button%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',o=!0),e.getAttribute(%22role%22)===%22button%22&&(t+=%22Button%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Not%20needed%20as%20it%20is%20a%20%3Ccode%3Ebutton%3C/code%3E%20element%20that%20is%20a%20button%20by%20default%3Cbr%3E%22),e.getAttribute(%22aria-hidden%22)!==%22true%22&&e.getAttribute(%22tabindex%22)===%22-1%22&&(t+=%22-%20%3Ccode%3E<button>%3C/code%3E%20has%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%20which%20means%20it%20will%20not%20be%20keyboard-operable%3Cbr%3E%22,o=!0),e.getAttribute(%22aria-hidden%22)===%22true%22&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+='-%20%3Ccode%3E<button>%3C/code%3E%20has%20%3Ccode%3Earia-hidden=%22true%22%3C/code%3E%20but%20can%20still%20be%20focused%20by%20keyboard%20user%20as%20it%20does%20not%20have%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E',o=!0),e.getAttribute(%22role%22)&&e.getAttribute(%22role%22)!==%22button%22&&(t+='-%20%3Ccode%3E<button>%3C/code%3E%20has%20a%20%3Ccode%3Erole%3C/code%3E%20set%20that%20is%20not%20%3Ccode%3Ebutton%3C/code%3E.%20It%20is%20set%20to%20%22'+e.getAttribute(%22role%22)+'%22.%20This%20overrides%20the%20native%20role%20and%20will%20likely%20confused%20assistive%20tech%20users%3Cbr%3E',o=!0)),e.tagName===%22A%22&&(!e.getAttribute(%22href%22)&&!e.getAttribute(%22tabindex%22)&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E%20element,%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E%20or%20%3Ccode%3Etabindex%3C/code%3E,%20%20and%20therefore%20is%20not%20focusable%3Cbr%3E%22,o=!0),!e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E%20element,%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20but%20is%20focusable%20because%20it%20has%20been%20provided%20with%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E%22,o=!0),e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E.%20It%20is%20focusable%20because%20there%20is%20a%20%3Ccode%3Etabindex%3C/code%3E%20present%3Cbr%3E%22,o=!0),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Button%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',o=!0)),e.tagName!==%22BUTTON%22&&e.tagName!==%22A%22&&e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E%20but%20is%20not%20a%20%3Ccode%3Ebutton%3C/code%3E%20element.%22,e.getAttribute(%22tabindex%22)===%22-1%22?t+=%22%3Cbr%3E-%20%3Cstrong%3ENote%3C/strong%3E:%20this%20button%20has%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%20and%20will%20not%20be%20keyboard-focusable.%22:t+=%22Check%20that%20it%20is%20keyboard-operable%20(should%20activate%20with%20%3Ckbd%3EEnter%3C/kbd%3E%20and%20%3Ckbd%3ESpace%3C/kbd%3E%20key)%3Cbr%3E%22,o=!0),a===%22%22?(e.getAttribute(%22title%22)?a=e.getAttribute(%22title%22):a=%22%5Cu203C%5CuFE0F%20Empty%20button%22,l=%22%5Cu203C%5CuFE0F%20Empty%20button%22,t+=%22%5Cu203C%5CuFE0F%20Empty%20button%3Cbr%3E%22,h=!0):l.trim()===%22%22&&(l=%22%5Cu203C%5CuFE0F%20No%20visible%20text%20on%20button%22),b&&a===%22%5Cu203C%5CuFE0F%20Empty%20button%22&&(t+=%22%20-%20image%20is%20missing%20alternative%20text%20content%3Cbr%3E%22),h&&(o=!1),r+=%22%3Ctr%22,r+='%20data-button-ref=%22'+c+'%22',o&&(r+='%20class=%22issue%20warn%22'),h&&(r+='%20class=%22issue%20err%22'),r+=%22%3E%22,e.tagName===%22BUTTON%22?g=%22%3Ccode%3E<button>%3C/code%3E%22:g='%3Ccode%3Erole=%22button%22%3C/code%3E',r+=%22%3Ctd%3E%22+g+%22%3C/td%3E%22,r+=%22%3Ctd%3E%22+l+%22%3C/td%3E%22,r+=%22%3Ctd%3E%22+a,a.trim()!==l.trim()&&l.trim()!==%22%22&&(r+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),r+=%22%3C/td%3E%22,r+=%22%3Ctd%3E%22,o&&(r+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20button%3C/div%3E'),h&&(r+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20button%3C/div%3E'),u=%22Button%20'%22+l.trim()+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+f+%60%0A---------------%0A%60,r+=t+'%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+c+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+c+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+f+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',r+='%3Ctd%3E%3Cbutton%20data-button-ref=%22'+c+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',r+=%22%3C/tr%3E%22,c++,(o%7C%7Ch)&&y++,h&&(u=u.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(u))%7D),n='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkgreen;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:button,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20buttons%20on%20this%20page.%3C/h1%3E',n+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20buttons%20where%20there%20*may*%20be%20issues%20('+y+%22%20found)%3C/label%3E%22,n+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20buttons%20on%20page%3C/button%3E',n+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20buttons%20(<button>%20or%20elements%20with%20role=%22button%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3EButton%20type%3C/th%3E%3Cth%20scope=%22col%22%3EButton%20text%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+r+%22%3C/tbody%3E%3C/table%3E%22,n+=%22%3Cscript%3Efunction%20showbtns()%7B%22,n+=%22var%20refWindow=window.opener;%22,n+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20buttonToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BbuttonToHighlight=%22%5Bdata-button-ref='%22%20+%20highlightButton.getAttribute(%22data-button-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(buttonToHighlight).focus();refWindow.document.querySelector(buttonToHighlight).style.outline=%224px%20dashed%20darkgreen%22;refWindow.document.querySelector(buttonToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(buttonToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,n+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',n+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',n+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7Bshowbtns();%7D);%3C%5C/script%3E';let%20p=window.open(%22%22,%22popUpWinButtons%22,%22height=800,width=1000%22);p.document.open(),p.document.write(n),p.document.close()%7Dk()%7D)();%7D)();%0A" }, { + "file": "character-keys.js", "bookmarklet": "Character key shortcuts", "description": "Test all printable character shortcut keys", - "file": "character-keys.js", - "pageTest": true, - "auditing": true, "source": "Detlev Fischer", "sourceUrl": "http://3needs.org/en/testing/code/kb-shortcuts.html", "tags": [ "2.1.4 Character Key Shortcuts (A)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e,t=32,o=8365;n();function%20n()%7Bconsole.log(%22pressed:%20%22+t+%22:%20%22+String.fromCharCode(t)),e=document.createEvent(%22Event%22),e.initEvent(%22keydown%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),e=document.createEvent(%22Event%22),e.initEvent(%22keypress%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),e=document.createEvent(%22Event%22),e.initEvent(%22keyup%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),t++,t%3Co&&(t==127&&(t=161),t==192&&(t=8364),window.setTimeout(n,20))%7D%7D)();%7D)();%0A" }, { + "file": "color-scheme.js", "bookmarklet": "Toggle color scheme", "description": "Switch between light and dark color scheme", - "file": "color-scheme.js", - "pageTest": "self", "source": "Thomas Orlita", "sourceUrl": "https://github.com/ThomasOrlita/awesome-bookmarklets#dark-color-scheme", "tags": [ "css" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bdocument.documentElement.style.colorScheme=document.documentElement.style.colorScheme==%22dark%22?%22light%22:%22dark%22;%7D)();%0A" }, { + "file": "complex-table.js", "bookmarklet": "Complex table", "description": "Visualize headers and IDs in a complex table", - "file": "complex-table.js", - "pageTest": true, "source": "Jonathan Avila", "sourceUrl": "https://labs.levelaccess.com/index.php/Complex_Tables_Favlet", "tags": [ "accessibility" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e=document.querySelectorAll(%22td,%20th%22),n,t=%5B%5D,d;if(e.length%3E0)%7Bfor(var%20l=0;l%3Ce.length;l++)%7Bif(e.item(l).hasAttribute(%22headers%22))%7Bn=e.item(l).getAttribute(%22headers%22),t=n.split(%22%20%22);for(var%20r=0;r%3Ct.length;r++)if(document.getElementById(t%5Br%5D))%7Bd=1;var%20a=document.createElement(%22Span%22),o=document.createTextNode(document.getElementById(t%5Br%5D).textContent+%22%20%22);a.appendChild(o),a.style.backgroundColor=%22antiqueWhite%22,a.style.color=%22black%22,e.item(l).appendChild(a)%7D%7Dn=%22%22,t=%22%22,o=%22%22%7Dd%7C%7Calert(%22no%20valid%20headers%20found%22)%7Delse%20alert(%22No%20table%20cells%20found%22)%7D)();%7D)();%0A" }, { + "file": "cursor-24x24.js", "bookmarklet": "Cursor 24x24", "description": "Change cursor to 24px by 24px circle", - "file": "cursor-24x24.js", - "pageTest": "self", "source": "Adrian Roselli", "sourceUrl": "https://adrianroselli.com/2022/05/24x24-pixel-cursor-bookmarklet.html#Update01", "tags": [ "2.5.8 Target Size (Minimum) (2.2 AA)" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20o=document,c=%22AAR24pxBkmklt1%22,l=o.getElementById(c),r=o.querySelectorAll(%22iframe%22),A=0,a=r.length,d;if(l)%7Blet%20e=function(t)%7Bfor(var%20n%20of%20t.querySelectorAll(%22*%22))n.shadowRoot&&(n.shadowRoot.getElementById(c).remove(),e(n.shadowRoot))%7D;var%20i=e;if(l.remove(),a)for(A=0;A%3Ca;A++)try%7Br%5BA%5D.contentWindow.document.getElementById(c).remove(),e(r%5BA%5D.contentWindow.document)%7Dcatch(t)%7Bconsole.log(t)%7De(o)%7Delse%7Blet%20e=function(t)%7Bfor(var%20n%20of%20t.querySelectorAll(%22*%22))n.shadowRoot&&(n.shadowRoot.appendChild(d.cloneNode(!0)),e(n.shadowRoot))%7D;var%20m=e;for(d=o.createElement(%22style%22),d.id=c,d.appendChild(o.createTextNode(%22*%7B%20cursor:%20url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAS1BMVEUAAAAAAAD+/v4AAABRUVE/Pz/u7u74+Pi6urrS0tJ8fHwAAAAAAAD///////8AAAD///////8AAAAAAAD////////////+/v7////mqvA4AAAAGHRSTlMA/vq59/Tx7+3p5uXV0L+okoFrZE1DFvCfRm9hAAAAnElEQVQoz3WSWRKEIAxEQ9hXURa5/0lnxpHS0kp/kX5AIAmcKtyzrzwvcNcWhFE4Biojwnb5i7QYc+295ohWLtPnTqc2g5a04+d+t69w07q748wm9fQn0fKXJ9gEDyUbAIrA9gQNRQFu4owZm6toOHiV3yArDwzrG1RkwEb/u4dO1gcNyKvI5ORzyQ9SJSGLSJWdbBTdWnoYyPH5AN6eCUUIphirAAAAAElFTkSuQmCC)%2012%2012,%20auto%20!important%7D%22)),o.getElementsByTagName(%22head%22)%5B0%5D.appendChild(d),A=0;A%3Ca;A++)try%7Br%5BA%5D.contentWindow.document.getElementsByTagName(%22head%22)%5B0%5D.appendChild(d.cloneNode(!0)),e(r%5BA%5D.contentWindow.document)%7Dcatch(t)%7Bconsole.log(t)%7De(o)%7D%7D)();%7D)();%0A" }, { + "file": "cursor-44x44.js", "bookmarklet": "Cursor 44x44", "description": "Change cursor to 44px by 44px square", - "file": "cursor-44x44.js", - "pageTest": "self", "source": "Adrian Roselli", "sourceUrl": "https://adrianroselli.com/2019/06/target-size-and-2-5-5.html#Update04", "tags": [ "2.5.5 Target Size (AAA)" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document.createElement(%22style%22),n=document.createTextNode(%22*%20%7B%20cursor:%20url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACwAAAAsCAYAAAAehFoBAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJBJREFUeNrs2dEKgDAIhWEN3/+VLYtBF12MppHwDxY0uvg4DJpORcSl0bB4uPcwq+oFHu8/956pbtJsAAYMGDBgwIABA044t3pMEgb8VU2XsWdn1o/aUUn4bchPBWNFYWvVidxbCFGmr7YULBs1YDPfsYcXEi9ryvDjAAwYMGDAgAED7nK8bHG7qNLs6nYXYAAheh5j8Qw5fwAAAABJRU5ErkJggg==)%2022%2022,%20auto%20!important%7D%22);t.appendChild(n);var%20a=document.getElementsByTagName(%22head%22);a%5B0%5D.appendChild(t),document.onkeydown=function(e)%7Bvar%20A;(%22key%22in(e=e%7C%7Cwindow.event)?e.key==%22Escape%22%7C%7Ce.key==%22Esc%22:e.keyCode==27)&&(A=document.createElement(%22style%22),document.head.appendChild(A),A.sheet.insertRule(%22*%7Bcursor:revert%20!important%7D%22,0))%7D%7D)();%7D)();%0A" }, { + "file": "design-mode-toggle.js", "bookmarklet": "Design mode toggle", "description": "Make all of the text on page editable", - "file": "design-mode-toggle.js", - "pageTest": false, "source": "Christoph Wagner", "sourceUrl": "https://developer.mozilla.org/en-US/docs/Web/API/SecurityPolicyViolationEvent#examples", "tags": [ "diagnostic" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7Bdocument.designMode=document.designMode==%22on%22?%22off%22:%22on%22;%7D)();%0A" }, { + "file": "disable-css.js", "bookmarklet": "Disable CSS", "description": "Drop all page styles", - "file": "disable-css.js", - "pageTest": false, "source": "Sarah Higley", "sourceUrl": "https://dorward.uk/software/disablecss/", "tags": [ @@ -146,76 +145,77 @@ "accessibility", "css" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7Bfor(e=0;e%3Cdocument.styleSheets.length;e++)document.styleSheets.item(e).disabled=!0;var%20e,t=document.getElementsByTagName(%22*%22);for(e=0;e%3Ct.length;e++)t%5Be%5D.style.cssText=%22%22;%7D)();%0A" }, { + "file": "duplicate-ids.js", "bookmarklet": "Duplicate IDs", "description": "Display duplicated ID values", - "file": "duplicate-ids.js", - "pageTest": true, "source": "Jonathan Avila", "sourceUrl": "https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/duplicateIds.js", "tags": [ "accessibility" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7Bfunction%20u()%7Bvar%20t=document.cloneNode(!0),l=t.querySelectorAll(%22%5Bid%5D%22),e=%5B%5D;c(l,e);var%20n=e.length+%60%20elements%20with%20duplicate%20ids%0A%60;e.forEach(function(r)%7Br.innerHTML=%22%22,n=n+r.outerHTML+%60%0A%60%7D),alert(n)%7Dfunction%20c(t,l)%7Bt.forEach(function(e)%7Bvar%20n=document.querySelectorAll('%5Bid=%22'+e.id+'%22%5D');n.length%3E1&&l.push(e)%7D)%7Du();%7D)();%0A" }, { + "file": "find-duplicate-aria-roles.js", "bookmarklet": "Find Duplicate ARIA Roles", "description": "Roles appearing more than once for banner, contentinfo, and main", - "file": "find-duplicate-aria-roles.js", - "pageTest": true, - "auditing": true, "source": "Adrian Roselli", "sourceUrl": "https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#ARIAdupes", "tags": [ "accessibility", "HTML" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e=document.createElement(%22style%22),n;document.head.appendChild(e),n=e.sheet,n.insertRule(%22*%5Brole=main%5D:nth-of-type(n+2),*%5Brole=banner%5D:nth-of-type(n+2),*%5Brole=contentinfo%5D:nth-of-type(n+2),main:nth-of-type(n+2)%7Bborder:2px%20dotted%20#f00%20!important;background-color:#f00;%7D%22,0)%7D)();%7D)();%0A" }, { + "file": "focus-everything.js", "bookmarklet": "Focus everything", "description": "A technique for testing 1.3.2 Meaningful Sequence a tab path visualizer", - "file": "focus-everything.js", - "pageTest": true, - "auditing": true, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "1.3.2 Meaningful Sequence (A)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7Bdocument.querySelectorAll(%22body%20*%22).forEach(function(t)%7Bt.setAttribute(%22tabindex%22,%220%22)%7D);%7D)();%0A" }, { + "file": "force-focus.js", "bookmarklet": "Force focus indicator", "description": "Adds a 4 pixel solid orange outline around all focusable elements", - "file": "force-focus.js", - "pageTest": false, - "auditing": true, "source": "Paul J. Adam", "sourceUrl": "https://pauljadam.com/bookmarklets/focus.html", "tags": [ "accessibility" ], + "auditing": true, + "pageTest": false, "dist": "javascript:void%20(()=%3E%7Bvar%20e=document.createElement(%22style%22),t=document.createTextNode(%22a:focus,%20*:focus%20%7B%20outline:%204px%20solid%20orange%20!important;%20outline-offset:1px%20!important;%20%7D%22),n=document.getElementsByTagName(%22head%22);e.appendChild(t);n%5B0%5D.appendChild(e);%7D)();%0A" }, { + "file": "grayscale.js", "bookmarklet": "Grayscale", "description": "Show entire page in gray scale (no color)", - "file": "grayscale.js", - "pageTest": false, "source": "Level Access", "sourceUrl": "https://labs.levelaccess.com/index.php/Grayscale_Favlet", "tags": [ "accessibility" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20e=document.createElement(%22style%22);e.type=%22text/css%22,e.appendChild(document.createTextNode(%22%22)),document.head.appendChild(e),e.sheet.insertRule(%22html%20%7B%20%20filter:%20grayscale(100%25)%20!important;%20-webkit-filter:%20grayscale(1)%20!important;%7D%22,e.sheet.cssRules.length)%7D)();%7D)();%0A" }, { + "file": "grouped-fields.js", "bookmarklet": "Grouped fields", "description": "Display grouped fields", - "file": "grouped-fields.js", "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ @@ -224,37 +224,36 @@ "dist": "javascript:void%20(()=%3E%7B(function()%7Bfunction%20b()%7Blet%20r=%22#662e2e%22,i=0;function%20a(e,l)%7Be.style.boxShadow=%220px%200px%200px%2010px%20white%22,e.style.outline=%225px%20solid%20%22+l,e.style.outlineOffset=%225px%22,i++%7Dfunction%20n(e,l,t)%7Blet%20o=document.createElement(%22span%22);o.innerHTML=l,o.style.display=%22inline-block%22,o.style.margin=%2220px%200%205px%20-10px%22,o.style.padding=%225px%22,o.style.background=t,o.style.fontWeight=%22bold%22,o.style.fontSize=%2218px%22,o.style.color=%22white%22,o.classList.add(%22group-description%22),e.parentNode.insertBefore(o,e)%7Dvar%20d,u=document.querySelectorAll(%22fieldset%22);console.log(u),Array.from(u).forEach(e=%3E%7Bconsole.log(e),a(e,r),e.querySelector(%22legend%22)&&n(e,'Group%20label%20(from%20fieldset%20%3E%20legend):%20%3Cbr%3E%3Cbr%3E%22'+e.querySelector(%22legend%22).textContent+'%22',r)%7D),r=%22#66482e%22,Array.from(document.querySelectorAll(%22%5Brole=group%5D%5Baria-label%5D,%5Brole=region%5D%5Baria-label%5D%22)).forEach(e=%3E%7Bconsole.log(e);let%20l=e.getAttribute(%22role%22).toLowerCase();a(e,r),n(e,%22Group%20label%20(from%20%5Brole=%22+l+'%5D%5Baria-label%5D):%20%3Cbr%3E%3Cbr%3E%22'+e.getAttribute(%22aria-label%22)+'%22',r)%7D),r=%22#662e43%22,Array.from(document.querySelectorAll(%22%5Brole=group%5D%5Baria-labelledby%5D,%5Brole=region%5D%5Baria-labelledby%5D%22)).forEach(e=%3E%7Bconsole.log(e);let%20l=e.getAttribute(%22role%22).toLowerCase();a(e,r);let%20t=%22Source%20for%20aria-labelledby%20is%20missing/broken%22;document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22))&&(t=document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22)).textContent),n(e,%22Group%20label%20(from%20%5Brole=%22+l+'%5D%5Baria-labelledby%5D):%20%3Cbr%3E%3Cbr%3E%22'+t+'%22',r)%7D),i===0&&alert(%22No%20grouped%20fields%20found%20on%20this%20page%22)%7Db()%7D)();%7D)();%0A" }, { + "file": "headings-console.js", "bookmarklet": "Document outline in console", "description": "Display level of all page headings in console", - "file": "headings-console.js", - "auditing": true, - "pageTest": "self", "source": "Mu-An Chiou", "sourceUrl": "https://github.com/muan/headings", "tags": [ "accessibility" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bvar%20a=%22%22;for(let%20t%20of%20document.querySelectorAll(%22h1,%20h2,%20h3,%20h4,%20h5,%20h6%22))%7Blet%20e=r(t);if(i(t)&&(t.offsetHeight%3E0%7C%7Ct.offsetWidth)&&e)%7Blet%20n=parseInt(t.tagName.match(/%5Cd/)%5B0%5D);a+=new%20Array((n-1)*2).fill(%22-%22).join(%22%22)+t.tagName.toLowerCase()+%22:%20%22+e+%60%0A%60%7D%7Dconsole.log(a);function%20r(t)%7Blet%20e=t.getAttribute(%22aria-labelledby%22);return(t.getAttribute(%22alt%22)%7C%7Ct.getAttribute(%22aria-label%22)%7C%7Ce&&o(document.getElementById(e))%7C%7Co(t)).trim()%7Dfunction%20o(t)%7Blet%20e=%22%22;for(let%20n%20of%20t.childNodes)e+=n%20instanceof%20HTMLElement?r(n):n.textContent%7C%7C%22%22;return%20e%7Dfunction%20i(t)%7Breturn!t.closest('%5Baria-hidden=%22%22%5D,%20%5Baria-hidden=%22true%22%5D')%7D%7D)();%0A" }, { + "file": "headings.js", "bookmarklet": "Headings", "description": "Display level of all page headings", - "file": "headings.js", - "auditing": true, - "pageTest": "self", "source": "Jonathan Avila", "sourceUrl": "https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/headings.js", "tags": [ "1.3.1 Info and Relationships (A)", "2.4.6 Headings and Labels (AA)" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bfunction%20n(o)%7Bs(o);for(var%20a=%5B%22frame%22,%22iframe%22%5D,e=0;e%3Ca.length;e++)for(var%20r=o.getElementsByTagName(a%5Be%5D),l=0;l%3Cr.length;l++)try%7Bn(r%5Bl%5D.contentWindow.document)%7Dcatch%7B%7D%7Dfunction%20s(o)%7Bfor(var%20a=o.querySelectorAll(%22h1,h2,h3,h4,h5,h6,%5Brole='heading'%5D%22),e=0;e%3Ca.length;e++)%7Bvar%20r=a%5Be%5D.tagName+%22%20%22;a%5Be%5D.hasAttribute(%22role%22)&&(r=r+%22role=%22+a%5Be%5D.getAttribute(%22role%22)+%22%20%22),a%5Be%5D.hasAttribute(%22aria-level%22)&&(r=r+%22aria-level=%22+a%5Be%5D.getAttribute(%22aria-level%22));var%20l=document.createTextNode(r),t=document.createElement(%22span%22);t.style.color=%22black%22,t.style.backgroundColor=%22gold%22,t.style.fontSize=%22small%22,t.style.border=%22thin%20solid%20black%22,t.style.position=%22absolute%22,t.appendChild(l),a%5Be%5D.parentNode.insertBefore(t,a%5Be%5D),a%5Be%5D.style.border=%22thin%20solid%20magenta%22%7D%7Dn(document);%7D)();%0A" }, { + "file": "hide-cursor.js", "bookmarklet": "Hide cursor", "description": "Hides cursor from window to encourage keyboard use", - "file": "hide-cursor.js", - "pageTest": false, "source": "Iain Bean", "sourceUrl": "https://iainbean.com/posts/2020/an-opinionated-guide-to-accessibility-testing/", "tags": [ @@ -266,38 +265,38 @@ "WCAG", "cursor" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7Bvar%20e=document.createElement(%22style%22),t=document.createTextNode('*%20%7B%20cursor:%20none%20!important;%20%7D%20body::after%7B%20position:%20absolute;%20top:%200;%20right:%204px;%20background-color:%20#000;%20color:%20#01ff70;%20z-index:%209999;%20font-size:%2016px;%20font-weight:%20400;%20padding:%203px%209px;%20outline:%204px%20solid%20#01ff70%20!important;%20content:%20%22hiding%20cursor%22;%7D'),o=document.getElementsByTagName(%22head%22);e.appendChild(t);o%5B0%5D.appendChild(e);%7D)();%0A" }, { + "file": "horizontal-scroll.js", "bookmarklet": "Horizontal scroll", "description": "Alert when a horizontal scrollbar appears", - "file": "horizontal-scroll.js", - "auditing": true, - "pageTest": true, - "source": " Jason Morris", + "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "accessibility" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20e=document.documentElement.clientWidth,o=!1;function%20n()%7Blet%20t=document.documentElement.clientWidth,i=document.body.scrollWidth%3Edocument.documentElement.clientWidth;i&&!o&&t%3Ce?(console.log(%60%25cHorizontal%20scrollbar%20detected!%25c%0AWindow%20width:%20%60+t+%60px%0AContent%20width:%20%60+document.body.scrollWidth+%60px%0AOverflow:%20%60+(document.body.scrollWidth-t)+%22px%22,%22color:%20#ff0000;%20font-size:%2014px;%20font-weight:%20bold;%22,%22color:%20inherit;%20font-size:%20inherit;%22),o=!0):i%7C%7C(o=!1),e=t%7Dwindow.addEventListener(%22resize%22,n),n(),console.log(%60%25cHorizontal%20scrollbar%20detector%20activated!%25c%0AResize%20the%20window%20to%20test.%60,%22color:%20#4CAF50;%20font-size:%2014px;%20font-weight:%20bold;%22,%22color:%20inherit;%20font-size:%20inherit;%22)%7D)();%7D)();%0A" }, { + "file": "html-link.js", "bookmarklet": "HTML link", "description": "Copy page title and URL in an HTML anchor", - "file": "html-link.js", - "pageTest": "self", "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "utility" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bvar%20t='%3Ca%20href=%22'+location.href+'%22%3E'+document.title+%22%3C/a%3E%22;window.prompt(%22HTML%20link:%22,t);%7D)();%0A" }, { + "file": "image-info.js", "bookmarklet": "Image info", "description": "Display image alt, role, title, aria-label, aria-labelledby", - "file": "image-info.js", - "pageTest": "true", "source": "Jonathan Avila", "sourceUrl": "https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/images.js", "tags": [ @@ -305,14 +304,13 @@ "1.4.5 Images of Text (A)", "2.4.4 Link Purpose (In Context) (A)" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7Bfunction%20b(l,e)%7Bd(l,e);for(var%20t=%5B%22frame%22,%22iframe%22%5D,o=0;o%3Ct.length;o++)for(var%20u=l.getElementsByTagName(t%5Bo%5D),i=0;i%3Cu.length;i++)try%7Bb(u%5Bi%5D.contentWindow.document,e)%7Dcatch%7Be.extFrameSrcList=e.extFrameSrcList+%60%0A%60+u%5Bi%5D.src,e.frameErrorCount=e.frameErrorCount+1%7Dreturn%20e%7Dfunction%20d(l,e)%7Bvar%20t=l.querySelectorAll(%22img,*%5Brole='image'%5D%22);e.foundCount=e.foundCount+t.length;var%20o,u=%5B%5D,i,n,a;if(t.length%3E0)for(var%20r=0;r%3Ct.length;r++)n=l.createElement(%22span%22),t.item(r).getAttribute(%22alt%22)?a='alt=%22'+t.item(r).getAttribute(%22alt%22)+'%22%20':t.item(r).hasAttribute(%22alt%22)?a='alt=%22%22%20':a=%22NO%20alt%20attribute!%20%22,t.item(r).getAttribute(%22title%22)&&(a=a+'title=%22'+t.item(r).getAttribute(%22title%22)+'%22%20'),t.item(r).getAttribute(%22aria-label%22)&&(a=a+'aria-label=%22'+t.item(r).getAttribute(%22aria-label%22)+'%22%20'),t.item(r).getAttribute(%22aria-labelledby%22)&&(a=a+'aria-labelledby=%22'+t.item(r).getAttribute(%22aria-labelledby%22)+'%22%20%5Cu2192%20'+l.getElementById(t.item(r).getAttribute(%22aria-labelledby%22)).innerHTML),n.appendChild(l.createTextNode(a)),n.style.backgroundColor=%22cyan%22,n.style.border=%22thin%20solid%20black%22,n.style.color=%22black%22,n.style.fontSize=%22small%22,n.zIndex=%2299999%22,t.item(r).style.border=%22thin%20dotted%20cyan%22,t.item(r).parentNode.insertBefore(n,t.item(r))%7Dfunction%20m(l)%7Bvar%20e=%5B%5D;e.foundCount=0,e.extFrameSrcList=%22%22,e.frameErrorCount=0,e=b(l,e),alert(e.foundCount+%22%20element(s)%20with%20alt,%20title,%20aria-label,%20aria-labelledby%20attributes%20found.%20%22)%7Dm(document);%7D)();%0A" }, { + "file": "images.js", "bookmarklet": "Images", "description": "Display all images", - "file": "images.js", - "pageTest": true, - "auditing": true, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ @@ -320,190 +318,191 @@ "1.4.5 Images of Text (A)", "2.4.4 Link Purpose (In Context) (A)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20f(e)%7Blet%20r=window.getComputedStyle(e);return%20r.display===%22none%22%7C%7Cr.opacity===0%7C%7Cr.clipPath===%22inset(100%25)%22&&r.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Cr.height===%221px%22&&r.width===%221px%22&&r.overflow===%22hidden%22%7Dfunction%20T(e)%7Blet%20r=window.getComputedStyle(e);r.position===%22absolute%22&&r.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),r.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),r.display===%22none%22&&(e.style.display=%22block%22),r.opacity===0&&(e.style.opacity=1)%7Dlet%20l=%22%22,o=%22%22,k=document.querySelectorAll(%22img,%5Brole=img%5D%22),d=1,u,m=0,b=%22%22,c=%22%22;Array.from(k).forEach(function(e)%7Blet%20r=document.createElement(%22div%22);r.appendChild(e.cloneNode(!0)),b=r.innerHTML;let%20t=%22%22,p=!1,y=!1,a=!1,n=!1,w=e.querySelector(%22%5Baria-hidden=true%5D%22);w&&w.classList.add(%22remove-from-accname%22),e.setAttribute(%22data-img-ref%22,d);let%20i=e.getAttribute(%22alt%22);i===null?(i=%22NO_ALT_ATTRIBUTE%22,p=!0):i===%22%22&&(i=%22EMPTY_ALT_ATTRIBUTE%22,y=!0);let%20s=i,A=e.getAttribute(%22src%22);if(f(e)&&(T(e),f(e)?t+=%22img%20is%20hidden.%3Cbr%3E%22:t+=%22img%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page.%3Cbr%3E%22),p&&(e.getAttribute(%22role%22)===%22img%22&&e.tagName!==%22IMG%22%7C%7C(t=%22-%20img%20has%20no%20%3Ccode%3Ealt%3C/code%3E%20attribute.%3Cbr%3E%22,n=!0)),y&&(t=%22-%20img%20has%20an%20empty%20%3Ccode%3Ealt%3C/code%3E%20attribute.%20This%20will%20hide%20it%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),(e.getAttribute(%22role%22)===%22presentation%22%7C%7Ce.getAttribute(%22role%22)===%22none%22)&&(t+=%22-%20img%20has%20a%20%3Ccode%3Erole%3C/code%3E%20set%20('%22+e.getAttribute(%22role%22)+%22')%20that%20will%20hide%20it%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),e.getAttribute(%22aria-hidden%22)===%22true%22&&(t+=%22-%20img%20has%20an%20%3Ccode%3Earia-hidden=true%3C/code%3E,%20so%20it%20will%20be%20hidden%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),e.getAttribute(%22title%22)&&(i===%22EMPTY_ALT_ATTRIBUTE%22?(t+=%22-%20img%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20AND%20an%20empty%20%3Ccode%3Ealt%3C/code%3E%20attribute.%20Because%20of%20the%20empty%20alt,%20the%20image%20will%20be%20hidden%20to%20AT,%20so%20the%20title%20attribute%20is%20not%20used/exposed.%3Cbr%3E%22,a=!1,n=!0):(t+='-%20img%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20attribute.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users.%3Cbr%3E',p?n=!0:a=!0)),e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20img%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Check%20that%20it%20behaves%20like%20a%20%3Ccode%3Ebutton%3C/code%3E.%3Cbr%3E%22,a=!0),e.getAttribute(%22role%22)===%22img%22&&(t+=%22-%20Not%20an%20inline%20img,%20so%20no%20%3Ccode%3Ealt%3C/code%3E%20attribute.%3Cbr%3E%22),e.getAttribute(%22role%22)===%22img%22&&e.getAttribute(%22alt%22)!==null&&e.tagName!==%22IMG%22&&(t+=%22-%20Background%20image%20has%20an%20%3Ccode%3Ealt%3C/code%3E%20attribute%20specified,%20but%20cannot%20be%20applied%20to%20this%20element;%20can%20only%20be%20applied%20to%20%3Ccode%3Eimg%3C/code%3E%20element.%3Cbr%3E%22,a=!1,n=!0),e.tagName!==%22IMG%22&&e.getAttribute(%22role%22)===%22img%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Eimg%3C/code%3E%20but%20is%20not%20an%20%3Ccode%3Eimg%3C/code%3E%20element.%3Cbr%3E%22),e.getAttribute(%22role%22)===%22img%22)%7Blet%20h=!1;if(e.tagName!==%22IMG%22)%7Blet%20I=e.currentStyle%7C%7Cwindow.getComputedStyle(e,!1),S=I.backgroundImage.slice(4,-1).replace(/%22/g,%22%22);if(e.getAttribute(%22aria-label%22)!==null&&(h=!0,i=e.getAttribute(%22aria-label%22),s=i,t+=%22-%20Accessible%20name%20provided%20by%20an%20%3Ccode%3Earia-label%3C/code%3E%20attribute.%3Cbr%3E%22,a=!1),!h&&e.getAttribute(%22aria-labelledby%22)!==null)%7Bh=!0;let%20x=e.getAttribute(%22aria-labelledby%22).split(%22%20%22);x.length%3E1?(i=%22%22,Array.from(x).forEach(function(B)%7Bi+=document.querySelector(%22#%22+B).textContent+%22%20%22%7D),i=i.trim(),t+=%22-%20Image%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20image%20on%20screen%3Cbr%3E%22,a=!0):(i=document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22)).textContent,t+=%22-%20Image%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20image%20on%20screen%3Cbr%3E%22,a=!0),s=i%7D%7Dh%7C%7C(t+=%22-%20Image%20has%20no%20accessible%20name%20provided.%20It%20must%20be%20set%20using%20%3Ccode%3Earia-labelledby%3C/code%3E%20or%20%3Ccode%3Earia-label%3C/code%3E%20(not%20%3Ccode%3Ealt%3C/code%3E)%3Cbr%3E%22,n=!0)%7Ds===%22%22&&(e.getAttribute(%22title%22)?s=e.getAttribute(%22title%22):s=%22%5Cu203C%5CuFE0F%20No%20alt,%20no%20title%22,t+=%22%5Cu203C%5CuFE0F%20No%20alt.%3Cbr%3E%22,n=!0),n&&(a=!1),o+=%22%3Ctr%22,o+='%20data-img-ref=%22'+d+'%22',a&&(o+='%20class=%22issue%20warn%22'),n&&(o+='%20class=%22issue%20err%22'),o+=%22%3E%22,e.tagName===%22IMG%22?u=%22%3Ccode%3E<img>%3C/code%3E%22:u='%3Ccode%3Erole=%22img%22%3C/code%3E',(s===%22NO_ALT_ATTRIBUTE%22%7C%7Cs===%22EMPTY_ALT_ATTRIBUTE%22)&&(i=%22%22,s=%22%22),o+=%22%3Ctd%3E%22+u+%22%3C/td%3E%22,o+='%3Ctd%3E%3Cimg%20src=%22'+A+'%22%20alt=%22%22%20style=%22max-width:200px;max-height:200px;%22%3E%3C/td%3E',o+=%22%3Ctd%3E%22+s,s.trim()!==i.trim()&&i.trim()!==%22%22&&(o+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),o+=%22%3C/td%3E%22,s.trim()!==i.trim()&&s.trim().toLowerCase()===i.trim().toLowerCase()&&(t+=%22-%20Same%20text%20but%20case%20difference%20noted%20(likely%20not%20an%20issue)%22),o+=%22%3Ctd%3E%22,a&&(o+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20image%3C/div%3E'),n&&(o+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20image%3C/div%3E',c=%22Image%20'%22+A+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+b+%60%0A---------------%0A%60),o+=t+'%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+d+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+d+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+b+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',o+='%3Ctd%3E%3Cbutton%20data-img-ref=%22'+d+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',o+=%22%3C/tr%3E%22,d++,(a%7C%7Cn)&&(m++,c=c.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(c))%7D),l='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkred;%7D;div.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:img,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20images%20on%20this%20page.%3C/h1%3E',l+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20images%20where%20there%20*may*%20be%20issues%20('+m+%22%20found)%3C/label%3E%22,l+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20images%20on%20page%3C/button%3E',l+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20images%20(img%20elements%20or%20elements%20with%20role=%22img%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3EImage%20type%3C/th%3E%3Cth%3EImage%20thumbnail%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+o+%22%3C/tbody%3E%3C/table%3E%22,l+=%22%3Cscript%3Efunction%20showImages()%7B%22,l+=%22var%20refWindow=window.opener;%22,l+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20imgToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BimgToHighlight=%22%5Bdata-img-ref='%22%20+%20highlightButton.getAttribute(%22data-img-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(imgToHighlight).setAttribute(%22tabindex%22,%22-1%22);refWindow.document.querySelector(imgToHighlight).focus();refWindow.document.querySelector(imgToHighlight).style.outline=%2210px%20solid%20darkred%22;refWindow.document.querySelector(imgToHighlight).style.outlineOffset=%22-10px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(imgToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,l+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',l+='var%20imgsToCopy=document.querySelectorAll(%22.imgToCopy%22);Array.from(imgsToCopy).forEach(imgToCopy%20=%3E%20%7BimgToCopy.addEventListener(%22focus%22,%20e%20=%3E%20%7BimgToCopy.select();%7D);%7D);',l+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',l+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowImages();%7D);%3C%5C/script%3E';let%20g=window.open(%22%22,%22popUpWinImages%22,%22height=800,width=1000%22);g.document.open(),g.document.write(l),g.document.close()%7Dv()%7D)();%7D)();%0A" }, { + "file": "inline-styles.js", "bookmarklet": "Inline styles", "description": "Highlight all elements with style attributes", - "file": "inline-styles.js", - "pageTest": true, "source": "Adrian Roselli", "sourceUrl": "https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#inline", "tags": [ "utility" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7Bvar%20t=document.createElement(%22style%22),e=document.createTextNode('%5Bstyle%5D%7B%20position:%20relative;%20outline:%204px%20solid%20#01ff70%20!important;%7D%20%5Bstyle%5D:after%7B%20content:%20%22inline%20style%22;%20position:%20absolute;%20top:%200;%20right:%200;%20background-color:%20#000;%20color:%20#01ff70;%20z-index:%209999;%20font-size:%2012px;%20font-weight:%20400;%20padding:%201px%203px;%7D%20body::after%7B%20position:%20absolute;%20top:%200;%20right:%204px;%20background-color:%20#000;%20color:%20#01ff70;%20z-index:%209999;%20font-size:%2016px;%20font-weight:%20400;%20padding:%203px%209px;%20outline:%204px%20solid%20#01ff70%20!important;%20content:%20%22inline%20styles%22;%7D%7D'),o=document.getElementsByTagName(%22head%22);t.appendChild(e);o%5B0%5D.appendChild(t);%7D)();%0A" }, { + "file": "isolator.js", "bookmarklet": "Isolator", "description": "Isolate a portion of the page", - "file": "isolator.js", - "pageTest": false, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "accessibility" ], - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20m(t)%7Blet%20a,o=t,s=t.tagName.toLowerCase(),i=%22%22,d=%22%22,l=%22%22,r=%22%22;for(;o.parentNode;)%7Bif((a=o.parentNode).tagName)%7Bi=a.tagName.toLowerCase();let%20c=a.querySelectorAll(%22:scope%20%3E%20%22+o.tagName);l=c.length%3E1?%22%5B%22+parseInt(Array.from(c).indexOf(o)+1)+%22%5D%22:%22%22,d=(s=o.tagName.toLowerCase())+l+r+d,r=%22/%22%7Do=a%7Dreturn%20i===%22%22&&(i=s),d=%22//%22+i+l+r+d%7Dfunction%20y()%7Blet%20t,a,o,s=!0,i=!1,d=document.querySelectorAll(%22*%22);function%20l(e,n)%7Bt=e,n.stopPropagation(),i%7C%7Cc(e),p(t)%7Dfunction%20r(e)%7Be.classList.remove(%22isolatorHighlight%22)%7Dfunction%20c(e)%7Be.classList.add(%22isolatorHighlight%22)%7Dfunction%20p(e)%7Bconsole.clear(),console.log(m(e)),o.innerHTML=m(e)%7DArray.from(d).forEach(e=%3E%7Be.addEventListener(%22click%22,n=%3E%7Bconsole.log(%22preventClicks%20=%20%22,s),s&&((function(f,u)%7Bt=f,f.tagName===%22HTML%22&&(s=!1),(function(g)%7Bif(!i)%7Blet%20h=g.parentNode,v=h.childNodes;h.tagName!==%22HTML%22?Array.from(v).forEach(x=%3E%7Bx!==g&&x.remove()%7D):i=!0%7D%7D)(f)%7D)(e),n.preventDefault())%7D),e.addEventListener(%22mouseover%22,n=%3E%7Bt=e,n.stopPropagation(),i%7C%7Cc(e),p(t)%7D),e.addEventListener(%22mouseout%22,n=%3E%7Br(e)%7D)%7D),(function()%7Blet%20e=document.createElement(%22style%22);e.textContent=%22.isolatorHighlight%7Boutline:4px%20solid%20black!important;outline-offset:-4px!important;-webkit-box-shadow:%200px%200px%200px%204px%20#fff;%20box-shadow:%200px%200px%200px%204px%20#fff;%7D#infoPanel%20%7Bz-index:1000;font-size:20px;background:rgba(0,0,0,0.8);color:#fff;font-weight:bold;padding:10px;position:fixed;bottom:20px;left:20px;font-family:sans-serif;%7D%20#infoPanel:empty%20%7Bvisibility:hidden;%7D%20#infoPanel%20code%20%7Bcolor:lime%7D%22,document.head.appendChild(e)%7D)(),(o=document.createElement(%22div%22)).setAttribute(%22id%22,%22infoPanel%22),o.setAttribute(%22role%22,%22status%22),document.body.appendChild(o),document.addEventListener(%22keydown%22,function(e)%7Bif(e.key===%22ArrowUp%22&&(e.preventDefault(),t.parentNode&&t.tagName!==%22HTML%22&&(r(t),console.log(%22currentEl.parentNode%20=%20%22,t.parentNode),a=t.parentNode,c(t=a)),p(t),o.textContent=o.textContent+%22%20(Press%20Return%20to%20isolate%20this%20element)%22),e.key===%22ArrowLeft%22&&(e.preventDefault(),t.previousElementSibling&&(r(t),l(t=t.previousElementSibling,e))),e.key===%22ArrowRight%22&&(e.preventDefault(),t.nextElementSibling&&(r(t),l(t=t.nextElementSibling,e))),e.key===%22ArrowDown%22&&(e.preventDefault(),t.childNodes.length%3E1))%7Br(t);let%20n,f=!1;Array.from(t.childNodes).forEach(u=%3E%7Bu.nodeType!==1%7C%7Cf%7C%7C(f=!0,n=u)%7D),n&&l(t=n,e)%7De.key===%22Enter%22&&(e.preventDefault(),t.click())%7D),p(%22Isolator%20started.%20Click%20on%20element%20you%20want%20to%20isolate%20in%20the%20DOM%22)%7Dy()%7D)();%7D)();%0A" + "pageTest": false, + "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20m(t)%7Blet%20a,o=t,s=t.tagName.toLowerCase(),i=%22%22,d=%22%22,l=%22%22,r=%22%22;for(;o.parentNode;)%7Bif((a=o.parentNode).tagName)%7Bi=a.tagName.toLowerCase();let%20c=a.querySelectorAll(%22:scope%20%3E%20%22+o.tagName);l=c.length%3E1?%22%5B%22+parseInt(Array.from(c).indexOf(o)+1)+%22%5D%22:%22%22,d=(s=o.tagName.toLowerCase())+l+r+d,r=%22/%22%7Do=a%7Dreturn%20i===%22%22&&(i=s),d=%22//%22+i+l+r+d%7Dfunction%20y()%7Blet%20t,a,o,s=!0,i=!1,d=document.querySelectorAll(%22*%22);function%20l(e,n)%7Bt=e,n.stopPropagation(),i%7C%7Cc(e),p(t)%7Dfunction%20r(e)%7Be.classList.remove(%22isolatorHighlight%22)%7Dfunction%20c(e)%7Be.classList.add(%22isolatorHighlight%22)%7Dfunction%20p(e)%7Bconsole.clear(),console.log(m(e)),o.innerHTML=m(e)%7DArray.from(d).forEach(e=%3E%7Be.addEventListener(%22click%22,n=%3E%7Bconsole.log(%22preventClicks%20=%20%22,s),s&&(function(f,u)%7Bt=f,f.tagName===%22HTML%22&&(s=!1),function(g)%7Bif(!i)%7Blet%20h=g.parentNode,v=h.childNodes;h.tagName!==%22HTML%22?Array.from(v).forEach(x=%3E%7Bx!==g&&x.remove()%7D):i=!0%7D%7D(f)%7D(e),n.preventDefault())%7D),e.addEventListener(%22mouseover%22,n=%3E%7Bt=e,n.stopPropagation(),i%7C%7Cc(e),p(t)%7D),e.addEventListener(%22mouseout%22,n=%3E%7Br(e)%7D)%7D),function()%7Blet%20e=document.createElement(%22style%22);e.textContent=%22.isolatorHighlight%7Boutline:4px%20solid%20black!important;outline-offset:-4px!important;-webkit-box-shadow:%200px%200px%200px%204px%20#fff;%20box-shadow:%200px%200px%200px%204px%20#fff;%7D#infoPanel%20%7Bz-index:1000;font-size:20px;background:rgba(0,0,0,0.8);color:#fff;font-weight:bold;padding:10px;position:fixed;bottom:20px;left:20px;font-family:sans-serif;%7D%20#infoPanel:empty%20%7Bvisibility:hidden;%7D%20#infoPanel%20code%20%7Bcolor:lime%7D%22,document.head.appendChild(e)%7D(),(o=document.createElement(%22div%22)).setAttribute(%22id%22,%22infoPanel%22),o.setAttribute(%22role%22,%22status%22),document.body.appendChild(o),document.addEventListener(%22keydown%22,function(e)%7Bif(e.key===%22ArrowUp%22&&(e.preventDefault(),t.parentNode&&t.tagName!==%22HTML%22&&(r(t),console.log(%22currentEl.parentNode%20=%20%22,t.parentNode),a=t.parentNode,c(t=a)),p(t),o.textContent=o.textContent+%22%20(Press%20Return%20to%20isolate%20this%20element)%22),e.key===%22ArrowLeft%22&&(e.preventDefault(),t.previousElementSibling&&(r(t),l(t=t.previousElementSibling,e))),e.key===%22ArrowRight%22&&(e.preventDefault(),t.nextElementSibling&&(r(t),l(t=t.nextElementSibling,e))),e.key===%22ArrowDown%22&&(e.preventDefault(),t.childNodes.length%3E1))%7Br(t);let%20n,f=!1;Array.from(t.childNodes).forEach(u=%3E%7Bu.nodeType!==1%7C%7Cf%7C%7C(f=!0,n=u)%7D),n&&l(t=n,e)%7De.key===%22Enter%22&&(e.preventDefault(),t.click())%7D),p(%22Isolator%20started.%20Click%20on%20element%20you%20want%20to%20isolate%20in%20the%20DOM%22)%7Dy()%7D)();%7D)();%0A" }, { + "file": "keyboard-visualizer.js", "bookmarklet": "Keyboard visualizer", "description": "Creates an overlay to display typed keys on the underlying page", - "file": "keyboard-visualizer.js", - "pageTest": "self", "source": "Sarah Higley", "sourceUrl": "https://codepen.io/smhigley/pen/eYEjKQz", "tags": [ "utility" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bvar%20c=%60%0A.sh-keyboard-viz%20%7B%0A%20%20position:%20fixed;%0A%20%20bottom:%2020px;%0A%20%20right:%2020px;%0A%20%20width:%2050%25;%0A%20%20max-width:%20300px;%0A%20%20background:%20rgba(0,%200,%200,%200.75);%0A%20%20color:%20white;%0A%20%20padding:%2010px%2020px;%0A%20%20border-radius:%204px;%0A%20%20border:%202px%20solid%20white;%0A%20%20box-shadow:%200%200%205px%201px%20rgba(0,%200,%200,%200.75);%0A%20%20font-size:%2018px;%0A%20%20font-weight:%20bold;%0A%20%20font-family:%20sans-serif;%0A%20%20z-index:%20999999;%0A%20%20max-height:%20calc(100vh%20-%2060px);%0A%20%20display:%20flex;%0A%20%20flex-direction:%20column;%0A%7D%0A%0A.sh-keyboard-viz%20ul%20%7B%0A%20%20flex:%201%201%20auto;%0A%20%20list-style-type:%20none;%0A%20%20padding:%200;%0A%20%20margin:%200;%0A%20%20overflow-y:%20auto;%0A%7D%0A%0A.sh-keyboard-viz%20li%20%7B%0A%20%20margin-bottom:%208px;%0A%7D%0A%0A.sh-keyboard-viz%20h3%20%7B%0A%20%20flex:%200%200%20auto;%0A%20%20font-size:%2024px;%0A%20%20margin:%200;%0A%20%20padding:%2010px%200%2015px;%0A%7D%0A%60;function%20u(e,n)%7Blet%20t=document.createElement(%22li%22);t.innerHTML=s(n),e.appendChild(t);let%20i=window.setTimeout(()=%3E%7Bl(t)%7D,5e3);return%7Belement:t,timerId:i%7D%7Dfunction%20l(e)%7Blet%20n=e.parentNode;n&&n.removeChild(e)%7Dfunction%20f(e,n)%7Blet%7Belement:t,timerId:i%7D=e;return%20t.innerHTML+=s(n),window.clearTimeout(i),i=window.setTimeout(()=%3E%7Bl(t)%7D,2e4),%7Belement:t,timerId:i%7D%7Dfunction%20a(e)%7Breturn%20e.length===1&&e.match(/%5E%5Ba-z0-9!%22#$%25&'()*+,./:;%3C=%3E?@%5B%5C%5D%20%5E_%60%7B%7C%7D~-%5D*$/i).length%3E0%7Dfunction%20r(e)%7Breturn%5B%22control%22,%22shift%22,%22os%22,%22alt%22,%22fn%22,%22meta%22%5D.includes(e.toLowerCase())%7Dfunction%20s(e)%7Breturn%20r(e)?%60$%7Be%7D%20%60:e%7Dfunction%20h()%7Blet%20e=document.createElement(%22div%22);e.className=%22sh-keyboard-viz%22,e.setAttribute(%22role%22,%22region%22),e.setAttribute(%22aria-labelledby%22,%22sh-viz-heading%22);let%20n=document.createElement(%22h3%22);n.id=%22sh-viz-heading%22,n.innerText=%22Pressed%20Keys%22,e.appendChild(n);let%20t=document.createElement(%22ul%22);return%20e.appendChild(t),e%7Dfunction%20m()%7Blet%20e=document.querySelector(%22.sh-keyboard-viz%22);if(!e)%7Be=h(),document.body.appendChild(e);let%20o=document.createElement(%22style%22);o.appendChild(document.createTextNode(c)),document.head.appendChild(o)%7Dlet%20n=e.querySelector(%22ul%22),t,i=!1;document.body.addEventListener(%22keydown%22,o=%3E%7Blet%20d=o.key===%22%20%22?%22Space%22:o.key;r(d)&&(i%7C%7C(t=void%200),i=!0),!a(d)&&!i&&(t=void%200),t?f(t,d):t=u(n,d),n.scrollHeight%3En.clientHeight&&t.element.scrollIntoView(),!a(d)&&!i&&(t=void%200)%7D,!0),document.body.addEventListener(%22keyup%22,o=%3E%7Br(o.key)&&(i=!1,t=void%200)%7D,!0)%7Dm();%7D)();%0A" }, { + "file": "language.js", "bookmarklet": "Language of page/parts", "description": "Display all lang attributes on page", - "file": "language.js", - "auditing": true, - "pageTest": true, "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "3.1.1 Language of Page (A)", "3.1.2 Language of Parts (AA)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7Bvar%20a=document.querySelectorAll(%22%5Blang%5D%22),g=document.querySelector(%22html%5Blang%5D%22),t=%22%22;g?t+=%22The%20page%20lang%20attribute%20is%20%22+g.getAttribute(%22lang%22)+%60%0A%60:t+=%60Page%20is%20missing%20lang%20attribute%0A%60;for(e=0;e%3Ca.length;e++)t+=a%5Be%5D.tagName+%22%20tag%20has%20%22+a%5Be%5D.getAttribute(%22lang%22)+%60%0A%60;var%20e;alert(t);%7D)();%0A" }, { + "file": "links.js", "bookmarklet": "Links", "description": "Display all links", - "file": "links.js", - "auditing": true, - "pageTest": false, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "accessibility" ], + "auditing": true, + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20L(e,i)%7Bi.parentNode.insertBefore(e,i.nextSibling)%7Dfunction%20y(e)%7Blet%20i=window.getComputedStyle(e);return%20i.display===%22none%22%7C%7Ci.opacity===0%7C%7Ci.clipPath===%22inset(100%25)%22&&i.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ci.height===%221px%22&&i.width===%221px%22&&i.overflow===%22hidden%22%7Dfunction%20C(e)%7Blet%20i=window.getComputedStyle(e);i.position===%22absolute%22&&i.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),i.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),i.display===%22none%22&&(e.style.display=%22block%22),i.opacity===0&&(e.style.opacity=1)%7Dlet%20f,n=%22%22,o=%22%22,B=document.querySelectorAll(%22a,%5Brole=link%5D%22),l=1,p,w=0,g=%22%22,h=%22%22;Array.from(B).forEach(function(e)%7Blet%20i=document.createElement(%22div%22);i.appendChild(e.cloneNode(!0)),g=i.innerHTML;let%20u=!1,t=%22%22,A=e.querySelectorAll(%22img%22),a=!1,c=!1;u=A.length%3E0;let%20x=e.querySelector(%22%5Baria-hidden=true%5D%22);x&&x.classList.add(%22remove-from-accname%22),u&&Array.from(A).forEach(function(b)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),b.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+b.getAttribute(%22alt%22)+%22%20%22),L(d,b)%7D),e.setAttribute(%22data-link-ref%22,l);let%20s=e.textContent,k=e.querySelector(%22.remove-from-accname%22);k&&k.remove();let%20r=e.textContent;if(e.getAttribute(%22aria-label%22)&&(r=e.getAttribute(%22aria-label%22),t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-label%3C/code%3E%22,s.trim()!==%22%22&&(t+=%22%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22),a=!0,r.trim().toLowerCase().indexOf(s.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-label%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')),e.getAttribute(%22aria-labelledby%22))%7Blet%20d=e.getAttribute(%22aria-labelledby%22).split(%22%20%22);d.length%3E1?(r=%22%22,Array.from(d).forEach(function(S)%7Br+=document.querySelector(%22#%22+S).textContent+%22%20%22%7D),r=r.trim(),t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,a=!0):(r=document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22)).textContent,t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,a=!0),r.trim().toLowerCase().indexOf(s.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-labelledby%20sources%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')%7Dy(e)&&(C(e),y(e)?t+=%22Link%20is%20hidden%3Cbr%3E%22:t+=%22Link%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),u&&(t+=%22%5Cu%7B1F304%7D%20Image%20link%3Cbr%3E%22),e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20Link%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Check%20that%20it%20behaves%20like%20a%20%3Ccode%3Ebutton%3C/code%3E%20and%20is%20not%20used%20as%20navigation.%3Cbr%3E%22,a=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)!==s&&(t+='-%20Link%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20different%20from%20text%20content.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E',a=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)===s&&(t+='Link%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20the%20same%20as%20the%20text%20content%20and%20therefore%20adds%20no%20extra%20useful%20information/context.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E'),e.tagName===%22A%22&&(e.getAttribute(%22href%22)===null&&!e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20is%20not%20keyboard-focusable%3Cbr%3E%22,a=!0),e.getAttribute(%22href%22)!==null&&!e.getAttribute(%22href%22)&&!e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20have%20an%20%3Ccode%3Ehref%3C/code%3E%20but%20it%20has%20no%20value,%20so%20it%20is%20keyboard-focusable%3Cbr%3E%22,a=!0),!e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20but%20is%20focusable%20because%20it%20has%20been%20provided%20with%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E%22,a=!0),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Link%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',a=!0),e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22Link%20has%20a%20%3Ccode%3Etabindex%3C/code%3E%20but%20it%20is%20not%20needed%20because%20the%20%3Ccode%3Ehref%3C/code%3E%20makes%20it%20focusable%3Cbr%3E%22),e.getAttribute(%22role%22)===%22link%22&&(t+=%22Link%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Elink%3C/code%3E.%20Not%20needed%20as%20it%20is%20an%20%3Ccode%3Ea%3C/code%3E%20element%20that%20is%20a%20link%20by%20default%3Cbr%3E%22)),e.tagName!==%22A%22&&e.getAttribute(%22role%22)===%22link%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Elink%3C/code%3E%20but%20is%20not%20an%20%3Ccode%3Ea%3C/code%3E%20element.%20Check%20that%20it%20is%20keyboard-operable%20(should%20activate%20with%20%3Ckbd%3EEnter%3C/kbd%3E%20key)%3Cbr%3E%22,a=!0),r===%22%22&&(e.getAttribute(%22title%22)?r=e.getAttribute(%22title%22):r=%22%5Cu203C%5CuFE0F%20Empty%20link%22,s=%22%5Cu203C%5CuFE0F%20Empty%20link%22,t+=%22%5Cu203C%5CuFE0F%20Empty%20link%3Cbr%3E%22,c=!0),u&&r===%22%5Cu203C%5CuFE0F%20Empty%20link%22&&(t+=%22%20-%20image%20is%20missing%20alternative%20text%20content%3Cbr%3E%22),e.href&&(f=e.href),c&&(a=!1),o+=%22%3Ctr%22,o+='%20data-link-ref=%22'+l+'%22',a&&(o+='%20class=%22issue%20warn%22'),c&&(o+='%20class=%22issue%20err%22'),o+=%22%3E%22,e.tagName===%22A%22?p=%22%3Ccode%3E<a>%3C/code%3E%22:p='%3Ccode%3Erole=%22link%22%3C/code%3E',o+=%22%3Ctd%3E%22+p+%22%3C/td%3E%22,o+=%22%3Ctd%3E%22+s+%22%3C/td%3E%22,o+=%22%3Ctd%3E%22+r,r.trim()!==s.trim()&&s.trim()!==%22%22&&(o+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),o+=%22%3C/td%3E%22,r.trim()!==s.trim()&&r.trim().toLowerCase()===s.trim().toLowerCase()&&(t+=%22-%20Same%20text%20but%20case%20difference%20noted%20(likely%20not%20an%20issue)%22),o+=%22%3Ctd%3E%22,a&&(o+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20link%3C/div%3E'),c&&(o+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20link%3C/div%3E'),h=%22Link%20'%22+s.trim()+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+g+%60%0A---------------%0A%60,o+=t+'%3Ca%20href=%22'+f+'%22%20target=%22_blank%22%20aria-label=%22'+r+'%22%3E%5Cu%7B1F517%7D%3C/a%3E%20%3Clabel%20for=%22l'+l+'%22%3ELinks%20to:%3C/label%3E%3Cinput%20id=%22l'+l+'%22%20class=%22linkToCopy%22%20type=%22text%22%20value=%22'+f+'%22%3E%20%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+l+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+l+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+g+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',o+='%3Ctd%3E%3Cbutton%20data-link-ref=%22'+l+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',o+=%22%3C/tr%3E%22,l++,(a%7C%7Cc)&&w++,c&&(h=h.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(h))%7D),n='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkblue;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:link,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20links%20on%20this%20page.%3C/h1%3E',n+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20links%20where%20there%20*may*%20be%20issues%20('+w+%22%20found)%3C/label%3E%22,n+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20links%20on%20page%3C/button%3E',n+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20links%20(anchors%20or%20elements%20with%20role=%22link%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3ELink%20type%3C/th%3E%3Cth%20scope=%22col%22%3ELink%20text%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+o+%22%3C/tbody%3E%3C/table%3E%22,n+=%22%3Cscript%3Efunction%20showLinks()%7B%22,n+=%22var%20refWindow=window.opener;%22,n+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20linkToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BlinkToHighlight=%22%5Bdata-link-ref='%22%20+%20highlightButton.getAttribute(%22data-link-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(linkToHighlight).focus();refWindow.document.querySelector(linkToHighlight).style.outline=%224px%20dashed%20darkblue%22;refWindow.document.querySelector(linkToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(linkToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,n+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',n+='var%20linksToCopy=document.querySelectorAll(%22.linkToCopy%22);Array.from(linksToCopy).forEach(linkToCopy%20=%3E%20%7BlinkToCopy.addEventListener(%22focus%22,%20e%20=%3E%20%7BlinkToCopy.select();%7D);%7D);',n+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',n+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowLinks();%7D);%3C%5C/script%3E';let%20m=window.open(%22%22,%22popUpWinLinks%22,%22height=800,width=1000%22);m.document.open(),m.document.write(n),m.document.close()%7Dv()%7D)();%7D)();%0A" }, { + "file": "markdown-link.js", "bookmarklet": "Markdown link", "description": "Copy page title and URL in markdown link format", - "file": "markdown-link.js", - "pageTest": "self", "source": "Brian Cantoni", "sourceUrl": "http://www.cantoni.org/2013/11/08/bookmarklet-copy-markdown-link", "tags": [ "utility" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bvar%20o=%22%5B%22+document.title+%22%5D(%22+location.href+%22)%22;window.prompt(%22Markdown%20link:%22,o);%7D)();%0A" }, { + "file": "non-underlined-links.js", "bookmarklet": "Non-underlined links", "description": "Display information about links without underlines", - "file": "non-underlined-links.js", - "auditing": true, - "pageTest": true, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "1.4.1 Use of Color (A)" ], - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;var%20l=%22%22;function%20y()%7Bconsole.clear();let%20c=!1,u=!1,i=!1,p=!1,k=document.querySelectorAll(%22a%22),f=0,h=!1,b=!1;function%20N(e,a,o)%7Blet%20n=%5Be,a,o%5D.map(function(t)%7Breturn(t/=255)%3C=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)%7D);return%20.2126*n%5B0%5D+.7152*n%5B1%5D+.0722*n%5B2%5D%7Dfunction%20x(e)%7Breturn%20e=(e=(e=e.replace(%22rgb(%22,%22%22)).replace(%22)%22,%22%22)).split(%22,%20%22)%7Dif((function()%7Blet%20e=document.createElement(%22style%22);e.textContent=%22.problem-highlight%20%7Boutline:5px%20solid%20darkred;outline-offset:3px;box-shadow:%200px%200px%200px%2010px%20#fff;%7D%22,document.head.appendChild(e)%7D)(),Array.from(k).forEach(e=%3E%7Bif(h=!1,b=!1,p=(function(a,o)%7Bfor(;(a=a.parentElement)&&!(a.matches%7C%7Ca.matchesSelector).call(a,o););return%20a%7D)(e,%22nav,%5Brole=navigation%5D%22),e.childNodes.length%3E0&&(e.childNodes%5B0%5D.tagName&&(e.childNodes%5B0%5D.tagName.toUpperCase()!==%22IMG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22SVG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22FIGURE%22%7C%7C(h=!0)),!(function(a)%7Bc=!1,u=!1,i=!1;let%20o=getComputedStyle(a);for(let%20n=0;n%3Co.length;n++)%7Blet%20t=o%5Bn%5D,r=o.getPropertyValue(t);t===%22text-decoration-line%22&&r===%22underline%22&&(u=!0),t!==%22border-bottom-style%22%7C%7Cr!==%22solid%22&&r!==%22dotted%22&&r!==%22dashed%22%7C%7C(i=!0),t===%22border-bottom-color%22&&r===%22transparent%22&&(i=!1),(u%7C%7Ci)&&(c=!0)%7Dreturn%20c%7D)(e)&&!h))%7Bl+=%60-------%0A%60,l+=%22Link%20text:%20%22+e.textContent+%60%0A%60,p%7C%7C((function(o)%7Bo.classList.add(%22problem-highlight%22)%7D)(e),l+=%22Affected%20node%20(xpath):%20%22+(function(o)%7Blet%20n,t=o,r=o.tagName.toLowerCase(),s=%22%22,d=%22%22,m=%22%22,g=%22%22;for(;t.parentNode;)%7Bif((n=t.parentNode).tagName)%7Bs=n.tagName.toLowerCase();let%20C=n.querySelectorAll(t.tagName);m=C.length%3E1?%22%5B%22+parseInt(Array.from(C).indexOf(t)+1)+%22%5D%22:%22%22,d=(r=t.tagName.toLowerCase())+m+g+d,g=%22/%22%7Dt=n%7Dreturn%20s===%22%22&&(s=r),d=%22//%22+s+m+g+d%7D)(e)+%60%0A%60,f++);let%20a=(function(o,n)%7Blet%20t=N(o%5B0%5D,o%5B1%5D,o%5B2%5D),r=N(n%5B0%5D,n%5B1%5D,n%5B2%5D);return(Math.max(t,r)+.05)/(Math.min(t,r)+.05)%7D)(x(getComputedStyle(e).color),x(getComputedStyle(e.parentNode).color));p?l+=%60Link%20is%20inside%20a%20%3Cnav%3E%20element%20and%20therefore%20its%20position/display%20does%20not%20require%20the%20underline%20for%20it%20to%20be%20perceived%20as%20a%20link.%0A%60:(a%3C3&&(l+=%22%5Cu%7B1F6A8%7D%20Contrast%20between%20link%20text%20and%20parent%20text%20node%20is%20under%203:1.%20Ratio%20is%20%22+a.toFixed(2)+%22:1.%22),l+=%60%0A%20%20%20Very%20likely%20a%20%5BSC%201.4.1%20Use%20of%20Color%5D(https://www.w3.org/TR/WCAG21/#use-of-color)%20issue%0A%60)%7D%7D),f%3E0)%7Blet%20e=f+%22%20possible%20issues%20with%20non-underlined%20links%20found%22;l=e+%60%0A%60+l,alert(e+%22%20(check%20console%20for%20more%20details)%22)%7Delse%20alert(%22No%20non-underlined%20links%20found%20(outside%20of%20a%20navigation%20area)%22);console.log(l)%7Dy();var%20w=l%7D)();%7D)();%0A" + "auditing": true, + "pageTest": true, + "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;var%20l=%22%22;function%20y()%7Bconsole.clear();let%20c=!1,u=!1,i=!1,p=!1,k=document.querySelectorAll(%22a%22),f=0,h=!1,b=!1;function%20N(e,a,o)%7Blet%20n=%5Be,a,o%5D.map(function(t)%7Breturn(t/=255)%3C=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)%7D);return%20.2126*n%5B0%5D+.7152*n%5B1%5D+.0722*n%5B2%5D%7Dfunction%20x(e)%7Breturn%20e=(e=(e=e.replace(%22rgb(%22,%22%22)).replace(%22)%22,%22%22)).split(%22,%20%22)%7Dif(function()%7Blet%20e=document.createElement(%22style%22);e.textContent=%22.problem-highlight%20%7Boutline:5px%20solid%20darkred;outline-offset:3px;box-shadow:%200px%200px%200px%2010px%20#fff;%7D%22,document.head.appendChild(e)%7D(),Array.from(k).forEach(e=%3E%7Bif(h=!1,b=!1,p=function(a,o)%7Bfor(;(a=a.parentElement)&&!(a.matches%7C%7Ca.matchesSelector).call(a,o););return%20a%7D(e,%22nav,%5Brole=navigation%5D%22),e.childNodes.length%3E0&&(e.childNodes%5B0%5D.tagName&&(e.childNodes%5B0%5D.tagName.toUpperCase()!==%22IMG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22SVG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22FIGURE%22%7C%7C(h=!0)),!function(a)%7Bc=!1,u=!1,i=!1;let%20o=getComputedStyle(a);for(let%20n=0;n%3Co.length;n++)%7Blet%20t=o%5Bn%5D,r=o.getPropertyValue(t);t===%22text-decoration-line%22&&r===%22underline%22&&(u=!0),t!==%22border-bottom-style%22%7C%7Cr!==%22solid%22&&r!==%22dotted%22&&r!==%22dashed%22%7C%7C(i=!0),t===%22border-bottom-color%22&&r===%22transparent%22&&(i=!1),(u%7C%7Ci)&&(c=!0)%7Dreturn%20c%7D(e)&&!h))%7Bl+=%60-------%0A%60,l+=%22Link%20text:%20%22+e.textContent+%60%0A%60,p%7C%7C(function(o)%7Bo.classList.add(%22problem-highlight%22)%7D(e),l+=%22Affected%20node%20(xpath):%20%22+function(o)%7Blet%20n,t=o,r=o.tagName.toLowerCase(),s=%22%22,d=%22%22,m=%22%22,g=%22%22;for(;t.parentNode;)%7Bif((n=t.parentNode).tagName)%7Bs=n.tagName.toLowerCase();let%20C=n.querySelectorAll(t.tagName);m=C.length%3E1?%22%5B%22+parseInt(Array.from(C).indexOf(t)+1)+%22%5D%22:%22%22,d=(r=t.tagName.toLowerCase())+m+g+d,g=%22/%22%7Dt=n%7Dreturn%20s===%22%22&&(s=r),d=%22//%22+s+m+g+d%7D(e)+%60%0A%60,f++);let%20a=function(o,n)%7Blet%20t=N(o%5B0%5D,o%5B1%5D,o%5B2%5D),r=N(n%5B0%5D,n%5B1%5D,n%5B2%5D);return(Math.max(t,r)+.05)/(Math.min(t,r)+.05)%7D(x(getComputedStyle(e).color),x(getComputedStyle(e.parentNode).color));p?l+=%60Link%20is%20inside%20a%20%3Cnav%3E%20element%20and%20therefore%20its%20position/display%20does%20not%20require%20the%20underline%20for%20it%20to%20be%20perceived%20as%20a%20link.%0A%60:(a%3C3&&(l+=%22%5Cu%7B1F6A8%7D%20Contrast%20between%20link%20text%20and%20parent%20text%20node%20is%20under%203:1.%20Ratio%20is%20%22+a.toFixed(2)+%22:1.%22),l+=%60%0A%20%20%20Very%20likely%20a%20%5BSC%201.4.1%20Use%20of%20Color%5D(https://www.w3.org/TR/WCAG21/#use-of-color)%20issue%0A%60)%7D%7D),f%3E0)%7Blet%20e=f+%22%20possible%20issues%20with%20non-underlined%20links%20found%22;l=e+%60%0A%60+l,alert(e+%22%20(check%20console%20for%20more%20details)%22)%7Delse%20alert(%22No%20non-underlined%20links%20found%20(outside%20of%20a%20navigation%20area)%22);console.log(l)%7Dy();var%20w=l%7D)();%7D)();%0A" }, { + "file": "page-link.js", "bookmarklet": "Page link", "description": "Copy page title and URL, separated by hyphens", - "file": "page-link.js", - "auditing": true, - "pageTest": "self", "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "utility" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bvar%20t=document.title+%22%20%5Cu2014%20%22+location.href;window.prompt(%22Plain%20text%20link:%22,t);%7D)();%0A" }, { + "file": "parsing-only.js", "bookmarklet": "Parsing only", "description": "Reduce HTML validation results to 4.1.1 Parsing (A) only", - "file": "parsing-only.js", - "auditing": true, - "pageTest": "self", "source": "Steve Faulkner", "sourceUrl": "https://cdpn.io/stevef/debug/dyGeywr", "tags": [ "4.1.1 Parsing (A)" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20r=!0,i=%5B%22tag%20seen%22,%22Stray%20end%20tag%22,%22Bad%20start%20tag%22,%22violates%20nesting%20rules%22,%22Duplicate%20ID%22,%22first%20occurrence%20of%20ID%22,%22Unclosed%20element%22,%22not%20allowed%20as%20child%20of%20element%22,%22unclosed%20elements%22,%22not%20allowed%20on%20element%22,%22unquoted%20attribute%20value%22,%22Duplicate%20attribute%22%5D,o,l,s,e,t,n,a=0;if(o=i.join(%22%7C%22),l=document.getElementById(%22results%22),!l)%7Balert(%22No%20results%20container%20found.%22);return%7Dfor(s=l.getElementsByTagName(%22li%22),n=0;n%3Cs.length;n++)e=s%5Bn%5D,e.className!==%22%22&&(t=(e.innerText!==void%200?e.innerText:e.textContent)+%22%22,(t.match(o)===null%7C%7Cr==!0&&t.indexOf(%22not%20allowed%20on%20element%22)!==-1&&t.indexOf(%22ng-%22)!==-1)&&(e.style.display=%22none%22,e.className=e.className+%22%20steveNoLike%22,a++));alert(%22Complete.%20%22+a+%22%20items%20removed.%22)%7D)();%7D)();%0A" }, { + "file": "placeholder-contrast.js", "bookmarklet": "Placeholder contrast checker", "description": "Measure contrast of placeholder text", - "file": "placeholder-contrast.js", - "auditing": true, - "pageTest": true, - "source": " Jason Morris", + "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "accessibility", "1.4.3 Contrast (Minimum) (AA)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bfunction%20s(o,e,t)%7Blet%5Bl,r,c%5D=%5Bo,e,t%5D.map(n=%3E(n=n/255,n%3C=.03928?n/12.92:Math.pow((n+.055)/1.055,2.4)));return%20.2126*l+.7152*r+.0722*c%7Dfunction%20u(o,e)%7Blet%20t=Math.max(o,e),l=Math.min(o,e);return(t+.05)/(l+.05)%7Dfunction%20d(o)%7Breturn%20o.match(/%5Cd+/g).map(Number)%7Dfunction%20g(o)%7Blet%20e=document.createElement(%22style%22),t=%22temp-%22+Math.random().toString(36).substr(2,9);o.classList.add(t),e.textContent=%60.$%7Bt%7D::placeholder%20%7B%20background-color:%20inherit;%20%7D%60,document.head.appendChild(e);let%20r=window.getComputedStyle(o,%22::placeholder%22).color;return%20o.classList.remove(t),e.remove(),r%7Dlet%20i=document.querySelectorAll(%22input%5Bplaceholder%5D,%20textarea%5Bplaceholder%5D%22);console.group(%22Placeholder%20Contrast%20Analysis%22),console.log(%22Analyzing%20%22+i.length+%60%20form%20elements...%0A%60),i.forEach((o,e)=%3E%7Blet%20t=window.getComputedStyle(o),l=g(o),r=t.backgroundColor,c=d(l),n=d(r),p=s(...c),h=s(...n),a=u(p,h),m=o.tagName.toLowerCase()+(o.id?%22#%22+o.id:%22%22)+(o.className?%22.%22+o.className.split(%22%20%22).join(%22.%22):%22%22)+%22::placeholder%22;console.group(%60Element%20$%7Be+1%7D:%20$%7Bm%7D%60),console.log(%22Placeholder%20Text:%22,o.placeholder),console.log(%22Placeholder%20Color:%22,l),console.log(%22Background:%22,r),a%3C4.5?console.log(%22%5Cu%7B1F6D1%7D%20Contrast%20Ratio:%22,a.toFixed(2)):console.log(%22%5Cu2705%20Contrast%20Ratio:%22,a.toFixed(2)),console.groupEnd(),o.style.outline=a%3C4.5?%225px%20solid%20#ff0000%22:%222px%20solid#00ff00%22%7D),console.groupEnd()%7D)();%7D)();%0A" }, { + "file": "re-enable-selection.js", "bookmarklet": "Re-enable selection", "description": "Unset user-select CSS property", - "file": "re-enable-selection.js", - "pageTest": true, "source": "Adrian Roselli", "sourceUrl": "https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#Selection", "tags": [ "diagnostic" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e=document.createElement(%22style%22),t;document.head.appendChild(e),t=e.sheet,t.insertRule(%22*%7Buser-select:unset%20!important%7D%22,0)%7D)();%7D)();%0A" }, { + "file": "service-html-validator.js", "bookmarklet": "Validate", "description": "Validate HTML of DOM", - "file": "service-html-validator.js", - "auditing": true, - "pageTest": "self", "source": "Deque", "sourceUrl": "https://dequeuniversity.com/validator", "tags": [ "4.1.1 Parsing (A)" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7B(function()%7B(function()%7Bvar%20t=document.doctype,d=%22%3C!DOCTYPE%20%22+t.name+(t.publicId?'%20PUBLIC%20%22'+t.publicId+'%22':%22%22)+(!t.publicId&&t.systemId?%22%20SYSTEM%22:%22%22)+(t.systemId?'%20%22'+t.systemId+'%22':%22%22)+%22%3E%22,m=document.documentElement.outerHTML,r=d+m,a=document.getElementById(%22deque-w3c-validator-bookmarklet%22);a&&a.remove();var%20e=document.createElement(%22form%22);e.id=%22deque-w3c-validator-bookmarklet%22,e.method=%22POST%22,e.action=%22https://validator.w3.org/nu/?showsource=yes&nocache=%22+Math.random(),e.target=%22_blank%22,e.enctype=%22multipart/form-data%22;var%20o=document.createElement(%22textarea%22);o.name=%22content%22,o.value=r,e.appendChild(o),document.body.appendChild(e),e.submit(),a=document.getElementById(%22deque-w3c-validator-bookmarklet%22),a&&a.remove()%7D)()%7D)();%7D)();%0A" }, { + "file": "service-internet-archive.js", "bookmarklet": "Save to Internet Archive", "description": "Submit current URL to the Internet Archive", - "file": "service-internet-archive.js", - "pageTest": "self", "source": "Jesse Gardner", "sourceUrl": "https://plasticmind.com/0s-and-1s/bookmarklet-archive-to-wayback-machine/", "tags": [ "utility" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bwindow.open(%22https://web.archive.org/save/%22+escape(window.location));%7D)();%0A" }, { + "file": "service-lighthouse.js", "bookmarklet": "Lighthouse report", "description": "Run a Lighthouse scan on current URL (regardless of broswer)", - "file": "service-lighthouse.js", - "pageTest": "self", "source": "Jeremy Keith", "sourceUrl": "https://adactio.com/journal/16523", "tags": [ "performance" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bwindow.open(%22https://googlechrome.github.io/lighthouse/viewer/?psiurl=%22+escape(window.location)+%22&strategy=mobile&category=performance&category=accessibility&category=best-practices&category=seo&category=pwa%22);%7D)();%0A" }, { + "file": "service-wave.js", "bookmarklet": "WAVE report", "description": "Run WebAIM WAVE on the current URL", - "file": "service-wave.js", - "pageTest": false, "source": "WebAIM", "sourceUrl": "https://wave.webaim.org/help", "tags": [ @@ -512,22 +511,26 @@ "1.4.3 Contrast (Minimum) (AA)", "2.1.1 Keyboard (A)", "2.2.1 Timing Adjustable (A)", - "2.2.2 Pause, Stop, Hide (A)", + "2.2.2 Pause", + "Stop", + "Hide (A)", "2.4.1 Bypass Blocks (A)", "2.4.2 Page Titled (A)", "2.4.4 Link Purpose (In Context) (A)", "2.4.6 Headings and Labels (AA)", "3.1.1 Language of Page (A)", "3.3.2 Labels or Instructions (A)", - "4.1.2 Name, Role, Value (A)" + "4.1.2 Name", + "Role", + "Value (A)" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7Bwindow.open(%22https://wave.webaim.org/report?url=%22+escape(window.location));%7D)();%0A" }, { + "file": "show-focus-styles.js", "bookmarklet": "Show focus styles", "description": "Force visibility of all focus styles at the same time", - "file": "show-focus-styles.js", - "pageTest": true, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ @@ -536,62 +539,62 @@ "2.4.12 Focus Not Obscured (2.2 AA", "2.4.13 Focus Not Obscured (2.2 AAA)" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bfunction%20r()%7Blet%20s=document.querySelectorAll('a%5Bhref%5D,button,select,input:not(%5Btype=%22hidden%22%5D),textarea,summary,details,area,%5Btabindex%5D,%5Bcontenteditable%5D:not(%5Bcontenteditable=%22false%22%5D)'),t,o=%22%22;console.clear(),Array.from(s).forEach(function(e)%7Be.style.transition=%22none%22,e.focus(),t=getComputedStyle(e),o=%22%22;for(var%20n=0;n%3Ct.length;n++)cssProperty=t%5Bn%5D,cssValue=t.getPropertyValue(cssProperty),o+=cssProperty+%22:%22+cssValue+%22;%22;e.setAttribute(%22style%22,o)%7D)%7Dr()%7D)();%7D)();%0A" }, { + "file": "strip-onpaste.js", "bookmarklet": "Remove onpaste", "description": "Remove onpaste attributes from password inputs which fixes security theatre of preventing paste", - "file": "strip-onpaste.js", - "pageTest": true, "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "utility" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7Bdocument.querySelectorAll(%22input%5Btype=password%5D%22).forEach(function(t)%7Breturn%20t.removeAttribute(%22onpaste%22)%7D);var%20e=document.createElement(%22style%22),o=document.createTextNode('body::after%7B%20position:%20absolute;%20top:%200;%20right:%204px;%20background-color:%20#000;%20color:%20#01ff70;%20z-index:%209999;%20font-size:%2016px;%20font-weight:%20400;%20padding:%203px%209px;%20outline:%204px%20solid%20#01ff70%20!important;%20content:%20%22removing%20onpaste%20attributes%22;%7D%7D'),n=document.getElementsByTagName(%22head%22);e.appendChild(o);n%5B0%5D.appendChild(e);%7D)();%0A" }, { + "file": "test-csp.js", "bookmarklet": "Test CSP", "description": "Test for errors related Content Security Policy (CSP)", - "file": "test-csp.js", - "pageTest": "self", "source": "SecurityPolicyViolationEvent on MDN", "sourceUrl": "https://developer.mozilla.org/en-US/docs/Web/API/SecurityPolicyViolationEvent#examples", "tags": [ "diagnostic" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bdocument.addEventListener(%22securitypolicyviolation%22,s,!1);var%20t=document.createElement(%22script%22);t.setAttribute(%22src%22,%22https://jsnmrs.github.io/bookmarklets/bookmarklets/test-js-external.js%22);document.body.appendChild(t);function%20s(e)%7B%22use%20strict%22;alert(e.violatedDirective+%22%20breaks%20Content%20Security%20Policy%20(CSP)%22)%7D%7D)();%0A" }, { + "file": "test-js-local.js", "bookmarklet": "Test local JS", "description": "Test for local JS support via bookmark", - "file": "test-js-local.js", - "pageTest": "self", "source": "Accessible Name and Description Inspector (ANDI) help page", "sourceUrl": "https://www.ssa.gov/accessibility/andi/help/faq.html", "tags": [ "diagnostic" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Balert(%22Your%20browser%20is%20not%20blocking%20JavaScript%20in%20favorites/bookmarks%22);%7D)();%0A" }, { + "file": "text-spacing.js", "bookmarklet": "Text spacing", "description": "Test on WCAG 1.4.12 Text Spacing", - "file": "text-spacing.js", - "auditing": true, - "pageTest": "self", "source": "Steve Faulkner", "sourceUrl": "https://codepen.io/stevef/pen/YLMqbo", "tags": [ "1.4.12 Text Spacing (AA)" ], + "auditing": true, + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document,l=%22phltsbkmklt%22,c=t.getElementById(l),a=t.querySelectorAll(%22iframe%22),e=0,i=a.length;if(c)%7Blet%20o=function(n)%7Bfor(var%20d%20of%20n.querySelectorAll(%22*%22))d.shadowRoot&&(d.shadowRoot.getElementById(l).remove(),o(d.shadowRoot))%7D;var%20m=o;if(c.remove(),i)for(e=0;e%3Ci;e++)try%7Ba%5Be%5D.contentWindow.document.getElementById(l).remove(),o(a%5Be%5D.contentWindow.document)%7Dcatch(n)%7Bconsole.log(n)%7Do(t)%7Delse%7Blet%20o=function(n)%7Bfor(var%20d%20of%20n.querySelectorAll(%22*%22))d.shadowRoot&&(d.shadowRoot.appendChild(r.cloneNode(!0)),o(d.shadowRoot))%7D;var%20h=o,r=t.createElement(%22style%22);for(r.id=l,r.appendChild(t.createTextNode(%22*%7Bline-height:1.5%20!important;letter-spacing:0.12em%20!important;word-spacing:0.16em%20!important;%7Dp%7Bmargin-bottom:2em%20!important;%7D%22)),t.getElementsByTagName(%22head%22)%5B0%5D.appendChild(r),e=0;e%3Ci;e++)try%7Ba%5Be%5D.contentWindow.document.getElementsByTagName(%22head%22)%5B0%5D.appendChild(r.cloneNode(!0)),o(a%5Be%5D.contentWindow.document)%7Dcatch(n)%7Bconsole.log(n)%7Do(t)%7D%7D)();%7D)();%0A" }, { + "file": "text-zoom.js", "bookmarklet": "Text zoom 200%", "description": "Zoom text only (not page) size to 200%", - "file": "text-zoom.js", - "pageTest": false, "source": "Ashlee M. Boyer", "sourceUrl": "https://ashleemboyer.com/blog/an-accessibility-bookmarklet-for-testing-200-percent-text-size", "tags": [ @@ -599,26 +602,26 @@ "1.4.4", "WCAG" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20e=document.querySelector(%22html%22),t=e.style.getPropertyValue(%22font-size%22)===%22200%25%22?null:%22200%25%22;e.style.setProperty(%22font-size%22,t)%7D)();%7D)();%0A" }, { + "file": "titles.js", "bookmarklet": "Titles", "description": "Display all titles", - "file": "titles.js", - "auditing": true, - "pageTest": false, "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "accessibility" ], - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20k(t,e)%7Be.parentNode.insertBefore(t,e.nextSibling)%7Dfunction%20w(t)%7Blet%20e=window.getComputedStyle(t);return%20e.display===%22none%22%7C%7Ce.opacity===0%7C%7Ce.clipPath===%22inset(100%25)%22&&e.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ce.height===%221px%22&&e.width===%221px%22&&e.overflow===%22hidden%22%7Dfunction%20B(t)%7Blet%20e=window.getComputedStyle(t);e.position===%22absolute%22&&e.overflow===%22hidden%22&&(t.style.height=%22auto%22,t.style.width=%22auto%22,t.style.position=%22relative%22,t.style.overflow=%22visible%22,t.style.display=%22block%22,t.style.opacity=1),(t.getAttribute(%22hidden%22)===%22%22%7C%7Ct.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ct.getAttribute(%22hidden%22)===%22true%22)&&t.removeAttribute(%22hidden%22),e.visibility===%22hidden%22&&(t.style.visibility=%22visible%22),e.display===%22none%22&&(t.style.display=%22block%22),e.opacity===0&&(t.style.opacity=1)%7Dlet%20o=%22%22,i=%22%22,E=document.querySelectorAll(%22body%20%5Btitle%5D,iframe%22),l=1,b=0,y=0,g=%22%22,a,c=%22%22;Array.from(E).forEach(function(t)%7Ba=%22No%22,(t.getAttribute(%22tabindex%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22%7C%7C(t.tagName===%22INPUT%22%7C%7Ct.tagName===%22BUTTON%22%7C%7Ct.tagName===%22TEXTAREA%22%7C%7Ct.tagName===%22SELECT%22%7C%7Ct.tagName===%22IFRAME%22%7C%7Ct.tagName===%22A%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22&&!t.disabled)&&(a=%22Yes%22);let%20e=document.createElement(%22div%22);e.appendChild(t.cloneNode(!0)),g=e.innerHTML;let%20s=%22%22,r=!1,n=!1;t.setAttribute(%22data-title-ref%22,l);let%20x=!1,A=t.querySelectorAll(%22img%22);x=A.length%3E0,x&&Array.from(A).forEach(function(m)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),m.getAttribute(%22alt%22)?d.textContent=%22%20%22+m.getAttribute(%22alt%22)+%22%20%22:d.textContent=%22**%20Image%20with%20empty%20or%20missing%20alt%20**%22,k(d,m)%7D);let%20p=t.textContent;t.tagName===%22IMG%22&&(p=t.getAttribute(%22alt%22));let%20u=p,h=t.getAttribute(%22title%22);u===null&&(u=%22%22),h===null&&(h=%22%22),w(t)&&(B(t),w(t)?s+=%22-%20Element%20is%20hidden%3Cbr%3E%22:s+=%22-%20Element%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),n&&(r=!1),i+=%22%3Ctr%22,i+='%20data-title-ref=%22'+l+'%22',u.trim()===h.trim()?(r=!1,n=!1):t.tagName!==%22IFRAME%22&&(r=!1,n=!0,b++,s+=%22-%20The%20title%20text%20differs%20from%20the%20on-screen%20text.%3Cbr%3E%22,a===%22Yes%22&&(s+=%22-%20This%20is%20an%20interactive%20element,%20but%20the%20title%20attribute%20*may*%20be%20ignored%20by%20assistive%20tech%20(depending%20on%20user%20settings).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20As%20this%20is%20a%20non-interactive%20element,%20the%20title%20attribute%20will%20be%20ignored%20by%20assistive%20tech.%3Cbr%3E%22)),t.tagName===%22IFRAME%22&&h.trim()===%22%22&&(r=!1,n=!0,b++,s+=%22An%20%3Ccode%3Eiframe%3C/code%3E%20MUST%20have%20a%20title%20attribute.%3Cbr%3E%22),r&&(i+='%20class=%22warn%22'),n&&(i+='%20class=%22issue%20err%22'),i+=%22%3E%22,i+=%22%3Ctd%3E%22+p+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22+h+%22%3C/td%3E%22,u.trim()===h.trim()&&u.trim()!==%22%22&&(s+=%22-%20title%20text%20is%20identical%20to%20on-screen%20text%20(superfluous,%20but%20not%20harmful).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20This%20is%20not%20an%20interactive/focusable%20element.%20The%20title%20attribute%20will%20not%20be%20available%20to%20anyone%20expect%20mouse%20users%20(touch%20screen,%20keyboard-only,%20assistive%20tech%20users%20all%20excluded).%3Cbr%3E%22),i+=%22%3Ctd%3E%22+a+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22,r&&(i+='%3Cdiv%20class=%22issues%22%3EPossible%20title%20issue%20found%20with%20this%20element%3C/div%3E'),n&&(i+='%3Cdiv%20class=%22issues%22%3EDefinite%20title%20issue%20found%20with%20this%20element%3C/div%3E'),c=%22Element%20with%20title%20'%22+p.trim()+%60':%0A%60+s+%60Markup%20with%20issue:%0A%60+g+%60%0A---------------%0A%60,i+=s+'%3Cbr%3E%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+l+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+l+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+g+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',i+='%3Ctd%3E%3Cbutton%20data-title-ref=%22'+l+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',i+=%22%3C/tr%3E%22,l++,(r%7C%7Cn)&&y++,n&&(c=c.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(c))%7D),o='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:rebeccapurple;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.checkDiffs:after%7Bcontent:%22Accessible%20name%20differs%22;color:#a50202;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:#a50202;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:elWithTitle,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20elements%20with%20titles%20on%20this%20page.%3C/h1%3E',b%3E0&&(o+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20elements%20with%20definite%20title%20issues('+y+%22).%3C/label%3E%3Cbr%3E%22),o+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20elements%20with%20%60title%60%20on%20page%3C/button%3E',o+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20things%20with%20title%20attributes%20on%20this%20page%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%20scope=%22col%22%3EOn-screen%20text%3C/th%3E%3Cth%3ETitle%20text%3C/th%3E%3Cth%3EInteractive?%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+i+%22%3C/tbody%3E%3C/table%3E%22,o+=%22%3Cscript%3Efunction%20showElsWithTitles()%7B%22,o+=%22var%20refWindow=window.opener;%22,o+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20titleToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BtitleToHighlight=%22%5Bdata-title-ref='%22%20+%20highlightButton.getAttribute(%22data-title-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(titleToHighlight).setAttribute(%22tabindex%22,%22-1%22);refWindow.document.querySelector(titleToHighlight).focus();refWindow.document.querySelector(titleToHighlight).style.outline=%224px%20dashed%20rebeccapurple%22;refWindow.document.querySelector(titleToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(titleToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,o+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',o+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',o+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowElsWithTitles();%7D);%3C%5C/script%3E';let%20f=window.open(%22%22,%22popUpWinTitles%22,%22height=800,width=1000%22);f.document.open(),f.document.write(o),f.document.close()%7Dv()%7D)();%7D)();%0A" + "auditing": true, + "pageTest": false, + "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20k(t,e)%7Be.parentNode.insertBefore(t,e.nextSibling)%7Dfunction%20w(t)%7Blet%20e=window.getComputedStyle(t);return%20e.display===%22none%22%7C%7Ce.opacity===0%7C%7Ce.clipPath===%22inset(100%25)%22&&e.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ce.height===%221px%22&&e.width===%221px%22&&e.overflow===%22hidden%22%7Dfunction%20B(t)%7Blet%20e=window.getComputedStyle(t);e.position===%22absolute%22&&e.overflow===%22hidden%22&&(t.style.height=%22auto%22,t.style.width=%22auto%22,t.style.position=%22relative%22,t.style.overflow=%22visible%22,t.style.display=%22block%22,t.style.opacity=1),(t.getAttribute(%22hidden%22)===%22%22%7C%7Ct.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ct.getAttribute(%22hidden%22)===%22true%22)&&t.removeAttribute(%22hidden%22),e.visibility===%22hidden%22&&(t.style.visibility=%22visible%22),e.display===%22none%22&&(t.style.display=%22block%22),e.opacity===0&&(t.style.opacity=1)%7Dlet%20o=%22%22,i=%22%22,E=document.querySelectorAll(%22body%20%5Btitle%5D,iframe%22),l=1,b=0,y=0,g=%22%22,a,c=%22%22;Array.from(E).forEach(function(t)%7Ba=%22No%22,(t.getAttribute(%22tabindex%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22%7C%7C(t.tagName===%22INPUT%22%7C%7Ct.tagName===%22BUTTON%22%7C%7Ct.tagName===%22TEXTAREA%22%7C%7Ct.tagName===%22SELECT%22%7C%7Ct.tagName===%22IFRAME%22%7C%7Ct.tagName===%22A%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22&&!t.disabled)&&(a=%22Yes%22);let%20e=document.createElement(%22div%22);e.appendChild(t.cloneNode(!0)),g=e.innerHTML;let%20s=%22%22,r=!1,n=!1;t.setAttribute(%22data-title-ref%22,l);let%20x=!1,A=t.querySelectorAll(%22img%22);if(x=A.length%3E0,x)%7Blet%20S=%22%22;Array.from(A).forEach(function(m)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),m.getAttribute(%22alt%22)?d.textContent=%22%20%22+m.getAttribute(%22alt%22)+%22%20%22:d.textContent=%22**%20Image%20with%20empty%20or%20missing%20alt%20**%22,k(d,m)%7D)%7Dlet%20p=t.textContent;t.tagName===%22IMG%22&&(p=t.getAttribute(%22alt%22));let%20u=p,h=t.getAttribute(%22title%22);u===null&&(u=%22%22),h===null&&(h=%22%22),w(t)&&(B(t),w(t)?s+=%22-%20Element%20is%20hidden%3Cbr%3E%22:s+=%22-%20Element%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),n&&(r=!1),i+=%22%3Ctr%22,i+='%20data-title-ref=%22'+l+'%22',u.trim()===h.trim()?(r=!1,n=!1):t.tagName!==%22IFRAME%22&&(r=!1,n=!0,b++,s+=%22-%20The%20title%20text%20differs%20from%20the%20on-screen%20text.%3Cbr%3E%22,a===%22Yes%22&&(s+=%22-%20This%20is%20an%20interactive%20element,%20but%20the%20title%20attribute%20*may*%20be%20ignored%20by%20assistive%20tech%20(depending%20on%20user%20settings).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20As%20this%20is%20a%20non-interactive%20element,%20the%20title%20attribute%20will%20be%20ignored%20by%20assistive%20tech.%3Cbr%3E%22)),t.tagName===%22IFRAME%22&&h.trim()===%22%22&&(r=!1,n=!0,b++,s+=%22An%20%3Ccode%3Eiframe%3C/code%3E%20MUST%20have%20a%20title%20attribute.%3Cbr%3E%22),r&&(i+='%20class=%22warn%22'),n&&(i+='%20class=%22issue%20err%22'),i+=%22%3E%22,i+=%22%3Ctd%3E%22+p+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22+h+%22%3C/td%3E%22,u.trim()===h.trim()&&u.trim()!==%22%22&&(s+=%22-%20title%20text%20is%20identical%20to%20on-screen%20text%20(superfluous,%20but%20not%20harmful).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20This%20is%20not%20an%20interactive/focusable%20element.%20The%20title%20attribute%20will%20not%20be%20available%20to%20anyone%20expect%20mouse%20users%20(touch%20screen,%20keyboard-only,%20assistive%20tech%20users%20all%20excluded).%3Cbr%3E%22),i+=%22%3Ctd%3E%22+a+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22,r&&(i+='%3Cdiv%20class=%22issues%22%3EPossible%20title%20issue%20found%20with%20this%20element%3C/div%3E'),n&&(i+='%3Cdiv%20class=%22issues%22%3EDefinite%20title%20issue%20found%20with%20this%20element%3C/div%3E'),c=%22Element%20with%20title%20'%22+p.trim()+%60':%0A%60+s+%60Markup%20with%20issue:%0A%60+g+%60%0A---------------%0A%60,i+=s+'%3Cbr%3E%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+l+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+l+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+g+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',i+='%3Ctd%3E%3Cbutton%20data-title-ref=%22'+l+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',i+=%22%3C/tr%3E%22,l++,(r%7C%7Cn)&&y++,n&&(c=c.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(c))%7D),o='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:rebeccapurple;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.checkDiffs:after%7Bcontent:%22Accessible%20name%20differs%22;color:#a50202;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:#a50202;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:elWithTitle,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20elements%20with%20titles%20on%20this%20page.%3C/h1%3E',b%3E0&&(o+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20elements%20with%20definite%20title%20issues('+y+%22).%3C/label%3E%3Cbr%3E%22),o+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20elements%20with%20%60title%60%20on%20page%3C/button%3E',o+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20things%20with%20title%20attributes%20on%20this%20page%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%20scope=%22col%22%3EOn-screen%20text%3C/th%3E%3Cth%3ETitle%20text%3C/th%3E%3Cth%3EInteractive?%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+i+%22%3C/tbody%3E%3C/table%3E%22,o+=%22%3Cscript%3Efunction%20showElsWithTitles()%7B%22,o+=%22var%20refWindow=window.opener;%22,o+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20titleToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BtitleToHighlight=%22%5Bdata-title-ref='%22%20+%20highlightButton.getAttribute(%22data-title-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(titleToHighlight).setAttribute(%22tabindex%22,%22-1%22);refWindow.document.querySelector(titleToHighlight).focus();refWindow.document.querySelector(titleToHighlight).style.outline=%224px%20dashed%20rebeccapurple%22;refWindow.document.querySelector(titleToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(titleToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,o+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',o+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',o+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowElsWithTitles();%7D);%3C%5C/script%3E';let%20f=window.open(%22%22,%22popUpWinTitles%22,%22height=800,width=1000%22);f.document.open(),f.document.write(o),f.document.close()%7Dv()%7D)();%7D)();%0A" }, { + "file": "tool-a11y-css.js", "bookmarklet": "a11y.css", "description": "Warns about possible risks and mistakes in HTML code", - "file": "tool-a11y-css.js", - "pageTest": false, "source": "Gaël Poupard", "sourceUrl": "https://ffoodd.github.io/a11y.css/", "tags": [ @@ -626,26 +629,27 @@ "css", "external" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e=document.createElement(%22LINK%22);e.href=%22https://rawgit.com/ffoodd/a11y.css/master/css/a11y-en.css%22,e.rel=%22stylesheet%22,e.media=%22all%22,document.body.appendChild(e)%7D)();%7D)();%0A" }, { + "file": "tool-andi.js", "bookmarklet": "ANDI", "description": "Accessible Name & Description Inspector is a free accessibility testing tool", - "file": "tool-andi.js", - "auditing": true, - "pageTest": false, "source": "Accessible Solutions Branch of the Social Security Administration", "sourceUrl": "https://www.ssa.gov/accessibility/andi/help/install.html", "tags": [ "accessibility", "external" ], + "auditing": true, + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document.createElement(%22script%22);t.setAttribute(%22src%22,%22https://www.ssa.gov/accessibility/andi/andi.js%22),document.body.appendChild(t)%7D)();%7D)();%0A" }, { + "file": "tool-aria-usage.js", "bookmarklet": "ARIA usage", "description": "Report on ARIA usage on current URL", - "file": "tool-aria-usage.js", "source": "TPGi", "sourceUrl": "https://thepaciellogroup.github.io/WAI-ARIA-Usage/WAI-ARIA_usage.html", "tags": [ @@ -655,9 +659,9 @@ "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document.createElement(%22script%22);t.setAttribute(%22src%22,%22https://thepaciellogroup.github.io/WAI-ARIA-Usage/aria-usage.js%22),document.body.appendChild(t)%7D)();%7D)();%0A" }, { + "file": "tool-aria.js", "bookmarklet": "ARIA", "description": "Display ARIA information for accessibility testing", - "file": "tool-aria.js", "source": "Paul J. Adam", "sourceUrl": "https://pauljadam.com/bookmarklets/aria.html", "tags": [ @@ -667,10 +671,9 @@ "dist": "javascript:void%20(()=%3E%7B(function()%7Bdocument.body.appendChild(document.createElement(%22script%22)).src=%22https://cdn.jsdelivr.net/gh/pauljadam/bookmarklets@master/aria.js%22;for(var%20t=document.getElementsByTagName(%22iframe%22),e=0;e%3Ct.length;e++)t%5Be%5D.contentDocument.body.appendChild(document.createElement(%22script%22)).src=%22https://cdn.jsdelivr.net/gh/pauljadam/bookmarklets@master/aria.js%22%7D)();%7D)();%0A" }, { + "file": "tool-contrast-checker.js", "bookmarklet": "Contrast checker", "description": "Contrast checker for color combinations", - "file": "tool-contrast-checker.js", - "pageTest": false, "source": "WebAIM", "sourceUrl": "https://webaim.org/resources/contrastchecker/bookmarklet", "tags": [ @@ -678,128 +681,130 @@ "1.4.3", "1.4.11" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20s=document.getElementById(%22contrastletdragable%22);if(s==null)%7Bvar%20e=document.createElement(%22div%22);e.id=%22contrastletdragable%22,e.style.width=%22384px%22,e.style.position=%22absolute%22,e.style.right=%2220px%22,e.style.top=window.pageYOffset+20+%22px%22,e.style.zIndex=%2210000%22,e.style.boxSizing=%22content-box%22;var%20o=document.createElement(%22div%22);o.id=%22contrastletdragzone%22,o.style.width=%22100%25%22,o.style.height=%2215px%22,o.style.cursor=%22move%22,o.style.backgroundColor=%22#0f2c65%22,o.style.boxSizing=%22content-box%22,e.appendChild(o),document.body.appendChild(e);var%20n=document.createElement(%22button%22);n.id=%22contrastletclose%22,n.style.width=%2215px%22,n.style.height=%2215px%22,n.style.float=%22right%22,n.style.padding=%220%22,n.style.border=%220%22,n.style.borderTop=%221px%20solid%20#0f2c65%22,n.style.borderRight=%221px%20solid%20#0f2c65%22,n.setAttribute(%22aria-label%22,%22Close%20Contrast%20Checker%22),n.addEventListener(%22click%22,function()%7Be.remove()%7D,!1);var%20v=document.createTextNode(%22X%22);n.appendChild(v),o.appendChild(n);var%20d=document.createElement(%22iframe%22);d.src=%22https://webaim.org/resources/contrastchecker/mini?ver=1&a=%22+Math.random(),d.style.width=%22380px%22,d.style.height=%22368px%22,d.style.margin=%220px%22,d.style.borderStyle=%22solid%22,d.style.borderColor=%22#0f2c65%22,d.style.boxSizing=%22content-box%22,e.appendChild(d);let%20m=0,u=0,f=function(i)%7Bm=i.clientX,u=i.clientY,document.addEventListener(%22mousemove%22,p),document.addEventListener(%22mouseup%22,y)%7D,p=function(i)%7Blet%20h=i.clientX-m,t=i.clientY-u;e.style.top=%60$%7Be.offsetTop+t%7Dpx%60,e.style.left=%60$%7Be.offsetLeft+h%7Dpx%60,m=i.clientX,u=i.clientY%7D,y=function()%7Bdocument.removeEventListener(%22mousemove%22,p),document.removeEventListener(%22mouseup%22,y)%7D;e.addEventListener(%22mousedown%22,f),document.addEventListener(%22keyup%22,function(i)%7Bi.keyCode===27&&e.remove()%7D),d.addEventListener(%22keyup%22,function(i)%7Bi.keyCode===27&&e.remove()%7D),document.addEventListener(%22securitypolicyviolation%22,()=%3E%7Bd.remove();var%20i=document.createTextNode(%22The%20Content%20Security%20Policy%20on%20this%20page%20does%20not%20allow%20embedded%20iframes.%20The%20Contrast%20Checker%20Bookmarklet%20cannot%20run%20on%20this%20page.%20Press%20Esc%20to%20dismiss%20this%20message.%22);e.style.backgroundColor=%22#fff%22,e.appendChild(i)%7D)%7D%7D)();%7D)();%0A" }, { + "file": "tool-html-codesniffer.js", "bookmarklet": "HTML CodeSniffer", "description": "Checks HTML source code and detects violations of a defined coding standard", - "file": "tool-html-codesniffer.js", - "pageTest": false, "source": "Squiz Labs", "sourceUrl": "https://squizlabs.github.io/HTML_CodeSniffer/", "tags": [ "accessibility", "external" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20n=%22//squizlabs.github.io/HTML_CodeSniffer/build/%22,t=function(o,d)%7Bvar%20e=document.createElement(%22script%22);e.onload=function()%7Be.onload=null,e.onreadystatechange=null,d.call(this)%7D,e.onreadystatechange=function()%7B/%5E(complete%7Cloaded)$/.test(this.readyState)===!0&&(e.onreadystatechange=null,e.onload())%7D,e.src=o,document.head?document.head.appendChild(e):document.getElementsByTagName(%22head%22)%5B0%5D.appendChild(e)%7D,a=%7Bpath:n%7D;t(n+%22HTMLCS.js%22,function()%7BHTMLCSAuditor.run(%22WCAG2AA%22,null,a)%7D)%7D)();%7D)();%0A" }, { + "file": "tool-label-in-name.js", "bookmarklet": "Label in name", "description": "Display label in name", - "file": "tool-label-in-name.js", - "pageTest": true, "source": "Jonathan Avila", "sourceUrl": "https://mraccess77.github.io/favlets/Label-in-name.js", "tags": [ "2.5.3 Label in Name (A)", "external" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7Bfunction%20o(r)%7Bvar%20e=r.createElement(%22script%22);e.setAttribute(%22src%22,%22https://whatsock.github.io/w3c-alternative-text-computation/Sample%2520JavaScript%2520Recursion%2520Algorithm/recursion.js%22),r.head.appendChild(e),setTimeout(function()%7Bm(r)%7D,500);for(var%20n=%5B%22frame%22,%22iframe%22%5D,t=0;t%3Cn.length;t++)for(var%20a=r.getElementsByTagName(n%5Bt%5D),l=0;l%3Ca.length;l++)try%7Bo(a%5Bl%5D.contentWindow.document)%7Dcatch%7B%7D%7Dfunction%20s(r,e)%7Bvar%20n=e.id;labels=r.getElementsByTagName(%22label%22);for(var%20t=0;t%3Clabels.length;t++)if(labels%5Bt%5D.htmlFor==n)return%20labels%5Bt%5D%7Dfunction%20m(r)%7Bfor(var%20e=r.querySelectorAll(%22button,%20input,%20textarea,%20select,%20%5Btabindex='0'%5D,a%5Bhref%5D,summary%22),n,t,a=0;a%3Ce.length;a++)if(n=%22%22,n=getAccName(e%5Ba%5D),t=%22%22,(e%5Ba%5D.tagName==%22INPUT%22%7C%7Ce%5Ba%5D.tagName==%22SELECT%22%7C%7Ce%5Ba%5D.tagName==%22TEXTAREA%22)&&s(r,e%5Ba%5D)?t=s(r,e%5Ba%5D).textContent:e%5Ba%5D.tagName==%22INPUT%22&&e%5Ba%5D.hasAttribute(%22value%22)?t=e%5Ba%5D.getAttribute(%22value%22):t=e%5Ba%5D.textContent,t=t.trim(),t&&!n.name.includes(t))%7Bvar%20l=document.createElement(%22span%22);l.style.color=%22black%22,l.style.backgroundColor=%22gold%22,l.style.fontSize=%22small%22,l.style.border=%22thin%20solid%20black%22,l.style.position=%22absolute%22,l.appendChild(r.createTextNode(n.name)),e%5Ba%5D.parentNode.insertBefore(l,e%5Ba%5D)%7D%7Do(document);%7D)();%0A" }, { + "file": "tool-sa11y.js", "bookmarklet": "Sa11y", "description": "The accessibility quality assurance assistant", - "file": "tool-sa11y.js", - "pageTest": "self", "source": "Toronto Metropolitan University", "sourceUrl": "https://ryersondmp.github.io/sa11y/demo/en/", "tags": [ "accessibility", "external" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7B(function(e)%7Be.body.appendChild(e.createElement(%22script%22)).src=%22https://cdn.jsdelivr.net/gh/ryersondmp/sa11y@latest/bookmarklet/sa11y-en.min.js%22%7D)(document);%7D)();%0A" }, { + "file": "truncation.js", "bookmarklet": "Truncation", "description": "Identify instances of text-overflow: ellipsis", - "file": "truncation.js", - "pageTest": true, - "source": " Jason Morris", + "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ "accessibility" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bfunction%20s(e)%7Bfor(var%20l=e.cssRules%7C%7Ce.rules,t=0;t%3Cl.length;t++)%7Bvar%20r=l%5Bt%5D;if(r.style&&r.style.textOverflow===%22ellipsis%22)%7Bvar%20f=document.querySelectorAll(r.selectorText);f.forEach(function(u)%7Bu.style.border=%225px%20solid%20red%22%7D)%7D%7D%7Dvar%20o=document.querySelectorAll(%22style%22);o.forEach(function(e)%7Bs(e.sheet)%7D);var%20c=document.querySelectorAll('link%5Brel=%22stylesheet%22%5D');c.forEach(function(e)%7Bvar%20l=e.sheet;l&&s(l)%7D);var%20n=document.querySelectorAll(%22*%22);n.forEach(function(e)%7Be.style.textOverflow===%22ellipsis%22&&(e.style.border=%225px%20solid%20red%22)%7D)%7D)();%7D)();%0A" }, { + "file": "user-agent.js", "bookmarklet": "User Agent", "description": "Display current user agent string", - "file": "user-agent.js", - "pageTest": "self", "source": "Thomas Orlita", "sourceUrl": "https://github.com/ThomasOrlita/awesome-bookmarklets#get-user-agent", "tags": [ "diagnostic" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7Bprompt(%22User%20agent:%22,navigator.userAgent);%7D)();%0A" }, { + "file": "viewport.js", "bookmarklet": "Viewport", "description": "Display viewport width and height", - "file": "viewport.js", - "pageTest": "self", "source": "jakob-e", "sourceUrl": "https://codepen.io/jakob-e/pen/qEZZox/top/", "tags": [ "diagnostic" ], + "pageTest": "self", "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document,n=window,i=t.body,e,o,d=%22top%22,p=%22left%22;if(n.vpbkmklt)%7Bi.removeChild(t.getElementById(%22vpbkmklt1%22)),i.removeChild(t.getElementById(%22vpbkmklt2%22)),n.vpbkmklt=0;return%7De=t.createElement(%22style%22),e.setAttribute(%22id%22,%22vpbkmklt1%22),e.innerText=%22.foo%7B%20content:bar;%7D%22,i.appendChild(e),e=t.createElement(%22script%22),e.setAttribute(%22id%22,%22vpbkmklt2%22),e.innerText=%22var%20u=undefined,d=document,w=window,b=d.body;s=d.getElementById('vpbkmklt1'),or=function()%7Bb.setAttribute('data-vp','width:%20%20'+w.innerWidth+'px%5C%5Cnheight:%20'+w.innerHeight+'px');%7D,dc=function(e)%7B%20%20%20x=(e!==u%20&&%20e.x/w.innerWidth%20%3E%20.5)?'right':'left';%20%20%20y=(e!==u%20&&%20e.y/w.innerHeight%20%3E%20.5)?'bottom':'top';if(e!==u%20)%7Bconsole.log(e.x/w.innerWidth);%7D%20%20s.innerText='body:before%7B'+y+':5px;'+x+':5px;content:attr(data-vp);background:#000;color:#01ff70;white-space:pre;display:inline-block;padding:5px;position:fixed;opacity:0.95;-webkit-font-smoothing:subpixel-antialiased;font:11px/1.4%20monospace;z-index:9999%20!important;%7D';%20%7D;%22,i.appendChild(e),n.vpbkmklt=1,n.onresize=or,t.ondblclick=dc,or(),dc()%7D)();%7D)();%0A" }, { + "file": "window-1280x1024.js", "bookmarklet": "Open 1280x1024", "description": "Opens a new window with the current URL at 1280x1024", - "file": "window-1280x1024.js", - "auditing": true, - "pageTest": true, "source": "Mike in a CSS Tricks article comment", "sourceUrl": "https://css-tricks.com/snippets/javascript/1024x768-bookmarklet/#comment-1766738", "tags": [ "1.4.4 Resize Text (AA)", "1.4.10 Reflow (AA)" ], + "auditing": true, + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=%22w%22+new%20Date().getTime(),o=%22toolbar=yes,location=yes,status=yes,resizable=yes,favorites=yes,width=1280,height=1024,left=0,top=0%22,e=document.createElement(%22P%22);e.innerHTML='%3Ca%20href=%22#%22%20id=%22'+t+%60%22%20target=%22_blank%22%20onclick=%22window.open(window.location.href,%20'',%20'%60+o+%60'%20);%20return%20false;%22%3E%3C/a%3E%3C/p%3E%60,document.body.appendChild(e),document.getElementById(t).click()&&document.body.removeChild(e)%7D)();%7D)();%0A" }, { + "file": "window-320x256.js", "bookmarklet": "Open 320x256", "description": "Opens a new window with the current URL at 320x256", - "file": "window-320x256.js", - "pageTest": true, "source": "Mike in a CSS Tricks article comment", "sourceUrl": "https://css-tricks.com/snippets/javascript/1024x768-bookmarklet/#comment-1766738", "tags": [ "1.4.10 Reflow (AA)" ], + "pageTest": true, "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=%22w%22+new%20Date().getTime(),o=%22toolbar=yes,location=yes,status=yes,resizable=yes,favorites=yes,width=320,height=256,left=0,top=0%22,e=document.createElement(%22P%22);e.innerHTML='%3Ca%20href=%22#%22%20id=%22'+t+%60%22%20target=%22_blank%22%20onclick=%22window.open(window.location.href,%20'',%20'%60+o+%60'%20);%20return%20false;%22%3E%3C/a%3E%3C/p%3E%60,document.body.appendChild(e),document.getElementById(t).click()&&document.body.removeChild(e)%7D)();%7D)();%0A" }, { + "file": "wtfocus.js", "bookmarklet": "WTFocus", "description": "Display information with focusable elements", - "file": "wtfocus.js", - "auditing": true, - "pageTest": "self", "source": "Ian Lloyd", "sourceUrl": "https://a11y-tools.com/bookmarklets/", "tags": [ "2.4.4 Link Purpose (In Context) (A)", - "4.1.2 Name, Role, Value (A)" + "4.1.2 Name", + "Role", + "Value (A)" ], - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20re()%7Blet%20z=document.activeElement,H=document.querySelectorAll('a%5Bhref%5D,button,select,input:not(%5Btype=%22hidden%22%5D),textarea,summary,area,%5Btabindex%5D:not(#WTFocusPanel):not(%5Btabindex%5E=%22-1%22%5D),%5Bcontenteditable%5D:not(%5Bcontenteditable=%22false%22%5D)'),E=%22background:#fff;color:darkgreen;font-weight:bold;text-decoration:line-through%22,j=%22font-weight:bold;color:#99f170;background:#333;display:inline-block;padding:3px;%22,h=%22color:pink;background:#333;padding:3px;%22,A=%22color:black;background:#fefbe3;font-weight:bold;%22,a=document.createElement(%22div%22),O=document.createElement(%22div%22),R=20,Y=400,w=7,ie='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F449%7D%5Cu%7B1F3FD%7D%3C/span%3E%3Cspan%20class=%22visually-hidden%22%3EAccessible%20name%20provided%20by%3C/span%3E%20',ce='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F6A8%7D%3C/span%3E%20%3Cspan%20class=%22visually-hidden%22%3EWarning%3C/span%3E',V,P=%22Accessible%20name:%20%22,k=!1,p=%22%22,m=!1,x=!1,I=!1,G=!1,L=!1;function%20W()%7Bm=!1,x=!1%7Dfunction%20l(e,r,o,n,C)%7Bk&&(r=r.split(%22%3C%22).join(%22<%22).split(%22%3E%22).join(%22>%22),p+=%22%3Cli%22,(C%7C%7Cn)&&(p+='%20class=%22',C&&(p+=%22visible%22),n&&(p+=%22outline%22),p+='%22'),p+='%20role=%22listitem%22%3E%3Cspan%20style=%22'+o+'%22%3E',m&&(p+=ie),x&&(p+=ce),p+=e+%22%3C/span%3E %22+r+%60%3C/li%3E%0A%60),r=r.replace(%22<%22,%22%3C%22).replace(%22>%22,%22%3E%22),console.log(%22%25c%22+e+'%22'+r+'%22',o)%7Dfunction%20J()%7Blet%20e=document.createElement(%22button%22);e.textContent=%22Close%20(Esc)%22,e.setAttribute(%22type%22,%22button%22),e.setAttribute(%22class%22,%22panel-btn%22),e.addEventListener(%22click%22,()=%3E%7BD()%7D);let%20r=document.createElement(%22button%22);r.textContent=%22Change%20Mode%20(M)%22,r.setAttribute(%22type%22,%22button%22),r.setAttribute(%22class%22,%22panel-btn%22),r.addEventListener(%22click%22,o=%3E%7BK()%7D),a.appendChild(e),a.appendChild(r)%7Dfunction%20K()%7BL?(document.querySelector(%22#WTFocusPanel%22).classList.remove(%22curtainsMode%22),document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22),document.querySelector(%22#WTFocusCurtain%22).setAttribute(%22hidden%22,%22hidden%22),L=!1,P=%22Accessible%20name:%20%22):(document.querySelector(%22#WTFocusPanel%22).classList.add(%22curtainsMode%22),document.querySelector(%22#WTFocusCurtain%22).removeAttribute(%22hidden%22),L=!0,P=%22%22),Q(z),z.focus()%7Dfunction%20D()%7Bdocument.querySelector(%22#WTFocusCurtain%22).remove(),document.querySelector(%22#WTFocusPanel%22).remove(),document.querySelector(%22#panelStyles%22).remove(),document.querySelector(%22#focusStyles%22).remove()%7Dfunction%20Q(e)%7Blet%20r=e.getBoundingClientRect(),o=document.documentElement.scrollTop,n=r.right+R+Y,C=a.offsetHeight,q=o+r.top+C,i=window.innerWidth,c=window.innerHeight;L?document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22):n%3Ei?(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=%22auto%22,a.style.right=i-r.left+R-w+%22px%22,a.classList.add(%22toLeft%22)):(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=r.right+R-w+%22px%22,a.style.right=%22auto%22,a.classList.remove(%22toLeft%22))%7Dconsole.clear(),(function()%7Blet%20e=document.createElement(%22style%22);e.setAttribute(%22type%22,%22text/css%22),e.setAttribute(%22id%22,%22panelStyles%22),e.textContent=%22.dupeAccName%20%7Boutline:4px%20dashed%20#CC3300!important;outline-offset:%22+w+%22px!important;overflow:visible;%7D%20.WTFocusTempFocusStyle:focus%20%7Boutline:%22+w+%22px%20solid%20black!important;outline-offset:%22+w+%22px!important;overflow:visible;/*background:yellow!important;color:black!important;*/%7D%20.WTFocusTempFocusStyle.dupeAccName:focus%20%7Boutline-color:#CC3300!important;%7D%20.visually-hidden%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D#WTFocusCurtain%20%7Bbackground:black;position:%20fixed;top:%200;bottom:%200;left:%200;right:%200;z-index:49999%7D%22,document.querySelector(%22body%22).appendChild(e)%7D)(),document.querySelector(%22#WTFocusCurtain%22)&&D(),k=!0,p=%22%22,(function(e)%7Blet%20r=document.createElement(%22style%22);r.setAttribute(%22type%22,%22text/css%22),r.setAttribute(%22id%22,%22focusStyles%22),r.textContent=%22#WTFocusPanel.error%20%7Bbackground:darkred;%7D%20#WTFocusPanel.warning%20%7Bbackground:#CC3300;%7D%20#WTFocusPanel.curtainsMode.error%20%7Bbackground:black;%7D%20#WTFocusPanel.curtainsMode%20%7Bz-index:50000;position:fixed;top:50%25;left:50%25;transform:translate(-50%25,-50%25);%7D%20#WTFocusPanel.curtainsMode.warning%20%7Bbackground:black;%7D%20#WTFocusPanel%5Bhidden%5D%20%7Bdisplay:none;%7D%20#WTFocusPanel%20*%20%7Btext-align:left%7D%20#WTFocusPanel%20%7Bborder:2px%20solid%20#fff;z-index:1000;text-shadow:none;font-family:sans-serif;display:block;text-align:left;position:%20absolute;z-index:10000;background:%20black;padding:%2020px%2020px;width:%22+e+%22px;font-size:16px;%7D%20#WTFocusPanel%20button%20%7Bfont-weight:bold;background:none;color:#fff;padding:3px%2010px;font-size:14px;border:1px%20solid%20#fff;display:inline-block;margin:10px%201em%20-10px%200;%7D%20#WTFocusPanel%20ul,#WTFocusPanel%20li%20%7Bmargin:0;padding:0;list-style:none%7D%20#WTFocusPanel%20li%20%7Bmargin:3px%200;background:#fff;color:#333;padding:2px%7D%20#WTFocusPanel%20li.outline%20%7Boutline:4px%20solid%20rgb(58,%20190,%2058);outline-offset:-4px;padding:8px%7D%20#WTFocusPanel.error:before%20%7Bbackground:darkred%7D%20#WTFocusPanel.warning:before%20%7Bbackground:#CC3300%7D%20#WTFocusPanel:before%20%7Bcontent:'';display:block;height:20px;width:20px;transform:rotate(45deg);position:absolute;background:#000;left:-12px;top:3px;border:2px%20solid%20#fff;border-right:none;border-top:none;%7D%20#WTFocusPanel.toBottom:before%20%7Btop:auto;bottom:3px%7D%20#WTFocusPanel.toLeft:before%20%7Bleft:auto;right:-12px;border:2px%20solid%20#fff;border-left:none;border-bottom:none;%7D%20#WTFocusPanel.curtainsMode%20%7Boutline:10px%20solid%20orange;%7D%20#WTFocusPanel.curtainsMode:before%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li.visible%20%7Bdisplay:block;%7D%20#WTFocusPanel.curtainsMode%20li%20span%20%7Bdisplay:none!important;%7D%20%22,document.querySelector(%22head%22).appendChild(r)%7D)(Y),O.setAttribute(%22id%22,%22WTFocusCurtain%22),O.setAttribute(%22hidden%22,%22hidden%22),document.querySelector(%22body%22).appendChild(O),a.setAttribute(%22id%22,%22WTFocusPanel%22),L&&a.setAttribute(%22class%22,%22curtainsMode%22),a.setAttribute(%22aria-live%22,%22polite%22),a.setAttribute(%22tabindex%22,%22-1%22),a.setAttribute(%22hidden%22,%22hidden%22),a.setAttribute(%22role%22,%22region%22),a.setAttribute(%22aria-label%22,%22Accessibility%20properties%20panel%22),document.querySelector(%22body%22).appendChild(a),window.addEventListener(%22keyup%22,e=%3E%7Be.key===%22Escape%22&&document.querySelector(%22#WTFocusPanel%22)&&D()%7D),window.addEventListener(%22keyup%22,e=%3E%7Be.key.toLowerCase()===%22m%22&&document.querySelector(%22#WTFocusPanel%22)&&K()%7D),J();let%20U=%5B%5D;Array.from(H).forEach(function(e)%7Be.classList.add(%22WTFocusTempFocusStyle%22);let%20r=e.querySelectorAll(%22style%22);Array.from(r).forEach(function(o)%7Bo.remove()%7D),e.addEventListener(%22focus%22,()=%3E%7Blet%20o=e.getAttribute(%22role%22),n=e.tagName.toLowerCase();if(console.clear(),!o)%7Bif(n!=%22article%22&&n!=%22button%22&&n!=%22dialog%22&&n!=%22figure%22&&n!=%22img%22&&n!=%22main%22&&n!=%22math%22%7C%7C(o=n),n==%22summary%22&&(o=%22button%22),n==%22aside%22&&(o=%22complementary%22),n==%22dd%22&&(o=%22definition%22),n==%22html%22&&(o=%22document%22),n!=%22details%22&&n!=%22fieldset%22&&n!=%22optgroup%22%7C%7C(o=%22group%22),n!=%22menu%22&&n!=%22ol%22&&n!=%22ul%22%7C%7C(o=%22list%22),n==%22datalist%22&&(o=%22listbox%22),n==%22li%22&&(o=%22listitem%22),n==%22nav%22&&(o=%22navigation%22),n==%22progress%22&&(o=%22progressbar%22),n==%22hr%22&&(o=%22separator%22),n==%22output%22&&(o=%22status%22),n!=%22dfn%22&&n!=%22dt%22%7C%7C(o=%22term%22),n==%22a%22&&(o=%22link%22),n==%22select%22&&(o=%22listbox%22),n==%22textarea%22&&(o=%22textbox%22),n==%22input%22)%7Blet%20t=e.getAttribute(%22type%22).toLowerCase();t===%22text%22&&(o=%22textbox%22),t===%22range%22&&(o=%22slider%22),t===%22number%22&&(o=%22spinbutton%22),t!==%22checkbox%22&&t!==%22radio%22%7C%7C(o=t),t!==%22button%22&&t!==%22image%22&&t!==%22reset%22&&t!==%22submit%22%7C%7C(o=%22button%22)%7D%7Dz=e,Array.from(H).forEach(function(t)%7Bt.classList.remove(%22dupeAccName%22)%7D);let%20C=!1;m=!1,x=!1;let%20q=e.querySelectorAll(%22img,%20%5Brole='image'%5D%5Baria-label%5D,%20%5Brole='img'%5D%5Baria-label%5D%22);(C=q.length%3E0)&&Array.from(q).forEach(function(t)%7Blet%20d=document.createElement(%22SPAN%22);var%20T,B;d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22data-temp-node%22,%22true%22),t.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+t.getAttribute(%22alt%22)+%22%20%22),t.getAttribute(%22role%22)&&t.getAttribute(%22aria-label%22)&&(d.textContent=%22%20%22+t.getAttribute(%22aria-label%22)+%22%20%22),T=d,(B=t).parentNode.insertBefore(T,B.nextSibling)%7D),setTimeout(function()%7Be.classList.add(%22WTFocusTempFocusStyle%22)%7D,100),p=%22%22;let%20i=e.tagName.toLowerCase(),c=e.getAttribute(%22role%22);c&&(c=e.getAttribute(%22role%22).toLowerCase());let%20Z=%22%3C%22+i+%22%3E%22,_=!1,$=!1;c&&(Z=%22%3C%22+i+'%20role=%22'+c+'%22%3E',(c===%22link%22&&i===%22a%22%7C%7Cc===%22button%22&&i===%22button%22%7C%7Cc===%22image%22&&i===%22img%22%7C%7Cc===%22img%22&&i===%22img%22%7C%7Cc===%22navigation%22&&i===%22nav%22%7C%7Cc===%22heading%22&&(i===%22h1%22%7C%7Ci===%22h2%22%7C%7Ci===%22h3%22%7C%7Ci===%22h4%22%7C%7Ci===%22h5%22%7C%7Ci===%22h6%22))&&(_=!0),(c===%22link%22&&i!==%22a%22%7C%7Cc===%22button%22&&i!==%22button%22%7C%7C(c===%22image%22%7C%7Cc===%22image%22)&&i!==%22img%22%7C%7Cc===%22navigation%22&&i!==%22nav%22%7C%7Cc===%22heading%22&&i!==%22h1%22&&i!==%22h2%22&&i!==%22h3%22&&i!==%22h4%22&&i!==%22h5%22&&i!==%22h6%22)&&($=!0));let%20ee,b=e.textContent,f=e.ariaLabel,S=e.getAttribute(%22aria-labelledby%22),N=e.getAttribute(%22placeholder%22),F=%22%22,g=e.getAttribute(%22value%22),v=e.getAttribute(%22title%22),s=%22%22,y=%22%22,te=!1,oe=!1,u=%22%22,ne=!1;k&&Q(e),b=b.trim();let%20ae=(function(t,d)%7Bfor(;(t=t.parentElement)&&!(t.matches%7C%7Ct.matchesSelector).call(t,d););return%20t%7D)(e,%22label%22);if(ae&&(te=!0,s=y=ae.textContent.trim()),e.getAttribute(%22id%22))%7Blet%20t=document.querySelector(%22%5Bfor='%22+e.getAttribute(%22id%22)+%22'%5D%22);t&&(oe=!0,y=t.textContent)%7Dif(te%7C%7Coe%7C%7C(y=%22N/A%22),b%7C%7C(b=%22N/A%22),g%7C%7C(g=%22N/A%22),v%7C%7C(v=%22N/A%22),N%7C%7C(N=%22N/A%22),f%7C%7C(f=%22N/A%22),S)%7Blet%20t=(ee=S).split(%22%20%22);t.length%3E1?(Array.from(t).forEach(function(d)%7Bdocument.querySelector(%22#%22+d)?F+=document.querySelector(%22#%22+d).textContent+%22%20%22:F+=%22%5Cu2753%5Cu2753%5Cu2753%20%22%7D),F=F.trim()):F=document.querySelector(%22#%22+ee).textContent%7Delse%20S=%22N/A%22;let%20le=e.querySelectorAll(%22%5Baria-hidden='true'%5D,%5Brole='presentation'%5D%22),M=b;if(le.length%3E0&&(ne=!0,Array.from(le).forEach(function(t)%7Blet%20d=t.textContent;d!==%22%22&&(M=M.split(d).join(%22%20%22))%7D),M=M.trim()),i===%22input%22)%7Blet%20t=e.getAttribute(%22type%22);t===%22submit%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22image%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22cancel%22&&g===%22N/A%22&&(s=%22Cancel%22,u=%22Not%20provided%20(using%20default)%22)%7Dif(v!==%22N/A%22&&(s=v,u=%22title%20attribute%22),g!==%22N/A%22&&(s=g,u=%22value%20attribute%22),N!==%22N/A%22&&(s=N,u=%22placeholder%20attribute%22),b!==%22N/A%22&&(s=M,u=%22Inner%20text%20content%22),y!==%22N/A%22&&(s=y,u=%22%3Clabel%3E%20text%22),f!==%22N/A%22&&(s=f,u=%22aria-label%22),S!==%22N/A%22&&(s=F,u=%22aria-labelledby%22),console.log(%22%25cACTIVE%20ELEMENT:%20%22,%22background:#193c10;color:white;%22),console.log(e),I=e.getAttribute(%22data-dupe%22)===%22true%22,G=I&&s===%22%22,s===%22%22%7C%7CI)%7Bif(s===%22%22&&(x=!0,k&&a.classList.add(%22error%22),l(P+%22No%20accessible%20name!%22,%22%22,h),l(%22Accessible%20Name%20Source:%20N/A%22,%22%22,h)),I&&s!==%22%22)%7Bk&&a.classList.add(%22warning%22);let%20t=document.querySelectorAll(%22%5Bdata-accname='%22+s+%22'%5D%22),d=t.length;l(P,s,h,!1,!0),G%7C%7C(Array.from(t).forEach(function(T)%7BT.classList.add(%22dupeAccName%22)%7D),l(%22Duplicate%20warning!%22,d+%22%20elements%20on%20page%20have%20the%20same%20accessible%20name%22,h)),console.log(%22Elements%20on%20page%20that%20have%20identical%20accessible%20names:%22),Array.from(t).forEach(function(T)%7Bconsole.log(T)%7D),l(%22Accessible%20Name%20Source:%20%22,u,h)%7D%7Delse%20k&&(a.classList.remove(%22error%22),a.classList.remove(%22warning%22)),l(P,s,j,!1,!0),l(%22Accessible%20Name%20Source:%20%22,u,j);x=!1,l(%22HTML%20Element:%20%22,Z,j),l(%22Role:%20%22,o,%22color:#333;background:#fff;%22,!1,!0),k%7C%7Cconsole.log(%22%25cACCESSIBLE%20NAME%20COMES%20FROM:%20%22,%22background:#193c10;color:white;%22),_&&(x=!0,l(%22Superfluous%20%60role%60%20attribute%22,%22%22,h)),$&&(x=!0,l(%22Better%20to%20use%20a%20native%20HTML%20element%22,%22%22,h)),b=b.trim(),y=y.trim(),v=v.trim(),f=f.trim(),S=S.trim(),W(),u===%22placeholder%20attribute%22?(m=!0,l(%22@placeholder:%20%22,N,A,!0)):l(%22@placeholder:%20%22,N,N===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22title%20attribute%22?(m=!0,l(%22@title:%20%22,v,A,!0)):l(%22@title:%20%22,v,v===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22value%20attribute%22?(m=!0,l(%22@value:%20%22,g,A,!0)):l(%22@value:%20%22,g,g===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22Inner%20text%20content%22?(m=!0,l(C?%22Inner%20text%20content%20(includes%20image%20alt):%20%22:%22Inner%20text%20content:%20%22,b,A,!0),ne&&l(%22!%20elements%20hidden%20to%20AT%20removed%22,%22%22,A)):l(%22Text%20Content:%20%22,b,b===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22%3Clabel%3E%20text%22?(m=!0,l(%22Visible%20%60label%60%20text:%20%22,y,A,!0)):l(%22Visible%20%60label%60%20text:%20%22,y,y===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-label%22?f===b?(x=!0,l(%22%60aria-label%60%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-label%20value:%20%22,f,A,!0)):l(%22@aria-label%20value:%20%22,f,f===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-labelledby%22?F===b?(x=!0,l(%22%60aria-labelledby%60%20source%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-labelledby%20value:%20%22,S,A,!0),l(%22@aria-labelledby%20sources:%20%22,F,A)):(l(%22@aria-labelledby%20value:%20%22,S,%22color:#333;background:#fff;%22),l(%22@aria-labelledby%20sources:%20%22,%22N/A%22,%22color:#333;background:#fff;%22)),k&&(document.querySelector(%22#WTFocusPanel%22).innerHTML='%3Cul%20role=%22list%22%3E'+p+%22%3C/ul%3E%22,document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22hidden%22),J());let%20se=document.querySelectorAll(%22%5Bdata-temp-node%5D%22);Array.from(se).forEach(function(t)%7Bt.remove()%7D),e.setAttribute(%22data-accname%22,s),X%7C%7C(function(t,d)%7Blet%20T=!1;Array.from(U).forEach(function(B)%7BB===t&&(T=!0)%7D),T?(d.setAttribute(%22data-dupe%22,%22true%22),document.querySelector(%22%5Bdata-accname='%22+t+%22'%5D%22).setAttribute(%22data-dupe%22,%22true%22)):U.push(t)%7D)(s,e)%7D)%7D);let%20X=!1;(function()%7Bif(V=document.activeElement,Array.from(H).forEach(function(e)%7Bdocument.activeElement===e&&e.blur(),e.focus()%7D),X=!0,V.tagName===%22BODY%22)%7Blet%20e=document.querySelector(%22body%22);e.setAttribute(%22tabindex%22,%22-1%22),e.focus(),document.querySelector(%22#WTFocusPanel%22).setAttribute(%22hidden%22,%22hidden%22)%7Delse%20V.focus();console.clear()%7D)(),console.log(%22had%20focus%20=%20%22,z)%7Dre()%7D)();%7D)();%0A" + "auditing": true, + "pageTest": "self", + "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20re()%7Blet%20z=document.activeElement,H=document.querySelectorAll('a%5Bhref%5D,button,select,input:not(%5Btype=%22hidden%22%5D),textarea,summary,area,%5Btabindex%5D:not(#WTFocusPanel):not(%5Btabindex%5E=%22-1%22%5D),%5Bcontenteditable%5D:not(%5Bcontenteditable=%22false%22%5D)'),E=%22background:#fff;color:darkgreen;font-weight:bold;text-decoration:line-through%22,j=%22font-weight:bold;color:#99f170;background:#333;display:inline-block;padding:3px;%22,h=%22color:pink;background:#333;padding:3px;%22,A=%22color:black;background:#fefbe3;font-weight:bold;%22,a=document.createElement(%22div%22),O=document.createElement(%22div%22),R=20,Y=400,w=7,ie='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F449%7D%5Cu%7B1F3FD%7D%3C/span%3E%3Cspan%20class=%22visually-hidden%22%3EAccessible%20name%20provided%20by%3C/span%3E%20',ce='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F6A8%7D%3C/span%3E%20%3Cspan%20class=%22visually-hidden%22%3EWarning%3C/span%3E',V,P=%22Accessible%20name:%20%22,k=!1,p=%22%22,m=!1,x=!1,I=!1,G=!1,L=!1;function%20W()%7Bm=!1,x=!1%7Dfunction%20l(e,r,o,n,C)%7Bk&&(r=r.split(%22%3C%22).join(%22<%22).split(%22%3E%22).join(%22>%22),p+=%22%3Cli%22,(C%7C%7Cn)&&(p+='%20class=%22',C&&(p+=%22visible%22),n&&(p+=%22outline%22),p+='%22'),p+='%20role=%22listitem%22%3E%3Cspan%20style=%22'+o+'%22%3E',m&&(p+=ie),x&&(p+=ce),p+=e+%22%3C/span%3E %22+r+%60%3C/li%3E%0A%60),r=r.replace(%22<%22,%22%3C%22).replace(%22>%22,%22%3E%22),console.log(%22%25c%22+e+'%22'+r+'%22',o)%7Dfunction%20J()%7Blet%20e=document.createElement(%22button%22);e.textContent=%22Close%20(Esc)%22,e.setAttribute(%22type%22,%22button%22),e.setAttribute(%22class%22,%22panel-btn%22),e.addEventListener(%22click%22,()=%3E%7BD()%7D);let%20r=document.createElement(%22button%22);r.textContent=%22Change%20Mode%20(M)%22,r.setAttribute(%22type%22,%22button%22),r.setAttribute(%22class%22,%22panel-btn%22),r.addEventListener(%22click%22,o=%3E%7BK()%7D),a.appendChild(e),a.appendChild(r)%7Dfunction%20K()%7BL?(document.querySelector(%22#WTFocusPanel%22).classList.remove(%22curtainsMode%22),document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22),document.querySelector(%22#WTFocusCurtain%22).setAttribute(%22hidden%22,%22hidden%22),L=!1,P=%22Accessible%20name:%20%22):(document.querySelector(%22#WTFocusPanel%22).classList.add(%22curtainsMode%22),document.querySelector(%22#WTFocusCurtain%22).removeAttribute(%22hidden%22),L=!0,P=%22%22),Q(z),z.focus()%7Dfunction%20D()%7Bdocument.querySelector(%22#WTFocusCurtain%22).remove(),document.querySelector(%22#WTFocusPanel%22).remove(),document.querySelector(%22#panelStyles%22).remove(),document.querySelector(%22#focusStyles%22).remove()%7Dfunction%20Q(e)%7Blet%20r=e.getBoundingClientRect(),o=document.documentElement.scrollTop,n=r.right+R+Y,C=a.offsetHeight,q=o+r.top+C,i=window.innerWidth,c=window.innerHeight;L?document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22):n%3Ei?(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=%22auto%22,a.style.right=i-r.left+R-w+%22px%22,a.classList.add(%22toLeft%22)):(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=r.right+R-w+%22px%22,a.style.right=%22auto%22,a.classList.remove(%22toLeft%22))%7Dconsole.clear(),function()%7Blet%20e=document.createElement(%22style%22);e.setAttribute(%22type%22,%22text/css%22),e.setAttribute(%22id%22,%22panelStyles%22),e.textContent=%22.dupeAccName%20%7Boutline:4px%20dashed%20#CC3300!important;outline-offset:%22+w+%22px!important;overflow:visible;%7D%20.WTFocusTempFocusStyle:focus%20%7Boutline:%22+w+%22px%20solid%20black!important;outline-offset:%22+w+%22px!important;overflow:visible;/*background:yellow!important;color:black!important;*/%7D%20.WTFocusTempFocusStyle.dupeAccName:focus%20%7Boutline-color:#CC3300!important;%7D%20.visually-hidden%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D#WTFocusCurtain%20%7Bbackground:black;position:%20fixed;top:%200;bottom:%200;left:%200;right:%200;z-index:49999%7D%22,document.querySelector(%22body%22).appendChild(e)%7D(),document.querySelector(%22#WTFocusCurtain%22)&&D(),k=!0,p=%22%22,function(e)%7Blet%20r=document.createElement(%22style%22);r.setAttribute(%22type%22,%22text/css%22),r.setAttribute(%22id%22,%22focusStyles%22),r.textContent=%22#WTFocusPanel.error%20%7Bbackground:darkred;%7D%20#WTFocusPanel.warning%20%7Bbackground:#CC3300;%7D%20#WTFocusPanel.curtainsMode.error%20%7Bbackground:black;%7D%20#WTFocusPanel.curtainsMode%20%7Bz-index:50000;position:fixed;top:50%25;left:50%25;transform:translate(-50%25,-50%25);%7D%20#WTFocusPanel.curtainsMode.warning%20%7Bbackground:black;%7D%20#WTFocusPanel%5Bhidden%5D%20%7Bdisplay:none;%7D%20#WTFocusPanel%20*%20%7Btext-align:left%7D%20#WTFocusPanel%20%7Bborder:2px%20solid%20#fff;z-index:1000;text-shadow:none;font-family:sans-serif;display:block;text-align:left;position:%20absolute;z-index:10000;background:%20black;padding:%2020px%2020px;width:%22+e+%22px;font-size:16px;%7D%20#WTFocusPanel%20button%20%7Bfont-weight:bold;background:none;color:#fff;padding:3px%2010px;font-size:14px;border:1px%20solid%20#fff;display:inline-block;margin:10px%201em%20-10px%200;%7D%20#WTFocusPanel%20ul,#WTFocusPanel%20li%20%7Bmargin:0;padding:0;list-style:none%7D%20#WTFocusPanel%20li%20%7Bmargin:3px%200;background:#fff;color:#333;padding:2px%7D%20#WTFocusPanel%20li.outline%20%7Boutline:4px%20solid%20rgb(58,%20190,%2058);outline-offset:-4px;padding:8px%7D%20#WTFocusPanel.error:before%20%7Bbackground:darkred%7D%20#WTFocusPanel.warning:before%20%7Bbackground:#CC3300%7D%20#WTFocusPanel:before%20%7Bcontent:'';display:block;height:20px;width:20px;transform:rotate(45deg);position:absolute;background:#000;left:-12px;top:3px;border:2px%20solid%20#fff;border-right:none;border-top:none;%7D%20#WTFocusPanel.toBottom:before%20%7Btop:auto;bottom:3px%7D%20#WTFocusPanel.toLeft:before%20%7Bleft:auto;right:-12px;border:2px%20solid%20#fff;border-left:none;border-bottom:none;%7D%20#WTFocusPanel.curtainsMode%20%7Boutline:10px%20solid%20orange;%7D%20#WTFocusPanel.curtainsMode:before%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li.visible%20%7Bdisplay:block;%7D%20#WTFocusPanel.curtainsMode%20li%20span%20%7Bdisplay:none!important;%7D%20%22,document.querySelector(%22head%22).appendChild(r)%7D(Y),O.setAttribute(%22id%22,%22WTFocusCurtain%22),O.setAttribute(%22hidden%22,%22hidden%22),document.querySelector(%22body%22).appendChild(O),a.setAttribute(%22id%22,%22WTFocusPanel%22),L&&a.setAttribute(%22class%22,%22curtainsMode%22),a.setAttribute(%22aria-live%22,%22polite%22),a.setAttribute(%22tabindex%22,%22-1%22),a.setAttribute(%22hidden%22,%22hidden%22),a.setAttribute(%22role%22,%22region%22),a.setAttribute(%22aria-label%22,%22Accessibility%20properties%20panel%22),document.querySelector(%22body%22).appendChild(a),window.addEventListener(%22keyup%22,e=%3E%7Be.key===%22Escape%22&&document.querySelector(%22#WTFocusPanel%22)&&D()%7D),window.addEventListener(%22keyup%22,e=%3E%7Be.key.toLowerCase()===%22m%22&&document.querySelector(%22#WTFocusPanel%22)&&K()%7D),J();let%20U=%5B%5D;Array.from(H).forEach(function(e)%7Be.classList.add(%22WTFocusTempFocusStyle%22);let%20r=e.querySelectorAll(%22style%22);Array.from(r).forEach(function(o)%7Bo.remove()%7D),e.addEventListener(%22focus%22,()=%3E%7Blet%20o=e.getAttribute(%22role%22),n=e.tagName.toLowerCase();if(console.clear(),!o)%7Bif(n!=%22article%22&&n!=%22button%22&&n!=%22dialog%22&&n!=%22figure%22&&n!=%22img%22&&n!=%22main%22&&n!=%22math%22%7C%7C(o=n),n==%22summary%22&&(o=%22button%22),n==%22aside%22&&(o=%22complementary%22),n==%22dd%22&&(o=%22definition%22),n==%22html%22&&(o=%22document%22),n!=%22details%22&&n!=%22fieldset%22&&n!=%22optgroup%22%7C%7C(o=%22group%22),n!=%22menu%22&&n!=%22ol%22&&n!=%22ul%22%7C%7C(o=%22list%22),n==%22datalist%22&&(o=%22listbox%22),n==%22li%22&&(o=%22listitem%22),n==%22nav%22&&(o=%22navigation%22),n==%22progress%22&&(o=%22progressbar%22),n==%22hr%22&&(o=%22separator%22),n==%22output%22&&(o=%22status%22),n!=%22dfn%22&&n!=%22dt%22%7C%7C(o=%22term%22),n==%22a%22&&(o=%22link%22),n==%22select%22&&(o=%22listbox%22),n==%22textarea%22&&(o=%22textbox%22),n==%22input%22)%7Blet%20t=e.getAttribute(%22type%22).toLowerCase();t===%22text%22&&(o=%22textbox%22),t===%22range%22&&(o=%22slider%22),t===%22number%22&&(o=%22spinbutton%22),t!==%22checkbox%22&&t!==%22radio%22%7C%7C(o=t),t!==%22button%22&&t!==%22image%22&&t!==%22reset%22&&t!==%22submit%22%7C%7C(o=%22button%22)%7D%7Dz=e,Array.from(H).forEach(function(t)%7Bt.classList.remove(%22dupeAccName%22)%7D);let%20C=!1;m=!1,x=!1;let%20q=e.querySelectorAll(%22img,%20%5Brole='image'%5D%5Baria-label%5D,%20%5Brole='img'%5D%5Baria-label%5D%22);(C=q.length%3E0)&&Array.from(q).forEach(function(t)%7Blet%20d=document.createElement(%22SPAN%22);var%20T,B;d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22data-temp-node%22,%22true%22),t.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+t.getAttribute(%22alt%22)+%22%20%22),t.getAttribute(%22role%22)&&t.getAttribute(%22aria-label%22)&&(d.textContent=%22%20%22+t.getAttribute(%22aria-label%22)+%22%20%22),T=d,(B=t).parentNode.insertBefore(T,B.nextSibling)%7D),setTimeout(function()%7Be.classList.add(%22WTFocusTempFocusStyle%22)%7D,100),p=%22%22;let%20i=e.tagName.toLowerCase(),c=e.getAttribute(%22role%22);c&&(c=e.getAttribute(%22role%22).toLowerCase());let%20Z=%22%3C%22+i+%22%3E%22,_=!1,$=!1;c&&(Z=%22%3C%22+i+'%20role=%22'+c+'%22%3E',(c===%22link%22&&i===%22a%22%7C%7Cc===%22button%22&&i===%22button%22%7C%7Cc===%22image%22&&i===%22img%22%7C%7Cc===%22img%22&&i===%22img%22%7C%7Cc===%22navigation%22&&i===%22nav%22%7C%7Cc===%22heading%22&&(i===%22h1%22%7C%7Ci===%22h2%22%7C%7Ci===%22h3%22%7C%7Ci===%22h4%22%7C%7Ci===%22h5%22%7C%7Ci===%22h6%22))&&(_=!0),(c===%22link%22&&i!==%22a%22%7C%7Cc===%22button%22&&i!==%22button%22%7C%7C(c===%22image%22%7C%7Cc===%22image%22)&&i!==%22img%22%7C%7Cc===%22navigation%22&&i!==%22nav%22%7C%7Cc===%22heading%22&&i!==%22h1%22&&i!==%22h2%22&&i!==%22h3%22&&i!==%22h4%22&&i!==%22h5%22&&i!==%22h6%22)&&($=!0));let%20ee,b=e.textContent,f=e.ariaLabel,S=e.getAttribute(%22aria-labelledby%22),N=e.getAttribute(%22placeholder%22),F=%22%22,g=e.getAttribute(%22value%22),v=e.getAttribute(%22title%22),s=%22%22,y=%22%22,te=!1,oe=!1,u=%22%22,ne=!1;k&&Q(e),b=b.trim();let%20ae=function(t,d)%7Bfor(;(t=t.parentElement)&&!(t.matches%7C%7Ct.matchesSelector).call(t,d););return%20t%7D(e,%22label%22);if(ae&&(te=!0,s=y=ae.textContent.trim()),e.getAttribute(%22id%22))%7Blet%20t=document.querySelector(%22%5Bfor='%22+e.getAttribute(%22id%22)+%22'%5D%22);t&&(oe=!0,y=t.textContent)%7Dif(te%7C%7Coe%7C%7C(y=%22N/A%22),b%7C%7C(b=%22N/A%22),g%7C%7C(g=%22N/A%22),v%7C%7C(v=%22N/A%22),N%7C%7C(N=%22N/A%22),f%7C%7C(f=%22N/A%22),S)%7Blet%20t=(ee=S).split(%22%20%22);t.length%3E1?(Array.from(t).forEach(function(d)%7Bdocument.querySelector(%22#%22+d)?F+=document.querySelector(%22#%22+d).textContent+%22%20%22:F+=%22%5Cu2753%5Cu2753%5Cu2753%20%22%7D),F=F.trim()):F=document.querySelector(%22#%22+ee).textContent%7Delse%20S=%22N/A%22;let%20le=e.querySelectorAll(%22%5Baria-hidden='true'%5D,%5Brole='presentation'%5D%22),M=b;if(le.length%3E0&&(ne=!0,Array.from(le).forEach(function(t)%7Blet%20d=t.textContent;d!==%22%22&&(M=M.split(d).join(%22%20%22))%7D),M=M.trim()),i===%22input%22)%7Blet%20t=e.getAttribute(%22type%22);t===%22submit%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22image%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22cancel%22&&g===%22N/A%22&&(s=%22Cancel%22,u=%22Not%20provided%20(using%20default)%22)%7Dif(v!==%22N/A%22&&(s=v,u=%22title%20attribute%22),g!==%22N/A%22&&(s=g,u=%22value%20attribute%22),N!==%22N/A%22&&(s=N,u=%22placeholder%20attribute%22),b!==%22N/A%22&&(s=M,u=%22Inner%20text%20content%22),y!==%22N/A%22&&(s=y,u=%22%3Clabel%3E%20text%22),f!==%22N/A%22&&(s=f,u=%22aria-label%22),S!==%22N/A%22&&(s=F,u=%22aria-labelledby%22),console.log(%22%25cACTIVE%20ELEMENT:%20%22,%22background:#193c10;color:white;%22),console.log(e),I=e.getAttribute(%22data-dupe%22)===%22true%22,G=I&&s===%22%22,s===%22%22%7C%7CI)%7Bif(s===%22%22&&(x=!0,k&&a.classList.add(%22error%22),l(P+%22No%20accessible%20name!%22,%22%22,h),l(%22Accessible%20Name%20Source:%20N/A%22,%22%22,h)),I&&s!==%22%22)%7Bk&&a.classList.add(%22warning%22);let%20t=document.querySelectorAll(%22%5Bdata-accname='%22+s+%22'%5D%22),d=t.length;l(P,s,h,!1,!0),G%7C%7C(Array.from(t).forEach(function(T)%7BT.classList.add(%22dupeAccName%22)%7D),l(%22Duplicate%20warning!%22,d+%22%20elements%20on%20page%20have%20the%20same%20accessible%20name%22,h)),console.log(%22Elements%20on%20page%20that%20have%20identical%20accessible%20names:%22),Array.from(t).forEach(function(T)%7Bconsole.log(T)%7D),l(%22Accessible%20Name%20Source:%20%22,u,h)%7D%7Delse%20k&&(a.classList.remove(%22error%22),a.classList.remove(%22warning%22)),l(P,s,j,!1,!0),l(%22Accessible%20Name%20Source:%20%22,u,j);x=!1,l(%22HTML%20Element:%20%22,Z,j),l(%22Role:%20%22,o,%22color:#333;background:#fff;%22,!1,!0),k%7C%7Cconsole.log(%22%25cACCESSIBLE%20NAME%20COMES%20FROM:%20%22,%22background:#193c10;color:white;%22),_&&(x=!0,l(%22Superfluous%20%60role%60%20attribute%22,%22%22,h)),$&&(x=!0,l(%22Better%20to%20use%20a%20native%20HTML%20element%22,%22%22,h)),b=b.trim(),y=y.trim(),v=v.trim(),f=f.trim(),S=S.trim(),W(),u===%22placeholder%20attribute%22?(m=!0,l(%22@placeholder:%20%22,N,A,!0)):l(%22@placeholder:%20%22,N,N===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22title%20attribute%22?(m=!0,l(%22@title:%20%22,v,A,!0)):l(%22@title:%20%22,v,v===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22value%20attribute%22?(m=!0,l(%22@value:%20%22,g,A,!0)):l(%22@value:%20%22,g,g===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22Inner%20text%20content%22?(m=!0,l(C?%22Inner%20text%20content%20(includes%20image%20alt):%20%22:%22Inner%20text%20content:%20%22,b,A,!0),ne&&l(%22!%20elements%20hidden%20to%20AT%20removed%22,%22%22,A)):l(%22Text%20Content:%20%22,b,b===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22%3Clabel%3E%20text%22?(m=!0,l(%22Visible%20%60label%60%20text:%20%22,y,A,!0)):l(%22Visible%20%60label%60%20text:%20%22,y,y===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-label%22?f===b?(x=!0,l(%22%60aria-label%60%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-label%20value:%20%22,f,A,!0)):l(%22@aria-label%20value:%20%22,f,f===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-labelledby%22?F===b?(x=!0,l(%22%60aria-labelledby%60%20source%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-labelledby%20value:%20%22,S,A,!0),l(%22@aria-labelledby%20sources:%20%22,F,A)):(l(%22@aria-labelledby%20value:%20%22,S,%22color:#333;background:#fff;%22),l(%22@aria-labelledby%20sources:%20%22,%22N/A%22,%22color:#333;background:#fff;%22)),k&&(document.querySelector(%22#WTFocusPanel%22).innerHTML='%3Cul%20role=%22list%22%3E'+p+%22%3C/ul%3E%22,document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22hidden%22),J());let%20se=document.querySelectorAll(%22%5Bdata-temp-node%5D%22);Array.from(se).forEach(function(t)%7Bt.remove()%7D),e.setAttribute(%22data-accname%22,s),X%7C%7Cfunction(t,d)%7Blet%20T=!1;Array.from(U).forEach(function(B)%7BB===t&&(T=!0)%7D),T?(d.setAttribute(%22data-dupe%22,%22true%22),document.querySelector(%22%5Bdata-accname='%22+t+%22'%5D%22).setAttribute(%22data-dupe%22,%22true%22)):U.push(t)%7D(s,e)%7D)%7D);let%20X=!1;(function()%7Bif(V=document.activeElement,Array.from(H).forEach(function(e)%7Bdocument.activeElement===e&&e.blur(),e.focus()%7D),X=!0,V.tagName===%22BODY%22)%7Blet%20e=document.querySelector(%22body%22);e.setAttribute(%22tabindex%22,%22-1%22),e.focus(),document.querySelector(%22#WTFocusPanel%22).setAttribute(%22hidden%22,%22hidden%22)%7Delse%20V.focus();console.clear()%7D)(),console.log(%22had%20focus%20=%20%22,z)%7Dre()%7D)();%7D)();%0A" }, { + "file": "youtube-uc-id.js", "bookmarklet": "Get YouTube UC ID", "description": "Fetches UC ID while on a YouTube profile page", - "file": "youtube-uc-id.js", - "pageTest": false, "source": "Jason Morris", "sourceUrl": "https://jasonmorris.com", "tags": [ @@ -807,6 +812,7 @@ "bmxfeed", "YouTube" ], + "pageTest": false, "dist": "javascript:void%20(()=%3E%7Bvar%20e=document.querySelector(%22link%5Brel=canonical%5D%22).getAttribute(%22href%22).replace(%22https://www.youtube.com/channel/%22,%22%22);e&&prompt(%22UC%20ID:%22,e);%7D)();%0A" } ] \ No newline at end of file diff --git a/data/bookmarks.html b/data/bookmarks.html index 5fd86a5..e988f1e 100644 --- a/data/bookmarks.html +++ b/data/bookmarks.html @@ -33,12 +33,12 @@

Bookmarks Menu

Image info
Images
Inline styles -
Isolator +
Isolator
Keyboard visualizer
Language of page/parts
Links
Markdown link -
Non-underlined links +
Non-underlined links
Page link
Parsing only
Placeholder contrast checker @@ -53,7 +53,7 @@

Bookmarks Menu

Test local JS
Text spacing
Text zoom 200% -
Titles +
Titles
a11y.css
ANDI
ARIA usage @@ -67,6 +67,6 @@

Bookmarks Menu

Viewport
Open 1280x1024
Open 320x256 -
WTFocus +
WTFocus
Get YouTube UC ID

\ No newline at end of file From b881b31319fcc1ec38a40ecf3da251b63501abbb Mon Sep 17 00:00:00 2001 From: Jason Morris Date: Wed, 31 Dec 2025 14:24:57 -0500 Subject: [PATCH 03/17] Update README with new bookmarklet workflow --- README.md | 34 +++++++++++++++++++++++++++++----- 1 file changed, 29 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 3387121..3d3e338 100644 --- a/README.md +++ b/README.md @@ -13,11 +13,35 @@ Tools for the browser. ## Adding a bookmarklet -1. Edit [`data/bookmarklets.json`](/data/bookmarklets.json) and add a new entry, following the schema used on the rest of the file -2. Create a new JS file (and optionally a test HTML page) for the new entry -3. Add code -4. Run `npm start` to lint JS, build data file, and generate static site -5. New entry will be added to the table of bookmarklets in `index.html` +1. Create a new JS file in `bookmarklets/` with a JSDoc metadata block at the top: + ```javascript + /** + * @bookmarklet My Bookmarklet Name + * @description What the bookmarklet does + * @author Your Name + * @authorUrl https://example.com + * @tags accessibility, utility + * @pageTest true + */ + (function() { + // Your bookmarklet code here + })(); + ``` +2. Optionally create a test HTML page in `bookmarklets/` with the same base name +3. Run `npm start` to lint JS, build data files, and generate the static site +4. The new entry will be added to the table of bookmarklets in `index.html` + +### Metadata fields + +| Field | Required | Description | +|-------|----------|-------------| +| `@bookmarklet` | Yes | Display name of the bookmarklet | +| `@description` | Yes | Brief description of what it does | +| `@author` | No | Original author's name | +| `@authorUrl` | No | Link to author or source | +| `@tags` | No | Comma-separated list of tags | +| `@auditing` | No | Set to `true` for auditing favorites | +| `@pageTest` | No | `true`, `false`, or `self` for test page behavior | ## Related web tools From bbda97d956caba6e81be923cddcfb360e1064173 Mon Sep 17 00:00:00 2001 From: Jason Morris Date: Wed, 31 Dec 2025 14:34:47 -0500 Subject: [PATCH 04/17] Remove generated files from git --- data/auditing.json | 299 --------------- data/bookmarklets.json | 818 ----------------------------------------- 2 files changed, 1117 deletions(-) delete mode 100644 data/auditing.json delete mode 100644 data/bookmarklets.json diff --git a/data/auditing.json b/data/auditing.json deleted file mode 100644 index 7b446a7..0000000 --- a/data/auditing.json +++ /dev/null @@ -1,299 +0,0 @@ -[ - { - "file": "auto-complete.js", - "bookmarklet": "Autocomplete", - "description": "Display all fields with autocomplete", - "source": "Rachele DiTullio", - "sourceUrl": "https://racheleditullio.com/blog/2023/11/autocomplete-accessibility-bookmarklet/", - "tags": [ - "1.3.5 Identify Input Purpose (AA)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20o=document.querySelectorAll(%22.autocomplete-info%22);if(o.length%3E0)o.forEach(t=%3E%7Bt.remove()%7D);else%7Blet%20t=document.querySelectorAll(%22input%5Bautocomplete%5D%22);t.length%3E0?t.forEach(l=%3E%7Blet%20i=l.getAttribute(%22autocomplete%22),n=l.getBoundingClientRect(),e=document.createElement(%22div%22);e.classList.add(%22autocomplete-info%22),e.style.position=%22absolute%22,e.style.top=window.scrollY+n.top+%22px%22,e.style.left=window.scrollX+n.left+%22px%22,e.style.backgroundColor=%22yellow%22,e.style.color=%22black%22,e.style.padding=%225px%22,e.style.border=%222px%20solid%20#000%22,e.style.zIndex=%229999%22,e.innerHTML=%60autocomplete=%3Cstrong%3E$%7Bi%7D%3C/strong%3E%60,document.body.appendChild(e)%7D):alert(%22No%20input%20fields%20with%20autocomplete%20attribute%20found%20on%20this%20page.%22)%7D%7D)();%7D)();%0A" - }, - { - "file": "buttons.js", - "bookmarklet": "Buttons", - "description": "Display all buttons", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20k()%7Bconsole.clear();function%20B(e,i)%7Bi.parentNode.insertBefore(e,i.nextSibling)%7Dfunction%20m(e)%7Blet%20i=window.getComputedStyle(e);return%20i.display===%22none%22%7C%7Ci.opacity===0%7C%7Ci.clipPath===%22inset(100%25)%22&&i.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ci.height===%221px%22&&i.width===%221px%22&&i.overflow===%22hidden%22%7Dfunction%20C(e)%7Blet%20i=window.getComputedStyle(e);i.position===%22absolute%22&&i.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),i.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),i.display===%22none%22&&(e.style.display=%22block%22),i.opacity===0&&(e.style.opacity=1)%7Dlet%20n=%22%22,r=%22%22,S=document.querySelectorAll(%22button,%5Brole=button%5D,input%5Btype=button%5D%22),c=1,g,y=0,f=%22%22,u=%22%22;Array.from(S).forEach(function(e)%7Blet%20i=document.createElement(%22div%22);i.appendChild(e.cloneNode(!0)),f=i.innerHTML;let%20b=!1,t=%22%22,w=e.querySelectorAll(%22img%22),o=!1,h=!1;b=w.length%3E0;let%20x=e.querySelector(%22%5Baria-hidden=true%5D%22);x&&x.classList.add(%22remove-from-accname%22),b&&Array.from(w).forEach(function(s)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),s.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+s.getAttribute(%22alt%22)+%22%20%22),B(d,s)%7D),e.setAttribute(%22data-button-ref%22,c);let%20l=e.textContent,A=e.querySelector(%22.remove-from-accname%22);A&&A.remove();let%20a=e.textContent;if(e.getAttribute(%22aria-label%22)&&(a=e.getAttribute(%22aria-label%22),t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-label%3C/code%3E.%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0,a.trim().toLowerCase().indexOf(l.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-label%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')),e.getAttribute(%22aria-labelledby%22))%7Blet%20s=e.getAttribute(%22aria-labelledby%22);s=s.replace(/:/g,%22%5C%5C:%22);let%20d=s.split(%22%20%22);d.length%3E1?(a=%22%22,Array.from(d).forEach(function(v)%7Bdocument.querySelector(%22#%22+v)?a+=document.querySelector(%22#%22+v).textContent+%22%20%22:a+=%22**%20aria-labelledby%20source%20is%20missing%20**%22%7D),a=a.trim(),t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0):(s=e.getAttribute(%22aria-labelledby%22),s=s.replace(/:/g,%22%5C%5C:%22),document.querySelector(%22#%22+s)?a=document.querySelector(%22#%22+s).textContent:a+=%22**%20aria-labelledby%20source%20is%20missing%20**%22,t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0),a.trim().toLowerCase().indexOf(l.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-labelledby%20sources%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')%7Dm(e)&&(C(e),m(e)?t+=%22Button%20is%20hidden%3Cbr%3E%22:t+=%22Button%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),b&&(t+=%22%5Cu%7B1F304%7D%20Image%20button%3Cbr%3E%22),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)!==l&&(t+=%22-%20button%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20different%20from%20text%20content.%22,a!==%22%22&&(t+='This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E'),t+=%22%3Cbr%3E%22,o=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)===l&&(t+='-%20button%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20the%20same%20as%20the%20text%20content%20and%20therefore%20adds%20no%20extra%20useful%20information/context.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E',o=!0),e.tagName===%22BUTTON%22&&(e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22Button%20has%20a%20%3Ccode%3Etabindex%3C/code%3E%20but%20it%20is%20not%20needed%20because%20the%20%3Ccode%3Ebutton%3C/code%3E%20is%20natively%20focusable%3Cbr%3E%22),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Button%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',o=!0),e.getAttribute(%22role%22)===%22button%22&&(t+=%22Button%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Not%20needed%20as%20it%20is%20a%20%3Ccode%3Ebutton%3C/code%3E%20element%20that%20is%20a%20button%20by%20default%3Cbr%3E%22),e.getAttribute(%22aria-hidden%22)!==%22true%22&&e.getAttribute(%22tabindex%22)===%22-1%22&&(t+=%22-%20%3Ccode%3E<button>%3C/code%3E%20has%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%20which%20means%20it%20will%20not%20be%20keyboard-operable%3Cbr%3E%22,o=!0),e.getAttribute(%22aria-hidden%22)===%22true%22&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+='-%20%3Ccode%3E<button>%3C/code%3E%20has%20%3Ccode%3Earia-hidden=%22true%22%3C/code%3E%20but%20can%20still%20be%20focused%20by%20keyboard%20user%20as%20it%20does%20not%20have%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E',o=!0),e.getAttribute(%22role%22)&&e.getAttribute(%22role%22)!==%22button%22&&(t+='-%20%3Ccode%3E<button>%3C/code%3E%20has%20a%20%3Ccode%3Erole%3C/code%3E%20set%20that%20is%20not%20%3Ccode%3Ebutton%3C/code%3E.%20It%20is%20set%20to%20%22'+e.getAttribute(%22role%22)+'%22.%20This%20overrides%20the%20native%20role%20and%20will%20likely%20confused%20assistive%20tech%20users%3Cbr%3E',o=!0)),e.tagName===%22A%22&&(!e.getAttribute(%22href%22)&&!e.getAttribute(%22tabindex%22)&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E%20element,%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E%20or%20%3Ccode%3Etabindex%3C/code%3E,%20%20and%20therefore%20is%20not%20focusable%3Cbr%3E%22,o=!0),!e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E%20element,%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20but%20is%20focusable%20because%20it%20has%20been%20provided%20with%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E%22,o=!0),e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E.%20It%20is%20focusable%20because%20there%20is%20a%20%3Ccode%3Etabindex%3C/code%3E%20present%3Cbr%3E%22,o=!0),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Button%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',o=!0)),e.tagName!==%22BUTTON%22&&e.tagName!==%22A%22&&e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E%20but%20is%20not%20a%20%3Ccode%3Ebutton%3C/code%3E%20element.%22,e.getAttribute(%22tabindex%22)===%22-1%22?t+=%22%3Cbr%3E-%20%3Cstrong%3ENote%3C/strong%3E:%20this%20button%20has%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%20and%20will%20not%20be%20keyboard-focusable.%22:t+=%22Check%20that%20it%20is%20keyboard-operable%20(should%20activate%20with%20%3Ckbd%3EEnter%3C/kbd%3E%20and%20%3Ckbd%3ESpace%3C/kbd%3E%20key)%3Cbr%3E%22,o=!0),a===%22%22?(e.getAttribute(%22title%22)?a=e.getAttribute(%22title%22):a=%22%5Cu203C%5CuFE0F%20Empty%20button%22,l=%22%5Cu203C%5CuFE0F%20Empty%20button%22,t+=%22%5Cu203C%5CuFE0F%20Empty%20button%3Cbr%3E%22,h=!0):l.trim()===%22%22&&(l=%22%5Cu203C%5CuFE0F%20No%20visible%20text%20on%20button%22),b&&a===%22%5Cu203C%5CuFE0F%20Empty%20button%22&&(t+=%22%20-%20image%20is%20missing%20alternative%20text%20content%3Cbr%3E%22),h&&(o=!1),r+=%22%3Ctr%22,r+='%20data-button-ref=%22'+c+'%22',o&&(r+='%20class=%22issue%20warn%22'),h&&(r+='%20class=%22issue%20err%22'),r+=%22%3E%22,e.tagName===%22BUTTON%22?g=%22%3Ccode%3E<button>%3C/code%3E%22:g='%3Ccode%3Erole=%22button%22%3C/code%3E',r+=%22%3Ctd%3E%22+g+%22%3C/td%3E%22,r+=%22%3Ctd%3E%22+l+%22%3C/td%3E%22,r+=%22%3Ctd%3E%22+a,a.trim()!==l.trim()&&l.trim()!==%22%22&&(r+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),r+=%22%3C/td%3E%22,r+=%22%3Ctd%3E%22,o&&(r+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20button%3C/div%3E'),h&&(r+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20button%3C/div%3E'),u=%22Button%20'%22+l.trim()+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+f+%60%0A---------------%0A%60,r+=t+'%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+c+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+c+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+f+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',r+='%3Ctd%3E%3Cbutton%20data-button-ref=%22'+c+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',r+=%22%3C/tr%3E%22,c++,(o%7C%7Ch)&&y++,h&&(u=u.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(u))%7D),n='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkgreen;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:button,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20buttons%20on%20this%20page.%3C/h1%3E',n+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20buttons%20where%20there%20*may*%20be%20issues%20('+y+%22%20found)%3C/label%3E%22,n+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20buttons%20on%20page%3C/button%3E',n+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20buttons%20(<button>%20or%20elements%20with%20role=%22button%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3EButton%20type%3C/th%3E%3Cth%20scope=%22col%22%3EButton%20text%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+r+%22%3C/tbody%3E%3C/table%3E%22,n+=%22%3Cscript%3Efunction%20showbtns()%7B%22,n+=%22var%20refWindow=window.opener;%22,n+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20buttonToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BbuttonToHighlight=%22%5Bdata-button-ref='%22%20+%20highlightButton.getAttribute(%22data-button-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(buttonToHighlight).focus();refWindow.document.querySelector(buttonToHighlight).style.outline=%224px%20dashed%20darkgreen%22;refWindow.document.querySelector(buttonToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(buttonToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,n+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',n+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',n+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7Bshowbtns();%7D);%3C%5C/script%3E';let%20p=window.open(%22%22,%22popUpWinButtons%22,%22height=800,width=1000%22);p.document.open(),p.document.write(n),p.document.close()%7Dk()%7D)();%7D)();%0A" - }, - { - "file": "character-keys.js", - "bookmarklet": "Character key shortcuts", - "description": "Test all printable character shortcut keys", - "source": "Detlev Fischer", - "sourceUrl": "http://3needs.org/en/testing/code/kb-shortcuts.html", - "tags": [ - "2.1.4 Character Key Shortcuts (A)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e,t=32,o=8365;n();function%20n()%7Bconsole.log(%22pressed:%20%22+t+%22:%20%22+String.fromCharCode(t)),e=document.createEvent(%22Event%22),e.initEvent(%22keydown%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),e=document.createEvent(%22Event%22),e.initEvent(%22keypress%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),e=document.createEvent(%22Event%22),e.initEvent(%22keyup%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),t++,t%3Co&&(t==127&&(t=161),t==192&&(t=8364),window.setTimeout(n,20))%7D%7D)();%7D)();%0A" - }, - { - "file": "find-duplicate-aria-roles.js", - "bookmarklet": "Find Duplicate ARIA Roles", - "description": "Roles appearing more than once for banner, contentinfo, and main", - "source": "Adrian Roselli", - "sourceUrl": "https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#ARIAdupes", - "tags": [ - "accessibility", - "HTML" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e=document.createElement(%22style%22),n;document.head.appendChild(e),n=e.sheet,n.insertRule(%22*%5Brole=main%5D:nth-of-type(n+2),*%5Brole=banner%5D:nth-of-type(n+2),*%5Brole=contentinfo%5D:nth-of-type(n+2),main:nth-of-type(n+2)%7Bborder:2px%20dotted%20#f00%20!important;background-color:#f00;%7D%22,0)%7D)();%7D)();%0A" - }, - { - "file": "focus-everything.js", - "bookmarklet": "Focus everything", - "description": "A technique for testing 1.3.2 Meaningful Sequence a tab path visualizer", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "1.3.2 Meaningful Sequence (A)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7Bdocument.querySelectorAll(%22body%20*%22).forEach(function(t)%7Bt.setAttribute(%22tabindex%22,%220%22)%7D);%7D)();%0A" - }, - { - "file": "force-focus.js", - "bookmarklet": "Force focus indicator", - "description": "Adds a 4 pixel solid orange outline around all focusable elements", - "source": "Paul J. Adam", - "sourceUrl": "https://pauljadam.com/bookmarklets/focus.html", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7Bvar%20e=document.createElement(%22style%22),t=document.createTextNode(%22a:focus,%20*:focus%20%7B%20outline:%204px%20solid%20orange%20!important;%20outline-offset:1px%20!important;%20%7D%22),n=document.getElementsByTagName(%22head%22);e.appendChild(t);n%5B0%5D.appendChild(e);%7D)();%0A" - }, - { - "file": "headings-console.js", - "bookmarklet": "Document outline in console", - "description": "Display level of all page headings in console", - "source": "Mu-An Chiou", - "sourceUrl": "https://github.com/muan/headings", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bvar%20a=%22%22;for(let%20t%20of%20document.querySelectorAll(%22h1,%20h2,%20h3,%20h4,%20h5,%20h6%22))%7Blet%20e=r(t);if(i(t)&&(t.offsetHeight%3E0%7C%7Ct.offsetWidth)&&e)%7Blet%20n=parseInt(t.tagName.match(/%5Cd/)%5B0%5D);a+=new%20Array((n-1)*2).fill(%22-%22).join(%22%22)+t.tagName.toLowerCase()+%22:%20%22+e+%60%0A%60%7D%7Dconsole.log(a);function%20r(t)%7Blet%20e=t.getAttribute(%22aria-labelledby%22);return(t.getAttribute(%22alt%22)%7C%7Ct.getAttribute(%22aria-label%22)%7C%7Ce&&o(document.getElementById(e))%7C%7Co(t)).trim()%7Dfunction%20o(t)%7Blet%20e=%22%22;for(let%20n%20of%20t.childNodes)e+=n%20instanceof%20HTMLElement?r(n):n.textContent%7C%7C%22%22;return%20e%7Dfunction%20i(t)%7Breturn!t.closest('%5Baria-hidden=%22%22%5D,%20%5Baria-hidden=%22true%22%5D')%7D%7D)();%0A" - }, - { - "file": "headings.js", - "bookmarklet": "Headings", - "description": "Display level of all page headings", - "source": "Jonathan Avila", - "sourceUrl": "https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/headings.js", - "tags": [ - "1.3.1 Info and Relationships (A)", - "2.4.6 Headings and Labels (AA)" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bfunction%20n(o)%7Bs(o);for(var%20a=%5B%22frame%22,%22iframe%22%5D,e=0;e%3Ca.length;e++)for(var%20r=o.getElementsByTagName(a%5Be%5D),l=0;l%3Cr.length;l++)try%7Bn(r%5Bl%5D.contentWindow.document)%7Dcatch%7B%7D%7Dfunction%20s(o)%7Bfor(var%20a=o.querySelectorAll(%22h1,h2,h3,h4,h5,h6,%5Brole='heading'%5D%22),e=0;e%3Ca.length;e++)%7Bvar%20r=a%5Be%5D.tagName+%22%20%22;a%5Be%5D.hasAttribute(%22role%22)&&(r=r+%22role=%22+a%5Be%5D.getAttribute(%22role%22)+%22%20%22),a%5Be%5D.hasAttribute(%22aria-level%22)&&(r=r+%22aria-level=%22+a%5Be%5D.getAttribute(%22aria-level%22));var%20l=document.createTextNode(r),t=document.createElement(%22span%22);t.style.color=%22black%22,t.style.backgroundColor=%22gold%22,t.style.fontSize=%22small%22,t.style.border=%22thin%20solid%20black%22,t.style.position=%22absolute%22,t.appendChild(l),a%5Be%5D.parentNode.insertBefore(t,a%5Be%5D),a%5Be%5D.style.border=%22thin%20solid%20magenta%22%7D%7Dn(document);%7D)();%0A" - }, - { - "file": "horizontal-scroll.js", - "bookmarklet": "Horizontal scroll", - "description": "Alert when a horizontal scrollbar appears", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20e=document.documentElement.clientWidth,o=!1;function%20n()%7Blet%20t=document.documentElement.clientWidth,i=document.body.scrollWidth%3Edocument.documentElement.clientWidth;i&&!o&&t%3Ce?(console.log(%60%25cHorizontal%20scrollbar%20detected!%25c%0AWindow%20width:%20%60+t+%60px%0AContent%20width:%20%60+document.body.scrollWidth+%60px%0AOverflow:%20%60+(document.body.scrollWidth-t)+%22px%22,%22color:%20#ff0000;%20font-size:%2014px;%20font-weight:%20bold;%22,%22color:%20inherit;%20font-size:%20inherit;%22),o=!0):i%7C%7C(o=!1),e=t%7Dwindow.addEventListener(%22resize%22,n),n(),console.log(%60%25cHorizontal%20scrollbar%20detector%20activated!%25c%0AResize%20the%20window%20to%20test.%60,%22color:%20#4CAF50;%20font-size:%2014px;%20font-weight:%20bold;%22,%22color:%20inherit;%20font-size:%20inherit;%22)%7D)();%7D)();%0A" - }, - { - "file": "images.js", - "bookmarklet": "Images", - "description": "Display all images", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "1.1.1 Non-text Content (A)", - "1.4.5 Images of Text (A)", - "2.4.4 Link Purpose (In Context) (A)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20f(e)%7Blet%20r=window.getComputedStyle(e);return%20r.display===%22none%22%7C%7Cr.opacity===0%7C%7Cr.clipPath===%22inset(100%25)%22&&r.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Cr.height===%221px%22&&r.width===%221px%22&&r.overflow===%22hidden%22%7Dfunction%20T(e)%7Blet%20r=window.getComputedStyle(e);r.position===%22absolute%22&&r.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),r.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),r.display===%22none%22&&(e.style.display=%22block%22),r.opacity===0&&(e.style.opacity=1)%7Dlet%20l=%22%22,o=%22%22,k=document.querySelectorAll(%22img,%5Brole=img%5D%22),d=1,u,m=0,b=%22%22,c=%22%22;Array.from(k).forEach(function(e)%7Blet%20r=document.createElement(%22div%22);r.appendChild(e.cloneNode(!0)),b=r.innerHTML;let%20t=%22%22,p=!1,y=!1,a=!1,n=!1,w=e.querySelector(%22%5Baria-hidden=true%5D%22);w&&w.classList.add(%22remove-from-accname%22),e.setAttribute(%22data-img-ref%22,d);let%20i=e.getAttribute(%22alt%22);i===null?(i=%22NO_ALT_ATTRIBUTE%22,p=!0):i===%22%22&&(i=%22EMPTY_ALT_ATTRIBUTE%22,y=!0);let%20s=i,A=e.getAttribute(%22src%22);if(f(e)&&(T(e),f(e)?t+=%22img%20is%20hidden.%3Cbr%3E%22:t+=%22img%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page.%3Cbr%3E%22),p&&(e.getAttribute(%22role%22)===%22img%22&&e.tagName!==%22IMG%22%7C%7C(t=%22-%20img%20has%20no%20%3Ccode%3Ealt%3C/code%3E%20attribute.%3Cbr%3E%22,n=!0)),y&&(t=%22-%20img%20has%20an%20empty%20%3Ccode%3Ealt%3C/code%3E%20attribute.%20This%20will%20hide%20it%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),(e.getAttribute(%22role%22)===%22presentation%22%7C%7Ce.getAttribute(%22role%22)===%22none%22)&&(t+=%22-%20img%20has%20a%20%3Ccode%3Erole%3C/code%3E%20set%20('%22+e.getAttribute(%22role%22)+%22')%20that%20will%20hide%20it%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),e.getAttribute(%22aria-hidden%22)===%22true%22&&(t+=%22-%20img%20has%20an%20%3Ccode%3Earia-hidden=true%3C/code%3E,%20so%20it%20will%20be%20hidden%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),e.getAttribute(%22title%22)&&(i===%22EMPTY_ALT_ATTRIBUTE%22?(t+=%22-%20img%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20AND%20an%20empty%20%3Ccode%3Ealt%3C/code%3E%20attribute.%20Because%20of%20the%20empty%20alt,%20the%20image%20will%20be%20hidden%20to%20AT,%20so%20the%20title%20attribute%20is%20not%20used/exposed.%3Cbr%3E%22,a=!1,n=!0):(t+='-%20img%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20attribute.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users.%3Cbr%3E',p?n=!0:a=!0)),e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20img%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Check%20that%20it%20behaves%20like%20a%20%3Ccode%3Ebutton%3C/code%3E.%3Cbr%3E%22,a=!0),e.getAttribute(%22role%22)===%22img%22&&(t+=%22-%20Not%20an%20inline%20img,%20so%20no%20%3Ccode%3Ealt%3C/code%3E%20attribute.%3Cbr%3E%22),e.getAttribute(%22role%22)===%22img%22&&e.getAttribute(%22alt%22)!==null&&e.tagName!==%22IMG%22&&(t+=%22-%20Background%20image%20has%20an%20%3Ccode%3Ealt%3C/code%3E%20attribute%20specified,%20but%20cannot%20be%20applied%20to%20this%20element;%20can%20only%20be%20applied%20to%20%3Ccode%3Eimg%3C/code%3E%20element.%3Cbr%3E%22,a=!1,n=!0),e.tagName!==%22IMG%22&&e.getAttribute(%22role%22)===%22img%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Eimg%3C/code%3E%20but%20is%20not%20an%20%3Ccode%3Eimg%3C/code%3E%20element.%3Cbr%3E%22),e.getAttribute(%22role%22)===%22img%22)%7Blet%20h=!1;if(e.tagName!==%22IMG%22)%7Blet%20I=e.currentStyle%7C%7Cwindow.getComputedStyle(e,!1),S=I.backgroundImage.slice(4,-1).replace(/%22/g,%22%22);if(e.getAttribute(%22aria-label%22)!==null&&(h=!0,i=e.getAttribute(%22aria-label%22),s=i,t+=%22-%20Accessible%20name%20provided%20by%20an%20%3Ccode%3Earia-label%3C/code%3E%20attribute.%3Cbr%3E%22,a=!1),!h&&e.getAttribute(%22aria-labelledby%22)!==null)%7Bh=!0;let%20x=e.getAttribute(%22aria-labelledby%22).split(%22%20%22);x.length%3E1?(i=%22%22,Array.from(x).forEach(function(B)%7Bi+=document.querySelector(%22#%22+B).textContent+%22%20%22%7D),i=i.trim(),t+=%22-%20Image%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20image%20on%20screen%3Cbr%3E%22,a=!0):(i=document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22)).textContent,t+=%22-%20Image%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20image%20on%20screen%3Cbr%3E%22,a=!0),s=i%7D%7Dh%7C%7C(t+=%22-%20Image%20has%20no%20accessible%20name%20provided.%20It%20must%20be%20set%20using%20%3Ccode%3Earia-labelledby%3C/code%3E%20or%20%3Ccode%3Earia-label%3C/code%3E%20(not%20%3Ccode%3Ealt%3C/code%3E)%3Cbr%3E%22,n=!0)%7Ds===%22%22&&(e.getAttribute(%22title%22)?s=e.getAttribute(%22title%22):s=%22%5Cu203C%5CuFE0F%20No%20alt,%20no%20title%22,t+=%22%5Cu203C%5CuFE0F%20No%20alt.%3Cbr%3E%22,n=!0),n&&(a=!1),o+=%22%3Ctr%22,o+='%20data-img-ref=%22'+d+'%22',a&&(o+='%20class=%22issue%20warn%22'),n&&(o+='%20class=%22issue%20err%22'),o+=%22%3E%22,e.tagName===%22IMG%22?u=%22%3Ccode%3E<img>%3C/code%3E%22:u='%3Ccode%3Erole=%22img%22%3C/code%3E',(s===%22NO_ALT_ATTRIBUTE%22%7C%7Cs===%22EMPTY_ALT_ATTRIBUTE%22)&&(i=%22%22,s=%22%22),o+=%22%3Ctd%3E%22+u+%22%3C/td%3E%22,o+='%3Ctd%3E%3Cimg%20src=%22'+A+'%22%20alt=%22%22%20style=%22max-width:200px;max-height:200px;%22%3E%3C/td%3E',o+=%22%3Ctd%3E%22+s,s.trim()!==i.trim()&&i.trim()!==%22%22&&(o+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),o+=%22%3C/td%3E%22,s.trim()!==i.trim()&&s.trim().toLowerCase()===i.trim().toLowerCase()&&(t+=%22-%20Same%20text%20but%20case%20difference%20noted%20(likely%20not%20an%20issue)%22),o+=%22%3Ctd%3E%22,a&&(o+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20image%3C/div%3E'),n&&(o+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20image%3C/div%3E',c=%22Image%20'%22+A+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+b+%60%0A---------------%0A%60),o+=t+'%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+d+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+d+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+b+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',o+='%3Ctd%3E%3Cbutton%20data-img-ref=%22'+d+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',o+=%22%3C/tr%3E%22,d++,(a%7C%7Cn)&&(m++,c=c.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(c))%7D),l='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkred;%7D;div.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:img,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20images%20on%20this%20page.%3C/h1%3E',l+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20images%20where%20there%20*may*%20be%20issues%20('+m+%22%20found)%3C/label%3E%22,l+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20images%20on%20page%3C/button%3E',l+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20images%20(img%20elements%20or%20elements%20with%20role=%22img%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3EImage%20type%3C/th%3E%3Cth%3EImage%20thumbnail%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+o+%22%3C/tbody%3E%3C/table%3E%22,l+=%22%3Cscript%3Efunction%20showImages()%7B%22,l+=%22var%20refWindow=window.opener;%22,l+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20imgToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BimgToHighlight=%22%5Bdata-img-ref='%22%20+%20highlightButton.getAttribute(%22data-img-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(imgToHighlight).setAttribute(%22tabindex%22,%22-1%22);refWindow.document.querySelector(imgToHighlight).focus();refWindow.document.querySelector(imgToHighlight).style.outline=%2210px%20solid%20darkred%22;refWindow.document.querySelector(imgToHighlight).style.outlineOffset=%22-10px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(imgToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,l+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',l+='var%20imgsToCopy=document.querySelectorAll(%22.imgToCopy%22);Array.from(imgsToCopy).forEach(imgToCopy%20=%3E%20%7BimgToCopy.addEventListener(%22focus%22,%20e%20=%3E%20%7BimgToCopy.select();%7D);%7D);',l+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',l+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowImages();%7D);%3C%5C/script%3E';let%20g=window.open(%22%22,%22popUpWinImages%22,%22height=800,width=1000%22);g.document.open(),g.document.write(l),g.document.close()%7Dv()%7D)();%7D)();%0A" - }, - { - "file": "language.js", - "bookmarklet": "Language of page/parts", - "description": "Display all lang attributes on page", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "3.1.1 Language of Page (A)", - "3.1.2 Language of Parts (AA)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7Bvar%20a=document.querySelectorAll(%22%5Blang%5D%22),g=document.querySelector(%22html%5Blang%5D%22),t=%22%22;g?t+=%22The%20page%20lang%20attribute%20is%20%22+g.getAttribute(%22lang%22)+%60%0A%60:t+=%60Page%20is%20missing%20lang%20attribute%0A%60;for(e=0;e%3Ca.length;e++)t+=a%5Be%5D.tagName+%22%20tag%20has%20%22+a%5Be%5D.getAttribute(%22lang%22)+%60%0A%60;var%20e;alert(t);%7D)();%0A" - }, - { - "file": "links.js", - "bookmarklet": "Links", - "description": "Display all links", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20L(e,i)%7Bi.parentNode.insertBefore(e,i.nextSibling)%7Dfunction%20y(e)%7Blet%20i=window.getComputedStyle(e);return%20i.display===%22none%22%7C%7Ci.opacity===0%7C%7Ci.clipPath===%22inset(100%25)%22&&i.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ci.height===%221px%22&&i.width===%221px%22&&i.overflow===%22hidden%22%7Dfunction%20C(e)%7Blet%20i=window.getComputedStyle(e);i.position===%22absolute%22&&i.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),i.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),i.display===%22none%22&&(e.style.display=%22block%22),i.opacity===0&&(e.style.opacity=1)%7Dlet%20f,n=%22%22,o=%22%22,B=document.querySelectorAll(%22a,%5Brole=link%5D%22),l=1,p,w=0,g=%22%22,h=%22%22;Array.from(B).forEach(function(e)%7Blet%20i=document.createElement(%22div%22);i.appendChild(e.cloneNode(!0)),g=i.innerHTML;let%20u=!1,t=%22%22,A=e.querySelectorAll(%22img%22),a=!1,c=!1;u=A.length%3E0;let%20x=e.querySelector(%22%5Baria-hidden=true%5D%22);x&&x.classList.add(%22remove-from-accname%22),u&&Array.from(A).forEach(function(b)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),b.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+b.getAttribute(%22alt%22)+%22%20%22),L(d,b)%7D),e.setAttribute(%22data-link-ref%22,l);let%20s=e.textContent,k=e.querySelector(%22.remove-from-accname%22);k&&k.remove();let%20r=e.textContent;if(e.getAttribute(%22aria-label%22)&&(r=e.getAttribute(%22aria-label%22),t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-label%3C/code%3E%22,s.trim()!==%22%22&&(t+=%22%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22),a=!0,r.trim().toLowerCase().indexOf(s.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-label%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')),e.getAttribute(%22aria-labelledby%22))%7Blet%20d=e.getAttribute(%22aria-labelledby%22).split(%22%20%22);d.length%3E1?(r=%22%22,Array.from(d).forEach(function(S)%7Br+=document.querySelector(%22#%22+S).textContent+%22%20%22%7D),r=r.trim(),t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,a=!0):(r=document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22)).textContent,t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,a=!0),r.trim().toLowerCase().indexOf(s.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-labelledby%20sources%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')%7Dy(e)&&(C(e),y(e)?t+=%22Link%20is%20hidden%3Cbr%3E%22:t+=%22Link%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),u&&(t+=%22%5Cu%7B1F304%7D%20Image%20link%3Cbr%3E%22),e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20Link%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Check%20that%20it%20behaves%20like%20a%20%3Ccode%3Ebutton%3C/code%3E%20and%20is%20not%20used%20as%20navigation.%3Cbr%3E%22,a=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)!==s&&(t+='-%20Link%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20different%20from%20text%20content.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E',a=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)===s&&(t+='Link%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20the%20same%20as%20the%20text%20content%20and%20therefore%20adds%20no%20extra%20useful%20information/context.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E'),e.tagName===%22A%22&&(e.getAttribute(%22href%22)===null&&!e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20is%20not%20keyboard-focusable%3Cbr%3E%22,a=!0),e.getAttribute(%22href%22)!==null&&!e.getAttribute(%22href%22)&&!e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20have%20an%20%3Ccode%3Ehref%3C/code%3E%20but%20it%20has%20no%20value,%20so%20it%20is%20keyboard-focusable%3Cbr%3E%22,a=!0),!e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20but%20is%20focusable%20because%20it%20has%20been%20provided%20with%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E%22,a=!0),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Link%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',a=!0),e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22Link%20has%20a%20%3Ccode%3Etabindex%3C/code%3E%20but%20it%20is%20not%20needed%20because%20the%20%3Ccode%3Ehref%3C/code%3E%20makes%20it%20focusable%3Cbr%3E%22),e.getAttribute(%22role%22)===%22link%22&&(t+=%22Link%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Elink%3C/code%3E.%20Not%20needed%20as%20it%20is%20an%20%3Ccode%3Ea%3C/code%3E%20element%20that%20is%20a%20link%20by%20default%3Cbr%3E%22)),e.tagName!==%22A%22&&e.getAttribute(%22role%22)===%22link%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Elink%3C/code%3E%20but%20is%20not%20an%20%3Ccode%3Ea%3C/code%3E%20element.%20Check%20that%20it%20is%20keyboard-operable%20(should%20activate%20with%20%3Ckbd%3EEnter%3C/kbd%3E%20key)%3Cbr%3E%22,a=!0),r===%22%22&&(e.getAttribute(%22title%22)?r=e.getAttribute(%22title%22):r=%22%5Cu203C%5CuFE0F%20Empty%20link%22,s=%22%5Cu203C%5CuFE0F%20Empty%20link%22,t+=%22%5Cu203C%5CuFE0F%20Empty%20link%3Cbr%3E%22,c=!0),u&&r===%22%5Cu203C%5CuFE0F%20Empty%20link%22&&(t+=%22%20-%20image%20is%20missing%20alternative%20text%20content%3Cbr%3E%22),e.href&&(f=e.href),c&&(a=!1),o+=%22%3Ctr%22,o+='%20data-link-ref=%22'+l+'%22',a&&(o+='%20class=%22issue%20warn%22'),c&&(o+='%20class=%22issue%20err%22'),o+=%22%3E%22,e.tagName===%22A%22?p=%22%3Ccode%3E<a>%3C/code%3E%22:p='%3Ccode%3Erole=%22link%22%3C/code%3E',o+=%22%3Ctd%3E%22+p+%22%3C/td%3E%22,o+=%22%3Ctd%3E%22+s+%22%3C/td%3E%22,o+=%22%3Ctd%3E%22+r,r.trim()!==s.trim()&&s.trim()!==%22%22&&(o+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),o+=%22%3C/td%3E%22,r.trim()!==s.trim()&&r.trim().toLowerCase()===s.trim().toLowerCase()&&(t+=%22-%20Same%20text%20but%20case%20difference%20noted%20(likely%20not%20an%20issue)%22),o+=%22%3Ctd%3E%22,a&&(o+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20link%3C/div%3E'),c&&(o+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20link%3C/div%3E'),h=%22Link%20'%22+s.trim()+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+g+%60%0A---------------%0A%60,o+=t+'%3Ca%20href=%22'+f+'%22%20target=%22_blank%22%20aria-label=%22'+r+'%22%3E%5Cu%7B1F517%7D%3C/a%3E%20%3Clabel%20for=%22l'+l+'%22%3ELinks%20to:%3C/label%3E%3Cinput%20id=%22l'+l+'%22%20class=%22linkToCopy%22%20type=%22text%22%20value=%22'+f+'%22%3E%20%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+l+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+l+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+g+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',o+='%3Ctd%3E%3Cbutton%20data-link-ref=%22'+l+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',o+=%22%3C/tr%3E%22,l++,(a%7C%7Cc)&&w++,c&&(h=h.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(h))%7D),n='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkblue;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:link,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20links%20on%20this%20page.%3C/h1%3E',n+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20links%20where%20there%20*may*%20be%20issues%20('+w+%22%20found)%3C/label%3E%22,n+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20links%20on%20page%3C/button%3E',n+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20links%20(anchors%20or%20elements%20with%20role=%22link%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3ELink%20type%3C/th%3E%3Cth%20scope=%22col%22%3ELink%20text%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+o+%22%3C/tbody%3E%3C/table%3E%22,n+=%22%3Cscript%3Efunction%20showLinks()%7B%22,n+=%22var%20refWindow=window.opener;%22,n+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20linkToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BlinkToHighlight=%22%5Bdata-link-ref='%22%20+%20highlightButton.getAttribute(%22data-link-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(linkToHighlight).focus();refWindow.document.querySelector(linkToHighlight).style.outline=%224px%20dashed%20darkblue%22;refWindow.document.querySelector(linkToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(linkToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,n+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',n+='var%20linksToCopy=document.querySelectorAll(%22.linkToCopy%22);Array.from(linksToCopy).forEach(linkToCopy%20=%3E%20%7BlinkToCopy.addEventListener(%22focus%22,%20e%20=%3E%20%7BlinkToCopy.select();%7D);%7D);',n+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',n+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowLinks();%7D);%3C%5C/script%3E';let%20m=window.open(%22%22,%22popUpWinLinks%22,%22height=800,width=1000%22);m.document.open(),m.document.write(n),m.document.close()%7Dv()%7D)();%7D)();%0A" - }, - { - "file": "non-underlined-links.js", - "bookmarklet": "Non-underlined links", - "description": "Display information about links without underlines", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "1.4.1 Use of Color (A)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;var%20l=%22%22;function%20y()%7Bconsole.clear();let%20c=!1,u=!1,i=!1,p=!1,k=document.querySelectorAll(%22a%22),f=0,h=!1,b=!1;function%20N(e,a,o)%7Blet%20n=%5Be,a,o%5D.map(function(t)%7Breturn(t/=255)%3C=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)%7D);return%20.2126*n%5B0%5D+.7152*n%5B1%5D+.0722*n%5B2%5D%7Dfunction%20x(e)%7Breturn%20e=(e=(e=e.replace(%22rgb(%22,%22%22)).replace(%22)%22,%22%22)).split(%22,%20%22)%7Dif(function()%7Blet%20e=document.createElement(%22style%22);e.textContent=%22.problem-highlight%20%7Boutline:5px%20solid%20darkred;outline-offset:3px;box-shadow:%200px%200px%200px%2010px%20#fff;%7D%22,document.head.appendChild(e)%7D(),Array.from(k).forEach(e=%3E%7Bif(h=!1,b=!1,p=function(a,o)%7Bfor(;(a=a.parentElement)&&!(a.matches%7C%7Ca.matchesSelector).call(a,o););return%20a%7D(e,%22nav,%5Brole=navigation%5D%22),e.childNodes.length%3E0&&(e.childNodes%5B0%5D.tagName&&(e.childNodes%5B0%5D.tagName.toUpperCase()!==%22IMG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22SVG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22FIGURE%22%7C%7C(h=!0)),!function(a)%7Bc=!1,u=!1,i=!1;let%20o=getComputedStyle(a);for(let%20n=0;n%3Co.length;n++)%7Blet%20t=o%5Bn%5D,r=o.getPropertyValue(t);t===%22text-decoration-line%22&&r===%22underline%22&&(u=!0),t!==%22border-bottom-style%22%7C%7Cr!==%22solid%22&&r!==%22dotted%22&&r!==%22dashed%22%7C%7C(i=!0),t===%22border-bottom-color%22&&r===%22transparent%22&&(i=!1),(u%7C%7Ci)&&(c=!0)%7Dreturn%20c%7D(e)&&!h))%7Bl+=%60-------%0A%60,l+=%22Link%20text:%20%22+e.textContent+%60%0A%60,p%7C%7C(function(o)%7Bo.classList.add(%22problem-highlight%22)%7D(e),l+=%22Affected%20node%20(xpath):%20%22+function(o)%7Blet%20n,t=o,r=o.tagName.toLowerCase(),s=%22%22,d=%22%22,m=%22%22,g=%22%22;for(;t.parentNode;)%7Bif((n=t.parentNode).tagName)%7Bs=n.tagName.toLowerCase();let%20C=n.querySelectorAll(t.tagName);m=C.length%3E1?%22%5B%22+parseInt(Array.from(C).indexOf(t)+1)+%22%5D%22:%22%22,d=(r=t.tagName.toLowerCase())+m+g+d,g=%22/%22%7Dt=n%7Dreturn%20s===%22%22&&(s=r),d=%22//%22+s+m+g+d%7D(e)+%60%0A%60,f++);let%20a=function(o,n)%7Blet%20t=N(o%5B0%5D,o%5B1%5D,o%5B2%5D),r=N(n%5B0%5D,n%5B1%5D,n%5B2%5D);return(Math.max(t,r)+.05)/(Math.min(t,r)+.05)%7D(x(getComputedStyle(e).color),x(getComputedStyle(e.parentNode).color));p?l+=%60Link%20is%20inside%20a%20%3Cnav%3E%20element%20and%20therefore%20its%20position/display%20does%20not%20require%20the%20underline%20for%20it%20to%20be%20perceived%20as%20a%20link.%0A%60:(a%3C3&&(l+=%22%5Cu%7B1F6A8%7D%20Contrast%20between%20link%20text%20and%20parent%20text%20node%20is%20under%203:1.%20Ratio%20is%20%22+a.toFixed(2)+%22:1.%22),l+=%60%0A%20%20%20Very%20likely%20a%20%5BSC%201.4.1%20Use%20of%20Color%5D(https://www.w3.org/TR/WCAG21/#use-of-color)%20issue%0A%60)%7D%7D),f%3E0)%7Blet%20e=f+%22%20possible%20issues%20with%20non-underlined%20links%20found%22;l=e+%60%0A%60+l,alert(e+%22%20(check%20console%20for%20more%20details)%22)%7Delse%20alert(%22No%20non-underlined%20links%20found%20(outside%20of%20a%20navigation%20area)%22);console.log(l)%7Dy();var%20w=l%7D)();%7D)();%0A" - }, - { - "file": "page-link.js", - "bookmarklet": "Page link", - "description": "Copy page title and URL, separated by hyphens", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "utility" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bvar%20t=document.title+%22%20%5Cu2014%20%22+location.href;window.prompt(%22Plain%20text%20link:%22,t);%7D)();%0A" - }, - { - "file": "parsing-only.js", - "bookmarklet": "Parsing only", - "description": "Reduce HTML validation results to 4.1.1 Parsing (A) only", - "source": "Steve Faulkner", - "sourceUrl": "https://cdpn.io/stevef/debug/dyGeywr", - "tags": [ - "4.1.1 Parsing (A)" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20r=!0,i=%5B%22tag%20seen%22,%22Stray%20end%20tag%22,%22Bad%20start%20tag%22,%22violates%20nesting%20rules%22,%22Duplicate%20ID%22,%22first%20occurrence%20of%20ID%22,%22Unclosed%20element%22,%22not%20allowed%20as%20child%20of%20element%22,%22unclosed%20elements%22,%22not%20allowed%20on%20element%22,%22unquoted%20attribute%20value%22,%22Duplicate%20attribute%22%5D,o,l,s,e,t,n,a=0;if(o=i.join(%22%7C%22),l=document.getElementById(%22results%22),!l)%7Balert(%22No%20results%20container%20found.%22);return%7Dfor(s=l.getElementsByTagName(%22li%22),n=0;n%3Cs.length;n++)e=s%5Bn%5D,e.className!==%22%22&&(t=(e.innerText!==void%200?e.innerText:e.textContent)+%22%22,(t.match(o)===null%7C%7Cr==!0&&t.indexOf(%22not%20allowed%20on%20element%22)!==-1&&t.indexOf(%22ng-%22)!==-1)&&(e.style.display=%22none%22,e.className=e.className+%22%20steveNoLike%22,a++));alert(%22Complete.%20%22+a+%22%20items%20removed.%22)%7D)();%7D)();%0A" - }, - { - "file": "placeholder-contrast.js", - "bookmarklet": "Placeholder contrast checker", - "description": "Measure contrast of placeholder text", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "accessibility", - "1.4.3 Contrast (Minimum) (AA)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bfunction%20s(o,e,t)%7Blet%5Bl,r,c%5D=%5Bo,e,t%5D.map(n=%3E(n=n/255,n%3C=.03928?n/12.92:Math.pow((n+.055)/1.055,2.4)));return%20.2126*l+.7152*r+.0722*c%7Dfunction%20u(o,e)%7Blet%20t=Math.max(o,e),l=Math.min(o,e);return(t+.05)/(l+.05)%7Dfunction%20d(o)%7Breturn%20o.match(/%5Cd+/g).map(Number)%7Dfunction%20g(o)%7Blet%20e=document.createElement(%22style%22),t=%22temp-%22+Math.random().toString(36).substr(2,9);o.classList.add(t),e.textContent=%60.$%7Bt%7D::placeholder%20%7B%20background-color:%20inherit;%20%7D%60,document.head.appendChild(e);let%20r=window.getComputedStyle(o,%22::placeholder%22).color;return%20o.classList.remove(t),e.remove(),r%7Dlet%20i=document.querySelectorAll(%22input%5Bplaceholder%5D,%20textarea%5Bplaceholder%5D%22);console.group(%22Placeholder%20Contrast%20Analysis%22),console.log(%22Analyzing%20%22+i.length+%60%20form%20elements...%0A%60),i.forEach((o,e)=%3E%7Blet%20t=window.getComputedStyle(o),l=g(o),r=t.backgroundColor,c=d(l),n=d(r),p=s(...c),h=s(...n),a=u(p,h),m=o.tagName.toLowerCase()+(o.id?%22#%22+o.id:%22%22)+(o.className?%22.%22+o.className.split(%22%20%22).join(%22.%22):%22%22)+%22::placeholder%22;console.group(%60Element%20$%7Be+1%7D:%20$%7Bm%7D%60),console.log(%22Placeholder%20Text:%22,o.placeholder),console.log(%22Placeholder%20Color:%22,l),console.log(%22Background:%22,r),a%3C4.5?console.log(%22%5Cu%7B1F6D1%7D%20Contrast%20Ratio:%22,a.toFixed(2)):console.log(%22%5Cu2705%20Contrast%20Ratio:%22,a.toFixed(2)),console.groupEnd(),o.style.outline=a%3C4.5?%225px%20solid%20#ff0000%22:%222px%20solid#00ff00%22%7D),console.groupEnd()%7D)();%7D)();%0A" - }, - { - "file": "service-html-validator.js", - "bookmarklet": "Validate", - "description": "Validate HTML of DOM", - "source": "Deque", - "sourceUrl": "https://dequeuniversity.com/validator", - "tags": [ - "4.1.1 Parsing (A)" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7B(function()%7Bvar%20t=document.doctype,d=%22%3C!DOCTYPE%20%22+t.name+(t.publicId?'%20PUBLIC%20%22'+t.publicId+'%22':%22%22)+(!t.publicId&&t.systemId?%22%20SYSTEM%22:%22%22)+(t.systemId?'%20%22'+t.systemId+'%22':%22%22)+%22%3E%22,m=document.documentElement.outerHTML,r=d+m,a=document.getElementById(%22deque-w3c-validator-bookmarklet%22);a&&a.remove();var%20e=document.createElement(%22form%22);e.id=%22deque-w3c-validator-bookmarklet%22,e.method=%22POST%22,e.action=%22https://validator.w3.org/nu/?showsource=yes&nocache=%22+Math.random(),e.target=%22_blank%22,e.enctype=%22multipart/form-data%22;var%20o=document.createElement(%22textarea%22);o.name=%22content%22,o.value=r,e.appendChild(o),document.body.appendChild(e),e.submit(),a=document.getElementById(%22deque-w3c-validator-bookmarklet%22),a&&a.remove()%7D)()%7D)();%7D)();%0A" - }, - { - "file": "text-spacing.js", - "bookmarklet": "Text spacing", - "description": "Test on WCAG 1.4.12 Text Spacing", - "source": "Steve Faulkner", - "sourceUrl": "https://codepen.io/stevef/pen/YLMqbo", - "tags": [ - "1.4.12 Text Spacing (AA)" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document,l=%22phltsbkmklt%22,c=t.getElementById(l),a=t.querySelectorAll(%22iframe%22),e=0,i=a.length;if(c)%7Blet%20o=function(n)%7Bfor(var%20d%20of%20n.querySelectorAll(%22*%22))d.shadowRoot&&(d.shadowRoot.getElementById(l).remove(),o(d.shadowRoot))%7D;var%20m=o;if(c.remove(),i)for(e=0;e%3Ci;e++)try%7Ba%5Be%5D.contentWindow.document.getElementById(l).remove(),o(a%5Be%5D.contentWindow.document)%7Dcatch(n)%7Bconsole.log(n)%7Do(t)%7Delse%7Blet%20o=function(n)%7Bfor(var%20d%20of%20n.querySelectorAll(%22*%22))d.shadowRoot&&(d.shadowRoot.appendChild(r.cloneNode(!0)),o(d.shadowRoot))%7D;var%20h=o,r=t.createElement(%22style%22);for(r.id=l,r.appendChild(t.createTextNode(%22*%7Bline-height:1.5%20!important;letter-spacing:0.12em%20!important;word-spacing:0.16em%20!important;%7Dp%7Bmargin-bottom:2em%20!important;%7D%22)),t.getElementsByTagName(%22head%22)%5B0%5D.appendChild(r),e=0;e%3Ci;e++)try%7Ba%5Be%5D.contentWindow.document.getElementsByTagName(%22head%22)%5B0%5D.appendChild(r.cloneNode(!0)),o(a%5Be%5D.contentWindow.document)%7Dcatch(n)%7Bconsole.log(n)%7Do(t)%7D%7D)();%7D)();%0A" - }, - { - "file": "titles.js", - "bookmarklet": "Titles", - "description": "Display all titles", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20k(t,e)%7Be.parentNode.insertBefore(t,e.nextSibling)%7Dfunction%20w(t)%7Blet%20e=window.getComputedStyle(t);return%20e.display===%22none%22%7C%7Ce.opacity===0%7C%7Ce.clipPath===%22inset(100%25)%22&&e.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ce.height===%221px%22&&e.width===%221px%22&&e.overflow===%22hidden%22%7Dfunction%20B(t)%7Blet%20e=window.getComputedStyle(t);e.position===%22absolute%22&&e.overflow===%22hidden%22&&(t.style.height=%22auto%22,t.style.width=%22auto%22,t.style.position=%22relative%22,t.style.overflow=%22visible%22,t.style.display=%22block%22,t.style.opacity=1),(t.getAttribute(%22hidden%22)===%22%22%7C%7Ct.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ct.getAttribute(%22hidden%22)===%22true%22)&&t.removeAttribute(%22hidden%22),e.visibility===%22hidden%22&&(t.style.visibility=%22visible%22),e.display===%22none%22&&(t.style.display=%22block%22),e.opacity===0&&(t.style.opacity=1)%7Dlet%20o=%22%22,i=%22%22,E=document.querySelectorAll(%22body%20%5Btitle%5D,iframe%22),l=1,b=0,y=0,g=%22%22,a,c=%22%22;Array.from(E).forEach(function(t)%7Ba=%22No%22,(t.getAttribute(%22tabindex%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22%7C%7C(t.tagName===%22INPUT%22%7C%7Ct.tagName===%22BUTTON%22%7C%7Ct.tagName===%22TEXTAREA%22%7C%7Ct.tagName===%22SELECT%22%7C%7Ct.tagName===%22IFRAME%22%7C%7Ct.tagName===%22A%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22&&!t.disabled)&&(a=%22Yes%22);let%20e=document.createElement(%22div%22);e.appendChild(t.cloneNode(!0)),g=e.innerHTML;let%20s=%22%22,r=!1,n=!1;t.setAttribute(%22data-title-ref%22,l);let%20x=!1,A=t.querySelectorAll(%22img%22);if(x=A.length%3E0,x)%7Blet%20S=%22%22;Array.from(A).forEach(function(m)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),m.getAttribute(%22alt%22)?d.textContent=%22%20%22+m.getAttribute(%22alt%22)+%22%20%22:d.textContent=%22**%20Image%20with%20empty%20or%20missing%20alt%20**%22,k(d,m)%7D)%7Dlet%20p=t.textContent;t.tagName===%22IMG%22&&(p=t.getAttribute(%22alt%22));let%20u=p,h=t.getAttribute(%22title%22);u===null&&(u=%22%22),h===null&&(h=%22%22),w(t)&&(B(t),w(t)?s+=%22-%20Element%20is%20hidden%3Cbr%3E%22:s+=%22-%20Element%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),n&&(r=!1),i+=%22%3Ctr%22,i+='%20data-title-ref=%22'+l+'%22',u.trim()===h.trim()?(r=!1,n=!1):t.tagName!==%22IFRAME%22&&(r=!1,n=!0,b++,s+=%22-%20The%20title%20text%20differs%20from%20the%20on-screen%20text.%3Cbr%3E%22,a===%22Yes%22&&(s+=%22-%20This%20is%20an%20interactive%20element,%20but%20the%20title%20attribute%20*may*%20be%20ignored%20by%20assistive%20tech%20(depending%20on%20user%20settings).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20As%20this%20is%20a%20non-interactive%20element,%20the%20title%20attribute%20will%20be%20ignored%20by%20assistive%20tech.%3Cbr%3E%22)),t.tagName===%22IFRAME%22&&h.trim()===%22%22&&(r=!1,n=!0,b++,s+=%22An%20%3Ccode%3Eiframe%3C/code%3E%20MUST%20have%20a%20title%20attribute.%3Cbr%3E%22),r&&(i+='%20class=%22warn%22'),n&&(i+='%20class=%22issue%20err%22'),i+=%22%3E%22,i+=%22%3Ctd%3E%22+p+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22+h+%22%3C/td%3E%22,u.trim()===h.trim()&&u.trim()!==%22%22&&(s+=%22-%20title%20text%20is%20identical%20to%20on-screen%20text%20(superfluous,%20but%20not%20harmful).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20This%20is%20not%20an%20interactive/focusable%20element.%20The%20title%20attribute%20will%20not%20be%20available%20to%20anyone%20expect%20mouse%20users%20(touch%20screen,%20keyboard-only,%20assistive%20tech%20users%20all%20excluded).%3Cbr%3E%22),i+=%22%3Ctd%3E%22+a+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22,r&&(i+='%3Cdiv%20class=%22issues%22%3EPossible%20title%20issue%20found%20with%20this%20element%3C/div%3E'),n&&(i+='%3Cdiv%20class=%22issues%22%3EDefinite%20title%20issue%20found%20with%20this%20element%3C/div%3E'),c=%22Element%20with%20title%20'%22+p.trim()+%60':%0A%60+s+%60Markup%20with%20issue:%0A%60+g+%60%0A---------------%0A%60,i+=s+'%3Cbr%3E%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+l+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+l+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+g+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',i+='%3Ctd%3E%3Cbutton%20data-title-ref=%22'+l+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',i+=%22%3C/tr%3E%22,l++,(r%7C%7Cn)&&y++,n&&(c=c.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(c))%7D),o='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:rebeccapurple;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.checkDiffs:after%7Bcontent:%22Accessible%20name%20differs%22;color:#a50202;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:#a50202;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:elWithTitle,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20elements%20with%20titles%20on%20this%20page.%3C/h1%3E',b%3E0&&(o+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20elements%20with%20definite%20title%20issues('+y+%22).%3C/label%3E%3Cbr%3E%22),o+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20elements%20with%20%60title%60%20on%20page%3C/button%3E',o+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20things%20with%20title%20attributes%20on%20this%20page%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%20scope=%22col%22%3EOn-screen%20text%3C/th%3E%3Cth%3ETitle%20text%3C/th%3E%3Cth%3EInteractive?%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+i+%22%3C/tbody%3E%3C/table%3E%22,o+=%22%3Cscript%3Efunction%20showElsWithTitles()%7B%22,o+=%22var%20refWindow=window.opener;%22,o+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20titleToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BtitleToHighlight=%22%5Bdata-title-ref='%22%20+%20highlightButton.getAttribute(%22data-title-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(titleToHighlight).setAttribute(%22tabindex%22,%22-1%22);refWindow.document.querySelector(titleToHighlight).focus();refWindow.document.querySelector(titleToHighlight).style.outline=%224px%20dashed%20rebeccapurple%22;refWindow.document.querySelector(titleToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(titleToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,o+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',o+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',o+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowElsWithTitles();%7D);%3C%5C/script%3E';let%20f=window.open(%22%22,%22popUpWinTitles%22,%22height=800,width=1000%22);f.document.open(),f.document.write(o),f.document.close()%7Dv()%7D)();%7D)();%0A" - }, - { - "file": "tool-andi.js", - "bookmarklet": "ANDI", - "description": "Accessible Name & Description Inspector is a free accessibility testing tool", - "source": "Accessible Solutions Branch of the Social Security Administration", - "sourceUrl": "https://www.ssa.gov/accessibility/andi/help/install.html", - "tags": [ - "accessibility", - "external" - ], - "auditing": true, - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document.createElement(%22script%22);t.setAttribute(%22src%22,%22https://www.ssa.gov/accessibility/andi/andi.js%22),document.body.appendChild(t)%7D)();%7D)();%0A" - }, - { - "file": "window-1280x1024.js", - "bookmarklet": "Open 1280x1024", - "description": "Opens a new window with the current URL at 1280x1024", - "source": "Mike in a CSS Tricks article comment", - "sourceUrl": "https://css-tricks.com/snippets/javascript/1024x768-bookmarklet/#comment-1766738", - "tags": [ - "1.4.4 Resize Text (AA)", - "1.4.10 Reflow (AA)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=%22w%22+new%20Date().getTime(),o=%22toolbar=yes,location=yes,status=yes,resizable=yes,favorites=yes,width=1280,height=1024,left=0,top=0%22,e=document.createElement(%22P%22);e.innerHTML='%3Ca%20href=%22#%22%20id=%22'+t+%60%22%20target=%22_blank%22%20onclick=%22window.open(window.location.href,%20'',%20'%60+o+%60'%20);%20return%20false;%22%3E%3C/a%3E%3C/p%3E%60,document.body.appendChild(e),document.getElementById(t).click()&&document.body.removeChild(e)%7D)();%7D)();%0A" - }, - { - "file": "wtfocus.js", - "bookmarklet": "WTFocus", - "description": "Display information with focusable elements", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "2.4.4 Link Purpose (In Context) (A)", - "4.1.2 Name", - "Role", - "Value (A)" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20re()%7Blet%20z=document.activeElement,H=document.querySelectorAll('a%5Bhref%5D,button,select,input:not(%5Btype=%22hidden%22%5D),textarea,summary,area,%5Btabindex%5D:not(#WTFocusPanel):not(%5Btabindex%5E=%22-1%22%5D),%5Bcontenteditable%5D:not(%5Bcontenteditable=%22false%22%5D)'),E=%22background:#fff;color:darkgreen;font-weight:bold;text-decoration:line-through%22,j=%22font-weight:bold;color:#99f170;background:#333;display:inline-block;padding:3px;%22,h=%22color:pink;background:#333;padding:3px;%22,A=%22color:black;background:#fefbe3;font-weight:bold;%22,a=document.createElement(%22div%22),O=document.createElement(%22div%22),R=20,Y=400,w=7,ie='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F449%7D%5Cu%7B1F3FD%7D%3C/span%3E%3Cspan%20class=%22visually-hidden%22%3EAccessible%20name%20provided%20by%3C/span%3E%20',ce='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F6A8%7D%3C/span%3E%20%3Cspan%20class=%22visually-hidden%22%3EWarning%3C/span%3E',V,P=%22Accessible%20name:%20%22,k=!1,p=%22%22,m=!1,x=!1,I=!1,G=!1,L=!1;function%20W()%7Bm=!1,x=!1%7Dfunction%20l(e,r,o,n,C)%7Bk&&(r=r.split(%22%3C%22).join(%22<%22).split(%22%3E%22).join(%22>%22),p+=%22%3Cli%22,(C%7C%7Cn)&&(p+='%20class=%22',C&&(p+=%22visible%22),n&&(p+=%22outline%22),p+='%22'),p+='%20role=%22listitem%22%3E%3Cspan%20style=%22'+o+'%22%3E',m&&(p+=ie),x&&(p+=ce),p+=e+%22%3C/span%3E %22+r+%60%3C/li%3E%0A%60),r=r.replace(%22<%22,%22%3C%22).replace(%22>%22,%22%3E%22),console.log(%22%25c%22+e+'%22'+r+'%22',o)%7Dfunction%20J()%7Blet%20e=document.createElement(%22button%22);e.textContent=%22Close%20(Esc)%22,e.setAttribute(%22type%22,%22button%22),e.setAttribute(%22class%22,%22panel-btn%22),e.addEventListener(%22click%22,()=%3E%7BD()%7D);let%20r=document.createElement(%22button%22);r.textContent=%22Change%20Mode%20(M)%22,r.setAttribute(%22type%22,%22button%22),r.setAttribute(%22class%22,%22panel-btn%22),r.addEventListener(%22click%22,o=%3E%7BK()%7D),a.appendChild(e),a.appendChild(r)%7Dfunction%20K()%7BL?(document.querySelector(%22#WTFocusPanel%22).classList.remove(%22curtainsMode%22),document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22),document.querySelector(%22#WTFocusCurtain%22).setAttribute(%22hidden%22,%22hidden%22),L=!1,P=%22Accessible%20name:%20%22):(document.querySelector(%22#WTFocusPanel%22).classList.add(%22curtainsMode%22),document.querySelector(%22#WTFocusCurtain%22).removeAttribute(%22hidden%22),L=!0,P=%22%22),Q(z),z.focus()%7Dfunction%20D()%7Bdocument.querySelector(%22#WTFocusCurtain%22).remove(),document.querySelector(%22#WTFocusPanel%22).remove(),document.querySelector(%22#panelStyles%22).remove(),document.querySelector(%22#focusStyles%22).remove()%7Dfunction%20Q(e)%7Blet%20r=e.getBoundingClientRect(),o=document.documentElement.scrollTop,n=r.right+R+Y,C=a.offsetHeight,q=o+r.top+C,i=window.innerWidth,c=window.innerHeight;L?document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22):n%3Ei?(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=%22auto%22,a.style.right=i-r.left+R-w+%22px%22,a.classList.add(%22toLeft%22)):(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=r.right+R-w+%22px%22,a.style.right=%22auto%22,a.classList.remove(%22toLeft%22))%7Dconsole.clear(),function()%7Blet%20e=document.createElement(%22style%22);e.setAttribute(%22type%22,%22text/css%22),e.setAttribute(%22id%22,%22panelStyles%22),e.textContent=%22.dupeAccName%20%7Boutline:4px%20dashed%20#CC3300!important;outline-offset:%22+w+%22px!important;overflow:visible;%7D%20.WTFocusTempFocusStyle:focus%20%7Boutline:%22+w+%22px%20solid%20black!important;outline-offset:%22+w+%22px!important;overflow:visible;/*background:yellow!important;color:black!important;*/%7D%20.WTFocusTempFocusStyle.dupeAccName:focus%20%7Boutline-color:#CC3300!important;%7D%20.visually-hidden%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D#WTFocusCurtain%20%7Bbackground:black;position:%20fixed;top:%200;bottom:%200;left:%200;right:%200;z-index:49999%7D%22,document.querySelector(%22body%22).appendChild(e)%7D(),document.querySelector(%22#WTFocusCurtain%22)&&D(),k=!0,p=%22%22,function(e)%7Blet%20r=document.createElement(%22style%22);r.setAttribute(%22type%22,%22text/css%22),r.setAttribute(%22id%22,%22focusStyles%22),r.textContent=%22#WTFocusPanel.error%20%7Bbackground:darkred;%7D%20#WTFocusPanel.warning%20%7Bbackground:#CC3300;%7D%20#WTFocusPanel.curtainsMode.error%20%7Bbackground:black;%7D%20#WTFocusPanel.curtainsMode%20%7Bz-index:50000;position:fixed;top:50%25;left:50%25;transform:translate(-50%25,-50%25);%7D%20#WTFocusPanel.curtainsMode.warning%20%7Bbackground:black;%7D%20#WTFocusPanel%5Bhidden%5D%20%7Bdisplay:none;%7D%20#WTFocusPanel%20*%20%7Btext-align:left%7D%20#WTFocusPanel%20%7Bborder:2px%20solid%20#fff;z-index:1000;text-shadow:none;font-family:sans-serif;display:block;text-align:left;position:%20absolute;z-index:10000;background:%20black;padding:%2020px%2020px;width:%22+e+%22px;font-size:16px;%7D%20#WTFocusPanel%20button%20%7Bfont-weight:bold;background:none;color:#fff;padding:3px%2010px;font-size:14px;border:1px%20solid%20#fff;display:inline-block;margin:10px%201em%20-10px%200;%7D%20#WTFocusPanel%20ul,#WTFocusPanel%20li%20%7Bmargin:0;padding:0;list-style:none%7D%20#WTFocusPanel%20li%20%7Bmargin:3px%200;background:#fff;color:#333;padding:2px%7D%20#WTFocusPanel%20li.outline%20%7Boutline:4px%20solid%20rgb(58,%20190,%2058);outline-offset:-4px;padding:8px%7D%20#WTFocusPanel.error:before%20%7Bbackground:darkred%7D%20#WTFocusPanel.warning:before%20%7Bbackground:#CC3300%7D%20#WTFocusPanel:before%20%7Bcontent:'';display:block;height:20px;width:20px;transform:rotate(45deg);position:absolute;background:#000;left:-12px;top:3px;border:2px%20solid%20#fff;border-right:none;border-top:none;%7D%20#WTFocusPanel.toBottom:before%20%7Btop:auto;bottom:3px%7D%20#WTFocusPanel.toLeft:before%20%7Bleft:auto;right:-12px;border:2px%20solid%20#fff;border-left:none;border-bottom:none;%7D%20#WTFocusPanel.curtainsMode%20%7Boutline:10px%20solid%20orange;%7D%20#WTFocusPanel.curtainsMode:before%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li.visible%20%7Bdisplay:block;%7D%20#WTFocusPanel.curtainsMode%20li%20span%20%7Bdisplay:none!important;%7D%20%22,document.querySelector(%22head%22).appendChild(r)%7D(Y),O.setAttribute(%22id%22,%22WTFocusCurtain%22),O.setAttribute(%22hidden%22,%22hidden%22),document.querySelector(%22body%22).appendChild(O),a.setAttribute(%22id%22,%22WTFocusPanel%22),L&&a.setAttribute(%22class%22,%22curtainsMode%22),a.setAttribute(%22aria-live%22,%22polite%22),a.setAttribute(%22tabindex%22,%22-1%22),a.setAttribute(%22hidden%22,%22hidden%22),a.setAttribute(%22role%22,%22region%22),a.setAttribute(%22aria-label%22,%22Accessibility%20properties%20panel%22),document.querySelector(%22body%22).appendChild(a),window.addEventListener(%22keyup%22,e=%3E%7Be.key===%22Escape%22&&document.querySelector(%22#WTFocusPanel%22)&&D()%7D),window.addEventListener(%22keyup%22,e=%3E%7Be.key.toLowerCase()===%22m%22&&document.querySelector(%22#WTFocusPanel%22)&&K()%7D),J();let%20U=%5B%5D;Array.from(H).forEach(function(e)%7Be.classList.add(%22WTFocusTempFocusStyle%22);let%20r=e.querySelectorAll(%22style%22);Array.from(r).forEach(function(o)%7Bo.remove()%7D),e.addEventListener(%22focus%22,()=%3E%7Blet%20o=e.getAttribute(%22role%22),n=e.tagName.toLowerCase();if(console.clear(),!o)%7Bif(n!=%22article%22&&n!=%22button%22&&n!=%22dialog%22&&n!=%22figure%22&&n!=%22img%22&&n!=%22main%22&&n!=%22math%22%7C%7C(o=n),n==%22summary%22&&(o=%22button%22),n==%22aside%22&&(o=%22complementary%22),n==%22dd%22&&(o=%22definition%22),n==%22html%22&&(o=%22document%22),n!=%22details%22&&n!=%22fieldset%22&&n!=%22optgroup%22%7C%7C(o=%22group%22),n!=%22menu%22&&n!=%22ol%22&&n!=%22ul%22%7C%7C(o=%22list%22),n==%22datalist%22&&(o=%22listbox%22),n==%22li%22&&(o=%22listitem%22),n==%22nav%22&&(o=%22navigation%22),n==%22progress%22&&(o=%22progressbar%22),n==%22hr%22&&(o=%22separator%22),n==%22output%22&&(o=%22status%22),n!=%22dfn%22&&n!=%22dt%22%7C%7C(o=%22term%22),n==%22a%22&&(o=%22link%22),n==%22select%22&&(o=%22listbox%22),n==%22textarea%22&&(o=%22textbox%22),n==%22input%22)%7Blet%20t=e.getAttribute(%22type%22).toLowerCase();t===%22text%22&&(o=%22textbox%22),t===%22range%22&&(o=%22slider%22),t===%22number%22&&(o=%22spinbutton%22),t!==%22checkbox%22&&t!==%22radio%22%7C%7C(o=t),t!==%22button%22&&t!==%22image%22&&t!==%22reset%22&&t!==%22submit%22%7C%7C(o=%22button%22)%7D%7Dz=e,Array.from(H).forEach(function(t)%7Bt.classList.remove(%22dupeAccName%22)%7D);let%20C=!1;m=!1,x=!1;let%20q=e.querySelectorAll(%22img,%20%5Brole='image'%5D%5Baria-label%5D,%20%5Brole='img'%5D%5Baria-label%5D%22);(C=q.length%3E0)&&Array.from(q).forEach(function(t)%7Blet%20d=document.createElement(%22SPAN%22);var%20T,B;d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22data-temp-node%22,%22true%22),t.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+t.getAttribute(%22alt%22)+%22%20%22),t.getAttribute(%22role%22)&&t.getAttribute(%22aria-label%22)&&(d.textContent=%22%20%22+t.getAttribute(%22aria-label%22)+%22%20%22),T=d,(B=t).parentNode.insertBefore(T,B.nextSibling)%7D),setTimeout(function()%7Be.classList.add(%22WTFocusTempFocusStyle%22)%7D,100),p=%22%22;let%20i=e.tagName.toLowerCase(),c=e.getAttribute(%22role%22);c&&(c=e.getAttribute(%22role%22).toLowerCase());let%20Z=%22%3C%22+i+%22%3E%22,_=!1,$=!1;c&&(Z=%22%3C%22+i+'%20role=%22'+c+'%22%3E',(c===%22link%22&&i===%22a%22%7C%7Cc===%22button%22&&i===%22button%22%7C%7Cc===%22image%22&&i===%22img%22%7C%7Cc===%22img%22&&i===%22img%22%7C%7Cc===%22navigation%22&&i===%22nav%22%7C%7Cc===%22heading%22&&(i===%22h1%22%7C%7Ci===%22h2%22%7C%7Ci===%22h3%22%7C%7Ci===%22h4%22%7C%7Ci===%22h5%22%7C%7Ci===%22h6%22))&&(_=!0),(c===%22link%22&&i!==%22a%22%7C%7Cc===%22button%22&&i!==%22button%22%7C%7C(c===%22image%22%7C%7Cc===%22image%22)&&i!==%22img%22%7C%7Cc===%22navigation%22&&i!==%22nav%22%7C%7Cc===%22heading%22&&i!==%22h1%22&&i!==%22h2%22&&i!==%22h3%22&&i!==%22h4%22&&i!==%22h5%22&&i!==%22h6%22)&&($=!0));let%20ee,b=e.textContent,f=e.ariaLabel,S=e.getAttribute(%22aria-labelledby%22),N=e.getAttribute(%22placeholder%22),F=%22%22,g=e.getAttribute(%22value%22),v=e.getAttribute(%22title%22),s=%22%22,y=%22%22,te=!1,oe=!1,u=%22%22,ne=!1;k&&Q(e),b=b.trim();let%20ae=function(t,d)%7Bfor(;(t=t.parentElement)&&!(t.matches%7C%7Ct.matchesSelector).call(t,d););return%20t%7D(e,%22label%22);if(ae&&(te=!0,s=y=ae.textContent.trim()),e.getAttribute(%22id%22))%7Blet%20t=document.querySelector(%22%5Bfor='%22+e.getAttribute(%22id%22)+%22'%5D%22);t&&(oe=!0,y=t.textContent)%7Dif(te%7C%7Coe%7C%7C(y=%22N/A%22),b%7C%7C(b=%22N/A%22),g%7C%7C(g=%22N/A%22),v%7C%7C(v=%22N/A%22),N%7C%7C(N=%22N/A%22),f%7C%7C(f=%22N/A%22),S)%7Blet%20t=(ee=S).split(%22%20%22);t.length%3E1?(Array.from(t).forEach(function(d)%7Bdocument.querySelector(%22#%22+d)?F+=document.querySelector(%22#%22+d).textContent+%22%20%22:F+=%22%5Cu2753%5Cu2753%5Cu2753%20%22%7D),F=F.trim()):F=document.querySelector(%22#%22+ee).textContent%7Delse%20S=%22N/A%22;let%20le=e.querySelectorAll(%22%5Baria-hidden='true'%5D,%5Brole='presentation'%5D%22),M=b;if(le.length%3E0&&(ne=!0,Array.from(le).forEach(function(t)%7Blet%20d=t.textContent;d!==%22%22&&(M=M.split(d).join(%22%20%22))%7D),M=M.trim()),i===%22input%22)%7Blet%20t=e.getAttribute(%22type%22);t===%22submit%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22image%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22cancel%22&&g===%22N/A%22&&(s=%22Cancel%22,u=%22Not%20provided%20(using%20default)%22)%7Dif(v!==%22N/A%22&&(s=v,u=%22title%20attribute%22),g!==%22N/A%22&&(s=g,u=%22value%20attribute%22),N!==%22N/A%22&&(s=N,u=%22placeholder%20attribute%22),b!==%22N/A%22&&(s=M,u=%22Inner%20text%20content%22),y!==%22N/A%22&&(s=y,u=%22%3Clabel%3E%20text%22),f!==%22N/A%22&&(s=f,u=%22aria-label%22),S!==%22N/A%22&&(s=F,u=%22aria-labelledby%22),console.log(%22%25cACTIVE%20ELEMENT:%20%22,%22background:#193c10;color:white;%22),console.log(e),I=e.getAttribute(%22data-dupe%22)===%22true%22,G=I&&s===%22%22,s===%22%22%7C%7CI)%7Bif(s===%22%22&&(x=!0,k&&a.classList.add(%22error%22),l(P+%22No%20accessible%20name!%22,%22%22,h),l(%22Accessible%20Name%20Source:%20N/A%22,%22%22,h)),I&&s!==%22%22)%7Bk&&a.classList.add(%22warning%22);let%20t=document.querySelectorAll(%22%5Bdata-accname='%22+s+%22'%5D%22),d=t.length;l(P,s,h,!1,!0),G%7C%7C(Array.from(t).forEach(function(T)%7BT.classList.add(%22dupeAccName%22)%7D),l(%22Duplicate%20warning!%22,d+%22%20elements%20on%20page%20have%20the%20same%20accessible%20name%22,h)),console.log(%22Elements%20on%20page%20that%20have%20identical%20accessible%20names:%22),Array.from(t).forEach(function(T)%7Bconsole.log(T)%7D),l(%22Accessible%20Name%20Source:%20%22,u,h)%7D%7Delse%20k&&(a.classList.remove(%22error%22),a.classList.remove(%22warning%22)),l(P,s,j,!1,!0),l(%22Accessible%20Name%20Source:%20%22,u,j);x=!1,l(%22HTML%20Element:%20%22,Z,j),l(%22Role:%20%22,o,%22color:#333;background:#fff;%22,!1,!0),k%7C%7Cconsole.log(%22%25cACCESSIBLE%20NAME%20COMES%20FROM:%20%22,%22background:#193c10;color:white;%22),_&&(x=!0,l(%22Superfluous%20%60role%60%20attribute%22,%22%22,h)),$&&(x=!0,l(%22Better%20to%20use%20a%20native%20HTML%20element%22,%22%22,h)),b=b.trim(),y=y.trim(),v=v.trim(),f=f.trim(),S=S.trim(),W(),u===%22placeholder%20attribute%22?(m=!0,l(%22@placeholder:%20%22,N,A,!0)):l(%22@placeholder:%20%22,N,N===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22title%20attribute%22?(m=!0,l(%22@title:%20%22,v,A,!0)):l(%22@title:%20%22,v,v===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22value%20attribute%22?(m=!0,l(%22@value:%20%22,g,A,!0)):l(%22@value:%20%22,g,g===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22Inner%20text%20content%22?(m=!0,l(C?%22Inner%20text%20content%20(includes%20image%20alt):%20%22:%22Inner%20text%20content:%20%22,b,A,!0),ne&&l(%22!%20elements%20hidden%20to%20AT%20removed%22,%22%22,A)):l(%22Text%20Content:%20%22,b,b===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22%3Clabel%3E%20text%22?(m=!0,l(%22Visible%20%60label%60%20text:%20%22,y,A,!0)):l(%22Visible%20%60label%60%20text:%20%22,y,y===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-label%22?f===b?(x=!0,l(%22%60aria-label%60%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-label%20value:%20%22,f,A,!0)):l(%22@aria-label%20value:%20%22,f,f===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-labelledby%22?F===b?(x=!0,l(%22%60aria-labelledby%60%20source%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-labelledby%20value:%20%22,S,A,!0),l(%22@aria-labelledby%20sources:%20%22,F,A)):(l(%22@aria-labelledby%20value:%20%22,S,%22color:#333;background:#fff;%22),l(%22@aria-labelledby%20sources:%20%22,%22N/A%22,%22color:#333;background:#fff;%22)),k&&(document.querySelector(%22#WTFocusPanel%22).innerHTML='%3Cul%20role=%22list%22%3E'+p+%22%3C/ul%3E%22,document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22hidden%22),J());let%20se=document.querySelectorAll(%22%5Bdata-temp-node%5D%22);Array.from(se).forEach(function(t)%7Bt.remove()%7D),e.setAttribute(%22data-accname%22,s),X%7C%7Cfunction(t,d)%7Blet%20T=!1;Array.from(U).forEach(function(B)%7BB===t&&(T=!0)%7D),T?(d.setAttribute(%22data-dupe%22,%22true%22),document.querySelector(%22%5Bdata-accname='%22+t+%22'%5D%22).setAttribute(%22data-dupe%22,%22true%22)):U.push(t)%7D(s,e)%7D)%7D);let%20X=!1;(function()%7Bif(V=document.activeElement,Array.from(H).forEach(function(e)%7Bdocument.activeElement===e&&e.blur(),e.focus()%7D),X=!0,V.tagName===%22BODY%22)%7Blet%20e=document.querySelector(%22body%22);e.setAttribute(%22tabindex%22,%22-1%22),e.focus(),document.querySelector(%22#WTFocusPanel%22).setAttribute(%22hidden%22,%22hidden%22)%7Delse%20V.focus();console.clear()%7D)(),console.log(%22had%20focus%20=%20%22,z)%7Dre()%7D)();%7D)();%0A" - } -] \ No newline at end of file diff --git a/data/bookmarklets.json b/data/bookmarklets.json deleted file mode 100644 index c224a38..0000000 --- a/data/bookmarklets.json +++ /dev/null @@ -1,818 +0,0 @@ -[ - { - "file": "are-ya-hidden.js", - "bookmarklet": "Are ya hidden?", - "description": "Display hidden content", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "accessibility" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20p=document.querySelectorAll(%22*%22);function%20u()%7BArray.from(p).forEach(t=%3E%7Bcs=getComputedStyle(t);for(var%20e=!1,s=!1,r=!1,l=!1,n=!1,c=!1,o=!1,d=!1,a=0;a%3Ccs.length;a++)cssProperty=cs%5Ba%5D,cssValue=cs.getPropertyValue(cssProperty),cssProperty===%22clip%22&&cssValue===%22rect(1px,%201px,%201px,%201px)%22&&(e=!0),cssProperty===%22clip-path%22&&cssValue===%22inset(100%25)%22&&(s=!0),cssProperty===%22height%22&&cssValue===%221px%22&&(r=!0),cssProperty===%22overflow-x%22&&cssValue===%22hidden%22&&(l=!0),cssProperty===%22overflow-y%22&&cssValue===%22hidden%22&&(n=!0),cssProperty===%22position%22&&cssValue===%22absolute%22&&(c=!0),cssProperty===%22white-space%22&&cssValue===%22nowrap%22&&(o=!0),cssProperty===%22width%22&&cssValue===%221px%22&&(d=!0);e===!0&&s===!0&&r===!0&&l===!0&&n===!0&&c===!0&&o===!0&&d===!0&&t.classList.add(%22was-visually-hidden%22),t.classList.forEach(h=%3E%7Bh.indexOf(%22-offscreen%22)!==-1&&t.classList.add(%22was-visually-hidden%22)%7D),(t.classList.contains(%22sr-only%22)%7C%7Ct.classList.contains(%22screenreader-only%22)%7C%7Ct.classList.contains(%22visually-hidden%22)%7C%7Ct.classList.contains(%22visuallyhidden%22))&&t.classList.add(%22was-visually-hidden%22)%7D)%7Dfunction%20i(t)%7Bu();var%20e,s=t.createElement(%22style%22);t.head.appendChild(s),(e=s.sheet).insertRule(%22%5Baria-hidden=true%5D%20%7Bbackground:black;color:black;%7D%22,0),e.insertRule(%22%5Baria-hidden=true%5D%20%5Baria-hidden=true%5D%20%7Bopacity:1%7D%22,0),e.insertRule(%22.was-visually-hidden%20%7Bclip-path:%20initial!important;clip:%20initial!important;height:%20auto!important;overflow:%20initial!important;position:%20initial!important;white-space:%20initial!important;width:%20auto!important;opacity:initial!important;z-index:initial!important;background:black!important;color:lime!important;%7D%22,0)%7Di(document);var%20y=document.querySelectorAll(%22iframe%22);Array.from(y).forEach(t=%3E%7Bi(t.contentWindow.document)%7D)%7D)();%7D)();%0A" - }, - { - "file": "auto-complete.js", - "bookmarklet": "Autocomplete", - "description": "Display all fields with autocomplete", - "source": "Rachele DiTullio", - "sourceUrl": "https://racheleditullio.com/blog/2023/11/autocomplete-accessibility-bookmarklet/", - "tags": [ - "1.3.5 Identify Input Purpose (AA)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20o=document.querySelectorAll(%22.autocomplete-info%22);if(o.length%3E0)o.forEach(t=%3E%7Bt.remove()%7D);else%7Blet%20t=document.querySelectorAll(%22input%5Bautocomplete%5D%22);t.length%3E0?t.forEach(l=%3E%7Blet%20i=l.getAttribute(%22autocomplete%22),n=l.getBoundingClientRect(),e=document.createElement(%22div%22);e.classList.add(%22autocomplete-info%22),e.style.position=%22absolute%22,e.style.top=window.scrollY+n.top+%22px%22,e.style.left=window.scrollX+n.left+%22px%22,e.style.backgroundColor=%22yellow%22,e.style.color=%22black%22,e.style.padding=%225px%22,e.style.border=%222px%20solid%20#000%22,e.style.zIndex=%229999%22,e.innerHTML=%60autocomplete=%3Cstrong%3E$%7Bi%7D%3C/strong%3E%60,document.body.appendChild(e)%7D):alert(%22No%20input%20fields%20with%20autocomplete%20attribute%20found%20on%20this%20page.%22)%7D%7D)();%7D)();%0A" - }, - { - "file": "background-images.js", - "bookmarklet": "Background images", - "description": "Highlight all CSS background images", - "source": "Zoe Mickley Gillenwater", - "sourceUrl": "https://zomigi.com/blog/bookmarklets-for-accessibility-testing/", - "tags": [ - "utility" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bfor(var%20n=document.getElementsByTagName(%22*%22),e,t=0;t%3Cn.length;t++)e=n%5Bt%5D,e.currentStyle?e.currentStyle.backgroundImage!==%22none%22&&(e.style.outline=%222px%20solid%20#f00%22):window.getComputedStyle&&document.defaultView.getComputedStyle(e,null).getPropertyValue(%22background-image%22)!==%22none%22&&(e.style.outline=%224px%20solid%20#f00%22)%7D)();%7D)();%0A" - }, - { - "file": "blur-page.js", - "bookmarklet": "Blur page", - "description": "Blur entire page", - "source": "Thomas Park", - "sourceUrl": "https://thomaspark.co/2013/11/3-simple-design-bookmarklets-to-improve-your-aesthetics/", - "tags": [ - "diagnostic" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bdocument.body.setAttribute(%22style%22,'filter:url(%22data:image/svg+xml;utf8,%3Csvg%20xmlns=%22http://www.w3.org/2000/svg%22%3E%3Cfilter%20id=%22blur%22%3E%3CfeGaussianBlur%20stdDeviation=%2210%22%20/%3E%3C/filter%3E%3C/svg%3E#blur%22);%20-webkit-filter:blur(10px);%20filter:blur(10px);')%7D)();%7D)();%0A" - }, - { - "file": "buttons.js", - "bookmarklet": "Buttons", - "description": "Display all buttons", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20k()%7Bconsole.clear();function%20B(e,i)%7Bi.parentNode.insertBefore(e,i.nextSibling)%7Dfunction%20m(e)%7Blet%20i=window.getComputedStyle(e);return%20i.display===%22none%22%7C%7Ci.opacity===0%7C%7Ci.clipPath===%22inset(100%25)%22&&i.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ci.height===%221px%22&&i.width===%221px%22&&i.overflow===%22hidden%22%7Dfunction%20C(e)%7Blet%20i=window.getComputedStyle(e);i.position===%22absolute%22&&i.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),i.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),i.display===%22none%22&&(e.style.display=%22block%22),i.opacity===0&&(e.style.opacity=1)%7Dlet%20n=%22%22,r=%22%22,S=document.querySelectorAll(%22button,%5Brole=button%5D,input%5Btype=button%5D%22),c=1,g,y=0,f=%22%22,u=%22%22;Array.from(S).forEach(function(e)%7Blet%20i=document.createElement(%22div%22);i.appendChild(e.cloneNode(!0)),f=i.innerHTML;let%20b=!1,t=%22%22,w=e.querySelectorAll(%22img%22),o=!1,h=!1;b=w.length%3E0;let%20x=e.querySelector(%22%5Baria-hidden=true%5D%22);x&&x.classList.add(%22remove-from-accname%22),b&&Array.from(w).forEach(function(s)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),s.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+s.getAttribute(%22alt%22)+%22%20%22),B(d,s)%7D),e.setAttribute(%22data-button-ref%22,c);let%20l=e.textContent,A=e.querySelector(%22.remove-from-accname%22);A&&A.remove();let%20a=e.textContent;if(e.getAttribute(%22aria-label%22)&&(a=e.getAttribute(%22aria-label%22),t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-label%3C/code%3E.%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0,a.trim().toLowerCase().indexOf(l.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-label%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')),e.getAttribute(%22aria-labelledby%22))%7Blet%20s=e.getAttribute(%22aria-labelledby%22);s=s.replace(/:/g,%22%5C%5C:%22);let%20d=s.split(%22%20%22);d.length%3E1?(a=%22%22,Array.from(d).forEach(function(v)%7Bdocument.querySelector(%22#%22+v)?a+=document.querySelector(%22#%22+v).textContent+%22%20%22:a+=%22**%20aria-labelledby%20source%20is%20missing%20**%22%7D),a=a.trim(),t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0):(s=e.getAttribute(%22aria-labelledby%22),s=s.replace(/:/g,%22%5C%5C:%22),document.querySelector(%22#%22+s)?a=document.querySelector(%22#%22+s).textContent:a+=%22**%20aria-labelledby%20source%20is%20missing%20**%22,t+=%22-%20button%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,o=!0),a.trim().toLowerCase().indexOf(l.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-labelledby%20sources%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')%7Dm(e)&&(C(e),m(e)?t+=%22Button%20is%20hidden%3Cbr%3E%22:t+=%22Button%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),b&&(t+=%22%5Cu%7B1F304%7D%20Image%20button%3Cbr%3E%22),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)!==l&&(t+=%22-%20button%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20different%20from%20text%20content.%22,a!==%22%22&&(t+='This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E'),t+=%22%3Cbr%3E%22,o=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)===l&&(t+='-%20button%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20the%20same%20as%20the%20text%20content%20and%20therefore%20adds%20no%20extra%20useful%20information/context.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E',o=!0),e.tagName===%22BUTTON%22&&(e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22Button%20has%20a%20%3Ccode%3Etabindex%3C/code%3E%20but%20it%20is%20not%20needed%20because%20the%20%3Ccode%3Ebutton%3C/code%3E%20is%20natively%20focusable%3Cbr%3E%22),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Button%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',o=!0),e.getAttribute(%22role%22)===%22button%22&&(t+=%22Button%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Not%20needed%20as%20it%20is%20a%20%3Ccode%3Ebutton%3C/code%3E%20element%20that%20is%20a%20button%20by%20default%3Cbr%3E%22),e.getAttribute(%22aria-hidden%22)!==%22true%22&&e.getAttribute(%22tabindex%22)===%22-1%22&&(t+=%22-%20%3Ccode%3E<button>%3C/code%3E%20has%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%20which%20means%20it%20will%20not%20be%20keyboard-operable%3Cbr%3E%22,o=!0),e.getAttribute(%22aria-hidden%22)===%22true%22&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+='-%20%3Ccode%3E<button>%3C/code%3E%20has%20%3Ccode%3Earia-hidden=%22true%22%3C/code%3E%20but%20can%20still%20be%20focused%20by%20keyboard%20user%20as%20it%20does%20not%20have%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E',o=!0),e.getAttribute(%22role%22)&&e.getAttribute(%22role%22)!==%22button%22&&(t+='-%20%3Ccode%3E<button>%3C/code%3E%20has%20a%20%3Ccode%3Erole%3C/code%3E%20set%20that%20is%20not%20%3Ccode%3Ebutton%3C/code%3E.%20It%20is%20set%20to%20%22'+e.getAttribute(%22role%22)+'%22.%20This%20overrides%20the%20native%20role%20and%20will%20likely%20confused%20assistive%20tech%20users%3Cbr%3E',o=!0)),e.tagName===%22A%22&&(!e.getAttribute(%22href%22)&&!e.getAttribute(%22tabindex%22)&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E%20element,%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E%20or%20%3Ccode%3Etabindex%3C/code%3E,%20%20and%20therefore%20is%20not%20focusable%3Cbr%3E%22,o=!0),!e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E%20element,%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20but%20is%20focusable%20because%20it%20has%20been%20provided%20with%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E%22,o=!0),e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20button%20is%20based%20on%20an%20%3Ccode%3E<a>%3C/code%3E.%20It%20is%20focusable%20because%20there%20is%20a%20%3Ccode%3Etabindex%3C/code%3E%20present%3Cbr%3E%22,o=!0),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Button%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',o=!0)),e.tagName!==%22BUTTON%22&&e.tagName!==%22A%22&&e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E%20but%20is%20not%20a%20%3Ccode%3Ebutton%3C/code%3E%20element.%22,e.getAttribute(%22tabindex%22)===%22-1%22?t+=%22%3Cbr%3E-%20%3Cstrong%3ENote%3C/strong%3E:%20this%20button%20has%20a%20negative%20%3Ccode%3Etabindex%3C/code%3E%20and%20will%20not%20be%20keyboard-focusable.%22:t+=%22Check%20that%20it%20is%20keyboard-operable%20(should%20activate%20with%20%3Ckbd%3EEnter%3C/kbd%3E%20and%20%3Ckbd%3ESpace%3C/kbd%3E%20key)%3Cbr%3E%22,o=!0),a===%22%22?(e.getAttribute(%22title%22)?a=e.getAttribute(%22title%22):a=%22%5Cu203C%5CuFE0F%20Empty%20button%22,l=%22%5Cu203C%5CuFE0F%20Empty%20button%22,t+=%22%5Cu203C%5CuFE0F%20Empty%20button%3Cbr%3E%22,h=!0):l.trim()===%22%22&&(l=%22%5Cu203C%5CuFE0F%20No%20visible%20text%20on%20button%22),b&&a===%22%5Cu203C%5CuFE0F%20Empty%20button%22&&(t+=%22%20-%20image%20is%20missing%20alternative%20text%20content%3Cbr%3E%22),h&&(o=!1),r+=%22%3Ctr%22,r+='%20data-button-ref=%22'+c+'%22',o&&(r+='%20class=%22issue%20warn%22'),h&&(r+='%20class=%22issue%20err%22'),r+=%22%3E%22,e.tagName===%22BUTTON%22?g=%22%3Ccode%3E<button>%3C/code%3E%22:g='%3Ccode%3Erole=%22button%22%3C/code%3E',r+=%22%3Ctd%3E%22+g+%22%3C/td%3E%22,r+=%22%3Ctd%3E%22+l+%22%3C/td%3E%22,r+=%22%3Ctd%3E%22+a,a.trim()!==l.trim()&&l.trim()!==%22%22&&(r+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),r+=%22%3C/td%3E%22,r+=%22%3Ctd%3E%22,o&&(r+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20button%3C/div%3E'),h&&(r+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20button%3C/div%3E'),u=%22Button%20'%22+l.trim()+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+f+%60%0A---------------%0A%60,r+=t+'%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+c+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+c+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+f+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',r+='%3Ctd%3E%3Cbutton%20data-button-ref=%22'+c+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',r+=%22%3C/tr%3E%22,c++,(o%7C%7Ch)&&y++,h&&(u=u.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(u))%7D),n='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkgreen;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:button,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20buttons%20on%20this%20page.%3C/h1%3E',n+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20buttons%20where%20there%20*may*%20be%20issues%20('+y+%22%20found)%3C/label%3E%22,n+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20buttons%20on%20page%3C/button%3E',n+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20buttons%20(<button>%20or%20elements%20with%20role=%22button%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3EButton%20type%3C/th%3E%3Cth%20scope=%22col%22%3EButton%20text%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+r+%22%3C/tbody%3E%3C/table%3E%22,n+=%22%3Cscript%3Efunction%20showbtns()%7B%22,n+=%22var%20refWindow=window.opener;%22,n+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20buttonToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BbuttonToHighlight=%22%5Bdata-button-ref='%22%20+%20highlightButton.getAttribute(%22data-button-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(buttonToHighlight).focus();refWindow.document.querySelector(buttonToHighlight).style.outline=%224px%20dashed%20darkgreen%22;refWindow.document.querySelector(buttonToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(buttonToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,n+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',n+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',n+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7Bshowbtns();%7D);%3C%5C/script%3E';let%20p=window.open(%22%22,%22popUpWinButtons%22,%22height=800,width=1000%22);p.document.open(),p.document.write(n),p.document.close()%7Dk()%7D)();%7D)();%0A" - }, - { - "file": "character-keys.js", - "bookmarklet": "Character key shortcuts", - "description": "Test all printable character shortcut keys", - "source": "Detlev Fischer", - "sourceUrl": "http://3needs.org/en/testing/code/kb-shortcuts.html", - "tags": [ - "2.1.4 Character Key Shortcuts (A)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e,t=32,o=8365;n();function%20n()%7Bconsole.log(%22pressed:%20%22+t+%22:%20%22+String.fromCharCode(t)),e=document.createEvent(%22Event%22),e.initEvent(%22keydown%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),e=document.createEvent(%22Event%22),e.initEvent(%22keypress%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),e=document.createEvent(%22Event%22),e.initEvent(%22keyup%22,!0,!1),e.key=String.fromCharCode(t),e.which=t,e.keyCode=t,e.charCode=t,document.getElementsByTagName(%22BODY%22)%5B0%5D.dispatchEvent(e),t++,t%3Co&&(t==127&&(t=161),t==192&&(t=8364),window.setTimeout(n,20))%7D%7D)();%7D)();%0A" - }, - { - "file": "color-scheme.js", - "bookmarklet": "Toggle color scheme", - "description": "Switch between light and dark color scheme", - "source": "Thomas Orlita", - "sourceUrl": "https://github.com/ThomasOrlita/awesome-bookmarklets#dark-color-scheme", - "tags": [ - "css" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bdocument.documentElement.style.colorScheme=document.documentElement.style.colorScheme==%22dark%22?%22light%22:%22dark%22;%7D)();%0A" - }, - { - "file": "complex-table.js", - "bookmarklet": "Complex table", - "description": "Visualize headers and IDs in a complex table", - "source": "Jonathan Avila", - "sourceUrl": "https://labs.levelaccess.com/index.php/Complex_Tables_Favlet", - "tags": [ - "accessibility" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e=document.querySelectorAll(%22td,%20th%22),n,t=%5B%5D,d;if(e.length%3E0)%7Bfor(var%20l=0;l%3Ce.length;l++)%7Bif(e.item(l).hasAttribute(%22headers%22))%7Bn=e.item(l).getAttribute(%22headers%22),t=n.split(%22%20%22);for(var%20r=0;r%3Ct.length;r++)if(document.getElementById(t%5Br%5D))%7Bd=1;var%20a=document.createElement(%22Span%22),o=document.createTextNode(document.getElementById(t%5Br%5D).textContent+%22%20%22);a.appendChild(o),a.style.backgroundColor=%22antiqueWhite%22,a.style.color=%22black%22,e.item(l).appendChild(a)%7D%7Dn=%22%22,t=%22%22,o=%22%22%7Dd%7C%7Calert(%22no%20valid%20headers%20found%22)%7Delse%20alert(%22No%20table%20cells%20found%22)%7D)();%7D)();%0A" - }, - { - "file": "cursor-24x24.js", - "bookmarklet": "Cursor 24x24", - "description": "Change cursor to 24px by 24px circle", - "source": "Adrian Roselli", - "sourceUrl": "https://adrianroselli.com/2022/05/24x24-pixel-cursor-bookmarklet.html#Update01", - "tags": [ - "2.5.8 Target Size (Minimum) (2.2 AA)" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20o=document,c=%22AAR24pxBkmklt1%22,l=o.getElementById(c),r=o.querySelectorAll(%22iframe%22),A=0,a=r.length,d;if(l)%7Blet%20e=function(t)%7Bfor(var%20n%20of%20t.querySelectorAll(%22*%22))n.shadowRoot&&(n.shadowRoot.getElementById(c).remove(),e(n.shadowRoot))%7D;var%20i=e;if(l.remove(),a)for(A=0;A%3Ca;A++)try%7Br%5BA%5D.contentWindow.document.getElementById(c).remove(),e(r%5BA%5D.contentWindow.document)%7Dcatch(t)%7Bconsole.log(t)%7De(o)%7Delse%7Blet%20e=function(t)%7Bfor(var%20n%20of%20t.querySelectorAll(%22*%22))n.shadowRoot&&(n.shadowRoot.appendChild(d.cloneNode(!0)),e(n.shadowRoot))%7D;var%20m=e;for(d=o.createElement(%22style%22),d.id=c,d.appendChild(o.createTextNode(%22*%7B%20cursor:%20url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAS1BMVEUAAAAAAAD+/v4AAABRUVE/Pz/u7u74+Pi6urrS0tJ8fHwAAAAAAAD///////8AAAD///////8AAAAAAAD////////////+/v7////mqvA4AAAAGHRSTlMA/vq59/Tx7+3p5uXV0L+okoFrZE1DFvCfRm9hAAAAnElEQVQoz3WSWRKEIAxEQ9hXURa5/0lnxpHS0kp/kX5AIAmcKtyzrzwvcNcWhFE4Biojwnb5i7QYc+295ohWLtPnTqc2g5a04+d+t69w07q748wm9fQn0fKXJ9gEDyUbAIrA9gQNRQFu4owZm6toOHiV3yArDwzrG1RkwEb/u4dO1gcNyKvI5ORzyQ9SJSGLSJWdbBTdWnoYyPH5AN6eCUUIphirAAAAAElFTkSuQmCC)%2012%2012,%20auto%20!important%7D%22)),o.getElementsByTagName(%22head%22)%5B0%5D.appendChild(d),A=0;A%3Ca;A++)try%7Br%5BA%5D.contentWindow.document.getElementsByTagName(%22head%22)%5B0%5D.appendChild(d.cloneNode(!0)),e(r%5BA%5D.contentWindow.document)%7Dcatch(t)%7Bconsole.log(t)%7De(o)%7D%7D)();%7D)();%0A" - }, - { - "file": "cursor-44x44.js", - "bookmarklet": "Cursor 44x44", - "description": "Change cursor to 44px by 44px square", - "source": "Adrian Roselli", - "sourceUrl": "https://adrianroselli.com/2019/06/target-size-and-2-5-5.html#Update04", - "tags": [ - "2.5.5 Target Size (AAA)" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document.createElement(%22style%22),n=document.createTextNode(%22*%20%7B%20cursor:%20url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACwAAAAsCAYAAAAehFoBAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJBJREFUeNrs2dEKgDAIhWEN3/+VLYtBF12MppHwDxY0uvg4DJpORcSl0bB4uPcwq+oFHu8/956pbtJsAAYMGDBgwIABA044t3pMEgb8VU2XsWdn1o/aUUn4bchPBWNFYWvVidxbCFGmr7YULBs1YDPfsYcXEi9ryvDjAAwYMGDAgAED7nK8bHG7qNLs6nYXYAAheh5j8Qw5fwAAAABJRU5ErkJggg==)%2022%2022,%20auto%20!important%7D%22);t.appendChild(n);var%20a=document.getElementsByTagName(%22head%22);a%5B0%5D.appendChild(t),document.onkeydown=function(e)%7Bvar%20A;(%22key%22in(e=e%7C%7Cwindow.event)?e.key==%22Escape%22%7C%7Ce.key==%22Esc%22:e.keyCode==27)&&(A=document.createElement(%22style%22),document.head.appendChild(A),A.sheet.insertRule(%22*%7Bcursor:revert%20!important%7D%22,0))%7D%7D)();%7D)();%0A" - }, - { - "file": "design-mode-toggle.js", - "bookmarklet": "Design mode toggle", - "description": "Make all of the text on page editable", - "source": "Christoph Wagner", - "sourceUrl": "https://developer.mozilla.org/en-US/docs/Web/API/SecurityPolicyViolationEvent#examples", - "tags": [ - "diagnostic" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7Bdocument.designMode=document.designMode==%22on%22?%22off%22:%22on%22;%7D)();%0A" - }, - { - "file": "disable-css.js", - "bookmarklet": "Disable CSS", - "description": "Drop all page styles", - "source": "Sarah Higley", - "sourceUrl": "https://dorward.uk/software/disablecss/", - "tags": [ - "diagnostic", - "accessibility", - "css" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7Bfor(e=0;e%3Cdocument.styleSheets.length;e++)document.styleSheets.item(e).disabled=!0;var%20e,t=document.getElementsByTagName(%22*%22);for(e=0;e%3Ct.length;e++)t%5Be%5D.style.cssText=%22%22;%7D)();%0A" - }, - { - "file": "duplicate-ids.js", - "bookmarklet": "Duplicate IDs", - "description": "Display duplicated ID values", - "source": "Jonathan Avila", - "sourceUrl": "https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/duplicateIds.js", - "tags": [ - "accessibility" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7Bfunction%20u()%7Bvar%20t=document.cloneNode(!0),l=t.querySelectorAll(%22%5Bid%5D%22),e=%5B%5D;c(l,e);var%20n=e.length+%60%20elements%20with%20duplicate%20ids%0A%60;e.forEach(function(r)%7Br.innerHTML=%22%22,n=n+r.outerHTML+%60%0A%60%7D),alert(n)%7Dfunction%20c(t,l)%7Bt.forEach(function(e)%7Bvar%20n=document.querySelectorAll('%5Bid=%22'+e.id+'%22%5D');n.length%3E1&&l.push(e)%7D)%7Du();%7D)();%0A" - }, - { - "file": "find-duplicate-aria-roles.js", - "bookmarklet": "Find Duplicate ARIA Roles", - "description": "Roles appearing more than once for banner, contentinfo, and main", - "source": "Adrian Roselli", - "sourceUrl": "https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#ARIAdupes", - "tags": [ - "accessibility", - "HTML" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e=document.createElement(%22style%22),n;document.head.appendChild(e),n=e.sheet,n.insertRule(%22*%5Brole=main%5D:nth-of-type(n+2),*%5Brole=banner%5D:nth-of-type(n+2),*%5Brole=contentinfo%5D:nth-of-type(n+2),main:nth-of-type(n+2)%7Bborder:2px%20dotted%20#f00%20!important;background-color:#f00;%7D%22,0)%7D)();%7D)();%0A" - }, - { - "file": "focus-everything.js", - "bookmarklet": "Focus everything", - "description": "A technique for testing 1.3.2 Meaningful Sequence a tab path visualizer", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "1.3.2 Meaningful Sequence (A)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7Bdocument.querySelectorAll(%22body%20*%22).forEach(function(t)%7Bt.setAttribute(%22tabindex%22,%220%22)%7D);%7D)();%0A" - }, - { - "file": "force-focus.js", - "bookmarklet": "Force focus indicator", - "description": "Adds a 4 pixel solid orange outline around all focusable elements", - "source": "Paul J. Adam", - "sourceUrl": "https://pauljadam.com/bookmarklets/focus.html", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7Bvar%20e=document.createElement(%22style%22),t=document.createTextNode(%22a:focus,%20*:focus%20%7B%20outline:%204px%20solid%20orange%20!important;%20outline-offset:1px%20!important;%20%7D%22),n=document.getElementsByTagName(%22head%22);e.appendChild(t);n%5B0%5D.appendChild(e);%7D)();%0A" - }, - { - "file": "grayscale.js", - "bookmarklet": "Grayscale", - "description": "Show entire page in gray scale (no color)", - "source": "Level Access", - "sourceUrl": "https://labs.levelaccess.com/index.php/Grayscale_Favlet", - "tags": [ - "accessibility" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20e=document.createElement(%22style%22);e.type=%22text/css%22,e.appendChild(document.createTextNode(%22%22)),document.head.appendChild(e),e.sheet.insertRule(%22html%20%7B%20%20filter:%20grayscale(100%25)%20!important;%20-webkit-filter:%20grayscale(1)%20!important;%7D%22,e.sheet.cssRules.length)%7D)();%7D)();%0A" - }, - { - "file": "grouped-fields.js", - "bookmarklet": "Grouped fields", - "description": "Display grouped fields", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "accessibility" - ], - "dist": "javascript:void%20(()=%3E%7B(function()%7Bfunction%20b()%7Blet%20r=%22#662e2e%22,i=0;function%20a(e,l)%7Be.style.boxShadow=%220px%200px%200px%2010px%20white%22,e.style.outline=%225px%20solid%20%22+l,e.style.outlineOffset=%225px%22,i++%7Dfunction%20n(e,l,t)%7Blet%20o=document.createElement(%22span%22);o.innerHTML=l,o.style.display=%22inline-block%22,o.style.margin=%2220px%200%205px%20-10px%22,o.style.padding=%225px%22,o.style.background=t,o.style.fontWeight=%22bold%22,o.style.fontSize=%2218px%22,o.style.color=%22white%22,o.classList.add(%22group-description%22),e.parentNode.insertBefore(o,e)%7Dvar%20d,u=document.querySelectorAll(%22fieldset%22);console.log(u),Array.from(u).forEach(e=%3E%7Bconsole.log(e),a(e,r),e.querySelector(%22legend%22)&&n(e,'Group%20label%20(from%20fieldset%20%3E%20legend):%20%3Cbr%3E%3Cbr%3E%22'+e.querySelector(%22legend%22).textContent+'%22',r)%7D),r=%22#66482e%22,Array.from(document.querySelectorAll(%22%5Brole=group%5D%5Baria-label%5D,%5Brole=region%5D%5Baria-label%5D%22)).forEach(e=%3E%7Bconsole.log(e);let%20l=e.getAttribute(%22role%22).toLowerCase();a(e,r),n(e,%22Group%20label%20(from%20%5Brole=%22+l+'%5D%5Baria-label%5D):%20%3Cbr%3E%3Cbr%3E%22'+e.getAttribute(%22aria-label%22)+'%22',r)%7D),r=%22#662e43%22,Array.from(document.querySelectorAll(%22%5Brole=group%5D%5Baria-labelledby%5D,%5Brole=region%5D%5Baria-labelledby%5D%22)).forEach(e=%3E%7Bconsole.log(e);let%20l=e.getAttribute(%22role%22).toLowerCase();a(e,r);let%20t=%22Source%20for%20aria-labelledby%20is%20missing/broken%22;document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22))&&(t=document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22)).textContent),n(e,%22Group%20label%20(from%20%5Brole=%22+l+'%5D%5Baria-labelledby%5D):%20%3Cbr%3E%3Cbr%3E%22'+t+'%22',r)%7D),i===0&&alert(%22No%20grouped%20fields%20found%20on%20this%20page%22)%7Db()%7D)();%7D)();%0A" - }, - { - "file": "headings-console.js", - "bookmarklet": "Document outline in console", - "description": "Display level of all page headings in console", - "source": "Mu-An Chiou", - "sourceUrl": "https://github.com/muan/headings", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bvar%20a=%22%22;for(let%20t%20of%20document.querySelectorAll(%22h1,%20h2,%20h3,%20h4,%20h5,%20h6%22))%7Blet%20e=r(t);if(i(t)&&(t.offsetHeight%3E0%7C%7Ct.offsetWidth)&&e)%7Blet%20n=parseInt(t.tagName.match(/%5Cd/)%5B0%5D);a+=new%20Array((n-1)*2).fill(%22-%22).join(%22%22)+t.tagName.toLowerCase()+%22:%20%22+e+%60%0A%60%7D%7Dconsole.log(a);function%20r(t)%7Blet%20e=t.getAttribute(%22aria-labelledby%22);return(t.getAttribute(%22alt%22)%7C%7Ct.getAttribute(%22aria-label%22)%7C%7Ce&&o(document.getElementById(e))%7C%7Co(t)).trim()%7Dfunction%20o(t)%7Blet%20e=%22%22;for(let%20n%20of%20t.childNodes)e+=n%20instanceof%20HTMLElement?r(n):n.textContent%7C%7C%22%22;return%20e%7Dfunction%20i(t)%7Breturn!t.closest('%5Baria-hidden=%22%22%5D,%20%5Baria-hidden=%22true%22%5D')%7D%7D)();%0A" - }, - { - "file": "headings.js", - "bookmarklet": "Headings", - "description": "Display level of all page headings", - "source": "Jonathan Avila", - "sourceUrl": "https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/headings.js", - "tags": [ - "1.3.1 Info and Relationships (A)", - "2.4.6 Headings and Labels (AA)" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bfunction%20n(o)%7Bs(o);for(var%20a=%5B%22frame%22,%22iframe%22%5D,e=0;e%3Ca.length;e++)for(var%20r=o.getElementsByTagName(a%5Be%5D),l=0;l%3Cr.length;l++)try%7Bn(r%5Bl%5D.contentWindow.document)%7Dcatch%7B%7D%7Dfunction%20s(o)%7Bfor(var%20a=o.querySelectorAll(%22h1,h2,h3,h4,h5,h6,%5Brole='heading'%5D%22),e=0;e%3Ca.length;e++)%7Bvar%20r=a%5Be%5D.tagName+%22%20%22;a%5Be%5D.hasAttribute(%22role%22)&&(r=r+%22role=%22+a%5Be%5D.getAttribute(%22role%22)+%22%20%22),a%5Be%5D.hasAttribute(%22aria-level%22)&&(r=r+%22aria-level=%22+a%5Be%5D.getAttribute(%22aria-level%22));var%20l=document.createTextNode(r),t=document.createElement(%22span%22);t.style.color=%22black%22,t.style.backgroundColor=%22gold%22,t.style.fontSize=%22small%22,t.style.border=%22thin%20solid%20black%22,t.style.position=%22absolute%22,t.appendChild(l),a%5Be%5D.parentNode.insertBefore(t,a%5Be%5D),a%5Be%5D.style.border=%22thin%20solid%20magenta%22%7D%7Dn(document);%7D)();%0A" - }, - { - "file": "hide-cursor.js", - "bookmarklet": "Hide cursor", - "description": "Hides cursor from window to encourage keyboard use", - "source": "Iain Bean", - "sourceUrl": "https://iainbean.com/posts/2020/an-opinionated-guide-to-accessibility-testing/", - "tags": [ - "accessibility", - "2.1", - "2.1.1 (A)", - "2.1.2 (A)", - "2.1.4 (A)", - "WCAG", - "cursor" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7Bvar%20e=document.createElement(%22style%22),t=document.createTextNode('*%20%7B%20cursor:%20none%20!important;%20%7D%20body::after%7B%20position:%20absolute;%20top:%200;%20right:%204px;%20background-color:%20#000;%20color:%20#01ff70;%20z-index:%209999;%20font-size:%2016px;%20font-weight:%20400;%20padding:%203px%209px;%20outline:%204px%20solid%20#01ff70%20!important;%20content:%20%22hiding%20cursor%22;%7D'),o=document.getElementsByTagName(%22head%22);e.appendChild(t);o%5B0%5D.appendChild(e);%7D)();%0A" - }, - { - "file": "horizontal-scroll.js", - "bookmarklet": "Horizontal scroll", - "description": "Alert when a horizontal scrollbar appears", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20e=document.documentElement.clientWidth,o=!1;function%20n()%7Blet%20t=document.documentElement.clientWidth,i=document.body.scrollWidth%3Edocument.documentElement.clientWidth;i&&!o&&t%3Ce?(console.log(%60%25cHorizontal%20scrollbar%20detected!%25c%0AWindow%20width:%20%60+t+%60px%0AContent%20width:%20%60+document.body.scrollWidth+%60px%0AOverflow:%20%60+(document.body.scrollWidth-t)+%22px%22,%22color:%20#ff0000;%20font-size:%2014px;%20font-weight:%20bold;%22,%22color:%20inherit;%20font-size:%20inherit;%22),o=!0):i%7C%7C(o=!1),e=t%7Dwindow.addEventListener(%22resize%22,n),n(),console.log(%60%25cHorizontal%20scrollbar%20detector%20activated!%25c%0AResize%20the%20window%20to%20test.%60,%22color:%20#4CAF50;%20font-size:%2014px;%20font-weight:%20bold;%22,%22color:%20inherit;%20font-size:%20inherit;%22)%7D)();%7D)();%0A" - }, - { - "file": "html-link.js", - "bookmarklet": "HTML link", - "description": "Copy page title and URL in an HTML anchor", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "utility" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bvar%20t='%3Ca%20href=%22'+location.href+'%22%3E'+document.title+%22%3C/a%3E%22;window.prompt(%22HTML%20link:%22,t);%7D)();%0A" - }, - { - "file": "image-info.js", - "bookmarklet": "Image info", - "description": "Display image alt, role, title, aria-label, aria-labelledby", - "source": "Jonathan Avila", - "sourceUrl": "https://github.com/mraccess77/mraccess77.github.io/blob/master/favlets/images.js", - "tags": [ - "1.1.1 Non-text Content (A)", - "1.4.5 Images of Text (A)", - "2.4.4 Link Purpose (In Context) (A)" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7Bfunction%20b(l,e)%7Bd(l,e);for(var%20t=%5B%22frame%22,%22iframe%22%5D,o=0;o%3Ct.length;o++)for(var%20u=l.getElementsByTagName(t%5Bo%5D),i=0;i%3Cu.length;i++)try%7Bb(u%5Bi%5D.contentWindow.document,e)%7Dcatch%7Be.extFrameSrcList=e.extFrameSrcList+%60%0A%60+u%5Bi%5D.src,e.frameErrorCount=e.frameErrorCount+1%7Dreturn%20e%7Dfunction%20d(l,e)%7Bvar%20t=l.querySelectorAll(%22img,*%5Brole='image'%5D%22);e.foundCount=e.foundCount+t.length;var%20o,u=%5B%5D,i,n,a;if(t.length%3E0)for(var%20r=0;r%3Ct.length;r++)n=l.createElement(%22span%22),t.item(r).getAttribute(%22alt%22)?a='alt=%22'+t.item(r).getAttribute(%22alt%22)+'%22%20':t.item(r).hasAttribute(%22alt%22)?a='alt=%22%22%20':a=%22NO%20alt%20attribute!%20%22,t.item(r).getAttribute(%22title%22)&&(a=a+'title=%22'+t.item(r).getAttribute(%22title%22)+'%22%20'),t.item(r).getAttribute(%22aria-label%22)&&(a=a+'aria-label=%22'+t.item(r).getAttribute(%22aria-label%22)+'%22%20'),t.item(r).getAttribute(%22aria-labelledby%22)&&(a=a+'aria-labelledby=%22'+t.item(r).getAttribute(%22aria-labelledby%22)+'%22%20%5Cu2192%20'+l.getElementById(t.item(r).getAttribute(%22aria-labelledby%22)).innerHTML),n.appendChild(l.createTextNode(a)),n.style.backgroundColor=%22cyan%22,n.style.border=%22thin%20solid%20black%22,n.style.color=%22black%22,n.style.fontSize=%22small%22,n.zIndex=%2299999%22,t.item(r).style.border=%22thin%20dotted%20cyan%22,t.item(r).parentNode.insertBefore(n,t.item(r))%7Dfunction%20m(l)%7Bvar%20e=%5B%5D;e.foundCount=0,e.extFrameSrcList=%22%22,e.frameErrorCount=0,e=b(l,e),alert(e.foundCount+%22%20element(s)%20with%20alt,%20title,%20aria-label,%20aria-labelledby%20attributes%20found.%20%22)%7Dm(document);%7D)();%0A" - }, - { - "file": "images.js", - "bookmarklet": "Images", - "description": "Display all images", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "1.1.1 Non-text Content (A)", - "1.4.5 Images of Text (A)", - "2.4.4 Link Purpose (In Context) (A)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20f(e)%7Blet%20r=window.getComputedStyle(e);return%20r.display===%22none%22%7C%7Cr.opacity===0%7C%7Cr.clipPath===%22inset(100%25)%22&&r.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Cr.height===%221px%22&&r.width===%221px%22&&r.overflow===%22hidden%22%7Dfunction%20T(e)%7Blet%20r=window.getComputedStyle(e);r.position===%22absolute%22&&r.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),r.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),r.display===%22none%22&&(e.style.display=%22block%22),r.opacity===0&&(e.style.opacity=1)%7Dlet%20l=%22%22,o=%22%22,k=document.querySelectorAll(%22img,%5Brole=img%5D%22),d=1,u,m=0,b=%22%22,c=%22%22;Array.from(k).forEach(function(e)%7Blet%20r=document.createElement(%22div%22);r.appendChild(e.cloneNode(!0)),b=r.innerHTML;let%20t=%22%22,p=!1,y=!1,a=!1,n=!1,w=e.querySelector(%22%5Baria-hidden=true%5D%22);w&&w.classList.add(%22remove-from-accname%22),e.setAttribute(%22data-img-ref%22,d);let%20i=e.getAttribute(%22alt%22);i===null?(i=%22NO_ALT_ATTRIBUTE%22,p=!0):i===%22%22&&(i=%22EMPTY_ALT_ATTRIBUTE%22,y=!0);let%20s=i,A=e.getAttribute(%22src%22);if(f(e)&&(T(e),f(e)?t+=%22img%20is%20hidden.%3Cbr%3E%22:t+=%22img%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page.%3Cbr%3E%22),p&&(e.getAttribute(%22role%22)===%22img%22&&e.tagName!==%22IMG%22%7C%7C(t=%22-%20img%20has%20no%20%3Ccode%3Ealt%3C/code%3E%20attribute.%3Cbr%3E%22,n=!0)),y&&(t=%22-%20img%20has%20an%20empty%20%3Ccode%3Ealt%3C/code%3E%20attribute.%20This%20will%20hide%20it%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),(e.getAttribute(%22role%22)===%22presentation%22%7C%7Ce.getAttribute(%22role%22)===%22none%22)&&(t+=%22-%20img%20has%20a%20%3Ccode%3Erole%3C/code%3E%20set%20('%22+e.getAttribute(%22role%22)+%22')%20that%20will%20hide%20it%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),e.getAttribute(%22aria-hidden%22)===%22true%22&&(t+=%22-%20img%20has%20an%20%3Ccode%3Earia-hidden=true%3C/code%3E,%20so%20it%20will%20be%20hidden%20from%20AT.%20Is%20this%20correct?.%3Cbr%3E%22,a=!0),e.getAttribute(%22title%22)&&(i===%22EMPTY_ALT_ATTRIBUTE%22?(t+=%22-%20img%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20AND%20an%20empty%20%3Ccode%3Ealt%3C/code%3E%20attribute.%20Because%20of%20the%20empty%20alt,%20the%20image%20will%20be%20hidden%20to%20AT,%20so%20the%20title%20attribute%20is%20not%20used/exposed.%3Cbr%3E%22,a=!1,n=!0):(t+='-%20img%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20attribute.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users.%3Cbr%3E',p?n=!0:a=!0)),e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20img%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Check%20that%20it%20behaves%20like%20a%20%3Ccode%3Ebutton%3C/code%3E.%3Cbr%3E%22,a=!0),e.getAttribute(%22role%22)===%22img%22&&(t+=%22-%20Not%20an%20inline%20img,%20so%20no%20%3Ccode%3Ealt%3C/code%3E%20attribute.%3Cbr%3E%22),e.getAttribute(%22role%22)===%22img%22&&e.getAttribute(%22alt%22)!==null&&e.tagName!==%22IMG%22&&(t+=%22-%20Background%20image%20has%20an%20%3Ccode%3Ealt%3C/code%3E%20attribute%20specified,%20but%20cannot%20be%20applied%20to%20this%20element;%20can%20only%20be%20applied%20to%20%3Ccode%3Eimg%3C/code%3E%20element.%3Cbr%3E%22,a=!1,n=!0),e.tagName!==%22IMG%22&&e.getAttribute(%22role%22)===%22img%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Eimg%3C/code%3E%20but%20is%20not%20an%20%3Ccode%3Eimg%3C/code%3E%20element.%3Cbr%3E%22),e.getAttribute(%22role%22)===%22img%22)%7Blet%20h=!1;if(e.tagName!==%22IMG%22)%7Blet%20I=e.currentStyle%7C%7Cwindow.getComputedStyle(e,!1),S=I.backgroundImage.slice(4,-1).replace(/%22/g,%22%22);if(e.getAttribute(%22aria-label%22)!==null&&(h=!0,i=e.getAttribute(%22aria-label%22),s=i,t+=%22-%20Accessible%20name%20provided%20by%20an%20%3Ccode%3Earia-label%3C/code%3E%20attribute.%3Cbr%3E%22,a=!1),!h&&e.getAttribute(%22aria-labelledby%22)!==null)%7Bh=!0;let%20x=e.getAttribute(%22aria-labelledby%22).split(%22%20%22);x.length%3E1?(i=%22%22,Array.from(x).forEach(function(B)%7Bi+=document.querySelector(%22#%22+B).textContent+%22%20%22%7D),i=i.trim(),t+=%22-%20Image%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20image%20on%20screen%3Cbr%3E%22,a=!0):(i=document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22)).textContent,t+=%22-%20Image%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20image%20on%20screen%3Cbr%3E%22,a=!0),s=i%7D%7Dh%7C%7C(t+=%22-%20Image%20has%20no%20accessible%20name%20provided.%20It%20must%20be%20set%20using%20%3Ccode%3Earia-labelledby%3C/code%3E%20or%20%3Ccode%3Earia-label%3C/code%3E%20(not%20%3Ccode%3Ealt%3C/code%3E)%3Cbr%3E%22,n=!0)%7Ds===%22%22&&(e.getAttribute(%22title%22)?s=e.getAttribute(%22title%22):s=%22%5Cu203C%5CuFE0F%20No%20alt,%20no%20title%22,t+=%22%5Cu203C%5CuFE0F%20No%20alt.%3Cbr%3E%22,n=!0),n&&(a=!1),o+=%22%3Ctr%22,o+='%20data-img-ref=%22'+d+'%22',a&&(o+='%20class=%22issue%20warn%22'),n&&(o+='%20class=%22issue%20err%22'),o+=%22%3E%22,e.tagName===%22IMG%22?u=%22%3Ccode%3E<img>%3C/code%3E%22:u='%3Ccode%3Erole=%22img%22%3C/code%3E',(s===%22NO_ALT_ATTRIBUTE%22%7C%7Cs===%22EMPTY_ALT_ATTRIBUTE%22)&&(i=%22%22,s=%22%22),o+=%22%3Ctd%3E%22+u+%22%3C/td%3E%22,o+='%3Ctd%3E%3Cimg%20src=%22'+A+'%22%20alt=%22%22%20style=%22max-width:200px;max-height:200px;%22%3E%3C/td%3E',o+=%22%3Ctd%3E%22+s,s.trim()!==i.trim()&&i.trim()!==%22%22&&(o+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),o+=%22%3C/td%3E%22,s.trim()!==i.trim()&&s.trim().toLowerCase()===i.trim().toLowerCase()&&(t+=%22-%20Same%20text%20but%20case%20difference%20noted%20(likely%20not%20an%20issue)%22),o+=%22%3Ctd%3E%22,a&&(o+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20image%3C/div%3E'),n&&(o+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20image%3C/div%3E',c=%22Image%20'%22+A+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+b+%60%0A---------------%0A%60),o+=t+'%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+d+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+d+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+b+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',o+='%3Ctd%3E%3Cbutton%20data-img-ref=%22'+d+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',o+=%22%3C/tr%3E%22,d++,(a%7C%7Cn)&&(m++,c=c.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(c))%7D),l='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkred;%7D;div.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:img,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20images%20on%20this%20page.%3C/h1%3E',l+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20images%20where%20there%20*may*%20be%20issues%20('+m+%22%20found)%3C/label%3E%22,l+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20images%20on%20page%3C/button%3E',l+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20images%20(img%20elements%20or%20elements%20with%20role=%22img%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3EImage%20type%3C/th%3E%3Cth%3EImage%20thumbnail%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+o+%22%3C/tbody%3E%3C/table%3E%22,l+=%22%3Cscript%3Efunction%20showImages()%7B%22,l+=%22var%20refWindow=window.opener;%22,l+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20imgToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BimgToHighlight=%22%5Bdata-img-ref='%22%20+%20highlightButton.getAttribute(%22data-img-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(imgToHighlight).setAttribute(%22tabindex%22,%22-1%22);refWindow.document.querySelector(imgToHighlight).focus();refWindow.document.querySelector(imgToHighlight).style.outline=%2210px%20solid%20darkred%22;refWindow.document.querySelector(imgToHighlight).style.outlineOffset=%22-10px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(imgToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,l+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',l+='var%20imgsToCopy=document.querySelectorAll(%22.imgToCopy%22);Array.from(imgsToCopy).forEach(imgToCopy%20=%3E%20%7BimgToCopy.addEventListener(%22focus%22,%20e%20=%3E%20%7BimgToCopy.select();%7D);%7D);',l+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',l+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowImages();%7D);%3C%5C/script%3E';let%20g=window.open(%22%22,%22popUpWinImages%22,%22height=800,width=1000%22);g.document.open(),g.document.write(l),g.document.close()%7Dv()%7D)();%7D)();%0A" - }, - { - "file": "inline-styles.js", - "bookmarklet": "Inline styles", - "description": "Highlight all elements with style attributes", - "source": "Adrian Roselli", - "sourceUrl": "https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#inline", - "tags": [ - "utility" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7Bvar%20t=document.createElement(%22style%22),e=document.createTextNode('%5Bstyle%5D%7B%20position:%20relative;%20outline:%204px%20solid%20#01ff70%20!important;%7D%20%5Bstyle%5D:after%7B%20content:%20%22inline%20style%22;%20position:%20absolute;%20top:%200;%20right:%200;%20background-color:%20#000;%20color:%20#01ff70;%20z-index:%209999;%20font-size:%2012px;%20font-weight:%20400;%20padding:%201px%203px;%7D%20body::after%7B%20position:%20absolute;%20top:%200;%20right:%204px;%20background-color:%20#000;%20color:%20#01ff70;%20z-index:%209999;%20font-size:%2016px;%20font-weight:%20400;%20padding:%203px%209px;%20outline:%204px%20solid%20#01ff70%20!important;%20content:%20%22inline%20styles%22;%7D%7D'),o=document.getElementsByTagName(%22head%22);t.appendChild(e);o%5B0%5D.appendChild(t);%7D)();%0A" - }, - { - "file": "isolator.js", - "bookmarklet": "Isolator", - "description": "Isolate a portion of the page", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "accessibility" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20m(t)%7Blet%20a,o=t,s=t.tagName.toLowerCase(),i=%22%22,d=%22%22,l=%22%22,r=%22%22;for(;o.parentNode;)%7Bif((a=o.parentNode).tagName)%7Bi=a.tagName.toLowerCase();let%20c=a.querySelectorAll(%22:scope%20%3E%20%22+o.tagName);l=c.length%3E1?%22%5B%22+parseInt(Array.from(c).indexOf(o)+1)+%22%5D%22:%22%22,d=(s=o.tagName.toLowerCase())+l+r+d,r=%22/%22%7Do=a%7Dreturn%20i===%22%22&&(i=s),d=%22//%22+i+l+r+d%7Dfunction%20y()%7Blet%20t,a,o,s=!0,i=!1,d=document.querySelectorAll(%22*%22);function%20l(e,n)%7Bt=e,n.stopPropagation(),i%7C%7Cc(e),p(t)%7Dfunction%20r(e)%7Be.classList.remove(%22isolatorHighlight%22)%7Dfunction%20c(e)%7Be.classList.add(%22isolatorHighlight%22)%7Dfunction%20p(e)%7Bconsole.clear(),console.log(m(e)),o.innerHTML=m(e)%7DArray.from(d).forEach(e=%3E%7Be.addEventListener(%22click%22,n=%3E%7Bconsole.log(%22preventClicks%20=%20%22,s),s&&(function(f,u)%7Bt=f,f.tagName===%22HTML%22&&(s=!1),function(g)%7Bif(!i)%7Blet%20h=g.parentNode,v=h.childNodes;h.tagName!==%22HTML%22?Array.from(v).forEach(x=%3E%7Bx!==g&&x.remove()%7D):i=!0%7D%7D(f)%7D(e),n.preventDefault())%7D),e.addEventListener(%22mouseover%22,n=%3E%7Bt=e,n.stopPropagation(),i%7C%7Cc(e),p(t)%7D),e.addEventListener(%22mouseout%22,n=%3E%7Br(e)%7D)%7D),function()%7Blet%20e=document.createElement(%22style%22);e.textContent=%22.isolatorHighlight%7Boutline:4px%20solid%20black!important;outline-offset:-4px!important;-webkit-box-shadow:%200px%200px%200px%204px%20#fff;%20box-shadow:%200px%200px%200px%204px%20#fff;%7D#infoPanel%20%7Bz-index:1000;font-size:20px;background:rgba(0,0,0,0.8);color:#fff;font-weight:bold;padding:10px;position:fixed;bottom:20px;left:20px;font-family:sans-serif;%7D%20#infoPanel:empty%20%7Bvisibility:hidden;%7D%20#infoPanel%20code%20%7Bcolor:lime%7D%22,document.head.appendChild(e)%7D(),(o=document.createElement(%22div%22)).setAttribute(%22id%22,%22infoPanel%22),o.setAttribute(%22role%22,%22status%22),document.body.appendChild(o),document.addEventListener(%22keydown%22,function(e)%7Bif(e.key===%22ArrowUp%22&&(e.preventDefault(),t.parentNode&&t.tagName!==%22HTML%22&&(r(t),console.log(%22currentEl.parentNode%20=%20%22,t.parentNode),a=t.parentNode,c(t=a)),p(t),o.textContent=o.textContent+%22%20(Press%20Return%20to%20isolate%20this%20element)%22),e.key===%22ArrowLeft%22&&(e.preventDefault(),t.previousElementSibling&&(r(t),l(t=t.previousElementSibling,e))),e.key===%22ArrowRight%22&&(e.preventDefault(),t.nextElementSibling&&(r(t),l(t=t.nextElementSibling,e))),e.key===%22ArrowDown%22&&(e.preventDefault(),t.childNodes.length%3E1))%7Br(t);let%20n,f=!1;Array.from(t.childNodes).forEach(u=%3E%7Bu.nodeType!==1%7C%7Cf%7C%7C(f=!0,n=u)%7D),n&&l(t=n,e)%7De.key===%22Enter%22&&(e.preventDefault(),t.click())%7D),p(%22Isolator%20started.%20Click%20on%20element%20you%20want%20to%20isolate%20in%20the%20DOM%22)%7Dy()%7D)();%7D)();%0A" - }, - { - "file": "keyboard-visualizer.js", - "bookmarklet": "Keyboard visualizer", - "description": "Creates an overlay to display typed keys on the underlying page", - "source": "Sarah Higley", - "sourceUrl": "https://codepen.io/smhigley/pen/eYEjKQz", - "tags": [ - "utility" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bvar%20c=%60%0A.sh-keyboard-viz%20%7B%0A%20%20position:%20fixed;%0A%20%20bottom:%2020px;%0A%20%20right:%2020px;%0A%20%20width:%2050%25;%0A%20%20max-width:%20300px;%0A%20%20background:%20rgba(0,%200,%200,%200.75);%0A%20%20color:%20white;%0A%20%20padding:%2010px%2020px;%0A%20%20border-radius:%204px;%0A%20%20border:%202px%20solid%20white;%0A%20%20box-shadow:%200%200%205px%201px%20rgba(0,%200,%200,%200.75);%0A%20%20font-size:%2018px;%0A%20%20font-weight:%20bold;%0A%20%20font-family:%20sans-serif;%0A%20%20z-index:%20999999;%0A%20%20max-height:%20calc(100vh%20-%2060px);%0A%20%20display:%20flex;%0A%20%20flex-direction:%20column;%0A%7D%0A%0A.sh-keyboard-viz%20ul%20%7B%0A%20%20flex:%201%201%20auto;%0A%20%20list-style-type:%20none;%0A%20%20padding:%200;%0A%20%20margin:%200;%0A%20%20overflow-y:%20auto;%0A%7D%0A%0A.sh-keyboard-viz%20li%20%7B%0A%20%20margin-bottom:%208px;%0A%7D%0A%0A.sh-keyboard-viz%20h3%20%7B%0A%20%20flex:%200%200%20auto;%0A%20%20font-size:%2024px;%0A%20%20margin:%200;%0A%20%20padding:%2010px%200%2015px;%0A%7D%0A%60;function%20u(e,n)%7Blet%20t=document.createElement(%22li%22);t.innerHTML=s(n),e.appendChild(t);let%20i=window.setTimeout(()=%3E%7Bl(t)%7D,5e3);return%7Belement:t,timerId:i%7D%7Dfunction%20l(e)%7Blet%20n=e.parentNode;n&&n.removeChild(e)%7Dfunction%20f(e,n)%7Blet%7Belement:t,timerId:i%7D=e;return%20t.innerHTML+=s(n),window.clearTimeout(i),i=window.setTimeout(()=%3E%7Bl(t)%7D,2e4),%7Belement:t,timerId:i%7D%7Dfunction%20a(e)%7Breturn%20e.length===1&&e.match(/%5E%5Ba-z0-9!%22#$%25&'()*+,./:;%3C=%3E?@%5B%5C%5D%20%5E_%60%7B%7C%7D~-%5D*$/i).length%3E0%7Dfunction%20r(e)%7Breturn%5B%22control%22,%22shift%22,%22os%22,%22alt%22,%22fn%22,%22meta%22%5D.includes(e.toLowerCase())%7Dfunction%20s(e)%7Breturn%20r(e)?%60$%7Be%7D%20%60:e%7Dfunction%20h()%7Blet%20e=document.createElement(%22div%22);e.className=%22sh-keyboard-viz%22,e.setAttribute(%22role%22,%22region%22),e.setAttribute(%22aria-labelledby%22,%22sh-viz-heading%22);let%20n=document.createElement(%22h3%22);n.id=%22sh-viz-heading%22,n.innerText=%22Pressed%20Keys%22,e.appendChild(n);let%20t=document.createElement(%22ul%22);return%20e.appendChild(t),e%7Dfunction%20m()%7Blet%20e=document.querySelector(%22.sh-keyboard-viz%22);if(!e)%7Be=h(),document.body.appendChild(e);let%20o=document.createElement(%22style%22);o.appendChild(document.createTextNode(c)),document.head.appendChild(o)%7Dlet%20n=e.querySelector(%22ul%22),t,i=!1;document.body.addEventListener(%22keydown%22,o=%3E%7Blet%20d=o.key===%22%20%22?%22Space%22:o.key;r(d)&&(i%7C%7C(t=void%200),i=!0),!a(d)&&!i&&(t=void%200),t?f(t,d):t=u(n,d),n.scrollHeight%3En.clientHeight&&t.element.scrollIntoView(),!a(d)&&!i&&(t=void%200)%7D,!0),document.body.addEventListener(%22keyup%22,o=%3E%7Br(o.key)&&(i=!1,t=void%200)%7D,!0)%7Dm();%7D)();%0A" - }, - { - "file": "language.js", - "bookmarklet": "Language of page/parts", - "description": "Display all lang attributes on page", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "3.1.1 Language of Page (A)", - "3.1.2 Language of Parts (AA)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7Bvar%20a=document.querySelectorAll(%22%5Blang%5D%22),g=document.querySelector(%22html%5Blang%5D%22),t=%22%22;g?t+=%22The%20page%20lang%20attribute%20is%20%22+g.getAttribute(%22lang%22)+%60%0A%60:t+=%60Page%20is%20missing%20lang%20attribute%0A%60;for(e=0;e%3Ca.length;e++)t+=a%5Be%5D.tagName+%22%20tag%20has%20%22+a%5Be%5D.getAttribute(%22lang%22)+%60%0A%60;var%20e;alert(t);%7D)();%0A" - }, - { - "file": "links.js", - "bookmarklet": "Links", - "description": "Display all links", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20L(e,i)%7Bi.parentNode.insertBefore(e,i.nextSibling)%7Dfunction%20y(e)%7Blet%20i=window.getComputedStyle(e);return%20i.display===%22none%22%7C%7Ci.opacity===0%7C%7Ci.clipPath===%22inset(100%25)%22&&i.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ci.height===%221px%22&&i.width===%221px%22&&i.overflow===%22hidden%22%7Dfunction%20C(e)%7Blet%20i=window.getComputedStyle(e);i.position===%22absolute%22&&i.overflow===%22hidden%22&&(e.style.height=%22auto%22,e.style.width=%22auto%22,e.style.position=%22relative%22,e.style.overflow=%22visible%22,e.style.display=%22block%22,e.style.opacity=1),(e.getAttribute(%22hidden%22)===%22%22%7C%7Ce.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ce.getAttribute(%22hidden%22)===%22true%22)&&e.removeAttribute(%22hidden%22),i.visibility===%22hidden%22&&(e.style.visibility=%22visible%22),i.display===%22none%22&&(e.style.display=%22block%22),i.opacity===0&&(e.style.opacity=1)%7Dlet%20f,n=%22%22,o=%22%22,B=document.querySelectorAll(%22a,%5Brole=link%5D%22),l=1,p,w=0,g=%22%22,h=%22%22;Array.from(B).forEach(function(e)%7Blet%20i=document.createElement(%22div%22);i.appendChild(e.cloneNode(!0)),g=i.innerHTML;let%20u=!1,t=%22%22,A=e.querySelectorAll(%22img%22),a=!1,c=!1;u=A.length%3E0;let%20x=e.querySelector(%22%5Baria-hidden=true%5D%22);x&&x.classList.add(%22remove-from-accname%22),u&&Array.from(A).forEach(function(b)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),b.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+b.getAttribute(%22alt%22)+%22%20%22),L(d,b)%7D),e.setAttribute(%22data-link-ref%22,l);let%20s=e.textContent,k=e.querySelector(%22.remove-from-accname%22);k&&k.remove();let%20r=e.textContent;if(e.getAttribute(%22aria-label%22)&&(r=e.getAttribute(%22aria-label%22),t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-label%3C/code%3E%22,s.trim()!==%22%22&&(t+=%22%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22),a=!0,r.trim().toLowerCase().indexOf(s.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-label%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')),e.getAttribute(%22aria-labelledby%22))%7Blet%20d=e.getAttribute(%22aria-labelledby%22).split(%22%20%22);d.length%3E1?(r=%22%22,Array.from(d).forEach(function(S)%7Br+=document.querySelector(%22#%22+S).textContent+%22%20%22%7D),r=r.trim(),t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(multiple%20sources).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,a=!0):(r=document.querySelector(%22#%22+e.getAttribute(%22aria-labelledby%22)).textContent,t+=%22-%20Link%20gets%20accessible%20name%20from%20%3Ccode%3Earia-labelledby%3C/code%3E%20(single%20source).%20Check%20that%20the%20accessible%20name%20does%20not%20contradict%20the%20text%20on%20screen%3Cbr%3E%22,a=!0),r.trim().toLowerCase().indexOf(s.trim().toLowerCase())===-1&&(t+='-%20On-screen%20text%20does%20not%20appear%20in%20%3Ccode%3Earia-labelledby%20sources%3C/code%3E.%20Looks%20like%20a%20%3Ca%20href=%22https://www.w3.org/WAI/WCAG21/Understanding/label-in-name.html%22%20target=%22_blank%22%3E2.5.3%20Label%20In%20Name%3C/a%3E%20failure%3Cbr%3E')%7Dy(e)&&(C(e),y(e)?t+=%22Link%20is%20hidden%3Cbr%3E%22:t+=%22Link%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),u&&(t+=%22%5Cu%7B1F304%7D%20Image%20link%3Cbr%3E%22),e.getAttribute(%22role%22)===%22button%22&&(t+=%22-%20Link%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Ebutton%3C/code%3E.%20Check%20that%20it%20behaves%20like%20a%20%3Ccode%3Ebutton%3C/code%3E%20and%20is%20not%20used%20as%20navigation.%3Cbr%3E%22,a=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)!==s&&(t+='-%20Link%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20different%20from%20text%20content.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E',a=!0),e.getAttribute(%22title%22)&&e.getAttribute(%22title%22)===s&&(t+='Link%20has%20a%20%3Ccode%3Etitle%3C/code%3E%20which%20is%20the%20same%20as%20the%20text%20content%20and%20therefore%20adds%20no%20extra%20useful%20information/context.%20This%20%3Ccode%3Etitle%3C/code%3E%20content%20--%20%22'+e.getAttribute(%22title%22)+'%22%20--%20will%20not%20be%20perceivable%20to%20assistive%20tech,%20keyboard%20and%20touch%20screen%20users%3Cbr%3E'),e.tagName===%22A%22&&(e.getAttribute(%22href%22)===null&&!e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20is%20not%20keyboard-focusable%3Cbr%3E%22,a=!0),e.getAttribute(%22href%22)!==null&&!e.getAttribute(%22href%22)&&!e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20have%20an%20%3Ccode%3Ehref%3C/code%3E%20but%20it%20has%20no%20value,%20so%20it%20is%20keyboard-focusable%3Cbr%3E%22,a=!0),!e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22-%20Link%20does%20not%20have%20an%20%3Ccode%3Ehref%3C/code%3E,%20but%20is%20focusable%20because%20it%20has%20been%20provided%20with%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%3Cbr%3E%22,a=!0),e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&e.getAttribute(%22tabindex%22)!==%220%22&&(t+='-%20Link%20has%20a%20positive%20%3Ccode%3Etabindex%3C/code%3E%20(not%20-1%20or%200).%20Could%20cause%20a%20%3Ca%20href=%22https://www.w3.org/TR/WCAG21/#focus-order%22%20target=%22_blank%22%3E2.4.3%20Focus%20order%3C/a%3E%20failure.%3Cbr%3E',a=!0),e.getAttribute(%22href%22)&&e.getAttribute(%22tabindex%22)&&e.getAttribute(%22tabindex%22)!==%22-1%22&&(t+=%22Link%20has%20a%20%3Ccode%3Etabindex%3C/code%3E%20but%20it%20is%20not%20needed%20because%20the%20%3Ccode%3Ehref%3C/code%3E%20makes%20it%20focusable%3Cbr%3E%22),e.getAttribute(%22role%22)===%22link%22&&(t+=%22Link%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Elink%3C/code%3E.%20Not%20needed%20as%20it%20is%20an%20%3Ccode%3Ea%3C/code%3E%20element%20that%20is%20a%20link%20by%20default%3Cbr%3E%22)),e.tagName!==%22A%22&&e.getAttribute(%22role%22)===%22link%22&&(t+=%22-%20This%20has%20a%20%3Ccode%3Erole%3C/code%3E%20of%20%3Ccode%3Elink%3C/code%3E%20but%20is%20not%20an%20%3Ccode%3Ea%3C/code%3E%20element.%20Check%20that%20it%20is%20keyboard-operable%20(should%20activate%20with%20%3Ckbd%3EEnter%3C/kbd%3E%20key)%3Cbr%3E%22,a=!0),r===%22%22&&(e.getAttribute(%22title%22)?r=e.getAttribute(%22title%22):r=%22%5Cu203C%5CuFE0F%20Empty%20link%22,s=%22%5Cu203C%5CuFE0F%20Empty%20link%22,t+=%22%5Cu203C%5CuFE0F%20Empty%20link%3Cbr%3E%22,c=!0),u&&r===%22%5Cu203C%5CuFE0F%20Empty%20link%22&&(t+=%22%20-%20image%20is%20missing%20alternative%20text%20content%3Cbr%3E%22),e.href&&(f=e.href),c&&(a=!1),o+=%22%3Ctr%22,o+='%20data-link-ref=%22'+l+'%22',a&&(o+='%20class=%22issue%20warn%22'),c&&(o+='%20class=%22issue%20err%22'),o+=%22%3E%22,e.tagName===%22A%22?p=%22%3Ccode%3E<a>%3C/code%3E%22:p='%3Ccode%3Erole=%22link%22%3C/code%3E',o+=%22%3Ctd%3E%22+p+%22%3C/td%3E%22,o+=%22%3Ctd%3E%22+s+%22%3C/td%3E%22,o+=%22%3Ctd%3E%22+r,r.trim()!==s.trim()&&s.trim()!==%22%22&&(o+='%3Cdiv%20class=%22anDiff%22%3EAccessible%20name%20differs%3C/div%3E'),o+=%22%3C/td%3E%22,r.trim()!==s.trim()&&r.trim().toLowerCase()===s.trim().toLowerCase()&&(t+=%22-%20Same%20text%20but%20case%20difference%20noted%20(likely%20not%20an%20issue)%22),o+=%22%3Ctd%3E%22,a&&(o+='%3Cdiv%20class=%22issues%22%3EPossible%20issue(s)%20found%20with%20this%20link%3C/div%3E'),c&&(o+='%3Cdiv%20class=%22issues%22%3EDefinite%20issue(s)%20found%20with%20this%20link%3C/div%3E'),h=%22Link%20'%22+s.trim()+%60':%0A%60+t+%60Markup%20with%20issue:%0A%60+g+%60%0A---------------%0A%60,o+=t+'%3Ca%20href=%22'+f+'%22%20target=%22_blank%22%20aria-label=%22'+r+'%22%3E%5Cu%7B1F517%7D%3C/a%3E%20%3Clabel%20for=%22l'+l+'%22%3ELinks%20to:%3C/label%3E%3Cinput%20id=%22l'+l+'%22%20class=%22linkToCopy%22%20type=%22text%22%20value=%22'+f+'%22%3E%20%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+l+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+l+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+g+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',o+='%3Ctd%3E%3Cbutton%20data-link-ref=%22'+l+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',o+=%22%3C/tr%3E%22,l++,(a%7C%7Cc)&&w++,c&&(h=h.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(h))%7D),n='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:darkblue;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.anDiff%7Bcolor:red;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:red;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:link,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20links%20on%20this%20page.%3C/h1%3E',n+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20links%20where%20there%20*may*%20be%20issues%20('+w+%22%20found)%3C/label%3E%22,n+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20links%20on%20page%3C/button%3E',n+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20links%20(anchors%20or%20elements%20with%20role=%22link%22)%20on%20this%20page,%20the%20accessible%20name%20and%20any%20issues%20found%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%3ELink%20type%3C/th%3E%3Cth%20scope=%22col%22%3ELink%20text%3C/th%3E%3Cth%20scope=%22col%22%3EAccessible%20name%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+o+%22%3C/tbody%3E%3C/table%3E%22,n+=%22%3Cscript%3Efunction%20showLinks()%7B%22,n+=%22var%20refWindow=window.opener;%22,n+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20linkToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BlinkToHighlight=%22%5Bdata-link-ref='%22%20+%20highlightButton.getAttribute(%22data-link-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(linkToHighlight).focus();refWindow.document.querySelector(linkToHighlight).style.outline=%224px%20dashed%20darkblue%22;refWindow.document.querySelector(linkToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(linkToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,n+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',n+='var%20linksToCopy=document.querySelectorAll(%22.linkToCopy%22);Array.from(linksToCopy).forEach(linkToCopy%20=%3E%20%7BlinkToCopy.addEventListener(%22focus%22,%20e%20=%3E%20%7BlinkToCopy.select();%7D);%7D);',n+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',n+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowLinks();%7D);%3C%5C/script%3E';let%20m=window.open(%22%22,%22popUpWinLinks%22,%22height=800,width=1000%22);m.document.open(),m.document.write(n),m.document.close()%7Dv()%7D)();%7D)();%0A" - }, - { - "file": "markdown-link.js", - "bookmarklet": "Markdown link", - "description": "Copy page title and URL in markdown link format", - "source": "Brian Cantoni", - "sourceUrl": "http://www.cantoni.org/2013/11/08/bookmarklet-copy-markdown-link", - "tags": [ - "utility" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bvar%20o=%22%5B%22+document.title+%22%5D(%22+location.href+%22)%22;window.prompt(%22Markdown%20link:%22,o);%7D)();%0A" - }, - { - "file": "non-underlined-links.js", - "bookmarklet": "Non-underlined links", - "description": "Display information about links without underlines", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "1.4.1 Use of Color (A)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;var%20l=%22%22;function%20y()%7Bconsole.clear();let%20c=!1,u=!1,i=!1,p=!1,k=document.querySelectorAll(%22a%22),f=0,h=!1,b=!1;function%20N(e,a,o)%7Blet%20n=%5Be,a,o%5D.map(function(t)%7Breturn(t/=255)%3C=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)%7D);return%20.2126*n%5B0%5D+.7152*n%5B1%5D+.0722*n%5B2%5D%7Dfunction%20x(e)%7Breturn%20e=(e=(e=e.replace(%22rgb(%22,%22%22)).replace(%22)%22,%22%22)).split(%22,%20%22)%7Dif(function()%7Blet%20e=document.createElement(%22style%22);e.textContent=%22.problem-highlight%20%7Boutline:5px%20solid%20darkred;outline-offset:3px;box-shadow:%200px%200px%200px%2010px%20#fff;%7D%22,document.head.appendChild(e)%7D(),Array.from(k).forEach(e=%3E%7Bif(h=!1,b=!1,p=function(a,o)%7Bfor(;(a=a.parentElement)&&!(a.matches%7C%7Ca.matchesSelector).call(a,o););return%20a%7D(e,%22nav,%5Brole=navigation%5D%22),e.childNodes.length%3E0&&(e.childNodes%5B0%5D.tagName&&(e.childNodes%5B0%5D.tagName.toUpperCase()!==%22IMG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22SVG%22&&e.childNodes%5B0%5D.tagName.toUpperCase()!==%22FIGURE%22%7C%7C(h=!0)),!function(a)%7Bc=!1,u=!1,i=!1;let%20o=getComputedStyle(a);for(let%20n=0;n%3Co.length;n++)%7Blet%20t=o%5Bn%5D,r=o.getPropertyValue(t);t===%22text-decoration-line%22&&r===%22underline%22&&(u=!0),t!==%22border-bottom-style%22%7C%7Cr!==%22solid%22&&r!==%22dotted%22&&r!==%22dashed%22%7C%7C(i=!0),t===%22border-bottom-color%22&&r===%22transparent%22&&(i=!1),(u%7C%7Ci)&&(c=!0)%7Dreturn%20c%7D(e)&&!h))%7Bl+=%60-------%0A%60,l+=%22Link%20text:%20%22+e.textContent+%60%0A%60,p%7C%7C(function(o)%7Bo.classList.add(%22problem-highlight%22)%7D(e),l+=%22Affected%20node%20(xpath):%20%22+function(o)%7Blet%20n,t=o,r=o.tagName.toLowerCase(),s=%22%22,d=%22%22,m=%22%22,g=%22%22;for(;t.parentNode;)%7Bif((n=t.parentNode).tagName)%7Bs=n.tagName.toLowerCase();let%20C=n.querySelectorAll(t.tagName);m=C.length%3E1?%22%5B%22+parseInt(Array.from(C).indexOf(t)+1)+%22%5D%22:%22%22,d=(r=t.tagName.toLowerCase())+m+g+d,g=%22/%22%7Dt=n%7Dreturn%20s===%22%22&&(s=r),d=%22//%22+s+m+g+d%7D(e)+%60%0A%60,f++);let%20a=function(o,n)%7Blet%20t=N(o%5B0%5D,o%5B1%5D,o%5B2%5D),r=N(n%5B0%5D,n%5B1%5D,n%5B2%5D);return(Math.max(t,r)+.05)/(Math.min(t,r)+.05)%7D(x(getComputedStyle(e).color),x(getComputedStyle(e.parentNode).color));p?l+=%60Link%20is%20inside%20a%20%3Cnav%3E%20element%20and%20therefore%20its%20position/display%20does%20not%20require%20the%20underline%20for%20it%20to%20be%20perceived%20as%20a%20link.%0A%60:(a%3C3&&(l+=%22%5Cu%7B1F6A8%7D%20Contrast%20between%20link%20text%20and%20parent%20text%20node%20is%20under%203:1.%20Ratio%20is%20%22+a.toFixed(2)+%22:1.%22),l+=%60%0A%20%20%20Very%20likely%20a%20%5BSC%201.4.1%20Use%20of%20Color%5D(https://www.w3.org/TR/WCAG21/#use-of-color)%20issue%0A%60)%7D%7D),f%3E0)%7Blet%20e=f+%22%20possible%20issues%20with%20non-underlined%20links%20found%22;l=e+%60%0A%60+l,alert(e+%22%20(check%20console%20for%20more%20details)%22)%7Delse%20alert(%22No%20non-underlined%20links%20found%20(outside%20of%20a%20navigation%20area)%22);console.log(l)%7Dy();var%20w=l%7D)();%7D)();%0A" - }, - { - "file": "page-link.js", - "bookmarklet": "Page link", - "description": "Copy page title and URL, separated by hyphens", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "utility" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bvar%20t=document.title+%22%20%5Cu2014%20%22+location.href;window.prompt(%22Plain%20text%20link:%22,t);%7D)();%0A" - }, - { - "file": "parsing-only.js", - "bookmarklet": "Parsing only", - "description": "Reduce HTML validation results to 4.1.1 Parsing (A) only", - "source": "Steve Faulkner", - "sourceUrl": "https://cdpn.io/stevef/debug/dyGeywr", - "tags": [ - "4.1.1 Parsing (A)" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20r=!0,i=%5B%22tag%20seen%22,%22Stray%20end%20tag%22,%22Bad%20start%20tag%22,%22violates%20nesting%20rules%22,%22Duplicate%20ID%22,%22first%20occurrence%20of%20ID%22,%22Unclosed%20element%22,%22not%20allowed%20as%20child%20of%20element%22,%22unclosed%20elements%22,%22not%20allowed%20on%20element%22,%22unquoted%20attribute%20value%22,%22Duplicate%20attribute%22%5D,o,l,s,e,t,n,a=0;if(o=i.join(%22%7C%22),l=document.getElementById(%22results%22),!l)%7Balert(%22No%20results%20container%20found.%22);return%7Dfor(s=l.getElementsByTagName(%22li%22),n=0;n%3Cs.length;n++)e=s%5Bn%5D,e.className!==%22%22&&(t=(e.innerText!==void%200?e.innerText:e.textContent)+%22%22,(t.match(o)===null%7C%7Cr==!0&&t.indexOf(%22not%20allowed%20on%20element%22)!==-1&&t.indexOf(%22ng-%22)!==-1)&&(e.style.display=%22none%22,e.className=e.className+%22%20steveNoLike%22,a++));alert(%22Complete.%20%22+a+%22%20items%20removed.%22)%7D)();%7D)();%0A" - }, - { - "file": "placeholder-contrast.js", - "bookmarklet": "Placeholder contrast checker", - "description": "Measure contrast of placeholder text", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "accessibility", - "1.4.3 Contrast (Minimum) (AA)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bfunction%20s(o,e,t)%7Blet%5Bl,r,c%5D=%5Bo,e,t%5D.map(n=%3E(n=n/255,n%3C=.03928?n/12.92:Math.pow((n+.055)/1.055,2.4)));return%20.2126*l+.7152*r+.0722*c%7Dfunction%20u(o,e)%7Blet%20t=Math.max(o,e),l=Math.min(o,e);return(t+.05)/(l+.05)%7Dfunction%20d(o)%7Breturn%20o.match(/%5Cd+/g).map(Number)%7Dfunction%20g(o)%7Blet%20e=document.createElement(%22style%22),t=%22temp-%22+Math.random().toString(36).substr(2,9);o.classList.add(t),e.textContent=%60.$%7Bt%7D::placeholder%20%7B%20background-color:%20inherit;%20%7D%60,document.head.appendChild(e);let%20r=window.getComputedStyle(o,%22::placeholder%22).color;return%20o.classList.remove(t),e.remove(),r%7Dlet%20i=document.querySelectorAll(%22input%5Bplaceholder%5D,%20textarea%5Bplaceholder%5D%22);console.group(%22Placeholder%20Contrast%20Analysis%22),console.log(%22Analyzing%20%22+i.length+%60%20form%20elements...%0A%60),i.forEach((o,e)=%3E%7Blet%20t=window.getComputedStyle(o),l=g(o),r=t.backgroundColor,c=d(l),n=d(r),p=s(...c),h=s(...n),a=u(p,h),m=o.tagName.toLowerCase()+(o.id?%22#%22+o.id:%22%22)+(o.className?%22.%22+o.className.split(%22%20%22).join(%22.%22):%22%22)+%22::placeholder%22;console.group(%60Element%20$%7Be+1%7D:%20$%7Bm%7D%60),console.log(%22Placeholder%20Text:%22,o.placeholder),console.log(%22Placeholder%20Color:%22,l),console.log(%22Background:%22,r),a%3C4.5?console.log(%22%5Cu%7B1F6D1%7D%20Contrast%20Ratio:%22,a.toFixed(2)):console.log(%22%5Cu2705%20Contrast%20Ratio:%22,a.toFixed(2)),console.groupEnd(),o.style.outline=a%3C4.5?%225px%20solid%20#ff0000%22:%222px%20solid#00ff00%22%7D),console.groupEnd()%7D)();%7D)();%0A" - }, - { - "file": "re-enable-selection.js", - "bookmarklet": "Re-enable selection", - "description": "Unset user-select CSS property", - "source": "Adrian Roselli", - "sourceUrl": "https://adrianroselli.com/2015/01/css-bookmarklets-for-testing-and-fixing.html#Selection", - "tags": [ - "diagnostic" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e=document.createElement(%22style%22),t;document.head.appendChild(e),t=e.sheet,t.insertRule(%22*%7Buser-select:unset%20!important%7D%22,0)%7D)();%7D)();%0A" - }, - { - "file": "service-html-validator.js", - "bookmarklet": "Validate", - "description": "Validate HTML of DOM", - "source": "Deque", - "sourceUrl": "https://dequeuniversity.com/validator", - "tags": [ - "4.1.1 Parsing (A)" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7B(function()%7Bvar%20t=document.doctype,d=%22%3C!DOCTYPE%20%22+t.name+(t.publicId?'%20PUBLIC%20%22'+t.publicId+'%22':%22%22)+(!t.publicId&&t.systemId?%22%20SYSTEM%22:%22%22)+(t.systemId?'%20%22'+t.systemId+'%22':%22%22)+%22%3E%22,m=document.documentElement.outerHTML,r=d+m,a=document.getElementById(%22deque-w3c-validator-bookmarklet%22);a&&a.remove();var%20e=document.createElement(%22form%22);e.id=%22deque-w3c-validator-bookmarklet%22,e.method=%22POST%22,e.action=%22https://validator.w3.org/nu/?showsource=yes&nocache=%22+Math.random(),e.target=%22_blank%22,e.enctype=%22multipart/form-data%22;var%20o=document.createElement(%22textarea%22);o.name=%22content%22,o.value=r,e.appendChild(o),document.body.appendChild(e),e.submit(),a=document.getElementById(%22deque-w3c-validator-bookmarklet%22),a&&a.remove()%7D)()%7D)();%7D)();%0A" - }, - { - "file": "service-internet-archive.js", - "bookmarklet": "Save to Internet Archive", - "description": "Submit current URL to the Internet Archive", - "source": "Jesse Gardner", - "sourceUrl": "https://plasticmind.com/0s-and-1s/bookmarklet-archive-to-wayback-machine/", - "tags": [ - "utility" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bwindow.open(%22https://web.archive.org/save/%22+escape(window.location));%7D)();%0A" - }, - { - "file": "service-lighthouse.js", - "bookmarklet": "Lighthouse report", - "description": "Run a Lighthouse scan on current URL (regardless of broswer)", - "source": "Jeremy Keith", - "sourceUrl": "https://adactio.com/journal/16523", - "tags": [ - "performance" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bwindow.open(%22https://googlechrome.github.io/lighthouse/viewer/?psiurl=%22+escape(window.location)+%22&strategy=mobile&category=performance&category=accessibility&category=best-practices&category=seo&category=pwa%22);%7D)();%0A" - }, - { - "file": "service-wave.js", - "bookmarklet": "WAVE report", - "description": "Run WebAIM WAVE on the current URL", - "source": "WebAIM", - "sourceUrl": "https://wave.webaim.org/help", - "tags": [ - "1.1.1 Non-text Content (A)", - "1.3.1 Info and Relationships (A)", - "1.4.3 Contrast (Minimum) (AA)", - "2.1.1 Keyboard (A)", - "2.2.1 Timing Adjustable (A)", - "2.2.2 Pause", - "Stop", - "Hide (A)", - "2.4.1 Bypass Blocks (A)", - "2.4.2 Page Titled (A)", - "2.4.4 Link Purpose (In Context) (A)", - "2.4.6 Headings and Labels (AA)", - "3.1.1 Language of Page (A)", - "3.3.2 Labels or Instructions (A)", - "4.1.2 Name", - "Role", - "Value (A)" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7Bwindow.open(%22https://wave.webaim.org/report?url=%22+escape(window.location));%7D)();%0A" - }, - { - "file": "show-focus-styles.js", - "bookmarklet": "Show focus styles", - "description": "Force visibility of all focus styles at the same time", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "2.4.7 Focus Visible (2.2 A)", - "2.4.11 Focus Appearance (2.2 AA)", - "2.4.12 Focus Not Obscured (2.2 AA", - "2.4.13 Focus Not Obscured (2.2 AAA)" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bfunction%20r()%7Blet%20s=document.querySelectorAll('a%5Bhref%5D,button,select,input:not(%5Btype=%22hidden%22%5D),textarea,summary,details,area,%5Btabindex%5D,%5Bcontenteditable%5D:not(%5Bcontenteditable=%22false%22%5D)'),t,o=%22%22;console.clear(),Array.from(s).forEach(function(e)%7Be.style.transition=%22none%22,e.focus(),t=getComputedStyle(e),o=%22%22;for(var%20n=0;n%3Ct.length;n++)cssProperty=t%5Bn%5D,cssValue=t.getPropertyValue(cssProperty),o+=cssProperty+%22:%22+cssValue+%22;%22;e.setAttribute(%22style%22,o)%7D)%7Dr()%7D)();%7D)();%0A" - }, - { - "file": "strip-onpaste.js", - "bookmarklet": "Remove onpaste", - "description": "Remove onpaste attributes from password inputs which fixes security theatre of preventing paste", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "utility" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7Bdocument.querySelectorAll(%22input%5Btype=password%5D%22).forEach(function(t)%7Breturn%20t.removeAttribute(%22onpaste%22)%7D);var%20e=document.createElement(%22style%22),o=document.createTextNode('body::after%7B%20position:%20absolute;%20top:%200;%20right:%204px;%20background-color:%20#000;%20color:%20#01ff70;%20z-index:%209999;%20font-size:%2016px;%20font-weight:%20400;%20padding:%203px%209px;%20outline:%204px%20solid%20#01ff70%20!important;%20content:%20%22removing%20onpaste%20attributes%22;%7D%7D'),n=document.getElementsByTagName(%22head%22);e.appendChild(o);n%5B0%5D.appendChild(e);%7D)();%0A" - }, - { - "file": "test-csp.js", - "bookmarklet": "Test CSP", - "description": "Test for errors related Content Security Policy (CSP)", - "source": "SecurityPolicyViolationEvent on MDN", - "sourceUrl": "https://developer.mozilla.org/en-US/docs/Web/API/SecurityPolicyViolationEvent#examples", - "tags": [ - "diagnostic" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bdocument.addEventListener(%22securitypolicyviolation%22,s,!1);var%20t=document.createElement(%22script%22);t.setAttribute(%22src%22,%22https://jsnmrs.github.io/bookmarklets/bookmarklets/test-js-external.js%22);document.body.appendChild(t);function%20s(e)%7B%22use%20strict%22;alert(e.violatedDirective+%22%20breaks%20Content%20Security%20Policy%20(CSP)%22)%7D%7D)();%0A" - }, - { - "file": "test-js-local.js", - "bookmarklet": "Test local JS", - "description": "Test for local JS support via bookmark", - "source": "Accessible Name and Description Inspector (ANDI) help page", - "sourceUrl": "https://www.ssa.gov/accessibility/andi/help/faq.html", - "tags": [ - "diagnostic" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Balert(%22Your%20browser%20is%20not%20blocking%20JavaScript%20in%20favorites/bookmarks%22);%7D)();%0A" - }, - { - "file": "text-spacing.js", - "bookmarklet": "Text spacing", - "description": "Test on WCAG 1.4.12 Text Spacing", - "source": "Steve Faulkner", - "sourceUrl": "https://codepen.io/stevef/pen/YLMqbo", - "tags": [ - "1.4.12 Text Spacing (AA)" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document,l=%22phltsbkmklt%22,c=t.getElementById(l),a=t.querySelectorAll(%22iframe%22),e=0,i=a.length;if(c)%7Blet%20o=function(n)%7Bfor(var%20d%20of%20n.querySelectorAll(%22*%22))d.shadowRoot&&(d.shadowRoot.getElementById(l).remove(),o(d.shadowRoot))%7D;var%20m=o;if(c.remove(),i)for(e=0;e%3Ci;e++)try%7Ba%5Be%5D.contentWindow.document.getElementById(l).remove(),o(a%5Be%5D.contentWindow.document)%7Dcatch(n)%7Bconsole.log(n)%7Do(t)%7Delse%7Blet%20o=function(n)%7Bfor(var%20d%20of%20n.querySelectorAll(%22*%22))d.shadowRoot&&(d.shadowRoot.appendChild(r.cloneNode(!0)),o(d.shadowRoot))%7D;var%20h=o,r=t.createElement(%22style%22);for(r.id=l,r.appendChild(t.createTextNode(%22*%7Bline-height:1.5%20!important;letter-spacing:0.12em%20!important;word-spacing:0.16em%20!important;%7Dp%7Bmargin-bottom:2em%20!important;%7D%22)),t.getElementsByTagName(%22head%22)%5B0%5D.appendChild(r),e=0;e%3Ci;e++)try%7Ba%5Be%5D.contentWindow.document.getElementsByTagName(%22head%22)%5B0%5D.appendChild(r.cloneNode(!0)),o(a%5Be%5D.contentWindow.document)%7Dcatch(n)%7Bconsole.log(n)%7Do(t)%7D%7D)();%7D)();%0A" - }, - { - "file": "text-zoom.js", - "bookmarklet": "Text zoom 200%", - "description": "Zoom text only (not page) size to 200%", - "source": "Ashlee M. Boyer", - "sourceUrl": "https://ashleemboyer.com/blog/an-accessibility-bookmarklet-for-testing-200-percent-text-size", - "tags": [ - "accessibility", - "1.4.4", - "WCAG" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7Blet%20e=document.querySelector(%22html%22),t=e.style.getPropertyValue(%22font-size%22)===%22200%25%22?null:%22200%25%22;e.style.setProperty(%22font-size%22,t)%7D)();%7D)();%0A" - }, - { - "file": "titles.js", - "bookmarklet": "Titles", - "description": "Display all titles", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "accessibility" - ], - "auditing": true, - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20v()%7Bconsole.clear();function%20k(t,e)%7Be.parentNode.insertBefore(t,e.nextSibling)%7Dfunction%20w(t)%7Blet%20e=window.getComputedStyle(t);return%20e.display===%22none%22%7C%7Ce.opacity===0%7C%7Ce.clipPath===%22inset(100%25)%22&&e.clip===%22rect(1px,%201px,%201px,%201px)%22%7C%7Ce.height===%221px%22&&e.width===%221px%22&&e.overflow===%22hidden%22%7Dfunction%20B(t)%7Blet%20e=window.getComputedStyle(t);e.position===%22absolute%22&&e.overflow===%22hidden%22&&(t.style.height=%22auto%22,t.style.width=%22auto%22,t.style.position=%22relative%22,t.style.overflow=%22visible%22,t.style.display=%22block%22,t.style.opacity=1),(t.getAttribute(%22hidden%22)===%22%22%7C%7Ct.getAttribute(%22hidden%22)===%22hidden%22%7C%7Ct.getAttribute(%22hidden%22)===%22true%22)&&t.removeAttribute(%22hidden%22),e.visibility===%22hidden%22&&(t.style.visibility=%22visible%22),e.display===%22none%22&&(t.style.display=%22block%22),e.opacity===0&&(t.style.opacity=1)%7Dlet%20o=%22%22,i=%22%22,E=document.querySelectorAll(%22body%20%5Btitle%5D,iframe%22),l=1,b=0,y=0,g=%22%22,a,c=%22%22;Array.from(E).forEach(function(t)%7Ba=%22No%22,(t.getAttribute(%22tabindex%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22%7C%7C(t.tagName===%22INPUT%22%7C%7Ct.tagName===%22BUTTON%22%7C%7Ct.tagName===%22TEXTAREA%22%7C%7Ct.tagName===%22SELECT%22%7C%7Ct.tagName===%22IFRAME%22%7C%7Ct.tagName===%22A%22)&&t.getAttribute(%22tabindex%22)!==%22-1%22&&!t.disabled)&&(a=%22Yes%22);let%20e=document.createElement(%22div%22);e.appendChild(t.cloneNode(!0)),g=e.innerHTML;let%20s=%22%22,r=!1,n=!1;t.setAttribute(%22data-title-ref%22,l);let%20x=!1,A=t.querySelectorAll(%22img%22);if(x=A.length%3E0,x)%7Blet%20S=%22%22;Array.from(A).forEach(function(m)%7Blet%20d=document.createElement(%22SPAN%22);d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22aria-hidden%22,%22true%22),m.getAttribute(%22alt%22)?d.textContent=%22%20%22+m.getAttribute(%22alt%22)+%22%20%22:d.textContent=%22**%20Image%20with%20empty%20or%20missing%20alt%20**%22,k(d,m)%7D)%7Dlet%20p=t.textContent;t.tagName===%22IMG%22&&(p=t.getAttribute(%22alt%22));let%20u=p,h=t.getAttribute(%22title%22);u===null&&(u=%22%22),h===null&&(h=%22%22),w(t)&&(B(t),w(t)?s+=%22-%20Element%20is%20hidden%3Cbr%3E%22:s+=%22-%20Element%20*was*%20hidden%20but%20has%20been%20temporarily%20revealed%20on%20the%20page%3Cbr%3E%22),n&&(r=!1),i+=%22%3Ctr%22,i+='%20data-title-ref=%22'+l+'%22',u.trim()===h.trim()?(r=!1,n=!1):t.tagName!==%22IFRAME%22&&(r=!1,n=!0,b++,s+=%22-%20The%20title%20text%20differs%20from%20the%20on-screen%20text.%3Cbr%3E%22,a===%22Yes%22&&(s+=%22-%20This%20is%20an%20interactive%20element,%20but%20the%20title%20attribute%20*may*%20be%20ignored%20by%20assistive%20tech%20(depending%20on%20user%20settings).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20As%20this%20is%20a%20non-interactive%20element,%20the%20title%20attribute%20will%20be%20ignored%20by%20assistive%20tech.%3Cbr%3E%22)),t.tagName===%22IFRAME%22&&h.trim()===%22%22&&(r=!1,n=!0,b++,s+=%22An%20%3Ccode%3Eiframe%3C/code%3E%20MUST%20have%20a%20title%20attribute.%3Cbr%3E%22),r&&(i+='%20class=%22warn%22'),n&&(i+='%20class=%22issue%20err%22'),i+=%22%3E%22,i+=%22%3Ctd%3E%22+p+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22+h+%22%3C/td%3E%22,u.trim()===h.trim()&&u.trim()!==%22%22&&(s+=%22-%20title%20text%20is%20identical%20to%20on-screen%20text%20(superfluous,%20but%20not%20harmful).%3Cbr%3E%22),a===%22No%22&&(s+=%22-%20This%20is%20not%20an%20interactive/focusable%20element.%20The%20title%20attribute%20will%20not%20be%20available%20to%20anyone%20expect%20mouse%20users%20(touch%20screen,%20keyboard-only,%20assistive%20tech%20users%20all%20excluded).%3Cbr%3E%22),i+=%22%3Ctd%3E%22+a+%22%3C/td%3E%22,i+=%22%3Ctd%3E%22,r&&(i+='%3Cdiv%20class=%22issues%22%3EPossible%20title%20issue%20found%20with%20this%20element%3C/div%3E'),n&&(i+='%3Cdiv%20class=%22issues%22%3EDefinite%20title%20issue%20found%20with%20this%20element%3C/div%3E'),c=%22Element%20with%20title%20'%22+p.trim()+%60':%0A%60+s+%60Markup%20with%20issue:%0A%60+g+%60%0A---------------%0A%60,i+=s+'%3Cbr%3E%3Cbutton%20class=%22showSnippet%22%20type=%22button%22%20aria-label=%22Show%20markup%20snippet%22%20aria-expanded=%22false%22%3E%3Ccode%3E</>%3C/code%3E%3C/button%3E%3Cdiv%20class=%22snippet%22%20hidden%3E%3Clabel%20for=%22snip'+l+'%22%3EMarkup%20snippet%3C/label%3E%3Ctextarea%20id=%22snip'+l+'%22%20aria-label=%22Markup%20snippet%20for%20this%20node%22%3E'+g+'%3C/textarea%3E%3Cbutton%20type=%22button%22%20class=%22decrapulate%22%20aria-label=%22De-crapulate%20this%20markup%20snippet%22%3EDe-crapulate%3C/button%3E%3C/div%3E%3C/td%3E',i+='%3Ctd%3E%3Cbutton%20data-title-ref=%22'+l+'%22%20class=%22highlightButton%22%20type=%22button%22%20aria-pressed=%22false%22%20aria-label=%22Highlight%20this%20issue%20on%20the%20page%20visually%22%3EShow%3C/button%3E%3C/td%3E',i+=%22%3C/tr%3E%22,l++,(r%7C%7Cn)&&y++,n&&(c=c.split(%22%3Ccode%3E%22).join(%22%60%22).split(%22%3C/code%3E%22).join(%22%60%22).split(%22%3Cbr%3E%22).join(%60%0A%60).split(%60%0A%0A%60).join(%60%0A%60),console.log(c))%7D),o='%3Cstyle%3E%5Baria-pressed=true%5D%7Bcolor:white;background:rebeccapurple;%7Ddiv.issues%7Bfont-weight:bold;%7D;textarea%20%7Bmargin:5px%200;%7D.snippet%20label%20%7Bfont-weight:bold;font-size:0.8em;color:black;%7D.snippet%7Bbackground:#efefef;outline:1px%20solid%20#666;padding:5px;margin-top:5px;%7D.checkDiffs%7Bbackground:PapayaWhip;%7D.checkDiffs:after%7Bcontent:%22Accessible%20name%20differs%22;color:#a50202;font-weight:bold;font-size:10px;display:block%7D.warn%20%7Bbackground:lightyellow;%7D.err%20%7Bbackground:PapayaWhip;color:#a50202;%7D.visually-hidden,.a11y,.visuallyhidden,.sr-text,.sr-only%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D*%20%7B-webkit-box-sizing:%20border-box;box-sizing:%20border-box;%7Dhtml%20%7B/*border:%20.75em%20solid%20#fff;*/min-height:%20100vh;%7Dbody%20%7Bbackground:%20#f7f7f5;color:%20#333;font:%20400%20105%25/1.4%20%22Work%20Sans%22,%20sans-serif;margin:%201.5em%20auto;max-width:%2054em;width:%2090%25;%7Da:elWithTitle,a:visited%20%7Bborder-bottom:%201px%20solid%20rgba(42,%20122,%20130,%20.5);color:%20#2b7a82;text-decoration:%20none;%7Da:hover%20%7Bborder-bottom:%202px%20solid;color:%20#1e565c;%7Dbutton:focus,a:focus%20%7Bbox-shadow:%20none;outline-offset:%202px;outline:%203px%20solid%20rgba(42,%20122,%20130,%20.75);%7Da:focus%20%7Bborder-bottom:%20none;%7Da:active%20%7Bbackground:%20#333;color:%20#fff;%7Dcode%20%7Bfont-family:%20Consolas,%20monaco,%20monospace;-moz-tab-size:%204;tab-size:%204;text-transform:%20none;white-space:%20pre-wrap;color:brown;%7Dtextarea%20%7Bwidth:%20100%25%7Dlegend%20h2,%20legend%20h3%20%7Bmargin:%200;%7Dtable%20%7Bborder-collapse:%20collapse;%7Dth,td%20%7Bpadding:%2010px;border:2px%20solid%20#2b7a82;%7Dtable%20caption%20%7Bfont-weight:%20bold;text-align:%20left;margin:1em%200;%7D%3C/style%3E%3Ch1%3EList%20of%20elements%20with%20titles%20on%20this%20page.%3C/h1%3E',b%3E0&&(o+='%3Cinput%20type=%22checkbox%22%20id=%22showPotentialProblemsOnly%22%3E%3Clabel%20for=%22showPotentialProblemsOnly%22%3EShow%20only%20elements%20with%20definite%20title%20issues('+y+%22).%3C/label%3E%3Cbr%3E%22),o+='%20%3Cbutton%20class=%22highlightButtonAll%22%20type=%22button%22%20aria-pressed=%22false%22%3EHighlight%20all%20elements%20with%20%60title%60%20on%20page%3C/button%3E',o+='%3Ctable%20border=%221%22%20cellpadding=%225%22%3E%3Ccaption%3EAll%20things%20with%20title%20attributes%20on%20this%20page%3C/caption%3E%3Cthead%3E%3Ctr%20valign=top%3E%3Cth%20scope=%22col%22%3EOn-screen%20text%3C/th%3E%3Cth%3ETitle%20text%3C/th%3E%3Cth%3EInteractive?%3C/th%3E%3Cth%20scope=%22col%22%3ENotes%3C/th%3E%3Cth%3EHighlight%20on%20the%20page%3C/th%3E%3C/tr%3E%3C/thead%3E%3Ctbody%3E'+i+%22%3C/tbody%3E%3C/table%3E%22,o+=%22%3Cscript%3Efunction%20showElsWithTitles()%7B%22,o+=%22var%20refWindow=window.opener;%22,o+=%60var%20highlightButtons=document.querySelectorAll(%22.highlightButton%22);var%20titleToHighlight;Array.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.addEventListener(%22click%22,%20e%20=%3E%20%7BtitleToHighlight=%22%5Bdata-title-ref='%22%20+%20highlightButton.getAttribute(%22data-title-ref%22)%20+%20%22'%5D%22;if%20(highlightButton.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BrefWindow.document.querySelector(titleToHighlight).setAttribute(%22tabindex%22,%22-1%22);refWindow.document.querySelector(titleToHighlight).focus();refWindow.document.querySelector(titleToHighlight).style.outline=%224px%20dashed%20rebeccapurple%22;refWindow.document.querySelector(titleToHighlight).style.outlineOffset=%22-4px%22;highlightButton.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BrefWindow.document.querySelector(titleToHighlight).style.outline=%22%22;highlightButton.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);%7D);%60,o+='var%20highlightButtonAll=document.querySelector(%22.highlightButtonAll%22);highlightButtonAll.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(highlightButtonAll.getAttribute(%22aria-pressed%22)===%22false%22)%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22false%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22true%22);%7D%20else%20%7BArray.from(highlightButtons).forEach(highlightButton%20=%3E%20%7BhighlightButton.setAttribute(%22aria-pressed%22,%22true%22);highlightButton.click();%7D);highlightButtonAll.setAttribute(%22aria-pressed%22,%22false%22);%7D%7D);',o+='function%20hideGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.setAttribute(%22hidden%22,%22hidden%22);%7D);%7Dfunction%20showGoodRows()%7BArray.from(trsWithoutIssue).forEach(trWithoutIssue%20=%3E%20%7BtrWithoutIssue.removeAttribute(%22hidden%22);%7D);%7Dvar%20trsWithoutIssue=document.querySelectorAll(%22tbody%20tr:not(.issue)%22);var%20showProblemCheckbox=document.querySelector(%22#showPotentialProblemsOnly%22);showProblemCheckbox.addEventListener(%22click%22,%20e%20=%3E%20%7Bif%20(showProblemCheckbox.checked)%20%7BhideGoodRows();%7D%20else%20%7BshowGoodRows();%7D%7D);',o+='%7Dwindow.addEventListener(%22load%22,%20(event)%20=%3E%20%7BshowElsWithTitles();%7D);%3C%5C/script%3E';let%20f=window.open(%22%22,%22popUpWinTitles%22,%22height=800,width=1000%22);f.document.open(),f.document.write(o),f.document.close()%7Dv()%7D)();%7D)();%0A" - }, - { - "file": "tool-a11y-css.js", - "bookmarklet": "a11y.css", - "description": "Warns about possible risks and mistakes in HTML code", - "source": "Gaël Poupard", - "sourceUrl": "https://ffoodd.github.io/a11y.css/", - "tags": [ - "accessibility", - "css", - "external" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20e=document.createElement(%22LINK%22);e.href=%22https://rawgit.com/ffoodd/a11y.css/master/css/a11y-en.css%22,e.rel=%22stylesheet%22,e.media=%22all%22,document.body.appendChild(e)%7D)();%7D)();%0A" - }, - { - "file": "tool-andi.js", - "bookmarklet": "ANDI", - "description": "Accessible Name & Description Inspector is a free accessibility testing tool", - "source": "Accessible Solutions Branch of the Social Security Administration", - "sourceUrl": "https://www.ssa.gov/accessibility/andi/help/install.html", - "tags": [ - "accessibility", - "external" - ], - "auditing": true, - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document.createElement(%22script%22);t.setAttribute(%22src%22,%22https://www.ssa.gov/accessibility/andi/andi.js%22),document.body.appendChild(t)%7D)();%7D)();%0A" - }, - { - "file": "tool-aria-usage.js", - "bookmarklet": "ARIA usage", - "description": "Report on ARIA usage on current URL", - "source": "TPGi", - "sourceUrl": "https://thepaciellogroup.github.io/WAI-ARIA-Usage/WAI-ARIA_usage.html", - "tags": [ - "accessibility", - "external" - ], - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document.createElement(%22script%22);t.setAttribute(%22src%22,%22https://thepaciellogroup.github.io/WAI-ARIA-Usage/aria-usage.js%22),document.body.appendChild(t)%7D)();%7D)();%0A" - }, - { - "file": "tool-aria.js", - "bookmarklet": "ARIA", - "description": "Display ARIA information for accessibility testing", - "source": "Paul J. Adam", - "sourceUrl": "https://pauljadam.com/bookmarklets/aria.html", - "tags": [ - "accessibility", - "external" - ], - "dist": "javascript:void%20(()=%3E%7B(function()%7Bdocument.body.appendChild(document.createElement(%22script%22)).src=%22https://cdn.jsdelivr.net/gh/pauljadam/bookmarklets@master/aria.js%22;for(var%20t=document.getElementsByTagName(%22iframe%22),e=0;e%3Ct.length;e++)t%5Be%5D.contentDocument.body.appendChild(document.createElement(%22script%22)).src=%22https://cdn.jsdelivr.net/gh/pauljadam/bookmarklets@master/aria.js%22%7D)();%7D)();%0A" - }, - { - "file": "tool-contrast-checker.js", - "bookmarklet": "Contrast checker", - "description": "Contrast checker for color combinations", - "source": "WebAIM", - "sourceUrl": "https://webaim.org/resources/contrastchecker/bookmarklet", - "tags": [ - "1.4.1", - "1.4.3", - "1.4.11" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20s=document.getElementById(%22contrastletdragable%22);if(s==null)%7Bvar%20e=document.createElement(%22div%22);e.id=%22contrastletdragable%22,e.style.width=%22384px%22,e.style.position=%22absolute%22,e.style.right=%2220px%22,e.style.top=window.pageYOffset+20+%22px%22,e.style.zIndex=%2210000%22,e.style.boxSizing=%22content-box%22;var%20o=document.createElement(%22div%22);o.id=%22contrastletdragzone%22,o.style.width=%22100%25%22,o.style.height=%2215px%22,o.style.cursor=%22move%22,o.style.backgroundColor=%22#0f2c65%22,o.style.boxSizing=%22content-box%22,e.appendChild(o),document.body.appendChild(e);var%20n=document.createElement(%22button%22);n.id=%22contrastletclose%22,n.style.width=%2215px%22,n.style.height=%2215px%22,n.style.float=%22right%22,n.style.padding=%220%22,n.style.border=%220%22,n.style.borderTop=%221px%20solid%20#0f2c65%22,n.style.borderRight=%221px%20solid%20#0f2c65%22,n.setAttribute(%22aria-label%22,%22Close%20Contrast%20Checker%22),n.addEventListener(%22click%22,function()%7Be.remove()%7D,!1);var%20v=document.createTextNode(%22X%22);n.appendChild(v),o.appendChild(n);var%20d=document.createElement(%22iframe%22);d.src=%22https://webaim.org/resources/contrastchecker/mini?ver=1&a=%22+Math.random(),d.style.width=%22380px%22,d.style.height=%22368px%22,d.style.margin=%220px%22,d.style.borderStyle=%22solid%22,d.style.borderColor=%22#0f2c65%22,d.style.boxSizing=%22content-box%22,e.appendChild(d);let%20m=0,u=0,f=function(i)%7Bm=i.clientX,u=i.clientY,document.addEventListener(%22mousemove%22,p),document.addEventListener(%22mouseup%22,y)%7D,p=function(i)%7Blet%20h=i.clientX-m,t=i.clientY-u;e.style.top=%60$%7Be.offsetTop+t%7Dpx%60,e.style.left=%60$%7Be.offsetLeft+h%7Dpx%60,m=i.clientX,u=i.clientY%7D,y=function()%7Bdocument.removeEventListener(%22mousemove%22,p),document.removeEventListener(%22mouseup%22,y)%7D;e.addEventListener(%22mousedown%22,f),document.addEventListener(%22keyup%22,function(i)%7Bi.keyCode===27&&e.remove()%7D),d.addEventListener(%22keyup%22,function(i)%7Bi.keyCode===27&&e.remove()%7D),document.addEventListener(%22securitypolicyviolation%22,()=%3E%7Bd.remove();var%20i=document.createTextNode(%22The%20Content%20Security%20Policy%20on%20this%20page%20does%20not%20allow%20embedded%20iframes.%20The%20Contrast%20Checker%20Bookmarklet%20cannot%20run%20on%20this%20page.%20Press%20Esc%20to%20dismiss%20this%20message.%22);e.style.backgroundColor=%22#fff%22,e.appendChild(i)%7D)%7D%7D)();%7D)();%0A" - }, - { - "file": "tool-html-codesniffer.js", - "bookmarklet": "HTML CodeSniffer", - "description": "Checks HTML source code and detects violations of a defined coding standard", - "source": "Squiz Labs", - "sourceUrl": "https://squizlabs.github.io/HTML_CodeSniffer/", - "tags": [ - "accessibility", - "external" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20n=%22//squizlabs.github.io/HTML_CodeSniffer/build/%22,t=function(o,d)%7Bvar%20e=document.createElement(%22script%22);e.onload=function()%7Be.onload=null,e.onreadystatechange=null,d.call(this)%7D,e.onreadystatechange=function()%7B/%5E(complete%7Cloaded)$/.test(this.readyState)===!0&&(e.onreadystatechange=null,e.onload())%7D,e.src=o,document.head?document.head.appendChild(e):document.getElementsByTagName(%22head%22)%5B0%5D.appendChild(e)%7D,a=%7Bpath:n%7D;t(n+%22HTMLCS.js%22,function()%7BHTMLCSAuditor.run(%22WCAG2AA%22,null,a)%7D)%7D)();%7D)();%0A" - }, - { - "file": "tool-label-in-name.js", - "bookmarklet": "Label in name", - "description": "Display label in name", - "source": "Jonathan Avila", - "sourceUrl": "https://mraccess77.github.io/favlets/Label-in-name.js", - "tags": [ - "2.5.3 Label in Name (A)", - "external" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7Bfunction%20o(r)%7Bvar%20e=r.createElement(%22script%22);e.setAttribute(%22src%22,%22https://whatsock.github.io/w3c-alternative-text-computation/Sample%2520JavaScript%2520Recursion%2520Algorithm/recursion.js%22),r.head.appendChild(e),setTimeout(function()%7Bm(r)%7D,500);for(var%20n=%5B%22frame%22,%22iframe%22%5D,t=0;t%3Cn.length;t++)for(var%20a=r.getElementsByTagName(n%5Bt%5D),l=0;l%3Ca.length;l++)try%7Bo(a%5Bl%5D.contentWindow.document)%7Dcatch%7B%7D%7Dfunction%20s(r,e)%7Bvar%20n=e.id;labels=r.getElementsByTagName(%22label%22);for(var%20t=0;t%3Clabels.length;t++)if(labels%5Bt%5D.htmlFor==n)return%20labels%5Bt%5D%7Dfunction%20m(r)%7Bfor(var%20e=r.querySelectorAll(%22button,%20input,%20textarea,%20select,%20%5Btabindex='0'%5D,a%5Bhref%5D,summary%22),n,t,a=0;a%3Ce.length;a++)if(n=%22%22,n=getAccName(e%5Ba%5D),t=%22%22,(e%5Ba%5D.tagName==%22INPUT%22%7C%7Ce%5Ba%5D.tagName==%22SELECT%22%7C%7Ce%5Ba%5D.tagName==%22TEXTAREA%22)&&s(r,e%5Ba%5D)?t=s(r,e%5Ba%5D).textContent:e%5Ba%5D.tagName==%22INPUT%22&&e%5Ba%5D.hasAttribute(%22value%22)?t=e%5Ba%5D.getAttribute(%22value%22):t=e%5Ba%5D.textContent,t=t.trim(),t&&!n.name.includes(t))%7Bvar%20l=document.createElement(%22span%22);l.style.color=%22black%22,l.style.backgroundColor=%22gold%22,l.style.fontSize=%22small%22,l.style.border=%22thin%20solid%20black%22,l.style.position=%22absolute%22,l.appendChild(r.createTextNode(n.name)),e%5Ba%5D.parentNode.insertBefore(l,e%5Ba%5D)%7D%7Do(document);%7D)();%0A" - }, - { - "file": "tool-sa11y.js", - "bookmarklet": "Sa11y", - "description": "The accessibility quality assurance assistant", - "source": "Toronto Metropolitan University", - "sourceUrl": "https://ryersondmp.github.io/sa11y/demo/en/", - "tags": [ - "accessibility", - "external" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function(e)%7Be.body.appendChild(e.createElement(%22script%22)).src=%22https://cdn.jsdelivr.net/gh/ryersondmp/sa11y@latest/bookmarklet/sa11y-en.min.js%22%7D)(document);%7D)();%0A" - }, - { - "file": "truncation.js", - "bookmarklet": "Truncation", - "description": "Identify instances of text-overflow: ellipsis", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "accessibility" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bfunction%20s(e)%7Bfor(var%20l=e.cssRules%7C%7Ce.rules,t=0;t%3Cl.length;t++)%7Bvar%20r=l%5Bt%5D;if(r.style&&r.style.textOverflow===%22ellipsis%22)%7Bvar%20f=document.querySelectorAll(r.selectorText);f.forEach(function(u)%7Bu.style.border=%225px%20solid%20red%22%7D)%7D%7D%7Dvar%20o=document.querySelectorAll(%22style%22);o.forEach(function(e)%7Bs(e.sheet)%7D);var%20c=document.querySelectorAll('link%5Brel=%22stylesheet%22%5D');c.forEach(function(e)%7Bvar%20l=e.sheet;l&&s(l)%7D);var%20n=document.querySelectorAll(%22*%22);n.forEach(function(e)%7Be.style.textOverflow===%22ellipsis%22&&(e.style.border=%225px%20solid%20red%22)%7D)%7D)();%7D)();%0A" - }, - { - "file": "user-agent.js", - "bookmarklet": "User Agent", - "description": "Display current user agent string", - "source": "Thomas Orlita", - "sourceUrl": "https://github.com/ThomasOrlita/awesome-bookmarklets#get-user-agent", - "tags": [ - "diagnostic" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7Bprompt(%22User%20agent:%22,navigator.userAgent);%7D)();%0A" - }, - { - "file": "viewport.js", - "bookmarklet": "Viewport", - "description": "Display viewport width and height", - "source": "jakob-e", - "sourceUrl": "https://codepen.io/jakob-e/pen/qEZZox/top/", - "tags": [ - "diagnostic" - ], - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=document,n=window,i=t.body,e,o,d=%22top%22,p=%22left%22;if(n.vpbkmklt)%7Bi.removeChild(t.getElementById(%22vpbkmklt1%22)),i.removeChild(t.getElementById(%22vpbkmklt2%22)),n.vpbkmklt=0;return%7De=t.createElement(%22style%22),e.setAttribute(%22id%22,%22vpbkmklt1%22),e.innerText=%22.foo%7B%20content:bar;%7D%22,i.appendChild(e),e=t.createElement(%22script%22),e.setAttribute(%22id%22,%22vpbkmklt2%22),e.innerText=%22var%20u=undefined,d=document,w=window,b=d.body;s=d.getElementById('vpbkmklt1'),or=function()%7Bb.setAttribute('data-vp','width:%20%20'+w.innerWidth+'px%5C%5Cnheight:%20'+w.innerHeight+'px');%7D,dc=function(e)%7B%20%20%20x=(e!==u%20&&%20e.x/w.innerWidth%20%3E%20.5)?'right':'left';%20%20%20y=(e!==u%20&&%20e.y/w.innerHeight%20%3E%20.5)?'bottom':'top';if(e!==u%20)%7Bconsole.log(e.x/w.innerWidth);%7D%20%20s.innerText='body:before%7B'+y+':5px;'+x+':5px;content:attr(data-vp);background:#000;color:#01ff70;white-space:pre;display:inline-block;padding:5px;position:fixed;opacity:0.95;-webkit-font-smoothing:subpixel-antialiased;font:11px/1.4%20monospace;z-index:9999%20!important;%7D';%20%7D;%22,i.appendChild(e),n.vpbkmklt=1,n.onresize=or,t.ondblclick=dc,or(),dc()%7D)();%7D)();%0A" - }, - { - "file": "window-1280x1024.js", - "bookmarklet": "Open 1280x1024", - "description": "Opens a new window with the current URL at 1280x1024", - "source": "Mike in a CSS Tricks article comment", - "sourceUrl": "https://css-tricks.com/snippets/javascript/1024x768-bookmarklet/#comment-1766738", - "tags": [ - "1.4.4 Resize Text (AA)", - "1.4.10 Reflow (AA)" - ], - "auditing": true, - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=%22w%22+new%20Date().getTime(),o=%22toolbar=yes,location=yes,status=yes,resizable=yes,favorites=yes,width=1280,height=1024,left=0,top=0%22,e=document.createElement(%22P%22);e.innerHTML='%3Ca%20href=%22#%22%20id=%22'+t+%60%22%20target=%22_blank%22%20onclick=%22window.open(window.location.href,%20'',%20'%60+o+%60'%20);%20return%20false;%22%3E%3C/a%3E%3C/p%3E%60,document.body.appendChild(e),document.getElementById(t).click()&&document.body.removeChild(e)%7D)();%7D)();%0A" - }, - { - "file": "window-320x256.js", - "bookmarklet": "Open 320x256", - "description": "Opens a new window with the current URL at 320x256", - "source": "Mike in a CSS Tricks article comment", - "sourceUrl": "https://css-tricks.com/snippets/javascript/1024x768-bookmarklet/#comment-1766738", - "tags": [ - "1.4.10 Reflow (AA)" - ], - "pageTest": true, - "dist": "javascript:void%20(()=%3E%7B(function()%7Bvar%20t=%22w%22+new%20Date().getTime(),o=%22toolbar=yes,location=yes,status=yes,resizable=yes,favorites=yes,width=320,height=256,left=0,top=0%22,e=document.createElement(%22P%22);e.innerHTML='%3Ca%20href=%22#%22%20id=%22'+t+%60%22%20target=%22_blank%22%20onclick=%22window.open(window.location.href,%20'',%20'%60+o+%60'%20);%20return%20false;%22%3E%3C/a%3E%3C/p%3E%60,document.body.appendChild(e),document.getElementById(t).click()&&document.body.removeChild(e)%7D)();%7D)();%0A" - }, - { - "file": "wtfocus.js", - "bookmarklet": "WTFocus", - "description": "Display information with focusable elements", - "source": "Ian Lloyd", - "sourceUrl": "https://a11y-tools.com/bookmarklets/", - "tags": [ - "2.4.4 Link Purpose (In Context) (A)", - "4.1.2 Name", - "Role", - "Value (A)" - ], - "auditing": true, - "pageTest": "self", - "dist": "javascript:void%20(()=%3E%7B(function()%7B%22use%20strict%22;function%20re()%7Blet%20z=document.activeElement,H=document.querySelectorAll('a%5Bhref%5D,button,select,input:not(%5Btype=%22hidden%22%5D),textarea,summary,area,%5Btabindex%5D:not(#WTFocusPanel):not(%5Btabindex%5E=%22-1%22%5D),%5Bcontenteditable%5D:not(%5Bcontenteditable=%22false%22%5D)'),E=%22background:#fff;color:darkgreen;font-weight:bold;text-decoration:line-through%22,j=%22font-weight:bold;color:#99f170;background:#333;display:inline-block;padding:3px;%22,h=%22color:pink;background:#333;padding:3px;%22,A=%22color:black;background:#fefbe3;font-weight:bold;%22,a=document.createElement(%22div%22),O=document.createElement(%22div%22),R=20,Y=400,w=7,ie='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F449%7D%5Cu%7B1F3FD%7D%3C/span%3E%3Cspan%20class=%22visually-hidden%22%3EAccessible%20name%20provided%20by%3C/span%3E%20',ce='%3Cspan%20aria-hidden=%22true%22%3E%5Cu%7B1F6A8%7D%3C/span%3E%20%3Cspan%20class=%22visually-hidden%22%3EWarning%3C/span%3E',V,P=%22Accessible%20name:%20%22,k=!1,p=%22%22,m=!1,x=!1,I=!1,G=!1,L=!1;function%20W()%7Bm=!1,x=!1%7Dfunction%20l(e,r,o,n,C)%7Bk&&(r=r.split(%22%3C%22).join(%22<%22).split(%22%3E%22).join(%22>%22),p+=%22%3Cli%22,(C%7C%7Cn)&&(p+='%20class=%22',C&&(p+=%22visible%22),n&&(p+=%22outline%22),p+='%22'),p+='%20role=%22listitem%22%3E%3Cspan%20style=%22'+o+'%22%3E',m&&(p+=ie),x&&(p+=ce),p+=e+%22%3C/span%3E %22+r+%60%3C/li%3E%0A%60),r=r.replace(%22<%22,%22%3C%22).replace(%22>%22,%22%3E%22),console.log(%22%25c%22+e+'%22'+r+'%22',o)%7Dfunction%20J()%7Blet%20e=document.createElement(%22button%22);e.textContent=%22Close%20(Esc)%22,e.setAttribute(%22type%22,%22button%22),e.setAttribute(%22class%22,%22panel-btn%22),e.addEventListener(%22click%22,()=%3E%7BD()%7D);let%20r=document.createElement(%22button%22);r.textContent=%22Change%20Mode%20(M)%22,r.setAttribute(%22type%22,%22button%22),r.setAttribute(%22class%22,%22panel-btn%22),r.addEventListener(%22click%22,o=%3E%7BK()%7D),a.appendChild(e),a.appendChild(r)%7Dfunction%20K()%7BL?(document.querySelector(%22#WTFocusPanel%22).classList.remove(%22curtainsMode%22),document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22),document.querySelector(%22#WTFocusCurtain%22).setAttribute(%22hidden%22,%22hidden%22),L=!1,P=%22Accessible%20name:%20%22):(document.querySelector(%22#WTFocusPanel%22).classList.add(%22curtainsMode%22),document.querySelector(%22#WTFocusCurtain%22).removeAttribute(%22hidden%22),L=!0,P=%22%22),Q(z),z.focus()%7Dfunction%20D()%7Bdocument.querySelector(%22#WTFocusCurtain%22).remove(),document.querySelector(%22#WTFocusPanel%22).remove(),document.querySelector(%22#panelStyles%22).remove(),document.querySelector(%22#focusStyles%22).remove()%7Dfunction%20Q(e)%7Blet%20r=e.getBoundingClientRect(),o=document.documentElement.scrollTop,n=r.right+R+Y,C=a.offsetHeight,q=o+r.top+C,i=window.innerWidth,c=window.innerHeight;L?document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22style%22):n%3Ei?(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=%22auto%22,a.style.right=i-r.left+R-w+%22px%22,a.classList.add(%22toLeft%22)):(q%3Ec?(a.style.top=%22auto%22,a.style.bottom=c-(o+r.bottom)-10+%22px%22,a.classList.add(%22toBottom%22)):(a.style.top=o+r.top+%22px%22,a.style.bottom=%22auto%22,a.classList.remove(%22toBottom%22)),a.style.left=r.right+R-w+%22px%22,a.style.right=%22auto%22,a.classList.remove(%22toLeft%22))%7Dconsole.clear(),function()%7Blet%20e=document.createElement(%22style%22);e.setAttribute(%22type%22,%22text/css%22),e.setAttribute(%22id%22,%22panelStyles%22),e.textContent=%22.dupeAccName%20%7Boutline:4px%20dashed%20#CC3300!important;outline-offset:%22+w+%22px!important;overflow:visible;%7D%20.WTFocusTempFocusStyle:focus%20%7Boutline:%22+w+%22px%20solid%20black!important;outline-offset:%22+w+%22px!important;overflow:visible;/*background:yellow!important;color:black!important;*/%7D%20.WTFocusTempFocusStyle.dupeAccName:focus%20%7Boutline-color:#CC3300!important;%7D%20.visually-hidden%20%7Bclip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%7D#WTFocusCurtain%20%7Bbackground:black;position:%20fixed;top:%200;bottom:%200;left:%200;right:%200;z-index:49999%7D%22,document.querySelector(%22body%22).appendChild(e)%7D(),document.querySelector(%22#WTFocusCurtain%22)&&D(),k=!0,p=%22%22,function(e)%7Blet%20r=document.createElement(%22style%22);r.setAttribute(%22type%22,%22text/css%22),r.setAttribute(%22id%22,%22focusStyles%22),r.textContent=%22#WTFocusPanel.error%20%7Bbackground:darkred;%7D%20#WTFocusPanel.warning%20%7Bbackground:#CC3300;%7D%20#WTFocusPanel.curtainsMode.error%20%7Bbackground:black;%7D%20#WTFocusPanel.curtainsMode%20%7Bz-index:50000;position:fixed;top:50%25;left:50%25;transform:translate(-50%25,-50%25);%7D%20#WTFocusPanel.curtainsMode.warning%20%7Bbackground:black;%7D%20#WTFocusPanel%5Bhidden%5D%20%7Bdisplay:none;%7D%20#WTFocusPanel%20*%20%7Btext-align:left%7D%20#WTFocusPanel%20%7Bborder:2px%20solid%20#fff;z-index:1000;text-shadow:none;font-family:sans-serif;display:block;text-align:left;position:%20absolute;z-index:10000;background:%20black;padding:%2020px%2020px;width:%22+e+%22px;font-size:16px;%7D%20#WTFocusPanel%20button%20%7Bfont-weight:bold;background:none;color:#fff;padding:3px%2010px;font-size:14px;border:1px%20solid%20#fff;display:inline-block;margin:10px%201em%20-10px%200;%7D%20#WTFocusPanel%20ul,#WTFocusPanel%20li%20%7Bmargin:0;padding:0;list-style:none%7D%20#WTFocusPanel%20li%20%7Bmargin:3px%200;background:#fff;color:#333;padding:2px%7D%20#WTFocusPanel%20li.outline%20%7Boutline:4px%20solid%20rgb(58,%20190,%2058);outline-offset:-4px;padding:8px%7D%20#WTFocusPanel.error:before%20%7Bbackground:darkred%7D%20#WTFocusPanel.warning:before%20%7Bbackground:#CC3300%7D%20#WTFocusPanel:before%20%7Bcontent:'';display:block;height:20px;width:20px;transform:rotate(45deg);position:absolute;background:#000;left:-12px;top:3px;border:2px%20solid%20#fff;border-right:none;border-top:none;%7D%20#WTFocusPanel.toBottom:before%20%7Btop:auto;bottom:3px%7D%20#WTFocusPanel.toLeft:before%20%7Bleft:auto;right:-12px;border:2px%20solid%20#fff;border-left:none;border-bottom:none;%7D%20#WTFocusPanel.curtainsMode%20%7Boutline:10px%20solid%20orange;%7D%20#WTFocusPanel.curtainsMode:before%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li%20%7Bdisplay:none;%7D%20#WTFocusPanel.curtainsMode%20li.visible%20%7Bdisplay:block;%7D%20#WTFocusPanel.curtainsMode%20li%20span%20%7Bdisplay:none!important;%7D%20%22,document.querySelector(%22head%22).appendChild(r)%7D(Y),O.setAttribute(%22id%22,%22WTFocusCurtain%22),O.setAttribute(%22hidden%22,%22hidden%22),document.querySelector(%22body%22).appendChild(O),a.setAttribute(%22id%22,%22WTFocusPanel%22),L&&a.setAttribute(%22class%22,%22curtainsMode%22),a.setAttribute(%22aria-live%22,%22polite%22),a.setAttribute(%22tabindex%22,%22-1%22),a.setAttribute(%22hidden%22,%22hidden%22),a.setAttribute(%22role%22,%22region%22),a.setAttribute(%22aria-label%22,%22Accessibility%20properties%20panel%22),document.querySelector(%22body%22).appendChild(a),window.addEventListener(%22keyup%22,e=%3E%7Be.key===%22Escape%22&&document.querySelector(%22#WTFocusPanel%22)&&D()%7D),window.addEventListener(%22keyup%22,e=%3E%7Be.key.toLowerCase()===%22m%22&&document.querySelector(%22#WTFocusPanel%22)&&K()%7D),J();let%20U=%5B%5D;Array.from(H).forEach(function(e)%7Be.classList.add(%22WTFocusTempFocusStyle%22);let%20r=e.querySelectorAll(%22style%22);Array.from(r).forEach(function(o)%7Bo.remove()%7D),e.addEventListener(%22focus%22,()=%3E%7Blet%20o=e.getAttribute(%22role%22),n=e.tagName.toLowerCase();if(console.clear(),!o)%7Bif(n!=%22article%22&&n!=%22button%22&&n!=%22dialog%22&&n!=%22figure%22&&n!=%22img%22&&n!=%22main%22&&n!=%22math%22%7C%7C(o=n),n==%22summary%22&&(o=%22button%22),n==%22aside%22&&(o=%22complementary%22),n==%22dd%22&&(o=%22definition%22),n==%22html%22&&(o=%22document%22),n!=%22details%22&&n!=%22fieldset%22&&n!=%22optgroup%22%7C%7C(o=%22group%22),n!=%22menu%22&&n!=%22ol%22&&n!=%22ul%22%7C%7C(o=%22list%22),n==%22datalist%22&&(o=%22listbox%22),n==%22li%22&&(o=%22listitem%22),n==%22nav%22&&(o=%22navigation%22),n==%22progress%22&&(o=%22progressbar%22),n==%22hr%22&&(o=%22separator%22),n==%22output%22&&(o=%22status%22),n!=%22dfn%22&&n!=%22dt%22%7C%7C(o=%22term%22),n==%22a%22&&(o=%22link%22),n==%22select%22&&(o=%22listbox%22),n==%22textarea%22&&(o=%22textbox%22),n==%22input%22)%7Blet%20t=e.getAttribute(%22type%22).toLowerCase();t===%22text%22&&(o=%22textbox%22),t===%22range%22&&(o=%22slider%22),t===%22number%22&&(o=%22spinbutton%22),t!==%22checkbox%22&&t!==%22radio%22%7C%7C(o=t),t!==%22button%22&&t!==%22image%22&&t!==%22reset%22&&t!==%22submit%22%7C%7C(o=%22button%22)%7D%7Dz=e,Array.from(H).forEach(function(t)%7Bt.classList.remove(%22dupeAccName%22)%7D);let%20C=!1;m=!1,x=!1;let%20q=e.querySelectorAll(%22img,%20%5Brole='image'%5D%5Baria-label%5D,%20%5Brole='img'%5D%5Baria-label%5D%22);(C=q.length%3E0)&&Array.from(q).forEach(function(t)%7Blet%20d=document.createElement(%22SPAN%22);var%20T,B;d.setAttribute(%22class%22,%22visually-hidden%22),d.setAttribute(%22style%22,%22clip-path:%20inset(100%25);clip:%20rect(1px,%201px,%201px,%201px);height:%201px;overflow:%20hidden;position:%20absolute;white-space:%20nowrap;width:%201px;%22),d.setAttribute(%22data-temp-node%22,%22true%22),t.getAttribute(%22alt%22)&&(d.textContent=%22%20%22+t.getAttribute(%22alt%22)+%22%20%22),t.getAttribute(%22role%22)&&t.getAttribute(%22aria-label%22)&&(d.textContent=%22%20%22+t.getAttribute(%22aria-label%22)+%22%20%22),T=d,(B=t).parentNode.insertBefore(T,B.nextSibling)%7D),setTimeout(function()%7Be.classList.add(%22WTFocusTempFocusStyle%22)%7D,100),p=%22%22;let%20i=e.tagName.toLowerCase(),c=e.getAttribute(%22role%22);c&&(c=e.getAttribute(%22role%22).toLowerCase());let%20Z=%22%3C%22+i+%22%3E%22,_=!1,$=!1;c&&(Z=%22%3C%22+i+'%20role=%22'+c+'%22%3E',(c===%22link%22&&i===%22a%22%7C%7Cc===%22button%22&&i===%22button%22%7C%7Cc===%22image%22&&i===%22img%22%7C%7Cc===%22img%22&&i===%22img%22%7C%7Cc===%22navigation%22&&i===%22nav%22%7C%7Cc===%22heading%22&&(i===%22h1%22%7C%7Ci===%22h2%22%7C%7Ci===%22h3%22%7C%7Ci===%22h4%22%7C%7Ci===%22h5%22%7C%7Ci===%22h6%22))&&(_=!0),(c===%22link%22&&i!==%22a%22%7C%7Cc===%22button%22&&i!==%22button%22%7C%7C(c===%22image%22%7C%7Cc===%22image%22)&&i!==%22img%22%7C%7Cc===%22navigation%22&&i!==%22nav%22%7C%7Cc===%22heading%22&&i!==%22h1%22&&i!==%22h2%22&&i!==%22h3%22&&i!==%22h4%22&&i!==%22h5%22&&i!==%22h6%22)&&($=!0));let%20ee,b=e.textContent,f=e.ariaLabel,S=e.getAttribute(%22aria-labelledby%22),N=e.getAttribute(%22placeholder%22),F=%22%22,g=e.getAttribute(%22value%22),v=e.getAttribute(%22title%22),s=%22%22,y=%22%22,te=!1,oe=!1,u=%22%22,ne=!1;k&&Q(e),b=b.trim();let%20ae=function(t,d)%7Bfor(;(t=t.parentElement)&&!(t.matches%7C%7Ct.matchesSelector).call(t,d););return%20t%7D(e,%22label%22);if(ae&&(te=!0,s=y=ae.textContent.trim()),e.getAttribute(%22id%22))%7Blet%20t=document.querySelector(%22%5Bfor='%22+e.getAttribute(%22id%22)+%22'%5D%22);t&&(oe=!0,y=t.textContent)%7Dif(te%7C%7Coe%7C%7C(y=%22N/A%22),b%7C%7C(b=%22N/A%22),g%7C%7C(g=%22N/A%22),v%7C%7C(v=%22N/A%22),N%7C%7C(N=%22N/A%22),f%7C%7C(f=%22N/A%22),S)%7Blet%20t=(ee=S).split(%22%20%22);t.length%3E1?(Array.from(t).forEach(function(d)%7Bdocument.querySelector(%22#%22+d)?F+=document.querySelector(%22#%22+d).textContent+%22%20%22:F+=%22%5Cu2753%5Cu2753%5Cu2753%20%22%7D),F=F.trim()):F=document.querySelector(%22#%22+ee).textContent%7Delse%20S=%22N/A%22;let%20le=e.querySelectorAll(%22%5Baria-hidden='true'%5D,%5Brole='presentation'%5D%22),M=b;if(le.length%3E0&&(ne=!0,Array.from(le).forEach(function(t)%7Blet%20d=t.textContent;d!==%22%22&&(M=M.split(d).join(%22%20%22))%7D),M=M.trim()),i===%22input%22)%7Blet%20t=e.getAttribute(%22type%22);t===%22submit%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22image%22&&g===%22N/A%22&&(s=%22Submit%22,u=%22Not%20provided%20(using%20default)%22),t===%22cancel%22&&g===%22N/A%22&&(s=%22Cancel%22,u=%22Not%20provided%20(using%20default)%22)%7Dif(v!==%22N/A%22&&(s=v,u=%22title%20attribute%22),g!==%22N/A%22&&(s=g,u=%22value%20attribute%22),N!==%22N/A%22&&(s=N,u=%22placeholder%20attribute%22),b!==%22N/A%22&&(s=M,u=%22Inner%20text%20content%22),y!==%22N/A%22&&(s=y,u=%22%3Clabel%3E%20text%22),f!==%22N/A%22&&(s=f,u=%22aria-label%22),S!==%22N/A%22&&(s=F,u=%22aria-labelledby%22),console.log(%22%25cACTIVE%20ELEMENT:%20%22,%22background:#193c10;color:white;%22),console.log(e),I=e.getAttribute(%22data-dupe%22)===%22true%22,G=I&&s===%22%22,s===%22%22%7C%7CI)%7Bif(s===%22%22&&(x=!0,k&&a.classList.add(%22error%22),l(P+%22No%20accessible%20name!%22,%22%22,h),l(%22Accessible%20Name%20Source:%20N/A%22,%22%22,h)),I&&s!==%22%22)%7Bk&&a.classList.add(%22warning%22);let%20t=document.querySelectorAll(%22%5Bdata-accname='%22+s+%22'%5D%22),d=t.length;l(P,s,h,!1,!0),G%7C%7C(Array.from(t).forEach(function(T)%7BT.classList.add(%22dupeAccName%22)%7D),l(%22Duplicate%20warning!%22,d+%22%20elements%20on%20page%20have%20the%20same%20accessible%20name%22,h)),console.log(%22Elements%20on%20page%20that%20have%20identical%20accessible%20names:%22),Array.from(t).forEach(function(T)%7Bconsole.log(T)%7D),l(%22Accessible%20Name%20Source:%20%22,u,h)%7D%7Delse%20k&&(a.classList.remove(%22error%22),a.classList.remove(%22warning%22)),l(P,s,j,!1,!0),l(%22Accessible%20Name%20Source:%20%22,u,j);x=!1,l(%22HTML%20Element:%20%22,Z,j),l(%22Role:%20%22,o,%22color:#333;background:#fff;%22,!1,!0),k%7C%7Cconsole.log(%22%25cACCESSIBLE%20NAME%20COMES%20FROM:%20%22,%22background:#193c10;color:white;%22),_&&(x=!0,l(%22Superfluous%20%60role%60%20attribute%22,%22%22,h)),$&&(x=!0,l(%22Better%20to%20use%20a%20native%20HTML%20element%22,%22%22,h)),b=b.trim(),y=y.trim(),v=v.trim(),f=f.trim(),S=S.trim(),W(),u===%22placeholder%20attribute%22?(m=!0,l(%22@placeholder:%20%22,N,A,!0)):l(%22@placeholder:%20%22,N,N===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22title%20attribute%22?(m=!0,l(%22@title:%20%22,v,A,!0)):l(%22@title:%20%22,v,v===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22value%20attribute%22?(m=!0,l(%22@value:%20%22,g,A,!0)):l(%22@value:%20%22,g,g===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22Inner%20text%20content%22?(m=!0,l(C?%22Inner%20text%20content%20(includes%20image%20alt):%20%22:%22Inner%20text%20content:%20%22,b,A,!0),ne&&l(%22!%20elements%20hidden%20to%20AT%20removed%22,%22%22,A)):l(%22Text%20Content:%20%22,b,b===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22%3Clabel%3E%20text%22?(m=!0,l(%22Visible%20%60label%60%20text:%20%22,y,A,!0)):l(%22Visible%20%60label%60%20text:%20%22,y,y===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-label%22?f===b?(x=!0,l(%22%60aria-label%60%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-label%20value:%20%22,f,A,!0)):l(%22@aria-label%20value:%20%22,f,f===%22N/A%22?%22color:#333;background:#fff;%22:E),W(),u===%22aria-labelledby%22?F===b?(x=!0,l(%22%60aria-labelledby%60%20source%20content%20is%20same%20as%20inner%20text%20content%22,%22%22,h)):(m=!0,l(%22@aria-labelledby%20value:%20%22,S,A,!0),l(%22@aria-labelledby%20sources:%20%22,F,A)):(l(%22@aria-labelledby%20value:%20%22,S,%22color:#333;background:#fff;%22),l(%22@aria-labelledby%20sources:%20%22,%22N/A%22,%22color:#333;background:#fff;%22)),k&&(document.querySelector(%22#WTFocusPanel%22).innerHTML='%3Cul%20role=%22list%22%3E'+p+%22%3C/ul%3E%22,document.querySelector(%22#WTFocusPanel%22).removeAttribute(%22hidden%22),J());let%20se=document.querySelectorAll(%22%5Bdata-temp-node%5D%22);Array.from(se).forEach(function(t)%7Bt.remove()%7D),e.setAttribute(%22data-accname%22,s),X%7C%7Cfunction(t,d)%7Blet%20T=!1;Array.from(U).forEach(function(B)%7BB===t&&(T=!0)%7D),T?(d.setAttribute(%22data-dupe%22,%22true%22),document.querySelector(%22%5Bdata-accname='%22+t+%22'%5D%22).setAttribute(%22data-dupe%22,%22true%22)):U.push(t)%7D(s,e)%7D)%7D);let%20X=!1;(function()%7Bif(V=document.activeElement,Array.from(H).forEach(function(e)%7Bdocument.activeElement===e&&e.blur(),e.focus()%7D),X=!0,V.tagName===%22BODY%22)%7Blet%20e=document.querySelector(%22body%22);e.setAttribute(%22tabindex%22,%22-1%22),e.focus(),document.querySelector(%22#WTFocusPanel%22).setAttribute(%22hidden%22,%22hidden%22)%7Delse%20V.focus();console.clear()%7D)(),console.log(%22had%20focus%20=%20%22,z)%7Dre()%7D)();%7D)();%0A" - }, - { - "file": "youtube-uc-id.js", - "bookmarklet": "Get YouTube UC ID", - "description": "Fetches UC ID while on a YouTube profile page", - "source": "Jason Morris", - "sourceUrl": "https://jasonmorris.com", - "tags": [ - "diagnostic", - "bmxfeed", - "YouTube" - ], - "pageTest": false, - "dist": "javascript:void%20(()=%3E%7Bvar%20e=document.querySelector(%22link%5Brel=canonical%5D%22).getAttribute(%22href%22).replace(%22https://www.youtube.com/channel/%22,%22%22);e&&prompt(%22UC%20ID:%22,e);%7D)();%0A" - } -] \ No newline at end of file From 40e6fa76c55493bce6045376a0fe8f40b1a66a46 Mon Sep 17 00:00:00 2001 From: Jason Morris Date: Wed, 31 Dec 2025 14:35:01 -0500 Subject: [PATCH 05/17] Ignore generated JSON files --- .gitignore | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitignore b/.gitignore index 9f09a5a..24a1576 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,5 @@ node_modules _site dist .vscode +data/bookmarklets.json +data/auditing.json From ff80ae9d31c506ea07fbd0161b7f2db993d45661 Mon Sep 17 00:00:00 2001 From: Jason Morris Date: Wed, 31 Dec 2025 19:40:36 -0500 Subject: [PATCH 06/17] autofixes --- bookmarklets/are-ya-hidden.js | 12 ++-- bookmarklets/grouped-fields.js | 24 ++++---- bookmarklets/isolator.js | 34 +++++------ bookmarklets/non-underlined-links.js | 25 ++++---- bookmarklets/show-focus-styles.js | 12 ++-- bookmarklets/wtfocus.js | 89 ++++++++++++++-------------- 6 files changed, 97 insertions(+), 99 deletions(-) diff --git a/bookmarklets/are-ya-hidden.js b/bookmarklets/are-ya-hidden.js index 1fb3082..cc0a397 100644 --- a/bookmarklets/are-ya-hidden.js +++ b/bookmarklets/are-ya-hidden.js @@ -24,7 +24,7 @@ o < cs.length; o++ ) - (cssProperty = cs[o]), + ((cssProperty = cs[o]), (cssValue = cs.getPropertyValue(cssProperty)), "clip" === cssProperty && "rect(1px, 1px, 1px, 1px)" === cssValue && @@ -35,7 +35,7 @@ "overflow-y" === cssProperty && "hidden" === cssValue && (l = !0), "position" === cssProperty && "absolute" === cssValue && (s = !0), "white-space" === cssProperty && "nowrap" === cssValue && (r = !0), - "width" === cssProperty && "1px" === cssValue && (d = !0); + "width" === cssProperty && "1px" === cssValue && (d = !0)); !0 === a && !0 === t && !0 === e && @@ -46,7 +46,7 @@ !0 === d && i.classList.add("was-visually-hidden"); let c = i.classList; - c.forEach((a) => { + (c.forEach((a) => { -1 !== a.indexOf("-offscreen") && i.classList.add("was-visually-hidden"); }), @@ -54,14 +54,14 @@ i.classList.contains("screenreader-only") || i.classList.contains("visually-hidden") || i.classList.contains("visuallyhidden")) && - i.classList.add("was-visually-hidden"); + i.classList.add("was-visually-hidden")); }); } function indicateAriaHiddenElements(i) { findAllVisuallyHiddenElements(); var a, t = i.createElement("style"); - i.head.appendChild(t), + (i.head.appendChild(t), (a = t.sheet).insertRule( "[aria-hidden=true] {background:black;color:black;}", 0 @@ -70,7 +70,7 @@ a.insertRule( ".was-visually-hidden {clip-path: initial!important;clip: initial!important;height: auto!important;overflow: initial!important;position: initial!important;white-space: initial!important;width: auto!important;opacity:initial!important;z-index:initial!important;background:black!important;color:lime!important;}", 0 - ); + )); } indicateAriaHiddenElements(document); var iframes = document.querySelectorAll("iframe"); diff --git a/bookmarklets/grouped-fields.js b/bookmarklets/grouped-fields.js index 0889f54..250c460 100644 --- a/bookmarklets/grouped-fields.js +++ b/bookmarklets/grouped-fields.js @@ -10,14 +10,14 @@ let e = "#662e2e", l = 0; function r(e, r) { - (e.style.boxShadow = "0px 0px 0px 10px white"), + ((e.style.boxShadow = "0px 0px 0px 10px white"), (e.style.outline = "5px solid " + r), (e.style.outlineOffset = "5px"), - l++; + l++); } function t(e, l, r) { let t = document.createElement("span"); - (t.innerHTML = l), + ((t.innerHTML = l), (t.style.display = "inline-block"), (t.style.margin = "20px 0 5px -10px"), (t.style.padding = "5px"), @@ -25,15 +25,15 @@ (t.style.fontWeight = "bold"), (t.style.fontSize = "18px"), (t.style.color = "white"), - t.classList.add("group-description"); + t.classList.add("group-description")); let o = e.parentNode; o.insertBefore(t, e); } var o, a = document.querySelectorAll("fieldset"); - console.log(a), + (console.log(a), Array.from(a).forEach((l) => { - console.log(l), + (console.log(l), r(l, e), l.querySelector("legend") && t( @@ -42,7 +42,7 @@ l.querySelector("legend").textContent + '"', e - ); + )); }), (e = "#66482e"), Array.from( @@ -52,7 +52,7 @@ ).forEach((l) => { console.log(l); let o = l.getAttribute("role").toLowerCase(); - r(l, e), + (r(l, e), t( l, "Group label (from [role=" + @@ -61,7 +61,7 @@ l.getAttribute("aria-label") + '"', e - ); + )); }), (e = "#662e43"), Array.from( @@ -73,7 +73,7 @@ let o = l.getAttribute("role").toLowerCase(); r(l, e); let a = "Source for aria-labelledby is missing/broken"; - document.querySelector("#" + l.getAttribute("aria-labelledby")) && + (document.querySelector("#" + l.getAttribute("aria-labelledby")) && (a = document.querySelector( "#" + l.getAttribute("aria-labelledby") ).textContent), @@ -85,9 +85,9 @@ a + '"', e - ); + )); }), - 0 === l && alert("No grouped fields found on this page"); + 0 === l && alert("No grouped fields found on this page")); } outlineGroupedFIelds(); })(); diff --git a/bookmarklets/isolator.js b/bookmarklets/isolator.js index afa7eab..15e3655 100644 --- a/bookmarklets/isolator.js +++ b/bookmarklets/isolator.js @@ -20,16 +20,16 @@ if ((t = o.parentNode).tagName) { i = t.tagName.toLowerCase(); const e = t.querySelectorAll(":scope > " + o.tagName); - (r = + ((r = e.length > 1 ? "[" + parseInt(Array.from(e).indexOf(o) + 1) + "]" : ""), (a = (n = o.tagName.toLowerCase()) + r + l + a), - (l = "/"); + (l = "/")); } o = t; } - return "" === i && (i = n), (a = "//" + i + r + l + a); + return ("" === i && (i = n), (a = "//" + i + r + l + a)); } function isolate() { let e, @@ -39,7 +39,7 @@ i = !1; const a = document.querySelectorAll("*"); function r(t, o) { - (e = t), o.stopPropagation(), i || s(t), d(e); + ((e = t), o.stopPropagation(), i || s(t), d(e)); } function l(e) { e.classList.remove("isolatorHighlight"); @@ -48,14 +48,14 @@ e.classList.add("isolatorHighlight"); } function d(e) { - console.clear(), console.log(getXpath(e)), (o.innerHTML = getXpath(e)); + (console.clear(), console.log(getXpath(e)), (o.innerHTML = getXpath(e))); } - Array.from(a).forEach((t) => { - t.addEventListener("click", (o) => { - console.log("preventClicks = ", n), + (Array.from(a).forEach((t) => { + (t.addEventListener("click", (o) => { + (console.log("preventClicks = ", n), n && (!(function (t, o) { - (e = t), "HTML" === t.tagName && (n = !1); + ((e = t), "HTML" === t.tagName && (n = !1)); !(function (e) { if (!i) { const t = e.parentNode, @@ -68,20 +68,20 @@ } })(t); })(t), - o.preventDefault()); + o.preventDefault())); }), t.addEventListener("mouseover", (o) => { - (e = t), o.stopPropagation(), i || s(t), d(e); + ((e = t), o.stopPropagation(), i || s(t), d(e)); }), t.addEventListener("mouseout", (e) => { l(t); - }); + })); }), (function () { const e = document.createElement("style"); - (e.textContent = + ((e.textContent = ".isolatorHighlight{outline:4px solid black!important;outline-offset:-4px!important;-webkit-box-shadow: 0px 0px 0px 4px #fff; box-shadow: 0px 0px 0px 4px #fff;}#infoPanel {z-index:1000;font-size:20px;background:rgba(0,0,0,0.8);color:#fff;font-weight:bold;padding:10px;position:fixed;bottom:20px;left:20px;font-family:sans-serif;} #infoPanel:empty {visibility:hidden;} #infoPanel code {color:lime}"), - document.head.appendChild(e); + document.head.appendChild(e)); })(), (o = document.createElement("div")).setAttribute("id", "infoPanel"), o.setAttribute("role", "status"), @@ -112,14 +112,14 @@ l(e); let t, o = !1; - Array.from(e.childNodes).forEach((e) => { + (Array.from(e.childNodes).forEach((e) => { 1 !== e.nodeType || o || ((o = !0), (t = e)); }), - t && r((e = t), n); + t && r((e = t), n)); } "Enter" === n.key && (n.preventDefault(), e.click()); }), - d("Isolator started. Click on element you want to isolate in the DOM"); + d("Isolator started. Click on element you want to isolate in the DOM")); } isolate(); })(); diff --git a/bookmarklets/non-underlined-links.js b/bookmarklets/non-underlined-links.js index 7cd801b..7d816cd 100644 --- a/bookmarklets/non-underlined-links.js +++ b/bookmarklets/non-underlined-links.js @@ -36,9 +36,9 @@ if ( ((function () { const e = document.createElement("style"); - (e.textContent = + ((e.textContent = ".problem-highlight {outline:5px solid darkred;outline-offset:3px;box-shadow: 0px 0px 0px 10px #fff;}"), - document.head.appendChild(e); + document.head.appendChild(e)); })(), Array.from(r).forEach((r) => { if ( @@ -49,7 +49,6 @@ ; (e = e.parentElement) && !(e.matches || e.matchesSelector).call(e, t); - ); return e; })(r, "nav,[role=navigation]")), @@ -60,24 +59,24 @@ "FIGURE" !== r.childNodes[0].tagName.toUpperCase()) || (a = !0)), !(function (n) { - (e = !1), (t = !1), (o = !1); + ((e = !1), (t = !1), (o = !1)); const r = getComputedStyle(n); for (let n = 0; n < r.length; n++) { const l = r[n], a = r.getPropertyValue(l); - "text-decoration-line" === l && "underline" === a && (t = !0), + ("text-decoration-line" === l && "underline" === a && (t = !0), "border-bottom-style" !== l || ("solid" !== a && "dotted" !== a && "dashed" !== a) || (o = !0), "border-bottom-color" === l && "transparent" === a && (o = !1), - (t || o) && (e = !0); + (t || o) && (e = !0)); } return e; })(r) && !a)) ) { - (consoleOutput += "-------\n"), + ((consoleOutput += "-------\n"), (consoleOutput += "Link text: " + r.textContent + "\n"), n || (!(function (e) { @@ -97,19 +96,19 @@ if ((t = o.parentNode).tagName) { r = t.tagName.toLowerCase(); const e = t.querySelectorAll(o.tagName); - (a = + ((a = e.length > 1 ? "[" + parseInt(Array.from(e).indexOf(o) + 1) + "]" : ""), (l = (n = o.tagName.toLowerCase()) + a + s + l), - (s = "/"); + (s = "/")); } o = t; } - return "" === r && (r = n), (l = "//" + r + a + s + l); + return ("" === r && (r = n), (l = "//" + r + a + s + l)); })(r) + "\n"), - l++); + l++)); const e = (function (e, t) { const o = i(e[0], e[1], e[2]), n = i(t[0], t[1], t[2]); @@ -133,8 +132,8 @@ l > 0) ) { const e = l + " possible issues with non-underlined links found"; - (consoleOutput = e + "\n" + consoleOutput), - alert(e + " (check console for more details)"); + ((consoleOutput = e + "\n" + consoleOutput), + alert(e + " (check console for more details)")); } else alert("No non-underlined links found (outside of a navigation area)"); console.log(consoleOutput); diff --git a/bookmarklets/show-focus-styles.js b/bookmarklets/show-focus-styles.js index 3bc9257..7e15178 100644 --- a/bookmarklets/show-focus-styles.js +++ b/bookmarklets/show-focus-styles.js @@ -13,18 +13,18 @@ ); let t, o = ""; - console.clear(), + (console.clear(), Array.from(e).forEach(function (e) { - (e.style.transition = "none"), + ((e.style.transition = "none"), e.focus(), (t = getComputedStyle(e)), - (o = ""); + (o = "")); for (var s = 0; s < t.length; s++) - (cssProperty = t[s]), + ((cssProperty = t[s]), (cssValue = t.getPropertyValue(cssProperty)), - (o += cssProperty + ":" + cssValue + ";"); + (o += cssProperty + ":" + cssValue + ";")); e.setAttribute("style", o); - }); + })); } showAllFocusStyles(); })(); diff --git a/bookmarklets/wtfocus.js b/bookmarklets/wtfocus.js index d65a8ae..f67af90 100644 --- a/bookmarklets/wtfocus.js +++ b/bookmarklets/wtfocus.js @@ -39,10 +39,10 @@ x = !1, v = !1; function T() { - (y = !1), (h = !1); + ((y = !1), (h = !1)); } function k(e, t, o, n, a) { - f && + (f && ((t = t.split("<").join("<").split(">").join(">")), (g += " " + t + "\n")), (t = t.replace("<", "<").replace(">", ">")), - console.log("%c" + e + '"' + t + '"', o); + console.log("%c" + e + '"' + t + '"', o)); } function F() { const e = document.createElement("button"); - (e.textContent = "Close (Esc)"), + ((e.textContent = "Close (Esc)"), e.setAttribute("type", "button"), e.setAttribute("class", "panel-btn"), e.addEventListener("click", () => { W(); - }); + })); const t = document.createElement("button"); - (t.textContent = "Change Mode (M)"), + ((t.textContent = "Change Mode (M)"), t.setAttribute("type", "button"), t.setAttribute("class", "panel-btn"), t.addEventListener("click", (e) => { S(); }), r.appendChild(e), - r.appendChild(t); + r.appendChild(t)); } function S() { - v + (v ? (document .querySelector("#WTFocusPanel") .classList.remove("curtainsMode"), @@ -93,13 +93,13 @@ (v = !0), (m = "")), C(e), - e.focus(); + e.focus()); } function W() { - document.querySelector("#WTFocusCurtain").remove(), + (document.querySelector("#WTFocusCurtain").remove(), document.querySelector("#WTFocusPanel").remove(), document.querySelector("#panelStyles").remove(), - document.querySelector("#focusStyles").remove(); + document.querySelector("#focusStyles").remove()); } function C(e) { const t = e.getBoundingClientRect(), @@ -133,10 +133,10 @@ (r.style.right = "auto"), r.classList.remove("toLeft")); } - console.clear(), + (console.clear(), (function () { const e = document.createElement("style"); - e.setAttribute("type", "text/css"), + (e.setAttribute("type", "text/css"), e.setAttribute("id", "panelStyles"), (e.textContent = ".dupeAccName {outline:4px dashed #CC3300!important;outline-offset:" + @@ -146,20 +146,20 @@ "px solid black!important;outline-offset:" + u + "px!important;overflow:visible;/*background:yellow!important;color:black!important;*/} .WTFocusTempFocusStyle.dupeAccName:focus {outline-color:#CC3300!important;} .visually-hidden {clip-path: inset(100%);clip: rect(1px, 1px, 1px, 1px);height: 1px;overflow: hidden;position: absolute;white-space: nowrap;width: 1px;}#WTFocusCurtain {background:black;position: fixed;top: 0;bottom: 0;left: 0;right: 0;z-index:49999}"), - document.querySelector("body").appendChild(e); + document.querySelector("body").appendChild(e)); })(), document.querySelector("#WTFocusCurtain") && W(), (f = !0), (g = ""), (function (e) { const t = document.createElement("style"); - t.setAttribute("type", "text/css"), + (t.setAttribute("type", "text/css"), t.setAttribute("id", "focusStyles"), (t.textContent = "#WTFocusPanel.error {background:darkred;} #WTFocusPanel.warning {background:#CC3300;} #WTFocusPanel.curtainsMode.error {background:black;} #WTFocusPanel.curtainsMode {z-index:50000;position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);} #WTFocusPanel.curtainsMode.warning {background:black;} #WTFocusPanel[hidden] {display:none;} #WTFocusPanel * {text-align:left} #WTFocusPanel {border:2px solid #fff;z-index:1000;text-shadow:none;font-family:sans-serif;display:block;text-align:left;position: absolute;z-index:10000;background: black;padding: 20px 20px;width:" + e + "px;font-size:16px;} #WTFocusPanel button {font-weight:bold;background:none;color:#fff;padding:3px 10px;font-size:14px;border:1px solid #fff;display:inline-block;margin:10px 1em -10px 0;} #WTFocusPanel ul,#WTFocusPanel li {margin:0;padding:0;list-style:none} #WTFocusPanel li {margin:3px 0;background:#fff;color:#333;padding:2px} #WTFocusPanel li.outline {outline:4px solid rgb(58, 190, 58);outline-offset:-4px;padding:8px} #WTFocusPanel.error:before {background:darkred} #WTFocusPanel.warning:before {background:#CC3300} #WTFocusPanel:before {content:'';display:block;height:20px;width:20px;transform:rotate(45deg);position:absolute;background:#000;left:-12px;top:3px;border:2px solid #fff;border-right:none;border-top:none;} #WTFocusPanel.toBottom:before {top:auto;bottom:3px} #WTFocusPanel.toLeft:before {left:auto;right:-12px;border:2px solid #fff;border-left:none;border-bottom:none;} #WTFocusPanel.curtainsMode {outline:10px solid orange;} #WTFocusPanel.curtainsMode:before {display:none;} #WTFocusPanel.curtainsMode li {display:none;} #WTFocusPanel.curtainsMode li.visible {display:block;} #WTFocusPanel.curtainsMode li span {display:none!important;} "), - document.querySelector("head").appendChild(t); + document.querySelector("head").appendChild(t)); })(s), i.setAttribute("id", "WTFocusCurtain"), i.setAttribute("hidden", "hidden"), @@ -180,12 +180,12 @@ document.querySelector("#WTFocusPanel") && S(); }), - F(); + F()); let N = []; Array.from(t).forEach(function (i) { i.classList.add("WTFocusTempFocusStyle"); const c = i.querySelectorAll("style"); - Array.from(c).forEach(function (e) { + (Array.from(c).forEach(function (e) { e.remove(); }), i.addEventListener("focus", () => { @@ -221,7 +221,7 @@ "input" == s) ) { let e = i.getAttribute("type").toLowerCase(); - "text" === e && (c = "textbox"), + ("text" === e && (c = "textbox"), "range" === e && (c = "slider"), "number" === e && (c = "spinbutton"), ("checkbox" !== e && "radio" !== e) || (c = e), @@ -229,22 +229,22 @@ "image" !== e && "reset" !== e && "submit" !== e) || - (c = "button"); + (c = "button")); } - (e = i), + ((e = i), Array.from(t).forEach(function (e) { e.classList.remove("dupeAccName"); - }); + })); let u = !1; - (y = !1), (h = !1); + ((y = !1), (h = !1)); const d = i.querySelectorAll( "img, [role='image'][aria-label], [role='img'][aria-label]" ); - (u = d.length > 0) && + ((u = d.length > 0) && Array.from(d).forEach(function (e) { const t = document.createElement("SPAN"); var o, n; - t.setAttribute("class", "visually-hidden"), + (t.setAttribute("class", "visually-hidden"), t.setAttribute( "style", "clip-path: inset(100%);clip: rect(1px, 1px, 1px, 1px);height: 1px;overflow: hidden;position: absolute;white-space: nowrap;width: 1px;" @@ -256,12 +256,12 @@ e.getAttribute("aria-label") && (t.textContent = " " + e.getAttribute("aria-label") + " "), (o = t), - (n = e).parentNode.insertBefore(o, n.nextSibling); + (n = e).parentNode.insertBefore(o, n.nextSibling)); }), setTimeout(function () { i.classList.add("WTFocusTempFocusStyle"); }, 100), - (g = ""); + (g = "")); const b = i.tagName.toLowerCase(); let p = i.getAttribute("role"); p && (p = i.getAttribute("role").toLowerCase()); @@ -309,13 +309,12 @@ R = !1, V = "", D = !1; - f && C(i), (P = P.trim()); + (f && C(i), (P = P.trim())); const Y = (function (e, t) { for ( ; (e = e.parentElement) && !(e.matches || e.matchesSelector).call(e, t); - ); return e; })(i, "label"); @@ -362,7 +361,7 @@ "input" === b) ) { const e = i.getAttribute("type"); - "submit" === e && + ("submit" === e && "N/A" === z && ((H = "Submit"), (V = "Not provided (using default)")), "image" === e && @@ -370,7 +369,7 @@ ((H = "Submit"), (V = "Not provided (using default)")), "cancel" === e && "N/A" === z && - ((H = "Cancel"), (V = "Not provided (using default)")); + ((H = "Cancel"), (V = "Not provided (using default)"))); } if ( ("N/A" !== I && ((H = I), (V = "title attribute")), @@ -400,7 +399,7 @@ f && r.classList.add("warning"); const e = document.querySelectorAll("[data-accname='" + H + "']"), t = e.length; - k(m, H, a, !1, !0), + (k(m, H, a, !1, !0), x || (Array.from(e).forEach(function (e) { e.classList.add("dupeAccName"); @@ -416,13 +415,13 @@ Array.from(e).forEach(function (e) { console.log(e); }), - k("Accessible Name Source: ", V, a); + k("Accessible Name Source: ", V, a)); } } else - f && (r.classList.remove("error"), r.classList.remove("warning")), + (f && (r.classList.remove("error"), r.classList.remove("warning")), k(m, H, n, !1, !0), - k("Accessible Name Source: ", V, n); - (h = !1), + k("Accessible Name Source: ", V, n)); + ((h = !1), k("HTML Element: ", v, n), k("Role: ", c, "color:#333;background:#fff;", !1, !0), f || @@ -527,9 +526,9 @@ ((document.querySelector("#WTFocusPanel").innerHTML = '

    ' + g + "
"), document.querySelector("#WTFocusPanel").removeAttribute("hidden"), - F()); + F())); const K = document.querySelectorAll("[data-temp-node]"); - Array.from(K).forEach(function (e) { + (Array.from(K).forEach(function (e) { e.remove(); }), i.setAttribute("data-accname", H), @@ -548,29 +547,29 @@ ); o.setAttribute("data-dupe", "true"); } else N.push(e); - })(H, i); - }); + })(H, i)); + })); }); let E = !1; - !(function () { + (!(function () { if ( ((p = document.activeElement), Array.from(t).forEach(function (e) { - document.activeElement === e && e.blur(), e.focus(); + (document.activeElement === e && e.blur(), e.focus()); }), (E = !0), "BODY" === p.tagName) ) { const e = document.querySelector("body"); - e.setAttribute("tabindex", "-1"), + (e.setAttribute("tabindex", "-1"), e.focus(), document .querySelector("#WTFocusPanel") - .setAttribute("hidden", "hidden"); + .setAttribute("hidden", "hidden")); } else p.focus(); console.clear(); })(), - console.log("had focus = ", e); + console.log("had focus = ", e)); } WTFocus(); })(); From 831f4e822768a2c362ec5f5f56e5c38762208f34 Mon Sep 17 00:00:00 2001 From: Jason Morris Date: Wed, 31 Dec 2025 19:40:48 -0500 Subject: [PATCH 07/17] NPM updates --- package-lock.json | 252 +++++++++++++++++++++++----------------------- package.json | 6 +- 2 files changed, 127 insertions(+), 131 deletions(-) diff --git a/package-lock.json b/package-lock.json index 511da7d..c1339cd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,12 +9,12 @@ "version": "1.0.0", "devDependencies": { "@11ty/eleventy": "^3.1.2", - "esbuild": "^0.27.0", - "eslint": "^9.39.1", + "esbuild": "^0.27.2", + "eslint": "^9.39.2", "eslint-config-prettier": "^10.1.8", "eslint-plugin-prettier": "^5.5.4", "netscape-bookmarks": "^0.1.1", - "prettier": "^3.7.3" + "prettier": "^3.7.4" } }, "node_modules/@11ty/dependency-tree": { @@ -224,9 +224,9 @@ } }, "node_modules/@esbuild/aix-ppc64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.27.0.tgz", - "integrity": "sha512-KuZrd2hRjz01y5JK9mEBSD3Vj3mbCvemhT466rSuJYeE/hjuBrHfjjcjMdTm/sz7au+++sdbJZJmuBwQLuw68A==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.27.2.tgz", + "integrity": "sha512-GZMB+a0mOMZs4MpDbj8RJp4cw+w1WV5NYD6xzgvzUJ5Ek2jerwfO2eADyI6ExDSUED+1X8aMbegahsJi+8mgpw==", "cpu": [ "ppc64" ], @@ -241,9 +241,9 @@ } }, "node_modules/@esbuild/android-arm": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.27.0.tgz", - "integrity": "sha512-j67aezrPNYWJEOHUNLPj9maeJte7uSMM6gMoxfPC9hOg8N02JuQi/T7ewumf4tNvJadFkvLZMlAq73b9uwdMyQ==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.27.2.tgz", + "integrity": "sha512-DVNI8jlPa7Ujbr1yjU2PfUSRtAUZPG9I1RwW4F4xFB1Imiu2on0ADiI/c3td+KmDtVKNbi+nffGDQMfcIMkwIA==", "cpu": [ "arm" ], @@ -258,9 +258,9 @@ } }, "node_modules/@esbuild/android-arm64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.27.0.tgz", - "integrity": "sha512-CC3vt4+1xZrs97/PKDkl0yN7w8edvU2vZvAFGD16n9F0Cvniy5qvzRXjfO1l94efczkkQE6g1x0i73Qf5uthOQ==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.27.2.tgz", + "integrity": "sha512-pvz8ZZ7ot/RBphf8fv60ljmaoydPU12VuXHImtAs0XhLLw+EXBi2BLe3OYSBslR4rryHvweW5gmkKFwTiFy6KA==", "cpu": [ "arm64" ], @@ -275,9 +275,9 @@ } }, "node_modules/@esbuild/android-x64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.27.0.tgz", - "integrity": "sha512-wurMkF1nmQajBO1+0CJmcN17U4BP6GqNSROP8t0X/Jiw2ltYGLHpEksp9MpoBqkrFR3kv2/te6Sha26k3+yZ9Q==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.27.2.tgz", + "integrity": "sha512-z8Ank4Byh4TJJOh4wpz8g2vDy75zFL0TlZlkUkEwYXuPSgX8yzep596n6mT7905kA9uHZsf/o2OJZubl2l3M7A==", "cpu": [ "x64" ], @@ -292,9 +292,9 @@ } }, "node_modules/@esbuild/darwin-arm64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.27.0.tgz", - "integrity": "sha512-uJOQKYCcHhg07DL7i8MzjvS2LaP7W7Pn/7uA0B5S1EnqAirJtbyw4yC5jQ5qcFjHK9l6o/MX9QisBg12kNkdHg==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.27.2.tgz", + "integrity": "sha512-davCD2Zc80nzDVRwXTcQP/28fiJbcOwvdolL0sOiOsbwBa72kegmVU0Wrh1MYrbuCL98Omp5dVhQFWRKR2ZAlg==", "cpu": [ "arm64" ], @@ -309,9 +309,9 @@ } }, "node_modules/@esbuild/darwin-x64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.27.0.tgz", - "integrity": "sha512-8mG6arH3yB/4ZXiEnXof5MK72dE6zM9cDvUcPtxhUZsDjESl9JipZYW60C3JGreKCEP+p8P/72r69m4AZGJd5g==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.27.2.tgz", + "integrity": "sha512-ZxtijOmlQCBWGwbVmwOF/UCzuGIbUkqB1faQRf5akQmxRJ1ujusWsb3CVfk/9iZKr2L5SMU5wPBi1UWbvL+VQA==", "cpu": [ "x64" ], @@ -326,9 +326,9 @@ } }, "node_modules/@esbuild/freebsd-arm64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.27.0.tgz", - "integrity": "sha512-9FHtyO988CwNMMOE3YIeci+UV+x5Zy8fI2qHNpsEtSF83YPBmE8UWmfYAQg6Ux7Gsmd4FejZqnEUZCMGaNQHQw==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.27.2.tgz", + "integrity": "sha512-lS/9CN+rgqQ9czogxlMcBMGd+l8Q3Nj1MFQwBZJyoEKI50XGxwuzznYdwcav6lpOGv5BqaZXqvBSiB/kJ5op+g==", "cpu": [ "arm64" ], @@ -343,9 +343,9 @@ } }, "node_modules/@esbuild/freebsd-x64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.27.0.tgz", - "integrity": "sha512-zCMeMXI4HS/tXvJz8vWGexpZj2YVtRAihHLk1imZj4efx1BQzN76YFeKqlDr3bUWI26wHwLWPd3rwh6pe4EV7g==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.27.2.tgz", + "integrity": "sha512-tAfqtNYb4YgPnJlEFu4c212HYjQWSO/w/h/lQaBK7RbwGIkBOuNKQI9tqWzx7Wtp7bTPaGC6MJvWI608P3wXYA==", "cpu": [ "x64" ], @@ -360,9 +360,9 @@ } }, "node_modules/@esbuild/linux-arm": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.27.0.tgz", - "integrity": "sha512-t76XLQDpxgmq2cNXKTVEB7O7YMb42atj2Re2Haf45HkaUpjM2J0UuJZDuaGbPbamzZ7bawyGFUkodL+zcE+jvQ==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.27.2.tgz", + "integrity": "sha512-vWfq4GaIMP9AIe4yj1ZUW18RDhx6EPQKjwe7n8BbIecFtCQG4CfHGaHuh7fdfq+y3LIA2vGS/o9ZBGVxIDi9hw==", "cpu": [ "arm" ], @@ -377,9 +377,9 @@ } }, "node_modules/@esbuild/linux-arm64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.27.0.tgz", - "integrity": "sha512-AS18v0V+vZiLJyi/4LphvBE+OIX682Pu7ZYNsdUHyUKSoRwdnOsMf6FDekwoAFKej14WAkOef3zAORJgAtXnlQ==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.27.2.tgz", + "integrity": "sha512-hYxN8pr66NsCCiRFkHUAsxylNOcAQaxSSkHMMjcpx0si13t1LHFphxJZUiGwojB1a/Hd5OiPIqDdXONia6bhTw==", "cpu": [ "arm64" ], @@ -394,9 +394,9 @@ } }, "node_modules/@esbuild/linux-ia32": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.27.0.tgz", - "integrity": "sha512-Mz1jxqm/kfgKkc/KLHC5qIujMvnnarD9ra1cEcrs7qshTUSksPihGrWHVG5+osAIQ68577Zpww7SGapmzSt4Nw==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.27.2.tgz", + "integrity": "sha512-MJt5BRRSScPDwG2hLelYhAAKh9imjHK5+NE/tvnRLbIqUWa+0E9N4WNMjmp/kXXPHZGqPLxggwVhz7QP8CTR8w==", "cpu": [ "ia32" ], @@ -411,9 +411,9 @@ } }, "node_modules/@esbuild/linux-loong64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.27.0.tgz", - "integrity": "sha512-QbEREjdJeIreIAbdG2hLU1yXm1uu+LTdzoq1KCo4G4pFOLlvIspBm36QrQOar9LFduavoWX2msNFAAAY9j4BDg==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.27.2.tgz", + "integrity": "sha512-lugyF1atnAT463aO6KPshVCJK5NgRnU4yb3FUumyVz+cGvZbontBgzeGFO1nF+dPueHD367a2ZXe1NtUkAjOtg==", "cpu": [ "loong64" ], @@ -428,9 +428,9 @@ } }, "node_modules/@esbuild/linux-mips64el": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.27.0.tgz", - "integrity": "sha512-sJz3zRNe4tO2wxvDpH/HYJilb6+2YJxo/ZNbVdtFiKDufzWq4JmKAiHy9iGoLjAV7r/W32VgaHGkk35cUXlNOg==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.27.2.tgz", + "integrity": "sha512-nlP2I6ArEBewvJ2gjrrkESEZkB5mIoaTswuqNFRv/WYd+ATtUpe9Y09RnJvgvdag7he0OWgEZWhviS1OTOKixw==", "cpu": [ "mips64el" ], @@ -445,9 +445,9 @@ } }, "node_modules/@esbuild/linux-ppc64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.27.0.tgz", - "integrity": "sha512-z9N10FBD0DCS2dmSABDBb5TLAyF1/ydVb+N4pi88T45efQ/w4ohr/F/QYCkxDPnkhkp6AIpIcQKQ8F0ANoA2JA==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.27.2.tgz", + "integrity": "sha512-C92gnpey7tUQONqg1n6dKVbx3vphKtTHJaNG2Ok9lGwbZil6DrfyecMsp9CrmXGQJmZ7iiVXvvZH6Ml5hL6XdQ==", "cpu": [ "ppc64" ], @@ -462,9 +462,9 @@ } }, "node_modules/@esbuild/linux-riscv64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.27.0.tgz", - "integrity": "sha512-pQdyAIZ0BWIC5GyvVFn5awDiO14TkT/19FTmFcPdDec94KJ1uZcmFs21Fo8auMXzD4Tt+diXu1LW1gHus9fhFQ==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.27.2.tgz", + "integrity": "sha512-B5BOmojNtUyN8AXlK0QJyvjEZkWwy/FKvakkTDCziX95AowLZKR6aCDhG7LeF7uMCXEJqwa8Bejz5LTPYm8AvA==", "cpu": [ "riscv64" ], @@ -479,9 +479,9 @@ } }, "node_modules/@esbuild/linux-s390x": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.27.0.tgz", - "integrity": "sha512-hPlRWR4eIDDEci953RI1BLZitgi5uqcsjKMxwYfmi4LcwyWo2IcRP+lThVnKjNtk90pLS8nKdroXYOqW+QQH+w==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.27.2.tgz", + "integrity": "sha512-p4bm9+wsPwup5Z8f4EpfN63qNagQ47Ua2znaqGH6bqLlmJ4bx97Y9JdqxgGZ6Y8xVTixUnEkoKSHcpRlDnNr5w==", "cpu": [ "s390x" ], @@ -496,9 +496,9 @@ } }, "node_modules/@esbuild/linux-x64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.27.0.tgz", - "integrity": "sha512-1hBWx4OUJE2cab++aVZ7pObD6s+DK4mPGpemtnAORBvb5l/g5xFGk0vc0PjSkrDs0XaXj9yyob3d14XqvnQ4gw==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.27.2.tgz", + "integrity": "sha512-uwp2Tip5aPmH+NRUwTcfLb+W32WXjpFejTIOWZFw/v7/KnpCDKG66u4DLcurQpiYTiYwQ9B7KOeMJvLCu/OvbA==", "cpu": [ "x64" ], @@ -513,9 +513,9 @@ } }, "node_modules/@esbuild/netbsd-arm64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.27.0.tgz", - "integrity": "sha512-6m0sfQfxfQfy1qRuecMkJlf1cIzTOgyaeXaiVaaki8/v+WB+U4hc6ik15ZW6TAllRlg/WuQXxWj1jx6C+dfy3w==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.27.2.tgz", + "integrity": "sha512-Kj6DiBlwXrPsCRDeRvGAUb/LNrBASrfqAIok+xB0LxK8CHqxZ037viF13ugfsIpePH93mX7xfJp97cyDuTZ3cw==", "cpu": [ "arm64" ], @@ -530,9 +530,9 @@ } }, "node_modules/@esbuild/netbsd-x64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.27.0.tgz", - "integrity": "sha512-xbbOdfn06FtcJ9d0ShxxvSn2iUsGd/lgPIO2V3VZIPDbEaIj1/3nBBe1AwuEZKXVXkMmpr6LUAgMkLD/4D2PPA==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.27.2.tgz", + "integrity": "sha512-HwGDZ0VLVBY3Y+Nw0JexZy9o/nUAWq9MlV7cahpaXKW6TOzfVno3y3/M8Ga8u8Yr7GldLOov27xiCnqRZf0tCA==", "cpu": [ "x64" ], @@ -547,9 +547,9 @@ } }, "node_modules/@esbuild/openbsd-arm64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.27.0.tgz", - "integrity": "sha512-fWgqR8uNbCQ/GGv0yhzttj6sU/9Z5/Sv/VGU3F5OuXK6J6SlriONKrQ7tNlwBrJZXRYk5jUhuWvF7GYzGguBZQ==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.27.2.tgz", + "integrity": "sha512-DNIHH2BPQ5551A7oSHD0CKbwIA/Ox7+78/AWkbS5QoRzaqlev2uFayfSxq68EkonB+IKjiuxBFoV8ESJy8bOHA==", "cpu": [ "arm64" ], @@ -564,9 +564,9 @@ } }, "node_modules/@esbuild/openbsd-x64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.27.0.tgz", - "integrity": "sha512-aCwlRdSNMNxkGGqQajMUza6uXzR/U0dIl1QmLjPtRbLOx3Gy3otfFu/VjATy4yQzo9yFDGTxYDo1FfAD9oRD2A==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.27.2.tgz", + "integrity": "sha512-/it7w9Nb7+0KFIzjalNJVR5bOzA9Vay+yIPLVHfIQYG/j+j9VTH84aNB8ExGKPU4AzfaEvN9/V4HV+F+vo8OEg==", "cpu": [ "x64" ], @@ -581,9 +581,9 @@ } }, "node_modules/@esbuild/openharmony-arm64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.27.0.tgz", - "integrity": "sha512-nyvsBccxNAsNYz2jVFYwEGuRRomqZ149A39SHWk4hV0jWxKM0hjBPm3AmdxcbHiFLbBSwG6SbpIcUbXjgyECfA==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.27.2.tgz", + "integrity": "sha512-LRBbCmiU51IXfeXk59csuX/aSaToeG7w48nMwA6049Y4J4+VbWALAuXcs+qcD04rHDuSCSRKdmY63sruDS5qag==", "cpu": [ "arm64" ], @@ -598,9 +598,9 @@ } }, "node_modules/@esbuild/sunos-x64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.27.0.tgz", - "integrity": "sha512-Q1KY1iJafM+UX6CFEL+F4HRTgygmEW568YMqDA5UV97AuZSm21b7SXIrRJDwXWPzr8MGr75fUZPV67FdtMHlHA==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.27.2.tgz", + "integrity": "sha512-kMtx1yqJHTmqaqHPAzKCAkDaKsffmXkPHThSfRwZGyuqyIeBvf08KSsYXl+abf5HDAPMJIPnbBfXvP2ZC2TfHg==", "cpu": [ "x64" ], @@ -615,9 +615,9 @@ } }, "node_modules/@esbuild/win32-arm64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.27.0.tgz", - "integrity": "sha512-W1eyGNi6d+8kOmZIwi/EDjrL9nxQIQ0MiGqe/AWc6+IaHloxHSGoeRgDRKHFISThLmsewZ5nHFvGFWdBYlgKPg==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.27.2.tgz", + "integrity": "sha512-Yaf78O/B3Kkh+nKABUF++bvJv5Ijoy9AN1ww904rOXZFLWVc5OLOfL56W+C8F9xn5JQZa3UX6m+IktJnIb1Jjg==", "cpu": [ "arm64" ], @@ -632,9 +632,9 @@ } }, "node_modules/@esbuild/win32-ia32": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.27.0.tgz", - "integrity": "sha512-30z1aKL9h22kQhilnYkORFYt+3wp7yZsHWus+wSKAJR8JtdfI76LJ4SBdMsCopTR3z/ORqVu5L1vtnHZWVj4cQ==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.27.2.tgz", + "integrity": "sha512-Iuws0kxo4yusk7sw70Xa2E2imZU5HoixzxfGCdxwBdhiDgt9vX9VUCBhqcwY7/uh//78A1hMkkROMJq9l27oLQ==", "cpu": [ "ia32" ], @@ -649,9 +649,9 @@ } }, "node_modules/@esbuild/win32-x64": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.27.0.tgz", - "integrity": "sha512-aIitBcjQeyOhMTImhLZmtxfdOcuNRpwlPNmlFKPcHQYPhEssw75Cl1TSXJXpMkzaua9FUetx/4OQKq7eJul5Cg==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.27.2.tgz", + "integrity": "sha512-sRdU18mcKf7F+YgheI/zGf5alZatMUTKj/jNS6l744f9u3WFu4v7twcUI9vu4mknF4Y9aDlblIie0IM+5xxaqQ==", "cpu": [ "x64" ], @@ -760,9 +760,9 @@ } }, "node_modules/@eslint/js": { - "version": "9.39.1", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.39.1.tgz", - "integrity": "sha512-S26Stp4zCy88tH94QbBv3XCuzRQiZ9yXofEILmglYTh/Ug/a9/umqvgFtYBAo3Lp0nsI/5/qH1CCrbdK3AP1Tw==", + "version": "9.39.2", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.39.2.tgz", + "integrity": "sha512-q1mjIoW1VX4IvSocvM/vbTiveKC4k9eLrajNEuSsmjymSDEbpGddtpfOoN7YGAqBK3NG+uqo8ia4PDTt8buCYA==", "dev": true, "license": "MIT", "engines": { @@ -945,7 +945,6 @@ "integrity": "sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==", "dev": true, "license": "MIT", - "peer": true, "bin": { "acorn": "bin/acorn" }, @@ -1134,10 +1133,11 @@ } }, "node_modules/brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.12.tgz", + "integrity": "sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==", "dev": true, + "license": "MIT", "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -1413,9 +1413,9 @@ } }, "node_modules/esbuild": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.0.tgz", - "integrity": "sha512-jd0f4NHbD6cALCyGElNpGAOtWxSq46l9X/sWB0Nzd5er4Kz2YTm+Vl0qKFT9KUJvD8+fiO8AvoHhFvEatfVixA==", + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.2.tgz", + "integrity": "sha512-HyNQImnsOC7X9PMNaCIeAm4ISCQXs5a5YasTXVliKv4uuBo1dKrG0A+uQS8M5eXjVMnLg3WgXaKvprHlFJQffw==", "dev": true, "hasInstallScript": true, "license": "MIT", @@ -1426,32 +1426,32 @@ "node": ">=18" }, "optionalDependencies": { - "@esbuild/aix-ppc64": "0.27.0", - "@esbuild/android-arm": "0.27.0", - "@esbuild/android-arm64": "0.27.0", - "@esbuild/android-x64": "0.27.0", - "@esbuild/darwin-arm64": "0.27.0", - "@esbuild/darwin-x64": "0.27.0", - "@esbuild/freebsd-arm64": "0.27.0", - "@esbuild/freebsd-x64": "0.27.0", - "@esbuild/linux-arm": "0.27.0", - "@esbuild/linux-arm64": "0.27.0", - "@esbuild/linux-ia32": "0.27.0", - "@esbuild/linux-loong64": "0.27.0", - "@esbuild/linux-mips64el": "0.27.0", - "@esbuild/linux-ppc64": "0.27.0", - "@esbuild/linux-riscv64": "0.27.0", - "@esbuild/linux-s390x": "0.27.0", - "@esbuild/linux-x64": "0.27.0", - "@esbuild/netbsd-arm64": "0.27.0", - "@esbuild/netbsd-x64": "0.27.0", - "@esbuild/openbsd-arm64": "0.27.0", - "@esbuild/openbsd-x64": "0.27.0", - "@esbuild/openharmony-arm64": "0.27.0", - "@esbuild/sunos-x64": "0.27.0", - "@esbuild/win32-arm64": "0.27.0", - "@esbuild/win32-ia32": "0.27.0", - "@esbuild/win32-x64": "0.27.0" + "@esbuild/aix-ppc64": "0.27.2", + "@esbuild/android-arm": "0.27.2", + "@esbuild/android-arm64": "0.27.2", + "@esbuild/android-x64": "0.27.2", + "@esbuild/darwin-arm64": "0.27.2", + "@esbuild/darwin-x64": "0.27.2", + "@esbuild/freebsd-arm64": "0.27.2", + "@esbuild/freebsd-x64": "0.27.2", + "@esbuild/linux-arm": "0.27.2", + "@esbuild/linux-arm64": "0.27.2", + "@esbuild/linux-ia32": "0.27.2", + "@esbuild/linux-loong64": "0.27.2", + "@esbuild/linux-mips64el": "0.27.2", + "@esbuild/linux-ppc64": "0.27.2", + "@esbuild/linux-riscv64": "0.27.2", + "@esbuild/linux-s390x": "0.27.2", + "@esbuild/linux-x64": "0.27.2", + "@esbuild/netbsd-arm64": "0.27.2", + "@esbuild/netbsd-x64": "0.27.2", + "@esbuild/openbsd-arm64": "0.27.2", + "@esbuild/openbsd-x64": "0.27.2", + "@esbuild/openharmony-arm64": "0.27.2", + "@esbuild/sunos-x64": "0.27.2", + "@esbuild/win32-arm64": "0.27.2", + "@esbuild/win32-ia32": "0.27.2", + "@esbuild/win32-x64": "0.27.2" } }, "node_modules/escape-html": { @@ -1474,9 +1474,9 @@ } }, "node_modules/eslint": { - "version": "9.39.1", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.39.1.tgz", - "integrity": "sha512-BhHmn2yNOFA9H9JmmIVKJmd288g9hrVRDkdoIgRCRuSySRUHH7r/DI6aAXW9T1WwUuY3DFgrcaqB+deURBLR5g==", + "version": "9.39.2", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.39.2.tgz", + "integrity": "sha512-LEyamqS7W5HB3ujJyvi0HQK/dtVINZvd5mAAp9eT5S/ujByGjiZLCzPcHVzuXbpJDJF/cxwHlfceVUDZ2lnSTw==", "dev": true, "license": "MIT", "dependencies": { @@ -1486,7 +1486,7 @@ "@eslint/config-helpers": "^0.4.2", "@eslint/core": "^0.17.0", "@eslint/eslintrc": "^3.3.1", - "@eslint/js": "9.39.1", + "@eslint/js": "9.39.2", "@eslint/plugin-kit": "^0.4.1", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", @@ -1539,7 +1539,6 @@ "integrity": "sha512-82GZUjRS0p/jganf6q1rEO25VSoHH0hKPCTrgillPjdI/3bgBhAE1QzHrHTizjpRvy6pGAvKjDJtk2pF9NDq8w==", "dev": true, "license": "MIT", - "peer": true, "bin": { "eslint-config-prettier": "bin/cli.js" }, @@ -2721,7 +2720,6 @@ "integrity": "sha512-JcEmHlyLK/o0uGAlj65vgg+7LIms0xKXe60lcDOTU7oVX/3LuEuLwrQpW3VJ7de5TaFKiW4kWkaIpJL42FEgxQ==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "posthtml-parser": "^0.11.0", "posthtml-render": "^3.0.0" @@ -2779,12 +2777,11 @@ } }, "node_modules/prettier": { - "version": "3.7.3", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.7.3.tgz", - "integrity": "sha512-QgODejq9K3OzoBbuyobZlUhznP5SKwPqp+6Q6xw6o8gnhr4O85L2U915iM2IDcfF2NPXVaM9zlo9tdwipnYwzg==", + "version": "3.7.4", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.7.4.tgz", + "integrity": "sha512-v6UNi1+3hSlVvv8fSaoUbggEM5VErKmmpGA7Pl3HF8V6uKY7rvClBOJlH6yNwQtfTueNkGVpOv/mtWL9L4bgRA==", "dev": true, "license": "MIT", - "peer": true, "bin": { "prettier": "bin/prettier.cjs" }, @@ -3086,7 +3083,6 @@ "integrity": "sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==", "dev": true, "license": "MIT", - "peer": true, "engines": { "node": ">=12" }, diff --git a/package.json b/package.json index 1c620f4..1bcb407 100644 --- a/package.json +++ b/package.json @@ -23,11 +23,11 @@ "author": "Jason Morris", "devDependencies": { "@11ty/eleventy": "^3.1.2", - "esbuild": "^0.27.0", - "eslint": "^9.39.1", + "esbuild": "^0.27.2", + "eslint": "^9.39.2", "eslint-config-prettier": "^10.1.8", "eslint-plugin-prettier": "^5.5.4", "netscape-bookmarks": "^0.1.1", - "prettier": "^3.7.3" + "prettier": "^3.7.4" } } From d24c9adb0a4610f0d2acf44df4d895b09bfa016c Mon Sep 17 00:00:00 2001 From: Jason Morris Date: Wed, 31 Dec 2025 19:41:08 -0500 Subject: [PATCH 08/17] Add an accessible name :facepalm: --- index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.html b/index.html index 8dbb17a..18abc85 100644 --- a/index.html +++ b/index.html @@ -66,4 +66,4 @@

Bookmarklet library

Bookmarklet bookmarks

A raindrop.io bookmarklets collection iframe embed follows.

- + From 9d472e5bae6cb1f982d03610a10bae665eed064e Mon Sep 17 00:00:00 2001 From: Jason Morris Date: Wed, 31 Dec 2025 19:41:15 -0500 Subject: [PATCH 09/17] Rebuild --- data/auditing.html | 6 +++--- data/bookmarks.html | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/data/auditing.html b/data/auditing.html index ff79e4b..cfda9bb 100644 --- a/data/auditing.html +++ b/data/auditing.html @@ -19,14 +19,14 @@

Bookmarks Menu

Images
Language of page/parts
Links -
Non-underlined links +
Non-underlined links
Page link
Parsing only
Placeholder contrast checker
Validate
Text spacing -
Titles +
Titles
ANDI
Open 1280x1024 -
WTFocus +
WTFocus

\ No newline at end of file diff --git a/data/bookmarks.html b/data/bookmarks.html index e988f1e..5fd86a5 100644 --- a/data/bookmarks.html +++ b/data/bookmarks.html @@ -33,12 +33,12 @@

Bookmarks Menu

Image info
Images
Inline styles -
Isolator +
Isolator
Keyboard visualizer
Language of page/parts
Links
Markdown link -
Non-underlined links +
Non-underlined links
Page link
Parsing only
Placeholder contrast checker @@ -53,7 +53,7 @@

Bookmarks Menu

Test local JS
Text spacing
Text zoom 200% -
Titles +
Titles
a11y.css
ANDI
ARIA usage @@ -67,6 +67,6 @@

Bookmarks Menu

Viewport
Open 1280x1024
Open 320x256 -
WTFocus +
WTFocus
Get YouTube UC ID

\ No newline at end of file From 1b8fb01e57ea2c71f30b9c604b7f8ad81d63a12c Mon Sep 17 00:00:00 2001 From: Jason Morris Date: Wed, 31 Dec 2025 19:50:57 -0500 Subject: [PATCH 10/17] Implement Phase 2: Convention-based test page matching Add bookmarklets.11tydata.cjs that uses Eleventy computed data to derive layout, file, permalink, and title from HTML filenames. Remove frontmatter from all 22 test pages - they now contain only test content with no YAML required. --- PLAN.md | 48 ++++++++++----------- bookmarklets/are-ya-hidden.html | 7 --- bookmarklets/auto-complete.html | 6 --- bookmarklets/background-images.html | 6 --- bookmarklets/bookmarklets.11tydata.cjs | 20 +++++++++ bookmarklets/character-keys.html | 6 --- bookmarklets/complex-table.html | 6 --- bookmarklets/duplicate-ids.html | 6 --- bookmarklets/find-duplicate-aria-roles.html | 6 --- bookmarklets/focus-everything.html | 6 --- bookmarklets/horizontal-scroll.html | 6 --- bookmarklets/image-info.html | 6 --- bookmarklets/images.html | 6 --- bookmarklets/inline-styles.html | 6 --- bookmarklets/language.html | 6 --- bookmarklets/non-underlined-links.html | 6 --- bookmarklets/placeholder-contrast.html | 6 --- bookmarklets/re-enable-selection.html | 6 --- bookmarklets/show-focus-styles.html | 6 --- bookmarklets/strip-onpaste.html | 6 --- bookmarklets/tool-label-in-name.html | 6 --- bookmarklets/truncation.html | 6 --- bookmarklets/window-1280x1024.html | 6 --- bookmarklets/window-320x256.html | 6 --- 24 files changed, 42 insertions(+), 159 deletions(-) create mode 100644 bookmarklets/bookmarklets.11tydata.cjs diff --git a/PLAN.md b/PLAN.md index c2728c5..1c2e1f1 100644 --- a/PLAN.md +++ b/PLAN.md @@ -1,5 +1,17 @@ # Bookmarklet Codebase Improvement Plan +## Implementation Status + +| Phase | Status | Notes | +|-------|--------|-------| +| Phase 1: Metadata in JS | ✅ Complete | All 62 bookmarklets have @bookmarklet metadata; build.js extracts and generates JSON | +| Phase 2: Simpler test pages | ✅ Complete | Uses Option B: `bookmarklets.11tydata.cjs` computes `file`, `permalink`, `title`, and `layout` from filename; all frontmatter removed from HTML test pages | +| Phase 3: Scaffolding | ❌ Not started | No scaffolding script exists | +| Phase 4: Validation | ⚠️ Partial | Basic "missing metadata" warning exists; no orphan detection or test page validation | +| Phase 5: Documentation | ❌ Not started | No CONTRIBUTING.md | + +--- + ## Current State Analysis ### What Works Well @@ -74,38 +86,22 @@ Add JSDoc-style metadata block to each bookmarklet: --- -### Phase 2: Auto-Generated Test Page Stubs +### Phase 2: Auto-Generated Test Page Stubs ✅ **Goal**: Reduce boilerplate for test pages by auto-generating the frontmatter. -#### Option A: Simplified Frontmatter (Recommended) -Test pages only need to specify the file reference: +**Implemented**: Option B (Convention-Based) -```yaml ---- -file: are-ya-hidden.js ---- -

- -
-``` - -The layout template derives all other data (`permalink`, `title`, `description`) from the bookmarklets data. +Created `bookmarklets/bookmarklets.11tydata.cjs` that uses Eleventy's computed data to auto-match HTML files to their JS counterparts by filename convention: +- `bookmarklets/foo.js` → auto-matched by `bookmarklets/foo.html` -**Layout change** (`_includes/layouts/test.html`): -```liquid ---- -layout: page -permalink: "{{ file | replace: '.js', '/' }}" ---- -{% assign bm = bookmarklets | where: "file", file | first %} -

{{ bm.bookmarklet }}

-... -``` +The directory data file computes: +- `layout`: Always `test` +- `file`: Derived from HTML filename (e.g., `foo.html` → `foo.js`) +- `permalink`: Derived from HTML filename (e.g., `foo.html` → `foo/`) +- `title`: Looked up from bookmarklets data by file -#### Option B: Convention-Based (No Frontmatter Needed) -Use Eleventy's computed data to auto-match HTML files to their JS counterparts by filename convention: -- `bookmarklets/foo.js` → auto-matched by `bookmarklets/foo.html` +Test pages now contain only their test content with no frontmatter required. --- diff --git a/bookmarklets/are-ya-hidden.html b/bookmarklets/are-ya-hidden.html index 0f88cd7..e296f44 100644 --- a/bookmarklets/are-ya-hidden.html +++ b/bookmarklets/are-ya-hidden.html @@ -1,10 +1,3 @@ ---- -permalink: "are-ya-hidden/" -file: "are-ya-hidden.js" -layout: test -title: are ya hidden ---- -