@primer/behaviors 0.0.0-20251214172224 → 0.0.0-20251214172756
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/dist/cjs/focus-trap.js
CHANGED
|
@@ -50,7 +50,8 @@ function focusTrap(container, initialFocus, abortSignal) {
|
|
|
50
50
|
sentinelStart.className = 'sentinel';
|
|
51
51
|
sentinelStart.tabIndex = 0;
|
|
52
52
|
sentinelStart.setAttribute('aria-hidden', 'true');
|
|
53
|
-
sentinelStart.style.cssText =
|
|
53
|
+
sentinelStart.style.cssText =
|
|
54
|
+
'position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0';
|
|
54
55
|
sentinelStart.onfocus = () => {
|
|
55
56
|
const lastFocusableChild = iterateFocusableElements.getFocusableChild(container, true);
|
|
56
57
|
lastFocusableChild === null || lastFocusableChild === void 0 ? void 0 : lastFocusableChild.focus();
|
|
@@ -59,7 +60,8 @@ function focusTrap(container, initialFocus, abortSignal) {
|
|
|
59
60
|
sentinelEnd.className = 'sentinel';
|
|
60
61
|
sentinelEnd.tabIndex = 0;
|
|
61
62
|
sentinelEnd.setAttribute('aria-hidden', 'true');
|
|
62
|
-
sentinelEnd.style.cssText =
|
|
63
|
+
sentinelEnd.style.cssText =
|
|
64
|
+
'position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0';
|
|
63
65
|
sentinelEnd.onfocus = () => {
|
|
64
66
|
const firstFocusableChild = iterateFocusableElements.getFocusableChild(container);
|
|
65
67
|
firstFocusableChild === null || firstFocusableChild === void 0 ? void 0 : firstFocusableChild.focus();
|
package/dist/cjs/focus-zone.js
CHANGED
|
@@ -347,7 +347,7 @@ function focusZone(container, settings) {
|
|
|
347
347
|
if (focusableElement) {
|
|
348
348
|
updateFocusedElement(focusableElement);
|
|
349
349
|
}
|
|
350
|
-
}, { signal, capture: true
|
|
350
|
+
}, { signal, capture: true });
|
|
351
351
|
}
|
|
352
352
|
activeDescendantControl.addEventListener('focusin', () => {
|
|
353
353
|
if (!currentFocusedElement) {
|
package/dist/esm/focus-trap.mjs
CHANGED
|
@@ -48,7 +48,8 @@ function focusTrap(container, initialFocus, abortSignal) {
|
|
|
48
48
|
sentinelStart.className = 'sentinel';
|
|
49
49
|
sentinelStart.tabIndex = 0;
|
|
50
50
|
sentinelStart.setAttribute('aria-hidden', 'true');
|
|
51
|
-
sentinelStart.style.cssText =
|
|
51
|
+
sentinelStart.style.cssText =
|
|
52
|
+
'position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0';
|
|
52
53
|
sentinelStart.onfocus = () => {
|
|
53
54
|
const lastFocusableChild = getFocusableChild(container, true);
|
|
54
55
|
lastFocusableChild === null || lastFocusableChild === void 0 ? void 0 : lastFocusableChild.focus();
|
|
@@ -57,7 +58,8 @@ function focusTrap(container, initialFocus, abortSignal) {
|
|
|
57
58
|
sentinelEnd.className = 'sentinel';
|
|
58
59
|
sentinelEnd.tabIndex = 0;
|
|
59
60
|
sentinelEnd.setAttribute('aria-hidden', 'true');
|
|
60
|
-
sentinelEnd.style.cssText =
|
|
61
|
+
sentinelEnd.style.cssText =
|
|
62
|
+
'position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0';
|
|
61
63
|
sentinelEnd.onfocus = () => {
|
|
62
64
|
const firstFocusableChild = getFocusableChild(container);
|
|
63
65
|
firstFocusableChild === null || firstFocusableChild === void 0 ? void 0 : firstFocusableChild.focus();
|
package/dist/esm/focus-zone.mjs
CHANGED
|
@@ -345,7 +345,7 @@ function focusZone(container, settings) {
|
|
|
345
345
|
if (focusableElement) {
|
|
346
346
|
updateFocusedElement(focusableElement);
|
|
347
347
|
}
|
|
348
|
-
}, { signal, capture: true
|
|
348
|
+
}, { signal, capture: true });
|
|
349
349
|
}
|
|
350
350
|
activeDescendantControl.addEventListener('focusin', () => {
|
|
351
351
|
if (!currentFocusedElement) {
|