${function() {
const variantData = data.variant || {"id":"03100922-b1e3-4fd9-86ea-5ded2f02b9c2","product_id":"52217593-2681-4ce0-bb62-fdb30767acf7","title":"green-S","weight_unit":"kg","inventory_quantity":1000,"sku":"128-230828-22-WT0002SEEN-green-S","barcode":"","position":7,"option1":"green","option2":"S","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/246e3963fe9e2b4679ea635574b2cf6f.jpeg","path":"246e3963fe9e2b4679ea635574b2cf6f.jpeg","width":900,"height":1200,"alt":"","aspect_ratio":0.75},"wholesale_price":[{"price":19.99,"min_quantity":1}],"weight":"0.3","compare_at_price":"19.99","price":"19.99","retail_price":"19.99","available":true,"url":"\/products\/harvest-dog-ghost-creative-design-t-shirt?variant=03100922-b1e3-4fd9-86ea-5ded2f02b9c2","available_quantity":999999999,"options":[{"name":"Color","value":"green"},{"name":"Size","value":"S"}],"off_ratio":0,"flashsale_info":[],"sales":1};
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 `
`;
}()}