fix(web): exact iOS caret, review fixes and round-eight items (#830)

Toolbar Enter spends one-shot Ctrl; Backspace finds the last grapheme with Segments.containing(); accessory Shift+Tab keeps the draft like a typed one.
Pass the captured session to Compose uploads, voice compose and held CJK drafts; clear Ctrl on deletion-only native edits; path picker clears predictions.
Clear xterm dead-key state on native commits; restore a borrowed clipboard field before classifying a key; overlay removeChar spans the pending/flushed boundary.
Place the trackpad caret from the overlay layout (getInputAnchor, committedText) or validated xterm cells, hiding when unproven; no end-minus-width arithmetic.
Grapheme-aware replay Backspace; docs, README rows, changeset and comment updates.
This commit is contained in:
Hadrien Kerlero committed 2026-11-21 21:16:13 +01:00
1 parent 414dd51eb2
commit cda5d96451
26 files changed
+1072 -170

No files matched your search

+6 -2
View File
@@ -70,8 +70,11 @@ describe('xterm private-API dependency guard', () => {
// and touch quietly stops forwarding to native SGR tracking apps. Property names survive
// minification, so a string check on the shipped bundle catches a rename on upgrade.
// terminal-ios-native-input.js wraps `_inputEvent`, `_handleTextAreaBlur` and `_finalizeComposition`
// and reads `_compositionView`; if any is missing its create() returns null, and iOS then gets
// neither the native-input owner nor the keyCode-229 recovery, so #830 returns without a signal.
// and reads `_compositionView`; if any is missing its create() returns null, and iOS falls back
// to the keyCode-229 recovery, so #830 (suggestions, phrase replacement, held delete) returns
// without a signal.
// The iOS owner also clears `_unprocessedDeadKey` when native input commits text,
// so the next terminal command is not swallowed as part of the dead-key sequence.
it('still ships the composition-helper and mouse-service fields terminal input depends on', () => {
const bundle = readFileSync(resolve(root, 'node_modules/@xterm/xterm/lib/xterm.js'), 'utf8');
for (const name of [
@@ -84,6 +87,7 @@ describe('xterm private-API dependency guard', () => {
'coreMouseService',
'activeEncoding',
'_inputEvent',
'_unprocessedDeadKey',
'_handleTextAreaBlur',
'_finalizeComposition',
'_compositionView',