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

[Panel] Textarea shortcuts not working on Windows #2113

Closed
afbora opened this issue Sep 17, 2019 · 15 comments

Comments

@afbora
Copy link
Contributor

@afbora afbora commented Sep 17, 2019

Describe the bug
Textarea shortcuts not working on Windows

To Reproduce

  1. Go to panel on Windows
  2. Edit any page that have textarea field
  3. Try to use shortcuts like that: CTRL + B, CTRL + I
  4. See nothing happened

Expected behavior
Shortcuts should work as works in MacOS

@texnixe Tested on MacOS and working
https://forum.getkirby.com/t/textarea-shortcuts-not-working-on-windows/15665

Kirby Version
3.2.4

Console output
No output

Desktop

  • Windows 10
  • Chrome, Firefox, Edge (Latest)
@afbora afbora changed the title Textarea shortcuts not working on Windows [Panel] Textarea shortcuts not working on Windows Sep 17, 2019
@distantnative

This comment has been minimized.

Copy link
Contributor

@distantnative distantnative commented Sep 17, 2019

I am seeing we are using the Vue key meta modifier: https://github.com/getkirby/kirby/blob/master/panel/src/components/Forms/Input/TextareaInput.vue#L37

On a mac that is the comand key, on windows this maps to the windows key.

@afbora

This comment has been minimized.

Copy link
Contributor Author

@afbora afbora commented Sep 17, 2019

When pressing Win + L as always use in texarea, windows locking 😱

@distantnative

This comment has been minimized.

Copy link
Contributor

@distantnative distantnative commented Sep 17, 2019

Yea, I am not sure having the windows key involved is such a great idea

@afbora

This comment has been minimized.

Copy link
Contributor Author

@afbora afbora commented Sep 17, 2019

Please have a look: vuejs/vue#4843

@distantnative

This comment has been minimized.

Copy link
Contributor

@distantnative distantnative commented Sep 17, 2019

Just read it, sadly no solution.

@afbora

This comment has been minimized.

Copy link
Contributor Author

@afbora afbora commented Sep 17, 2019

Worked with CTRL + WIN + B to bold, not at all useful 😞

Can't we add a property like checkCmdOrCtrl()?
I don't think users can use CTRL + WIN + X because I see it for the first time.

@distantnative

This comment has been minimized.

Copy link
Contributor

@distantnative distantnative commented Sep 17, 2019

I think we had them first on ctrl as well but that was blocking something else - not sure. @bastianallgeier might remember. Otherwise yea, we could bind both meta and ctrl.

@afbora

This comment has been minimized.

Copy link
Contributor Author

@afbora afbora commented Sep 17, 2019

Let's solve it or not, it would be nice to put a link to the bottom of the textarea or panel that opens the relevant or all shortcuts dialog for end users.

@bastianallgeier

This comment has been minimized.

Copy link
Contributor

@bastianallgeier bastianallgeier commented Sep 17, 2019

Related: #1898

@bastianallgeier

This comment has been minimized.

Copy link
Contributor

@bastianallgeier bastianallgeier commented Sep 17, 2019

Maybe it's better to bind them to CTRL only?

@lukasbestle

This comment has been minimized.

Copy link
Contributor

@lukasbestle lukasbestle commented Sep 17, 2019

I think Cmd makes sense on macOS – it's convention and as long as we use the keys that are used in other apps for the purpose, it's probably the best solution. Ctrl would be very confusing.

On Windows we should however support Ctrl, so I support (haha) the idea of supporting both.

@afbora

This comment has been minimized.

Copy link
Contributor Author

@afbora afbora commented Sep 18, 2019

Btw CTRL + S working perfect and i'm already using this shortcut

@distantnative

This comment has been minimized.

Copy link
Contributor

@distantnative distantnative commented Sep 18, 2019

True, cause in our global events keydown bus we are alreay using both: https://github.com/getkirby/kirby/blob/master/panel/src/config/events.js#L59-L61

So I think the straightforward way is to add ctrl in Textarea as well.

@afbora

This comment has been minimized.

Copy link
Contributor Author

@afbora afbora commented Sep 18, 2019

Let's solve it or not, it would be nice to put a link to the bottom of the textarea or panel that opens the relevant or all shortcuts dialog for end users.

GitHub Style

https://github.com/getkirby/kirby/network

Bottom of page

FireShot Capture 763 - Network Graph · getkirby_kirby - https___github com_getkirby_kirby_network

Shortcuts modal

image (1)

distantnative added a commit that referenced this issue Oct 11, 2019
@distantnative distantnative self-assigned this Oct 11, 2019
distantnative added a commit that referenced this issue Oct 11, 2019
@afbora

This comment has been minimized.

Copy link
Contributor Author

@afbora afbora commented Oct 11, 2019

@afbora afbora closed this Oct 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.