Case ce-0188-japanese-ime-focus-blur-safari · Scenario scenario-ime-composition-focus-blur

Japanese IME composition lost when focus changes in Safari

OS: macOS 14.0 Device: Desktop or Laptop Any Browser: Safari 17.0 Keyboard: Japanese (IME) Status: draft
composition ime focus blur japanese safari macos

Phenomenon

When composing Japanese text with IME in a contenteditable element, clicking elsewhere or changing focus causes incomplete kanji conversions to be lost. The composition may be cancelled before conversion is complete, resulting in lost work.

Reproduction example

  1. Focus the editable area.
  2. Activate Japanese IME.
  3. Type romaji text (e.g., “kanji”) and start kanji conversion.
  4. Click elsewhere or change focus before completing the conversion.

Observed behavior

  • The compositionend event fires with incomplete data
  • Incomplete kanji conversions are lost
  • The blur event may fire before or after compositionend
  • Candidate list disappears without committing selection

Expected behavior

  • Composition should be preserved or gracefully handled when focus changes
  • Incomplete conversions should not be lost
  • Event sequence should be predictable and consistent

Browser Comparison

  • Safari: Composition may be lost on blur, especially on macOS
  • Chrome: May have different behavior
  • Firefox: May have different behavior

Notes and possible direction for workarounds

  • Monitor blur and compositionend events to detect composition loss
  • Consider storing pending conversion state for recovery
  • Prevent programmatic blur during active conversion if possible
Before
Hello かんじ
Japanese romaji input in progress (kanji → かんじ), candidate list displayed
After Blur (Bug)
Hello
Focus change cancels composition, incomplete kanji conversion lost
vs
✅ Expected
Hello 漢字
Expected: Composition preserved or handled gracefully

Browser compatibility matrix

This matrix shows which browser and OS combinations have documented cases for this scenario. The current case is highlighted. Click on a cell to view other cases.

Current case
Confirmed
Draft
No case documented

All variants (detailed table)

Complete list of all cases for this scenario with full environment details.

Case OS Device Browser Keyboard Status
ce-0188-japanese-ime-focus-blur-safari macOS 14.0 Desktop or Laptop Any Safari 17.0 Japanese (IME) draft
ce-0201-chinese-ime-focus-blur-chrome Windows 11 Desktop or Laptop Any Chrome 120.0 Chinese (IME - Pinyin) draft

Playground for this case

Use the reported environment as a reference and record what happens in your environment while interacting with the editable area.

Reported environment
OS: macOS 14.0
Device: Desktop or Laptop Any
Browser: Safari 17.0
Keyboard: Japanese (IME)
Your environment
Sample HTML:
Event log
Use this log together with the case description when filing or updating an issue.
0 events
Interact with the editable area to see events here.

Comments & Discussion

Have questions, suggestions, or want to share your experience? Join the discussion below.