Blocks with custom parameters (adding captions, colors, and other data to a block)

Hi there,
I’m trying to make a website where the person can edit the content using blocks and be able to have a kind of WYSIWYG preview in the panel, especially for colors.
I’ve created fields for my colors, and now I’d like the headings to have these colors.
I’m reading this article but I’m not sure it gives me the tool to do what I want.

Thanks a lot.

There is a plugin for Kirby 3 that could solve your problem:

This function is already integrated in Kirby 4:

Alright, I’ve edited my post to make it more clear, even for myself.

I’d like to be able to see these colors in the admin panel as I edit them (a bit like if I had a caption to a picture for exemple.)

Thanks for the plugins.
I’m testing kirby 4 so the color field is already there :slight_smile:

So that means you have expanded the heading block with a color field? And now you want this color applied to the block preview?

exactly yeah!

Then you would have to create a custom preview for the block in a plugin, and apply the color via css.

See our blocks documentation how to do that:

Yep, thanks, I managed to do it.

I was wondering, a bit offtopic, but is it possible to have multiple columns for the block layout in the admin panel ? (but not affect the website visually?)

Thanks!