/** * DOM write helpers that preserve the browser's undo/redo stack. * * Direct `element.value = x` wipes the undo history. `setRangeText` registers an undo * step instead, so Ctrl+Z keeps working. Every value mutation in NumoraInput should * route through one of these helpers (the public `setValue({ undoable: false })` * escape hatch is the only intentional exception). */ /** * Writes a new value to the input and sets the caret in one operation, preserving the * undo stack. Skips the write if the value and caret are already what we want - that * avoids adding a noisy no-op undo step. * * @param el - The input element * @param newValue - The value to write * @param cursorPos - The caret position to set after the write */ export declare function writeValuePreservingUndo(el: HTMLInputElement, newValue: string, cursorPos: number): void; /** * Writes a focus-strip result: replaces the formatted value with raw digits and maps * the caret/selection in one shot. Uses `preserve` (not `end`) so setRangeText does not * snap the caret to the end of the string before setSelectionRange runs - that snap is * what causes the visible left-then-right flicker when external `input` listeners paint * between the two calls. */ export declare function writeStripPreservingUndo(el: HTMLInputElement, raw: string, rawStart: number, rawEnd: number): void;