${function() {
const variantData = data.variant || {"id":"4a3a46ed-cafb-4df2-bafe-cbd8e848dfea","product_id":"885b2db7-c0d9-4c27-b76a-577daf1c16b1","title":"White-S","weight_unit":"kg","inventory_quantity":1000,"sku":"WTS199723-WHI00S","barcode":"","position":13,"option1":"White","option2":"S","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/dbe107cc3269abbd855f41ff98b80806.jpeg","path":"dbe107cc3269abbd855f41ff98b80806.jpeg","width":680,"height":907,"alt":"","aspect_ratio":0.7497243660418964},"wholesale_price":[{"price":18.99,"min_quantity":1}],"weight":"0","compare_at_price":"31.99","price":"18.99","retail_price":"31.99","available":true,"url":"\/products\/womens-adhd-thoughts-print-t-shirt-2?variant=4a3a46ed-cafb-4df2-bafe-cbd8e848dfea","available_quantity":999999999,"options":[{"name":"Color","value":"White"},{"name":"Size","value":"S"}],"off_ratio":41,"flashsale_info":[],"sales":16};
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 `
`;
}()}