axe-core 4.3.2 → 4.3.3-canary.2f439b3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/axe.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! axe v4.3.2
1
+ /*! axe v4.3.3-canary.2f439b3
2
2
  * Copyright (c) 2021 Deque Systems, Inc.
3
3
  *
4
4
  * Your use of this Source Code Form is subject to the terms of the Mozilla Public
@@ -27,7 +27,7 @@
27
27
  return _typeof(obj);
28
28
  }
29
29
  var axe = axe || {};
30
- axe.version = '4.3.2';
30
+ axe.version = '4.3.3-canary.2f439b3';
31
31
  if (typeof define === 'function' && define.amd) {
32
32
  define('axe-core', [], function() {
33
33
  return axe;
@@ -54,7 +54,7 @@
54
54
  SupportError.prototype = Object.create(Error.prototype);
55
55
  SupportError.prototype.constructor = SupportError;
56
56
  'use strict';
57
- var _excluded = [ 'node' ], _excluded2 = [ 'node' ], _excluded3 = [ 'variant' ], _excluded4 = [ 'matches' ], _excluded5 = [ 'chromium' ], _excluded6 = [ 'noImplicit' ], _excluded7 = [ 'noPresentational' ], _excluded8 = [ 'nodes' ], _excluded9 = [ 'node' ], _excluded10 = [ 'relatedNodes' ], _excluded11 = [ 'node' ];
57
+ var _excluded = [ 'node' ], _excluded2 = [ 'node' ], _excluded3 = [ 'variant' ], _excluded4 = [ 'matches' ], _excluded5 = [ 'chromium' ], _excluded6 = [ 'noImplicit' ], _excluded7 = [ 'noPresentational' ], _excluded8 = [ 'nodes' ], _excluded9 = [ 'node' ], _excluded10 = [ 'relatedNodes' ], _excluded11 = [ 'environmentData' ], _excluded12 = [ 'environmentData' ], _excluded13 = [ 'node' ], _excluded14 = [ 'environmentData' ], _excluded15 = [ 'environmentData' ], _excluded16 = [ 'environmentData' ];
58
58
  function _defineProperty(obj, key, value) {
59
59
  if (key in obj) {
60
60
  Object.defineProperty(obj, key, {
@@ -1393,11 +1393,11 @@
1393
1393
  } else {
1394
1394
  mixin = require_mixin();
1395
1395
  generate = function() {
1396
- var cache20 = [];
1396
+ var cache21 = [];
1397
1397
  return function(length) {
1398
1398
  var args, i = 0;
1399
- if (cache20[length]) {
1400
- return cache20[length];
1399
+ if (cache21[length]) {
1400
+ return cache21[length];
1401
1401
  }
1402
1402
  args = [];
1403
1403
  while (length--) {
@@ -2216,7 +2216,7 @@
2216
2216
  var _on = ee.on;
2217
2217
  var emit = ee.emit;
2218
2218
  module.exports = function(original, length, options) {
2219
- var cache20 = create(null), conf, memLength, _get, set, del, _clear, extDel, extGet, extHas, normalizer, getListeners, setListeners, deleteListeners, memoized, resolve;
2219
+ var cache21 = create(null), conf, memLength, _get, set, del, _clear, extDel, extGet, extHas, normalizer, getListeners, setListeners, deleteListeners, memoized, resolve;
2220
2220
  if (length !== false) {
2221
2221
  memLength = length;
2222
2222
  } else if (isNaN(original.length)) {
@@ -2242,11 +2242,11 @@
2242
2242
  }
2243
2243
  id = _get(args);
2244
2244
  if (id !== null) {
2245
- if (hasOwnProperty.call(cache20, id)) {
2245
+ if (hasOwnProperty.call(cache21, id)) {
2246
2246
  if (getListeners) {
2247
2247
  conf.emit('get', id, args, this);
2248
2248
  }
2249
- return cache20[id];
2249
+ return cache21[id];
2250
2250
  }
2251
2251
  }
2252
2252
  if (args.length === 1) {
@@ -2260,10 +2260,10 @@
2260
2260
  throw customError('Circular invocation', 'CIRCULAR_INVOCATION');
2261
2261
  }
2262
2262
  id = set(args);
2263
- } else if (hasOwnProperty.call(cache20, id)) {
2263
+ } else if (hasOwnProperty.call(cache21, id)) {
2264
2264
  throw customError('Circular invocation', 'CIRCULAR_INVOCATION');
2265
2265
  }
2266
- cache20[id] = result;
2266
+ cache21[id] = result;
2267
2267
  if (setListeners) {
2268
2268
  conf.emit('set', id, null, result);
2269
2269
  }
@@ -2272,21 +2272,21 @@
2272
2272
  } else if (length === 0) {
2273
2273
  memoized = function memoized() {
2274
2274
  var result;
2275
- if (hasOwnProperty.call(cache20, 'data')) {
2275
+ if (hasOwnProperty.call(cache21, 'data')) {
2276
2276
  if (getListeners) {
2277
2277
  conf.emit('get', 'data', arguments, this);
2278
2278
  }
2279
- return cache20.data;
2279
+ return cache21.data;
2280
2280
  }
2281
2281
  if (arguments.length) {
2282
2282
  result = apply.call(original, this, arguments);
2283
2283
  } else {
2284
2284
  result = call.call(original, this);
2285
2285
  }
2286
- if (hasOwnProperty.call(cache20, 'data')) {
2286
+ if (hasOwnProperty.call(cache21, 'data')) {
2287
2287
  throw customError('Circular invocation', 'CIRCULAR_INVOCATION');
2288
2288
  }
2289
- cache20.data = result;
2289
+ cache21.data = result;
2290
2290
  if (setListeners) {
2291
2291
  conf.emit('set', 'data', null, result);
2292
2292
  }
@@ -2299,21 +2299,21 @@
2299
2299
  args = resolve(arguments);
2300
2300
  }
2301
2301
  id = String(args[0]);
2302
- if (hasOwnProperty.call(cache20, id)) {
2302
+ if (hasOwnProperty.call(cache21, id)) {
2303
2303
  if (getListeners) {
2304
2304
  conf.emit('get', id, args, this);
2305
2305
  }
2306
- return cache20[id];
2306
+ return cache21[id];
2307
2307
  }
2308
2308
  if (args.length === 1) {
2309
2309
  result = call.call(original, this, args[0]);
2310
2310
  } else {
2311
2311
  result = apply.call(original, this, args);
2312
2312
  }
2313
- if (hasOwnProperty.call(cache20, id)) {
2313
+ if (hasOwnProperty.call(cache21, id)) {
2314
2314
  throw customError('Circular invocation', 'CIRCULAR_INVOCATION');
2315
2315
  }
2316
- cache20[id] = result;
2316
+ cache21[id] = result;
2317
2317
  if (setListeners) {
2318
2318
  conf.emit('set', id, null, result);
2319
2319
  }
@@ -2334,28 +2334,28 @@
2334
2334
  return String(args[0]);
2335
2335
  },
2336
2336
  has: function has(id) {
2337
- return hasOwnProperty.call(cache20, id);
2337
+ return hasOwnProperty.call(cache21, id);
2338
2338
  },
2339
2339
  delete: function _delete(id) {
2340
2340
  var result;
2341
- if (!hasOwnProperty.call(cache20, id)) {
2341
+ if (!hasOwnProperty.call(cache21, id)) {
2342
2342
  return;
2343
2343
  }
2344
2344
  if (del) {
2345
2345
  del(id);
2346
2346
  }
2347
- result = cache20[id];
2348
- delete cache20[id];
2347
+ result = cache21[id];
2348
+ delete cache21[id];
2349
2349
  if (deleteListeners) {
2350
2350
  conf.emit('delete', id, result);
2351
2351
  }
2352
2352
  },
2353
2353
  clear: function clear() {
2354
- var oldCache = cache20;
2354
+ var oldCache = cache21;
2355
2355
  if (_clear) {
2356
2356
  _clear();
2357
2357
  }
2358
- cache20 = create(null);
2358
+ cache21 = create(null);
2359
2359
  conf.emit('clear', oldCache);
2360
2360
  },
2361
2361
  on: function on(type, listener) {
@@ -2400,7 +2400,7 @@
2400
2400
  extGet = defineLength(function() {
2401
2401
  var id, args = arguments;
2402
2402
  if (length === 0) {
2403
- return cache20.data;
2403
+ return cache21.data;
2404
2404
  }
2405
2405
  if (resolve) {
2406
2406
  args = resolve(args);
@@ -2410,7 +2410,7 @@
2410
2410
  } else {
2411
2411
  id = String(args[0]);
2412
2412
  }
2413
- return cache20[id];
2413
+ return cache21[id];
2414
2414
  });
2415
2415
  extHas = defineLength(function() {
2416
2416
  var id, args = arguments;
@@ -2561,7 +2561,7 @@
2561
2561
  var indexOf = require_e_index_of();
2562
2562
  var create = Object.create;
2563
2563
  module.exports = function() {
2564
- var lastId = 0, map = [], cache20 = create(null);
2564
+ var lastId = 0, map = [], cache21 = create(null);
2565
2565
  return {
2566
2566
  get: function get(args) {
2567
2567
  var index = 0, set = map, i, length = args.length;
@@ -2609,11 +2609,11 @@
2609
2609
  }
2610
2610
  set[1][i] = ++lastId;
2611
2611
  }
2612
- cache20[lastId] = args;
2612
+ cache21[lastId] = args;
2613
2613
  return lastId;
2614
2614
  },
2615
2615
  delete: function _delete(id) {
2616
- var index = 0, set = map, i, args = cache20[id], length = args.length, path = [];
2616
+ var index = 0, set = map, i, args = cache21[id], length = args.length, path = [];
2617
2617
  if (length === 0) {
2618
2618
  delete set[length];
2619
2619
  } else if (set = set[length]) {
@@ -2640,11 +2640,11 @@
2640
2640
  set[1].splice(i, 1);
2641
2641
  }
2642
2642
  }
2643
- delete cache20[id];
2643
+ delete cache21[id];
2644
2644
  },
2645
2645
  clear: function clear() {
2646
2646
  map = [];
2647
- cache20 = create(null);
2647
+ cache21 = create(null);
2648
2648
  }
2649
2649
  };
2650
2650
  };
@@ -2653,27 +2653,27 @@
2653
2653
  'use strict';
2654
2654
  var indexOf = require_e_index_of();
2655
2655
  module.exports = function() {
2656
- var lastId = 0, argsMap = [], cache20 = [];
2656
+ var lastId = 0, argsMap = [], cache21 = [];
2657
2657
  return {
2658
2658
  get: function get(args) {
2659
2659
  var index = indexOf.call(argsMap, args[0]);
2660
- return index === -1 ? null : cache20[index];
2660
+ return index === -1 ? null : cache21[index];
2661
2661
  },
2662
2662
  set: function set(args) {
2663
2663
  argsMap.push(args[0]);
2664
- cache20.push(++lastId);
2664
+ cache21.push(++lastId);
2665
2665
  return lastId;
2666
2666
  },
2667
2667
  delete: function _delete(id) {
2668
- var index = indexOf.call(cache20, id);
2668
+ var index = indexOf.call(cache21, id);
2669
2669
  if (index !== -1) {
2670
2670
  argsMap.splice(index, 1);
2671
- cache20.splice(index, 1);
2671
+ cache21.splice(index, 1);
2672
2672
  }
2673
2673
  },
2674
2674
  clear: function clear() {
2675
2675
  argsMap = [];
2676
- cache20 = [];
2676
+ cache21 = [];
2677
2677
  }
2678
2678
  };
2679
2679
  };
@@ -2683,7 +2683,7 @@
2683
2683
  var indexOf = require_e_index_of();
2684
2684
  var create = Object.create;
2685
2685
  module.exports = function(length) {
2686
- var lastId = 0, map = [ [], [] ], cache20 = create(null);
2686
+ var lastId = 0, map = [ [], [] ], cache21 = create(null);
2687
2687
  return {
2688
2688
  get: function get(args) {
2689
2689
  var index = 0, set = map, i;
@@ -2717,11 +2717,11 @@
2717
2717
  i = set[0].push(args[index]) - 1;
2718
2718
  }
2719
2719
  set[1][i] = ++lastId;
2720
- cache20[lastId] = args;
2720
+ cache21[lastId] = args;
2721
2721
  return lastId;
2722
2722
  },
2723
2723
  delete: function _delete(id) {
2724
- var index = 0, set = map, i, path = [], args = cache20[id];
2724
+ var index = 0, set = map, i, path = [], args = cache21[id];
2725
2725
  while (index < length - 1) {
2726
2726
  i = indexOf.call(set[0], args[index]);
2727
2727
  if (i === -1) {
@@ -2744,11 +2744,11 @@
2744
2744
  set[0].splice(i, 1);
2745
2745
  set[1].splice(i, 1);
2746
2746
  }
2747
- delete cache20[id];
2747
+ delete cache21[id];
2748
2748
  },
2749
2749
  clear: function clear() {
2750
2750
  map = [ [], [] ];
2751
- cache20 = create(null);
2751
+ cache21 = create(null);
2752
2752
  }
2753
2753
  };
2754
2754
  };
@@ -2861,7 +2861,7 @@
2861
2861
  var apply = Function.prototype.apply;
2862
2862
  var create = Object.create;
2863
2863
  require_registered_extensions().async = function(tbi, conf) {
2864
- var waiting = create(null), cache20 = create(null), base = conf.memoized, original = conf.original, currentCallback, currentContext, currentArgs;
2864
+ var waiting = create(null), cache21 = create(null), base = conf.memoized, original = conf.original, currentCallback, currentContext, currentArgs;
2865
2865
  conf.memoized = defineLength(function(arg) {
2866
2866
  var args = arguments, last = args[args.length - 1];
2867
2867
  if (typeof last === 'function') {
@@ -2893,8 +2893,8 @@
2893
2893
  currentCallback = currentContext = currentArgs = null;
2894
2894
  nextTick(function() {
2895
2895
  var data2;
2896
- if (hasOwnProperty.call(cache20, id)) {
2897
- data2 = cache20[id];
2896
+ if (hasOwnProperty.call(cache21, id)) {
2897
+ data2 = cache21[id];
2898
2898
  conf.emit('getasync', id, args, context5);
2899
2899
  apply.call(cb, data2.context, data2.args);
2900
2900
  } else {
@@ -2928,7 +2928,7 @@
2928
2928
  if (err2) {
2929
2929
  conf['delete'](id);
2930
2930
  } else {
2931
- cache20[id] = {
2931
+ cache21[id] = {
2932
2932
  context: this,
2933
2933
  args: args2
2934
2934
  };
@@ -2975,16 +2975,16 @@
2975
2975
  if (hasOwnProperty.call(waiting, id)) {
2976
2976
  return;
2977
2977
  }
2978
- if (!cache20[id]) {
2978
+ if (!cache21[id]) {
2979
2979
  return;
2980
2980
  }
2981
- result = cache20[id];
2982
- delete cache20[id];
2981
+ result = cache21[id];
2982
+ delete cache21[id];
2983
2983
  conf.emit('deleteasync', id, slice.call(result.args, 1));
2984
2984
  });
2985
2985
  conf.on('clear', function() {
2986
- var oldCache = cache20;
2987
- cache20 = create(null);
2986
+ var oldCache = cache21;
2987
+ cache21 = create(null);
2988
2988
  conf.emit('clearasync', objectMap(oldCache, function(data2) {
2989
2989
  return slice.call(data2.args, 1);
2990
2990
  }));
@@ -3078,7 +3078,7 @@
3078
3078
  var create = Object.create;
3079
3079
  var supportedModes = primitiveSet('then', 'then:finally', 'done', 'done:finally');
3080
3080
  require_registered_extensions().promise = function(mode, conf) {
3081
- var waiting = create(null), cache20 = create(null), promises = create(null);
3081
+ var waiting = create(null), cache21 = create(null), promises = create(null);
3082
3082
  if (mode === true) {
3083
3083
  mode = null;
3084
3084
  } else {
@@ -3090,7 +3090,7 @@
3090
3090
  conf.on('set', function(id, ignore, promise) {
3091
3091
  var isFailed = false;
3092
3092
  if (!isPromise(promise)) {
3093
- cache20[id] = promise;
3093
+ cache21[id] = promise;
3094
3094
  conf.emit('setasync', id, 1);
3095
3095
  return;
3096
3096
  }
@@ -3105,7 +3105,7 @@
3105
3105
  return;
3106
3106
  }
3107
3107
  delete waiting[id];
3108
- cache20[id] = result;
3108
+ cache21[id] = result;
3109
3109
  conf.emit('setasync', id, count);
3110
3110
  };
3111
3111
  var onFailure = function onFailure() {
@@ -3175,16 +3175,16 @@
3175
3175
  delete waiting[id];
3176
3176
  return;
3177
3177
  }
3178
- if (!hasOwnProperty.call(cache20, id)) {
3178
+ if (!hasOwnProperty.call(cache21, id)) {
3179
3179
  return;
3180
3180
  }
3181
- var result = cache20[id];
3182
- delete cache20[id];
3181
+ var result = cache21[id];
3182
+ delete cache21[id];
3183
3183
  conf.emit('deleteasync', id, [ result ]);
3184
3184
  });
3185
3185
  conf.on('clear', function() {
3186
- var oldCache = cache20;
3187
- cache20 = create(null);
3186
+ var oldCache = cache21;
3187
+ cache21 = create(null);
3188
3188
  waiting = create(null);
3189
3189
  promises = create(null);
3190
3190
  conf.emit('clearasync', objectMap(oldCache, function(data2) {
@@ -3206,8 +3206,8 @@
3206
3206
  conf.on('deleteasync', del = function del(id, resultArray) {
3207
3207
  apply.call(dispose, null, resultArray);
3208
3208
  });
3209
- conf.on('clearasync', function(cache20) {
3210
- forEach(cache20, function(result, id) {
3209
+ conf.on('clearasync', function(cache21) {
3210
+ forEach(cache21, function(result, id) {
3211
3211
  del(id, result);
3212
3212
  });
3213
3213
  });
@@ -3216,8 +3216,8 @@
3216
3216
  conf.on('delete', del = function del(id, result) {
3217
3217
  dispose(result);
3218
3218
  });
3219
- conf.on('clear', function(cache20) {
3220
- forEach(cache20, function(result, id) {
3219
+ conf.on('clear', function(cache21) {
3220
+ forEach(cache21, function(result, id) {
3221
3221
  del(id, result);
3222
3222
  });
3223
3223
  });
@@ -3438,20 +3438,20 @@
3438
3438
  var create = Object.create;
3439
3439
  var defineProperties = Object.defineProperties;
3440
3440
  extensions.refCounter = function(ignore, conf, options) {
3441
- var cache20, postfix;
3442
- cache20 = create(null);
3441
+ var cache21, postfix;
3442
+ cache21 = create(null);
3443
3443
  postfix = options.async && extensions.async || options.promise && extensions.promise ? 'async' : '';
3444
3444
  conf.on('set' + postfix, function(id, length) {
3445
- cache20[id] = length || 1;
3445
+ cache21[id] = length || 1;
3446
3446
  });
3447
3447
  conf.on('get' + postfix, function(id) {
3448
- ++cache20[id];
3448
+ ++cache21[id];
3449
3449
  });
3450
3450
  conf.on('delete' + postfix, function(id) {
3451
- delete cache20[id];
3451
+ delete cache21[id];
3452
3452
  });
3453
3453
  conf.on('clear' + postfix, function() {
3454
- cache20 = {};
3454
+ cache21 = {};
3455
3455
  });
3456
3456
  defineProperties(conf.memoized, {
3457
3457
  deleteRef: d(function() {
@@ -3459,10 +3459,10 @@
3459
3459
  if (id === null) {
3460
3460
  return null;
3461
3461
  }
3462
- if (!cache20[id]) {
3462
+ if (!cache21[id]) {
3463
3463
  return null;
3464
3464
  }
3465
- if (!--cache20[id]) {
3465
+ if (!--cache21[id]) {
3466
3466
  conf['delete'](id);
3467
3467
  return true;
3468
3468
  }
@@ -3473,10 +3473,10 @@
3473
3473
  if (id === null) {
3474
3474
  return 0;
3475
3475
  }
3476
- if (!cache20[id]) {
3476
+ if (!cache21[id]) {
3477
3477
  return 0;
3478
3478
  }
3479
- return cache20[id];
3479
+ return cache21[id];
3480
3480
  })
3481
3481
  });
3482
3482
  };
@@ -5043,6 +5043,9 @@
5043
5043
  getCheckOption: function getCheckOption() {
5044
5044
  return get_check_option_default;
5045
5045
  },
5046
+ getEnvironmentData: function getEnvironmentData() {
5047
+ return _getEnvironmentData;
5048
+ },
5046
5049
  getFlattenedTree: function getFlattenedTree() {
5047
5050
  return get_flattened_tree_default;
5048
5051
  },
@@ -7322,13 +7325,14 @@
7322
7325
  });
7323
7326
  }
7324
7327
  function isVisible(el, screenReader, recursed) {
7328
+ var _window$Node;
7325
7329
  if (!el) {
7326
7330
  throw new TypeError('Cannot determine if element is visible for non-DOM nodes');
7327
7331
  }
7328
7332
  var vNode = el instanceof abstract_virtual_node_default ? el : get_node_from_tree_default(el);
7329
7333
  el = vNode ? vNode.actualNode : el;
7330
7334
  var cacheName = '_isVisible' + (screenReader ? 'ScreenReader' : '');
7331
- var _window$Node = window.Node, DOCUMENT_NODE = _window$Node.DOCUMENT_NODE, DOCUMENT_FRAGMENT_NODE = _window$Node.DOCUMENT_FRAGMENT_NODE;
7335
+ var _ref9 = (_window$Node = window.Node) !== null && _window$Node !== void 0 ? _window$Node : {}, DOCUMENT_NODE = _ref9.DOCUMENT_NODE, DOCUMENT_FRAGMENT_NODE = _ref9.DOCUMENT_FRAGMENT_NODE;
7332
7336
  var nodeType = vNode ? vNode.props.nodeType : el.nodeType;
7333
7337
  var nodeName2 = vNode ? vNode.props.nodeName : el.nodeName.toLowerCase();
7334
7338
  if (vNode && typeof vNode[cacheName] !== 'undefined') {
@@ -7371,9 +7375,12 @@
7371
7375
  return false;
7372
7376
  }
7373
7377
  var elHeight = parseInt(style.getPropertyValue('height'));
7374
- var scrollableWithZeroHeight = get_scroll_default(el) && elHeight === 0;
7375
- var posAbsoluteOverflowHiddenAndSmall = style.getPropertyValue('position') === 'absolute' && elHeight < 2 && style.getPropertyValue('overflow') === 'hidden';
7376
- if (!screenReader && (isClipped(style) || style.getPropertyValue('opacity') === '0' || scrollableWithZeroHeight || posAbsoluteOverflowHiddenAndSmall)) {
7378
+ var elWidth = parseInt(style.getPropertyValue('width'));
7379
+ var scroll = get_scroll_default(el);
7380
+ var scrollableWithZeroHeight = scroll && elHeight === 0;
7381
+ var scrollableWithZeroWidth = scroll && elWidth === 0;
7382
+ var posAbsoluteOverflowHiddenAndSmall = style.getPropertyValue('position') === 'absolute' && (elHeight < 2 || elWidth < 2) && style.getPropertyValue('overflow') === 'hidden';
7383
+ if (!screenReader && (isClipped(style) || style.getPropertyValue('opacity') === '0' || scrollableWithZeroHeight || scrollableWithZeroWidth || posAbsoluteOverflowHiddenAndSmall)) {
7377
7384
  return false;
7378
7385
  }
7379
7386
  if (!recursed && (style.getPropertyValue('visibility') === 'hidden' || !screenReader && is_offscreen_default(el))) {
@@ -7565,12 +7572,14 @@
7565
7572
  function addNodeToGrid(grid, vNode) {
7566
7573
  vNode._grid = grid;
7567
7574
  vNode.clientRects.forEach(function(rect) {
7575
+ var _grid$numCols;
7568
7576
  var x = rect.left;
7569
7577
  var y = rect.top;
7570
7578
  var startRow = y / gridSize | 0;
7571
7579
  var startCol = x / gridSize | 0;
7572
7580
  var endRow = (y + rect.height) / gridSize | 0;
7573
7581
  var endCol = (x + rect.width) / gridSize | 0;
7582
+ grid.numCols = Math.max((_grid$numCols = grid.numCols) !== null && _grid$numCols !== void 0 ? _grid$numCols : 0, endCol);
7574
7583
  for (var row = startRow; row <= endRow; row++) {
7575
7584
  grid.cells[row] = grid.cells[row] || [];
7576
7585
  for (var col = startCol; col <= endCol; col++) {
@@ -7637,18 +7646,22 @@
7637
7646
  }
7638
7647
  }
7639
7648
  function getRectStack(grid, rect) {
7649
+ var _grid$cells$row$col$f, _grid$cells$row$col;
7640
7650
  var recursed = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
7641
7651
  var x = rect.left + rect.width / 2;
7642
7652
  var y = rect.top + rect.height / 2;
7643
7653
  var row = y / gridSize | 0;
7644
7654
  var col = x / gridSize | 0;
7645
- var stack = grid.cells[row][col].filter(function(gridCellNode) {
7655
+ if (row > grid.cells.length || col > grid.numCols) {
7656
+ throw new Error('Element midpoint exceeds the grid bounds');
7657
+ }
7658
+ var stack = (_grid$cells$row$col$f = (_grid$cells$row$col = grid.cells[row][col]) === null || _grid$cells$row$col === void 0 ? void 0 : _grid$cells$row$col.filter(function(gridCellNode) {
7646
7659
  return gridCellNode.clientRects.find(function(clientRect) {
7647
7660
  var rectX = clientRect.left;
7648
7661
  var rectY = clientRect.top;
7649
7662
  return x <= rectX + clientRect.width && x >= rectX && y <= rectY + clientRect.height && y >= rectY;
7650
7663
  });
7651
- });
7664
+ })) !== null && _grid$cells$row$col$f !== void 0 ? _grid$cells$row$col$f : [];
7652
7665
  var gridContainer = grid.container;
7653
7666
  if (gridContainer) {
7654
7667
  stack = getRectStack(gridContainer._grid, gridContainer.boundingClientRect, true).concat(stack);
@@ -7824,8 +7837,8 @@
7824
7837
  var hiddenTextElms = [ 'HEAD', 'TITLE', 'TEMPLATE', 'SCRIPT', 'STYLE', 'IFRAME', 'OBJECT', 'VIDEO', 'AUDIO', 'NOSCRIPT' ];
7825
7838
  function hasChildTextNodes(elm) {
7826
7839
  if (!hiddenTextElms.includes(elm.actualNode.nodeName.toUpperCase())) {
7827
- return elm.children.some(function(_ref9) {
7828
- var actualNode = _ref9.actualNode;
7840
+ return elm.children.some(function(_ref10) {
7841
+ var actualNode = _ref10.actualNode;
7829
7842
  return actualNode.nodeType === 3 && actualNode.nodeValue.trim();
7830
7843
  });
7831
7844
  }
@@ -8446,6 +8459,11 @@
8446
8459
  allowedAttrs: [ 'aria-expanded' ],
8447
8460
  superclassRole: [ 'landmark' ]
8448
8461
  },
8462
+ comment: {
8463
+ type: 'structure',
8464
+ allowedAttrs: [ 'aria-level', 'aria-posinset', 'aria-setsize' ],
8465
+ superclassRole: [ 'article' ]
8466
+ },
8449
8467
  definition: {
8450
8468
  type: 'structure',
8451
8469
  allowedAttrs: [ 'aria-expanded' ],
@@ -8557,7 +8575,7 @@
8557
8575
  },
8558
8576
  listbox: {
8559
8577
  type: 'composite',
8560
- requiredOwned: [ 'option' ],
8578
+ requiredOwned: [ 'group', 'option' ],
8561
8579
  allowedAttrs: [ 'aria-multiselectable', 'aria-readonly', 'aria-required', 'aria-activedescendant', 'aria-expanded', 'aria-orientation' ],
8562
8580
  superclassRole: [ 'select' ],
8563
8581
  accessibleNameRequired: true
@@ -8636,6 +8654,11 @@
8636
8654
  accessibleNameRequired: true,
8637
8655
  childrenPresentational: true
8638
8656
  },
8657
+ mark: {
8658
+ type: 'structure',
8659
+ superclassRole: [ 'section' ],
8660
+ prohibitedAttrs: [ 'aria-label', 'aria-labelledby' ]
8661
+ },
8639
8662
  navigation: {
8640
8663
  type: 'landmark',
8641
8664
  allowedAttrs: [ 'aria-expanded' ],
@@ -8653,7 +8676,7 @@
8653
8676
  },
8654
8677
  option: {
8655
8678
  type: 'widget',
8656
- requiredContext: [ 'listbox' ],
8679
+ requiredContext: [ 'group', 'listbox' ],
8657
8680
  allowedAttrs: [ 'aria-selected', 'aria-checked', 'aria-posinset', 'aria-setsize' ],
8658
8681
  superclassRole: [ 'input' ],
8659
8682
  accessibleNameRequired: true,
@@ -8815,6 +8838,12 @@
8815
8838
  nameFromContent: true,
8816
8839
  childrenPresentational: true
8817
8840
  },
8841
+ suggestion: {
8842
+ type: 'structure',
8843
+ requiredOwned: [ 'insertion', 'deletion' ],
8844
+ superclassRole: [ 'section' ],
8845
+ prohibitedAttrs: [ 'aria-label', 'aria-labelledby' ]
8846
+ },
8818
8847
  tab: {
8819
8848
  type: 'widget',
8820
8849
  requiredContext: [ 'tablist' ],
@@ -9191,7 +9220,7 @@
9191
9220
  },
9192
9221
  b: {
9193
9222
  contentTypes: [ 'phrasing', 'flow' ],
9194
- allowedRoles: false
9223
+ allowedRoles: true
9195
9224
  },
9196
9225
  base: {
9197
9226
  allowedRoles: false,
@@ -9594,7 +9623,7 @@
9594
9623
  },
9595
9624
  nav: {
9596
9625
  contentTypes: [ 'sectioning', 'flow' ],
9597
- allowedRoles: [ 'doc-index', 'doc-pagelist', 'doc-toc' ],
9626
+ allowedRoles: [ 'doc-index', 'doc-pagelist', 'doc-toc', 'menu', 'menubar', 'tablist' ],
9598
9627
  shadowRoot: true
9599
9628
  },
9600
9629
  noscript: {
@@ -9653,7 +9682,7 @@
9653
9682
  },
9654
9683
  progress: {
9655
9684
  contentTypes: [ 'phrasing', 'flow' ],
9656
- allowedRoles: true,
9685
+ allowedRoles: false,
9657
9686
  implicitAttrs: {
9658
9687
  'aria-valuemax': '100',
9659
9688
  'aria-valuemin': '0',
@@ -9741,7 +9770,7 @@
9741
9770
  },
9742
9771
  svg: {
9743
9772
  contentTypes: [ 'embedded', 'phrasing', 'flow' ],
9744
- allowedRoles: [ 'application', 'document', 'img' ],
9773
+ allowedRoles: true,
9745
9774
  chromiumRole: 'SVGRoot',
9746
9775
  namingMethods: [ 'svgTitleText' ]
9747
9776
  },
@@ -9833,7 +9862,7 @@
9833
9862
  },
9834
9863
  wbr: {
9835
9864
  contentTypes: [ 'phrasing', 'flow' ],
9836
- allowedRoles: true
9865
+ allowedRoles: [ 'presentation', 'none' ]
9837
9866
  }
9838
9867
  };
9839
9868
  var html_elms_default = htmlElms;
@@ -10025,8 +10054,8 @@
10025
10054
  }
10026
10055
  return parseFloat(value);
10027
10056
  }
10028
- function hslToRgb(_ref10) {
10029
- var _ref11 = _slicedToArray(_ref10, 4), hue = _ref11[0], saturation = _ref11[1], lightness = _ref11[2], alpha = _ref11[3];
10057
+ function hslToRgb(_ref11) {
10058
+ var _ref12 = _slicedToArray(_ref11, 4), hue = _ref12[0], saturation = _ref12[1], lightness = _ref12[2], alpha = _ref12[3];
10030
10059
  saturation /= 255;
10031
10060
  lightness /= 255;
10032
10061
  var high = (1 - Math.abs(2 * lightness - 1)) * saturation;
@@ -10046,8 +10075,8 @@
10046
10075
  } else {
10047
10076
  colors = [ high, 0, low ];
10048
10077
  }
10049
- return colors.map(function(color10) {
10050
- return Math.round((color10 + base) * 255);
10078
+ return colors.map(function(color11) {
10079
+ return Math.round((color11 + base) * 255);
10051
10080
  }).concat(alpha);
10052
10081
  }
10053
10082
  function Color(red, green, blue, alpha) {
@@ -10065,7 +10094,7 @@
10065
10094
  var colorFnRegex = /^((?:rgb|hsl)a?)\s*\(([^\)]*)\)/i;
10066
10095
  this.parseString = function parseString(colorString) {
10067
10096
  if (standards_default.cssColors[colorString] || colorString === 'transparent') {
10068
- var _ref12 = standards_default.cssColors[colorString] || [ 0, 0, 0 ], _ref13 = _slicedToArray(_ref12, 3), red2 = _ref13[0], green2 = _ref13[1], blue2 = _ref13[2];
10097
+ var _ref13 = standards_default.cssColors[colorString] || [ 0, 0, 0 ], _ref14 = _slicedToArray(_ref13, 3), red2 = _ref14[0], green2 = _ref14[1], blue2 = _ref14[2];
10069
10098
  this.red = red2;
10070
10099
  this.green = green2;
10071
10100
  this.blue = blue2;
@@ -10115,7 +10144,7 @@
10115
10144
  }
10116
10145
  };
10117
10146
  this.parseColorFnString = function parseColorFnString(colorString) {
10118
- var _ref14 = colorString.match(colorFnRegex) || [], _ref15 = _slicedToArray(_ref14, 3), colorFunc = _ref15[1], colorValStr = _ref15[2];
10147
+ var _ref15 = colorString.match(colorFnRegex) || [], _ref16 = _slicedToArray(_ref15, 3), colorFunc = _ref16[1], colorValStr = _ref16[2];
10119
10148
  if (!colorFunc || !colorValStr) {
10120
10149
  return;
10121
10150
  }
@@ -10404,7 +10433,7 @@
10404
10433
  key: 'props',
10405
10434
  get: function get() {
10406
10435
  if (!this._cache.hasOwnProperty('props')) {
10407
- var _this$actualNode = this.actualNode, nodeType = _this$actualNode.nodeType, nodeName2 = _this$actualNode.nodeName, id = _this$actualNode.id, multiple = _this$actualNode.multiple, nodeValue = _this$actualNode.nodeValue, value = _this$actualNode.value;
10436
+ var _this$actualNode = this.actualNode, nodeType = _this$actualNode.nodeType, nodeName2 = _this$actualNode.nodeName, id = _this$actualNode.id, multiple = _this$actualNode.multiple, nodeValue = _this$actualNode.nodeValue, value = _this$actualNode.value, selected = _this$actualNode.selected;
10408
10437
  this._cache.props = {
10409
10438
  nodeType: nodeType,
10410
10439
  nodeName: this._isXHTML ? nodeName2 : nodeName2.toLowerCase(),
@@ -10412,7 +10441,8 @@
10412
10441
  type: this._type,
10413
10442
  multiple: multiple,
10414
10443
  nodeValue: nodeValue,
10415
- value: value
10444
+ value: value,
10445
+ selected: selected
10416
10446
  };
10417
10447
  }
10418
10448
  return this._cache.props;
@@ -10600,30 +10630,6 @@
10600
10630
  }).join('\n\n');
10601
10631
  }
10602
10632
  var failure_summary_default = failureSummary;
10603
- function getEnvironmentData() {
10604
- var win = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : window;
10605
- var _win$screen = win.screen, screen = _win$screen === void 0 ? {} : _win$screen, _win$navigator = win.navigator, navigator = _win$navigator === void 0 ? {} : _win$navigator, _win$location = win.location, location = _win$location === void 0 ? {} : _win$location, innerHeight = win.innerHeight, innerWidth = win.innerWidth;
10606
- var orientation = screen.msOrientation || screen.orientation || screen.mozOrientation || {};
10607
- return {
10608
- testEngine: {
10609
- name: 'axe-core',
10610
- version: axe.version
10611
- },
10612
- testRunner: {
10613
- name: axe._audit.brand
10614
- },
10615
- testEnvironment: {
10616
- userAgent: navigator.userAgent,
10617
- windowWidth: innerWidth,
10618
- windowHeight: innerHeight,
10619
- orientationAngle: orientation.angle,
10620
- orientationType: orientation.type
10621
- },
10622
- timestamp: new Date().toISOString(),
10623
- url: location.href
10624
- };
10625
- }
10626
- var get_environment_data_default = getEnvironmentData;
10627
10633
  function incompleteFallbackMessage() {
10628
10634
  return typeof axe._audit.data.incompleteFallbackMessage === 'function' ? axe._audit.data.incompleteFallbackMessage() : axe._audit.data.incompleteFallbackMessage;
10629
10635
  }
@@ -10707,7 +10713,6 @@
10707
10713
  axe._thisWillBeDeletedDoNotUse = axe._thisWillBeDeletedDoNotUse || {};
10708
10714
  axe._thisWillBeDeletedDoNotUse.helpers = {
10709
10715
  failureSummary: failure_summary_default,
10710
- getEnvironmentData: get_environment_data_default,
10711
10716
  incompleteFallbackMessage: incomplete_fallback_msg_default,
10712
10717
  processAggregate: process_aggregate_default
10713
10718
  };
@@ -10790,8 +10795,48 @@
10790
10795
  };
10791
10796
  }
10792
10797
  var get_check_option_default = getCheckOption;
10793
- function createFrameContext(frame, _ref16) {
10794
- var focusable = _ref16.focusable, page = _ref16.page;
10798
+ function _getEnvironmentData() {
10799
+ var _win$location;
10800
+ var metadata = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
10801
+ var win = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : window;
10802
+ if (metadata && _typeof(metadata) === 'object') {
10803
+ return metadata;
10804
+ } else if (_typeof(win) !== 'object') {
10805
+ return {};
10806
+ }
10807
+ return {
10808
+ testEngine: {
10809
+ name: 'axe-core',
10810
+ version: axe.version
10811
+ },
10812
+ testRunner: {
10813
+ name: axe._audit.brand
10814
+ },
10815
+ testEnvironment: getTestEnvironment(win),
10816
+ timestamp: new Date().toISOString(),
10817
+ url: (_win$location = win.location) === null || _win$location === void 0 ? void 0 : _win$location.href
10818
+ };
10819
+ }
10820
+ function getTestEnvironment(win) {
10821
+ if (!win.navigator || _typeof(win.navigator) !== 'object') {
10822
+ return {};
10823
+ }
10824
+ var navigator = win.navigator, innerHeight = win.innerHeight, innerWidth = win.innerWidth;
10825
+ var _ref17 = getOrientation(win) || {}, angle = _ref17.angle, type = _ref17.type;
10826
+ return {
10827
+ userAgent: navigator.userAgent,
10828
+ windowWidth: innerWidth,
10829
+ windowHeight: innerHeight,
10830
+ orientationAngle: angle,
10831
+ orientationType: type
10832
+ };
10833
+ }
10834
+ function getOrientation(_ref18) {
10835
+ var screen = _ref18.screen;
10836
+ return screen.orientation || screen.msOrientation || screen.mozOrientation;
10837
+ }
10838
+ function createFrameContext(frame, _ref19) {
10839
+ var focusable = _ref19.focusable, page = _ref19.page;
10795
10840
  return {
10796
10841
  node: frame,
10797
10842
  include: [],
@@ -10829,8 +10874,8 @@
10829
10874
  }
10830
10875
  context5.frames.push(createFrameContext(frame, context5));
10831
10876
  }
10832
- function isPageContext(_ref17) {
10833
- var include = _ref17.include;
10877
+ function isPageContext(_ref20) {
10878
+ var include = _ref20.include;
10834
10879
  return include.length === 1 && include[0].actualNode === document.documentElement;
10835
10880
  }
10836
10881
  function pushUniqueFrameSelector(context5, type, selectorArray) {
@@ -10930,8 +10975,8 @@
10930
10975
  });
10931
10976
  }
10932
10977
  }
10933
- function getRootNode2(_ref18) {
10934
- var include = _ref18.include, exclude = _ref18.exclude;
10978
+ function getRootNode2(_ref21) {
10979
+ var include = _ref21.include, exclude = _ref21.exclude;
10935
10980
  var selectors = Array.from(include).concat(Array.from(exclude));
10936
10981
  for (var i = 0; i < selectors.length; ++i) {
10937
10982
  var item = selectors[i];
@@ -10980,8 +11025,8 @@
10980
11025
  }
10981
11026
  function _getFrameContexts(context5) {
10982
11027
  var _Context = new Context(context5), frames = _Context.frames;
10983
- return frames.map(function(_ref19) {
10984
- var node = _ref19.node, frameContext = _objectWithoutProperties(_ref19, _excluded2);
11028
+ return frames.map(function(_ref22) {
11029
+ var node = _ref22.node, frameContext = _objectWithoutProperties(_ref22, _excluded2);
10985
11030
  frameContext.initiator = false;
10986
11031
  var frameSelector = _getAncestry(node);
10987
11032
  return {
@@ -11666,8 +11711,8 @@
11666
11711
  return matchExpressions(domTree, expressions, filter);
11667
11712
  }
11668
11713
  var query_selector_all_filter_default = querySelectorAllFilter;
11669
- function preloadCssom(_ref20) {
11670
- var _ref20$treeRoot = _ref20.treeRoot, treeRoot = _ref20$treeRoot === void 0 ? axe._tree[0] : _ref20$treeRoot;
11714
+ function preloadCssom(_ref23) {
11715
+ var _ref23$treeRoot = _ref23.treeRoot, treeRoot = _ref23$treeRoot === void 0 ? axe._tree[0] : _ref23$treeRoot;
11671
11716
  var rootNodes = getAllRootNodesInTree(treeRoot);
11672
11717
  if (!rootNodes.length) {
11673
11718
  return Promise.resolve();
@@ -11697,8 +11742,8 @@
11697
11742
  }
11698
11743
  function getCssomForAllRootNodes(rootNodes, convertDataToStylesheet) {
11699
11744
  var promises = [];
11700
- rootNodes.forEach(function(_ref21, index) {
11701
- var rootNode = _ref21.rootNode, shadowId = _ref21.shadowId;
11745
+ rootNodes.forEach(function(_ref24, index) {
11746
+ var rootNode = _ref24.rootNode, shadowId = _ref24.shadowId;
11702
11747
  var sheets = getStylesheetsOfRootNode(rootNode, shadowId, convertDataToStylesheet);
11703
11748
  if (!sheets) {
11704
11749
  return Promise.all(promises);
@@ -11779,10 +11824,10 @@
11779
11824
  return true;
11780
11825
  });
11781
11826
  }
11782
- function preloadMedia(_ref22) {
11783
- var _ref22$treeRoot = _ref22.treeRoot, treeRoot = _ref22$treeRoot === void 0 ? axe._tree[0] : _ref22$treeRoot;
11784
- var mediaVirtualNodes = query_selector_all_filter_default(treeRoot, 'video, audio', function(_ref23) {
11785
- var actualNode = _ref23.actualNode;
11827
+ function preloadMedia(_ref25) {
11828
+ var _ref25$treeRoot = _ref25.treeRoot, treeRoot = _ref25$treeRoot === void 0 ? axe._tree[0] : _ref25$treeRoot;
11829
+ var mediaVirtualNodes = query_selector_all_filter_default(treeRoot, 'video, audio', function(_ref26) {
11830
+ var actualNode = _ref26.actualNode;
11786
11831
  if (actualNode.hasAttribute('src')) {
11787
11832
  return !!actualNode.getAttribute('src');
11788
11833
  }
@@ -11794,8 +11839,8 @@
11794
11839
  }
11795
11840
  return true;
11796
11841
  });
11797
- return Promise.all(mediaVirtualNodes.map(function(_ref24) {
11798
- var actualNode = _ref24.actualNode;
11842
+ return Promise.all(mediaVirtualNodes.map(function(_ref27) {
11843
+ var actualNode = _ref27.actualNode;
11799
11844
  return isMediaElementReady(actualNode);
11800
11845
  }));
11801
11846
  }
@@ -12090,8 +12135,8 @@
12090
12135
  }
12091
12136
  }
12092
12137
  function setScrollState(scrollState) {
12093
- scrollState.forEach(function(_ref26) {
12094
- var elm = _ref26.elm, top = _ref26.top, left = _ref26.left;
12138
+ scrollState.forEach(function(_ref29) {
12139
+ var elm = _ref29.elm, top = _ref29.top, left = _ref29.left;
12095
12140
  return setScroll(elm, top, left);
12096
12141
  });
12097
12142
  }
@@ -12202,9 +12247,9 @@
12202
12247
  nodeTypeToName[nodeNamesToTypes[nodeName2]] = nodeName2;
12203
12248
  });
12204
12249
  function normaliseProps(serialNode) {
12205
- var _serialNode$nodeName, _ref27, _serialNode$nodeType;
12250
+ var _serialNode$nodeName, _ref30, _serialNode$nodeType;
12206
12251
  var nodeName2 = (_serialNode$nodeName = serialNode.nodeName) !== null && _serialNode$nodeName !== void 0 ? _serialNode$nodeName : nodeTypeToName[serialNode.nodeType];
12207
- var nodeType = (_ref27 = (_serialNode$nodeType = serialNode.nodeType) !== null && _serialNode$nodeType !== void 0 ? _serialNode$nodeType : nodeNamesToTypes[serialNode.nodeName]) !== null && _ref27 !== void 0 ? _ref27 : 1;
12252
+ var nodeType = (_ref30 = (_serialNode$nodeType = serialNode.nodeType) !== null && _serialNode$nodeType !== void 0 ? _serialNode$nodeType : nodeNamesToTypes[serialNode.nodeName]) !== null && _ref30 !== void 0 ? _ref30 : 1;
12208
12253
  assert_default(typeof nodeType === 'number', 'nodeType has to be a number, got \''.concat(nodeType, '\''));
12209
12254
  assert_default(typeof nodeName2 === 'string', 'nodeName has to be a string, got \''.concat(nodeName2, '\''));
12210
12255
  nodeName2 = nodeName2.toLowerCase();
@@ -12225,8 +12270,8 @@
12225
12270
  delete props.attributes;
12226
12271
  return Object.freeze(props);
12227
12272
  }
12228
- function normaliseAttrs(_ref28) {
12229
- var _ref28$attributes = _ref28.attributes, attributes4 = _ref28$attributes === void 0 ? {} : _ref28$attributes;
12273
+ function normaliseAttrs(_ref31) {
12274
+ var _ref31$attributes = _ref31.attributes, attributes4 = _ref31$attributes === void 0 ? {} : _ref31$attributes;
12230
12275
  var attrMap = {
12231
12276
  htmlFor: 'for',
12232
12277
  className: 'class'
@@ -12368,7 +12413,7 @@
12368
12413
  }
12369
12414
  var is_unsupported_role_default = isUnsupportedRole;
12370
12415
  function isValidRole(role) {
12371
- var _ref29 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, allowAbstract = _ref29.allowAbstract, _ref29$flagUnsupporte = _ref29.flagUnsupported, flagUnsupported = _ref29$flagUnsupporte === void 0 ? false : _ref29$flagUnsupporte;
12416
+ var _ref32 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, allowAbstract = _ref32.allowAbstract, _ref32$flagUnsupporte = _ref32.flagUnsupported, flagUnsupported = _ref32$flagUnsupporte === void 0 ? false : _ref32$flagUnsupporte;
12372
12417
  var roleDefinition = standards_default.ariaRoles[role];
12373
12418
  var isRoleUnsupported = is_unsupported_role_default(role);
12374
12419
  if (!roleDefinition || flagUnsupported && isRoleUnsupported) {
@@ -12378,7 +12423,7 @@
12378
12423
  }
12379
12424
  var is_valid_role_default = isValidRole;
12380
12425
  function getExplicitRole(vNode) {
12381
- var _ref30 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, fallback = _ref30.fallback, abstracts = _ref30.abstracts, dpub = _ref30.dpub;
12426
+ var _ref33 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, fallback = _ref33.fallback, abstracts = _ref33.abstracts, dpub = _ref33.dpub;
12382
12427
  vNode = vNode instanceof abstract_virtual_node_default ? vNode : get_node_from_tree_default(vNode);
12383
12428
  if (vNode.props.nodeType !== 1) {
12384
12429
  return null;
@@ -12777,7 +12822,7 @@
12777
12822
  }
12778
12823
  var get_element_spec_default = getElementSpec;
12779
12824
  function implicitRole2(node) {
12780
- var _ref31 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, chromium = _ref31.chromium;
12825
+ var _ref34 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, chromium = _ref34.chromium;
12781
12826
  var vNode = node instanceof abstract_virtual_node_default ? node : get_node_from_tree_default(node);
12782
12827
  node = vNode.actualNode;
12783
12828
  if (!vNode) {
@@ -12827,8 +12872,8 @@
12827
12872
  }
12828
12873
  return getInheritedRole(vNode.parent, explicitRoleOptions);
12829
12874
  }
12830
- function resolveImplicitRole(vNode, _ref32) {
12831
- var chromium = _ref32.chromium, explicitRoleOptions = _objectWithoutProperties(_ref32, _excluded5);
12875
+ function resolveImplicitRole(vNode, _ref35) {
12876
+ var chromium = _ref35.chromium, explicitRoleOptions = _objectWithoutProperties(_ref35, _excluded5);
12832
12877
  var implicitRole3 = implicit_role_default(vNode, {
12833
12878
  chromium: chromium
12834
12879
  });
@@ -12848,8 +12893,8 @@
12848
12893
  return hasGlobalAria || is_focusable_default(vNode);
12849
12894
  }
12850
12895
  function resolveRole(node) {
12851
- var _ref33 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
12852
- var noImplicit = _ref33.noImplicit, roleOptions = _objectWithoutProperties(_ref33, _excluded6);
12896
+ var _ref36 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
12897
+ var noImplicit = _ref36.noImplicit, roleOptions = _objectWithoutProperties(_ref36, _excluded6);
12853
12898
  var vNode = node instanceof abstract_virtual_node_default ? node : get_node_from_tree_default(node);
12854
12899
  if (vNode.props.nodeType !== 1) {
12855
12900
  return null;
@@ -12867,8 +12912,8 @@
12867
12912
  return explicitRole2;
12868
12913
  }
12869
12914
  function getRole(node) {
12870
- var _ref34 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
12871
- var noPresentational = _ref34.noPresentational, options = _objectWithoutProperties(_ref34, _excluded7);
12915
+ var _ref37 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
12916
+ var noPresentational = _ref37.noPresentational, options = _objectWithoutProperties(_ref37, _excluded7);
12872
12917
  var role = resolveRole(node, options);
12873
12918
  if (noPresentational && [ 'presentation', 'none' ].includes(role)) {
12874
12919
  return null;
@@ -12889,7 +12934,7 @@
12889
12934
  }
12890
12935
  var title_text_default = titleText;
12891
12936
  function namedFromContents(vNode) {
12892
- var _ref35 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, strict = _ref35.strict;
12937
+ var _ref38 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, strict = _ref38.strict;
12893
12938
  vNode = vNode instanceof abstract_virtual_node_default ? vNode : get_node_from_tree_default(vNode);
12894
12939
  if (vNode.props.nodeType !== 1) {
12895
12940
  return false;
@@ -13012,12 +13057,12 @@
13012
13057
  button: ''
13013
13058
  };
13014
13059
  var nativeTextMethods = {
13015
- valueText: function valueText(_ref36) {
13016
- var actualNode = _ref36.actualNode;
13060
+ valueText: function valueText(_ref39) {
13061
+ var actualNode = _ref39.actualNode;
13017
13062
  return actualNode.value || '';
13018
13063
  },
13019
- buttonDefaultText: function buttonDefaultText(_ref37) {
13020
- var actualNode = _ref37.actualNode;
13064
+ buttonDefaultText: function buttonDefaultText(_ref40) {
13065
+ var actualNode = _ref40.actualNode;
13021
13066
  return defaultButtonValues[actualNode.type] || '';
13022
13067
  },
13023
13068
  tableCaptionText: descendantText.bind(null, 'caption'),
@@ -13037,8 +13082,8 @@
13037
13082
  function attrText(attr, vNode) {
13038
13083
  return vNode.attr(attr) || '';
13039
13084
  }
13040
- function descendantText(nodeName2, _ref38, context5) {
13041
- var actualNode = _ref38.actualNode;
13085
+ function descendantText(nodeName2, _ref41, context5) {
13086
+ var actualNode = _ref41.actualNode;
13042
13087
  nodeName2 = nodeName2.toLowerCase();
13043
13088
  var nodeNames2 = [ nodeName2, actualNode.nodeName.toLowerCase() ].join(',');
13044
13089
  var candidate = actualNode.querySelector(nodeNames2);
@@ -13151,7 +13196,7 @@
13151
13196
  }
13152
13197
  var options = query_selector_all_default(vNode, 'option');
13153
13198
  var selectedOptions = options.filter(function(option) {
13154
- return option.hasAttr('selected');
13199
+ return option.props.selected;
13155
13200
  });
13156
13201
  if (!selectedOptions.length) {
13157
13202
  selectedOptions.push(options[0]);
@@ -13232,8 +13277,8 @@
13232
13277
  }
13233
13278
  return virtualNode.props.nodeValue;
13234
13279
  }
13235
- function shouldIgnoreHidden(_ref39, context5) {
13236
- var actualNode = _ref39.actualNode;
13280
+ function shouldIgnoreHidden(_ref42, context5) {
13281
+ var actualNode = _ref42.actualNode;
13237
13282
  if (!actualNode) {
13238
13283
  return false;
13239
13284
  }
@@ -13524,7 +13569,7 @@
13524
13569
  locations: [ 'billing', 'shipping' ]
13525
13570
  };
13526
13571
  function isValidAutocomplete(autocompleteValue) {
13527
- var _ref40 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, _ref40$looseTyped = _ref40.looseTyped, looseTyped = _ref40$looseTyped === void 0 ? false : _ref40$looseTyped, _ref40$stateTerms = _ref40.stateTerms, stateTerms = _ref40$stateTerms === void 0 ? [] : _ref40$stateTerms, _ref40$locations = _ref40.locations, locations = _ref40$locations === void 0 ? [] : _ref40$locations, _ref40$qualifiers = _ref40.qualifiers, qualifiers = _ref40$qualifiers === void 0 ? [] : _ref40$qualifiers, _ref40$standaloneTerm = _ref40.standaloneTerms, standaloneTerms = _ref40$standaloneTerm === void 0 ? [] : _ref40$standaloneTerm, _ref40$qualifiedTerms = _ref40.qualifiedTerms, qualifiedTerms = _ref40$qualifiedTerms === void 0 ? [] : _ref40$qualifiedTerms;
13572
+ var _ref43 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, _ref43$looseTyped = _ref43.looseTyped, looseTyped = _ref43$looseTyped === void 0 ? false : _ref43$looseTyped, _ref43$stateTerms = _ref43.stateTerms, stateTerms = _ref43$stateTerms === void 0 ? [] : _ref43$stateTerms, _ref43$locations = _ref43.locations, locations = _ref43$locations === void 0 ? [] : _ref43$locations, _ref43$qualifiers = _ref43.qualifiers, qualifiers = _ref43$qualifiers === void 0 ? [] : _ref43$qualifiers, _ref43$standaloneTerm = _ref43.standaloneTerms, standaloneTerms = _ref43$standaloneTerm === void 0 ? [] : _ref43$standaloneTerm, _ref43$qualifiedTerms = _ref43.qualifiedTerms, qualifiedTerms = _ref43$qualifiedTerms === void 0 ? [] : _ref43$qualifiedTerms;
13528
13573
  autocompleteValue = autocompleteValue.toLowerCase().trim();
13529
13574
  stateTerms = stateTerms.concat(_autocomplete.stateTerms);
13530
13575
  if (stateTerms.includes(autocompleteValue) || autocompleteValue === '') {
@@ -15549,8 +15594,8 @@
15549
15594
  nodeName: [ 'abbr', 'address', 'canvas', 'div', 'p', 'pre', 'blockquote', 'ins', 'del', 'output', 'span', 'table', 'tbody', 'thead', 'tfoot', 'td', 'em', 'strong', 'small', 's', 'cite', 'q', 'dfn', 'abbr', 'time', 'code', 'var', 'samp', 'kbd', 'sub', 'sup', 'i', 'b', 'u', 'mark', 'ruby', 'rt', 'rp', 'bdi', 'bdo', 'br', 'wbr', 'th', 'tr' ]
15550
15595
  } ];
15551
15596
  lookupTable.evaluateRoleForElement = {
15552
- A: function A(_ref41) {
15553
- var node = _ref41.node, out = _ref41.out;
15597
+ A: function A(_ref44) {
15598
+ var node = _ref44.node, out = _ref44.out;
15554
15599
  if (node.namespaceURI === 'http://www.w3.org/2000/svg') {
15555
15600
  return true;
15556
15601
  }
@@ -15559,19 +15604,19 @@
15559
15604
  }
15560
15605
  return true;
15561
15606
  },
15562
- AREA: function AREA(_ref42) {
15563
- var node = _ref42.node;
15607
+ AREA: function AREA(_ref45) {
15608
+ var node = _ref45.node;
15564
15609
  return !node.href;
15565
15610
  },
15566
- BUTTON: function BUTTON(_ref43) {
15567
- var node = _ref43.node, role = _ref43.role, out = _ref43.out;
15611
+ BUTTON: function BUTTON(_ref46) {
15612
+ var node = _ref46.node, role = _ref46.role, out = _ref46.out;
15568
15613
  if (node.getAttribute('type') === 'menu') {
15569
15614
  return role === 'menuitem';
15570
15615
  }
15571
15616
  return out;
15572
15617
  },
15573
- IMG: function IMG(_ref44) {
15574
- var node = _ref44.node, role = _ref44.role, out = _ref44.out;
15618
+ IMG: function IMG(_ref47) {
15619
+ var node = _ref47.node, role = _ref47.role, out = _ref47.out;
15575
15620
  switch (node.alt) {
15576
15621
  case null:
15577
15622
  return out;
@@ -15583,8 +15628,8 @@
15583
15628
  return role !== 'presentation' && role !== 'none';
15584
15629
  }
15585
15630
  },
15586
- INPUT: function INPUT(_ref45) {
15587
- var node = _ref45.node, role = _ref45.role, out = _ref45.out;
15631
+ INPUT: function INPUT(_ref48) {
15632
+ var node = _ref48.node, role = _ref48.role, out = _ref48.out;
15588
15633
  switch (node.type) {
15589
15634
  case 'button':
15590
15635
  case 'image':
@@ -15614,32 +15659,32 @@
15614
15659
  return false;
15615
15660
  }
15616
15661
  },
15617
- LI: function LI(_ref46) {
15618
- var node = _ref46.node, out = _ref46.out;
15662
+ LI: function LI(_ref49) {
15663
+ var node = _ref49.node, out = _ref49.out;
15619
15664
  var hasImplicitListitemRole = axe.utils.matchesSelector(node, 'ol li, ul li');
15620
15665
  if (hasImplicitListitemRole) {
15621
15666
  return out;
15622
15667
  }
15623
15668
  return true;
15624
15669
  },
15625
- MENU: function MENU(_ref47) {
15626
- var node = _ref47.node;
15670
+ MENU: function MENU(_ref50) {
15671
+ var node = _ref50.node;
15627
15672
  if (node.getAttribute('type') === 'context') {
15628
15673
  return false;
15629
15674
  }
15630
15675
  return true;
15631
15676
  },
15632
- OPTION: function OPTION(_ref48) {
15633
- var node = _ref48.node;
15677
+ OPTION: function OPTION(_ref51) {
15678
+ var node = _ref51.node;
15634
15679
  var withinOptionList = axe.utils.matchesSelector(node, 'select > option, datalist > option, optgroup > option');
15635
15680
  return !withinOptionList;
15636
15681
  },
15637
- SELECT: function SELECT(_ref49) {
15638
- var node = _ref49.node, role = _ref49.role;
15682
+ SELECT: function SELECT(_ref52) {
15683
+ var node = _ref52.node, role = _ref52.role;
15639
15684
  return !node.multiple && node.size <= 1 && role === 'menu';
15640
15685
  },
15641
- SVG: function SVG(_ref50) {
15642
- var node = _ref50.node, out = _ref50.out;
15686
+ SVG: function SVG(_ref53) {
15687
+ var node = _ref53.node, out = _ref53.out;
15643
15688
  if (node.parentNode && node.parentNode.namespaceURI === 'http://www.w3.org/2000/svg') {
15644
15689
  return true;
15645
15690
  }
@@ -15767,10 +15812,36 @@
15767
15812
  if (Array.isArray(options[role])) {
15768
15813
  allowed = unique_array_default(options[role].concat(allowed));
15769
15814
  }
15770
- if (role && allowed) {
15815
+ var tableMap = cache_default.get('aria-allowed-attr-table');
15816
+ if (!tableMap) {
15817
+ tableMap = new WeakMap();
15818
+ cache_default.set('aria-allowed-attr-table', tableMap);
15819
+ }
15820
+ function validateRowAttrs() {
15821
+ if (virtualNode.parent && role === 'row') {
15822
+ var table5 = closest_default(virtualNode, 'table, [role="treegrid"], [role="table"], [role="grid"]');
15823
+ var tableRole = tableMap.get(table5);
15824
+ if (table5 && !tableRole) {
15825
+ tableRole = get_role_default(table5);
15826
+ tableMap.set(table5, tableRole);
15827
+ }
15828
+ if ([ 'table', 'grid' ].includes(tableRole) && role === 'row') {
15829
+ return true;
15830
+ }
15831
+ }
15832
+ }
15833
+ var ariaAttr = Array.isArray(options.validTreeRowAttrs) ? options.validTreeRowAttrs : [];
15834
+ var preChecks = {};
15835
+ ariaAttr.forEach(function(attr) {
15836
+ preChecks[attr] = validateRowAttrs;
15837
+ });
15838
+ if (allowed) {
15771
15839
  for (var _i14 = 0; _i14 < attrs.length; _i14++) {
15840
+ var _preChecks$attrName;
15772
15841
  var attrName = attrs[_i14];
15773
- if (validate_attr_default(attrName) && !allowed.includes(attrName)) {
15842
+ if (validate_attr_default(attrName) && (_preChecks$attrName = preChecks[attrName]) !== null && _preChecks$attrName !== void 0 && _preChecks$attrName.call(preChecks)) {
15843
+ invalid.push(attrName + '="' + virtualNode.attr(attrName) + '"');
15844
+ } else if (validate_attr_default(attrName) && !allowed.includes(attrName)) {
15774
15845
  invalid.push(attrName + '="' + virtualNode.attr(attrName) + '"');
15775
15846
  }
15776
15847
  }
@@ -15827,6 +15898,13 @@
15827
15898
  return void 0;
15828
15899
  }
15829
15900
  if (idref) {
15901
+ if (!is_visible_default(idref, true)) {
15902
+ this.data({
15903
+ messageKey: 'hidden',
15904
+ values: token_list_default(attr2)
15905
+ });
15906
+ return false;
15907
+ }
15830
15908
  return idref.getAttribute('role') === 'alert' || idref.getAttribute('aria-live') === 'assertive' || idref.getAttribute('aria-live') === 'polite' || token_list_default(virtualNode.attr('aria-describedby')).indexOf(attr2) > -1;
15831
15909
  }
15832
15910
  return;
@@ -16756,6 +16834,9 @@
16756
16834
  flattenColors: function flattenColors() {
16757
16835
  return flatten_colors_default;
16758
16836
  },
16837
+ flattenShadowColors: function flattenShadowColors() {
16838
+ return flatten_shadow_colors_default;
16839
+ },
16759
16840
  getBackgroundColor: function getBackgroundColor() {
16760
16841
  return get_background_color_default;
16761
16842
  },
@@ -16873,7 +16954,24 @@
16873
16954
  return null;
16874
16955
  }
16875
16956
  var filtered_rect_stack_default = filteredRectStack;
16957
+ var blendFunctions = {
16958
+ normal: function normal(Cb, Cs) {
16959
+ return Cs;
16960
+ }
16961
+ };
16962
+ function simpleAlphaCompositing(Cs, \u03b1s, Cb, \u03b1b, blendMode) {
16963
+ return Math.round(\u03b1s * (1 - \u03b1b) * Cs + \u03b1s * \u03b1b * blendFunctions[blendMode](Cb, Cs) + (1 - \u03b1s) * \u03b1b * Cb);
16964
+ }
16876
16965
  function flattenColors(fgColor, bgColor) {
16966
+ var blendMode = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'normal';
16967
+ var r = simpleAlphaCompositing(fgColor.red, fgColor.alpha, bgColor.red, bgColor.alpha, blendMode);
16968
+ var g = simpleAlphaCompositing(fgColor.green, fgColor.alpha, bgColor.green, bgColor.alpha, blendMode);
16969
+ var b = simpleAlphaCompositing(fgColor.blue, fgColor.alpha, bgColor.blue, bgColor.alpha, blendMode);
16970
+ var a = Math.max(0, Math.min(fgColor.alpha + bgColor.alpha * (1 - fgColor.alpha), 1));
16971
+ return new color_default(r, g, b, a);
16972
+ }
16973
+ var flatten_colors_default = flattenColors;
16974
+ function flattenColors2(fgColor, bgColor) {
16877
16975
  var alpha = fgColor.alpha;
16878
16976
  var r = (1 - alpha) * bgColor.red + alpha * fgColor.red;
16879
16977
  var g = (1 - alpha) * bgColor.green + alpha * fgColor.green;
@@ -16881,7 +16979,7 @@
16881
16979
  var a = fgColor.alpha + bgColor.alpha * (1 - fgColor.alpha);
16882
16980
  return new color_default(r, g, b, a);
16883
16981
  }
16884
- var flatten_colors_default = flattenColors;
16982
+ var flatten_shadow_colors_default = flattenColors2;
16885
16983
  function contentOverlapping(targetElement, bgNode) {
16886
16984
  var targetRect = targetElement.getClientRects()[0];
16887
16985
  var obscuringElements = shadow_elements_from_point_default(targetRect.left, targetRect.top);
@@ -16936,7 +17034,7 @@
16936
17034
  }
16937
17035
  var get_background_stack_default = getBackgroundStack;
16938
17036
  function getTextShadowColors(node) {
16939
- var _ref51 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, minRatio = _ref51.minRatio, maxRatio = _ref51.maxRatio;
17037
+ var _ref54 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, minRatio = _ref54.minRatio, maxRatio = _ref54.maxRatio;
16940
17038
  var style = window.getComputedStyle(node);
16941
17039
  var textShadow = style.getPropertyValue('text-shadow');
16942
17040
  if (textShadow === 'none') {
@@ -16947,19 +17045,19 @@
16947
17045
  assert_default(isNaN(fontSize) === false, 'Unable to determine font-size value '.concat(fontSizeStr));
16948
17046
  var shadowColors = [];
16949
17047
  var shadows = parseTextShadows(textShadow);
16950
- shadows.forEach(function(_ref52) {
16951
- var colorStr = _ref52.colorStr, pixels = _ref52.pixels;
17048
+ shadows.forEach(function(_ref55) {
17049
+ var colorStr = _ref55.colorStr, pixels = _ref55.pixels;
16952
17050
  colorStr = colorStr || style.getPropertyValue('color');
16953
17051
  var _pixels = _slicedToArray(pixels, 3), offsetY = _pixels[0], offsetX = _pixels[1], _pixels$ = _pixels[2], blurRadius = _pixels$ === void 0 ? 0 : _pixels$;
16954
17052
  if ((!minRatio || blurRadius >= fontSize * minRatio) && (!maxRatio || blurRadius < fontSize * maxRatio)) {
16955
- var color10 = textShadowColor({
17053
+ var color11 = textShadowColor({
16956
17054
  colorStr: colorStr,
16957
17055
  offsetY: offsetY,
16958
17056
  offsetX: offsetX,
16959
17057
  blurRadius: blurRadius,
16960
17058
  fontSize: fontSize
16961
17059
  });
16962
- shadowColors.push(color10);
17060
+ shadowColors.push(color11);
16963
17061
  }
16964
17062
  });
16965
17063
  return shadowColors;
@@ -16998,8 +17096,8 @@
16998
17096
  }
16999
17097
  return shadows;
17000
17098
  }
17001
- function textShadowColor(_ref53) {
17002
- var colorStr = _ref53.colorStr, offsetX = _ref53.offsetX, offsetY = _ref53.offsetY, blurRadius = _ref53.blurRadius, fontSize = _ref53.fontSize;
17099
+ function textShadowColor(_ref56) {
17100
+ var colorStr = _ref56.colorStr, offsetX = _ref56.offsetX, offsetY = _ref56.offsetY, blurRadius = _ref56.blurRadius, fontSize = _ref56.fontSize;
17003
17101
  if (offsetX > blurRadius || offsetY > blurRadius) {
17004
17102
  return new color_default(0, 0, 0, 0);
17005
17103
  }
@@ -17029,6 +17127,9 @@
17029
17127
  var bgColors = get_text_shadow_colors_default(elm, {
17030
17128
  minRatio: shadowOutlineEmMax
17031
17129
  });
17130
+ if (bgColors.length) {
17131
+ bgColors = [ bgColors.reduce(flatten_shadow_colors_default) ];
17132
+ }
17032
17133
  var elmStack = get_background_stack_default(elm);
17033
17134
  (elmStack || []).some(function(bgElm) {
17034
17135
  var bgElmStyle = window.getComputedStyle(bgElm);
@@ -17040,7 +17141,7 @@
17040
17141
  }
17041
17142
  if (bgColor.alpha !== 0) {
17042
17143
  bgElms.push(bgElm);
17043
- bgColors.push(bgColor);
17144
+ bgColors.unshift(bgColor);
17044
17145
  return bgColor.alpha === 1;
17045
17146
  } else {
17046
17147
  return false;
@@ -17049,8 +17150,10 @@
17049
17150
  if (bgColors === null || elmStack === null) {
17050
17151
  return null;
17051
17152
  }
17052
- bgColors.push(new color_default(255, 255, 255, 1));
17053
- var colors = bgColors.reduce(flatten_colors_default);
17153
+ bgColors.unshift(new color_default(255, 255, 255, 1));
17154
+ var colors = bgColors.reduce(function(bgColor, fgColor) {
17155
+ return flatten_colors_default(fgColor, bgColor);
17156
+ });
17054
17157
  return colors;
17055
17158
  }
17056
17159
  var get_background_color_default = getBackgroundColor;
@@ -17103,7 +17206,7 @@
17103
17206
  var textShadowColors = get_text_shadow_colors_default(node, {
17104
17207
  minRatio: 0
17105
17208
  });
17106
- return [ fgColor ].concat(_toConsumableArray(textShadowColors), [ bgColor ]).reduce(flatten_colors_default);
17209
+ return [ fgColor ].concat(_toConsumableArray(textShadowColors), [ bgColor ]).reduce(flatten_shadow_colors_default);
17107
17210
  }
17108
17211
  return flatten_colors_default(fgColor, bgColor);
17109
17212
  }
@@ -17159,7 +17262,7 @@
17159
17262
  if (shadowColors.length === 0) {
17160
17263
  contrast = get_contrast_default(bgColor, fgColor);
17161
17264
  } else if (fgColor && bgColor) {
17162
- shadowColor = [].concat(_toConsumableArray(shadowColors), [ bgColor ]).reduce(flatten_colors_default);
17265
+ shadowColor = [].concat(_toConsumableArray(shadowColors), [ bgColor ]).reduce(flatten_shadow_colors_default);
17163
17266
  var bgContrast = get_contrast_default(bgColor, shadowColor);
17164
17267
  var fgContrast = get_contrast_default(shadowColor, fgColor);
17165
17268
  contrast = Math.max(bgContrast, fgContrast);
@@ -17167,7 +17270,7 @@
17167
17270
  }
17168
17271
  var ptSize = Math.ceil(fontSize * 72) / 96;
17169
17272
  var isSmallFont = bold && ptSize < boldTextPt || !bold && ptSize < largeTextPt;
17170
- var _ref54 = isSmallFont ? contrastRatio.normal : contrastRatio.large, expected = _ref54.expected, minThreshold = _ref54.minThreshold, maxThreshold = _ref54.maxThreshold;
17273
+ var _ref57 = isSmallFont ? contrastRatio.normal : contrastRatio.large, expected = _ref57.expected, minThreshold = _ref57.minThreshold, maxThreshold = _ref57.maxThreshold;
17171
17274
  var isValid = contrast > expected;
17172
17275
  if (typeof minThreshold === 'number' && contrast < minThreshold || typeof maxThreshold === 'number' && contrast > maxThreshold) {
17173
17276
  return true;
@@ -17176,14 +17279,14 @@
17176
17279
  var missing;
17177
17280
  if (bgColor === null) {
17178
17281
  missing = incomplete_data_default.get('bgColor');
17179
- } else {
17282
+ } else if (!isValid) {
17180
17283
  missing = contrastContributor;
17181
17284
  }
17182
17285
  var equalRatio = truncatedResult === 1;
17183
17286
  var shortTextContent = visibleText.length === 1;
17184
17287
  if (equalRatio) {
17185
17288
  missing = incomplete_data_default.set('bgColor', 'equalRatio');
17186
- } else if (shortTextContent && !ignoreLength) {
17289
+ } else if (!isValid && shortTextContent && !ignoreLength) {
17187
17290
  missing = 'shortTextContent';
17188
17291
  }
17189
17292
  this.data({
@@ -17207,8 +17310,8 @@
17207
17310
  }
17208
17311
  return isValid;
17209
17312
  }
17210
- function findPseudoElement(vNode, _ref55) {
17211
- var _ref55$pseudoSizeThre = _ref55.pseudoSizeThreshold, pseudoSizeThreshold = _ref55$pseudoSizeThre === void 0 ? .25 : _ref55$pseudoSizeThre, _ref55$ignorePseudo = _ref55.ignorePseudo, ignorePseudo = _ref55$ignorePseudo === void 0 ? false : _ref55$ignorePseudo;
17313
+ function findPseudoElement(vNode, _ref58) {
17314
+ var _ref58$pseudoSizeThre = _ref58.pseudoSizeThreshold, pseudoSizeThreshold = _ref58$pseudoSizeThre === void 0 ? .25 : _ref58$pseudoSizeThre, _ref58$ignorePseudo = _ref58.ignorePseudo, ignorePseudo = _ref58$ignorePseudo === void 0 ? false : _ref58$ignorePseudo;
17212
17315
  if (ignorePseudo) {
17213
17316
  return;
17214
17317
  }
@@ -17250,7 +17353,7 @@
17250
17353
  }
17251
17354
  function parseUnit(str) {
17252
17355
  var unitRegex = /^([0-9.]+)([a-z]+)$/i;
17253
- var _ref56 = str.match(unitRegex) || [], _ref57 = _slicedToArray(_ref56, 3), _ref57$ = _ref57[1], value = _ref57$ === void 0 ? '' : _ref57$, _ref57$2 = _ref57[2], unit = _ref57$2 === void 0 ? '' : _ref57$2;
17356
+ var _ref59 = str.match(unitRegex) || [], _ref60 = _slicedToArray(_ref59, 3), _ref60$ = _ref60[1], value = _ref60$ === void 0 ? '' : _ref60$, _ref60$2 = _ref60[2], unit = _ref60$2 === void 0 ? '' : _ref60$2;
17254
17357
  return {
17255
17358
  value: parseFloat(value),
17256
17359
  unit: unit.toLowerCase()
@@ -17493,14 +17596,14 @@
17493
17596
  }
17494
17597
  function getHeadingOrder(results) {
17495
17598
  results = _toConsumableArray(results);
17496
- results.sort(function(_ref58, _ref59) {
17497
- var nodeA = _ref58.node;
17498
- var nodeB = _ref59.node;
17599
+ results.sort(function(_ref61, _ref62) {
17600
+ var nodeA = _ref61.node;
17601
+ var nodeB = _ref62.node;
17499
17602
  return nodeA.ancestry.length - nodeB.ancestry.length;
17500
17603
  });
17501
17604
  var headingOrder = results.reduce(mergeHeadingOrder, []);
17502
- return headingOrder.filter(function(_ref60) {
17503
- var level = _ref60.level;
17605
+ return headingOrder.filter(function(_ref63) {
17606
+ var level = _ref63.level;
17504
17607
  return level !== -1;
17505
17608
  });
17506
17609
  }
@@ -17551,7 +17654,7 @@
17551
17654
  var headingRole = role && role.includes('heading');
17552
17655
  var ariaHeadingLevel = vNode.attr('aria-level');
17553
17656
  var ariaLevel = parseInt(ariaHeadingLevel, 10);
17554
- var _ref61 = vNode.props.nodeName.match(/h(\d)/) || [], _ref62 = _slicedToArray(_ref61, 2), headingLevel = _ref62[1];
17657
+ var _ref64 = vNode.props.nodeName.match(/h(\d)/) || [], _ref65 = _slicedToArray(_ref64, 2), headingLevel = _ref65[1];
17555
17658
  if (!headingRole) {
17556
17659
  return -1;
17557
17660
  }
@@ -17617,8 +17720,8 @@
17617
17720
  if (results.length < 2) {
17618
17721
  return results;
17619
17722
  }
17620
- var incompleteResults = results.filter(function(_ref63) {
17621
- var result = _ref63.result;
17723
+ var incompleteResults = results.filter(function(_ref66) {
17724
+ var result = _ref66.result;
17622
17725
  return result !== void 0;
17623
17726
  });
17624
17727
  var uniqueResults = [];
@@ -17630,12 +17733,12 @@
17630
17733
  if (nameMap[name]) {
17631
17734
  return 'continue';
17632
17735
  }
17633
- var sameNameResults = incompleteResults.filter(function(_ref64, resultNum) {
17634
- var data2 = _ref64.data;
17736
+ var sameNameResults = incompleteResults.filter(function(_ref67, resultNum) {
17737
+ var data2 = _ref67.data;
17635
17738
  return data2.name === name && resultNum !== index;
17636
17739
  });
17637
- var isSameUrl = sameNameResults.every(function(_ref65) {
17638
- var data2 = _ref65.data;
17740
+ var isSameUrl = sameNameResults.every(function(_ref68) {
17741
+ var data2 = _ref68.data;
17639
17742
  return isIdenticalObject(data2.urlProps, urlProps);
17640
17743
  });
17641
17744
  if (sameNameResults.length && !isSameUrl) {
@@ -17765,7 +17868,7 @@
17765
17868
  function internalLinkPresentEvaluate(node, options, virtualNode) {
17766
17869
  var links = query_selector_all_default(virtualNode, 'a[href]');
17767
17870
  return links.some(function(vLink) {
17768
- return /^#[^/!]/.test(vLink.actualNode.getAttribute('href'));
17871
+ return /^#[^/!]/.test(vLink.attr('href'));
17769
17872
  });
17770
17873
  }
17771
17874
  var internal_link_present_evaluate_default = internalLinkPresentEvaluate;
@@ -17836,6 +17939,13 @@
17836
17939
  var currStyle = getStyleValues(node);
17837
17940
  var nextStyle = nextSibling ? getStyleValues(nextSibling) : null;
17838
17941
  var prevStyle = prevSibling ? getStyleValues(prevSibling) : null;
17942
+ var optionsPassLength = options.passLength;
17943
+ var optionsFailLength = options.failLength;
17944
+ var headingLength = node.textContent.trim().length;
17945
+ var paragraphLength = nextSibling === null || nextSibling === void 0 ? void 0 : nextSibling.textContent.trim().length;
17946
+ if (headingLength > paragraphLength * optionsPassLength) {
17947
+ return true;
17948
+ }
17839
17949
  if (!nextStyle || !isHeaderStyle(currStyle, nextStyle, margins)) {
17840
17950
  return true;
17841
17951
  }
@@ -17846,6 +17956,9 @@
17846
17956
  if (prevStyle && !isHeaderStyle(currStyle, prevStyle, margins)) {
17847
17957
  return void 0;
17848
17958
  }
17959
+ if (headingLength > paragraphLength * optionsFailLength) {
17960
+ return void 0;
17961
+ }
17849
17962
  return false;
17850
17963
  }
17851
17964
  var p_as_heading_evaluate_default = pAsHeadingEvaluate;
@@ -17881,8 +17994,8 @@
17881
17994
  } else if (node !== document.body && has_content_default(node, true)) {
17882
17995
  return [ virtualNode ];
17883
17996
  } else {
17884
- return virtualNode.children.filter(function(_ref66) {
17885
- var actualNode = _ref66.actualNode;
17997
+ return virtualNode.children.filter(function(_ref69) {
17998
+ var actualNode = _ref69.actualNode;
17886
17999
  return actualNode.nodeType === 1;
17887
18000
  }).map(function(vNode) {
17888
18001
  return findRegionlessElms(vNode, options);
@@ -18065,8 +18178,8 @@
18065
18178
  if (!virtualNode.children) {
18066
18179
  return void 0;
18067
18180
  }
18068
- var titleNode = virtualNode.children.find(function(_ref67) {
18069
- var props = _ref67.props;
18181
+ var titleNode = virtualNode.children.find(function(_ref70) {
18182
+ var props = _ref70.props;
18070
18183
  return props.nodeName === 'title';
18071
18184
  });
18072
18185
  if (!titleNode) {
@@ -18089,8 +18202,8 @@
18089
18202
  }
18090
18203
  var svg_non_empty_title_evaluate_default = svgNonEmptyTitleEvaluate;
18091
18204
  function cssOrientationLockEvaluate(node, options, virtualNode, context5) {
18092
- var _ref68 = context5 || {}, _ref68$cssom = _ref68.cssom, cssom = _ref68$cssom === void 0 ? void 0 : _ref68$cssom;
18093
- var _ref69 = options || {}, _ref69$degreeThreshol = _ref69.degreeThreshold, degreeThreshold = _ref69$degreeThreshol === void 0 ? 0 : _ref69$degreeThreshol;
18205
+ var _ref71 = context5 || {}, _ref71$cssom = _ref71.cssom, cssom = _ref71$cssom === void 0 ? void 0 : _ref71$cssom;
18206
+ var _ref72 = options || {}, _ref72$degreeThreshol = _ref72.degreeThreshold, degreeThreshold = _ref72$degreeThreshol === void 0 ? 0 : _ref72$degreeThreshol;
18094
18207
  if (!cssom || !cssom.length) {
18095
18208
  return void 0;
18096
18209
  }
@@ -18104,8 +18217,8 @@
18104
18217
  if (!orientationRules.length) {
18105
18218
  return 'continue';
18106
18219
  }
18107
- orientationRules.forEach(function(_ref70) {
18108
- var cssRules = _ref70.cssRules;
18220
+ orientationRules.forEach(function(_ref73) {
18221
+ var cssRules = _ref73.cssRules;
18109
18222
  Array.from(cssRules).forEach(function(cssRule) {
18110
18223
  var locked = getIsOrientationLocked(cssRule);
18111
18224
  if (locked && cssRule.selectorText.toUpperCase() !== 'HTML') {
@@ -18130,8 +18243,8 @@
18130
18243
  }
18131
18244
  return false;
18132
18245
  function groupCssomByDocument(cssObjectModel) {
18133
- return cssObjectModel.reduce(function(out, _ref71) {
18134
- var sheet = _ref71.sheet, root = _ref71.root, shadowId = _ref71.shadowId;
18246
+ return cssObjectModel.reduce(function(out, _ref74) {
18247
+ var sheet = _ref74.sheet, root = _ref74.root, shadowId = _ref74.shadowId;
18135
18248
  var key = shadowId ? shadowId : 'topDocument';
18136
18249
  if (!out[key]) {
18137
18250
  out[key] = {
@@ -18147,15 +18260,15 @@
18147
18260
  return out;
18148
18261
  }, {});
18149
18262
  }
18150
- function isMediaRuleWithOrientation(_ref72) {
18151
- var type = _ref72.type, cssText = _ref72.cssText;
18263
+ function isMediaRuleWithOrientation(_ref75) {
18264
+ var type = _ref75.type, cssText = _ref75.cssText;
18152
18265
  if (type !== 4) {
18153
18266
  return false;
18154
18267
  }
18155
18268
  return /orientation:\s*landscape/i.test(cssText) || /orientation:\s*portrait/i.test(cssText);
18156
18269
  }
18157
- function getIsOrientationLocked(_ref73) {
18158
- var selectorText = _ref73.selectorText, style = _ref73.style;
18270
+ function getIsOrientationLocked(_ref76) {
18271
+ var selectorText = _ref76.selectorText, style = _ref76.style;
18159
18272
  if (!selectorText || style.length <= 0) {
18160
18273
  return false;
18161
18274
  }
@@ -18202,7 +18315,7 @@
18202
18315
  }
18203
18316
  }
18204
18317
  function getAngleInDegrees(angleWithUnit) {
18205
- var _ref74 = angleWithUnit.match(/(deg|grad|rad|turn)/) || [], _ref75 = _slicedToArray(_ref74, 1), unit = _ref75[0];
18318
+ var _ref77 = angleWithUnit.match(/(deg|grad|rad|turn)/) || [], _ref78 = _slicedToArray(_ref77, 1), unit = _ref78[0];
18206
18319
  if (!unit) {
18207
18320
  return;
18208
18321
  }
@@ -18251,7 +18364,7 @@
18251
18364
  }
18252
18365
  var css_orientation_lock_evaluate_default = cssOrientationLockEvaluate;
18253
18366
  function metaViewportScaleEvaluate(node, options, virtualNode) {
18254
- var _ref76 = options || {}, _ref76$scaleMinimum = _ref76.scaleMinimum, scaleMinimum = _ref76$scaleMinimum === void 0 ? 2 : _ref76$scaleMinimum, _ref76$lowerBound = _ref76.lowerBound, lowerBound = _ref76$lowerBound === void 0 ? false : _ref76$lowerBound;
18367
+ var _ref79 = options || {}, _ref79$scaleMinimum = _ref79.scaleMinimum, scaleMinimum = _ref79$scaleMinimum === void 0 ? 2 : _ref79$scaleMinimum, _ref79$lowerBound = _ref79.lowerBound, lowerBound = _ref79$lowerBound === void 0 ? false : _ref79$lowerBound;
18255
18368
  var content = virtualNode.attr('content') || '';
18256
18369
  if (!content) {
18257
18370
  return true;
@@ -18367,8 +18480,8 @@
18367
18480
  if (!tabbableElements || !tabbableElements.length) {
18368
18481
  return true;
18369
18482
  }
18370
- var relatedNodes = tabbableElements.reduce(function(out, _ref77) {
18371
- var el = _ref77.actualNode;
18483
+ var relatedNodes = tabbableElements.reduce(function(out, _ref80) {
18484
+ var el = _ref80.actualNode;
18372
18485
  var nodeName2 = el.nodeName.toUpperCase();
18373
18486
  if (elementsThatCanBeDisabled.includes(nodeName2)) {
18374
18487
  out.push(el);
@@ -18407,8 +18520,8 @@
18407
18520
  }
18408
18521
  var focusable_element_evaluate_default = focusableElementEvaluate;
18409
18522
  function focusableModalOpenEvaluate(node, options, virtualNode) {
18410
- var tabbableElements = virtualNode.tabbableElements.map(function(_ref78) {
18411
- var actualNode = _ref78.actualNode;
18523
+ var tabbableElements = virtualNode.tabbableElements.map(function(_ref81) {
18524
+ var actualNode = _ref81.actualNode;
18412
18525
  return actualNode;
18413
18526
  });
18414
18527
  if (!tabbableElements || !tabbableElements.length) {
@@ -18440,8 +18553,8 @@
18440
18553
  if (!tabbableElements || !tabbableElements.length) {
18441
18554
  return true;
18442
18555
  }
18443
- var relatedNodes = tabbableElements.reduce(function(out, _ref79) {
18444
- var el = _ref79.actualNode;
18556
+ var relatedNodes = tabbableElements.reduce(function(out, _ref82) {
18557
+ var el = _ref82.actualNode;
18445
18558
  var nodeName2 = el.nodeName.toUpperCase();
18446
18559
  if (!elementsThatCanBeDisabled.includes(nodeName2)) {
18447
18560
  out.push(el);
@@ -18623,7 +18736,7 @@
18623
18736
  return sanitize_default(noUnicodeStr);
18624
18737
  }
18625
18738
  function labelContentNameMismatchEvaluate(node, options, virtualNode) {
18626
- var _ref80 = options || {}, pixelThreshold = _ref80.pixelThreshold, occuranceThreshold = _ref80.occuranceThreshold;
18739
+ var _ref83 = options || {}, pixelThreshold = _ref83.pixelThreshold, occuranceThreshold = _ref83.occuranceThreshold;
18627
18740
  var accText = accessible_text_default(node).toLowerCase();
18628
18741
  if (is_human_interpretable_default(accText) < 1) {
18629
18742
  return void 0;
@@ -19373,7 +19486,7 @@
19373
19486
  if (!role || [ 'none', 'presentation' ].includes(role)) {
19374
19487
  return true;
19375
19488
  }
19376
- var _ref81 = aria_roles_default[role] || {}, accessibleNameRequired = _ref81.accessibleNameRequired;
19489
+ var _ref84 = aria_roles_default[role] || {}, accessibleNameRequired = _ref84.accessibleNameRequired;
19377
19490
  if (accessibleNameRequired || is_focusable_default(virtualNode)) {
19378
19491
  return true;
19379
19492
  }
@@ -20604,8 +20717,8 @@
20604
20717
  });
20605
20718
  };
20606
20719
  }
20607
- function getHelpUrl(_ref82, ruleId, version) {
20608
- var brand = _ref82.brand, application = _ref82.application, lang = _ref82.lang;
20720
+ function getHelpUrl(_ref85, ruleId, version) {
20721
+ var brand = _ref85.brand, application = _ref85.application, lang = _ref85.lang;
20609
20722
  return constants_default.helpUrlBase + brand + '/' + (version || axe.version.substring(0, axe.version.lastIndexOf('.'))) + '/' + ruleId + '?application=' + encodeURIComponent(application) + (lang && lang !== 'en' ? '&lang=' + encodeURIComponent(lang) : '');
20610
20723
  }
20611
20724
  var audit_default = Audit;
@@ -21013,14 +21126,14 @@
21013
21126
  nodeResult.failureSummary = failure_summary_default(nodeResult);
21014
21127
  });
21015
21128
  });
21016
- return _extends({}, get_environment_data_default(), results, {
21129
+ return _extends({}, _getEnvironmentData(), results, {
21017
21130
  toolOptions: options
21018
21131
  });
21019
21132
  }
21020
21133
  var run_virtual_rule_default = runVirtualRule;
21021
- function normalizeRunParams(_ref83) {
21022
- var _ref85, _options$reporter, _axe$_audit;
21023
- var _ref84 = _slicedToArray(_ref83, 3), context5 = _ref84[0], options = _ref84[1], callback = _ref84[2];
21134
+ function normalizeRunParams(_ref86) {
21135
+ var _ref88, _options$reporter, _axe$_audit;
21136
+ var _ref87 = _slicedToArray(_ref86, 3), context5 = _ref87[0], options = _ref87[1], callback = _ref87[2];
21024
21137
  var typeErr = new TypeError('axe.run arguments are invalid');
21025
21138
  if (!isContext(context5)) {
21026
21139
  if (callback !== void 0) {
@@ -21041,7 +21154,7 @@
21041
21154
  throw typeErr;
21042
21155
  }
21043
21156
  options = clone_default(options);
21044
- options.reporter = (_ref85 = (_options$reporter = options.reporter) !== null && _options$reporter !== void 0 ? _options$reporter : (_axe$_audit = axe._audit) === null || _axe$_audit === void 0 ? void 0 : _axe$_audit.reporter) !== null && _ref85 !== void 0 ? _ref85 : 'v1';
21157
+ options.reporter = (_ref88 = (_options$reporter = options.reporter) !== null && _options$reporter !== void 0 ? _options$reporter : (_axe$_audit = axe._audit) === null || _axe$_audit === void 0 ? void 0 : _axe$_audit.reporter) !== null && _ref88 !== void 0 ? _ref88 : 'v1';
21045
21158
  return {
21046
21159
  context: context5,
21047
21160
  options: options,
@@ -21166,32 +21279,37 @@
21166
21279
  return new Promise(function(res, rej) {
21167
21280
  axe._audit.run(contextObj, options, res, rej);
21168
21281
  }).then(function(results) {
21169
- results = results.map(function(_ref86) {
21170
- var nodes = _ref86.nodes, result = _objectWithoutProperties(_ref86, _excluded8);
21282
+ results = results.map(function(_ref89) {
21283
+ var nodes = _ref89.nodes, result = _objectWithoutProperties(_ref89, _excluded8);
21171
21284
  return _extends({
21172
21285
  nodes: nodes.map(serializeNode)
21173
21286
  }, result);
21174
21287
  });
21175
- var frames = contextObj.frames.map(function(_ref87) {
21176
- var node = _ref87.node;
21288
+ var frames = contextObj.frames.map(function(_ref90) {
21289
+ var node = _ref90.node;
21177
21290
  return new dq_element_default(node, options).toJSON();
21178
21291
  });
21292
+ var environmentData;
21293
+ if (contextObj.initiator) {
21294
+ environmentData = _getEnvironmentData();
21295
+ }
21179
21296
  return {
21180
21297
  results: results,
21181
- frames: frames
21298
+ frames: frames,
21299
+ environmentData: environmentData
21182
21300
  };
21183
21301
  })['finally'](function() {
21184
21302
  axe._running = false;
21185
21303
  teardown_default();
21186
21304
  });
21187
21305
  }
21188
- function serializeNode(_ref88) {
21189
- var node = _ref88.node, nodeResult = _objectWithoutProperties(_ref88, _excluded9);
21306
+ function serializeNode(_ref91) {
21307
+ var node = _ref91.node, nodeResult = _objectWithoutProperties(_ref91, _excluded9);
21190
21308
  nodeResult.node = node.toJSON();
21191
21309
  for (var _i28 = 0, _arr2 = [ 'any', 'all', 'none' ]; _i28 < _arr2.length; _i28++) {
21192
21310
  var type = _arr2[_i28];
21193
- nodeResult[type] = nodeResult[type].map(function(_ref89) {
21194
- var relatedNodes = _ref89.relatedNodes, checkResult = _objectWithoutProperties(_ref89, _excluded10);
21311
+ nodeResult[type] = nodeResult[type].map(function(_ref92) {
21312
+ var relatedNodes = _ref92.relatedNodes, checkResult = _objectWithoutProperties(_ref92, _excluded10);
21195
21313
  return _extends({}, checkResult, {
21196
21314
  relatedNodes: relatedNodes.map(function(node2) {
21197
21315
  return node2.toJSON();
@@ -21202,17 +21320,22 @@
21202
21320
  return nodeResult;
21203
21321
  }
21204
21322
  function finishRun(partialResults) {
21205
- var _ref90, _options$reporter2, _axe$_audit2;
21323
+ var _ref94, _options$reporter2, _axe$_audit2;
21206
21324
  var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
21207
21325
  options = clone_default(options);
21326
+ var _ref93 = partialResults.find(function(r) {
21327
+ return r.environmentData;
21328
+ }) || {}, environmentData = _ref93.environmentData;
21208
21329
  axe._audit.normalizeOptions(options);
21209
- options.reporter = (_ref90 = (_options$reporter2 = options.reporter) !== null && _options$reporter2 !== void 0 ? _options$reporter2 : (_axe$_audit2 = axe._audit) === null || _axe$_audit2 === void 0 ? void 0 : _axe$_audit2.reporter) !== null && _ref90 !== void 0 ? _ref90 : 'v1';
21330
+ options.reporter = (_ref94 = (_options$reporter2 = options.reporter) !== null && _options$reporter2 !== void 0 ? _options$reporter2 : (_axe$_audit2 = axe._audit) === null || _axe$_audit2 === void 0 ? void 0 : _axe$_audit2.reporter) !== null && _ref94 !== void 0 ? _ref94 : 'v1';
21210
21331
  setFrameSpec(partialResults);
21211
21332
  var results = merge_results_default(partialResults);
21212
21333
  results = axe._audit.after(results, options);
21213
21334
  results.forEach(publish_metadata_default);
21214
21335
  results = results.map(finalize_result_default);
21215
- return createReport2(results, options);
21336
+ return createReport2(results, _extends({
21337
+ environmentData: environmentData
21338
+ }, options));
21216
21339
  }
21217
21340
  function setFrameSpec(partialResults) {
21218
21341
  var frameStack = [];
@@ -21234,8 +21357,8 @@
21234
21357
  _iterator4.f();
21235
21358
  }
21236
21359
  }
21237
- function getMergedFrameSpecs(_ref91) {
21238
- var childFrameSpecs = _ref91.frames, parentFrameSpec = _ref91.frameSpec;
21360
+ function getMergedFrameSpecs(_ref95) {
21361
+ var childFrameSpecs = _ref95.frames, parentFrameSpec = _ref95.frameSpec;
21239
21362
  if (!parentFrameSpec) {
21240
21363
  return childFrameSpecs;
21241
21364
  }
@@ -21264,14 +21387,10 @@
21264
21387
  callback = options;
21265
21388
  options = {};
21266
21389
  }
21267
- var out = process_aggregate_default(results, options);
21268
- callback(_extends({}, get_environment_data_default(), {
21269
- toolOptions: options,
21270
- violations: out.violations,
21271
- passes: out.passes,
21272
- incomplete: out.incomplete,
21273
- inapplicable: out.inapplicable
21274
- }));
21390
+ var _options2 = options, environmentData = _options2.environmentData, toolOptions = _objectWithoutProperties(_options2, _excluded11);
21391
+ callback(_extends({}, _getEnvironmentData(environmentData), {
21392
+ toolOptions: toolOptions
21393
+ }, process_aggregate_default(results, options)));
21275
21394
  };
21276
21395
  var na_default = naReporter;
21277
21396
  var noPassesReporter = function noPassesReporter(results, options, callback) {
@@ -21279,11 +21398,12 @@
21279
21398
  callback = options;
21280
21399
  options = {};
21281
21400
  }
21401
+ var _options3 = options, environmentData = _options3.environmentData, toolOptions = _objectWithoutProperties(_options3, _excluded12);
21282
21402
  options.resultTypes = [ 'violations' ];
21283
- var out = process_aggregate_default(results, options);
21284
- callback(_extends({}, get_environment_data_default(), {
21285
- toolOptions: options,
21286
- violations: out.violations
21403
+ var _process_aggregate_de = process_aggregate_default(results, options), violations = _process_aggregate_de.violations;
21404
+ callback(_extends({}, _getEnvironmentData(environmentData), {
21405
+ toolOptions: toolOptions,
21406
+ violations: violations
21287
21407
  }));
21288
21408
  };
21289
21409
  var no_passes_default = noPassesReporter;
@@ -21301,9 +21421,9 @@
21301
21421
  for (var _i29 = 0, _types = types; _i29 < _types.length; _i29++) {
21302
21422
  var type = _types[_i29];
21303
21423
  if (transformedResult[type] && Array.isArray(transformedResult[type])) {
21304
- transformedResult[type] = transformedResult[type].map(function(_ref92) {
21424
+ transformedResult[type] = transformedResult[type].map(function(_ref96) {
21305
21425
  var _node;
21306
- var node = _ref92.node, typeResult = _objectWithoutProperties(_ref92, _excluded11);
21426
+ var node = _ref96.node, typeResult = _objectWithoutProperties(_ref96, _excluded13);
21307
21427
  node = typeof ((_node = node) === null || _node === void 0 ? void 0 : _node.toJSON) === 'function' ? node.toJSON() : node;
21308
21428
  return _extends({
21309
21429
  node: node
@@ -21321,14 +21441,14 @@
21321
21441
  callback = options;
21322
21442
  options = {};
21323
21443
  }
21324
- function rawCallback(raw3) {
21325
- var env = get_environment_data_default();
21444
+ var _options4 = options, environmentData = _options4.environmentData, toolOptions = _objectWithoutProperties(_options4, _excluded14);
21445
+ raw_default(results, toolOptions, function(raw3) {
21446
+ var env = _getEnvironmentData(environmentData);
21326
21447
  callback({
21327
21448
  raw: raw3,
21328
21449
  env: env
21329
21450
  });
21330
- }
21331
- raw_default(results, options, rawCallback);
21451
+ });
21332
21452
  };
21333
21453
  var raw_env_default = rawEnvReporter;
21334
21454
  var v1Reporter = function v1Reporter(results, options, callback) {
@@ -21336,6 +21456,7 @@
21336
21456
  callback = options;
21337
21457
  options = {};
21338
21458
  }
21459
+ var _options5 = options, environmentData = _options5.environmentData, toolOptions = _objectWithoutProperties(_options5, _excluded15);
21339
21460
  var out = process_aggregate_default(results, options);
21340
21461
  var addFailureSummaries = function addFailureSummaries(result) {
21341
21462
  result.nodes.forEach(function(nodeResult) {
@@ -21344,13 +21465,9 @@
21344
21465
  };
21345
21466
  out.incomplete.forEach(addFailureSummaries);
21346
21467
  out.violations.forEach(addFailureSummaries);
21347
- callback(_extends({}, get_environment_data_default(), {
21348
- toolOptions: options,
21349
- violations: out.violations,
21350
- passes: out.passes,
21351
- incomplete: out.incomplete,
21352
- inapplicable: out.inapplicable
21353
- }));
21468
+ callback(_extends({}, _getEnvironmentData(environmentData), {
21469
+ toolOptions: toolOptions
21470
+ }, out));
21354
21471
  };
21355
21472
  var v1_default = v1Reporter;
21356
21473
  var v2Reporter = function v2Reporter(results, options, callback) {
@@ -21358,14 +21475,11 @@
21358
21475
  callback = options;
21359
21476
  options = {};
21360
21477
  }
21478
+ var _options6 = options, environmentData = _options6.environmentData, toolOptions = _objectWithoutProperties(_options6, _excluded16);
21361
21479
  var out = process_aggregate_default(results, options);
21362
- callback(_extends({}, get_environment_data_default(), {
21363
- toolOptions: options,
21364
- violations: out.violations,
21365
- passes: out.passes,
21366
- incomplete: out.incomplete,
21367
- inapplicable: out.inapplicable
21368
- }));
21480
+ callback(_extends({}, _getEnvironmentData(environmentData), {
21481
+ toolOptions: toolOptions
21482
+ }, out));
21369
21483
  };
21370
21484
  var v2_default = v2Reporter;
21371
21485
  axe.constants = constants_default;
@@ -21384,6 +21498,9 @@
21384
21498
  Rule: rule_default,
21385
21499
  metadataFunctionMap: metadata_function_map_default
21386
21500
  };
21501
+ axe._thisWillBeDeletedDoNotUse['public'] = {
21502
+ reporters: reporters
21503
+ };
21387
21504
  axe.imports = imports_exports;
21388
21505
  axe.cleanup = cleanup_default;
21389
21506
  axe.configure = configure_default;
@@ -21843,7 +21960,8 @@
21843
21960
  pass: 'aria-errormessage exists and references elements visible to screen readers that use a supported aria-errormessage technique',
21844
21961
  fail: {
21845
21962
  singular: 'aria-errormessage value `${data.values}` must use a technique to announce the message (e.g., aria-live, aria-describedby, role=alert, etc.)',
21846
- plural: 'aria-errormessage values `${data.values}` must use a technique to announce the message (e.g., aria-live, aria-describedby, role=alert, etc.)'
21963
+ plural: 'aria-errormessage values `${data.values}` must use a technique to announce the message (e.g., aria-live, aria-describedby, role=alert, etc.)',
21964
+ hidden: 'aria-errormessage value `${data.values}` cannot reference a hidden element'
21847
21965
  },
21848
21966
  incomplete: {
21849
21967
  singular: 'ensure aria-errormessage value `${data.values}` references an existing element',
@@ -22411,7 +22529,8 @@
22411
22529
  impact: 'serious',
22412
22530
  messages: {
22413
22531
  pass: '<p> elements are not styled as headings',
22414
- fail: 'Heading elements should be used instead of styled p elements'
22532
+ fail: 'Heading elements should be used instead of styled <p> elements',
22533
+ incomplete: 'Unable to determine if <p> elements are styled as headings'
22415
22534
  }
22416
22535
  },
22417
22536
  region: {
@@ -22738,7 +22857,12 @@
22738
22857
  tags: [ 'cat.aria', 'wcag2a', 'wcag412' ],
22739
22858
  actIds: [ '5c01ea' ],
22740
22859
  all: [],
22741
- any: [ 'aria-allowed-attr' ],
22860
+ any: [ {
22861
+ options: {
22862
+ validTreeRowAttrs: [ 'aria-posinset', 'aria-setsize', 'aria-expanded', 'aria-level' ]
22863
+ },
22864
+ id: 'aria-allowed-attr'
22865
+ } ],
22742
22866
  none: [ 'aria-unsupported-attr', {
22743
22867
  options: {
22744
22868
  elementsAllowedAriaLabel: [ 'applet', 'input' ]
@@ -23615,7 +23739,9 @@
23615
23739
  size: 1.15
23616
23740
  }, {
23617
23741
  size: 1.4
23618
- } ]
23742
+ } ],
23743
+ passLength: 1,
23744
+ failLength: .5
23619
23745
  },
23620
23746
  id: 'p-as-heading'
23621
23747
  } ],
@@ -23804,7 +23930,10 @@
23804
23930
  evaluate: 'abstractrole-evaluate'
23805
23931
  }, {
23806
23932
  id: 'aria-allowed-attr',
23807
- evaluate: 'aria-allowed-attr-evaluate'
23933
+ evaluate: 'aria-allowed-attr-evaluate',
23934
+ options: {
23935
+ validTreeRowAttrs: [ 'aria-posinset', 'aria-setsize', 'aria-expanded', 'aria-level' ]
23936
+ }
23808
23937
  }, {
23809
23938
  id: 'aria-allowed-role',
23810
23939
  evaluate: 'aria-allowed-role-evaluate',
@@ -24135,7 +24264,9 @@
24135
24264
  size: 1.15
24136
24265
  }, {
24137
24266
  size: 1.4
24138
- } ]
24267
+ } ],
24268
+ passLength: 1,
24269
+ failLength: .5
24139
24270
  }
24140
24271
  }, {
24141
24272
  id: 'region',