Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cursor keys are now trapped by autocomplete selector even if you're not autocompleting #10116

Closed
ara4n opened this issue Jun 19, 2019 · 4 comments

Comments

@ara4n
Copy link
Member

ara4n commented Jun 19, 2019

if you type :)left arrow then suddenly the :) gets turned into an emoji picked from autocomplete options, which you then have to disentangle yourself from & cancel.

This is a recent regression, and very annoying, because i do not expect autocompletes to kick in unless i am explicitly autocompleting (by hitting tab or whatever), rather than moving cursor keys to fix typos caused by my broken keyboard.

@bwindels
Copy link
Contributor

bwindels commented Jun 21, 2019

ftr, this is in the main composer, the edit editor doesn't seem to have the problem.

@bwindels
Copy link
Contributor

bwindels commented Jun 21, 2019

regression from matrix-org/matrix-react-sdk#2966

@bwindels
Copy link
Contributor

bwindels commented Jun 21, 2019

So, the change that was introduced in the above PR is that the left and right arrows also navigate the completions (when available) instead of the caret. This brought it in line with what that up and down arrow already did before that. So in a multi-line message, you'd already have the problem trying to move the cursor up or down.

This brings up the question, how should autocomplete work?

  • only open when explicitly asked for (tab)?
  • open explicitly and on certain cues (typing @, #, :)?
    • How about ascii aliases for emojis like xD for 😆?
  • once autocompletion is open, should
    • left & right arrow navigates completions instead of caret?
    • up & down arrow navigates completions instead of caret?
  • just for clarity: once escape is pressed, autocomplete should not reappear for the same location in the editor

Defining this well will also be valuable to make sure the autocomplete behaves as intended in the new editor.

It makes sense that the left / right arrow being diverted is a lot more bothersome than up and down as that's how you navigate the editor most of the time. I propose I just disable left and right arrows going to autocomplete when it's open to get rid of the annoyance for now.

@lampholder
Copy link
Member

@bwindels - yes - I reckon we just remove left/right for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants