Sorry the code before was from collection-item.liquid
The code for main-collection-product-grid.liquid is here:
{%- liquid
assign paginated = false
if section.settings.pagination == 'paginated'
assign paginated = true
endif
assign per_page = section.settings.rows | times: section.settings.columns
assign filter_bar_enabled = false
if section.settings.show_item_count or section.settings.show_sort or section.settings.show_filters
assign filter_bar_enabled = true
endif
-%}
{% schema %}
{
"name": "t:sections.main_collection_product_grid.name",
"class": "collection-section",
"settings": [
{
"type": "header",
"content": "t:sections.main_collection_product_grid.settings.collection__header.content"
},
{
"type": "select",
"id": "columns",
"label": "t:sections.collection_sections_shared.settings.collection_columns.label",
"default": "4",
"options": [
{
"value": "2",
"label": "t:sections.collection_sections_shared.settings.columns.option_2"
},
{
"value": "3",
"label": "t:sections.collection_sections_shared.settings.columns.option_3"
},
{
"value": "4",
"label": "t:sections.collection_sections_shared.settings.columns.option_4"
},
{
"value": "5",
"label": "t:sections.collection_sections_shared.settings.columns.option_5"
}
]
},
{
"type": "select",
"id": "rows",
"label": "t:sections.collection_sections_shared.settings.rows.label",
"default": "4",
"options": [
{
"value": "3",
"label": "t:sections.collection_sections_shared.settings.rows.option_3"
},
{
"value": "4",
"label": "t:sections.collection_sections_shared.settings.rows.option_4"
},
{
"value": "5",
"label": "t:sections.collection_sections_shared.settings.rows.option_5"
},
{
"value": "6",
"label": "t:sections.collection_sections_shared.settings.rows.option_6"
},
{
"value": "7",
"label": "t:sections.collection_sections_shared.settings.rows.option_7"
},
{
"value": "8",
"label": "t:sections.collection_sections_shared.settings.rows.option_8"
},
{
"value": "9",
"label": "t:sections.collection_sections_shared.settings.rows.option_9"
},
{
"value": "10",
"label": "t:sections.collection_sections_shared.settings.rows.option_10"
}
]
},
{
"type": "checkbox",
"id": "show_item_count",
"label": "t:shared.settings.show_item_count.label",
"default": true
},
{
"type": "header",
"content": "t:shared.settings.filtering__header.content"
},
{
"id": "show_sort",
"type": "checkbox",
"label": "t:shared.settings.show_sort.label",
"default": true
},
{
"id": "show_filters",
"type": "checkbox",
"label": "t:shared.settings.show_filters.label",
"info": "t:shared.settings.show_filters.info",
"default": true
},
{
"type": "checkbox",
"id": "enable_sticky_filter_bar",
"label": "t:shared.settings.enable_sticky_filter_bar.label",
"default": true
},
{
"type": "checkbox",
"id": "collapse_filter_bar",
"label": "t:shared.settings.collapse_filter_bar.label",
"default": true
},
{
"type": "checkbox",
"id": "collapse_filter_groups_mobile",
"label": "t:shared.settings.collapse_filter_groups_mobile.label",
"default": true
},
{
"id": "show_swatch_filters",
"type": "checkbox",
"label": "t:shared.settings.show_swatch_filters.label",
"info": "t:shared.settings.show_swatch_filters.info",
"default": true
},
{
"id": "show_chip_filters",
"type": "checkbox",
"label": "t:shared.settings.show_chip_filters.label",
"info": "t:shared.settings.show_chip_filters.info",
"default": true
},
{
"type": "select",
"id": "chip_layout",
"label": "t:shared.settings.chip_layout.label",
"default": "3col",
"options": [
{
"value": "3col",
"label": "t:shared.settings.chip_layout.option_3col"
},
{
"value": "2col",
"label": "t:shared.settings.chip_layout.option_2col"
},
{
"value": "natural",
"label": "t:shared.settings.chip_layout.option_natural"
}
]
},
{
"type": "header",
"content": "t:shared.settings.pagination__header.content"
},
{
"type": "select",
"id": "pagination",
"label": "t:shared.settings.pagination.label",
"default": "paginated",
"options": [
{
"value": "infinite",
"label": "t:shared.settings.pagination.options__1"
},
{
"value": "click",
"label": "t:shared.settings.pagination.options__2"
},
{
"value": "paginated",
"label": "t:shared.settings.pagination.options__3"
}
],
"info": "t:sections.main_collection_product_grid.settings.pagination.info"
},
{
"type": "header",
"content": "t:sections.main_collection_product_grid.settings.style__header.content"
},
{
"id": "enable_animation",
"type": "checkbox",
"label": "t:shared.settings.section_style.enable_animation.label",
"info": "t:shared.settings.section_style.enable_animation.info",
"default": true
},
{
"type": "select",
"id": "divider_style",
"label": "t:shared.settings.section_style.divider_style.label",
"default": "none",
"options": [
{
"label": "t:shared.settings.section_style.divider_style.option_none",
"value": "none"
},
{
"label": "t:shared.settings.section_style.divider_style.option_solid",
"value": "solid"
}
]
}
]
}
{% endschema %}