if(void 0===orichiElementButtonAddToCart){var orichiPixelApiUrl="https://pixel.orichi.info",orichiPixelParameter,orichiElementButtonAddToCart="button[data-add-to-cart-text],.shp_add_to_cart_btn, #AddToCart,.button--addToCart, #so-btn-add-to-cart-copy, .lh-add_to_cart, .product-add-to-cart, button[data-add-to-cart-text], .single_add_to_cart_button, #addToCart, .product-form--atc-button,.gt_atom-gfJyZItCdWdircv_productButtonBuyItNow,.product-form__cart-submit,#teeAtcButton,#new-form-atc,.single_add_to_cart_button,#AddToCartForm button,.product__form button.add-to-cart, #AddToCart-product-template,.product-form__cart-submit,[name^='add'],button[data-pf-type='ProductATC'], .ProductForm__AddToCart,.product-form__add-button,.add-to-cart-btn,.ProductForm__AddToCart span,.tt-btn-addtocart,.btn-addtocart,.mfy-sticky-add-to-cart span,[name^='add'] span, .so-btn-add-to-cart-vanity-copy, .btn-addtocart span, .stickyaddtocart span, .vtl-ub-suggestion__add-to-cart",orichiElementButtonCheckout='button.cart__checkout, #CartDrawer-Checkout, #cartButtonSubmit, #mu-checkout-button, .shopify-payment-button__button,form[action^="/checkout"] :submit[name^="checkout"],form[action^="/checkout"] .checkout-button,.checkout_btn,.OTCheckout,[name^="checkout"],form[action^="/cart"] :submit[name^="checkout"],form[action^="/cart"] .checkout-button,#cart .action_button.right, .btn-checkout, a[href="/checkout"],.cb-bundle_custom_checkout_button_selector span, .cart_button_secure[href^="/checkout"], button[data-checkout="checkout"]',currency=null!=Shopify.currency?Shopify.currency.active:"USD",orichiPixelCurrency=null!=Shopify.currency?Shopify.currency.active:"USD",pageURL=window.location.href;(pageURL=void 0!==__st.pageurl?"https://"+__st.pageurl:window.location.href).indexOf("&")&&(pageURL=pageURL.split("&")[0]),!Shopify.Checkout||"thank_you"!=Shopify.Checkout.page&&"checkout_one_thank_you"!=Shopify.Checkout.page||"hello-8241.myshopify.com"!=Shopify.shop||(orichiPixelCurrency=Shopify.Checkout.currency);var isUseProductID=["gurudreads.myshopify.com","tim-and-ted.myshopify.com","bonorganik-kids.myshopify.com"].indexOf(Shopify.shop)>=0,notIncludeShippingFee=["grem-store.myshopify.com"].indexOf(Shopify.shop)>=0,notUsingPurchase=["nossalojabuzz.myshopify.com"].indexOf(Shopify.shop)>=0}async function orichiInitFacebookPixel(){let pixels=await orichiGetAllFacebookPixels($);if(window.pixels=pixels,pixels.length>0){try{""!=orGetPara("Var-ATC-Add")&&(orichiElementButtonAddToCart+=","+orGetPara("Var-ATC-Add")),""!=orGetPara("Var-ATC-Set")&&(orichiElementButtonAddToCart=orGetPara("Var-ATC-Set")),""!=orGetPara("Var-CB-Add")&&(orichiElementButtonCheckout+=","+orGetPara("Var-CB-Add")),""!=orGetPara("Var-CB-Set")&&(orichiElementButtonCheckout=orGetPara("Var-CB-Set")),"1"==orGetPara("Ev-ProductID-Use")&&(isUseProductID=!0),"1"==orGetPara("Var-Currency-Reset")&&(currency=Shopify.currency.active,orichiPixelCurrency=Shopify.currency.active),"1"==orGetPara("Var-Currency-COPresent")&&(!Shopify.Checkout||"thank_you"!=Shopify.Checkout.page&&"checkout_one_thank_you"!=Shopify.Checkout.page||(orichiPixelCurrency=Shopify.Checkout.currency,currency=Shopify.Checkout.currency))}catch(error){}if(trackPageView(pixels),null!=pageURL&&pageURL.indexOf("/products/")>-1){var product_url;if(pageURL.indexOf("?")>-1)product_url=(product_url=pageURL.split("?"))[0]+".json";else var product_url=pageURL+".json";var product=await otGetInfoProductByLink(product_url,$);trackViewContent(pixels,product)}if("theycollection.myshopify.com"==Shopify.shop){var orichiPixelcurrentUrl=window.location.href,interval_obj=setInterval((async function(){if(orichiPixelcurrentUrl!=window.location.href&&(orichiPixelcurrentUrl=window.location.href,pageURL.indexOf("/products/")>-1)){var product_url;if(pageURL.indexOf("?")>-1)product_url=(product_url=pageURL.split("?"))[0]+".json";else var product_url=pageURL+".json";var product=await otGetInfoProductByLink(product_url,$),variantid=getParameterByName("variant");trackViewContentVariant(pixels,product,variantid),trackPageView(pixels)}}));try{orichiElementButtonAddToCart="#abc";var t=fetch;fetch=function(e,o){var r=!1;e&&"function"==typeof e.search&&e.search(/cart\/add/)>=0&&o&&("POST"==o.method||"PUT"==o.method)&&(console.log("caught a fetch cart event",e,o),r=!0);var n=t(e,o);return n.then((function(){r&&void 0!==trackAddToCartThey&&trackAddToCartThey(window.pixels)})),n}}catch(A){y.log(A),y.log("error catching cart fetch")}}if(document.addEventListener("click",(function(event){if("gaelo1.myshopify.com"!=Shopify.shop&&"borealis-watch-company.myshopify.com"!=Shopify.shop&&"capefrigg.myshopify.com"!=Shopify.shop&&"flapper-head.myshopify.com"!=Shopify.shop&&"panta-rei-int.myshopify.com"!=Shopify.shop&&"theplantparty.myshopify.com"!=Shopify.shop&&"footgoo.myshopify.com"!=Shopify.shop&&"zorazola.myshopify.com"!=Shopify.shop&&"sevosa.myshopify.com"!=Shopify.shop&&"tryfuns.myshopify.com"!=Shopify.shop&&"biotanie.myshopify.com"!=Shopify.shop&&"ovlied.myshopify.com"!=Shopify.shop&&"jj-ellie-beauty.myshopify.com"!=Shopify.shop&&"grem-store.myshopify.com"!=Shopify.shop&&"sunlu3d.myshopify.com"!=Shopify.shop&&"mesaudaprofessional.myshopify.com"!=Shopify.shop&&"mesaudacosmetics.myshopify.com"!=Shopify.shop)if("alohaaloe.myshopify.com"!=Shopify.shop){if(event.target.matches(orichiElementButtonAddToCart)&&trackAddToCart(pixels),"cozy-drippy.myshopify.com"==Shopify.shop&&event.target.matches(".shopify-payment-button__button"))if("undefined"!=typeof itemInCart&&void 0!==itemInCart.items){var cart=itemInCart;if(cart.items.length>0){let content_ids=[],content_name=[];$.each(cart.items,(function(index,value){content_ids.push(value.variant_id),content_name.push(value.product_title),index==cart.items.length-1&&trackInitiateCheckout(pixels,content_ids,content_name,cart)}))}}else $.ajax({type:"GET",url:"/cart.js",dataType:"json"}).done(cart=>{if(cart.items.length>0){let content_ids=[],content_name=[];$.each(cart.items,(function(index,value){content_ids.push(value.variant_id),content_name.push(value.product_title),index==cart.items.length-1&&trackInitiateCheckout(pixels,content_ids,content_name,cart)}))}}).fail((function(jqXHR,textStatus){}))}else if(event.target.matches(".shopify-payment-button__button"))if("home"==__st.p){var prid=$(event.target).parents("form").attr("id").replace("AddToCartForm-",""),proObj=JSON.parse($("#ProductJson-"+prid).html());let content_ids=[$("#ProductSelect-"+prid).val()],content_name=[proObj.title],quantity=parseInt($("#Quantity").val());trackInitiateCheckout(pixels,content_ids,content_name,{total_price:quantity*proObj.price,item_count:quantity})}else if("product"==__st.p){var proObj=JSON.parse($("#ProductJson-product-template").html());let content_ids=[$("#ProductSelect-product-template").val()],content_name=[proObj.title],quantity=parseInt($("#Quantity").val());trackInitiateCheckout(pixels,content_ids,content_name,{total_price:quantity*proObj.price,item_count:quantity})}})),$("body").on("click",orichiElementButtonCheckout,(function(e){if("sua-ferramenta-shop.myshopify.com"!=Shopify.shop&&"gaelo1.myshopify.com"!=Shopify.shop&&"vital-chakra.myshopify.com"!=Shopify.shop&&"dejajewels.myshopify.com"!=Shopify.shop&&"maviere.myshopify.com"!=Shopify.shop)if("undefined"!=typeof itemInCart&&void 0!==itemInCart.items){var cart=itemInCart;if(cart.items.length>0){let content_ids=[],content_name=[];$.each(cart.items,(function(index,value){content_ids.push(isUseProductID?value.product_id:value.variant_id),content_name.push(value.product_title),index==cart.items.length-1&&trackInitiateCheckout(pixels,content_ids,content_name,cart)}))}}else $.ajax({type:"GET",url:"/cart.js",dataType:"json"}).done(cart=>{if(cart.items.length>0){let content_ids=[],content_name=[];$.each(cart.items,(function(index,value){content_ids.push(isUseProductID?value.product_id:value.variant_id),content_name.push(value.product_title),index==cart.items.length-1&&trackInitiateCheckout(pixels,content_ids,content_name,cart)}))}}).fail((function(jqXHR,textStatus){}))})),Shopify.Checkout&&("thank_you"==Shopify.Checkout.page||"checkout_one_thank_you"==Shopify.Checkout.page)){var productIds=[],productNames=[],quantity=0;Shopify.checkout.line_items.forEach((function(item,index){if(quantity+=item.quantity,""!=item.variant_title)var prod_name=item.title+" - "+item.variant_title;else var prod_name=item.title;productNames.push(prod_name),productIds.push(isUseProductID?item.product_id:item.variant_id)})),trackPurchase($,productIds,quantity,pixels)}if(""!=orGetPara("Ev-Lead-Add")&&window.location.href.indexOf(orGetPara("Ev-Lead-Add"))>-1&&orfbq(pixels,"Lead"),""!=orGetPara("Ev-SurveyV-Add")&&window.location.href.indexOf(orGetPara("Ev-SurveyV-Addd"))>-1&&orfbq(pixels,"SurveyView"),"even-subscriptions.myshopify.com"==Shopify.shop&&setTimeout((function(){$(orichiElementButtonCheckout).click((function(e){if("undefined"!=typeof itemInCart&&void 0!==itemInCart.items){var cart=itemInCart;if(cart.items.length>0){let content_ids=[],content_name=[];$.each(cart.items,(function(index,value){content_ids.push(value.variant_id),content_name.push(value.product_title),index==cart.items.length-1&&trackInitiateCheckout(pixels,content_ids,content_name,cart)}))}}else $.ajax({type:"GET",url:"/cart.js",dataType:"json"}).done(cart=>{if(cart.items.length>0){let content_ids=[],content_name=[];$.each(cart.items,(function(index,value){content_ids.push(value.variant_id),content_name.push(value.product_title),index==cart.items.length-1&&trackInitiateCheckout(pixels,content_ids,content_name,cart)}))}}).fail((function(jqXHR,textStatus){}))}))}),300),"sunlu3d.myshopify.com"==Shopify.shop&&$("body").on("click",".orichi-checkout-button",(function(e){if($("#cart_agree").length>0&&$("#cart_agree").prop("checked"))if("undefined"!=typeof itemInCart&&void 0!==itemInCart.items){var cart=itemInCart;if(cart.items.length>0){let content_ids=[],content_name=[];$.each(cart.items,(function(index,value){content_ids.push(value.variant_id),content_name.push(value.product_title),index==cart.items.length-1&&trackInitiateCheckout(pixels,content_ids,content_name,cart)}))}}else $.ajax({type:"GET",url:"/cart.js",dataType:"json"}).done(cart=>{if(cart.items.length>0){let content_ids=[],content_name=[];$.each(cart.items,(function(index,value){content_ids.push(value.variant_id),content_name.push(value.product_title),index==cart.items.length-1&&trackInitiateCheckout(pixels,content_ids,content_name,cart)}))}}).fail((function(jqXHR,textStatus){}));$('[name="checkout"]').click()})),"hobby-stories.myshopify.com"==Shopify.shop&&"collection"==__st.p&&$("body").on("click",".gf_add-to-cart",(function(e){var prid=$(this).parent().attr("data-pid"),productJson=JSON.parse($("#product-json"+prid).html()),event_id=(new Date).getTime()+getRandomInt(1,1e5);orfbq(pixels,"AddToCart",{content_ids:productJson.id,content_type:"product",value:parseInt(productJson.price)/100,content_name:productJson.title,currency:orichiPixelCurrency},event_id)})),"hobbyparati-es.myshopify.com"==Shopify.shop&&$("body").on("click",".rebuy-product-actions .rebuy-button",(function(e){trackAddToCart(pixels)})),"meow-approved.myshopify.com"==Shopify.shop){var atcFunction=window.handleAddToCart;window.handleAddToCart=function(e){atcFunction(e),trackAddToCart(pixels)}}if("coffee-gummies.myshopify.com"==Shopify.shop&&($("body").on("click",'form[action="/cart/add"] #main_form_button',(function(e){var prid=$('form[action="/cart/add"]').parent().attr("data-product-id"),proObj=window.__pageflyProducts[prid],event_id=(new Date).getTime()+getRandomInt(1,1e5);orfbq(pixels,"AddToCart",{content_ids:prid,content_type:"product",value:parseInt(proObj.variants[0].price)/100,content_name:proObj.title,currency:orichiPixelCurrency},event_id)})),$("body").on("click",'#contact_form button[type="submit"]',(function(e){var prid=$('form[action="/cart/add"]').parent().attr("data-product-id"),proObj=window.__pageflyProducts[prid],content_ids=[prid],content_name=[proObj.title],event_id=(new Date).getTime()+getRandomInt(1,1e5);orfbq(pixels,"InitiateCheckout",{content_type:"product",content_ids:content_ids,currency:orichiPixelCurrency,value:parseFloat(proObj.variants[0].price)/100,num_items:1,content_name:content_name},event_id)}))),"sandratest1.myshopify.com"==Shopify.shop&&"undefined"!=typeof RevyBundle&&$("button.cart__checkout").length>0&&0==$(".Orichi-dynamic-checkout-button").length){var checkoutHtml=$("button.cart__checkout")[0].outerHTML;$("button.cart__checkout").first().replaceWith(`
${checkoutHtml}
`)}if("gaelo1.myshopify.com"==Shopify.shop&&$("button.cart__checkout").length>0&&0==$(".Orichi-dynamic-checkout-button").length){var checkoutHtml=$("button.cart__checkout")[0].outerHTML;$("button.cart__checkout").first().replaceWith(`
${checkoutHtml}
`)}if("sneakers-haute-couture.myshopify.com"==Shopify.shop&&setInterval((function(){if($(".cart__form .checkout__button [name=checkout]").length>0&&0==$(".checkout__button .Orichi-dynamic-checkout-button").length){var checkoutHtml=$(".cart__form .checkout__button [name=checkout]")[0].outerHTML;$(".cart__form .checkout__button [name=checkout]").first().replaceWith(`
${checkoutHtml}
`)}if($(".cart__form .cart__total [name=checkout]").length>0&&0==$(".cart__total .Orichi-dynamic-checkout-button").length){var checkoutHtml=$(".cart__form .cart__total [name=checkout]")[0].outerHTML;$(".cart__form .cart__total [name=checkout]").first().replaceWith(`
${checkoutHtml}
`)}}),200),"azfacial.myshopify.com"==Shopify.shop&&setInterval((function(){if($("button.cart-items__checkout-button").length>0&&0==$(".Orichi-dynamic-checkout-button").length){var checkoutHtml=$("button.cart-items__checkout-button")[0].outerHTML;$("button.cart-items__checkout-button").first().replaceWith(`
${checkoutHtml}
`)}}),100),""!=orGetPara("Ev-CB-Override")){var element=orGetPara("Ev-CB-Override");setInterval((function(){if($(element).length>0&&0==$(".Orichi-dynamic-checkout-button").length){var checkoutHtml=$(element)[0].outerHTML;$(element).first().replaceWith(`
${checkoutHtml}
`)}}),100)}if("thereswill.myshopify.com"==Shopify.shop&&$("button.cart__checkout").length>0&&0==$(".Orichi-dynamic-checkout-button").length){var checkoutHtml=$("button.cart__checkout")[0].outerHTML;$("button.cart__checkout").first().replaceWith(`
${checkoutHtml}
`)}if("quibike2.myshopify.com"==Shopify.shop&&(myInterval=setInterval((function(){null!=Spurit.global&&(clearInterval(myInterval),Spurit.global.checkout.onCheckout((function(next){if("undefined"!=typeof itemInCart&&void 0!==itemInCart.items){var cart=itemInCart;if(cart.items.length>0){let content_ids=[],content_name=[];$.each(cart.items,(function(index,value){content_ids.push(isUseProductID?value.product_id:value.variant_id),content_name.push(value.product_title),index==cart.items.length-1&&trackInitiateCheckout(pixels,content_ids,content_name,cart)}))}}else $.ajax({type:"GET",url:"/cart.js",dataType:"json"}).done(cart=>{if(cart.items.length>0){let content_ids=[],content_name=[];$.each(cart.items,(function(index,value){content_ids.push(isUseProductID?value.product_id:value.variant_id),content_name.push(value.product_title),index==cart.items.length-1&&trackInitiateCheckout(pixels,content_ids,content_name,cart)}))}}).fail((function(jqXHR,textStatus){}))})))}),500)),"digital-army.myshopify.com"==Shopify.shop||"madamebrigite.myshopify.com"==Shopify.shop){var quantityEle='input[name="quantity"]:first';$("body").on("click",".aod_buy_now .aod_buy_button",(function(e){if(void 0!==__st.rid&&void 0!==meta.product.variants[0].id){var event_id=(new Date).getTime()+getRandomInt(1,1e5);orfbq(pixels,"InitiateCheckout",{content_type:"product",content_ids:isUseProductID?meta.product.id:meta.product.variants[0].id,currency:orichiPixelCurrency,value:parseInt($(quantityEle).val())*parseInt(meta.product.variants[0].price)/100,num_items:parseInt($(quantityEle).val()),content_name:meta.product.variants[0].name},event_id)}}))}var pixelIds=null!=ShopifyAnalytics&&null!=ShopifyAnalytics.lib&&null!=ShopifyAnalytics.lib.config["Facebook Pixel"]&&null!=ShopifyAnalytics.lib.config["Facebook Pixel"].pixelIds?ShopifyAnalytics.lib.config["Facebook Pixel"].pixelIds.join(","):"";pixelIds!=window.orichiSetting.DoubleIssueCheck&&$.ajax({url:`${orichiPixelApiUrl}/Customer/UpdateDoubleIssue?shop=`+Shopify.shop+"&pixelCheck="+pixelIds,type:"GET",success:function(res){}}),!Shopify.Checkout||"thank_you"!=Shopify.Checkout.page&&"checkout_one_thank_you"!=Shopify.Checkout.page||$("body").append(`