Skip to content

Commit

Permalink
Adjust card badge polish (#155)
Browse files Browse the repository at this point in the history
  • Loading branch information
tauthomas01 authored Jul 13, 2021
1 parent 5c7d933 commit 81561cc
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 14 deletions.
2 changes: 1 addition & 1 deletion assets/component-badge.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
font-size: 1.2rem;
letter-spacing: 0.1rem;
line-height: 1;
padding: 0.6rem 1.6rem;
padding: 0.6rem 1.3rem;
text-align: center;
background-color: rgb(var(--color-badge-background));
border-color: rgba(var(--color-badge-border), var(--alpha-badge-border));
Expand Down
2 changes: 1 addition & 1 deletion assets/template-giftcard.css
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ h2,
font-size: 1.2rem;
letter-spacing: 0.1rem;
line-height: 1;
padding: 0.6rem 1.6rem;
padding: 0.6rem 1.3rem;
text-align: center;
background-color: rgb(var(--color-base-background-1));
border-color: rgba(var(--color-base-text), 0.04);
Expand Down
8 changes: 2 additions & 6 deletions sections/collage.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -88,13 +88,9 @@
<div class="collage-product__badge">
<div class="card__badge">
{%- if block.settings.product.available == false -%}
<span class="badge badge--bottom-left color-{{ settings.sold_out_badge_color_scheme }}" aria-hidden="true">
{{ 'products.product.sold_out' | t }}
</span>
<span class="badge badge--bottom-left color-{{ settings.sold_out_badge_color_scheme }}" aria-hidden="true">{{ 'products.product.sold_out' | t }}</span>
{%- elsif block.settings.product.compare_at_price > block.settings.product.price and block.settings.product.available -%}
<span class="badge badge--bottom-left color-{{ settings.sale_badge_color_scheme }}" aria-hidden="true">
{{ 'products.product.on_sale' | t }}
</span>
<span class="badge badge--bottom-left color-{{ settings.sale_badge_color_scheme }}" aria-hidden="true">{{ 'products.product.on_sale' | t }}</span>
{%- endif -%}
</div>
</div>
Expand Down
8 changes: 2 additions & 6 deletions snippets/product-card.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,9 @@

<div class="card__badge">
{%- if product_card_product.available == false -%}
<span class="badge badge--bottom-left color-{{ settings.sold_out_badge_color_scheme }}" aria-hidden="true">
{{ 'products.product.sold_out' | t }}
</span>
<span class="badge badge--bottom-left color-{{ settings.sold_out_badge_color_scheme }}" aria-hidden="true">{{ 'products.product.sold_out' | t }}</span>
{%- elsif product_card_product.compare_at_price > product_card_product.price and product_card_product.available -%}
<span class="badge badge--bottom-left color-{{ settings.sale_badge_color_scheme }}" aria-hidden="true">
{{ 'products.product.on_sale' | t }}
</span>
<span class="badge badge--bottom-left color-{{ settings.sale_badge_color_scheme }}" aria-hidden="true">{{ 'products.product.on_sale' | t }}</span>
{%- endif -%}
</div>
</div>
Expand Down

0 comments on commit 81561cc

Please sign in to comment.