Making a module inside an if statement visible to page editors


Hi there,

I’m working on an email template that has a {{rich_text}} module inside an if statement, like this:

{% boolean "show_bottom_callout" label="Show bottom callout", no_wrapper=True, export_to_template_context=True %}

{% if widget_data.show_bottom_callout.value == true %}
{% widget_block rich_text "bottom_callout_content" overrideable=True, label='Bottom callout content', no_wrapper=True  %}
{% widget_attribute "html" %}
{% end_widget_attribute %}
{% end_widget_block %}
{% endif %}

Now, when I use this template, the rich text module is not visible/editable until the boolean has been turned on, and the page has been refreshed. This adds confusion for an editor who might not be aware that the text is editable (after refresh).

Does anyone have a suggestion for how I can show the rich text module to editors even if the boolean is false?

Thanks for your help!