@y14e/roving-tabindex 3.0.2 → 3.0.3
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/README.md +4 -4
- package/dist/index.cjs +2 -2
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +2 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -10,14 +10,14 @@ npm i @y14e/roving-tabindex
|
|
|
10
10
|
|
|
11
11
|
```ts
|
|
12
12
|
// npm
|
|
13
|
-
import { createRovingTabIndex } from '@y14e/roving-tabindex@3.0.
|
|
13
|
+
import { createRovingTabIndex } from '@y14e/roving-tabindex@3.0.3';
|
|
14
14
|
|
|
15
15
|
// CDNs
|
|
16
|
-
import { createRovingTabIndex } from 'https://esm.sh/@y14e/roving-tabindex@3.0.
|
|
16
|
+
import { createRovingTabIndex } from 'https://esm.sh/@y14e/roving-tabindex@3.0.3';
|
|
17
17
|
// or
|
|
18
|
-
import { createRovingTabIndex } from 'https://cdn.jsdelivr.net/npm/@y14e/roving-tabindex@3.0.
|
|
18
|
+
import { createRovingTabIndex } from 'https://cdn.jsdelivr.net/npm/@y14e/roving-tabindex@3.0.3/+esm';
|
|
19
19
|
// or
|
|
20
|
-
import { createRovingTabIndex } from 'https://esm.unpkg.com/@y14e/roving-tabindex@3.0.
|
|
20
|
+
import { createRovingTabIndex } from 'https://esm.unpkg.com/@y14e/roving-tabindex@3.0.3';
|
|
21
21
|
```
|
|
22
22
|
|
|
23
23
|
## 📦 APIs
|
package/dist/index.cjs
CHANGED
|
@@ -471,11 +471,11 @@ var RovingTabIndex = class {
|
|
|
471
471
|
if (!typeahead) {
|
|
472
472
|
continue;
|
|
473
473
|
}
|
|
474
|
+
const char = focusable.textContent?.trim()?.at(0)?.toUpperCase();
|
|
474
475
|
const value = focusable.ariaKeyShortcuts?.trim();
|
|
475
476
|
const keys = new Set(
|
|
476
477
|
value ? value.split(/\s+/).filter((key) => /^\S$/i.test(key)).map((key) => key.toUpperCase()) : []
|
|
477
478
|
);
|
|
478
|
-
const char = focusable.textContent?.trim()?.at(0)?.toUpperCase();
|
|
479
479
|
if (char) {
|
|
480
480
|
keys.add(char);
|
|
481
481
|
saveAttributes([focusable], ["aria-keyshortcuts"]);
|
|
@@ -529,7 +529,7 @@ function getActiveElement() {
|
|
|
529
529
|
* Lightweight roving tabindex utility with fully focus management.
|
|
530
530
|
* Designed for accessible menus, tabs, toolbars, and composite widgets.
|
|
531
531
|
*
|
|
532
|
-
* @version 3.0.
|
|
532
|
+
* @version 3.0.3
|
|
533
533
|
* @author Yusuke Kamiyamane
|
|
534
534
|
* @license MIT
|
|
535
535
|
* @copyright Copyright (c) Yusuke Kamiyamane
|
package/dist/index.d.cts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Lightweight roving tabindex utility with fully focus management.
|
|
4
4
|
* Designed for accessible menus, tabs, toolbars, and composite widgets.
|
|
5
5
|
*
|
|
6
|
-
* @version 3.0.
|
|
6
|
+
* @version 3.0.3
|
|
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
|
* Lightweight roving tabindex utility with fully focus management.
|
|
4
4
|
* Designed for accessible menus, tabs, toolbars, and composite widgets.
|
|
5
5
|
*
|
|
6
|
-
* @version 3.0.
|
|
6
|
+
* @version 3.0.3
|
|
7
7
|
* @author Yusuke Kamiyamane
|
|
8
8
|
* @license MIT
|
|
9
9
|
* @copyright Copyright (c) Yusuke Kamiyamane
|
package/dist/index.js
CHANGED
|
@@ -469,11 +469,11 @@ var RovingTabIndex = class {
|
|
|
469
469
|
if (!typeahead) {
|
|
470
470
|
continue;
|
|
471
471
|
}
|
|
472
|
+
const char = focusable.textContent?.trim()?.at(0)?.toUpperCase();
|
|
472
473
|
const value = focusable.ariaKeyShortcuts?.trim();
|
|
473
474
|
const keys = new Set(
|
|
474
475
|
value ? value.split(/\s+/).filter((key) => /^\S$/i.test(key)).map((key) => key.toUpperCase()) : []
|
|
475
476
|
);
|
|
476
|
-
const char = focusable.textContent?.trim()?.at(0)?.toUpperCase();
|
|
477
477
|
if (char) {
|
|
478
478
|
keys.add(char);
|
|
479
479
|
saveAttributes([focusable], ["aria-keyshortcuts"]);
|
|
@@ -527,7 +527,7 @@ function getActiveElement() {
|
|
|
527
527
|
* Lightweight roving tabindex utility with fully focus management.
|
|
528
528
|
* Designed for accessible menus, tabs, toolbars, and composite widgets.
|
|
529
529
|
*
|
|
530
|
-
* @version 3.0.
|
|
530
|
+
* @version 3.0.3
|
|
531
531
|
* @author Yusuke Kamiyamane
|
|
532
532
|
* @license MIT
|
|
533
533
|
* @copyright Copyright (c) Yusuke Kamiyamane
|