axe-core 4.6.1 → 4.6.2-canary.4c3a00c

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,5 +1,5 @@
1
- /*! axe v4.6.1
2
- * Copyright (c) 2022 Deque Systems, Inc.
1
+ /*! axe v4.6.2-canary.4c3a00c
2
+ * Copyright (c) 2023 Deque Systems, Inc.
3
3
  *
4
4
  * Your use of this Source Code Form is subject to the terms of the Mozilla Public
5
5
  * License, v. 2.0. If a copy of the MPL was not distributed with this
@@ -22,7 +22,7 @@
22
22
  }, _typeof(obj);
23
23
  }
24
24
  var axe = axe || {};
25
- axe.version = '4.6.1';
25
+ axe.version = '4.6.2-canary.4c3a00c';
26
26
  if (typeof define === 'function' && define.amd) {
27
27
  define('axe-core', [], function() {
28
28
  return axe;
@@ -7553,7 +7553,11 @@
7553
7553
  var node = parentVNode ? treeWalker.nextNode() : treeWalker.currentNode;
7554
7554
  while (node) {
7555
7555
  var _vNode = get_node_from_tree_default(node);
7556
- if (node.parentElement) {
7556
+ if (_vNode && _vNode.parent) {
7557
+ parentVNode = _vNode.parent;
7558
+ } else if (node.assignedSlot) {
7559
+ parentVNode = get_node_from_tree_default(node.assignedSlot);
7560
+ } else if (node.parentElement) {
7557
7561
  parentVNode = get_node_from_tree_default(node.parentElement);
7558
7562
  } else if (node.parentNode && get_node_from_tree_default(node.parentNode)) {
7559
7563
  parentVNode = get_node_from_tree_default(node.parentNode);
@@ -18127,16 +18131,15 @@
18127
18131
  function fullyEncompasses(node, rects) {
18128
18132
  rects = Array.isArray(rects) ? rects : [ rects ];
18129
18133
  var nodeRect = node.getBoundingClientRect();
18134
+ var right = nodeRect.right, bottom = nodeRect.bottom;
18130
18135
  var style = window.getComputedStyle(node);
18131
18136
  var overflow = style.getPropertyValue('overflow');
18132
18137
  if ([ 'scroll', 'auto' ].includes(overflow) || node instanceof window.HTMLHtmlElement) {
18133
- nodeRect.width = node.scrollWidth;
18134
- nodeRect.height = node.scrollHeight;
18135
- nodeRect.right = nodeRect.left + nodeRect.width;
18136
- nodeRect.bottom = nodeRect.top + nodeRect.height;
18138
+ right = nodeRect.left + node.scrollWidth;
18139
+ bottom = nodeRect.top + node.scrollHeight;
18137
18140
  }
18138
18141
  return rects.every(function(rect) {
18139
- return rect.top >= nodeRect.top && rect.bottom <= nodeRect.bottom && rect.left >= nodeRect.left && rect.right <= nodeRect.right;
18142
+ return rect.top >= nodeRect.top && rect.bottom <= bottom && rect.left >= nodeRect.left && rect.right <= right;
18140
18143
  });
18141
18144
  }
18142
18145
  function normalizeBlendMode(blendmode) {