schema settings are displayed in default value when preview is done after saving a non default value

schema settings are displayed in default value when preview is done after saving a non default value

oesteban
Shopify Partner
6 0 0

I have this simple liquid template with a color property setting. On the editor the value selected is displayed when changed but when changes are saved and previewed, the value taken on the block {{ block.settings.button-color }} is always the default value.

 

What am I missing?

 

<!-- Display color values for debugging -->
<p>Button Color: {{ block.settings.button-color }}</p>

{% schema %}
{
"name": "Test",
"target": "section",
"settings": [
{ "type": "color", "id": "button-color", "label": "Button Color", "default": "#000000" }
]
}
{% endschema %}
Reply 1 (1)

oesteban
Shopify Partner
6 0 0

I found out the problem only impacts Dawn theme for some reason, I have not updated it or changed it in any way on my partner developer shop. Switching to a different theme fixed the problem.