I’ve added the below code to make a testimonial multicolumn but since I’ve added it, it’s also changed the style of the other multicolumns. Is there any way of editing the code so it only effects the one multicolumn I intended it to, and not the others.
Any advice is really appreciated.
URL: https://tyton.uk/
Dawn theme
{{ ‘section-multicolumn.css’ | asset_url | stylesheet_tag }}
{{ 'component-slider.css' | asset_url | stylesheet_tag }} {% style %} .multicolumn { padding: 35px 0px; background: {{ section.settings.testimonial_section_background }}; } .reviews { color: {{ section.settings.star_color }}; } .multicolumn-card { background: {{ section.settings.testimonial_background }}; padding: 20px; box-shadow: 0 1px 6px 0 rgb(32 33 36 / 28%); } @media only screen and (max-width: 800px) { .multicolumn-list__item.slider__slide { width: 90%; } } {% endstyle %}{{ section.settings.title | escape }}
{{ section.settings.subtitle | escape }}
{%- endif -%}-
{%- liquid
assign highest_ratio = 0
for block in section.blocks
if block.settings.image.aspect_ratio > highest_ratio
assign highest_ratio = block.settings.image.aspect_ratio
endif
endfor
-%}
{%- for block in section.blocks -%}
-
{%- if block.settings.image != blank -%} {% if section.settings.image_ratio == 'adapt' or section.settings.image_ratio == 'circle' %} {% assign spaced_image = true %} {% endif %} {% if block.settings.toggle_image == true %}{%- endif -%} {%- endif -%}
{%- if block.settings.text != blank -%}
{{ block.settings.text }}{%- endif -%} {%- if block.settings.title != blank -%}{{ block.settings.title | escape }}
{%- endif -%} {% if block.settings.toggle_review_stars == true %}{%- endif -%}{% if block.settings.stars_count == "5" %} {%- elsif block.settings.stars_count == "4.5" -%} {%- elsif block.settings.stars_count == "4" -%} {%- elsif block.settings.stars_count == "3" -%} {%- elsif block.settings.stars_count == "2" -%} {%- endif -%}
{%- endfor -%}
{%- if section.settings.swipe_on_mobile -%}
{% schema %}
{
“name”: “Testimonials”,
“class”: “spaced-section spaced-section–full-width”,
“tag”: “section”,
“settings”: [
{
“type”: “text”,
“id”: “title”,
“default”: “Testimonials”,
“label”: “t:sections.multicolumn.settings.title.label”
},
{
“type”: “text”,
“id”: “subtitle”,
“label”: “Sub heading”,
“default”: “Get inspired by other customers”
},
{
“type”: “select”,
“id”: “heading_alignment”,
“options”: [
{
“value”: “left”,
“label”: “t:sections.multicolumn.settings.column_alignment.options__1.label”
},
{
“value”: “center”,
“label”: “t:sections.multicolumn.settings.column_alignment.options__2.label”
}
],
“default”: “left”,
“label”: “Heading alignment”
},
{
“type”: “select”,
“id”: “image_width”,
“options”: [
{
“value”: “third”,
“label”: “t:sections.multicolumn.settings.image_width.options__1.label”
},
{
“value”: “half”,
“label”: “t:sections.multicolumn.settings.image_width.options__2.label”
},
{
“value”: “full”,
“label”: “t:sections.multicolumn.settings.image_width.options__3.label”
}
],
“default”: “full”,
“label”: “t:sections.multicolumn.settings.image_width.label”
},
{
“type”: “select”,
“id”: “image_ratio”,
“options”: [
{
“value”: “adapt”,
“label”: “t:sections.multicolumn.settings.image_ratio.options__1.label”
},
{
“value”: “portrait”,
“label”: “t:sections.multicolumn.settings.image_ratio.options__2.label”
},
{
“value”: “square”,
“label”: “t:sections.multicolumn.settings.image_ratio.options__3.label”
},
{
“value”: “circle”,
“label”: “t:sections.multicolumn.settings.image_ratio.options__4.label”
}
],
“default”: “adapt”,
“label”: “t:sections.multicolumn.settings.image_ratio.label”
},
{
“type”: “select”,
“id”: “column_alignment”,
“options”: [
{
“value”: “left”,
“label”: “t:sections.multicolumn.settings.column_alignment.options__1.label”
},
{
“value”: “center”,
“label”: “t:sections.multicolumn.settings.column_alignment.options__2.label”
}
],
“default”: “left”,
“label”: “t:sections.multicolumn.settings.column_alignment.label”
},
{
“type”: “select”,
“id”: “background_style”,
“options”: [
{
“value”: “none”,
“label”: “t:sections.multicolumn.settings.background_style.options__1.label”
},
{
“value”: “primary”,
“label”: “t:sections.multicolumn.settings.background_style.options__2.label”
},
{
“value”: “secondary”,
“label”: “t:sections.multicolumn.settings.background_style.options__3.label”
}
],
“default”: “primary”,
“label”: “t:sections.multicolumn.settings.background_style.label”
},
{
“type”: “checkbox”,
“id”: “swipe_on_mobile”,
“default”: false,
“label”: “t:sections.multicolumn.settings.swipe_on_mobile.label”
},
{
“type”: “color”,
“id”: “star_color”,
“label”: “Star color”,
“default”: “#ffcc33”
},
{
“type”: “color”,
“id”: “testimonial_background”,
“label”: “Testimonial background”,
“default”: “#ffffff”
},
{
“type”: “color”,
“id”: “testimonial_section_background”,
“label”: “Section background”,
“default”: “#eaeaea”
}
],
“blocks”: [
{
“type”: “column”,
“name”: “Customer”,
“settings”: [
{
“type”: “image_picker”,
“id”: “image”,
“label”: “t:sections.multicolumn.blocks.column.settings.image.label”
},
{
“type”: “checkbox”,
“id”: “toggle_image”,
“default”: true,
“label”: “Show/Hide”
},
{
“type”: “text”,
“id”: “title”,
“default”: “Full Name”,
“label”: “Customer”
},
{
“type”: “richtext”,
“id”: “text”,
“default”: “
Pair text with an image to focus on your chosen product, collection, or blog post. Add details on availability, style, or even provide a review.
”,“label”: “Feedback”
},
{
“type”: “select”,
“id”: “stars_count”,
“options”: [
{
“value”: “5”,
“label”: “5”
},
{
“value”: “4.5”,
“label”: “4.5”
},
{
“value”: “4”,
“label”: “4”
},
{
“value”: “3”,
“label”: “3”
},
{
“value”: “2”,
“label”: “2”
}
],
“default”: “5”,
“label”: “Stars count”
},
{
“type”: “checkbox”,
“id”: “toggle_review_stars”,
“default”: true,
“label”: “Show stars”
}
]
}
],
“presets”: [
{
“name”: “Testimonials”,
“blocks”: [
{
“type”: “column”
},
{
“type”: “column”
},
{
“type”: “column”
}
]
}
]
}
{% endschema %}