SmilyOrg / tw5-monaco

Monaco editor for TiddlyWiki
https://smilyorg.github.io/tw5-monaco/
26 stars 4 forks source link

Autocomplete on Android Phone doesn't move the cursor/caret #19

Open cdaven opened 2 years ago

cdaven commented 2 years ago

When I use the soft keyboard's autocomplete on my pretty new Android phone (Chrome browser, SwiftKey keyboard), the cursor/caret ends up before the inserted word, as if it didn't move at all.

Example:

I press in turn the suggested words at the top of my soft keyboard: "I", "am", "currently", "working on", "the", "next". This is what I end up with:

 am currently working on the next I

Note the leading space. The cursor/caret is blinking just to the left of "I".

SmilyOrg commented 2 years ago

Interesting! I think this is specific to the plugin as it seems to work fine in vanilla Monaco.

It could be due to the way internal text state is updated that works differently on mobile.

I'll take a look when I get the chance, thanks for reporting!