Skip to content

Bug: Committing an IME composition with a mouse click scrolls the viewport back to the composed text #8834

Description

@2wheeh

Lexical version: 0.47.0

Steps To Reproduce

  1. Put the caret at the end of a paragraph and, with the IME active, type some Korean letters (ex. ).
  2. Leave it in composing state so it stays underlined. Do not press Space/Enter/arrow keys, which would commit it normally.
  3. Scroll with the wheel/trackpad until the composing character is out of view. (Scroll with the wheel, not the keyboard. A key press would commit the composition and defeat the repro.)
  4. Click once, without typing. Either of these reproduces it:
    4.1 Click inside the editor, on a different line that is currently visible.
    4.2 Click outside the editor - a toolbar button, blank space, etc.

Link to code example: playground

The current behavior

2026-07-14.10.52.54.mov

The expected behavior

2026-07-14.10.51.43.mov

Impact of fix

Severity: Not an outage and no data loss — the composed text does commit correctly. It is a UX correctness bug: the viewport jumps away from where the user put it, and in the click-inside-the-editor case the caret and the viewport end up in two different places, which reads as the editor being broken.

Frequency: Every time a pointer press force-commits an in-flight composition, in any document long enough to scroll. The triggering sequence is ordinary rather than exotic — compose a word, scroll to find something, click it — so an affected user hits this repeatedly in a single session rather than once in a while.

Who benefits: Users typing with an IME — Korean, Japanese, and Chinese input being the main cases, plus any other composition-based input method. This is the default text entry path for those languages, not an optional mode, so it affects every such user of a Lexical-based editor rather than a niche configuration.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions