${function() {
const variantData = data.variant || {"id":"02adc656-6486-4f78-9059-5a93ccf90ab2","product_id":"ccac8e69-30e9-4210-87be-ca10ba94595b","title":"black-S","weight_unit":"kg","inventory_quantity":1000,"sku":"T22092617-black-S","barcode":"","position":1,"option1":"black","option2":"S","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/e97432648ce0ee73f6e54205cf0e60cc.jpeg","path":"e97432648ce0ee73f6e54205cf0e60cc.jpeg","width":540,"height":702,"alt":"","aspect_ratio":0.7692307692307693},"wholesale_price":[{"price":35,"min_quantity":1}],"weight":"0","compare_at_price":"55","price":"35","retail_price":"55","available":true,"url":"\/products\/dear-person-behind-me-love-like-jesus-sweatshirtc014079f-182f-48ba-8f47-60e3b0139572?variant=02adc656-6486-4f78-9059-5a93ccf90ab2","available_quantity":999999999,"options":[{"name":"color","value":"black"},{"name":"size","value":"S"}],"off_ratio":36,"flashsale_info":[],"sales":8};
const saveType = "amount";
const saveText = "Save {{saved_amount}}";
const productLabelDiscountOn = true;
return `
-
${saveText.replace('\{\{saved_amount\}\}',
saveType == 'percentage'
? variantData.off_ratio + '%'
: ``
)}
`;
}()}
${function(){
const tipText = "Please select a {{ name }}".replace(/\{\{\s+name\s+\}\}/g, data);
return `${tipText}
`
}()}
${function(){
const tipText = "Please select a {{ name }}".replace(/\{\{\s+name\s+\}\}/g, data);
return `${tipText}
`
}()}
Product was out of stock.
Product is unavailable.
${function() {
const postageFreeAmount = 79;
const custom_text = "Buy {amount} more to enjoy FREE Shipping";
const totalPrice = +data.total_price;
const diffPrice = postageFreeAmount - totalPrice;
const percentDiff = (diffPrice > 0 ? (totalPrice / postageFreeAmount * 100) : 100) + '%';
let tipText = "Your order is free delivery";
if (diffPrice > 0) {
tipText = custom_text.replace('{amount}', `
`);
}
return `
`;
}()}