Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Force HTML blocks to be in preview mode when in a shared block #7138
We then use this functionality to force HTML blocks to render in preview mode when disabled. This means that HTML blocks always render in preview mode when they are shared which is a nice UX enhancement.
How has this been tested?
I unfortunately had to temporarily skip all of the
I manually tested by:
It took me a while to understand what kind of magic is happening in this PR. I like this usage of Context API. I must admit it nicely takes advantage of the virtual DOM tree scoping to inform child blocks that they should be in disabled state
It also tests well, very nice improvement. Can we use it also with other blocks that have preview mode, maybe shortcodes?