HubSpot Ideas

Anton

control modules availibilty via theme settings

As many of you know themes can come with a lot of modules which may not be used by the marketers. If they don't use it parts of it shouldn't be rendered to achieve smaller CSS/JS.

 

It would be great if the developers could access the "is_availible_for_new_content" from the modules meta.json via the themes fields.json file. 

 

possible usecase:

An accordion module with multiple settings in the theme fields.json (background color, padding...)

 

The CSS part looks currently something like this 

 

 

.accordion{
background: {{theme.modules.accordion.background.color}};
padding: {{theme.modules.accordion.vert_padding + 'rem'}} {{theme.modules.accordion.vert_padding + 'rem'}}
...
}

 

 

 

A developer can disable/enable the whole part with a boolean and an if-statement. But this doesn't have an impact on the module usability - therefore it's not really needed.

 

Would be great if the devs could change the module meta.json like this

 

"is_available_for_new_content" : {{theme.modules.accordion.toggle_visibility}}