Skip to content

Instantly share code, notes, and snippets.

View svaustin66's full-sized avatar

Scott Austin svaustin66

View GitHub Profile
@svaustin66
svaustin66 / page__product-photos.liquid
Created May 23, 2022 00:27
Product Review Tool section
{% comment %}
Custom section added by JadePuma
Instructions - https://jadepuma.com/blogs/shopify-tutorials/flex-product-image-review-tool
{% endcomment %}
{%- assign id = section.id -%}
{% comment %} Section specific CSS {% endcomment %}
@svaustin66
svaustin66 / jadepuma.css.liquid
Created May 14, 2022 20:39
Replace Judge.me Review Stars with your own Icons
.product-app .jdgm-prev-badge__stars .jdgm--on { background-image: url("{{ 'Ryno-on-rect.png' | file_img_url: '50x' }}"); background-size: cover; }
.product-app .jdgm-prev-badge__stars .jdgm--off { background-image: url("{{ 'Ryno-off-rect.png' | file_img_url: '50x' }}"); background-size: contain; }
.product-app .jdgm-prev-badge__stars .jdgm--half { background-image: url("{{ 'Ryno-half-rect.png' | file_img_url: '50x' }}"); background-size: contain; }
.product-app .jdgm-prev-badge__stars .jdgm-star:last-of-type { padding-right: 4px !important; }
.product-app .jdgm-prev-badge__stars .jdgm-star::before { opacity: 0; }
@svaustin66
svaustin66 / index__klaviyo.liquid
Created April 13, 2022 02:27
Klaviyo form section for the Flex theme
{% comment %}
Custom section added by JadePuma
Instructions - https://jadepuma.com/blogs/shopify-tutorials/klaviyo-sign-up-form-section-for-the-flex-theme
{% endcomment %}
{% comment %} Assign object as block or section {% endcomment %}
{% if type == 'block' %}
{%- assign object = block -%}
@svaustin66
svaustin66 / checkout-breadcrumbs.liquid
Created March 22, 2022 04:42
Snippet for custom breadcrumbs in checkout of a Shopify Plus store.
{% if content_for_layout contains 'data-step="contact_information"' %}
<ul class="bc">
<a href="/cart">
<li class="bc_item bc_complete">Cart</li>
</a>
<li class="bc_item bc_current">Customer Information</li>
<li class="bc_item">Shipping Method</li>
<li class="bc_item">Payment Method</li>
</ul>
@svaustin66
svaustin66 / page__brand-guidelines.liquid
Last active July 29, 2022 17:07
This section can be added to a page to document and share your Brand Guidelines for your Shopify store. This code works for the Flex theme.
{%- assign id = section.id -%}
{% comment %} Section specific CSS {% endcomment %}
{%- capture section_css -%}
.section-heading {
text-align: center;
color: {{ section.settings.heading-color }};
background-color: {{ section.settings.heading-background-color }};
margin: 20px 0;
@svaustin66
svaustin66 / article__featured-products.liquid
Last active August 10, 2022 02:01
This Online Store 2.0 section allows you to easily promote a product in an article in the Flex theme in a Shopfiy store
{% comment %}
Custom section added by JadePuma
Instructions - https://jadepuma.com/blogs/shopify-tutorials/add-a-cart-message-section-to-the-flex-theme
Last editted - 9Aug22
{% endcomment %}
{% for tag in article.tags %}
{% if tag contains 'product-' %}
@svaustin66
svaustin66 / product-demo.liquid
Created March 9, 2022 03:52
Here's a template that does stuff
<div class="commit-create position-relative ">
<div class="">
<textarea class="form-control file-editor-textarea js-blob-contents js-code-textarea " rows="17" name="gist[contents][][value]" data-filename="product-demo.liquid" data-codemirror-mode="" data-allow-unchanged="true" data-hotkey-scope-id="code-editor" data-codemirror-fixed-height="true" placeholder="Enter file contents here" aria-label="Enter file contents here" spellcheck="false" style="display: none;"></textarea>
<div class="CodeMirror cm-s-github-light" style="height: 322px;"><div class="CodeMirror-vscrollbar" tabindex="-1" cm-not-content="true"><div style="min-width: 1px; height: 0px;"></div></div><div class="CodeMirror-hscrollbar" tabindex="-1" cm-not-content="true"><div style="height: 100%; min-height: 1px; width: 0px;"></div></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="Co
@svaustin66
svaustin66 / cart__simple-cross-sell.liquid
Created March 2, 2022 04:45
Code for the custom liquid section
<script
type="application/json"
data-section-type="cart-simple-cross-sell"
data-section-id="{{ section.id }}"
>
</script>
{% comment %} Advanced {% endcomment %}
{%- assign css_class = section.settings.css_class -%}
{%- assign custom_css = section.settings.custom_css -%}
@svaustin66
svaustin66 / page.policy.liquid
Created March 1, 2022 04:53
Code for the Custom Liquid section
{% comment %}
The 4 code bits below are added to the Custom liquid section that you'll add to each policy page
in Theme Customization in the Shopify admin.
Only add one code bit to each Custom Liquid section.
{% endcomment %}
<div class="content">
@svaustin66
svaustin66 / product-accordion.liquid
Created February 28, 2022 02:38
Product Accordion Snippet
{% capture icon_set %}
{% if settings.toggle_icon_style == 'carets' %}
{% render 'icon',
name: 'down-caret',
icon_class: 'icon--rotate'
%}
{% else %}
{% render 'icon',
name: 'plus',
icon_class: 'icon--active'