I've been playing around with the idea of template modularization within the Hubspot COS, The idea being that you would create multiple layout and section options that are controlled via the page editor. Today I build this pretty simple example for a client project. I would really like some feedback.
What this does is:
1. allow you choose if you want to use a banner image
2. if yes, then allows you to choose if you want to use a block image or background image
3. if background image then allows you to choose if you want to use text inside the div using the background image.
There are 3 different size and align options.
The only thing I don't like with this idea is that, in the case where modules are added or removed from the page conditionally, you have to refresh the page in order to see the change in modules. At the moment I think this is the only draw back. This is one of the things I am hoping to get some feed back on.
I built this for an email template however it should work in a custom HTML/HubL module on any page, You'll just have to copy and paste the code into the template.
@Jsum, this is pretty unique. Have you thought about using custom modules to add even more customization? I've been seeing a lot of landing pages made out of only a flex-column, then users who don't know code can go in and add custom modules to build what they want. With a robust stylesheet, you should be able to keep everything sticking to the style guide pretty well.
I've never seen this type of modularization for an email template though, thanks for sharing!
Thanks, and yes @Ty I have used custom modules for this. In my opinion this is more robust, and if the ordering of modules and having to refresh on update could be solved this would be a much more user friendly option that is so scalable you could create hundreds of unique pages from one template.