Sha256: 46a60448136ffd99ed18526cbcd5b994388ffd554b2e7008ff75d29df7f79416

Contents?: true

Size: 642 Bytes

Versions: 83

Compression:

Stored size: 642 Bytes

Contents

/* eslint-disable no-console */

import axe from 'axe-core'

export const runAxe = function(include = '.pb--kit-example', ignore = ['.pb--kit-example :first-child']) {
  axe
    .run({
      include: [include],
      exclude: [ignore],
    })
    .then((results) => {
      if (results.violations.length) {
        console.warn('🚨 [axe-core] Accessibility issues found. See below for a list:')
        console.dir(results.violations)
      } else {
        console.log('[axe-core] Yay! 🎉 No accessibility violations were found!')
      }
    })
    .catch((err) => {
      console.error('Something bad happened:', err.message)
    })
}

Version data entries

83 entries across 83 versions & 1 rubygems

Version Path
playbook_ui-9.8.0 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.7.0.pre.alphawidth1 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.7.0.pre.alpha.a11y.btn app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.7.0 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.6.1 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.6.1.pre.deps1 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.6.0 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.5.0.alpha.rs.downgrade app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.5.0 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.4.0.alpha.sisense app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.4.0.alpha.user.kit.bug app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.4.0 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.3.1.pre.alpha2 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.4.0.pre.alpha2 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.4.0.pre.alpha1 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.3.1.pre.alpha1 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.3.0.alpha.inline3 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.3.0.pre.alpha.password.strength.2 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.3.0.alpha.inline2 app/pb_kits/playbook/utilities/accessibility.js
playbook_ui-9.3.0.alpha.inline1 app/pb_kits/playbook/utilities/accessibility.js