Gutenberg: Show block outline when focusing / hovering the block type

Created on 13 Mar 2020  路  8Comments  路  Source: WordPress/gutenberg

One detail we didn't get to implement from #18667 is that when the user focuses or hovers the block type / movers, the outlines of the whole block appear to clearly show its boundaries.

image

This is the equivalent of the "selection" tool.

[Feature] Blocks [Feature] Writing Flow [Status] In Progress [Type] Enhancement [Type] Task

Most helpful comment

I have this working:

Screen Capture on 2020-03-16 at 13-53-18

It's currently using the same styles as selection. The show/hide mechanics follow the same rules as the Movers.

If folks have an idea for perhaps alternative styles, please let me know :)

All 8 comments

Thanks I missed having a clearly defined area showing the outline of the block area.

Comparing version 7.6 and 7.7

Gutenberg 7.6
Screen Shot 2020-03-15 at 11 38 31

Gutenberg 7.7
Screen Shot 2020-03-15 at 11 39 08

In 7.7 we are missing the boundary of the area one is working in. It can create confusion.

Comparisons

Blue outline around the selected Cover Block:
Screen Shot 2020-03-16 at 11 55 22

No outline in the selected child paragraph block:
Screen Shot 2020-03-16 at 11 55 30

Blue outline around the selected spacer block. Which also uses a grey background placeholder.
Screen Shot 2020-03-16 at 12 01 06

Blue outline around the selected Image Block:
Screen Shot 2020-03-16 at 11 55 52

No outline in the selected caption area. (Caption it almost like a child paragraph block to the image block.)
Screen Shot 2020-03-16 at 11 58 06

Selected Paragraph block.
Screen Shot 2020-03-16 at 11 59 56

It might be good enough to just hover over the general toolbar (move etc icons) to show the outline. It gives a clear definition of the space they contain. Giving a clear definition of the area that is being manipulated. Without having to go to the top toolbar to go into the drop down to select the Select tool.

Without having to go to the top toolbar to go into the drop down to select the Select tool.

You can also press the escape key.

I too miss the outline (and isn't it part of accessibility?), especially since the editor is using a color without regard to the background color that the theme has set. This also applies to the placeholder text. I found in the CSS that the placeholder text is set to gray, opaque, and a background of transparent. (that's just downright irresponsible)

One thing to also consider is too many outlines and too heavy an interface can also cause accessibility issues. What I like about this initial proposal in the issue, gives some steps onto how a balance can happen. I think it's important to look back at that point of this issue a little and focus on that, through the movers.

No outline in the selected child paragraph block

Part of the logic here is that the caret (the blinking line that indicates you can type) _is_ the focus state for text-related blocks like Paragraph and Heading.

I'm taking a look at this now 馃

I have this working:

Screen Capture on 2020-03-16 at 13-53-18

It's currently using the same styles as selection. The show/hide mechanics follow the same rules as the Movers.

If folks have an idea for perhaps alternative styles, please let me know :)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

moorscode picture moorscode  路  3Comments

spocke picture spocke  路  3Comments

wpalchemist picture wpalchemist  路  3Comments

jasmussen picture jasmussen  路  3Comments

maddisondesigns picture maddisondesigns  路  3Comments