Skip to content

Commit

Permalink
address review comment about overlap and transparency
Browse files Browse the repository at this point in the history
  • Loading branch information
ludoboludo committed Oct 4, 2023
1 parent 839747b commit 7f73d7e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions sections/image-with-text.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
if section.index == 1
assign fetch_priority = 'high'
endif
if section.settings.color_scheme != section.settings.section_color_scheme
assign add_color_classes = true
if section.settings.color_scheme == section.settings.section_color_scheme and section.settings.content_layout == 'no-overlap'
assign remove_color_classes = true
endif
-%}

Expand All @@ -30,7 +30,7 @@
<div class="image-with-text__grid grid grid--gapless grid--1-col grid--{% if section.settings.desktop_image_width == 'medium' %}2-col-tablet{% else %}3-col-tablet{% endif %}{% if section.settings.layout == 'text_first' %} image-with-text__grid--reverse{% endif %}">
<div class="image-with-text__media-item image-with-text__media-item--{{ section.settings.desktop_image_width }} image-with-text__media-item--{{ section.settings.desktop_content_position }} grid__item">
<div
class="image-with-text__media image-with-text__media--{{ section.settings.height }} global-media-settings{% if add_color_classes %} gradient color-{{ section.settings.color_scheme }}{% else %} background-transparent{% endif %}{% if section.settings.image != blank %} media{% else %} image-with-text__media--placeholder placeholder{% endif %}{% if section.settings.image_behavior != 'none' %} animate--{{ section.settings.image_behavior }}{% endif %}"
class="image-with-text__media image-with-text__media--{{ section.settings.height }} global-media-settings{% unless remove_color_classes %} gradient color-{{ section.settings.color_scheme }}{% else %} background-transparent{% endunless %}{% if section.settings.image != blank %} media{% else %} image-with-text__media--placeholder placeholder{% endif %}{% if section.settings.image_behavior != 'none' %} animate--{{ section.settings.image_behavior }}{% endif %}"
{% if section.settings.height == 'adapt' and section.settings.image != blank %}
style="padding-bottom: {{ 1 | divided_by: section.settings.image.aspect_ratio | times: 100 }}%;"
{% endif %}
Expand Down Expand Up @@ -62,7 +62,7 @@
<div class="image-with-text__text-item grid__item">
<div
id="ImageWithText--{{ section.id }}"
class="image-with-text__content image-with-text__content--{{ section.settings.desktop_content_position }} image-with-text__content--desktop-{{ section.settings.desktop_content_alignment }} image-with-text__content--mobile-{{ section.settings.mobile_content_alignment }} image-with-text__content--{{ section.settings.height }} content-container{% if add_color_classes %} gradient color-{{ section.settings.color_scheme }}{% else %} background-transparent{% endif %}"
class="image-with-text__content image-with-text__content--{{ section.settings.desktop_content_position }} image-with-text__content--desktop-{{ section.settings.desktop_content_alignment }} image-with-text__content--mobile-{{ section.settings.mobile_content_alignment }} image-with-text__content--{{ section.settings.height }} content-container{% unless remove_color_classes %} gradient color-{{ section.settings.color_scheme }}{% else %} background-transparent{% endunless %}"
>
{%- for block in section.blocks -%}
{% case block.type %}
Expand Down

0 comments on commit 7f73d7e

Please sign in to comment.