v3.0: Reapply fix for checkbox issue per #855

This commit is contained in:
Francisco Hodge 2021-03-16 22:02:15 -04:00
parent c707ef79ca
commit 8d22cc258f
2 changed files with 4 additions and 3 deletions

View File

@ -1078,8 +1078,9 @@ class SimpleKeyboard {
if (
(targetTagName === "textarea" || targetTagName === "input") &&
"selectionStart" in event.target &&
"selectionEnd" in event.target &&
["text", "search", "url", "tel", "password"].includes(
event.target.type
) &&
!instance.options.disableCaretPositioning
) {
/**

View File

@ -44,7 +44,7 @@ export type CandidateBoxRenderParams = {
}
export type KeyboardElement = HTMLDivElement | HTMLButtonElement;
export type KeyboardHandlerEvent = PointerEvent & TouchEvent & KeyboardEvent & { target: HTMLDivElement | HTMLInputElement };
export type KeyboardHandlerEvent = PointerEvent & TouchEvent & KeyboardEvent & { target: HTMLDivElement & HTMLInputElement };
export interface KeyboardButtonElements {
[key: string]: KeyboardElement[]