govuk_publishing_components 30.4.1 → 30.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-event-tracker.js +63 -51
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-link-tracker.js +8 -8
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-page-views.js +11 -10
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/init-ga4.js +26 -0
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4.js +1 -3
- data/app/assets/stylesheets/govuk_publishing_components/components/_organisation-logo.scss +2 -4
- data/app/views/govuk_publishing_components/component_guide/show.html.erb +28 -27
- data/lib/govuk_publishing_components/version.rb +1 -1
- data/node_modules/axe-core/README.md +83 -53
- data/node_modules/axe-core/axe.d.ts +403 -224
- data/node_modules/axe-core/axe.js +23281 -21919
- data/node_modules/axe-core/axe.min.js +3 -3
- data/node_modules/axe-core/locales/da.json +795 -780
- data/node_modules/axe-core/locales/de.json +932 -621
- data/node_modules/axe-core/locales/es.json +786 -771
- data/node_modules/axe-core/locales/eu.json +787 -0
- data/node_modules/axe-core/locales/fr.json +982 -840
- data/node_modules/axe-core/locales/ja.json +988 -880
- data/node_modules/axe-core/locales/ko.json +999 -775
- data/node_modules/axe-core/locales/nl.json +46 -34
- data/node_modules/axe-core/locales/pl.json +965 -0
- data/node_modules/axe-core/locales/pt_BR.json +966 -880
- data/node_modules/axe-core/package.json +189 -145
- data/node_modules/axe-core/sri-history.json +312 -192
- data/node_modules/govuk-frontend/govuk/all.js +64 -44
- data/node_modules/govuk-frontend/govuk/components/accordion/_index.scss +1 -1
- data/node_modules/govuk-frontend/govuk/components/accordion/accordion.js +3 -13
- data/node_modules/govuk-frontend/govuk/components/accordion/fixtures.json +12 -12
- data/node_modules/govuk-frontend/govuk/components/accordion/template.njk +5 -1
- data/node_modules/govuk-frontend/govuk/components/character-count/fixtures.json +1 -1
- data/node_modules/govuk-frontend/govuk/components/details/details.js +8 -20
- data/node_modules/govuk-frontend/govuk/components/details/macro-options.json +6 -0
- data/node_modules/govuk-frontend/govuk/components/details/template.njk +1 -1
- data/node_modules/govuk-frontend/govuk/components/error-message/fixtures.json +9 -0
- data/node_modules/govuk-frontend/govuk/components/error-summary/macro-options.json +6 -0
- data/node_modules/govuk-frontend/govuk/components/error-summary/template.njk +2 -2
- data/node_modules/govuk-frontend/govuk/components/footer/fixtures.json +59 -20
- data/node_modules/govuk-frontend/govuk/components/footer/macro-options.json +40 -0
- data/node_modules/govuk-frontend/govuk/components/footer/template.njk +17 -7
- data/node_modules/govuk-frontend/govuk/components/header/_index.scss +14 -21
- data/node_modules/govuk-frontend/govuk/components/header/fixtures.json +11 -11
- data/node_modules/govuk-frontend/govuk/components/header/header.js +53 -11
- data/node_modules/govuk-frontend/govuk/components/header/macro-options.json +2 -2
- data/node_modules/govuk-frontend/govuk/components/header/template.njk +1 -1
- data/node_modules/govuk-frontend/govuk/components/input/_index.scss +9 -10
- data/node_modules/govuk-frontend/govuk/components/inset-text/macro-options.json +6 -0
- data/node_modules/govuk-frontend/govuk/components/inset-text/template.njk +1 -1
- data/node_modules/govuk-frontend/govuk/components/notification-banner/macro-options.json +6 -0
- data/node_modules/govuk-frontend/govuk/components/notification-banner/template.njk +2 -2
- data/node_modules/govuk-frontend/govuk/components/panel/macro-options.json +6 -0
- data/node_modules/govuk-frontend/govuk/components/panel/template.njk +2 -2
- data/node_modules/govuk-frontend/govuk/components/select/_index.scss +6 -0
- data/node_modules/govuk-frontend/govuk/components/select/fixtures.json +15 -1
- data/node_modules/govuk-frontend/govuk/components/summary-list/_index.scss +37 -10
- data/node_modules/govuk-frontend/govuk/components/summary-list/fixtures.json +69 -4
- data/node_modules/govuk-frontend/govuk/components/summary-list/template.njk +3 -3
- data/node_modules/govuk-frontend/govuk/components/tabs/fixtures.json +13 -13
- data/node_modules/govuk-frontend/govuk/components/tabs/template.njk +5 -1
- data/node_modules/govuk-frontend/govuk/helpers/_typography.scss +14 -7
- data/node_modules/govuk-frontend/govuk/overrides/_spacing.scss +56 -12
- data/node_modules/govuk-frontend/govuk/settings/_spacing.scss +4 -8
- data/node_modules/govuk-frontend/govuk/template.njk +5 -5
- data/node_modules/govuk-frontend/govuk-esm/components/accordion/accordion.mjs +3 -13
- data/node_modules/govuk-frontend/govuk-esm/components/details/details.mjs +8 -20
- data/node_modules/govuk-frontend/govuk-esm/components/header/header.mjs +53 -11
- data/node_modules/govuk-frontend/package.json +1 -1
- metadata +6 -584
- data/node_modules/axe-core/CHANGELOG.md +0 -1053
- data/node_modules/axe-core/CONTRIBUTING.md +0 -187
- data/node_modules/axe-core/bower.json +0 -40
- data/node_modules/axe-core/doc/API.md +0 -889
- data/node_modules/axe-core/doc/accessibility-supported.md +0 -33
- data/node_modules/axe-core/doc/act-rules-format.md +0 -37
- data/node_modules/axe-core/doc/aria-supported.md +0 -13
- data/node_modules/axe-core/doc/backwards-compatibility-doc.md +0 -94
- data/node_modules/axe-core/doc/check-message-template.md +0 -124
- data/node_modules/axe-core/doc/code-submission-guidelines.md +0 -178
- data/node_modules/axe-core/doc/developer-guide.md +0 -514
- data/node_modules/axe-core/doc/examples/chrome-debugging-protocol/README.md +0 -13
- data/node_modules/axe-core/doc/examples/chrome-debugging-protocol/axe-cdp.js +0 -81
- data/node_modules/axe-core/doc/examples/chrome-debugging-protocol/package.json +0 -11
- data/node_modules/axe-core/doc/examples/html-handlebars.md +0 -164
- data/node_modules/axe-core/doc/examples/jasmine/README.md +0 -35
- data/node_modules/axe-core/doc/examples/jasmine/karma.conf.js +0 -29
- data/node_modules/axe-core/doc/examples/jasmine/package.json +0 -21
- data/node_modules/axe-core/doc/examples/jasmine/spec/a11y.js +0 -36
- data/node_modules/axe-core/doc/examples/jest_react/README.md +0 -41
- data/node_modules/axe-core/doc/examples/jest_react/link.js +0 -7
- data/node_modules/axe-core/doc/examples/jest_react/link.test.js +0 -24
- data/node_modules/axe-core/doc/examples/jest_react/package.json +0 -28
- data/node_modules/axe-core/doc/examples/jest_react/test-helpers.js +0 -21
- data/node_modules/axe-core/doc/examples/jsdom/package.json +0 -15
- data/node_modules/axe-core/doc/examples/mocha/README.md +0 -35
- data/node_modules/axe-core/doc/examples/mocha/karma.conf.js +0 -29
- data/node_modules/axe-core/doc/examples/mocha/package.json +0 -22
- data/node_modules/axe-core/doc/examples/phantomjs/README.md +0 -17
- data/node_modules/axe-core/doc/examples/phantomjs/axe-phantom.js +0 -53
- data/node_modules/axe-core/doc/examples/phantomjs/package.json +0 -19
- data/node_modules/axe-core/doc/examples/puppeteer/README.md +0 -12
- data/node_modules/axe-core/doc/examples/puppeteer/axe-puppeteer.js +0 -60
- data/node_modules/axe-core/doc/examples/puppeteer/package.json +0 -13
- data/node_modules/axe-core/doc/examples/qunit/README.md +0 -37
- data/node_modules/axe-core/doc/examples/qunit/package.json +0 -21
- data/node_modules/axe-core/doc/examples/test-examples.js +0 -32
- data/node_modules/axe-core/doc/plugins.md +0 -123
- data/node_modules/axe-core/doc/projects.md +0 -48
- data/node_modules/axe-core/doc/rule-descriptions.md +0 -129
- data/node_modules/axe-core/doc/rule-development.md +0 -123
- data/node_modules/axe-core/doc/rule-proposal.md +0 -106
- data/node_modules/axe-core/lib/checks/aria/abstractrole.js +0 -10
- data/node_modules/axe-core/lib/checks/aria/abstractrole.json +0 -14
- data/node_modules/axe-core/lib/checks/aria/allowed-attr.js +0 -39
- data/node_modules/axe-core/lib/checks/aria/allowed-attr.json +0 -14
- data/node_modules/axe-core/lib/checks/aria/aria-allowed-role.js +0 -28
- data/node_modules/axe-core/lib/checks/aria/aria-allowed-role.json +0 -22
- data/node_modules/axe-core/lib/checks/aria/aria-hidden-body.js +0 -1
- data/node_modules/axe-core/lib/checks/aria/aria-hidden-body.json +0 -11
- data/node_modules/axe-core/lib/checks/aria/aria-roledescription.js +0 -14
- data/node_modules/axe-core/lib/checks/aria/aria-roledescription.json +0 -23
- data/node_modules/axe-core/lib/checks/aria/errormessage.js +0 -33
- data/node_modules/axe-core/lib/checks/aria/errormessage.json +0 -14
- data/node_modules/axe-core/lib/checks/aria/fallbackrole.js +0 -1
- data/node_modules/axe-core/lib/checks/aria/fallbackrole.json +0 -11
- data/node_modules/axe-core/lib/checks/aria/has-widget-role.js +0 -6
- data/node_modules/axe-core/lib/checks/aria/has-widget-role.json +0 -12
- data/node_modules/axe-core/lib/checks/aria/implicit-role-fallback.js +0 -6
- data/node_modules/axe-core/lib/checks/aria/implicit-role-fallback.json +0 -12
- data/node_modules/axe-core/lib/checks/aria/invalidrole.js +0 -17
- data/node_modules/axe-core/lib/checks/aria/invalidrole.json +0 -14
- data/node_modules/axe-core/lib/checks/aria/no-implicit-explicit-label.js +0 -21
- data/node_modules/axe-core/lib/checks/aria/no-implicit-explicit-label.json +0 -11
- data/node_modules/axe-core/lib/checks/aria/required-attr.js +0 -53
- data/node_modules/axe-core/lib/checks/aria/required-attr.json +0 -14
- data/node_modules/axe-core/lib/checks/aria/required-children.js +0 -154
- data/node_modules/axe-core/lib/checks/aria/required-children.json +0 -32
- data/node_modules/axe-core/lib/checks/aria/required-parent.js +0 -87
- data/node_modules/axe-core/lib/checks/aria/required-parent.json +0 -14
- data/node_modules/axe-core/lib/checks/aria/unsupportedattr.js +0 -39
- data/node_modules/axe-core/lib/checks/aria/unsupportedattr.json +0 -11
- data/node_modules/axe-core/lib/checks/aria/unsupportedrole.js +0 -1
- data/node_modules/axe-core/lib/checks/aria/unsupportedrole.json +0 -11
- data/node_modules/axe-core/lib/checks/aria/valid-attr-value.js +0 -80
- data/node_modules/axe-core/lib/checks/aria/valid-attr-value.json +0 -19
- data/node_modules/axe-core/lib/checks/aria/valid-attr.js +0 -25
- data/node_modules/axe-core/lib/checks/aria/valid-attr.json +0 -15
- data/node_modules/axe-core/lib/checks/aria/valid-scrollable-semantics.js +0 -62
- data/node_modules/axe-core/lib/checks/aria/valid-scrollable-semantics.json +0 -12
- data/node_modules/axe-core/lib/checks/color/color-contrast.js +0 -86
- data/node_modules/axe-core/lib/checks/color/color-contrast.json +0 -30
- data/node_modules/axe-core/lib/checks/color/link-in-text-block.js +0 -85
- data/node_modules/axe-core/lib/checks/color/link-in-text-block.json +0 -19
- data/node_modules/axe-core/lib/checks/forms/autocomplete-appropriate.js +0 -67
- data/node_modules/axe-core/lib/checks/forms/autocomplete-appropriate.json +0 -11
- data/node_modules/axe-core/lib/checks/forms/autocomplete-valid.js +0 -2
- data/node_modules/axe-core/lib/checks/forms/autocomplete-valid.json +0 -11
- data/node_modules/axe-core/lib/checks/forms/fieldset-after.js +0 -25
- data/node_modules/axe-core/lib/checks/forms/fieldset.js +0 -109
- data/node_modules/axe-core/lib/checks/forms/fieldset.json +0 -20
- data/node_modules/axe-core/lib/checks/forms/group-labelledby-after.js +0 -16
- data/node_modules/axe-core/lib/checks/forms/group-labelledby.js +0 -66
- data/node_modules/axe-core/lib/checks/forms/group-labelledby.json +0 -17
- data/node_modules/axe-core/lib/checks/keyboard/accesskeys-after.js +0 -19
- data/node_modules/axe-core/lib/checks/keyboard/accesskeys.js +0 -5
- data/node_modules/axe-core/lib/checks/keyboard/accesskeys.json +0 -12
- data/node_modules/axe-core/lib/checks/keyboard/focusable-content.js +0 -16
- data/node_modules/axe-core/lib/checks/keyboard/focusable-content.json +0 -11
- data/node_modules/axe-core/lib/checks/keyboard/focusable-disabled.js +0 -30
- data/node_modules/axe-core/lib/checks/keyboard/focusable-disabled.json +0 -11
- data/node_modules/axe-core/lib/checks/keyboard/focusable-element.js +0 -12
- data/node_modules/axe-core/lib/checks/keyboard/focusable-element.json +0 -11
- data/node_modules/axe-core/lib/checks/keyboard/focusable-modal-open.js +0 -14
- data/node_modules/axe-core/lib/checks/keyboard/focusable-modal-open.json +0 -11
- data/node_modules/axe-core/lib/checks/keyboard/focusable-no-name.js +0 -6
- data/node_modules/axe-core/lib/checks/keyboard/focusable-no-name.json +0 -11
- data/node_modules/axe-core/lib/checks/keyboard/focusable-not-tabbable.js +0 -30
- data/node_modules/axe-core/lib/checks/keyboard/focusable-not-tabbable.json +0 -11
- data/node_modules/axe-core/lib/checks/keyboard/landmark-is-top-level.js +0 -18
- data/node_modules/axe-core/lib/checks/keyboard/landmark-is-top-level.json +0 -11
- data/node_modules/axe-core/lib/checks/keyboard/page-has-elm-after.js +0 -11
- data/node_modules/axe-core/lib/checks/keyboard/page-has-elm.js +0 -13
- data/node_modules/axe-core/lib/checks/keyboard/page-has-heading-one.json +0 -15
- data/node_modules/axe-core/lib/checks/keyboard/page-has-main.json +0 -15
- data/node_modules/axe-core/lib/checks/keyboard/page-no-duplicate-after.js +0 -2
- data/node_modules/axe-core/lib/checks/keyboard/page-no-duplicate-banner.json +0 -16
- data/node_modules/axe-core/lib/checks/keyboard/page-no-duplicate-contentinfo.json +0 -16
- data/node_modules/axe-core/lib/checks/keyboard/page-no-duplicate-main.json +0 -15
- data/node_modules/axe-core/lib/checks/keyboard/page-no-duplicate.js +0 -36
- data/node_modules/axe-core/lib/checks/keyboard/tabindex.js +0 -6
- data/node_modules/axe-core/lib/checks/keyboard/tabindex.json +0 -11
- data/node_modules/axe-core/lib/checks/label/alt-space-value.js +0 -3
- data/node_modules/axe-core/lib/checks/label/alt-space-value.json +0 -11
- data/node_modules/axe-core/lib/checks/label/duplicate-img-label.js +0 -22
- data/node_modules/axe-core/lib/checks/label/duplicate-img-label.json +0 -11
- data/node_modules/axe-core/lib/checks/label/explicit.js +0 -15
- data/node_modules/axe-core/lib/checks/label/explicit.json +0 -11
- data/node_modules/axe-core/lib/checks/label/help-same-as-label.js +0 -23
- data/node_modules/axe-core/lib/checks/label/help-same-as-label.json +0 -12
- data/node_modules/axe-core/lib/checks/label/hidden-explicit-label.js +0 -12
- data/node_modules/axe-core/lib/checks/label/hidden-explicit-label.json +0 -11
- data/node_modules/axe-core/lib/checks/label/implicit.js +0 -7
- data/node_modules/axe-core/lib/checks/label/implicit.json +0 -11
- data/node_modules/axe-core/lib/checks/label/label-content-name-mismatch.js +0 -59
- data/node_modules/axe-core/lib/checks/label/label-content-name-mismatch.json +0 -15
- data/node_modules/axe-core/lib/checks/label/multiple-label.js +0 -39
- data/node_modules/axe-core/lib/checks/label/multiple-label.json +0 -11
- data/node_modules/axe-core/lib/checks/label/title-only.js +0 -5
- data/node_modules/axe-core/lib/checks/label/title-only.json +0 -11
- data/node_modules/axe-core/lib/checks/landmarks/landmark-is-unique-after.js +0 -23
- data/node_modules/axe-core/lib/checks/landmarks/landmark-is-unique.js +0 -7
- data/node_modules/axe-core/lib/checks/landmarks/landmark-is-unique.json +0 -12
- data/node_modules/axe-core/lib/checks/language/has-lang.js +0 -20
- data/node_modules/axe-core/lib/checks/language/has-lang.json +0 -14
- data/node_modules/axe-core/lib/checks/language/valid-lang.js +0 -26
- data/node_modules/axe-core/lib/checks/language/valid-lang.json +0 -11
- data/node_modules/axe-core/lib/checks/language/xml-lang-mismatch.js +0 -5
- data/node_modules/axe-core/lib/checks/language/xml-lang-mismatch.json +0 -11
- data/node_modules/axe-core/lib/checks/lists/dlitem.js +0 -23
- data/node_modules/axe-core/lib/checks/lists/dlitem.json +0 -11
- data/node_modules/axe-core/lib/checks/lists/listitem.js +0 -21
- data/node_modules/axe-core/lib/checks/lists/listitem.json +0 -14
- data/node_modules/axe-core/lib/checks/lists/only-dlitems.js +0 -42
- data/node_modules/axe-core/lib/checks/lists/only-dlitems.json +0 -11
- data/node_modules/axe-core/lib/checks/lists/only-listitems.js +0 -58
- data/node_modules/axe-core/lib/checks/lists/only-listitems.json +0 -14
- data/node_modules/axe-core/lib/checks/lists/structured-dlitems.js +0 -22
- data/node_modules/axe-core/lib/checks/lists/structured-dlitems.json +0 -11
- data/node_modules/axe-core/lib/checks/media/caption.js +0 -8
- data/node_modules/axe-core/lib/checks/media/caption.json +0 -11
- data/node_modules/axe-core/lib/checks/media/description.js +0 -8
- data/node_modules/axe-core/lib/checks/media/description.json +0 -11
- data/node_modules/axe-core/lib/checks/media/frame-tested.js +0 -28
- data/node_modules/axe-core/lib/checks/media/frame-tested.json +0 -15
- data/node_modules/axe-core/lib/checks/media/no-autoplay-audio.js +0 -93
- data/node_modules/axe-core/lib/checks/media/no-autoplay-audio.json +0 -15
- data/node_modules/axe-core/lib/checks/mobile/css-orientation-lock.js +0 -251
- data/node_modules/axe-core/lib/checks/mobile/css-orientation-lock.json +0 -15
- data/node_modules/axe-core/lib/checks/mobile/meta-viewport-large.json +0 -15
- data/node_modules/axe-core/lib/checks/mobile/meta-viewport-scale.js +0 -55
- data/node_modules/axe-core/lib/checks/mobile/meta-viewport.json +0 -14
- data/node_modules/axe-core/lib/checks/navigation/header-present.js +0 -4
- data/node_modules/axe-core/lib/checks/navigation/header-present.json +0 -11
- data/node_modules/axe-core/lib/checks/navigation/heading-order-after.js +0 -14
- data/node_modules/axe-core/lib/checks/navigation/heading-order.js +0 -15
- data/node_modules/axe-core/lib/checks/navigation/heading-order.json +0 -12
- data/node_modules/axe-core/lib/checks/navigation/identical-links-same-purpose-after.js +0 -100
- data/node_modules/axe-core/lib/checks/navigation/identical-links-same-purpose.js +0 -31
- data/node_modules/axe-core/lib/checks/navigation/identical-links-same-purpose.json +0 -12
- data/node_modules/axe-core/lib/checks/navigation/internal-link-present.js +0 -4
- data/node_modules/axe-core/lib/checks/navigation/internal-link-present.json +0 -11
- data/node_modules/axe-core/lib/checks/navigation/landmark.js +0 -3
- data/node_modules/axe-core/lib/checks/navigation/landmark.json +0 -11
- data/node_modules/axe-core/lib/checks/navigation/meta-refresh.js +0 -4
- data/node_modules/axe-core/lib/checks/navigation/meta-refresh.json +0 -11
- data/node_modules/axe-core/lib/checks/navigation/p-as-heading.js +0 -93
- data/node_modules/axe-core/lib/checks/navigation/p-as-heading.json +0 -30
- data/node_modules/axe-core/lib/checks/navigation/region.js +0 -107
- data/node_modules/axe-core/lib/checks/navigation/region.json +0 -11
- data/node_modules/axe-core/lib/checks/navigation/skip-link.js +0 -5
- data/node_modules/axe-core/lib/checks/navigation/skip-link.json +0 -12
- data/node_modules/axe-core/lib/checks/navigation/unique-frame-title-after.js +0 -9
- data/node_modules/axe-core/lib/checks/navigation/unique-frame-title.js +0 -6
- data/node_modules/axe-core/lib/checks/navigation/unique-frame-title.json +0 -12
- data/node_modules/axe-core/lib/checks/parsing/duplicate-id-active.json +0 -12
- data/node_modules/axe-core/lib/checks/parsing/duplicate-id-after.js +0 -8
- data/node_modules/axe-core/lib/checks/parsing/duplicate-id-aria.json +0 -12
- data/node_modules/axe-core/lib/checks/parsing/duplicate-id.js +0 -17
- data/node_modules/axe-core/lib/checks/parsing/duplicate-id.json +0 -12
- data/node_modules/axe-core/lib/checks/shared/aria-label.js +0 -2
- data/node_modules/axe-core/lib/checks/shared/aria-label.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/aria-labelledby.js +0 -2
- data/node_modules/axe-core/lib/checks/shared/aria-labelledby.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/avoid-inline-spacing.js +0 -18
- data/node_modules/axe-core/lib/checks/shared/avoid-inline-spacing.json +0 -14
- data/node_modules/axe-core/lib/checks/shared/button-has-visible-text.js +0 -12
- data/node_modules/axe-core/lib/checks/shared/button-has-visible-text.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/doc-has-title.js +0 -2
- data/node_modules/axe-core/lib/checks/shared/doc-has-title.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/exists.js +0 -1
- data/node_modules/axe-core/lib/checks/shared/exists.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/has-alt.js +0 -6
- data/node_modules/axe-core/lib/checks/shared/has-alt.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/has-visible-text.js +0 -1
- data/node_modules/axe-core/lib/checks/shared/has-visible-text.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/is-on-screen.js +0 -4
- data/node_modules/axe-core/lib/checks/shared/is-on-screen.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/non-empty-alt.js +0 -2
- data/node_modules/axe-core/lib/checks/shared/non-empty-alt.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/non-empty-if-present.js +0 -15
- data/node_modules/axe-core/lib/checks/shared/non-empty-if-present.json +0 -14
- data/node_modules/axe-core/lib/checks/shared/non-empty-title.js +0 -2
- data/node_modules/axe-core/lib/checks/shared/non-empty-title.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/non-empty-value.js +0 -2
- data/node_modules/axe-core/lib/checks/shared/non-empty-value.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/role-none.js +0 -1
- data/node_modules/axe-core/lib/checks/shared/role-none.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/role-presentation.js +0 -1
- data/node_modules/axe-core/lib/checks/shared/role-presentation.json +0 -11
- data/node_modules/axe-core/lib/checks/shared/svg-non-empty-title.js +0 -4
- data/node_modules/axe-core/lib/checks/shared/svg-non-empty-title.json +0 -11
- data/node_modules/axe-core/lib/checks/tables/caption-faked.js +0 -10
- data/node_modules/axe-core/lib/checks/tables/caption-faked.json +0 -11
- data/node_modules/axe-core/lib/checks/tables/has-caption.js +0 -1
- data/node_modules/axe-core/lib/checks/tables/has-caption.json +0 -12
- data/node_modules/axe-core/lib/checks/tables/has-summary.js +0 -1
- data/node_modules/axe-core/lib/checks/tables/has-summary.json +0 -12
- data/node_modules/axe-core/lib/checks/tables/has-th.js +0 -31
- data/node_modules/axe-core/lib/checks/tables/has-th.json +0 -12
- data/node_modules/axe-core/lib/checks/tables/headers-visible-text.js +0 -30
- data/node_modules/axe-core/lib/checks/tables/html5-scope.js +0 -5
- data/node_modules/axe-core/lib/checks/tables/html5-scope.json +0 -11
- data/node_modules/axe-core/lib/checks/tables/same-caption-summary.js +0 -7
- data/node_modules/axe-core/lib/checks/tables/same-caption-summary.json +0 -11
- data/node_modules/axe-core/lib/checks/tables/scope-value.js +0 -5
- data/node_modules/axe-core/lib/checks/tables/scope-value.json +0 -11
- data/node_modules/axe-core/lib/checks/tables/td-has-header.js +0 -30
- data/node_modules/axe-core/lib/checks/tables/td-has-header.json +0 -11
- data/node_modules/axe-core/lib/checks/tables/td-headers-attr.js +0 -61
- data/node_modules/axe-core/lib/checks/tables/td-headers-attr.json +0 -12
- data/node_modules/axe-core/lib/checks/tables/th-has-data-cells.js +0 -76
- data/node_modules/axe-core/lib/checks/tables/th-has-data-cells.json +0 -12
- data/node_modules/axe-core/lib/checks/tables/th-single-row-column.js +0 -39
- data/node_modules/axe-core/lib/checks/visibility/hidden-content.js +0 -21
- data/node_modules/axe-core/lib/checks/visibility/hidden-content.json +0 -12
- data/node_modules/axe-core/lib/commons/aria/arialabel-text.js +0 -18
- data/node_modules/axe-core/lib/commons/aria/arialabelledby-text.js +0 -52
- data/node_modules/axe-core/lib/commons/aria/attributes.js +0 -45
- data/node_modules/axe-core/lib/commons/aria/get-element-unallowed-roles.js +0 -113
- data/node_modules/axe-core/lib/commons/aria/get-owned-virtual.js +0 -24
- data/node_modules/axe-core/lib/commons/aria/get-role.js +0 -44
- data/node_modules/axe-core/lib/commons/aria/index.js +0 -2424
- data/node_modules/axe-core/lib/commons/aria/is-accessible-ref.js +0 -59
- data/node_modules/axe-core/lib/commons/aria/is-aria-role-allowed-on-element.js +0 -41
- data/node_modules/axe-core/lib/commons/aria/is-unsupported-role.js +0 -14
- data/node_modules/axe-core/lib/commons/aria/label-virtual.js +0 -54
- data/node_modules/axe-core/lib/commons/aria/named-from-contents.js +0 -39
- data/node_modules/axe-core/lib/commons/aria/roles.js +0 -208
- data/node_modules/axe-core/lib/commons/aria/validate-attr-value.js +0 -62
- data/node_modules/axe-core/lib/commons/color/center-point-of-rect.js +0 -30
- data/node_modules/axe-core/lib/commons/color/contrast.js +0 -178
- data/node_modules/axe-core/lib/commons/color/element-has-image.js +0 -36
- data/node_modules/axe-core/lib/commons/color/element-is-distinct.js +0 -88
- data/node_modules/axe-core/lib/commons/color/get-background-color.js +0 -285
- data/node_modules/axe-core/lib/commons/color/get-foreground-color.js +0 -61
- data/node_modules/axe-core/lib/commons/color/get-own-background-color.js +0 -22
- data/node_modules/axe-core/lib/commons/color/incomplete-data.js +0 -50
- data/node_modules/axe-core/lib/commons/color/index.js +0 -8
- data/node_modules/axe-core/lib/commons/dom/elements-below-floating.js +0 -39
- data/node_modules/axe-core/lib/commons/dom/find-elms-in-context.js +0 -28
- data/node_modules/axe-core/lib/commons/dom/find-up.js +0 -63
- data/node_modules/axe-core/lib/commons/dom/get-composed-parent.js +0 -25
- data/node_modules/axe-core/lib/commons/dom/get-element-by-reference.js +0 -34
- data/node_modules/axe-core/lib/commons/dom/get-element-coordinates.js +0 -38
- data/node_modules/axe-core/lib/commons/dom/get-element-stack.js +0 -589
- data/node_modules/axe-core/lib/commons/dom/get-root-node.js +0 -12
- data/node_modules/axe-core/lib/commons/dom/get-scroll-offset.js +0 -33
- data/node_modules/axe-core/lib/commons/dom/get-tabbable-elements.js +0 -24
- data/node_modules/axe-core/lib/commons/dom/get-viewport-size.js +0 -37
- data/node_modules/axe-core/lib/commons/dom/has-content-virtual.js +0 -75
- data/node_modules/axe-core/lib/commons/dom/idrefs.js +0 -36
- data/node_modules/axe-core/lib/commons/dom/index.js +0 -9
- data/node_modules/axe-core/lib/commons/dom/is-focusable.js +0 -95
- data/node_modules/axe-core/lib/commons/dom/is-hidden-with-css.js +0 -73
- data/node_modules/axe-core/lib/commons/dom/is-html5.js +0 -17
- data/node_modules/axe-core/lib/commons/dom/is-in-text-block.js +0 -94
- data/node_modules/axe-core/lib/commons/dom/is-modal-open.js +0 -98
- data/node_modules/axe-core/lib/commons/dom/is-node.js +0 -13
- data/node_modules/axe-core/lib/commons/dom/is-offscreen.js +0 -62
- data/node_modules/axe-core/lib/commons/dom/is-skip-link.js +0 -45
- data/node_modules/axe-core/lib/commons/dom/is-visible.js +0 -176
- data/node_modules/axe-core/lib/commons/dom/is-visual-content.js +0 -49
- data/node_modules/axe-core/lib/commons/dom/shadow-elements-from-point.js +0 -42
- data/node_modules/axe-core/lib/commons/dom/url-props-from-attribute.js +0 -152
- data/node_modules/axe-core/lib/commons/dom/visually-contains.js +0 -111
- data/node_modules/axe-core/lib/commons/dom/visually-overlaps.js +0 -46
- data/node_modules/axe-core/lib/commons/forms/index.js +0 -8
- data/node_modules/axe-core/lib/commons/forms/is-aria-combobox.js +0 -13
- data/node_modules/axe-core/lib/commons/forms/is-aria-listbox.js +0 -13
- data/node_modules/axe-core/lib/commons/forms/is-aria-range.js +0 -14
- data/node_modules/axe-core/lib/commons/forms/is-aria-textbox.js +0 -13
- data/node_modules/axe-core/lib/commons/forms/is-native-select.js +0 -13
- data/node_modules/axe-core/lib/commons/forms/is-native-textbox.js +0 -28
- data/node_modules/axe-core/lib/commons/index.js +0 -11
- data/node_modules/axe-core/lib/commons/intro.stub +0 -1
- data/node_modules/axe-core/lib/commons/matches/attributes.js +0 -27
- data/node_modules/axe-core/lib/commons/matches/condition.js +0 -19
- data/node_modules/axe-core/lib/commons/matches/from-definition.js +0 -52
- data/node_modules/axe-core/lib/commons/matches/from-function.js +0 -38
- data/node_modules/axe-core/lib/commons/matches/from-primative.js +0 -30
- data/node_modules/axe-core/lib/commons/matches/index.js +0 -39
- data/node_modules/axe-core/lib/commons/matches/node-name.js +0 -24
- data/node_modules/axe-core/lib/commons/matches/properties.js +0 -28
- data/node_modules/axe-core/lib/commons/outro.stub +0 -2
- data/node_modules/axe-core/lib/commons/table/get-all-cells.js +0 -28
- data/node_modules/axe-core/lib/commons/table/get-cell-position.js +0 -28
- data/node_modules/axe-core/lib/commons/table/get-headers.js +0 -79
- data/node_modules/axe-core/lib/commons/table/get-scope.js +0 -54
- data/node_modules/axe-core/lib/commons/table/index.js +0 -9
- data/node_modules/axe-core/lib/commons/table/is-column-header.js +0 -13
- data/node_modules/axe-core/lib/commons/table/is-data-cell.js +0 -22
- data/node_modules/axe-core/lib/commons/table/is-data-table.js +0 -189
- data/node_modules/axe-core/lib/commons/table/is-header.js +0 -22
- data/node_modules/axe-core/lib/commons/table/is-row-header.js +0 -13
- data/node_modules/axe-core/lib/commons/table/to-grid.js +0 -38
- data/node_modules/axe-core/lib/commons/table/traverse.js +0 -78
- data/node_modules/axe-core/lib/commons/text/accessible-text-virtual.js +0 -152
- data/node_modules/axe-core/lib/commons/text/form-control-value.js +0 -192
- data/node_modules/axe-core/lib/commons/text/index.js +0 -8
- data/node_modules/axe-core/lib/commons/text/is-human-interpretable.js +0 -51
- data/node_modules/axe-core/lib/commons/text/is-icon-ligature.js +0 -210
- data/node_modules/axe-core/lib/commons/text/is-valid-autocomplete.js +0 -117
- data/node_modules/axe-core/lib/commons/text/label-text.js +0 -58
- data/node_modules/axe-core/lib/commons/text/label-virtual.js +0 -53
- data/node_modules/axe-core/lib/commons/text/native-element-types.js +0 -100
- data/node_modules/axe-core/lib/commons/text/native-text-alternative.js +0 -50
- data/node_modules/axe-core/lib/commons/text/native-text-methods.js +0 -122
- data/node_modules/axe-core/lib/commons/text/sanitize.js +0 -18
- data/node_modules/axe-core/lib/commons/text/subtree-text.js +0 -89
- data/node_modules/axe-core/lib/commons/text/title-text.js +0 -33
- data/node_modules/axe-core/lib/commons/text/unicode.js +0 -147
- data/node_modules/axe-core/lib/commons/text/unsupported.js +0 -5
- data/node_modules/axe-core/lib/commons/text/visible-text-nodes.js +0 -25
- data/node_modules/axe-core/lib/commons/text/visible-virtual.js +0 -46
- data/node_modules/axe-core/lib/commons/utils/index.js +0 -10
- data/node_modules/axe-core/lib/core/base/audit.js +0 -781
- data/node_modules/axe-core/lib/core/base/cache.js +0 -33
- data/node_modules/axe-core/lib/core/base/check-result.js +0 -33
- data/node_modules/axe-core/lib/core/base/check.js +0 -170
- data/node_modules/axe-core/lib/core/base/context.js +0 -274
- data/node_modules/axe-core/lib/core/base/rule-result.js +0 -39
- data/node_modules/axe-core/lib/core/base/rule.js +0 -560
- data/node_modules/axe-core/lib/core/base/virtual-node/abstract-virtual-node.js +0 -40
- data/node_modules/axe-core/lib/core/base/virtual-node/serial-virtual-node.js +0 -88
- data/node_modules/axe-core/lib/core/base/virtual-node/virtual-node.js +0 -136
- data/node_modules/axe-core/lib/core/constants.js +0 -76
- data/node_modules/axe-core/lib/core/imports/index.js +0 -51
- data/node_modules/axe-core/lib/core/index.js +0 -43
- data/node_modules/axe-core/lib/core/log.js +0 -12
- data/node_modules/axe-core/lib/core/public/cleanup-plugins.js +0 -53
- data/node_modules/axe-core/lib/core/public/configure.js +0 -110
- data/node_modules/axe-core/lib/core/public/get-rules.js +0 -29
- data/node_modules/axe-core/lib/core/public/load.js +0 -66
- data/node_modules/axe-core/lib/core/public/plugins.js +0 -47
- data/node_modules/axe-core/lib/core/public/reporter.js +0 -24
- data/node_modules/axe-core/lib/core/public/reset.js +0 -12
- data/node_modules/axe-core/lib/core/public/run-rules.js +0 -96
- data/node_modules/axe-core/lib/core/public/run-virtual-rule.js +0 -50
- data/node_modules/axe-core/lib/core/public/run.js +0 -159
- data/node_modules/axe-core/lib/core/reporters/helpers/failure-summary.js +0 -35
- data/node_modules/axe-core/lib/core/reporters/helpers/get-environment-data.js +0 -39
- data/node_modules/axe-core/lib/core/reporters/helpers/incomplete-fallback-msg.js +0 -13
- data/node_modules/axe-core/lib/core/reporters/helpers/index.js +0 -3
- data/node_modules/axe-core/lib/core/reporters/helpers/process-aggregate.js +0 -102
- data/node_modules/axe-core/lib/core/reporters/na.js +0 -24
- data/node_modules/axe-core/lib/core/reporters/no-passes.js +0 -18
- data/node_modules/axe-core/lib/core/reporters/raw-env.js +0 -12
- data/node_modules/axe-core/lib/core/reporters/raw.js +0 -32
- data/node_modules/axe-core/lib/core/reporters/v1.js +0 -29
- data/node_modules/axe-core/lib/core/reporters/v2.js +0 -22
- data/node_modules/axe-core/lib/core/utils/aggregate.js +0 -19
- data/node_modules/axe-core/lib/core/utils/aggregateChecks.js +0 -85
- data/node_modules/axe-core/lib/core/utils/aggregateNodeResults.js +0 -61
- data/node_modules/axe-core/lib/core/utils/aggregateResult.js +0 -37
- data/node_modules/axe-core/lib/core/utils/are-styles-set.js +0 -21
- data/node_modules/axe-core/lib/core/utils/assert.js +0 -12
- data/node_modules/axe-core/lib/core/utils/check-helper.js +0 -38
- data/node_modules/axe-core/lib/core/utils/clone.js +0 -27
- data/node_modules/axe-core/lib/core/utils/collect-results-from-frames.js +0 -127
- data/node_modules/axe-core/lib/core/utils/contains.js +0 -44
- data/node_modules/axe-core/lib/core/utils/css-parser.js +0 -7
- data/node_modules/axe-core/lib/core/utils/dq-element.js +0 -97
- data/node_modules/axe-core/lib/core/utils/element-matches.js +0 -43
- data/node_modules/axe-core/lib/core/utils/escape-selector.js +0 -78
- data/node_modules/axe-core/lib/core/utils/extend-meta-data.js +0 -17
- data/node_modules/axe-core/lib/core/utils/finalize-result.js +0 -11
- data/node_modules/axe-core/lib/core/utils/find-by.js +0 -14
- data/node_modules/axe-core/lib/core/utils/flattened-tree.js +0 -156
- data/node_modules/axe-core/lib/core/utils/get-all-checks.js +0 -12
- data/node_modules/axe-core/lib/core/utils/get-base-lang.js +0 -16
- data/node_modules/axe-core/lib/core/utils/get-check-message.js +0 -21
- data/node_modules/axe-core/lib/core/utils/get-check-option.js +0 -39
- data/node_modules/axe-core/lib/core/utils/get-friendly-uri-end.js +0 -144
- data/node_modules/axe-core/lib/core/utils/get-node-attributes.js +0 -21
- data/node_modules/axe-core/lib/core/utils/get-root-node.js +0 -17
- data/node_modules/axe-core/lib/core/utils/get-scroll.js +0 -39
- data/node_modules/axe-core/lib/core/utils/get-selector.js +0 -409
- data/node_modules/axe-core/lib/core/utils/get-stylesheet-factory.js +0 -51
- data/node_modules/axe-core/lib/core/utils/get-xpath.js +0 -83
- data/node_modules/axe-core/lib/core/utils/index.js +0 -10
- data/node_modules/axe-core/lib/core/utils/inject-style.js +0 -38
- data/node_modules/axe-core/lib/core/utils/is-hidden.js +0 -52
- data/node_modules/axe-core/lib/core/utils/is-html-element.js +0 -135
- data/node_modules/axe-core/lib/core/utils/is-shadow-root.js +0 -40
- data/node_modules/axe-core/lib/core/utils/is-xhtml.js +0 -14
- data/node_modules/axe-core/lib/core/utils/matches.js +0 -263
- data/node_modules/axe-core/lib/core/utils/memoize.js +0 -17
- data/node_modules/axe-core/lib/core/utils/merge-results.js +0 -116
- data/node_modules/axe-core/lib/core/utils/node-sorter.js +0 -21
- data/node_modules/axe-core/lib/core/utils/parse-crossorigin-stylesheet.js +0 -54
- data/node_modules/axe-core/lib/core/utils/parse-sameorigin-stylesheet.js +0 -96
- data/node_modules/axe-core/lib/core/utils/parse-stylesheet.js +0 -70
- data/node_modules/axe-core/lib/core/utils/performance-timer.js +0 -126
- data/node_modules/axe-core/lib/core/utils/pollyfills.js +0 -299
- data/node_modules/axe-core/lib/core/utils/preload-cssom.js +0 -253
- data/node_modules/axe-core/lib/core/utils/preload-media.js +0 -65
- data/node_modules/axe-core/lib/core/utils/preload.js +0 -144
- data/node_modules/axe-core/lib/core/utils/process-message.js +0 -72
- data/node_modules/axe-core/lib/core/utils/publish-metadata.js +0 -106
- data/node_modules/axe-core/lib/core/utils/qsa.js +0 -110
- data/node_modules/axe-core/lib/core/utils/queue.js +0 -138
- data/node_modules/axe-core/lib/core/utils/respondable.js +0 -261
- data/node_modules/axe-core/lib/core/utils/rule-should-run.js +0 -82
- data/node_modules/axe-core/lib/core/utils/scroll-state.js +0 -57
- data/node_modules/axe-core/lib/core/utils/select.js +0 -135
- data/node_modules/axe-core/lib/core/utils/to-array.js +0 -21
- data/node_modules/axe-core/lib/core/utils/token-list.js +0 -15
- data/node_modules/axe-core/lib/core/utils/uuid.js +0 -244
- data/node_modules/axe-core/lib/core/utils/valid-input-type.js +0 -35
- data/node_modules/axe-core/lib/core/utils/valid-langs.js +0 -8152
- data/node_modules/axe-core/lib/intro.stub +0 -15
- data/node_modules/axe-core/lib/misc/any-failure-summary.json +0 -6
- data/node_modules/axe-core/lib/misc/incomplete-fallback.json +0 -3
- data/node_modules/axe-core/lib/misc/none-failure-summary.json +0 -6
- data/node_modules/axe-core/lib/outro.stub +0 -2
- data/node_modules/axe-core/lib/rules/accesskeys.json +0 -13
- data/node_modules/axe-core/lib/rules/area-alt.json +0 -21
- data/node_modules/axe-core/lib/rules/aria-allowed-attr-matches.js +0 -11
- data/node_modules/axe-core/lib/rules/aria-allowed-attr.json +0 -12
- data/node_modules/axe-core/lib/rules/aria-allowed-role-matches.js +0 -7
- data/node_modules/axe-core/lib/rules/aria-allowed-role.json +0 -14
- data/node_modules/axe-core/lib/rules/aria-dpub-role-fallback-matches.js +0 -10
- data/node_modules/axe-core/lib/rules/aria-dpub-role-fallback.json +0 -14
- data/node_modules/axe-core/lib/rules/aria-form-field-name-matches.js +0 -50
- data/node_modules/axe-core/lib/rules/aria-has-attr-matches.js +0 -11
- data/node_modules/axe-core/lib/rules/aria-hidden-body.json +0 -13
- data/node_modules/axe-core/lib/rules/aria-hidden-focus-matches.js +0 -18
- data/node_modules/axe-core/lib/rules/aria-hidden-focus.json +0 -18
- data/node_modules/axe-core/lib/rules/aria-input-field-name.json +0 -13
- data/node_modules/axe-core/lib/rules/aria-required-attr.json +0 -12
- data/node_modules/axe-core/lib/rules/aria-required-children.json +0 -12
- data/node_modules/axe-core/lib/rules/aria-required-parent.json +0 -12
- data/node_modules/axe-core/lib/rules/aria-roledescription.json +0 -12
- data/node_modules/axe-core/lib/rules/aria-roles.json +0 -13
- data/node_modules/axe-core/lib/rules/aria-toggle-field-name.json +0 -18
- data/node_modules/axe-core/lib/rules/aria-valid-attr-value.json +0 -12
- data/node_modules/axe-core/lib/rules/aria-valid-attr.json +0 -12
- data/node_modules/axe-core/lib/rules/audio-caption.json +0 -20
- data/node_modules/axe-core/lib/rules/autocomplete-matches.js +0 -49
- data/node_modules/axe-core/lib/rules/autocomplete-valid.json +0 -12
- data/node_modules/axe-core/lib/rules/avoid-inline-spacing.json +0 -12
- data/node_modules/axe-core/lib/rules/blink.json +0 -19
- data/node_modules/axe-core/lib/rules/button-name.json +0 -25
- data/node_modules/axe-core/lib/rules/bypass-matches.js +0 -1
- data/node_modules/axe-core/lib/rules/bypass.json +0 -20
- data/node_modules/axe-core/lib/rules/checkboxgroup.json +0 -13
- data/node_modules/axe-core/lib/rules/color-contrast-matches.js +0 -161
- data/node_modules/axe-core/lib/rules/color-contrast.json +0 -13
- data/node_modules/axe-core/lib/rules/css-orientation-lock.json +0 -13
- data/node_modules/axe-core/lib/rules/data-table-large-matches.js +0 -11
- data/node_modules/axe-core/lib/rules/data-table-matches.js +0 -1
- data/node_modules/axe-core/lib/rules/definition-list.json +0 -13
- data/node_modules/axe-core/lib/rules/dlitem.json +0 -13
- data/node_modules/axe-core/lib/rules/document-title.json +0 -13
- data/node_modules/axe-core/lib/rules/duplicate-id-active-matches.js +0 -8
- data/node_modules/axe-core/lib/rules/duplicate-id-active.json +0 -14
- data/node_modules/axe-core/lib/rules/duplicate-id-aria-matches.js +0 -1
- data/node_modules/axe-core/lib/rules/duplicate-id-aria.json +0 -14
- data/node_modules/axe-core/lib/rules/duplicate-id-misc-matches.js +0 -11
- data/node_modules/axe-core/lib/rules/duplicate-id.json +0 -14
- data/node_modules/axe-core/lib/rules/empty-heading.json +0 -13
- data/node_modules/axe-core/lib/rules/focus-order-semantics.json +0 -13
- data/node_modules/axe-core/lib/rules/form-field-multiple-labels.json +0 -13
- data/node_modules/axe-core/lib/rules/frame-tested.json +0 -12
- data/node_modules/axe-core/lib/rules/frame-title-has-text.js +0 -2
- data/node_modules/axe-core/lib/rules/frame-title-unique.json +0 -13
- data/node_modules/axe-core/lib/rules/frame-title.json +0 -25
- data/node_modules/axe-core/lib/rules/heading-matches.js +0 -15
- data/node_modules/axe-core/lib/rules/heading-order.json +0 -13
- data/node_modules/axe-core/lib/rules/hidden-content.json +0 -13
- data/node_modules/axe-core/lib/rules/html-has-lang.json +0 -13
- data/node_modules/axe-core/lib/rules/html-lang-valid.json +0 -12
- data/node_modules/axe-core/lib/rules/html-namespace-matches.js +0 -1
- data/node_modules/axe-core/lib/rules/html-xml-lang-mismatch.json +0 -13
- data/node_modules/axe-core/lib/rules/identical-links-same-purpose-matches.js +0 -13
- data/node_modules/axe-core/lib/rules/identical-links-same-purpose.json +0 -14
- data/node_modules/axe-core/lib/rules/image-alt.json +0 -25
- data/node_modules/axe-core/lib/rules/img-redundant-alt.json +0 -12
- data/node_modules/axe-core/lib/rules/input-button-name.json +0 -26
- data/node_modules/axe-core/lib/rules/input-image-alt.json +0 -18
- data/node_modules/axe-core/lib/rules/inserted-into-focus-order-matches.js +0 -1
- data/node_modules/axe-core/lib/rules/label-content-name-mismatch-matches.js +0 -45
- data/node_modules/axe-core/lib/rules/label-content-name-mismatch.json +0 -12
- data/node_modules/axe-core/lib/rules/label-matches.js +0 -11
- data/node_modules/axe-core/lib/rules/label-title-only.json +0 -13
- data/node_modules/axe-core/lib/rules/label.json +0 -26
- data/node_modules/axe-core/lib/rules/landmark-banner-is-top-level.json +0 -13
- data/node_modules/axe-core/lib/rules/landmark-complementary-is-top-level.json +0 -12
- data/node_modules/axe-core/lib/rules/landmark-contentinfo-is-top-level.json +0 -13
- data/node_modules/axe-core/lib/rules/landmark-has-body-context.js +0 -8
- data/node_modules/axe-core/lib/rules/landmark-main-is-top-level.json +0 -12
- data/node_modules/axe-core/lib/rules/landmark-no-duplicate-banner.json +0 -12
- data/node_modules/axe-core/lib/rules/landmark-no-duplicate-contentinfo.json +0 -12
- data/node_modules/axe-core/lib/rules/landmark-no-duplicate-main.json +0 -12
- data/node_modules/axe-core/lib/rules/landmark-one-main.json +0 -12
- data/node_modules/axe-core/lib/rules/landmark-unique-matches.js +0 -41
- data/node_modules/axe-core/lib/rules/landmark-unique.json +0 -13
- data/node_modules/axe-core/lib/rules/layout-table-matches.js +0 -8
- data/node_modules/axe-core/lib/rules/layout-table.json +0 -14
- data/node_modules/axe-core/lib/rules/link-in-text-block-matches.js +0 -14
- data/node_modules/axe-core/lib/rules/link-in-text-block.json +0 -14
- data/node_modules/axe-core/lib/rules/link-name.json +0 -25
- data/node_modules/axe-core/lib/rules/list.json +0 -13
- data/node_modules/axe-core/lib/rules/listitem.json +0 -13
- data/node_modules/axe-core/lib/rules/marquee.json +0 -13
- data/node_modules/axe-core/lib/rules/meta-refresh.json +0 -20
- data/node_modules/axe-core/lib/rules/meta-viewport-large.json +0 -13
- data/node_modules/axe-core/lib/rules/meta-viewport.json +0 -13
- data/node_modules/axe-core/lib/rules/no-autoplay-audio-matches.js +0 -18
- data/node_modules/axe-core/lib/rules/no-autoplay-audio.json +0 -15
- data/node_modules/axe-core/lib/rules/no-empty-role-matches.js +0 -9
- data/node_modules/axe-core/lib/rules/no-role-matches.js +0 -1
- data/node_modules/axe-core/lib/rules/not-html-matches.js +0 -1
- data/node_modules/axe-core/lib/rules/object-alt.json +0 -25
- data/node_modules/axe-core/lib/rules/p-as-heading-matches.js +0 -17
- data/node_modules/axe-core/lib/rules/p-as-heading.json +0 -13
- data/node_modules/axe-core/lib/rules/page-has-heading-one.json +0 -12
- data/node_modules/axe-core/lib/rules/radiogroup.json +0 -13
- data/node_modules/axe-core/lib/rules/region.json +0 -12
- data/node_modules/axe-core/lib/rules/role-img-alt.json +0 -19
- data/node_modules/axe-core/lib/rules/scope-attr-valid.json +0 -12
- data/node_modules/axe-core/lib/rules/scrollable-region-focusable-matches.js +0 -30
- data/node_modules/axe-core/lib/rules/scrollable-region-focusable.json +0 -12
- data/node_modules/axe-core/lib/rules/server-side-image-map.json +0 -18
- data/node_modules/axe-core/lib/rules/skip-link-matches.js +0 -1
- data/node_modules/axe-core/lib/rules/skip-link.json +0 -13
- data/node_modules/axe-core/lib/rules/svg-img-alt.json +0 -24
- data/node_modules/axe-core/lib/rules/svg-namespace-matches.js +0 -1
- data/node_modules/axe-core/lib/rules/tabindex.json +0 -12
- data/node_modules/axe-core/lib/rules/table-duplicate-name.json +0 -12
- data/node_modules/axe-core/lib/rules/table-fake-caption.json +0 -20
- data/node_modules/axe-core/lib/rules/td-has-header.json +0 -20
- data/node_modules/axe-core/lib/rules/td-headers-attr.json +0 -12
- data/node_modules/axe-core/lib/rules/th-has-data-cells.json +0 -13
- data/node_modules/axe-core/lib/rules/valid-lang.json +0 -13
- data/node_modules/axe-core/lib/rules/video-caption.json +0 -19
- data/node_modules/axe-core/lib/rules/video-description.json +0 -21
- data/node_modules/axe-core/lib/rules/window-is-top.js +0 -3
- data/node_modules/axe-core/lib/rules/xml-lang-mismatch-matches.js +0 -12
- data/node_modules/axe-core/typings/axe-core/axe-core-tests.ts +0 -188
@@ -1,135 +0,0 @@
|
|
1
|
-
const htmlTags = [
|
2
|
-
'a',
|
3
|
-
'abbr',
|
4
|
-
'address',
|
5
|
-
'area',
|
6
|
-
'article',
|
7
|
-
'aside',
|
8
|
-
'audio',
|
9
|
-
'b',
|
10
|
-
'base',
|
11
|
-
'bdi',
|
12
|
-
'bdo',
|
13
|
-
'blockquote',
|
14
|
-
'body',
|
15
|
-
'br',
|
16
|
-
'button',
|
17
|
-
'canvas',
|
18
|
-
'caption',
|
19
|
-
'cite',
|
20
|
-
'code',
|
21
|
-
'col',
|
22
|
-
'colgroup',
|
23
|
-
'data',
|
24
|
-
'datalist',
|
25
|
-
'dd',
|
26
|
-
'del',
|
27
|
-
'details',
|
28
|
-
'dfn',
|
29
|
-
'dialog',
|
30
|
-
'div',
|
31
|
-
'dl',
|
32
|
-
'dt',
|
33
|
-
'em',
|
34
|
-
'embed',
|
35
|
-
'fieldset',
|
36
|
-
'figcaption',
|
37
|
-
'figure',
|
38
|
-
'footer',
|
39
|
-
'form',
|
40
|
-
'h1',
|
41
|
-
'h2',
|
42
|
-
'h3',
|
43
|
-
'h4',
|
44
|
-
'h5',
|
45
|
-
'h6',
|
46
|
-
'head',
|
47
|
-
'header',
|
48
|
-
'hgroup',
|
49
|
-
'hr',
|
50
|
-
'html',
|
51
|
-
'i',
|
52
|
-
'iframe',
|
53
|
-
'img',
|
54
|
-
'input',
|
55
|
-
'ins',
|
56
|
-
'kbd',
|
57
|
-
'keygen',
|
58
|
-
'label',
|
59
|
-
'legend',
|
60
|
-
'li',
|
61
|
-
'link',
|
62
|
-
'main',
|
63
|
-
'map',
|
64
|
-
'mark',
|
65
|
-
'math',
|
66
|
-
'menu',
|
67
|
-
'menuitem',
|
68
|
-
'meta',
|
69
|
-
'meter',
|
70
|
-
'nav',
|
71
|
-
'noscript',
|
72
|
-
'object',
|
73
|
-
'ol',
|
74
|
-
'optgroup',
|
75
|
-
'option',
|
76
|
-
'output',
|
77
|
-
'p',
|
78
|
-
'param',
|
79
|
-
'picture',
|
80
|
-
'pre',
|
81
|
-
'progress',
|
82
|
-
'q',
|
83
|
-
'rb',
|
84
|
-
'rp',
|
85
|
-
'rt',
|
86
|
-
'rtc',
|
87
|
-
'ruby',
|
88
|
-
's',
|
89
|
-
'samp',
|
90
|
-
'script',
|
91
|
-
'section',
|
92
|
-
'select',
|
93
|
-
'slot',
|
94
|
-
'small',
|
95
|
-
'source',
|
96
|
-
'span',
|
97
|
-
'strong',
|
98
|
-
'style',
|
99
|
-
'sub',
|
100
|
-
'summary',
|
101
|
-
'sup',
|
102
|
-
'svg',
|
103
|
-
'table',
|
104
|
-
'tbody',
|
105
|
-
'td',
|
106
|
-
'template',
|
107
|
-
'textarea',
|
108
|
-
'tfoot',
|
109
|
-
'th',
|
110
|
-
'thead',
|
111
|
-
'time',
|
112
|
-
'title',
|
113
|
-
'tr',
|
114
|
-
'track',
|
115
|
-
'u',
|
116
|
-
'ul',
|
117
|
-
'var',
|
118
|
-
'video',
|
119
|
-
'wbr'
|
120
|
-
];
|
121
|
-
|
122
|
-
/**
|
123
|
-
* Verifies that if a given html tag is valid
|
124
|
-
* @method isHtmlElement
|
125
|
-
* @memberof axe.utils
|
126
|
-
* @param htmlTag htmlTag to check if valid
|
127
|
-
* @return {Boolean} true/ false
|
128
|
-
*/
|
129
|
-
axe.utils.isHtmlElement = function isHtmlElement(node) {
|
130
|
-
if (node.namespaceURI === 'http://www.w3.org/2000/svg') {
|
131
|
-
return false;
|
132
|
-
}
|
133
|
-
|
134
|
-
return htmlTags.includes(node.nodeName.toLowerCase());
|
135
|
-
};
|
@@ -1,40 +0,0 @@
|
|
1
|
-
/* global axe */
|
2
|
-
|
3
|
-
const possibleShadowRoots = [
|
4
|
-
'article',
|
5
|
-
'aside',
|
6
|
-
'blockquote',
|
7
|
-
'body',
|
8
|
-
'div',
|
9
|
-
'footer',
|
10
|
-
'h1',
|
11
|
-
'h2',
|
12
|
-
'h3',
|
13
|
-
'h4',
|
14
|
-
'h5',
|
15
|
-
'h6',
|
16
|
-
'header',
|
17
|
-
'main',
|
18
|
-
'nav',
|
19
|
-
'p',
|
20
|
-
'section',
|
21
|
-
'span'
|
22
|
-
];
|
23
|
-
/**
|
24
|
-
* Test a node to see if it has a spec-conforming shadow root
|
25
|
-
*
|
26
|
-
* @param {Node} node The HTML DOM node
|
27
|
-
* @return {Boolean}
|
28
|
-
*/
|
29
|
-
axe.utils.isShadowRoot = function isShadowRoot(node) {
|
30
|
-
if (node.shadowRoot) {
|
31
|
-
const nodeName = node.nodeName.toLowerCase();
|
32
|
-
if (
|
33
|
-
possibleShadowRoots.includes(nodeName) ||
|
34
|
-
/^[a-z][a-z0-9_.-]*-[a-z0-9_.-]*$/.test(nodeName)
|
35
|
-
) {
|
36
|
-
return true;
|
37
|
-
}
|
38
|
-
}
|
39
|
-
return false;
|
40
|
-
};
|
@@ -1,14 +0,0 @@
|
|
1
|
-
/**
|
2
|
-
* Determines if a document node is XHTML
|
3
|
-
* @method isXHTML
|
4
|
-
* @memberof axe.utils
|
5
|
-
* @param {Node} doc a document node
|
6
|
-
* @return {Boolean}
|
7
|
-
*/
|
8
|
-
axe.utils.isXHTML = function(doc) {
|
9
|
-
'use strict';
|
10
|
-
if (!doc.createElement) {
|
11
|
-
return false;
|
12
|
-
}
|
13
|
-
return doc.createElement('A').localName === 'A';
|
14
|
-
};
|
@@ -1,263 +0,0 @@
|
|
1
|
-
function matchesTag(vNode, exp) {
|
2
|
-
return (
|
3
|
-
vNode.props.nodeType === 1 &&
|
4
|
-
(exp.tag === '*' || vNode.props.nodeName === exp.tag)
|
5
|
-
);
|
6
|
-
}
|
7
|
-
|
8
|
-
function matchesClasses(vNode, exp) {
|
9
|
-
return !exp.classes || exp.classes.every(cl => vNode.hasClass(cl.value));
|
10
|
-
}
|
11
|
-
|
12
|
-
function matchesAttributes(vNode, exp) {
|
13
|
-
return (
|
14
|
-
!exp.attributes ||
|
15
|
-
exp.attributes.every(att => {
|
16
|
-
var nodeAtt = vNode.attr(att.key);
|
17
|
-
return nodeAtt !== null && (!att.value || att.test(nodeAtt));
|
18
|
-
})
|
19
|
-
);
|
20
|
-
}
|
21
|
-
|
22
|
-
function matchesId(vNode, exp) {
|
23
|
-
return !exp.id || vNode.props.id === exp.id;
|
24
|
-
}
|
25
|
-
|
26
|
-
function matchesPseudos(target, exp) {
|
27
|
-
if (
|
28
|
-
!exp.pseudos ||
|
29
|
-
exp.pseudos.every(pseudo => {
|
30
|
-
if (pseudo.name === 'not') {
|
31
|
-
return !axe.utils.matchesExpression(target, pseudo.expressions[0]);
|
32
|
-
}
|
33
|
-
throw new Error(
|
34
|
-
'the pseudo selector ' + pseudo.name + ' has not yet been implemented'
|
35
|
-
);
|
36
|
-
})
|
37
|
-
) {
|
38
|
-
return true;
|
39
|
-
}
|
40
|
-
return false;
|
41
|
-
}
|
42
|
-
|
43
|
-
function matchExpression(vNode, expression) {
|
44
|
-
return (
|
45
|
-
matchesTag(vNode, expression) &&
|
46
|
-
matchesClasses(vNode, expression) &&
|
47
|
-
matchesAttributes(vNode, expression) &&
|
48
|
-
matchesId(vNode, expression) &&
|
49
|
-
matchesPseudos(vNode, expression)
|
50
|
-
);
|
51
|
-
}
|
52
|
-
|
53
|
-
var escapeRegExp = (function() {
|
54
|
-
/*! Credit: XRegExp 0.6.1 (c) 2007-2008 Steven Levithan <http://stevenlevithan.com/regex/xregexp/> MIT License */
|
55
|
-
var from = /(?=[\-\[\]{}()*+?.\\\^$|,#\s])/g;
|
56
|
-
var to = '\\';
|
57
|
-
return function(string) {
|
58
|
-
return string.replace(from, to);
|
59
|
-
};
|
60
|
-
})();
|
61
|
-
|
62
|
-
const reUnescape = /\\/g;
|
63
|
-
function convertAttributes(atts) {
|
64
|
-
/*! Credit Mootools Copyright Mootools, MIT License */
|
65
|
-
if (!atts) {
|
66
|
-
return;
|
67
|
-
}
|
68
|
-
return atts.map(att => {
|
69
|
-
const attributeKey = att.name.replace(reUnescape, '');
|
70
|
-
const attributeValue = (att.value || '').replace(reUnescape, '');
|
71
|
-
let test, regexp;
|
72
|
-
|
73
|
-
switch (att.operator) {
|
74
|
-
case '^=':
|
75
|
-
regexp = new RegExp('^' + escapeRegExp(attributeValue));
|
76
|
-
break;
|
77
|
-
case '$=':
|
78
|
-
regexp = new RegExp(escapeRegExp(attributeValue) + '$');
|
79
|
-
break;
|
80
|
-
case '~=':
|
81
|
-
regexp = new RegExp(
|
82
|
-
'(^|\\s)' + escapeRegExp(attributeValue) + '(\\s|$)'
|
83
|
-
);
|
84
|
-
break;
|
85
|
-
case '|=':
|
86
|
-
regexp = new RegExp('^' + escapeRegExp(attributeValue) + '(-|$)');
|
87
|
-
break;
|
88
|
-
case '=':
|
89
|
-
test = function(value) {
|
90
|
-
return attributeValue === value;
|
91
|
-
};
|
92
|
-
break;
|
93
|
-
case '*=':
|
94
|
-
test = function(value) {
|
95
|
-
return value && value.includes(attributeValue);
|
96
|
-
};
|
97
|
-
break;
|
98
|
-
case '!=':
|
99
|
-
test = function(value) {
|
100
|
-
return attributeValue !== value;
|
101
|
-
};
|
102
|
-
break;
|
103
|
-
default:
|
104
|
-
test = function(value) {
|
105
|
-
return !!value;
|
106
|
-
};
|
107
|
-
}
|
108
|
-
|
109
|
-
if (attributeValue === '' && /^[*$^]=$/.test(att.operator)) {
|
110
|
-
test = function() {
|
111
|
-
return false;
|
112
|
-
};
|
113
|
-
}
|
114
|
-
|
115
|
-
if (!test) {
|
116
|
-
test = function(value) {
|
117
|
-
return value && regexp.test(value);
|
118
|
-
};
|
119
|
-
}
|
120
|
-
return {
|
121
|
-
key: attributeKey,
|
122
|
-
value: attributeValue,
|
123
|
-
test: test
|
124
|
-
};
|
125
|
-
});
|
126
|
-
}
|
127
|
-
|
128
|
-
function convertClasses(classes) {
|
129
|
-
if (!classes) {
|
130
|
-
return;
|
131
|
-
}
|
132
|
-
return classes.map(className => {
|
133
|
-
className = className.replace(reUnescape, '');
|
134
|
-
|
135
|
-
return {
|
136
|
-
value: className,
|
137
|
-
regexp: new RegExp('(^|\\s)' + escapeRegExp(className) + '(\\s|$)')
|
138
|
-
};
|
139
|
-
});
|
140
|
-
}
|
141
|
-
|
142
|
-
function convertPseudos(pseudos) {
|
143
|
-
if (!pseudos) {
|
144
|
-
return;
|
145
|
-
}
|
146
|
-
return pseudos.map(p => {
|
147
|
-
var expressions;
|
148
|
-
|
149
|
-
if (p.name === 'not') {
|
150
|
-
expressions = p.value;
|
151
|
-
expressions = expressions.selectors
|
152
|
-
? expressions.selectors
|
153
|
-
: [expressions];
|
154
|
-
expressions = convertExpressions(expressions);
|
155
|
-
}
|
156
|
-
return {
|
157
|
-
name: p.name,
|
158
|
-
expressions: expressions,
|
159
|
-
value: p.value
|
160
|
-
};
|
161
|
-
});
|
162
|
-
}
|
163
|
-
|
164
|
-
/**
|
165
|
-
* convert the css-selector-parser format into the Slick format
|
166
|
-
* @private
|
167
|
-
* @param Array {Object} expressions
|
168
|
-
* @return Array {Object}
|
169
|
-
*
|
170
|
-
*/
|
171
|
-
function convertExpressions(expressions) {
|
172
|
-
return expressions.map(exp => {
|
173
|
-
var newExp = [];
|
174
|
-
var rule = exp.rule;
|
175
|
-
while (rule) {
|
176
|
-
/* eslint no-restricted-syntax: 0 */
|
177
|
-
// `.tagName` is a property coming from the `CSSSelectorParser` library
|
178
|
-
newExp.push({
|
179
|
-
tag: rule.tagName ? rule.tagName.toLowerCase() : '*',
|
180
|
-
combinator: rule.nestingOperator ? rule.nestingOperator : ' ',
|
181
|
-
id: rule.id,
|
182
|
-
attributes: convertAttributes(rule.attrs),
|
183
|
-
classes: convertClasses(rule.classNames),
|
184
|
-
pseudos: convertPseudos(rule.pseudos)
|
185
|
-
});
|
186
|
-
rule = rule.rule;
|
187
|
-
}
|
188
|
-
return newExp;
|
189
|
-
});
|
190
|
-
}
|
191
|
-
|
192
|
-
/**
|
193
|
-
* Convert a CSS selector to the Slick format expression
|
194
|
-
*
|
195
|
-
* @private
|
196
|
-
* @param {String} selector CSS selector to convert
|
197
|
-
* @returns {Object[]} Array of Slick format expressions
|
198
|
-
*/
|
199
|
-
axe.utils.convertSelector = function convertSelector(selector) {
|
200
|
-
var expressions = axe.utils.cssParser.parse(selector);
|
201
|
-
expressions = expressions.selectors ? expressions.selectors : [expressions];
|
202
|
-
return convertExpressions(expressions);
|
203
|
-
};
|
204
|
-
|
205
|
-
/**
|
206
|
-
* Determine if a virtual node matches a Slick format CSS expression
|
207
|
-
*
|
208
|
-
* @private
|
209
|
-
* @method matchesExpression
|
210
|
-
* @memberof axe.utils
|
211
|
-
* @param {VirtualNode} vNode VirtualNode to match
|
212
|
-
* @param {Object|Object[]} expressions CSS selector expression or array of expressions
|
213
|
-
* @returns {Boolean}
|
214
|
-
*/
|
215
|
-
axe.utils.matchesExpression = function matchesExpression(
|
216
|
-
vNode,
|
217
|
-
expressions,
|
218
|
-
matchAnyParent
|
219
|
-
) {
|
220
|
-
let exps = [].concat(expressions);
|
221
|
-
let expression = exps.pop();
|
222
|
-
let matches = matchExpression(vNode, expression);
|
223
|
-
|
224
|
-
while (!matches && matchAnyParent && vNode.parent) {
|
225
|
-
vNode = vNode.parent;
|
226
|
-
matches = matchExpression(vNode, expression);
|
227
|
-
}
|
228
|
-
|
229
|
-
if (exps.length) {
|
230
|
-
if ([' ', '>'].includes(expression.combinator) === false) {
|
231
|
-
throw new Error(
|
232
|
-
'axe.utils.matchesExpression does not support the combinator: ' +
|
233
|
-
expression.combinator
|
234
|
-
);
|
235
|
-
}
|
236
|
-
|
237
|
-
matches =
|
238
|
-
matches &&
|
239
|
-
axe.utils.matchesExpression(
|
240
|
-
vNode.parent,
|
241
|
-
exps,
|
242
|
-
expression.combinator === ' '
|
243
|
-
);
|
244
|
-
}
|
245
|
-
|
246
|
-
return matches;
|
247
|
-
};
|
248
|
-
|
249
|
-
/**
|
250
|
-
* matches implementation that operates on a VirtualNode
|
251
|
-
*
|
252
|
-
* @method matches
|
253
|
-
* @memberof axe.utils
|
254
|
-
* @param {VirtualNode} vNode VirtualNode to match
|
255
|
-
* @param {String} selector CSS selector string
|
256
|
-
* @return {Boolean}
|
257
|
-
*/
|
258
|
-
axe.utils.matches = function matches(vNode, selector) {
|
259
|
-
let expressions = axe.utils.convertSelector(selector);
|
260
|
-
return expressions.some(expression =>
|
261
|
-
axe.utils.matchesExpression(vNode, expression)
|
262
|
-
);
|
263
|
-
};
|
@@ -1,17 +0,0 @@
|
|
1
|
-
/**
|
2
|
-
* Memoize a function.
|
3
|
-
* @method memoize
|
4
|
-
* @memberof axe.utils
|
5
|
-
* @param {Function} fn Function to memoize
|
6
|
-
* @return {Function}
|
7
|
-
*/
|
8
|
-
axe._memoizedFns = [];
|
9
|
-
axe.utils.memoize = function(fn) {
|
10
|
-
// keep track of each function that is memoized so it can be cleared at
|
11
|
-
// the end of a run. each memoized function has its own cache, so there is
|
12
|
-
// no method to clear all memoized caches. instead, we have to clear each
|
13
|
-
// individual memoized function ourselves.
|
14
|
-
const memoized = axe.imports.memoize(fn);
|
15
|
-
axe._memoizedFns.push(memoized);
|
16
|
-
return memoized;
|
17
|
-
};
|
@@ -1,116 +0,0 @@
|
|
1
|
-
/**
|
2
|
-
* Adds the owning frame's CSS selector onto each instance of DqElement
|
3
|
-
* @private
|
4
|
-
* @param {Array} resultSet `nodes` array on a `RuleResult`
|
5
|
-
* @param {HTMLElement} frameElement The frame element
|
6
|
-
* @param {String} frameSelector Unique CSS selector for the frame
|
7
|
-
*/
|
8
|
-
function pushFrame(resultSet, options, frameElement, frameSelector) {
|
9
|
-
'use strict';
|
10
|
-
var frameXpath = axe.utils.getXpath(frameElement);
|
11
|
-
var frameSpec = {
|
12
|
-
element: frameElement,
|
13
|
-
selector: frameSelector,
|
14
|
-
xpath: frameXpath
|
15
|
-
};
|
16
|
-
|
17
|
-
resultSet.forEach(function(res) {
|
18
|
-
res.node = axe.utils.DqElement.fromFrame(res.node, options, frameSpec);
|
19
|
-
|
20
|
-
var checks = axe.utils.getAllChecks(res);
|
21
|
-
if (checks.length) {
|
22
|
-
checks.forEach(function(check) {
|
23
|
-
check.relatedNodes = check.relatedNodes.map(node =>
|
24
|
-
axe.utils.DqElement.fromFrame(node, options, frameSpec)
|
25
|
-
);
|
26
|
-
});
|
27
|
-
}
|
28
|
-
});
|
29
|
-
}
|
30
|
-
|
31
|
-
/**
|
32
|
-
* Adds `to` to `from` and then re-sorts by DOM order
|
33
|
-
* @private
|
34
|
-
* @param {Array} target `nodes` array on a `RuleResult`
|
35
|
-
* @param {Array} to `nodes` array on a `RuleResult`
|
36
|
-
* @return {Array} The merged and sorted result
|
37
|
-
*/
|
38
|
-
function spliceNodes(target, to) {
|
39
|
-
'use strict';
|
40
|
-
|
41
|
-
var firstFromFrame = to[0].node,
|
42
|
-
sorterResult,
|
43
|
-
t;
|
44
|
-
for (var i = 0, l = target.length; i < l; i++) {
|
45
|
-
t = target[i].node;
|
46
|
-
sorterResult = axe.utils.nodeSorter(
|
47
|
-
{ actualNode: t.element },
|
48
|
-
{ actualNode: firstFromFrame.element }
|
49
|
-
);
|
50
|
-
if (
|
51
|
-
sorterResult > 0 ||
|
52
|
-
(sorterResult === 0 && firstFromFrame.selector.length < t.selector.length)
|
53
|
-
) {
|
54
|
-
target.splice.apply(target, [i, 0].concat(to));
|
55
|
-
return;
|
56
|
-
}
|
57
|
-
}
|
58
|
-
|
59
|
-
target.push.apply(target, to);
|
60
|
-
}
|
61
|
-
|
62
|
-
function normalizeResult(result) {
|
63
|
-
'use strict';
|
64
|
-
|
65
|
-
if (!result || !result.results) {
|
66
|
-
return null;
|
67
|
-
}
|
68
|
-
|
69
|
-
if (!Array.isArray(result.results)) {
|
70
|
-
return [result.results];
|
71
|
-
}
|
72
|
-
|
73
|
-
if (!result.results.length) {
|
74
|
-
return null;
|
75
|
-
}
|
76
|
-
|
77
|
-
return result.results;
|
78
|
-
}
|
79
|
-
|
80
|
-
/**
|
81
|
-
* Merges one or more RuleResults (possibly from different frames) into one RuleResult
|
82
|
-
* @private
|
83
|
-
* @param {Array} frameResults Array of objects including the RuleResults as `results` and frame as `frame`
|
84
|
-
* @return {Array} The merged RuleResults; should only have one result per rule
|
85
|
-
*/
|
86
|
-
axe.utils.mergeResults = function mergeResults(frameResults, options) {
|
87
|
-
'use strict';
|
88
|
-
var result = [];
|
89
|
-
frameResults.forEach(function(frameResult) {
|
90
|
-
var results = normalizeResult(frameResult);
|
91
|
-
if (!results || !results.length) {
|
92
|
-
return;
|
93
|
-
}
|
94
|
-
|
95
|
-
results.forEach(function(ruleResult) {
|
96
|
-
if (ruleResult.nodes && frameResult.frame) {
|
97
|
-
pushFrame(
|
98
|
-
ruleResult.nodes,
|
99
|
-
options,
|
100
|
-
frameResult.frameElement,
|
101
|
-
frameResult.frame
|
102
|
-
);
|
103
|
-
}
|
104
|
-
|
105
|
-
var res = axe.utils.findBy(result, 'id', ruleResult.id);
|
106
|
-
if (!res) {
|
107
|
-
result.push(ruleResult);
|
108
|
-
} else {
|
109
|
-
if (ruleResult.nodes.length) {
|
110
|
-
spliceNodes(res.nodes, ruleResult.nodes);
|
111
|
-
}
|
112
|
-
}
|
113
|
-
});
|
114
|
-
});
|
115
|
-
return result;
|
116
|
-
};
|
@@ -1,21 +0,0 @@
|
|
1
|
-
/**
|
2
|
-
* Array#sort callback to sort nodes by DOM order
|
3
|
-
* @private
|
4
|
-
* @param {Node} nodeA
|
5
|
-
* @param {Node} nodeB
|
6
|
-
* @return {Integer} @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/Sort
|
7
|
-
*/
|
8
|
-
axe.utils.nodeSorter = function nodeSorter(nodeA, nodeB) {
|
9
|
-
/*eslint no-bitwise: 0 */
|
10
|
-
nodeA = nodeA.actualNode || nodeA;
|
11
|
-
nodeB = nodeB.actualNode || nodeB;
|
12
|
-
if (nodeA === nodeB) {
|
13
|
-
return 0;
|
14
|
-
}
|
15
|
-
|
16
|
-
if (nodeA.compareDocumentPosition(nodeB) & 4) {
|
17
|
-
return -1; // a before b
|
18
|
-
} else {
|
19
|
-
return 1; // b before a
|
20
|
-
}
|
21
|
-
};
|
@@ -1,54 +0,0 @@
|
|
1
|
-
/**
|
2
|
-
* Parse cross-origin stylesheets
|
3
|
-
*
|
4
|
-
* @method parseCrossOriginStylesheet
|
5
|
-
* @memberof axe.utils
|
6
|
-
* @param {String} url url from which to fetch stylesheet
|
7
|
-
* @param {Object} options options object from `axe.utils.parseStylesheet`
|
8
|
-
* @param {Array<Number>} priority sheet priority
|
9
|
-
* @param {Array<String>} importedUrls urls of already imported stylesheets
|
10
|
-
* @param {Boolean} isCrossOrigin boolean denoting if a stylesheet is `cross-origin`
|
11
|
-
* @returns {Promise}
|
12
|
-
*/
|
13
|
-
axe.utils.parseCrossOriginStylesheet = function parseCrossOriginStylesheet(
|
14
|
-
url,
|
15
|
-
options,
|
16
|
-
priority,
|
17
|
-
importedUrls,
|
18
|
-
isCrossOrigin
|
19
|
-
) {
|
20
|
-
const axiosOptions = {
|
21
|
-
method: 'get',
|
22
|
-
timeout: axe.constants.preload.timeout,
|
23
|
-
url
|
24
|
-
};
|
25
|
-
|
26
|
-
/**
|
27
|
-
* Add `url` to `importedUrls`
|
28
|
-
*/
|
29
|
-
importedUrls.push(url);
|
30
|
-
|
31
|
-
/**
|
32
|
-
* Fetch `cross-origin stylesheet` via axios
|
33
|
-
*/
|
34
|
-
return axe.imports.axios(axiosOptions).then(({ data }) => {
|
35
|
-
const result = options.convertDataToStylesheet({
|
36
|
-
data,
|
37
|
-
isCrossOrigin,
|
38
|
-
priority,
|
39
|
-
root: options.rootNode,
|
40
|
-
shadowId: options.shadowId
|
41
|
-
});
|
42
|
-
|
43
|
-
/**
|
44
|
-
* Parse resolved stylesheet further for any `@import` styles
|
45
|
-
*/
|
46
|
-
return axe.utils.parseStylesheet(
|
47
|
-
result.sheet,
|
48
|
-
options,
|
49
|
-
priority,
|
50
|
-
importedUrls,
|
51
|
-
result.isCrossOrigin
|
52
|
-
);
|
53
|
-
});
|
54
|
-
};
|