people are viewing this right now
${function() {
const variantData = data.variant || {"id":"1d7f6966-f0e1-431d-bfbe-8be5687911fa","product_id":"e23222c2-fc56-45e1-bdd9-398e7b911557","title":"Black-S","weight_unit":"kg","inventory_quantity":0,"sku":"WL2403083995-Black-S","barcode":"","position":9,"option1":"Black","option2":"S","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/8d4def63a10a7cf85c665ec29c629335.jpeg","path":"8d4def63a10a7cf85c665ec29c629335.jpeg","width":2160,"height":2158,"alt":"Outletsltd Unisex Dragon Ball Majin Buu T-shirt","aspect_ratio":1.0009267840593141},"wholesale_price":[{"price":17.99,"min_quantity":1}],"weight":"250","compare_at_price":"29.98","price":"17.99","retail_price":"29.98","available":true,"url":"\/products\/unisex-dragon-ball-majin-buu-t-shirt?variant=1d7f6966-f0e1-431d-bfbe-8be5687911fa","available_quantity":999999999,"options":[{"name":"Color","value":"Black"},{"name":"Size","value":"S"}],"off_ratio":40,"flashsale_info":[],"sales":6};
const saveType = "percentage";
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}
`
}()}
${function() {
const minDays = parseInt('8');
const maxDays = parseInt('18');
const customText = "Estimated Delivery\uff1a{min_date} - {max_date}";
const minDate = new Date(Date.now() + (minDays * 86400000));
const maxDate = new Date(Date.now() + (maxDays * 86400000));
const formatDate = (minDate.getFullYear() == maxDate.getFullYear() && minDate.getFullYear() == new Date().getFullYear())
? new Intl.DateTimeFormat('en', { month: 'short', day: '2-digit' })
: new Intl.DateTimeFormat('en', { month: 'short', day: '2-digit', year: 'numeric' });
const tipText = customText.replace(/\{min_date\}/g, '' + formatDate.format(minDate) + '')
.replace(/\{max_date\}/g, '' + formatDate.format(maxDate) + '');
return `
`;
}()}
Product was out of stock.
Product is unavailable.
${function() {
const postageFreeAmount = 69;
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 `
`;
}()}