Feature request: Splittable "The content" element

Hi!

I am thinking about those Content elements seen in Adobe products such as Illustrator and InDesign: there is a setting that connects two or more different boxes, allowing the content to flow from one to another, no matter where they are placed.

Such thing would allow building even more complex layouts. Imagine a content area that is supposed to house a CTA or a Banner, about 20% down the content. This would be super easy in the layout editor, if content could “jump over” the other elements that are between the text.

This approach is increasingly important because the sidebar is pretty obsolete concept, given the fact that barely 20% of visitors ever see it. So if we are solving the layout for the mobile, we are automatically solving it for the Desktop as well, allowing us to remove the Sidebar and have more streamlined reading experience.

For that reason it would be great to be able to build Single layouts where the content can be interrupted with other layout elements.

Thanks!

3 Likes

Very interesting idea here! I’m not sure how it would be possible but I like the creative possibilities for sure. The DOM has some hard limitations (paired closing tags) so I don’t think we could interrupt at arbitrary points. The breaks would need to happen between sections.

A few different approaches come to mind thinking about it:

  1. Outlets. “The Content” element (what is actually used in the Layout Builder) could accept child elements. Then the Page itself would have an “Outlet” element somewhere. When that is encountered, it would output the elements passed in from the Layout. This is similar to how in React (and other component based DOM construction systems) allow creation of components that accept children.
  2. We add a setting to “The Content” that allows choosing a number of sections. It would be kinda like a Consumer where you can consume N or All items. That way your Layout Could insert content inbetween.
  3. Similarly, we could add a Looper Provider for “Content Elements” and it would loop over the top level elements and output the markup of each section.

Unfortunately, any of these options are pretty involved to create and would mean some invasive changes so it’s definitely something we’ll need to have some more use cases compiled to be worth the development investment. I can definitely see the benefit in any of the above options though.

2 Likes