Hi,
I have added a custom liquid section to my theme (Studio) to display partner logos. The code was taken from shopify blog.
I now need help to add padding to this section, as its currently full page width, whereas all other sections within the theme have thick padding on left and right - see barnochata.com (bottom of home page).
Code as added to the theme:
## {{ section.settings.title | escape }}
{% if section.blocks.size > 0 %}
{% for block in section.blocks %}
- {% if block.settings.link != blank %}
{% endif %}
{% if block.settings.image != blank %}
{{ block.settings.image | img_url: '150x150', scale: 2 | img_tag: block.settings.image.alt, 'logo-bar__image' }}
{% else %}
{{ 'logo' | placeholder_svg_tag: 'placeholder-svg' }}
{% endif %}
{% if block.settings.link != blank %}
{% endif %}
{% endfor %}
{% endif %}
{% schema %}
{
"name": "Logo list",
"class": "index-section",
"max_blocks": 15,
"settings": [
{
"type": "text",
"id": "title",
"label": "Heading",
"default": "Logo list"
},
{
"type": "select",
"id": "logo_width",
"label": "Logo width",
"default": "150px",
"options": [
{
"label": "Extra Small",
"value": "100px"
},
{
"label": "Small",
"value": "125px"
},
{
"label": "Medium",
"value": "150px"
},
{
"label": "Large",
"value": "175px"
},
{
"label": "Extra Large",
"value": "200px"
}
]
}
],
"blocks": [
{
"type": "logo_image",
"name": "Logo",
"settings": [
{
"type": "image_picker",
"id": "image",
"label": "Image"
},
{
"type": "url",
"id": "link",
"label": "Link",
"info": "Optional"
}
]
}
],
"presets": [
{
"name": "Logo list",
"category": "Image",
"blocks": [
{
"type": "logo_image"
},
{
"type": "logo_image"
},
{
"type": "logo_image"
},
{
"type": "logo_image"
}
]
}
]
}
{% endschema %}