This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// (c) Copyright 2016 Caroline Schnapp. All Rights Reserved. Contact: [email protected] | |
// See https://docs.shopify.com/themes/customization/navigation/link-product-options-in-menus | |
// Modified by Jonathan Moore (Style Hatch) https://github.com/jonathanmoore | |
/* | |
Updated to work with sectioned themes | |
- Added required methods from the deprecated options_selection.js | |
- Triggers an initial variant change | |
- Hides sold out variants with only one option |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- /templates/page.contact-custom.liquid --> | |
<div class="wrapper page-margin" data-section-id="{{ section.id }}"> | |
<div class="grid"> | |
<div class="grid__item large--two-thirds push--large--one-sixth"> | |
<h1 class="text-center h2">{{ page.title }}</h1> | |
{%- if section.settings.page_position == 'none' -%} | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="product-section" id="ProductSection-{{ section.id }}" data-section-id="{{ section.id }}" data-section-type="product" data-image-zoom-enable="{{ section.settings.zoom_enable }}"> | |
<div itemscope itemtype="http://schema.org/Product" class="product-page"> | |
<div class="wrapper"> | |
<meta itemprop="url" content="{{ shop.url }}{{ product.url }}"> | |
<meta itemprop="image" content="{{ product.featured_image.src | img_url: 'grande' }}"> | |
{% if section.settings.product_breadcrumbs %} | |
{% include 'breadcrumb' %} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- /snippets/collection-sorting.liquid --> | |
<div class="form-horizontal"> | |
<label for="SortBy" class="uppercase">{{ 'collections.sorting.title' | t }} </label> | |
<select name="SortBy" id="SortBy"> | |
<option value="manual">{{ 'collections.sorting.featured' | t }}</option> | |
<option value="best-selling">{{ 'collections.sorting.best_selling' | t }}</option> | |
<option value="title-ascending">{{ 'collections.sorting.az' | t }}</option> | |
<option value="title-descending">{{ 'collections.sorting.za' | t }}</option> | |
<option value="price-ascending">{{ 'collections.sorting.price_ascending' | t }}</option> | |
<option value="price-descending">{{ 'collections.sorting.price_descending' | t }}</option> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- /snippets/product-no-price.liquid --> | |
<div itemscope itemtype="http://schema.org/Product" class="product-page"> | |
<div class="wrapper"> | |
<meta itemprop="url" content="{{ shop.url }}{{ product.url }}"> | |
<meta itemprop="image" content="{{ product.featured_image.src | img_url: 'grande' }}"> | |
<meta itemprop="price" content="{{ product.price | money }}"> | |
{% if settings.product_breadcrumbs %} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- /sections/collection-custom-center-center.liquid --> | |
{%- assign grid_offset = '' -%} | |
{%- assign products_count = collection.products_count -%} | |
{%- case section.settings.grid_setting_large -%} | |
{%- when 1 -%} | |
{%- assign grid_width_large = 'large--one-whole' -%} | |
{%- when 2 -%} | |
{%- assign grid_width_large = 'large--one-half' -%} | |
{%- if products_count == 1 -%} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- /sections/collection-custom-center.liquid --> | |
{%- assign grid_offset = '' -%} | |
{%- assign products_count = collection.products_count -%} | |
{%- case section.settings.grid_setting_large -%} | |
{%- when 1 -%} | |
{%- assign grid_width_large = 'large--one-whole' -%} | |
{%- when 2 -%} | |
{%- assign grid_width_large = 'large--one-half' -%} | |
{%- if products_count == 1 -%} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- /sections/collection-custom-left.liquid --> | |
{%- assign grid_offset = '' -%} | |
{%- assign products_count = collection.products_count -%} | |
{%- case section.settings.grid_setting_large -%} | |
{%- when 1 -%} | |
{%- assign grid_width_large = 'large--one-whole' -%} | |
{%- when 2 -%} | |
{%- assign grid_width_large = 'large--one-half' -%} | |
{%- if products_count == 1 -%} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% assign blockList = '' %} | |
{% for block in section.blocks %} | |
{% assign blockList = blockList | append: block.type | append:',' %} | |
{% endfor %} | |
{% assign blockArray = blockList | split: "," %} | |
{% assign swaparoo = false %} | |
{% if blockArray[0] != 'image' and blockArray[1] == 'image' %} | |
{% assign swaparoo = true %} | |
{% endif %} |