Reputation: 1
First of all, I wish everyone a good day.
I want to group blocks that I created with StreamField.
I am attaching an example video and image below.
Thank you for your help, best regards.
What do I want to do?
All component list
All html blocks
Upvotes: 0
Views: 209
Reputation: 25227
Maybe the group
option on the block definition is what you're looking for?
body = StreamField([
('title', CharBlock(group='text blocks')),
('paragraph', RichTextBlock(group='text blocks')),
('image', ImageChooserBlock(group='media blocks')),
('video', EmbedBlock(group='media blocks')),
])
Upvotes: 1