-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Grouping blocks using keyboard shortcuts #15980
Comments
I have a local branch prepped to add the keyboard shortcuts back. This will be pushed as soon as #14908 is merged. We can then decide on the exact screenshots. The code has already been written so it may as well get used if we decide keyboard shortcuts are a good idea. |
Not strongly opinionated about this, but I do wonder whether this option would result in some confusion around why grouping a single block using the shortcut doesn't work (and results in the browser behaviour being triggered). On the flipside, I do agree that Cmd+G / Ctrl+G is a very widely recognised shortcut for grouping and it might be instinctive for users to try it. |
Discussed during today's accessibility bug scrub.
Noting
Personally, I use text search a lot. I wouldn't be happy to see that native text search doesn't work in Gutenberg and I guess I wouldn't be alone. Also, when considering keyboard shortcuts please refer to the recommendations in #3218 and related issues. |
I agree that hijacking ⌘G would be the most intuitive solution for most users. But overriding a (probably) often used shortcut doesn‘t seem like the right way to do that. Using ⌘⌥G might need some getting used to but seems like the best option in the long term. |
Alrighty. I think with @afercia's suggestions and our consensus, we have a way forward. Let's go with option 1 from the initial issue. We'll also want to keep in mind Andrea's suggestions posted below.
|
I was just going to suggest this and found this open issue. I also have a background in graphic design and I find myself pressing I agree that we do not want to highjack browser shortcuts but I would love to see Cheers! |
@getdave I believe we have a way forward. Can you work on this?
|
Looks like I neglected to those this. Grouping via keyboard shortcuts has been in place for a good while now. 🎉 |
@getdave What's the shortcut? I tried it the other day and couldn't find it. |
This still appears to be an issue on Windows, Chrome version 85.0.4183.121 (Official Build) (64-bit) Ctrl+g opens up Chrome find text and does not group the block contents |
Here's the PR which added the functionality Also here was the original linked Issue #14601. Note when I implemented this I studied carefully the best keyboard shortcut so as not to collide with existing "known" OS shortcuts. That said, there's always remove for improvement so if these need to be updated in light of new evidence it should be (technically) trivial. |
I'd totally missed that! Thanks for reopening. 🤞 we can find a consensus this time. |
Hi! |
Closing this out as this was implemented :) #46972 |
Based on a discussion in #14908 it looks like this should be its own issue so it doesn't hold up the merge for the grouping action. I outlined the problem in this comment, but sharing here for better visibility.
The Problem
⌘G
is often used for grouping items in graphics applications. It would be nice to use that familiarity with grouping blocks within Gutenberg. However, the browsers currently use⌘G
for finding the next instance of a word when searching the page.Proposals
Use a new shortcut
⌘⌥G
for grouping and⇧⌘⌥G
for ungrouping. Hijacking a browser shortcut⌘G
may not be optimal. This shortcut is very text-based, and so is Gutenberg, so this might be best to leave as is.Use the
⌘G
only when two or more blocks are selected. When people have selected a couple of blocks, they're more than likely to perform an action with them then begin searching for words. Hijack⌘G
only in this case. Otherwise⌘G
would function as the browser shortcut for finding words.Let's hear your thoughts around this and come to an agreement.
The text was updated successfully, but these errors were encountered: