${function() {
const variantData = data.variant || {"id":"388fd0d2-1887-4a39-90ce-59d46c741b50","product_id":"3f6889b7-bbbb-489c-a04a-981f7a311d21","title":"Colorful-S","weight_unit":"kg","inventory_quantity":999,"sku":"103-230517-09-MT0036QZZV-Colorful-S","barcode":"","position":1,"option1":"Colorful","option2":"S","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/ae9ddb3b0a4c67d9cd2456233aef3de3.jpeg","path":"ae9ddb3b0a4c67d9cd2456233aef3de3.jpeg","width":900,"height":1200,"alt":"","aspect_ratio":0.75},"wholesale_price":[{"price":18.99,"min_quantity":1}],"weight":"0.2","compare_at_price":"39.98","price":"18.99","retail_price":"39.98","available":true,"url":"\/products\/mens-lgbtq-pride-rainbow-printing-shirt?variant=388fd0d2-1887-4a39-90ce-59d46c741b50","available_quantity":999999999,"options":[{"name":"Color","value":"Colorful"},{"name":"Size","value":"S"}],"off_ratio":53,"flashsale_info":[],"sales":11};
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 `
`;
}()}