Skip to content
This repository has been archived by the owner on Jul 18, 2024. It is now read-only.

YSHOP2-326 : COD v1 [Product column] Padding not working #284

Merged
merged 3 commits into from
Apr 11, 2023
Merged
Show file tree
Hide file tree
Changes from 2 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
16 changes: 10 additions & 6 deletions sections/product-column.liquid
Original file line number Diff line number Diff line change
@@ -1,23 +1,25 @@
{% assign id = 100 | rand: 2000 %}

{{ 'product-column.css' | asset_url | stylesheet_tag }}

{%- style -%}
.product_customization {
.product_customization-{{ id }} {
padding-top: {{ section.settings.padding_top}}px;
padding-bottom: {{ section.settings.padding_bottom}}px;
}

.product_customization {
.product_customization-{{ id }} {
background-color: {{ section.settings.background_color.hex }};
}

@media screen and (max-width: 768px) {
.product_customization {
.product_customization-{{ id }} {
display: {% if section.settings.show_product %}block{% else %}none{% endif %};
}
}
{%- endstyle -%}

<section class='product_customization'>
<section class='product_customization-{{ id }}'>
{%- assign selected_product = section.settings.product %}

{%- if product %}
Expand Down Expand Up @@ -59,13 +61,15 @@
"type": "number",
bj-anas marked this conversation as resolved.
Show resolved Hide resolved
"id": "padding_top",
"label": "Padding top",
"default": 10
"default": 50

},
{
"type": "number",
"id": "padding_bottom",
"label": "Padding bottom",
"default": 10
"default": 50

},
{
"type": "text",
Expand Down
8 changes: 5 additions & 3 deletions sections/product.liquid
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
{% assign id = 100 | rand: 2000 %}

{{ 'product.css' | asset_url | stylesheet_tag }}

{%- style -%}
.product_customization {
.product_customization-{{ id }} {
padding-top: {{ section.settings.padding_top}}px;
padding-bottom: {{ section.settings.padding_bottom}}px;
}

.countdown-container {
background-color: {{ block.settings.background_color.hex }};
color: {{ block.settings.text_color.hex }};
}
{%- endstyle -%}

<section class='product_customization'>
<section class='product_customization-{{ id }}'>
{%- assign selected_product = section.settings.product %}

{%- if product %}
Expand Down