Guest Posted April 30, 2021 Share Posted April 30, 2021 Site URL: https://modernbusiness.squarespace.com Hey. Squarespace breaks this into one column on mobile. But I would like the images to display in two columns. I have a multiple pages of the same. Is there a way to do that? Link to comment
Solution tuanphan Posted May 1, 2021 Solution Share Posted May 1, 2021 Add to Design > Custom CSS /* Products 2 columns */ @media screen and (max-width:767px) { div#block-yui_3_17_2_1_1618893896866_14059 ~ .row .span-3 { width: 50% !important; float: left !important; } div#block-yui_3_17_2_1_1618893896866_14059 ~ .row .span-3:nth-child(2n+1) { clear: left !important; } } Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message How to: Setup Password & Share url - Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care Link to comment
Guest Posted May 1, 2021 Share Posted May 1, 2021 5 hours ago, tuanphan said: Add to Design > Custom CSS /* Products 2 columns */ @media screen and (max-width:767px) { div#block-yui_3_17_2_1_1618893896866_14059 ~ .row .span-3 { width: 50% !important; float: left !important; } div#block-yui_3_17_2_1_1618893896866_14059 ~ .row .span-3:nth-child(2n+1) { clear: left !important; } } Thank you. Link to comment
Guest Posted May 2, 2021 Share Posted May 2, 2021 Hey @tuanphan. How can I make that it works on multiple pages? https://modernbusiness.squarespace.com/categories/accessories https://modernbusiness.squarespace.com/categories/toiletries etc. Basically, I have the same thing on numerous pages. Link to comment
tuanphan Posted May 4, 2021 Share Posted May 4, 2021 On 5/2/2021 at 10:30 PM, kristobans said: Hey @tuanphan. How can I make that it works on multiple pages? https://modernbusiness.squarespace.com/categories/accessories https://modernbusiness.squarespace.com/categories/toiletries etc. Basically, I have the same thing on numerous pages. Each page needs a different code. If you use Summary or Gallery block, we can target easier with 1 code /* Mobile 2 columns products */ @media screen and (max-width:767px) { /* accessories */ div#block-yui_3_17_2_1_1619418261951_140576+.row .span-3 { width: 50% !important; float: left !important; } div#block-yui_3_17_2_1_1619418261951_140576+.row .span-3:nth-child(2n+1) { clear: left !important; } /* toiletries */ div#block-yui_3_17_2_1_1619424383691_34796+.row .span-3 { width: 50% !important; float: left !important; } div#block-yui_3_17_2_1_1619424383691_34796+.row .span-3:nth-child(2n+1) { clear: left !important; } } Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message How to: Setup Password & Share url - Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care Link to comment
Guest Posted May 4, 2021 Share Posted May 4, 2021 5 hours ago, tuanphan said: Each page needs a different code. If you use Summary or Gallery block, we can target easier with 1 code /* Mobile 2 columns products */ @media screen and (max-width:767px) { /* accessories */ div#block-yui_3_17_2_1_1619418261951_140576+.row .span-3 { width: 50% !important; float: left !important; } div#block-yui_3_17_2_1_1619418261951_140576+.row .span-3:nth-child(2n+1) { clear: left !important; } /* toiletries */ div#block-yui_3_17_2_1_1619424383691_34796+.row .span-3 { width: 50% !important; float: left !important; } div#block-yui_3_17_2_1_1619424383691_34796+.row .span-3:nth-child(2n+1) { clear: left !important; } } Hey. Thank you. I've changed the code for each page. It's easier at this point. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment