I’d like to add a Group of Buttons core/buttons to an Inner Block template but can’t get it to work.
I have to add CSS Classes to the inner core/button so it’s not enought just to add core/buttons without the specific buttons.
To add a Group of Buttons core/buttons to an Inner Block template with specific CSS classes for each button, you need to ensure you’re defining the core/button blocks within the core/buttons block correctly in your template. Here’s a basic example:
{
“name”: “my-template”,
“title”: “My Template”,
“innerBlocks”: [
[“core/buttons”, {}, [
[“core/button”, { “className”: “my-custom-class-1” }],
[“core/button”, { “className”: “my-custom-class-2” }]
]]
]
}
Ensure each core/button has the appropriate CSS class in the attributes. Adjust the class names as needed for your specific use case.
I hope it will helps you