[13.0] [FIX]: making all accesskeys working on Google Chrome in web_responsive
This is fix for all problems described in #1830 and #1737.
I've made some research about what accesskey is used in different versions of Odoo (without web_responsive) for apps menu: 12.0, community: no accesskey, enterprise: accesskey="h" 13.0,community: no accesskey, enterprise: accesskey="h" 14.0, both: accesskey="h" master, both: accesskey="h"
So it's strange that web_responsive currently changes it to A. There is no breaking change here.
So I think you told about breaking change for current web_responsive users.
I don't know how to implement both accesskey's on Chrome because KeyboardNavigationMixin does nothing on this browser and lets Chrome to handle accesskeys by itself. And duplicate accesskey attributes are not supported.
For Chrome users, Alt + Shift + A currently doesn't work. And we will affect only non Chrome users of web_responsive.
In case of this change they will see visual hint for accesskey, displaying H on the icon. And they just learn to new shortcut in few seconds.
If it matter it will possible to make trick for backward compatibility and handle Alt + Shift + A in addition for Alt + Shift + H only for non Chrome users. But visual hint will show H for apps menu icon.
I can try to do it in few days. Do you think it's worth it?
Yes, I mean breaking web_responsive habit since a lot of versions. We had that accesskey before Odoo granted one in their core. And we keep e as shortcut for edit as more natural and what we had in v8 in core. It would be good if you can find a way to compatibilize both.
OK, I'll try.
Thanks for the investigation. Trying on runbot with Firefox, I get an undesired effect: the opening of the Firefox Archive menu, which wasn't happening before:
https://user-images.githubusercontent.com/7165771/122168972-2ca24d00-ce7d-11eb-8be1-c683f37be0fe.mp4
Can you do it the contrary? Let accesskey as A, and add through the hack the H
I think you insist on this shortcut cause the convenience of pressing it. I agree.
Returning to the root cause I wanted to change it because it doesn't work on Chrome.
But this hack works on Chrome! So I think I can leave only A key and write additional support for Alt + Shift + A for Chrome and it will be the best solution.
I have a new question :)
Talking about finger convenience. Maybe make Z and X keys instead of P and N for prev/next page. According to usability it will be nice. We group all common keys for right-handed users. What do you think?
This is working variant for Alt + Shift + A. Tested on Chrome and Edge on Windows.
Yes, @SplashS, one of the goals of keeping this is to have one-hand shortcuts, but also to be consistent across versions. Your proposal about using z/x for previous/next makes sense to me, but preserving as well the others for the second goal.
There hasn't been any activity on this pull request in the past 4 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days. If you want this PR to never become stale, please ask a PSC member to apply the "no stale" label.