Sha256: eea078e1fdd415381c907c780d6ddfc059c838f8d824b8264338c5b116f4106f

Contents?: true

Size: 1.71 KB

Versions: 13

Compression:

Stored size: 1.71 KB

Contents

---
{
  "name": "header",
  "category": "header",
  "class": "section-header",
  "settings": [
    {
      "id": "brand",
      "type": "text",
      "label": "Text to display in the header",
      "default": "Header"
    },
    {
      "id": "logo",
      "type": "image_picker",
      "label": "Logo",
      "default": "/images/logo.png"
    }
  ],
  "blocks": [
    {
      "type": "link",
      "settings": [
        {
          "id": "label",
          "type": "text",
          "label": "Label",
          "default": "Link"
        },
        {
          "id": "url",
          "type": "url",
          "label": "Url",
          "default": "https://www.locomotivecms.com"
        },
        {
          "id": "new_tab",
          "type": "checkbox",
          "label": "Open in a new tab?",
          "default": true
        }
      ]
    }
  ],
  "default": {
    "settings": {
      "brand": "MY COMPANY"
    },
    "blocks": [
      {
        "type": "link",
        "settings":
        {
          "label": "Link #1",
          "url": "https://www.nocoffee.fr",
          "new_tab": true
        }
      },
      {
        "type": "link",
        "settings":
        {
          "label": "Link #2",
          "url": "https://www.nocoffee.fr",
          "new_tab": true
        }
      },
      {
        "type": "link"
      }
    ]
  },
  "dropzone_presets": [
    {
      "name": "Default header",
      "category": "Header",
      "use_default": true
    }
  ]
}
---
<h1> {{ section.settings.brand }} </h1>
<ul>
  {% for block in section.blocks %}
    <li>
      <a href="{{ block.settings.url }}" target="{% if block.settings.new_tab %}_blank{% endif %}">
        {{ block.settings.label }}
      </a>
    </li>
  {% endfor %}
</ul>

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
locomotivecms_steam-1.8.0.alpha2 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.8.0.alpha1 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.7.1 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.7.0 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.6.1 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.6.0 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.6.0.rc1 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.6.0.beta1 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.5.3 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.5.2 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.5.1 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.5.0 spec/fixtures/default/app/views/sections/header.liquid
locomotivecms_steam-1.5.0.rc1 spec/fixtures/default/app/views/sections/header.liquid