{% capture color_map %}Beige: #c7b299,
Black: #000000,
Blue: #095a80,
Brown: #543b24,
Green: #2b5f2a,
Orange: #ba6435,
Pink: #e294a7,
Purple: #493664,
Red: #9c3232,
White: #ffffff,
Yellow: #e0c02a,
Gray: #707070,
Miscellaneous: url(//cdn.shopify.com/s/files/1/0079/0459/1990/files/Volcom_Hex_MULTI.png?7608704333814782072),
Violet:#493664{% endcapture %}
{% assign color_map = color_map | split: ',' %}
{%- for option in set.options -%}
{%- assign swatch_bg = '' -%}
{%- for color in color_map -%}
{%- assign key = color | split: ':' | first | strip | handle -%}
{%- assign value = color | split: ':' | last | strip -%}
{%- assign option_handle = option.value | handle -%}
{%- if key == option_handle -%}
{%- assign swatch_bg = value -%}
{%- endif -%}
{%- endfor -%}
{%- endfor -%}
{% if set.range != nil %}
{% assign min = set.key | append: '.gte' %}
{% assign max = set.key | append: '.lte' %}
{% assign min_default_position = 0 %}
{% assign max_default_position = set.range_max | ceil %}
{% assign min_default_value = 0 | times: 100 | money %}
{% assign max_default_value = set.range_max | times: 100 | money %}
{% endif %}
{% assign max_count = 5 %}
{% assign max_count = max_count | times: 6 %}
{% if set.options.size > max_count %}
{% endif %}