Open jamonholmgren opened 7 years ago
I like this idea a lot. I think there's maybe 2 items here:
Grouped content. Currently content is only grouped in the context of a page. However, it could be you have a 'profile' piece of content that you want to always display using a piece of text content, image content, and html content. So you could define content blocks to be more modular. Grouped content may or may not be global content.
Lists. This is tricky because there is ordering like you mentioned, and potentially dynamic sorting and filtering and search.
If you have a list of content groups, with each group having a piece of text content called 'title', you could sort by that field.
Generally, I kind of wonder if this will become something closer to contentful or headless cms-y because I immediately want to add tagging and collections to pieces of content.
If we added tagging/collections/categories to content or content groups, we could have a list component that could define which tags(s) to grab and sort order. In the case of content groups, maybe which fields to display. It may have to have content that nests other content (ie. if your list adds a presentationlayer around each item... like if your list is a list of blog posts, and you want to wrap the image, title, and description in a card in just the list ui.)
This is an issue to track the discussion about content areas in Thesis.
Here's a random page from the internet (Denny's restaurant, I guess):
As you can see, there are repeated, similar blocks vertically down the page. If we wanted to make this page editable in Thesis currently, it would be a bit of a pain. Usually what we do is put more
content
blocks than we need and hide the empty ones, something like this:It's not ideal.
One idea to fix this is to have content areas where you can repeat content blocks an arbitrary number of times.
Content Areas
The
do...end
block holds the default content for any new content blocks that are added by the user.The user can add content blocks to the content area by clicking a + icon or something, at the bottom of the content area. This drops in a new copy of the default content that they can then edit.
We would need to differentiate the blocks but also keep them grouped. Something like
"Year Section"
describes the whole area, but each content block is"Year Section-1"
etc, or something like that.That brings up the question of sorting, too. Do we need a sort order field on
page_contents
? We would also need a sorting handle, and it could get messy.It's a bit late, so I'll stop here. Looking for more thoughts on this.