Skip to content

[Web] IME-based text input incorrectly fails to capture first character in composing region #103645

@cbracken

Description

@cbracken

Reported on Hacker News.

When inputting Japanese text in a Flutter Web app, we appear to be failing to capture the first character input in the composing region. See attached video for the (incorrect behaviour). I was able to repro on both macOS and Windows. Presumably this affects Linux as well.

Enregistrement.d.ecran.le.2022-05-12.a.10.50.52.mov

Repro steps

  1. Launch a Flutter Web app that includes a text field.
  2. Switch to Japanese input hiragana mode (you should see an あ in the menu bar)
  3. Type n-i-h-o-n-n.

Expected behaviour:
After each keypress you should see:

  • n: n
  • ni: に
  • nih: にh
  • niho: にほ
  • nihon: にほn
  • nihonn: にほん (at this point you may get an auto-conversion to 日本, 2本, or other similar kanji conversion for 'nihon')

Actual behaviour:

  • n: n
  • ni: nい
  • nih: nいh
  • niho: nいほ
  • nihon: nいほn
  • nihonn: nいほん (at this point you may get an auto-conversion to 伊ほん, 伊本 or other similar kanji conversion for 'ihon')

Notes

Verified on Windows, macOS, and Linux and this issue does not affect the desktop embedders, so appears to likely to be an issue in the web engine.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High-priority issues at the top of the work lista: text inputEntering text in a text field or keyboard related problemshas reproducible stepsThe issue has been confirmed reproducible and is ready to work onplatform-webWeb applications specifically

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions