Gutenberg: 'focus' doesn't work anymore?

Created on 4 May 2018  Â·  2Comments  Â·  Source: WordPress/gutenberg

Issue Overview


Previously on some blocks I had some features only displayed when a block was focused. I achieved this simply by doing a quick focus check (i.e., const SampleFeature = focus && etc ) Now, it seems focus checks always fail.

Chrome

Expected Behavior

I want a div to show up when a block is focused in the editor, otherwise I want it to be hidden.

Current Behavior

Any such divs will be hidden whether or not a block is focused in the editor.

Possible Solution

¯_(ツ)_/¯

Most helpful comment

Focus was deprecated in favour of isSelected

All 2 comments

Focus was deprecated in favour of isSelected

Ahh Thanks

Was this page helpful?
0 / 5 - 0 ratings

Related issues

wpalchemist picture wpalchemist  Â·  3Comments

maddisondesigns picture maddisondesigns  Â·  3Comments

ellatrix picture ellatrix  Â·  3Comments

BE-Webdesign picture BE-Webdesign  Â·  3Comments

youknowriad picture youknowriad  Â·  3Comments