${function() {
const variantData = data.variant || {"id":"1a4cc0b5-e47a-429c-a7d3-07e8849339e6","product_id":"3b49aa5b-0125-4be7-b4ef-bb2ce880ce6a","title":"Color-S","weight_unit":"kg","inventory_quantity":1000,"sku":"W23091319-Color-S","barcode":"","position":1,"option1":"Color","option2":"S","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/e13a02c483ef07665eddc58d4c467f02.jpeg","path":"e13a02c483ef07665eddc58d4c467f02.jpeg","width":1200,"height":1599,"alt":"","aspect_ratio":0.7504690431519699},"wholesale_price":[{"price":15.28,"min_quantity":1}],"weight":"0","compare_at_price":"24.27","price":"15.28","retail_price":"24.27","available":true,"url":"\/products\/womens-hippie-peace-sign-crew-neck-short-sleeve-top4f341c1f-0673-41d5-a0c5-c60b9a8d1f81?variant=1a4cc0b5-e47a-429c-a7d3-07e8849339e6","available_quantity":999999999,"options":[{"name":"color","value":"Color"},{"name":"size","value":"S"}],"off_ratio":37,"flashsale_info":[],"sales":7};
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 `
`;
}()}