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

feat: Hide keyboard shortcuts on mobile screens #9051

Merged
merged 3 commits into from
Aug 16, 2018

Conversation

tofumatt
Copy link
Member

Fix #9050.

Description

Hide the shortcuts for mobile screens.

How has this been tested?

Tested locally; works.

Screenshots

screen shot 2018-08-16 at 14 31 03

Types of changes

CSS change.

Checklist:

  • My code is tested.
  • My code follows the WordPress code style.
  • My code follows the accessibility standards.
  • My code has proper inline documentation.

@tofumatt tofumatt requested review from jasmussen and a team August 16, 2018 13:39
@jasmussen
Copy link
Contributor

I'm actually seeing some issues, though I'm not sure if that's a result of this PR or a regression from the one I just merged :(

This PR:

issues

Master:

master

Upon further investigation, yeah definitely looks like a regression from my PR, sorry :( Pushing a fix in a second.

@jasmussen jasmussen added this to the 3.6 milestone Aug 16, 2018
@jasmussen
Copy link
Contributor

Just pushed a fix to the issue:

fixed

See also:

screen shot 2018-08-16 at 17 13 15

screen shot 2018-08-16 at 17 13 19

Copy link
Contributor

@jasmussen jasmussen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This improves on the menu situation on small viewports, and it also helps (hot)fix a regression I introduced. Sorry about that. Let's get this into 3.6.

// Hide the keyboard shortcuts on mobile, because they aren't super-useful
// for most mobile users and it frees up screen space for any item
// with a long description.
display: none;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably fine for now, but I wonder if this should be hidden entirely in the generic MenuItem component or something specific to the Global menu item.

It can be used in the Block Settings Menu and elsewhere since it's a generic component.

@tofumatt
Copy link
Member Author

tofumatt commented Aug 16, 2018 via email

@youknowriad youknowriad merged commit 2399173 into master Aug 16, 2018
@tofumatt tofumatt deleted the try/hide-shortcuts-on-mobile branch August 16, 2018 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants