${function() {
const variantData = data.variant || {"id":"a4e9f29d-db7a-4851-921b-969227ae9e44","product_id":"19ca469f-9f5e-4769-9734-45d5f5292abb","title":"Colorful-S","weight_unit":"kg","inventory_quantity":1000,"sku":"123-230531-57-WT0033G9F2-Colorful-S","barcode":"","position":1,"option1":"Colorful","option2":"S","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/24bb4adafa6c39255c1d5e960da86f21.jpeg","path":"24bb4adafa6c39255c1d5e960da86f21.jpeg","width":900,"height":1200,"alt":"","aspect_ratio":0.75},"wholesale_price":[{"price":19.99,"min_quantity":1}],"weight":"0.2","compare_at_price":"28","price":"19.99","retail_price":"28","available":true,"url":"\/products\/womens-colorful-starry-sky-and-aurora-colorful-print-casual-top-d3xe?variant=a4e9f29d-db7a-4851-921b-969227ae9e44","available_quantity":999999999,"options":[{"name":"Color","value":"Colorful"},{"name":"Size","value":"S"}],"off_ratio":29,"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 `
`;
}()}