test

{{- page.content -}} {%- form 'contact', class: 'Form Form--spacingTight' -%} {%- if form.posted_successfully? -%}

{{ 'contact.form.successfully_sent' | t }}

{%- endif -%} {%- if form.errors -%}
    {%- for field in form.errors -%} {%- if field == 'form' -%}
  • {{ form.errors.messages[field] }}
  • {%- else -%}
  • {{ form.errors.translated_fields[field] }} {{ form.errors.messages[field] }}
  • {%- endif -%} {%- endfor -%}
{%- endif -%}
{%- for block in section.blocks -%} {%- assign field_title = block.settings.title -%} {%- if field_title == blank -%} {%- capture field_title -%}Custom field {% increment custom_field %}{%- endcapture -%} {%- endif -%} {%- if block.type == 'text' -%}
{%- if block.settings.use_long_text -%} {%- else -%} {%- endif -%}
{%- elsif block.type == 'dropdown' -%} {%- assign values = block.settings.values | split: ',' -%} {%- if values == empty -%} {%- continue -%} {%- endif -%}
{%- render 'icon' with 'select-arrow' -%}
{%- endif -%} {%- endfor -%}
{%- endform -%}
{% schema %} { "name": "Contact page", "settings": [], "blocks": [ { "type": "text", "name": "Text field", "settings": [ { "type": "text", "id": "title", "label": "Name", "default": "Custom field" }, { "type": "checkbox", "id": "use_long_text", "label": "Use long text", "default": false }, { "type": "checkbox", "id": "is_required", "label": "Field is required", "default": false } ] }, { "type": "dropdown", "name": "Dropdown", "settings": [ { "type": "text", "id": "title", "label": "Name", "default": "Custom field" }, { "type": "text", "id": "values", "label": "Values", "info": "Separate each value by a comma.", "default": "value 1, value 2, value 3" } ] } ], "default": { "blocks": [ { "type": "text", "settings": { "title": "Your phone (optional)" } } ] } } {% endschema %}