Skip to content

Try: Fix cropped focus ring in block library#17215

Merged
jasmussen merged 1 commit into
masterfrom
try/block-library-focus-fix
Aug 27, 2019
Merged

Try: Fix cropped focus ring in block library#17215
jasmussen merged 1 commit into
masterfrom
try/block-library-focus-fix

Conversation

@jasmussen

Copy link
Copy Markdown
Contributor

Maybe fixes #17094 and maybe fixes #17168 too.

There's focus ring on blocks in the block library and the switcher. These are cropped when blocks are near the edges, due to an overflow: hidden;. This PR attempts to fix that with a deadpan negative margin. Will it work? This is where YOU come in!

Before:

63598879-72966e80-c58e-11e9-8a61-8d870dc60e39

After:

Screenshot 2019-08-27 at 15 56 45

Maybe fixes #17094 and maybe fixes #17168 too.

There's focus ring on blocks in the block library and the switcher. These are cropped when blocks are near the edges, due to an overflow: hidden;. This PR attempts to fix that with a deadpan negative margin. Will it work? This is where YOU come in!

@kjellr kjellr left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks, @jasmussen. This seems like a relatively solid fix for now. The main issue I see is that the hover state of one item can bump right up against the focus state of another now:

Screen Shot 2019-08-27 at 11 17 30 AM

I don't have any immediate ideas for that... perhaps a transparent border or something? But if we can't figure that out, I think this is still an improvement, so probably fine to merge as a fix for now.

@jasmussen

Copy link
Copy Markdown
Contributor Author

Thanks, I think that's a better state than master, a better holdover :)

@jasmussen jasmussen merged commit 51ec639 into master Aug 27, 2019
@jasmussen jasmussen deleted the try/block-library-focus-fix branch August 27, 2019 15:47
@mapk

mapk commented Aug 28, 2019

Copy link
Copy Markdown
Contributor

Thanks for this @jasmussen! Sorry for the breakage. 😞

@jasmussen

Copy link
Copy Markdown
Contributor Author

Don't worry about it!

@gziolo gziolo added this to the Gutenberg 6.5 milestone Aug 30, 2019
@gziolo gziolo added [Type] Bug An existing feature does not function as intended [Feature] Inserter The main way to insert blocks using the + button in the editing interface labels Aug 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Feature] Inserter The main way to insert blocks using the + button in the editing interface [Type] Bug An existing feature does not function as intended

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Revise method of preventing a "flash" of default inserter help panel content Choosing Block | Focus Overflow Hidden

4 participants