This file contains 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
<script> | |
// Calculate the sequence number of the holidays here: https://miniwebtool.com/day-of-the-year-calculator/ | |
// function to check leap year | |
function checkLeapYear(year) { | |
const isLeap = new Date(year, 1, 29).getDate() === 29; | |
return isLeap; | |
} | |
const currentYear = new Date().getFullYear(); | |
if (checkLeapYear(currentYear)) { |
This file contains 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
{%- form 'product', product, id: form_id, class: 'product-single-form' -%} | |
<!-- Line item property --> | |
<input type="hidden" name="properties[Field]" value="Field value"> | |
<!-- Cart attribute --> | |
<input type="hidden" name="attributes[Vendor]" value="Livom"> | |
{%- endform -%} |
This file contains 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
# ================================ Customizable Settings ================================ | |
# ================================================================ | |
# Tiered Discounts by Quantity | |
# | |
# A list of discount tier offers where: | |
# - 'product_selector_match_type' determines whether we look for | |
# products that do or don't match the entered selectors. Can | |
# be: | |
# - ':include' to check if the product does match | |
# - ':exclude' to make sure the product doesn't match |
This file contains 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
# ================================ Customizable Settings ================================ | |
# ================================================================ | |
# Tiered Product Discount by Quantity | |
# | |
# If the total quantity of matching items is greater than (or | |
# equal to) an entered threshold, the associated discount is | |
# applied to each matching item. | |
# | |
# - 'product_selector_match_type' determines whether we look for | |
# products that do or don't match the entered selectors. Can |
This file contains 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
<!-- Variant ID and quantity separated by semicolon + optional discount code as URL parameter -> redirect to checkout --> | |
https://shop-url.com/cart/42417843929345:1?discount=DISCOUNT_CODE |
This file contains 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
https://westernrise.com/discount/GIFT22?redirect=%2Fcollections%2Fbottoms |
This file contains 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
html { | |
-webkit-text-size-adjust: 100%; | |
text-rendering: geometricPrecision; | |
-webkit-font-smoothing: antialiased; | |
-webkit-font-smoothing: subpixel-antialiased; | |
-moz-font-smoothing: antialiased; | |
font-smoothing: antialiased; | |
} |
This file contains 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
<!-- Outer part or a circle --> | |
<svg width="100" height="100" viewBox="0 0 215 215" fill="none" xmlns="http://www.w3.org/2000/svg"> | |
<path fill-rule="evenodd" clip-rule="evenodd" d="M214.5 214.5H0V0C0 118.465 96.0349 214.5 214.5 214.5Z" fill="black"/> | |
</svg> | |
<!-- Inner part of a circle (sector) --> | |
<svg height="100" width="100" viewBox="0 0 512 512" fill="#000" xmlns="http://www.w3.org/2000/svg"> | |
<path d="M0,0v512h512C512,229.2,282.8,0,0,0z"/> | |
</svg> |
This file contains 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
var url = new URL(window.location.href); | |
url.searchParams.set('view', 'upsell-bundle'); | |
ablyftTools.redirect(url.toString()); |
This file contains 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
{%- comment -%} | |
https://www.npmjs.com/package/@adearriba/shopify-checkout?activeTab=code | |
{%- endcomment -%} | |
<script type="module" src="{{ 'shopify-checkout.js' | asset_url }}"></script> | |
<script> | |
import { $checkout } from './shopify-checkout.js'; | |
$checkout.on('load', (e) => { | |
console.log(e); | |
let discountNumberLineEl = document.querySelector('[data-checkout-discount-amount-target]'); |
NewerOlder