UNPKG

@maskito/core

Version:

The main zero-dependency and framework-agnostic Maskito's package to create an input mask

27 lines 947 B
import type { MaskitoPlugin } from '@maskito/core'; /** * 1. Android user (with G-board keyboard or similar) presses 1st space * ``` * {type: "beforeinput", data: " ", inputType: "insertText"} * ``` * 2. User presses 2nd space * ``` * // Android tries to delete previously inserted space * {type: "beforeinput", inputType: "deleteContentBackward"} * {type: "beforeinput", data: ". ", inputType: "insertText"} * ``` * --------- * 1. MacOS user presses 1st space * ``` * {type: "beforeinput", data: " ", inputType: "insertText"} * ``` * 2. User presses 2nd space * ``` * // MacOS automatically run `element.setSelectionRange(indexBeforeSpace, indexAfterSpace)` and then * {type: "beforeinput", data: ". ", inputType: "insertText"} * ``` * --------- * @see https://github.com/taiga-family/maskito/issues/2023 */ export declare function createDoubleSpacePlugin(): MaskitoPlugin; //# sourceMappingURL=double-space.plugin.d.ts.map