[wp-trac] [WordPress Trac] #45371: Add tag: Use `event.isComposing` to support input method editor (IME) converters

WordPress Trac noreply at wordpress.org
Mon Apr 15 13:29:58 UTC 2019


#45371: Add tag: Use `event.isComposing` to support input method editor (IME)
converters
-------------------------------------+----------------------------
 Reporter:  afercia                  |       Owner:  ryanshoover
     Type:  defect (bug)             |      Status:  assigned
 Priority:  normal                   |   Milestone:  5.2
Component:  I18N                     |     Version:  4.9
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-testing  |     Focuses:  accessibility
-------------------------------------+----------------------------

Comment (by afercia):

 Testing on Windows 10 with Japanese IME and Hiragana I need to press Enter
 twice: first time, to confirm the IME suggestion. After that, the Tags
 suggestions appear and I need to press Enter again. @miyauchi is this the
 expected behavior? Just to be 100% sure I'm not missing anything :)

 @ryanshoover thanks for the new patch. If it's OK for IME, looks good to
 me: the patch restores the original behavior pre [41988] so that (when not
 using an IME) the tags are added when pressing Enter once. Just one small
 thing: I'm not sure I understand `false` used here:

 `if ( window.tagBox || false )`

 For reference and history: reading the related
 [https://github.com/w3c/uievents/issues/202 w3c/uievents GitHub issue] it
 appears the composition events are unreliable: the events order differs
 across browsers and also across languages. The new approach looks cleaner
 and solves the issue. Worth mentioning two useful tools to test keyboard
 events:
 - https://w3c.github.io/uievents/tools/key-event-viewer.html
 - https://input-inspector.now.sh/profiles/2NIftuQTgXLvr5PhtrF8

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/45371#comment:28>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list