1class SelligentTracking{universeId;customerEmail;log;productData;constructor(universeId,customerEmail,log=!0){this.universeId=universeId,this.customerEmail=customerEmail,this.log=!0}getCheckoutMetafields=()=>{const script=document.querySelector("#order-additional-data");return script?JSON.parse(script.innerText):null};purchaseTracker=checkout=>{const myCheckout={sku:checkout.line_items[0].sku,quantity:checkout.line_items.length,total:checkout.total_price,payment:checkout.credit_card?"Credit Card":"Other",vendor:checkout.line_items[0].vendor,order_id:`${checkout.order_id}`,email:checkout.email,currency:checkout.currency};window.trackdata=window.trackdata||[],window.trackdata.push("aOcGfliaI"),window.trackdata.push(myCheckout.sku),window.trackdata.push(myCheckout.quantity),window.trackdata.push(myCheckout.total),window.trackdata.push(myCheckout.payment),window.trackdata.push(myCheckout.vendor),window.trackdata.push(myCheckout.order_id),window.trackdata.push(myCheckout.email),window.trackdata.push(myCheckout.currency)};checkoutTracker=()=>{(function(d,s,id){var js,sjs=d.getElementsByTagName(s)[0];d.getElementById(id)||(js=d.createElement(s),js.id=id,js.src="//pittarello.slgnt.eu/optiext/webtracker.dll",sjs.parentNode.insertBefore(js,sjs))})(document,"script","webtracker")};pushTags=tag=>{tag.isTargeting=!0,tag.async=!0,tag.isEvent=tag.isEvent!==void 0?tag.isEvent:!0,tag.isConsentless=!ShopifyTheme.isMarketingAllowed(),window.wa.bt_queue.push(tag),console.log("selligent tag",tag)};track=()=>{window.wa=document.createElement("script"),window.wa_s=document.getElementsByTagName("script")[0],window.wa.src=`https://targetemsecure.blob.core.windows.net/${this.universeId}/1355a767dca046448551d3b13a9bc343_1.js`,window.wa.type="text/javascript",window.wa_s.parentNode.insertBefore(wa,wa_s),window.wa.bt_queue=[],window.wa.afterInit=()=>{this.afterInit()}};afterInit=()=>{const ev={isEvent:!1,isConsentless:!ShopifyTheme.isMarketingAllowed()};this.productData&&(ev.tagValues=this.productData.tagValues),this.customerEmail&&(ev.customIdentifier=this.customerEmail),this.pushTags(ev),window.addEventListener(Utils.E_CART_ADDED,e=>this.product("CART",e.detail.gender,e.detail.vendor,e.detail.type||e.detail.product_type)),window.addEventListener(Utils.E_MENU_CLICK,e=>this.menu(e.detail)),window.addEventListener(Utils.E_BANNER_CLICK,e=>this.banner(e.detail)),window.addEventListener(Utils.E_ANNOUNCEMENT_CLICK,e=>this.announcement(e.detail)),window.addEventListener(Utils.E_CAROUSEL_CLICK,e=>this.carousel(e.detail)),window.addEventListener(Utils.E_FILTER_CHANGE,e=>this.filters(e.detail)),window.addEventListener(Utils.E_FOOTER_CLICK,e=>this.footer(e.detail)),window.addEventListener(Utils.E_PILL_CLICK,e=>this.pill(e.detail)),window.addEventListener(Utils.E_CART_CODE,e=>this.coupon("ADD",e.detail.code))};product=(action,gender,vendor,category)=>{this.productData={tagValues:[{tag:"ACT_MAR_CURR",value:`${action}_${gender}_${vendor}_${category}`.toUpperCase()},{tag:"ACT_CAT_CURR",value:`${action}_${gender}_${category}_${vendor}`.toUpperCase()},{tag:"ACT_MAR_OVER",value:`${action}_${gender}_${vendor}_${category}`.toUpperCase()},{tag:"ACT_CAT_OVER",value:`${action}_${gender}_${category}_${vendor}`.toUpperCase()}]}};menu=data=>{this.pushTags({tagValues:[{tag:"NAV",value:`${data.parents?data.parents.join("_").toUpperCase()+"_":""}${data.label.toUpperCase()}`}]})};banner=data=>{this.pushTags({tagValues:[{tag:"PAGE_INTEREST",value:`${data.pageType}${data.pageName?data.pageName:""}_${data.label}`.toUpperCase()}]})};announcement=data=>{this.pushTags({tagValues:[{tag:"ANNOUNCEMENT_INTEREST",value:`${data.label}`.toUpperCase()}]})};carousel=data=>{this.pushTags({tagValues:[{tag:"CAROUSEL_INTEREST",value:`${data.list.pageType}${data.list.pageName?data.list.pageName:""}_${data.list.title}_${data.product.product.title}`.toUpperCase()}]})};filters=data=>{this.pushTags({tagValues:data.change.map(change=>({tag:"FILTRI",value:`${change.name.split(".").at(-1)}_${change.value}`.toUpperCase()}))})};footer=data=>{this.pushTags({tagValues:{tag:"INFORMATION_INTEREST",value:`FOOTER_${data.page}_${data.label}`.toUpperCase()}})};pill=data=>{this.pushTags({tagValues:{tag:"PILLOLE",value:`${data.collection}_${data.label}`.toUpperCase()}})};coupon=(action,code)=>{this.pushTags({tagValues:{tag:"ACTION_COUPON",value:`${action}_${code}`.toUpperCase()}})};purchase=checkout=>{this.purchaseTracker(checkout),this.checkoutTracker(),this.track(),checkout.discount&&checkout.discount.applicable&&this.coupon("P
1UR",checkout.discount.code),checkout.line_items.forEach(item=>{const productMetafields=this.getCheckoutMetafields().items_metafields.filter(f=>f.id==item.product_id).at(0);var gender="";if(productMetafields){const genderM=productMetafields.metafields.filter(m=>m.key=="custom.gender").at(0);genderM&&(gender=genderM.value)}this.product("PUR",gender,item.vendor,item.type||item.product_type)})}}Shopify&&Shopify.checkout&&Shopify.checkout.order_id!=null&&Shopify.checkout.order_id!=null&&new SelligentTracking("1355a767-dca0-4644-8551-d3b13a9bc343",Shopify.checkout.email).purchase(Shopify.checkout); 2//# sourceMappingURL=/cdn/shop/t/218/assets/selligent-tracking.js.map?v=101429192908237943011790168719
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.