power-focusable 4.1.7 → 4.1.8
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/index.cjs +16 -8
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +16 -8
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -46,15 +46,19 @@ function getFocusables(container = document.body, options = {}) {
|
|
|
46
46
|
}
|
|
47
47
|
let { composed = false, filter, include } = options;
|
|
48
48
|
if (typeof composed !== "boolean") {
|
|
49
|
-
console.warn("Invalid composed. Fallback: false.");
|
|
49
|
+
console.warn("Invalid composed option. Fallback: false.");
|
|
50
50
|
composed = false;
|
|
51
51
|
}
|
|
52
52
|
if (typeof filter !== "undefined" && typeof filter !== "function") {
|
|
53
|
-
console.warn(
|
|
53
|
+
console.warn(
|
|
54
|
+
"Invalid filter function. Fallback: no filter function (undefined)."
|
|
55
|
+
);
|
|
54
56
|
filter = void 0;
|
|
55
57
|
}
|
|
56
58
|
if (typeof include !== "undefined" && typeof include !== "function") {
|
|
57
|
-
console.warn(
|
|
59
|
+
console.warn(
|
|
60
|
+
"Invalid include function. Fallback: no include function (undefined)."
|
|
61
|
+
);
|
|
58
62
|
include = void 0;
|
|
59
63
|
}
|
|
60
64
|
const elements = [];
|
|
@@ -181,19 +185,23 @@ function getRelativeFocusable(container, offset, options) {
|
|
|
181
185
|
return null;
|
|
182
186
|
}
|
|
183
187
|
if (typeof composed !== "boolean") {
|
|
184
|
-
console.warn("Invalid composed. Fallback: false.");
|
|
188
|
+
console.warn("Invalid composed option. Fallback: false.");
|
|
185
189
|
composed = false;
|
|
186
190
|
}
|
|
187
191
|
if (typeof filter !== "undefined" && typeof filter !== "function") {
|
|
188
|
-
console.warn(
|
|
192
|
+
console.warn(
|
|
193
|
+
"Invalid filter function. Fallback: no filter function (undefined)."
|
|
194
|
+
);
|
|
189
195
|
filter = void 0;
|
|
190
196
|
}
|
|
191
197
|
if (typeof include !== "undefined" && typeof include !== "function") {
|
|
192
|
-
console.warn(
|
|
198
|
+
console.warn(
|
|
199
|
+
"Invalid include function. Fallback: no include function (undefined)."
|
|
200
|
+
);
|
|
193
201
|
include = void 0;
|
|
194
202
|
}
|
|
195
203
|
if (typeof wrap !== "boolean") {
|
|
196
|
-
console.warn("Invalid wrap. Fallback: false.");
|
|
204
|
+
console.warn("Invalid wrap option. Fallback: false.");
|
|
197
205
|
wrap = false;
|
|
198
206
|
}
|
|
199
207
|
const focusables = getFocusables(container, { composed, filter, include });
|
|
@@ -427,7 +435,7 @@ function isUngroupedRadio(element) {
|
|
|
427
435
|
* High-precision focus management utility with full composed tree support.
|
|
428
436
|
* Handles complex focus rules including tabindex ordering, radio groups, inert.
|
|
429
437
|
*
|
|
430
|
-
* @version 4.1.
|
|
438
|
+
* @version 4.1.8
|
|
431
439
|
* @author Yusuke Kamiyamane
|
|
432
440
|
* @license MIT
|
|
433
441
|
* @copyright Copyright (c) Yusuke Kamiyamane
|
package/dist/index.d.cts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* High-precision focus management utility with full composed tree support.
|
|
4
4
|
* Handles complex focus rules including tabindex ordering, radio groups, inert.
|
|
5
5
|
*
|
|
6
|
-
* @version 4.1.
|
|
6
|
+
* @version 4.1.8
|
|
7
7
|
* @author Yusuke Kamiyamane
|
|
8
8
|
* @license MIT
|
|
9
9
|
* @copyright Copyright (c) Yusuke Kamiyamane
|
package/dist/index.d.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* High-precision focus management utility with full composed tree support.
|
|
4
4
|
* Handles complex focus rules including tabindex ordering, radio groups, inert.
|
|
5
5
|
*
|
|
6
|
-
* @version 4.1.
|
|
6
|
+
* @version 4.1.8
|
|
7
7
|
* @author Yusuke Kamiyamane
|
|
8
8
|
* @license MIT
|
|
9
9
|
* @copyright Copyright (c) Yusuke Kamiyamane
|
package/dist/index.js
CHANGED
|
@@ -44,15 +44,19 @@ function getFocusables(container = document.body, options = {}) {
|
|
|
44
44
|
}
|
|
45
45
|
let { composed = false, filter, include } = options;
|
|
46
46
|
if (typeof composed !== "boolean") {
|
|
47
|
-
console.warn("Invalid composed. Fallback: false.");
|
|
47
|
+
console.warn("Invalid composed option. Fallback: false.");
|
|
48
48
|
composed = false;
|
|
49
49
|
}
|
|
50
50
|
if (typeof filter !== "undefined" && typeof filter !== "function") {
|
|
51
|
-
console.warn(
|
|
51
|
+
console.warn(
|
|
52
|
+
"Invalid filter function. Fallback: no filter function (undefined)."
|
|
53
|
+
);
|
|
52
54
|
filter = void 0;
|
|
53
55
|
}
|
|
54
56
|
if (typeof include !== "undefined" && typeof include !== "function") {
|
|
55
|
-
console.warn(
|
|
57
|
+
console.warn(
|
|
58
|
+
"Invalid include function. Fallback: no include function (undefined)."
|
|
59
|
+
);
|
|
56
60
|
include = void 0;
|
|
57
61
|
}
|
|
58
62
|
const elements = [];
|
|
@@ -179,19 +183,23 @@ function getRelativeFocusable(container, offset, options) {
|
|
|
179
183
|
return null;
|
|
180
184
|
}
|
|
181
185
|
if (typeof composed !== "boolean") {
|
|
182
|
-
console.warn("Invalid composed. Fallback: false.");
|
|
186
|
+
console.warn("Invalid composed option. Fallback: false.");
|
|
183
187
|
composed = false;
|
|
184
188
|
}
|
|
185
189
|
if (typeof filter !== "undefined" && typeof filter !== "function") {
|
|
186
|
-
console.warn(
|
|
190
|
+
console.warn(
|
|
191
|
+
"Invalid filter function. Fallback: no filter function (undefined)."
|
|
192
|
+
);
|
|
187
193
|
filter = void 0;
|
|
188
194
|
}
|
|
189
195
|
if (typeof include !== "undefined" && typeof include !== "function") {
|
|
190
|
-
console.warn(
|
|
196
|
+
console.warn(
|
|
197
|
+
"Invalid include function. Fallback: no include function (undefined)."
|
|
198
|
+
);
|
|
191
199
|
include = void 0;
|
|
192
200
|
}
|
|
193
201
|
if (typeof wrap !== "boolean") {
|
|
194
|
-
console.warn("Invalid wrap. Fallback: false.");
|
|
202
|
+
console.warn("Invalid wrap option. Fallback: false.");
|
|
195
203
|
wrap = false;
|
|
196
204
|
}
|
|
197
205
|
const focusables = getFocusables(container, { composed, filter, include });
|
|
@@ -425,7 +433,7 @@ function isUngroupedRadio(element) {
|
|
|
425
433
|
* High-precision focus management utility with full composed tree support.
|
|
426
434
|
* Handles complex focus rules including tabindex ordering, radio groups, inert.
|
|
427
435
|
*
|
|
428
|
-
* @version 4.1.
|
|
436
|
+
* @version 4.1.8
|
|
429
437
|
* @author Yusuke Kamiyamane
|
|
430
438
|
* @license MIT
|
|
431
439
|
* @copyright Copyright (c) Yusuke Kamiyamane
|