${function() {
const variantData = data.variant || {"id":"9401d8b6-50b6-407b-814d-2ad52fabc0eb","product_id":"2daefbc4-22bf-4a0e-873f-4dad453ef8d7","title":"Black-34","weight_unit":"kg","inventory_quantity":0,"sku":"BK4284-Boots-34","barcode":"","position":1,"option1":"Black","option2":"34","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/01fb30b3fe8bfcca4d7b45628ad36688.jpeg","path":"01fb30b3fe8bfcca4d7b45628ad36688.jpeg","width":800,"height":800,"alt":"","aspect_ratio":1},"wholesale_price":[{"price":79.99,"min_quantity":1}],"weight":"0.9","compare_at_price":"0","price":"79.99","retail_price":"0","available":false,"url":"\/products\/chained-belt-boots?variant=9401d8b6-50b6-407b-814d-2ad52fabc0eb","available_quantity":0,"options":[{"name":"Color","value":"Black"},{"name":"Size","value":"34"}],"off_ratio":0,"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 variantData = data.variant || {"id":"9401d8b6-50b6-407b-814d-2ad52fabc0eb","product_id":"2daefbc4-22bf-4a0e-873f-4dad453ef8d7","title":"Black-34","weight_unit":"kg","inventory_quantity":0,"sku":"BK4284-Boots-34","barcode":"","position":1,"option1":"Black","option2":"34","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/01fb30b3fe8bfcca4d7b45628ad36688.jpeg","path":"01fb30b3fe8bfcca4d7b45628ad36688.jpeg","width":800,"height":800,"alt":"","aspect_ratio":1},"wholesale_price":[{"price":79.99,"min_quantity":1}],"weight":"0.9","compare_at_price":"0","price":"79.99","retail_price":"0","available":false,"url":"\/products\/chained-belt-boots?variant=9401d8b6-50b6-407b-814d-2ad52fabc0eb","available_quantity":0,"options":[{"name":"Color","value":"Black"},{"name":"Size","value":"34"}],"off_ratio":0,"flashsale_info":[],"sales":8};
return `
`
}()}
${function() {
const postageFreeAmount = 100;
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 `
`;
}()}