{% if item.type == “buttons” %}
<div class="buttons {{ item.style }}"> {% for button in item.content %} {% if button.link %} {% assign link = button.link %} {% include util/prepend_link.html %} <a class="button {{ button.style }}" href="{{ link }}"> {% else %} <a class="button {{ button.style }}"> {% endif %} {% if button.icon %} <span class="icon {{ button.icon.style }}"> <i class="fa {{ button.icon.name }}"></i> </span> {% endif %} <span>{{ button.content | newline_to_br }}</span> </a> {% comment %} button {% endcomment %} {% endfor %} </div> {% comment %} buttons {% endcomment %}
{% elsif item.type == “link” %}
{% assign link = item.link %} {% include util/prepend_link.html %} <a class="{{ item.style }}" href="{{ link }}"> {% include util/item_content.html %} </a>
{% elsif item.type == “image” %}
{% if item.link %} {% assign link = item.link %} {% include util/prepend_link.html %} <a href="{{ link }}"> {% assign link = item.file %} {% include util/prepend_link.html %} <img class="{{ item.style }}" src="{{ link }}" alt="{{ item.name }}" width="{{ item.width }}" height="{{ item.height }}"></img> </a> {% else %} {% assign link = item.file %} {% include util/prepend_link.html %} <img class="{{ item.style }}" src="{{ link }}" alt="{{ item.name }}" width="{{ item.width }}" height="{{ item.height }}"></img> {% endif %}
{% elsif item.type == “text” %}
<p class="{{ item.style }}"> {% include util/item_content.html %} </p>
{% elsif item.type == “icons” %}
<span class="icon {{ item.style }}"> <span class="fa-stack"> {% for icon in item.content %} <i class="fa {{ icon.name }} {{ icon.style }}"></i> {% endfor %} </span> {% comment %} span {% endcomment %} </span> {% comment %} span {% endcomment %}
{% endif %}