aria-ease 1.1.8 → 1.1.9
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/package.json
CHANGED
|
@@ -6,10 +6,8 @@
|
|
|
6
6
|
|
|
7
7
|
import { HTMLElement, NodeListOfHTMLElement } from '../../Types'
|
|
8
8
|
|
|
9
|
-
|
|
10
9
|
let eventListenersAdded: Set<HTMLElement> = new Set();
|
|
11
10
|
|
|
12
|
-
|
|
13
11
|
export function makeMenuAccessible(menuId: string, menuItemClass: string): void {
|
|
14
12
|
const menuDiv: HTMLElement = document.querySelector(`#${menuId}`) as HTMLElement
|
|
15
13
|
const menuItems: NodeListOfHTMLElement = menuDiv.querySelectorAll(`.${menuItemClass}`)
|
|
@@ -26,7 +24,6 @@ export function makeMenuAccessible(menuId: string, menuItemClass: string): void
|
|
|
26
24
|
})
|
|
27
25
|
|
|
28
26
|
function handleKeyPress(event: KeyboardEvent, menuItems: NodeListOfHTMLElement, menuItemIndex: number): void {
|
|
29
|
-
event.preventDefault()
|
|
30
27
|
switch(event.key) {
|
|
31
28
|
case 'ArrowUp':
|
|
32
29
|
case 'ArrowLeft':
|
|
@@ -6,10 +6,8 @@
|
|
|
6
6
|
|
|
7
7
|
import { HTMLElement, NodeListOfHTMLElement } from "../../Types"
|
|
8
8
|
|
|
9
|
-
|
|
10
9
|
let eventListenersAdded: Set<HTMLElement> = new Set();
|
|
11
10
|
|
|
12
|
-
|
|
13
11
|
export function makeTabAccessible(tabId: string, tabItemClass: string): void {
|
|
14
12
|
const tabDiv: HTMLElement = document.querySelector(`#${tabId}`) as HTMLElement
|
|
15
13
|
const tabItems: NodeListOfHTMLElement = tabDiv.querySelectorAll(`.${tabItemClass}`)
|
|
@@ -22,7 +20,6 @@ export function makeTabAccessible(tabId: string, tabItemClass: string): void {
|
|
|
22
20
|
});
|
|
23
21
|
|
|
24
22
|
function handleKeyPress(event: KeyboardEvent, tabItems: NodeListOfHTMLElement, tabItemIndex: number): void {
|
|
25
|
-
event.preventDefault()
|
|
26
23
|
switch(event.key) {
|
|
27
24
|
case 'ArrowUp':
|
|
28
25
|
case 'ArrowLeft':
|