Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adjust color contrast for Vendor on the cart page #1462

Merged
merged 6 commits into from
Mar 16, 2022
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion assets/base.css
Original file line number Diff line number Diff line change
Expand Up @@ -566,7 +566,7 @@ table:not([class]) th {
}

.light {
opacity: 0.7;
opacity: 0.75;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the color applied to the body is already using a .75 opacity. So I will change the approach as this is currently just a repetition of what was already there in the first place 🤔

}

a:empty,
Expand Down
5 changes: 1 addition & 4 deletions assets/component-cart-items.css
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
}

.cart-item__details {
color: rgb(var(--color-foreground));
font-size: 1.6rem;
line-height: calc(1 + 0.4 / var(--font-body-scale));
}
Expand Down Expand Up @@ -193,10 +194,6 @@ cart-remove-button .icon-remove {
display: none;
}

.product-option {
color: rgba(var(--color-foreground), 0.7);
}

.product-option + .product-option {
margin-top: 0.4rem;
}
Expand Down
1 change: 1 addition & 0 deletions assets/component-cart-notification.css
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@
}

.cart-notification-product {
color: rgb(var(--color-foreground));
align-items: flex-start;
display: flex;
padding-bottom: 3rem;
Expand Down
6 changes: 3 additions & 3 deletions sections/cart-notification-product.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<dl>
{%- unless item.product.has_only_default_variant -%}
{%- for option in item.options_with_values -%}
<div class="product-option">
<div class="product-option light">
<dt>{{ option.name }}: </dt>
<dd>{{ option.value }}</dd>
</div>
Expand All @@ -26,7 +26,7 @@
{%- for property in item.properties -%}
{%- assign property_first_char = property.first | slice: 0 -%}
{%- if property.last != blank and property_first_char != '_' -%}
<div class="product-option">
<div class="product-option light">
<dt>{{ property.first }}: </dt>
<dd>
{%- if property.last contains '/uploads/' -%}
Expand All @@ -42,7 +42,7 @@
{%- endfor -%}
</dl>
{%- if item.selling_plan_allocation != nil -%}
<p class="product-option">{{ item.selling_plan_allocation.selling_plan.name }}</p>
<p class="product-option light">{{ item.selling_plan_allocation.selling_plan.name }}</p>
{%- endif -%}
</div>
</div>
Expand Down
12 changes: 6 additions & 6 deletions sections/main-cart-items.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -86,18 +86,18 @@
<span class="visually-hidden">
{{ 'products.product.price.regular_price' | t }}
</span>
<s class="cart-item__old-price product-option">
<s class="cart-item__old-price product-option light">
{{- item.original_price | money -}}
</s>
<span class="visually-hidden">
{{ 'products.product.price.sale_price' | t }}
</span>
<strong class="cart-item__final-price product-option">
<strong class="cart-item__final-price product-option light">
{{ item.final_price | money }}
</strong>
</div>
{%- else -%}
<div class="product-option">
<div class="product-option light">
{{ item.original_price | money }}
</div>
{%- endif -%}
Expand All @@ -106,7 +106,7 @@
<dl>
{%- if item.product.has_only_default_variant == false -%}
{%- for option in item.options_with_values -%}
<div class="product-option">
<div class="product-option light">
<dt>{{ option.name }}: </dt>
<dd>{{ option.value }}</dd>
</div>
Expand All @@ -116,7 +116,7 @@
{%- for property in item.properties -%}
{%- assign property_first_char = property.first | slice: 0 -%}
{%- if property.last != blank and property_first_char != '_' -%}
<div class="product-option">
<div class="product-option light">
<dt>{{ property.first }}: </dt>
<dd>
{%- if property.last contains '/uploads/' -%}
Expand All @@ -132,7 +132,7 @@
{%- endfor -%}
</dl>

<p class="product-option">{{ item.selling_plan_allocation.selling_plan.name }}</p>
<p class="product-option light">{{ item.selling_plan_allocation.selling_plan.name }}</p>
{%- endif -%}

<ul class="discounts list-unstyled" role="list" aria-label="{{ 'customer.order.discount' | t }}">
Expand Down