We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more

Re: Increase number of section blocks allowed within collections (Galleria)

Increase number of section blocks allowed within collections (Galleria)

JKP84
Shopify Partner
35 0 14

hi - I am working on Galleria theme and i would like to increase the number of section blocks allowed on one of my collection templates. It currently stops at 20.

 

Previously, i have been able to find where to change this number within the code, but i am not familiar with the Galleria theme.

 

Can anyone help, the page i would like help on is: https://mojoandmuse.co.uk/collections/portfolio

(password: weuhai)

 

TIA

 

Jo

Replies 9 (9)

LitCommerce
Astronaut
2860 684 761

Hi @JKP84,

Go to sections > collection-list.liquid file, find 'max_blocks' and change code:

"max_blocks":12,

=>

"max_blocks":20,

Hope it helps!

LitCommerce - The Most Simple & Affordable Multi-channel Selling Tool.
Effortlessly sell on biggest marketplaces like Amazon, Etsy, eBay, Facebook etc with bulk listing tool, real-time sync & smart order management. Use LitCommerce free for 1-year now!
JKP84
Shopify Partner
35 0 14

Hi @LitCommerce 

thank you for your suggestion but that does not work - i am still restricted to 20 sections on a page. 
it is not the collection list - i have a new template in collections - this is what i am editing and won't let me increase the number of sections it can have.

LitCommerce
Astronaut
2860 684 761

Hi @JKP84,

Can you send me the code of the file, I will check it.

LitCommerce - The Most Simple & Affordable Multi-channel Selling Tool.
Effortlessly sell on biggest marketplaces like Amazon, Etsy, eBay, Facebook etc with bulk listing tool, real-time sync & smart order management. Use LitCommerce free for 1-year now!
JKP84
Shopify Partner
35 0 14

@LitCommerce which file do you need please?

LitCommerce
Astronaut
2860 684 761

Hi @JKP84,

The new template file you created earlier, it is limited to 20 blocks.

Or you can send me the screenshot of the notification. I will check it.

LitCommerce - The Most Simple & Affordable Multi-channel Selling Tool.
Effortlessly sell on biggest marketplaces like Amazon, Etsy, eBay, Facebook etc with bulk listing tool, real-time sync & smart order management. Use LitCommerce free for 1-year now!
JKP84
Shopify Partner
35 0 14

@LitCommerce sure, although after some reading up on this it seems to be a problem with the new 2.0 themes.. 

 

the template file is a json file so doesn't contain anything relevant i don't believe - it is a long file of all the info of the images and text i have uploaded.  

 

so i am including below the code from the collections-list.liquid file:

 

<link rel="stylesheet" href="{{ 'collection-card.css' | asset_url }}" media="print" onload="this.media='all'">
<noscript>{{ 'collection-card.css' | asset_url | stylesheet_tag }}</noscript>

{% capture Content %}
<div class="#grid @gap:{{ section.settings.gutter }} {% if section.settings.swipe_on_mobile %}@mobile-overlap{% else %}@mobile:columns:1{% endif %} @container @columns:{{ section.settings.columns }}">
{% assign placeholder_index = 1 %}
{% for block in section.blocks %}
{%- capture placeholder_index -%}{%- cycle 1, 2, 3, 4, 5, 6 -%}{%- endcapture -%}
<div class="#column reveal-animate" style="--reveal-index: {{ forloop.index }}">
{% render 'collection-card',
collection: block.settings.collection,
custom_image: block.settings.image,
placeholder_index: placeholder_index,
image_size: section.settings.image_size,
columns: section.settings.columns,
media_hover_zoom: section.settings.hover_zoom,
align: section.settings.text_align
%}
</div>
{% endfor %}
</div>
{% endcapture %}

{% if section.settings.show_section_button %}
{%- assign section_button = section.settings.section_button -%}
{% endif %}

{% render 'section-body',
content: Content,
container: false,
spaced: true,
title: section.settings.title,
subtitle: section.settings.subtitle,
button: section_button,
button_link: routes.collections_url,
color_scheme: section.settings.color_scheme
%}

{% schema %}
{
"name": "t:sections.collection-list.name",
"tag": "section",
"max_blocks": 25,
"settings": [
{
"type": "text",
"id": "title",
"default": "Collections",
"label": "t:sections.collection-list.settings.title.label"
},
{
"type": "text",
"id": "subtitle",
"label": "Subheading"
},
{
"type": "select",
"id": "color_scheme",
"options": [
{
"value": "default",
"label": "Default"
},
{
"value": "alt",
"label": "Alternate"
},
{
"value": "accent",
"label": "Accent"
},
{
"value": "invert",
"label": "Inverted"
}
],
"default": "alt",
"label": "Color scheme"
},
{
"type": "range",
"id": "columns",
"label": "Columns",
"min": 3,
"max": 6,
"step": 1,
"default": 5
},
{
"type": "select",
"id": "gutter",
"label": "Space between",
"options": [
{
"value": "sm",
"label": "Small"
},
{
"value": "md",
"label": "Medium"
},
{
"value": "lg",
"label": "Large"
}
],
"default": "md"
},
{
"type": "select",
"id": "text_align",
"label": "Text alignment",
"options": [
{
"value": "left",
"label": "Left"
},
{
"value": "center",
"label": "Center"
},
{
"value": "right",
"label": "Right"
}
],
"default": "center"
},
{
"type": "select",
"id": "image_size",
"options": [
{
"value": "circle",
"label": "Circle"
},
{
"value": "square",
"label": "Square"
},
{
"value": "landscape",
"label": "Landscape"
},
{
"value": "portrait",
"label": "Portrait"
}
],
"default": "circle",
"label": "Image style",
"info": "t:sections.collection-list.settings.image_ratio.info"
},
{
"type": "checkbox",
"id": "hover_zoom",
"default": true,
"label": "Enable image zoom on hover"
},
{
"type": "checkbox",
"id": "swipe_on_mobile",
"default": true,
"label": "Enable carousel on mobile",
"info": "Note: swipe functionality not active in theme editor"
},
{
"type": "header",
"content": "Button"
},
{
"type": "checkbox",
"id": "show_section_button",
"default": true,
"label": "Show button"
},
{
"type": "text",
"id": "section_button",
"label": "Button label",
"default": "All Collections"
}
],
"blocks": [
{
"type": "featured_collection",
"name": "t:sections.collection-list.blocks.featured_collection.name",
"settings": [
{
"type": "collection",
"id": "collection",
"label": "t:sections.collection-list.blocks.featured_collection.settings.collection.label"
},
{
"type": "image_picker",
"id": "image",
"label": "Custom image"
}
]
}
],
"presets": [
{
"name": "t:sections.collection-list.presets.name",
"blocks": [
{
"type": "featured_collection"
},
{
"type": "featured_collection"
},
{
"type": "featured_collection"
},
{
"type": "featured_collection"
},
{
"type": "featured_collection"
}
]
}
]
}
{% endschema %}

 

 

LitCommerce
Astronaut
2860 684 761

Hi @JKP84,

With store 2.0 generated by json it's limited to 16. Refer https://shopify.dev/themes/architecture/sections/section-schema#max_blocks

So if your theme is using shopify 2.0, it won't be possible. 

Hope it helps!

LitCommerce - The Most Simple & Affordable Multi-channel Selling Tool.
Effortlessly sell on biggest marketplaces like Amazon, Etsy, eBay, Facebook etc with bulk listing tool, real-time sync & smart order management. Use LitCommerce free for 1-year now!
JKP84
Shopify Partner
35 0 14

Thanks @LitCommerce -  i am using 2.0 - i saw this so realised it was a problem for many people. 

know of any plans to change this? seems to be quite a restriction for a lot of people.

 

thanks for your help!

LitCommerce
Astronaut
2860 684 761

Hi @JKP84,

Yes. It's a problem for many people but no one can edit it. 

You can just contact Shopify for support. Refer https://help.shopify.com/en/questions#/contact 

After receiving many comments, I think Shopify can update it for the next version.

If it helped you solve your issue, please mark it as a solution. Thank you and good luck.

LitCommerce - The Most Simple & Affordable Multi-channel Selling Tool.
Effortlessly sell on biggest marketplaces like Amazon, Etsy, eBay, Facebook etc with bulk listing tool, real-time sync & smart order management. Use LitCommerce free for 1-year now!