Skip to content

Commit 6f99700

Browse files
author
LiJun
committed
fix: type warning and wrong porperty
1 parent 90ee087 commit 6f99700

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/hooks/useAccessibility.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ export default function useAccessibility<T extends HTMLElement>(
266266
// Arrow prevent default to avoid page scroll, not apply for input and textarea
267267
if (
268268
(ArrowKeys.includes(which) || [HOME, END].includes(which)) &&
269-
!['INPUT', 'TEXTAREA'].includes(e.target.nodeType)
269+
!['INPUT', 'TEXTAREA'].includes((e.target as Element).nodeName)
270270
) {
271271
e.preventDefault();
272272
}

0 commit comments

Comments
 (0)