Block Style Selector Not Getting Style From a Current Block

6 replies
Last updated: May 3, 2021
I’m not sure if there is a regression or there is something wrong with my config (which is pretty much out-of-the-box for the block editor) but for some reason my block style selector is not getting the actual style from a currently selected block. Is anybody experiencing this too?
Apr 28, 2021, 9:19 PM
Marks are working ok. Also the style selector updates as soon as I go into/out of full screen
Apr 28, 2021, 9:22 PM
Downgraded to 2.9.0 and style selector works correctly. So assume it’s a regression from 2.10.0
Apr 29, 2021, 6:19 AM
Yep, the function that handles the styles is memoized and it has lost the
dependency and I assume
is not updated with selection thus not triggering a “fresh” function call[…]sanity/form-builder/src/inputs/PortableText/Toolbar/Toolbar.tsx
Apr 29, 2021, 6:35 AM
Apr 29, 2021, 6:44 AM
I’d create a PR but I’m not sure how to test it. The
is clearly connected to an account that I have no access to:)
Apr 29, 2021, 7:00 AM
I ran into this over the weekend as well.
May 3, 2021, 2:46 PM – build remarkable experiences at scale

Sanity is a customizable solution that treats content as data to power your digital business. Free to get started, and pay-as-you-go on all plans.

Categorized in