Gift Card - Perfect for Any Occasion
${function() {
const variantData = data.variant || {"id":"e1bb400b-f403-4012-a843-91c484d3d353","product_id":"efa4af8e-216c-4431-91af-ab1f8304cafa","title":"$50.00","weight_unit":"kg","inventory_quantity":0,"sku":"-$50.00-A001027","barcode":"","position":1,"option1":"$50.00","option2":"","option3":"","note":"","image":null,"wholesale_price":[{"price":50,"min_quantity":1}],"weight":"0","compare_at_price":"50","price":"50","retail_price":"50","available":true,"url":"\/products\/gift-card-perfect-for-any-occasion?variant=e1bb400b-f403-4012-a843-91c484d3d353","available_quantity":999999999,"options":[{"name":"Gift Card Denominations","value":"$50.00"}],"off_ratio":"0","flashsale_info":{"variant_id":"e1bb400b-f403-4012-a843-91c484d3d353","product_id":"","quantity":0,"discount_id":"","limit_time":0,"limit_buy":0,"user_limit_buy":0,"discount_sales":0,"discount_sales_rate":"","discount_stock":0,"ends_at":0,"starts_at":0,"allow_oversold":"","allocation_method":"","price":"50","compare_at_price":"","discount_price":"50","customary_saved_price":"","customary_off_ratio":"","discount_saved_price":"","discount_off_ratio":"0","use_before_price":false,"before_price":"","title":"","properties":"","color_setting_promotional_copy":"","discount_quantity":0,"is_need_split":false},"sales":0};
const saveType = "percentage";
const productLabelDiscountOn = true;
return `
-
${saveType == 'percentage'
? `-${variantData.off_ratio}%`
: `-`
}
`;
}()}
${function(){
const tipText = "Please select a {{ name }}".replace(/\{\{\s+name\s+\}\}/g, data);
return `${tipText}
`
}()}
const addToCartText = "Add to cart";
SPZCore.Dom.waitForChild(
document.body,
() => !!document.querySelector('[data-click="addToCart"], [role="addToCart"]'),
() => {
const addToCartEle = window.SPZCore.Dom.scopedQuerySelector(
document.body,
'[data-click="addToCart"], [role="addToCart"]'
);
const getContentChild_ = function(el) {
if(el) {
const childs = el.childNodes;
for (let i = childs.length - 1; i >= 0; i--) {
const child = childs[i];
if (child.getAttribute && child.getAttribute('role') === 'content') {
return child;
}
}
}
return;
}
const changeAddToCartText = function(text) {
const contentEle = getContentChild_(addToCartEle);
if(contentEle){
const addToCartChilds = addToCartEle.childNodes;
for (let i = addToCartChilds.length - 1; i >= 0; i--) {
const child = addToCartChilds[i];
if (typeof child.getAttribute !== 'function' || (child.getAttribute('role') !== 'content' && child.getAttribute('role') !== 'loading')) {
addToCartEle.removeChild(child);
}
}
}else{
addToCartEle.innerHTML = addToCartText;
}
}
changeAddToCartText(addToCartText);
}
);
Product was out of stock.
Product is unavailable.
people are viewing this right now