Anchor to Referencing color_scheme_group settings directly
Referencing color_scheme_group settings directly
{% for scheme in settings.color_schemes %}
.color-{{ scheme.id }} {
--color-background: {{ scheme.settings.background }};
--color-text: {{ scheme.settings.text }};
}
{% endfor %}
{% for scheme in settings.color_schemes %}
.color-{{ scheme.id }} {
--color-background: {{ scheme.settings.background }};
--color-text: {{ scheme.settings.text }};
}
{% endfor %}
{
"settings": {
"color_schemes": {}
}
}
Output
.color-background-1 {
--color-background: #FFFFFF;
--color-text: #121212;
}
.color-background-2 {
--color-background: #F3F3F3;
--color-text: #121212;
}
.color-inverse {
--color-background: #121212;
--color-text: #FFFFFF;
}
.color-accent-1 {
--color-background: #121212;
--color-text: #FFFFFF;
}
.color-accent-2 {
--color-background: #334FB4;
--color-text: #FFFFFF;
}
Was this section helpful?