/** Shopify CDN: Minification failed

Line 16:0 Unexpected "{"
Line 16:1 Unexpected "{"
Line 16:3 Expected identifier but found "'section-rich-text.css'"
Line 18:0 Unexpected "{"
Line 18:1 Expected identifier but found "%"
Line 19:10 Unexpected "{"
Line 19:19 Expected ":"
Line 20:14 Expected identifier but found whitespace
Line 20:16 Unexpected "{"
Line 20:25 Expected ":"
... and 72 more hidden warnings

**/
{{ 'section-rich-text.css' | asset_url | stylesheet_tag }}

{% style %}
.section-{{ section.id }}-padding {
  padding-top: {{ section.settings.padding_top | times: 0.75 | round }}px;
  padding-bottom: {{ section.settings.padding_bottom | times: 0.75 | round }}px;
}
@media screen and (min-width: 750px) {
  .section-{{ section.id }}-padding {
    padding-top: {{ section.settings.padding_top }}px;
    padding-bottom: {{ section.settings.padding_bottom }}px;
  }
}
{% endstyle %}

<div class="
  rich-text-section
  color-{{ section.settings.color_scheme }}
  {% if section.settings.full_width %}rich-text--full-width{% else %}page-width{% endif %}
  section-{{ section.id }}-padding
">
  <div class="rich-text__wrapper rich-text__wrapper--{{ section.settings.desktop_content_position }}">
    <div class="rich-text__blocks {{ section.settings.content_alignment }}">
      {% for block in section.blocks %}
        {% case block.type %}
        
        {% when 'heading' %}
          <{{ block.settings.heading_tag }}
            class="rich-text__heading inline-richtext"
            style="color: {{ block.settings.text_color }};"
          >
            {{ block.settings.heading }}
          </{{ block.settings.heading_tag }}>
        
        {% when 'caption' %}
          <p class="rich-text__caption {{ block.settings.text_style }}--{{ block.settings.text_size }}"
             style="color: {{ block.settings.text_color }};">
            {{ block.settings.caption }}
          </p>
        
        {% when 'text' %}
          <div class="rich-text__text rte" style="color: {{ block.settings.text_color }};">
            {{ block.settings.text }}
          </div>
        
        {% when 'button' %}
          <div class="rich-text__buttons">
            {% if block.settings.button_label != blank %}
              <a href="{{ block.settings.button_link }}"
                 class="button {% if block.settings.button_style_secondary %}button--secondary{% else %}button--primary{% endif %}"
                 style="background-color: {{ block.settings.button_bg_color }}; color: {{ block.settings.button_text_color }};"
              >
                {{ block.settings.button_label }}
              </a>
            {% endif %}
          </div>
        
        {% endcase %}
      {% endfor %}
    </div>
  </div>
</div>

{% schema %}
{
  "name": "Enhanced Rich Text",
  "settings": [
    {
      "type": "select",
      "id": "desktop_content_position",
      "label": "Positie inhoud (desktop)",
      "options": [
        { "value": "left", "label": "Links" },
        { "value": "center", "label": "Midden" },
        { "value": "right", "label": "Rechts" }
      ],
      "default": "center"
    },
    {
      "type": "select",
      "id": "content_alignment",
      "label": "Inhoud uitlijning",
      "options": [
        { "value": "left", "label": "Links" },
        { "value": "center", "label": "Midden" },
        { "value": "right", "label": "Rechts" }
      ],
      "default": "center"
    },
    {
      "type": "color_scheme",
      "id": "color_scheme",
      "label": "Sectie kleurenschema",
      "default": "scheme-1"
    },
    {
      "type": "checkbox",
      "id": "full_width",
      "label": "Volledige breedte",
      "default": false
    },
    {
      "type": "range",
      "id": "padding_top",
      "label": "Padding boven",
      "min": 0,
      "max": 100,
      "step": 4,
      "unit": "px",
      "default": 40
    },
    {
      "type": "range",
      "id": "padding_bottom",
      "label": "Padding onder",
      "min": 0,
      "max": 100,
      "step": 4,
      "unit": "px",
      "default": 40
    }
  ],
  "blocks": [
    {
      "type": "heading",
      "name": "Kop",
      "settings": [
        {
          "type": "inline_richtext",
          "id": "heading",
          "label": "Tekst"
        },
        {
          "type": "select",
          "id": "heading_tag",
          "label": "Kopniveau",
          "options": [
            { "value": "h1", "label": "H1" },
            { "value": "h2", "label": "H2" },
            { "value": "h3", "label": "H3" },
            { "value": "h4", "label": "H4" }
          ],
          "default": "h2"
        },
        {
          "type": "color",
          "id": "text_color",
          "label": "Tekstkleur",
          "default": "#000000"
        }
      ]
    },
    {
      "type": "caption",
      "name": "Subtekst",
      "settings": [
        {
          "type": "text",
          "id": "caption",
          "label": "Tekst"
        },
        {
          "type": "select",
          "id": "text_style",
          "label": "Stijl",
          "options": [
            { "value": "subtitle", "label": "Subtitle" },
            { "value": "caption-with-letter-spacing", "label": "Caption gespatieerd" }
          ],
          "default": "subtitle"
        },
        {
          "type": "select",
          "id": "text_size",
          "label": "Grootte",
          "options": [
            { "value": "small", "label": "Klein" },
            { "value": "medium", "label": "Middel" },
            { "value": "large", "label": "Groot" }
          ],
          "default": "medium"
        },
        {
          "type": "color",
          "id": "text_color",
          "label": "Tekstkleur",
          "default": "#444444"
        }
      ]
    },
    {
      "type": "text",
      "name": "Paragraaf",
      "settings": [
        {
          "type": "richtext",
          "id": "text",
          "label": "Inhoud"
        },
        {
          "type": "color",
          "id": "text_color",
          "label": "Tekstkleur",
          "default": "#333333"
        }
      ]
    },
    {
      "type": "button",
      "name": "Knop",
      "settings": [
        {
          "type": "text",
          "id": "button_label",
          "label": "Knoptekst"
        },
        {
          "type": "url",
          "id": "button_link",
          "label": "Link"
        },
        {
          "type": "checkbox",
          "id": "button_style_secondary",
          "label": "Secundaire stijl",
          "default": false
        },
        {
          "type": "color",
          "id": "button_bg_color",
          "label": "Achtergrondkleur knop",
          "default": "#4c5c4f"
        },
        {
          "type": "color",
          "id": "button_text_color",
          "label": "Tekstkleur knop",
          "default": "#ffffff"
        }
      ]
    }
  ],
  "presets": [
    {
      "name": "Enhanced Rich Text",
      "blocks": [
        { "type": "heading" },
        { "type": "text" },
        { "type": "button" }
      ]
    }
  ]
}
{% endschema %}
