fluid-lab / gamepad-navigator

GSoC 2020 project
Other
8 stars 10 forks source link

Improve editing of `<textarea/>` and `contenteditable` elements. #143

Open duhrer opened 10 months ago

duhrer commented 10 months ago

In testing with this page linked from the fluidproject.org site, I encountered for the first time an element with the contenteditable flag set.

I added the ability to edit these, but it's very clunky. There is no special handling for <textarea/> content either at the moment. Both of these can be multi-line, which doesn't work well at all with the existing onscreen keyboard because:

  1. The content scrolls offscreen.
  2. The cursor is often not visible.
  3. There are no up/down arrow controls.
  4. There's no enter key.

I may leave this as it is for 1.0, but wanted to document the issues, as I think it could be worth looping back and polishing this up later.

duhrer commented 10 months ago

In looking at Google's search input, it's a <textarea/>with its row attribute set to 1, which we need to special case and treat like an <input type="text"/>element, i.e. we should not try to present/edit that as a multi-line field.