web: a tap that closes the Format sheet leaves the caret where it tapped
Fable's follow-up D on #181. A tap in the document closes the sheet on the editor's focusin, and the editor dropped the kept selection at once, before ProseMirror had read the tap from the page, so the old selection was written back over it: the caret was not where the person tapped. When the editor already has focus as the sheet closes (a tap did it), the kept selection now goes a moment later, after that read, and the document is not refocused. TestATapInTheDocumentClosesTheSheet taps just after "First" and checks the caret is there (offset 5, collapsed, in the first paragraph). It failed before (the second paragraph still selected).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
3 files changed,
+36
−12
fixtures/editor-entry.js+10 −0internal/docs/phone_sheet_browser_test.go+15 −1internal/docs/static/{editor.cbd2f10270dbb05d.js => editor.fe1db7ee4d4551b0.js}+11 −11
fixtures/editor-entry.jsLoading diff…
internal/docs/phone_sheet_browser_test.goLoading diff…
internal/docs/static/{editor.cbd2f10270dbb05d.js => editor.fe1db7ee4d4551b0.js}Loading diff…