Closed turnstylerj closed 1 year ago
Interesting, I understand what you mean.
Do you think there times when you would want to see previews when there is only 1 child block? I'm thinking that the plugin could potentially skip previews altogether when there's only 1 child block (instead of it being configurable). But it might be the case that there are times when you still want to show the user the overlay even if there's only 1 child.
Personally, no I don't think I'd ever show the preview with only one child block. But I could potentially see other use cases where someone might want to for consistency, and there are times when a Neo block will have a few different child blocks (but I only really need the visual preview on the parent), so I think having it configurable on the parent block for its children would allow for the most flexibility.
I've added an approach to handling this in the latest release 4.1.0.
I've simplified things a little bit though. There's now an additional setting for neo fields that lets you disable the plugin when there's only 1 child block available for a neo field:
Check out the latest release and let me know if it works OK for you.
Thanks for the quick turnaround! I think the level of Neo support is solid enough now to give this plugin a spin on a full site, so I'm looking forward to working with it and will definitely provide some feedback!
Description
When using Neo fields for a content builder, it's common to use child blocks for repeatable sections of content (i.e. rows inside an accordion), but the preview modal adds extra friction/clicks when there's only one type of child block that allows the author to add a new set of repeatable fields inside the block.
In these situations, it'd be nice to have the ability to disable Matrix Field Preview for child blocks of a Neo block within that block's preview settings.
Example