first commit
This commit is contained in:
297
sections/product-template.liquid
Normal file
297
sections/product-template.liquid
Normal file
@@ -0,0 +1,297 @@
|
|||||||
|
{% if section.settings.product_breadcrumb == false %}
|
||||||
|
{% style %}
|
||||||
|
.container .breadcrumb__wrapper {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
{% endstyle %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
<div class="sixteen columns" data-initial-width="sixteen" data-sidebar-width="twelve">
|
||||||
|
<div class="product-{{ product.id }}">
|
||||||
|
<div class="section product_section clearfix {% if product.images.size > 1 %}thumbnail_position--{{settings.thumbnail_position}} {% endif %} product_slideshow_animation--{{settings.product_slideshow_animation}}"
|
||||||
|
data-thumbnail="{{settings.thumbnail_position}}"
|
||||||
|
data-slideshow-animation="{{settings.product_slideshow_animation}}"
|
||||||
|
data-slideshow-speed="{{settings.slideshow_speed}}">
|
||||||
|
|
||||||
|
<div class="eight columns product-image--align-{{ section.settings.product_images_position }} {% if section.settings.product_images_position == 'left' %}alpha{% else %}omega{% endif %}" data-initial-width="eight" data-sidebar-width="six">
|
||||||
|
{% include 'product-images' %}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="product__description seven columns {% if section.settings.product_images_position == 'left' %}omega product__description--right{% else %}alpha product__description--left{% endif %}" data-initial-width="seven" data-sidebar-width="five">
|
||||||
|
<div id="shopify-product-reviews" data-id="{{product.id}}">{{ product.metafields.spr.reviews }}</div>
|
||||||
|
{% assign collection_handles = product.collections | map: 'handle' %}
|
||||||
|
{% assign variant = product.selected_or_first_available_variant %}
|
||||||
|
{% assign variant_price = variant.price %}
|
||||||
|
{% assign variant_compare_at_price = variant.compare_at_price %}
|
||||||
|
|
||||||
|
{%- liquid
|
||||||
|
assign variant_price = variant.metafields.app--168074346497.auto_discounted_price.value | default: variant.price
|
||||||
|
|
||||||
|
if variant.metafields.app--168074346497.discount_type.value != nil and variant.metafields.app--168074346497.discount_type.value != "fixed" and product.metafields.app--168074346497.discount_percentage.value > 0.01
|
||||||
|
assign deducted_percentage = 1.0 | minus: product.metafields.app--168074346497.discount_percentage.value
|
||||||
|
|
||||||
|
if variant.metafields.app--168074346497.discount_percentage.value > 0.01
|
||||||
|
assign deducted_percentage = 1.0 | minus: variant.metafields.app--168074346497.discount_percentage.value
|
||||||
|
endif
|
||||||
|
|
||||||
|
assign variant_price = variant.price | divided_by: 100.0 | times: deducted_percentage | times: 100.0 | ceil
|
||||||
|
|
||||||
|
assign variant_compare_at_price = variant.price
|
||||||
|
|
||||||
|
if variant.compare_at_price > variant_compare_at_price
|
||||||
|
assign variant_compare_at_price = variant.compare_at_price
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
if variant_price < variant.price and variant_compare_at_price == blank
|
||||||
|
assign variant_compare_at_price = variant.price
|
||||||
|
endif
|
||||||
|
-%}
|
||||||
|
|
||||||
|
{% if collection and section.settings.show_collection_link %}
|
||||||
|
<a class="product_collection" title="{{ collection.title | escape }}" href="{{ collection.url }}">
|
||||||
|
{{ collection.title }}
|
||||||
|
</a>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
<h1 class="product_name">{{ product.title }}</h1>
|
||||||
|
<!-- Start of Judge.me code -->
|
||||||
|
<div style='{{ jm_style }}' class='jdgm-widget jdgm-preview-badge' data-id='{{ product.id }}' data-auto-install='false'>
|
||||||
|
{{ product.metafields.judgeme.badge }}
|
||||||
|
</div>
|
||||||
|
<!-- End of Judge.me code -->
|
||||||
|
<span class="stamped-product-reviews-badge stamped-main-badge" data-id="{{product.id}}" data-product-title="{{product.title}}" data-product-type="{{product.type}}" style="display: block;"></span>
|
||||||
|
|
||||||
|
{% if settings.enable_shopify_product_badges %}
|
||||||
|
<span class="shopify-product-reviews-badge" data-id="{{ product.id }}"></span>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if section.settings.display_vendor %}
|
||||||
|
<p class="vendor">
|
||||||
|
{{ product.vendor | link_to_vendor }}
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if variant.sku != blank and section.settings.display_sku %}
|
||||||
|
<p class="sku">
|
||||||
|
{{ variant.sku }}
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if collection_handles contains 'coming-soon' %}
|
||||||
|
<p class="modal_price">{{ 'collections.general.coming_soon' | t }}</p>
|
||||||
|
{% else %}
|
||||||
|
<p class="modal_price">
|
||||||
|
<span class="sold_out">{% if variant.available == false %}{{ 'products.product.sold_out' | t }}{% endif %}</span>
|
||||||
|
<span content="{{ variant_price | money_without_currency | remove: "," }}" class="{% if variant_compare_at_price > variant_price %}sale{% endif %}">
|
||||||
|
<span class="current_price {% if product.available == false %}hidden{% endif %}">
|
||||||
|
{% if variant_price > 0 %}
|
||||||
|
<span class="money">{{ variant_price | money }}</span>
|
||||||
|
{% else %}
|
||||||
|
{{ settings.free_price_text }}
|
||||||
|
{% endif %}
|
||||||
|
</span>
|
||||||
|
</span>
|
||||||
|
<span class="was_price">
|
||||||
|
{% if variant_price < variant_compare_at_price and variant.available %}
|
||||||
|
<span class="money">{{ variant_compare_at_price | money }}</span>
|
||||||
|
{% endif %}
|
||||||
|
</span>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
{% include 'product-notify-me' %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if section.settings.product_description_position == "top" %}
|
||||||
|
{% if product.description != blank %}
|
||||||
|
<div class="description">
|
||||||
|
{{ product.description | split: '<!-- split -->' | first }}
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% unless collection_handles contains 'coming-soon' %}
|
||||||
|
{% include 'product-form' with 'product' %}
|
||||||
|
{% endunless %}
|
||||||
|
|
||||||
|
{% if settings.enable_shopify_review_comments and settings.review_position == "top" %}
|
||||||
|
<div id="shopify-product-reviews" data-id="{{product.id}}">{{ product.metafields.spr.reviews }}</div>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if section.settings.product_description_position == "bottom" %}
|
||||||
|
{% if product.available %}<hr />{% endif %}
|
||||||
|
{% if product.description != blank %}
|
||||||
|
<div class="description">
|
||||||
|
{{ product.description | split: '<!-- split -->' | first }}
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if section.settings.display_collections or section.settings.display_tags or section.settings.display_type %}
|
||||||
|
<hr />
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
<div class="meta">
|
||||||
|
{% if section.settings.display_collections %}
|
||||||
|
<p>
|
||||||
|
<span class="label">{{ 'products.product.collections' | t }}:</span>
|
||||||
|
<span>
|
||||||
|
{% for col in product.collections %}
|
||||||
|
<a href="{{ col.url }}" title="{{ col.title }}">{{ col.title }}</a>{% unless forloop.last %},{% endunless %}
|
||||||
|
{% endfor %}
|
||||||
|
</span>
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if section.settings.display_tags %}
|
||||||
|
<p>
|
||||||
|
{% for tag in product.tags %}
|
||||||
|
{% if forloop.first %}
|
||||||
|
<span class="label">{{ 'products.product.tags' | t }}:</span>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% unless tag contains 'meta-' %}
|
||||||
|
<span>
|
||||||
|
<a href="/collections/{% if collection %}{{ collection.handle }}{% else %}all{% endif %}/{{ tag | handle }}" title="{{ 'products.product.products_tagged' | t: tag: tag }}">{{ tag }}</a>{% unless forloop.last %},{% endunless %}
|
||||||
|
</span>
|
||||||
|
{% endunless %}
|
||||||
|
{% endfor %}
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if section.settings.display_type %}
|
||||||
|
<p>
|
||||||
|
<span class="label">{{ 'products.product.product_types' | t }}:</span> <span>{{ product.type | link_to_type }}</span>
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if section.settings.display_vendor %}
|
||||||
|
<p>
|
||||||
|
<span class="label">{{ 'products.product.vendor' | t }}:</span> <span>{{ product.vendor | link_to_vendor }}</span>
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{% include "social-buttons" with "product" %}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{% if product.description contains "<!-- split -->" %}
|
||||||
|
<br class="clear" />
|
||||||
|
<div class="section clearfix">
|
||||||
|
<div class="description">
|
||||||
|
{{ product.description | split: '<!-- split -->' | last }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if settings.enable_shopify_review_comments and settings.review_position == "bottom" %}
|
||||||
|
<div class="sixteen columns" data-initial-width="sixteen" data-sidebar-width="twelve">
|
||||||
|
<div id="shopify-product-reviews" data-id="{{product.id}}">{{ product.metafields.spr.reviews }}</div>
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
</div>
|
||||||
|
<!-- Start of Judge.me code -->
|
||||||
|
<div style='clear:both'></div>
|
||||||
|
<div id='judgeme_product_reviews' class='jdgm-widget jdgm-review-widget' data-product-title='{{ product.title | escape }}' data-id='{{ product.id }}' data-auto-install='false'>
|
||||||
|
{{ product.metafields.judgeme.widget }}
|
||||||
|
</div>
|
||||||
|
<!-- End of Judge.me code -->
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{% schema %}
|
||||||
|
|
||||||
|
{
|
||||||
|
"name": "Product",
|
||||||
|
"class": "product-template-section clearfix",
|
||||||
|
"settings": [
|
||||||
|
{
|
||||||
|
"type": "checkbox",
|
||||||
|
"id": "product_breadcrumb",
|
||||||
|
"label": "Show breadcrumb links",
|
||||||
|
"default": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "checkbox",
|
||||||
|
"id": "show_collection_link",
|
||||||
|
"label": "Show collection link",
|
||||||
|
"default": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "checkbox",
|
||||||
|
"id": "display_sku",
|
||||||
|
"label": "Show SKU"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "checkbox",
|
||||||
|
"id": "display_tags",
|
||||||
|
"label": "Show tags"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "checkbox",
|
||||||
|
"id": "display_type",
|
||||||
|
"label": "Show type"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "checkbox",
|
||||||
|
"id": "display_vendor",
|
||||||
|
"label": "Show vendor"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "checkbox",
|
||||||
|
"id": "display_collections",
|
||||||
|
"label": "Show collections"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "checkbox",
|
||||||
|
"id": "display_social_buttons",
|
||||||
|
"label": "Show social media share icons",
|
||||||
|
"default": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "radio",
|
||||||
|
"id": "product_description_position",
|
||||||
|
"label": "Description position",
|
||||||
|
"options": [
|
||||||
|
{
|
||||||
|
"value": "top",
|
||||||
|
"label": "Above 'add to cart'"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"value": "bottom",
|
||||||
|
"label": "Below 'add to cart'"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "radio",
|
||||||
|
"id": "product_images_position",
|
||||||
|
"label": "Images position",
|
||||||
|
"options": [
|
||||||
|
{
|
||||||
|
"value": "left",
|
||||||
|
"label": "Left"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"value": "right",
|
||||||
|
"label": "Right"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "header",
|
||||||
|
"content": "Dynamic checkout button"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "checkbox",
|
||||||
|
"id": "show_payment_button",
|
||||||
|
"label": "Show dynamic checkout button",
|
||||||
|
"default": true,
|
||||||
|
"info": "Each customer will see their preferred payment method from those available on your store, such as PayPal or Apple Pay. [Learn more](https://help.shopify.com/manual/using-themes/change-the-layout/dynamic-checkout)"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
{% endschema %}
|
||||||
230
snippets/product-thumbnail.liquid
Normal file
230
snippets/product-thumbnail.liquid
Normal file
@@ -0,0 +1,230 @@
|
|||||||
|
{% if sidebar %}
|
||||||
|
<div class="{% if products_per_row == 2 %}six columns {% cycle collection_group_thumb: 'alpha', 'omega' %}{% elsif products_per_row == 3 %}four columns {% cycle collection_group_thumb: 'alpha', '', 'omega' %}{% else %}three columns {% cycle collection_group_thumb: 'alpha', '', '', 'omega' %}{% endif %} thumbnail {% cycle collection_group_mobile: 'even', 'odd' %} swap-{{ settings.collection_secondary_image }}" data-initial-width="{% if products_per_row == 2 %}eight{% elsif products_per_row == 3 %}one-third{% elsif products_per_row == 4 %}four{% endif %}" data-sidebar-width="{% if products_per_row == 2 %}six{% elsif products_per_row == 3 %}four{% elsif products_per_row == 4 %}three{% endif %}">
|
||||||
|
{% else %}
|
||||||
|
<div class="{% if products_per_row == 2 %}eight columns {% cycle collection_group_thumb: 'alpha', 'omega' %}{% elsif products_per_row == 3 %}one-third column {% cycle collection_group_thumb: 'alpha', '', 'omega' %}{% else %}four columns {% cycle collection_group_thumb: 'alpha', '', '', 'omega' %}{% endif %} thumbnail {% cycle collection_group_mobile: 'even', 'odd' %} swap-{{ settings.collection_secondary_image }}" data-initial-width="{% if products_per_row == 2 %}eight{% elsif products_per_row == 3 %}one-third{% elsif products_per_row == 4 %}four{% endif %}" data-sidebar-width="{% if products_per_row == 2 %}six{% elsif products_per_row == 3 %}four{% elsif products_per_row == 4 %}three{% endif %}">
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% assign collection_handles = product.collections | map: 'handle' %}
|
||||||
|
|
||||||
|
{% if product.featured_image.alt contains 'youtube' or image.alt contains 'vimeo' %}
|
||||||
|
{% assign alt_text = product.title %}
|
||||||
|
{% else %}
|
||||||
|
{% assign alt_text = product.featured_image.alt %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if settings.align_height %}
|
||||||
|
{% assign collection_height = settings.collection_height | plus: 0 %}
|
||||||
|
{% assign product_aspect_ratio = product.featured_image.aspect_ratio | plus: 0 %}
|
||||||
|
{% assign product_set_width = product_aspect_ratio | times: collection_height %}
|
||||||
|
|
||||||
|
{% if product.featured_image.width >= product.featured_image.height %}
|
||||||
|
{% assign align_height_value = 'width: 100%; height: auto;' %}
|
||||||
|
{% else %}
|
||||||
|
{% assign align_height_value = 'width: 100%;' %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
<a href="{{ product.url | within: collection }}">
|
||||||
|
<div class="relative product_image">
|
||||||
|
|
||||||
|
<div class="product_container">
|
||||||
|
<div class="image__container" style="{% if settings.align_height %} max-width: {{ product_set_width }}px; {% else %} max-width: {{- product.featured_image.width -}}px;{% endif %}">
|
||||||
|
{% if settings.thumbnail_border_enabled %}
|
||||||
|
<div class="image__border">
|
||||||
|
{% endif %}
|
||||||
|
<img src="{{ product.featured_image | product_img_url: '300x' }}"
|
||||||
|
alt="{{ alt_text | escape }}"
|
||||||
|
class="lazyload lazyload--fade-in"
|
||||||
|
style="{{ align_height_value }} max-width: {{- product.featured_image.width -}}px;"
|
||||||
|
data-sizes="auto"
|
||||||
|
data-src="{{ product.featured_image | product_img_url: '2048x' }}"
|
||||||
|
data-srcset=" {{ product.featured_image | product_img_url: '2048x' }} 2048w,
|
||||||
|
{{ product.featured_image | product_img_url: '1600x' }} 1600w,
|
||||||
|
{{ product.featured_image | product_img_url: '1200x' }} 1200w,
|
||||||
|
{{ product.featured_image | product_img_url: '1000x' }} 1000w,
|
||||||
|
{{ product.featured_image | product_img_url: '800x' }} 800w,
|
||||||
|
{{ product.featured_image | product_img_url: '600x' }} 600w,
|
||||||
|
{{ product.featured_image | product_img_url: '400x' }} 400w"
|
||||||
|
/>
|
||||||
|
{% if settings.collection_secondary_image != blank %}
|
||||||
|
<div class="image__container" style="max-width: {% if product.images[1] != blank %}{{- product.images[1].width -}}px{% else %}{{- product.featured_image.width -}}px{% endif %}; ">
|
||||||
|
<img src="{% if product.images[1] != blank %}{{ product.images[1] | product_img_url: '900x' }}{% else %}{{ product.featured_image | product_img_url: '900x' }}{% endif %}"
|
||||||
|
class="secondary lazyload"
|
||||||
|
alt="{{ alt_text | escape }}"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
{% if settings.thumbnail_border_enabled %}
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="quick_shop_container">
|
||||||
|
{% if settings.quick_shop_enabled %}
|
||||||
|
<span data-fancybox-href="#product-{{ product.id }}" class="quick_shop action_button" data-gallery="product-{{ product.id }}-gallery">
|
||||||
|
{{ 'collections.general.quick_shop' | t }}
|
||||||
|
</span>
|
||||||
|
{% endif %}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="info">
|
||||||
|
<span class="title">{{ product.title }}</span>
|
||||||
|
<!-- Start of Judge.me code -->
|
||||||
|
<div style='{{ jm_style }};font-size: 14px' class='jdgm-widget jdgm-preview-badge' data-id='{{ product.id }}' data-auto-install='false'>
|
||||||
|
{{ product.metafields.judgeme.badge }}
|
||||||
|
</div>
|
||||||
|
<!-- End of Judge.me code -->
|
||||||
|
{% if settings.enable_shopify_collection_badges %}
|
||||||
|
<span class="shopify-product-reviews-badge" data-id="{{ product.id }}"></span>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if settings.display_vendor_collection %}
|
||||||
|
<span class="vendor">{{ product.vendor }}</span>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if collection_handles contains 'coming-soon' %}
|
||||||
|
<p class="price">{{ 'collections.general.coming_soon' | t }}</p>
|
||||||
|
{% else %}
|
||||||
|
{%- liquid
|
||||||
|
assign product_price = product.metafields.app--168074346497.min_auto_discounted_price.value | default: product.price
|
||||||
|
assign product_price_min = product_price
|
||||||
|
assign product_compare_at_price_max = product.compare_at_price_max
|
||||||
|
|
||||||
|
if product.metafields.app--168074346497.discount_percentage.value > 0.01
|
||||||
|
assign deducted_percentage = 1.0 | minus: product.metafields.app--168074346497.discount_percentage.value
|
||||||
|
|
||||||
|
assign product_price = product.price | divided_by: 100.0 | times: deducted_percentage | times: 100.0 | ceil
|
||||||
|
assign product_price_min = product_price
|
||||||
|
|
||||||
|
assign product_compare_at_price_max = product.price_max
|
||||||
|
|
||||||
|
if product.compare_at_price_max > product_compare_at_price_max
|
||||||
|
assign product_compare_at_price_max = product.compare_at_price_max
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
if product_price < product.price and product_compare_at_price_max == blank
|
||||||
|
assign product_compare_at_price_max = product.price_max
|
||||||
|
endif
|
||||||
|
-%}
|
||||||
|
<p class="price {% if product_compare_at_price_max > product_price %}sale{% endif %}">
|
||||||
|
{% if product.available %}
|
||||||
|
{% if product.price_varies and product_price_min > 0 %}
|
||||||
|
<small><em>{{ 'products.general.from' | t }}</em></small>
|
||||||
|
{% endif %}
|
||||||
|
{% if product_price_min > 0 %}
|
||||||
|
<span class="money">{{ product_price_min | money }}</span>
|
||||||
|
{% else %}
|
||||||
|
{{ settings.free_price_text }}
|
||||||
|
{% endif %}
|
||||||
|
{% if product_compare_at_price_max > product_price %}
|
||||||
|
<span class="was_price">
|
||||||
|
<span class="money">{{ product_compare_at_price_max | money }}</span>
|
||||||
|
</span>
|
||||||
|
{% endif %}
|
||||||
|
{% else %}
|
||||||
|
<span class="sold_out">{{ 'products.product.sold_out' | t }}</span>
|
||||||
|
{% endif %}
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
</div>
|
||||||
|
{% include 'product-thumbnail__sticker' %}
|
||||||
|
</a>
|
||||||
|
{% include 'collection-swatch' %}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{% if settings.quick_shop_enabled %}
|
||||||
|
{% if product.description contains "#tab1" %}
|
||||||
|
{% assign tabs = true %}
|
||||||
|
{% else %}
|
||||||
|
{% assign tabs = false %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
<div id="product-{{ product.id }}" class="modal quick-shop-modal product-{{ product.id }}">
|
||||||
|
<div class="container section" style="width: inherit">
|
||||||
|
<div class="eight columns modal_image flex-active-slide">
|
||||||
|
{% assign featured_image = product.selected_or_first_available_variant.featured_image | default: product.featured_image %}
|
||||||
|
<img src="{{ featured_image | product_img_url: '580x', scale: 2 }}"
|
||||||
|
class="lazyload lazyload--fade-in"
|
||||||
|
alt="{{ alt_text | escape }}" />
|
||||||
|
</div>
|
||||||
|
<div class="six columns">
|
||||||
|
<h3>{{ product.title }}</h3>
|
||||||
|
{% if settings.enable_shopify_collection_badges %}
|
||||||
|
<span class="shopify-product-reviews-badge" data-id="{{ product.id }}"></span>
|
||||||
|
{% endif %}
|
||||||
|
{% if settings.display_vendor_collection %}
|
||||||
|
<p class="vendor">
|
||||||
|
<span>{{ product.vendor | link_to_vendor }}</span>
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% assign variant = product.selected_or_first_available_variant %}
|
||||||
|
|
||||||
|
{% if collection_handles contains 'coming-soon' %}
|
||||||
|
<p class="modal_price">{{ 'collections.general.coming_soon' | t }}</p>
|
||||||
|
{% else %}
|
||||||
|
<p class="modal_price">
|
||||||
|
<span class="sold_out">{% if variant.available == false %}{{ 'products.product.sold_out' | t }}{% endif %}</span>
|
||||||
|
<span class="{% if variant.compare_at_price > variant.price %}sale{% endif %}">
|
||||||
|
<span class="current_price {% if product.available == false %}hidden{% endif %}">
|
||||||
|
{% if variant.price > 0 %}
|
||||||
|
<span class="money">{{ variant.price | money }}</span>
|
||||||
|
{% else %}
|
||||||
|
{{ settings.free_price_text }}
|
||||||
|
{% endif %}
|
||||||
|
</span>
|
||||||
|
</span>
|
||||||
|
<span class="was_price">
|
||||||
|
{% if variant.price < variant.compare_at_price and variant.available %}
|
||||||
|
<span class="money">{{ variant.compare_at_price | money }}</span>
|
||||||
|
{% endif %}
|
||||||
|
</span>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
{% include 'product-notify-me' %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if settings.product_description_position == "top" %}
|
||||||
|
{% if settings.description_words == "none" %}
|
||||||
|
{{ product.description | split: '<!-- split -->' | first }}
|
||||||
|
{% else %}
|
||||||
|
{% if tabs %}
|
||||||
|
{{ product.description | split: '<!-- split -->' | first }}
|
||||||
|
{% else %}
|
||||||
|
<p>{{ product.description | strip_html | truncatewords: settings.description_words }}</p>
|
||||||
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
<p>
|
||||||
|
<a href="{{ product.url | within: collection }}" class="view_product_info" title="{{ product.title | escape }}">{{ 'collections.general.view_product_details_html' | t }}</a>
|
||||||
|
</p>
|
||||||
|
<hr />
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% unless collection_handles contains 'coming-soon' %}
|
||||||
|
{% include 'product-form', show_payment_button_quickshop: settings.show_payment_button %}
|
||||||
|
{% endunless %}
|
||||||
|
|
||||||
|
{% if settings.product_description_position == "bottom" %}
|
||||||
|
<hr />
|
||||||
|
{% if settings.description_words == "none" %}
|
||||||
|
{{ product.description | split: '<!-- split -->' | first }}
|
||||||
|
{% else %}
|
||||||
|
{% if tabs %}
|
||||||
|
{{ product.description | split: '<!-- split -->' | first }}
|
||||||
|
{% else %}
|
||||||
|
<p>{{ product.description | strip_html | truncatewords: settings.description_words }}</p>
|
||||||
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
<p>
|
||||||
|
<a href="{{ product.url | within: collection }}" class="view_product_info" title="{{ product.title | escape }}">{{ 'collections.general.view_product_details_html' | t }}</a>
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
Reference in New Issue
Block a user