Ich versuche, einen benutzerdefinierten Gutenberg-Block mit InnerBlocks mit einer Vorlage zu entwerfen. Ich möchte jedes Steuerelement in der Symbolleiste eines ‘Absatz‘ Innerblock in dieser Vorlage. Ich habe gesucht, aber ich habe keine Lösung gefunden. Vielleicht ist es mit diesem Code verständlicher:
edit: function( props ) {
return el('div',{className: props.className},
el( InnerBlocks,{
template:[
[ 'core/image', {} ],
[ 'core/heading', { placeholder: 'Book Title' } ],
[ 'core/paragraph', { placeholder: 'Summary' },
/*
I want to disable the toolbar of this innerblock
Of course the below code is not possible into a template of innerblocks
[BlockControls,{ key: 'controls' }, []],
*/
]
],
templateLock: "all",
})
);
}
Danke vielmals.