Repository navigation
Inkkit 0.3.2
Inkkit 0.3.2
Faster long-document editing, stable media across source-mode changes, and a public way for native hosts to report selection activation.
Added
setHostActive(active: boolean | null)controls selection presentation when browser focus events cannot describe a native host's state. Pass whether the editor is active in its host window; passnullto restore browser detection. It does not change focus, selection, text or history.
Fixed
- Appending images preserves a note that contains only a rule, an empty code fence, an image or a reference definition. Trailing blank lines, spaces and original line endings remain intact. Unsafe appends, including those after an open code fence, still fail without changing the document.
- Read-only editors expose their state to accessibility tools while retaining selection, copying and find.
- Unchanged file presentations survive source-mode typing and mode switches. Hidden audio, video and PDF views release playback resources, and returning to formatted mode does not start playback. Changed references and document loads invalidate retained answers.
- Long-document source transitions reuse safe parse results and unchanged rendered blocks. Source headings are cached, search highlights update around edits, and Select All constructs ranges in a single document walk. Syntax with cross-document dependencies keeps whole-document parsing and validation.
- Large source textarea replacements avoid WebKit's costly attached-value replacement while preserving focus, selection, scroll and composition guards.
Reproducible measurements and their limits are in the performance guide. Browser timings do not establish native-host or IME performance.
Native source typing improves after undo, redo and paste, but the under-35-ms target for 10,000 paragraphs remains unmet on the tested Apple M4. Issue #206 remains open; trusted native input and exact-byte save/reopen checks pass.
Compatibility
The host-activation method is additive. Existing hosts retain browser focus detection until they call it. setEditable and both selection color tokens remain unchanged.
File adapters should call refreshReferences when their answer changes. Returning from source mode no longer resolves unchanged files again. Pending hidden resolutions are canceled; completed resolutions remain valid until their reference or document changes, the last view is removed, or the host refreshes them. Clipboard and print resolve their own output.
Apps adopt this published package separately. Inkkit does not decide which items are editable or download remote images.