Gutenberg: Sibling inserter doesn't appear above selected block with no toolbar

Created on 11 Jul 2018  路  4Comments  路  Source: WordPress/gutenberg

Describe the bug
The sibling inserter (+) doesn't appear above a block that is selected if the block has no toolbar.

To Reproduce

  1. Insert a paragraph block with text
  2. Insert a More block
  3. With the More block selected, hover your mouse over in the centre area between the Paragraph block and the More block
  4. Notice that sibling inserter doesn't appear.

Expected behavior
The sibling inserter (+) should appear.

Screenshots
inserter

Additional context
This is because we disable :hover on the sibling inserter that is before a selected block. This prevents it from getting in the way when there is a toolbar.

https://github.com/WordPress/gutenberg/blob/74e1b760e318526c929c83ef95151b6ff1645b78/editor/components/block-list/style.scss#L751-L760

To fix this, we would have to update the CSS above to be smart enough to know whether or not there are items in BlockToolbar. This could be awkward since that information is stored in React context.

Came up in https://github.com/WordPress/gutenberg/pull/7799.

[Feature] Inserter [Type] Bug

Most helpful comment

I think this could annoy some people so let's milestone it.

All 4 comments

Not sure how much of a priority this is.

@jasmussen @karmatosed 鈥撀爓ould you mind putting it in a milestone if you think it's worth doing or just closing it if not?

I think this could annoy some people so let's milestone it.

This seems to be working as expected now.

@mtias Since all blocks have toolbars now due to the ellipsis menu being moved there, the original intent of this ticket doesn't really make sense anymore. There are no blocks without toolbars. So yeah, it is working as expected, but what the issue wanted to accomplish has not been done, though it is now not really feasible anymore.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

youknowriad picture youknowriad  路  3Comments

mhenrylucero picture mhenrylucero  路  3Comments

aduth picture aduth  路  3Comments

nylen picture nylen  路  3Comments

franz-josef-kaiser picture franz-josef-kaiser  路  3Comments