${function() {
const variantData = data.variant || {"id":"4a83d019-a76d-4a2d-8652-5dcf73445339","product_id":"d985cad1-e5ed-45c1-ad09-b0d80c19c69b","title":"Black-S(13cm)","weight_unit":"kg","inventory_quantity":1000,"sku":"GB7002-Black-S","barcode":"","position":1,"option1":"Black","option2":"S(13cm)","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/e6ec31624a879e58fc9e8acb01a7c70e.jpeg","path":"e6ec31624a879e58fc9e8acb01a7c70e.jpeg","width":800,"height":800,"alt":"","aspect_ratio":1},"wholesale_price":[{"price":29.99,"min_quantity":1}],"weight":"0.6","compare_at_price":"0","price":"29.99","retail_price":"0","available":true,"url":"\/products\/its-my-way-bear-chain-bag?variant=4a83d019-a76d-4a2d-8652-5dcf73445339","available_quantity":1000,"options":[{"name":"Color","value":"Black"},{"name":"Size","value":"S(13cm)"}],"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 variantData = data.variant || {"id":"4a83d019-a76d-4a2d-8652-5dcf73445339","product_id":"d985cad1-e5ed-45c1-ad09-b0d80c19c69b","title":"Black-S(13cm)","weight_unit":"kg","inventory_quantity":1000,"sku":"GB7002-Black-S","barcode":"","position":1,"option1":"Black","option2":"S(13cm)","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/e6ec31624a879e58fc9e8acb01a7c70e.jpeg","path":"e6ec31624a879e58fc9e8acb01a7c70e.jpeg","width":800,"height":800,"alt":"","aspect_ratio":1},"wholesale_price":[{"price":29.99,"min_quantity":1}],"weight":"0.6","compare_at_price":"0","price":"29.99","retail_price":"0","available":true,"url":"\/products\/its-my-way-bear-chain-bag?variant=4a83d019-a76d-4a2d-8652-5dcf73445339","available_quantity":1000,"options":[{"name":"Color","value":"Black"},{"name":"Size","value":"S(13cm)"}],"off_ratio":0,"flashsale_info":[],"sales":1};
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 `
`;
}()}