-
Notifications
You must be signed in to change notification settings - Fork 881
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
Keyboard shortcut modal #6306
base: development
Are you sure you want to change the base?
Keyboard shortcut modal #6306
Conversation
…at/keyboard-shortcut-modal
…c icons, capitalize non-special shortcut letters
CTRL Z is the standard keyboard shortcut for undo on Windows. We should probably use the same shortcut that YouTube does. |
src/renderer/components/FtKeyboardShortcutPrompt/FtKeyboardShortcutPrompt.vue
Outdated
Show resolved
Hide resolved
src/renderer/components/FtKeyboardShortcutPrompt/FtKeyboardShortcutPrompt.vue
Outdated
Show resolved
Hide resolved
src/renderer/components/FtKeyboardShortcutPrompt/FtKeyboardShortcutPrompt.vue
Outdated
Show resolved
Hide resolved
<ft-button | ||
:label="$t('Settings.Show Keyboard Shortcuts')" | ||
@click="showKeyboardShortcutPrompt" | ||
/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In your screenshot the button looks very out of place in its current position, but I can't think of anything better at the moment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fair call out, I didn't know what exactly to do with this one either. This was another adjustment I tried out. Open to this one or any other suggestions. @absidue
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe it could be under general setting with a keyboard icon added to the button? Or maybe a separate keyboard shortcuts "settings section" (so it wouldnt be using a modal popup and would just display all the shortcuts under the Keyboard Shortcuts section but we'd be able to update it to support #251 eventually).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it's its own setting section, I do worry that people will think it's already modifiable. I can put it on its own row there as a button for now if that works, but it might still look out of place and not fit in as a "general setting".
Edit: I do love the keyboard icon idea and incorporated that now. Still unsure on how best to improve the placement.
Co-authored-by: absidue <48293849 [email protected]>
Change shortcut to be more accurate, remove duplicate action for closing current FreeTube window, update label for force reload
…reeTube into feat/keyboard-shortcut-modal
5469153
to
8476c4a
Compare
|
@efb4f5ff-1298-471a-8973-3d47447115dc Excellent catch, fixed and added to the testing criteria now |
This pull request has conflicts, please resolve those before we can evaluate the pull request. |
…at/keyboard-shortcut-modal
Conflicts have been resolved. A maintainer will review the pull request shortly. |
Weird suggestion: If a contributor adds a shortcut key than they also have to :
Would it be possible to generate the contents of the shortcut modal based on the docs? That way if someone changes something in the docs it will automatically be reflected within the app. Pull latest list on startup just like the IV instances. |
@PikachuEXE just tested is and it looks pretty good. Unsure if this is really needed |
I don't think we should do that. Invidious instance list is from a public api that we dont control and can be updated without a new version of FreeTube being installed. If we get the modal from the docs repo then either the modal will be incorrect for nightlies or will be incorrect for the release. Another option is we could update the docs repo's keyboard shortcuts section to mention that you can now view the keyboard shortcuts in the app, show how to view the shortcuts and mention how that page might be out of date. |
That's an interesting idea. The two main approaches I can think of would be parsing the HTML directly (which might have different formatting, preambles, etc. than we would prefer for an in-app modal) or getting it from a JSON file of shortcuts (like we do with the Invidious instances). The main issue with the latter is that we'd have to either update the JSON file as well for each change (thus being the same amount of effort of two changes per new/modified shortcut) or convert the docs page to grabbing the data dynamically from the JSON file as well, which would be shaky and might be hard to section & format. So I don't think there's a solution at the moment that would guarantee a lower amount of net effort. Edit: Whoops, just updated to see a similar comment by @ChunkyProgrammer. |
Should code comments be added to the shortcuts section so people are aware they also have to change it in the modal when they are adding/changing shortcuts? |
The latest code comment doesn't seem to mention the modal |
00eff2a
to
31349ab
Compare
31349ab
to
0126970
Compare
Implemented #5966 but it depends on this |
Keyboard shortcut modal
Pull Request Type
Related issue
closes #2822
Description
Ctrl ZShift ? keyboard shortcut (same as YT) (for non- mobile device sizes only) button at the top of the settings page that opens/closes a modal containing all of the keyboard shortcuts available in FreeTubeft-prompt
logic to check forft-icon-button
s as well, not justft-button
sScreenshots
Testing
Desktop
Additional context