How are you looking to extend? I looking for ways to customize what is there using CSS or are you a developer wanting to extend the functionality with code?
Thank you Leslie
I’m a developer. I have seen that the columns block layouts are included in a variations constant, but I have not found yet how to override or extend it with new layouts. If I get it I will post it here.
Best
I have found how to do it:
wp.blocks.registerBlockVariation( ‘core/columns’, { name: ‘custom’, title: ‘Smiley’, isDefault: true, innerBlocks: [ [ ‘core/column’, { width: 33.33 } ], [ ‘core/column’, { width: 66.66 } ] ], icon: ‘smiley’, scope: [ ‘block’ ] } );
But I would like to add also a custom class to the variation.Any tips about how to get it?
Thank you in advance
Found it
wp.blocks.registerBlockVariation( ‘core/columns’, { name: ‘custom’, title: ‘Smiley’, isDefault: true, innerBlocks: [ [ ‘core/column’, { width: 33.33 } ], [ ‘core/column’, { width: 66.66, className: ‘custom’ } ] ], icon: ‘smiley’, scope: [ ‘block’ ] } );
Glad you found it. Sorry I didn’t get back sooner. For reference to anyone who finds this in a search, block filters on ww.wp.xz.cn should be helpful.
Thanks for updating as resolved.