Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
I want to hide '0-5' and '4M' collections from Collections/all page. This is my current code, any help would be appreciated.
{% assign using_linklist = false %}
{% assign pagination = 12 %}
{% assign linklist = 'all-collections' %}
{% if linklists[linklist] and linklists[linklist].links.size > 0 %}
{% assign using_linklist = true %}
{% endif %}
{% render 'breadcrumbs' %}
<script type="application/pxs-animation-mapping+json">
{
"blocks": [".collection__item"],
"elements": [
".collection__item-info"
]
}
</script>
{% style %}
#shopify-section-{{ section.id }} .collection-list__content {
grid-template-columns: repeat({{ section.settings.thumbnail_columns_desktop }}, minmax(0, 1fr));
}
@media only screen and (max-width: 860px) {
#shopify-section-{{ section.id }} .collection-list__content {
grid-template-columns: repeat({{ section.settings.thumbnail_columns_mobile }}, minmax(0, 1fr));
}
}
{% endstyle %}
<h1 class="visually-hidden">{{ 'general.breadcrumbs.collections' | t }}</h1>
{% paginate collections by pagination %}
<div class="collection-list__container">
<ul class="collection-list__content collection--image-crop-{{ section.settings.image-crop }}" data-layout="grid">
{% if using_linklist %}
{% for link in linklists[linklist].links %}
{% assign link_handle = link.handle %}
{% assign collection = collections[link_handle] %}
{% render 'collection-list-item', collection: collection %}
{% endfor %}
{% else %}
{% for collection in collections %}
{% render 'collection-list-item', collection: collection %}
{% endfor %}
{% endif %}
</div>
</ul>
{% unless using_linklist %}
{%
render 'pagination',
paginate: paginate
%}
{% endunless %}
{% endpaginate %}
{% schema %}
{
"name": "t:sections.collections.name",
"class": "listcollections--section section--canonical",
"settings": [
{
"type": "range",
"id": "thumbnail_columns_desktop",
"label": "t:sections.collections.thumbnail_columns_desktop.label",
"min": 3,
"max": 6,
"step": 1,
"default": 5
},
{
"type": "range",
"id": "thumbnail_columns_mobile",
"label": "t:sections.collections.thumbnail_columns_mobile.label",
"min": 1,
"max": 3,
"step": 1,
"default": 2
},
{
"type": "select",
"id": "image-crop",
"label": "t:sections.collections.image-crop.label",
"info": "t:sections.collections.image-crop.info",
"options": [
{
"value": "original",
"label": "t:sections.collections.image-crop.option_1"
},
{
"value": "circle",
"label": "t:sections.collections.image-crop.option_2"
},
{
"value": "round",
"label": "t:sections.collections.image-crop.option_3"
}
]
}
]
}
{% endschema %}
Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025