PageSourceSearch

https://thecommense.com/cdn/shop/t/7/assets/js-trackifyx.js?v=32769155987791644431729424014

js thecommense.com collected 2026-09-25 14:19:23 UTC 117,478 bytes, 3 lines download raw bytes

1const tfx_shop_settings={shop_id:28094,shop:"commenses.myshopify.com",plan:"shopify_plus",tfx_plan:{optin:!1,popular:!1,price:29.99,extraPixelPrice:19,shopifyPrices:{Development:10.99,BasicShopify:29.99,Shopify:59.99,AdvancedShopify:99.99,ShopifyPlus:199.99},isPlanAvailable:!0,ui:{color:"#3b4f66",border:"#3f3f3f",width:"auto"},limits:{pixels:8,"Server-Side API":"Purchase events","Non-Purchase events Server-Side API":"","Niche Tracking Tags":"Unlimited",analytics:"4 Months","Auto Catalog Feed":"","Custom Diagnosis":"","Scripts & Coding":"Custom","Feed Options":"Enterprise","FB Audience Builder":"Advanced","Large Feed Support":"","Dedicated CS Manager":"","Biweekly Manual Pixel Audit":"","Pixel Audit Recommendations":"","Time Based Events":"Advanced","Report Variants":"","Advanced Matching":"","Report Microdata":"","Value Reporting":"","Price Value Reporting":"","InitiateCheckout Button Click":"",CCPA:"","Tracking Consent Api":"","Event To Fire":"","Enable IOS14 Suppression":"","Enable SS for pending status":""}},tfx_planName:"shopifyExtended",currency:"USD",debug:!1,baseURL:"https://trackifyx.redretarget.com",pixels:[{id:124271,pixel_id:"1036932283761925",type:"master",context:[""],enabled:!0,month_ago:"2021-11-09T15:52:31Z",serversideapi_enabled:!0,serversideapi_status:"",is_token_valid:!0}],orders:[],logging:!0,proxy:"a/tfx",user_agent:"Mozilla/5.0 (iPhone; CPU iPhone OS 15_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/19B74 [FBAN/FBIOS;FBDV/iPhone11,8;FBMD/iPhone;FBSN/iOS;FBSV/15.1;FBSS/2;FBID/phone;FBLC/en_US;FBOP/5]",user_ip:"2606:54c0:7680:ce8::c:2fb",id:36214,enabled:!0,report_variants:!1,advance_matching:!0,microdata:!1,value_reporting:!0,reporting_percentage:100,time_on_site:!1,ccpa:"disabled",tracking_consent_api:"ignore",event_to_fire:["pageViewEvent","viewContentEvent","viewCategoryEvent","purchaseEvent","addToCartEvent"],all_events_for_suppress:["viewCategoryEvent","customizeProductEvent","viewCartEvent","paymentLeadEvent","addShippingInfoEvent","addToWishListEvent","searchEvent","contactEvent","timerEvent","pageViewEvent","viewContentEvent","addPaymentInfoEvent","purchaseEvent","initiateCheckoutEvent","addToCartEvent","microData","buttonClick"],enable_ios14_suppression:!1,enable_ssevents_for_pending:!0,orders_purchase:!1,ocu_ss_api:0,shopify_pixel:!1,contents:!0,atc_click:!0,ic_switch:!0},CountryCode={AF:{phoneCode:"93"},AX:{phoneCode:"+358-18"},AL:{phoneCode:"355"},DZ:{phoneCode:"213"},AS:{phoneCode:"+1-684"},AD:{phoneCode:"376"},AO:{phoneCode:"244"},AI:{phoneCode:"+1-264"},AQ:{phoneCode:""},AG:{phoneCode:"+1-268"},AR:{phoneCode:"54"},AM:{phoneCode:"374"},AW:{phoneCode:"297"},AU:{phoneCode:"61"},AT:{phoneCode:"43"},AZ:{phoneCode:"994"},BS:{phoneCode:"+1-242"},BH:{phoneCode:"973"},BD:{phoneCode:"880"},BB:{phoneCode:"+1-246"},BY:{phoneCode:"375"},BE:{phoneCode:"32"},BZ:{phoneCode:"501"},BJ:{phoneCode:"229"},BM:{phoneCode:"+1-441"},BT:{phoneCode:"975"},BO:{phoneCode:"591"},BA:{phoneCode:"387"},BW:{phoneCode:"267"},BV:{phoneCode:"0055"},BR:{phoneCode:"55"},IO:{phoneCode:"246"},BN:{phoneCode:"673"},BG:{phoneCode:"359"},BF:{phoneCode:"226"},BI:{phoneCode:"257"},KH:{phoneCode:"855"},CM:{phoneCode:"237"},CA:{phoneCode:"1"},CV:{phoneCode:"238"},KY:{phoneCode:"+1-345"},CF:{phoneCode:"236"},TD:{phoneCode:"235"},CL:{phoneCode:"56"},CN:{phoneCode:"86"},CX:{phoneCode:"61"},CC:{phoneCode:"61"},CO:{phoneCode:"57"},KM:{phoneCode:"269"},CG:{phoneCode:"242"},CD:{phoneCode:"243"},CK:{phoneCode:"682"},CR:{phoneCode:"506"},CI:{phoneCode:"225"},HR:{phoneCode:"385"},CU:{phoneCode:"53"},CY:{phoneCode:"357"},CZ:{phoneCode:"420"},DK:{phoneCode:"45"},DJ:{phoneCode:"253"},DM:{phoneCode:"+1-767"},DO:{phoneCode:"+1-809 and 1-829"},TL:{phoneCode:"670"},EC:{phoneCode:"593"},EG:{phoneCode:"20"},SV:{phoneCode:"503"},GQ:{phoneCode:"240"},ER:{phoneCode:"291"},EE:{phoneCode:"372"},ET:{phoneCode:"251"},FK:{phoneCode:"500"},FO:{phoneCode:"298"},FJ:{phoneCode:"679"},FI:{phoneCode:"358"},FR:{phoneCode:"33"},GF:{phoneCode:"594"},PF:{phoneCode:"689"},TF:{phoneCode:""},GA:{phoneCode:"241"},GM:{phoneCode:"220"},GE:{phoneCode:"995"}
1,DE:{phoneCode:"49"},GH:{phoneCode:"233"},GI:{phoneCode:"350"},GR:{phoneCode:"30"},GL:{phoneCode:"299"},GD:{phoneCode:"+1-473"},GP:{phoneCode:"590"},GU:{phoneCode:"+1-671"},GT:{phoneCode:"502"},GG:{phoneCode:"+44-1481"},GN:{phoneCode:"224"},GW:{phoneCode:"245"},GY:{phoneCode:"592"},HT:{phoneCode:"509"},HM:{phoneCode:""},HN:{phoneCode:"504"},HK:{phoneCode:"852"},HU:{phoneCode:"36"},IS:{phoneCode:"354"},IN:{phoneCode:"91"},ID:{phoneCode:"62"},IR:{phoneCode:"98"},IQ:{phoneCode:"964"},IE:{phoneCode:"353"},IL:{phoneCode:"972"},IT:{phoneCode:"39"},JM:{phoneCode:"+1-876"},JP:{phoneCode:"81"},JE:{phoneCode:"+44-1534"},JO:{phoneCode:"962"},KZ:{phoneCode:"7"},KE:{phoneCode:"254"},KI:{phoneCode:"686"},KP:{phoneCode:"850"},KR:{phoneCode:"82"},KW:{phoneCode:"965"},KG:{phoneCode:"996"},LA:{phoneCode:"856"},LV:{phoneCode:"371"},LB:{phoneCode:"961"},LS:{phoneCode:"266"},LR:{phoneCode:"231"},LY:{phoneCode:"218"},LI:{phoneCode:"423"},LT:{phoneCode:"370"},LU:{phoneCode:"352"},MO:{phoneCode:"853"},MK:{phoneCode:"389"},MG:{phoneCode:"261"},MW:{phoneCode:"265"},MY:{phoneCode:"60"},MV:{phoneCode:"960"},ML:{phoneCode:"223"},MT:{phoneCode:"356"},IM:{phoneCode:"+44-1624"},MH:{phoneCode:"692"},MQ:{phoneCode:"596"},MR:{phoneCode:"222"},MU:{phoneCode:"230"},YT:{phoneCode:"262"},MX:{phoneCode:"52"},FM:{phoneCode:"691"},MD:{phoneCode:"373"},MC:{phoneCode:"377"},MN:{phoneCode:"976"},ME:{phoneCode:"382"},MS:{phoneCode:"+1-664"},MA:{phoneCode:"212"},MZ:{phoneCode:"258"},MM:{phoneCode:"95"},NA:{phoneCode:"264"},NR:{phoneCode:"674"},NP:{phoneCode:"977"},BQ:{phoneCode:"599"},NL:{phoneCode:"31"},NC:{phoneCode:"687"},NZ:{phoneCode:"64"},NI:{phoneCode:"505"},NE:{phoneCode:"227"},NG:{phoneCode:"234"},NU:{phoneCode:"683"},NF:{phoneCode:"672"},MP:{phoneCode:"+1-670"},NO:{phoneCode:"47"},OM:{phoneCode:"968"},PK:{phoneCode:"92"},PW:{phoneCode:"680"},PS:{phoneCode:"970"},PA:{phoneCode:"507"},PG:{phoneCode:"675"},PY:{phoneCode:"595"},PE:{phoneCode:"51"},PH:{phoneCode:"63"},PN:{phoneCode:"870"},PL:{phoneCode:"48"},PT:{phoneCode:"351"},PR:{phoneCode:"+1-787 and 1-939"},QA:{phoneCode:"974"},RE:{phoneCode:"262"},RO:{phoneCode:"40"},RU:{phoneCode:"7"},RW:{phoneCode:"250"},SH:{phoneCode:"290"},KN:{phoneCode:"+1-869"},LC:{phoneCode:"+1-758"},PM:{phoneCode:"508"},VC:{phoneCode:"+1-784"},BL:{phoneCode:"590"},MF:{phoneCode:"590"},WS:{phoneCode:"685"},SM:{phoneCode:"378"},ST:{phoneCode:"239"},SA:{phoneCode:"966"},SN:{phoneCode:"221"},RS:{phoneCode:"381"},SC:{phoneCode:"248"},SL:{phoneCode:"232"},SG:{phoneCode:"65"},SK:{phoneCode:"421"},SI:{phoneCode:"386"},SB:{phoneCode:"677"},SO:{phoneCode:"252"},ZA:{phoneCode:"27"},GS:{phoneCode:""},SS:{phoneCode:"211"},ES:{phoneCode:"34"},LK:{phoneCode:"94"},SD:{phoneCode:"249"},SR:{phoneCode:"597"},SJ:{phoneCode:"47"},SZ:{phoneCode:"268"},SE:{phoneCode:"46"},CH:{phoneCode:"41"},SY:{phoneCode:"963"},TW:{phoneCode:"886"},TJ:{phoneCode:"992"},TZ:{phoneCode:"255"},TH:{phoneCode:"66"},TG:{phoneCode:"228"},TK:{phoneCode:"690"},TO:{phoneCode:"676"},TT:{phoneCode:"+1-868"},TN:{phoneCode:"216"},TR:{phoneCode:"90"},TM:{phoneCode:"993"},TC:{phoneCode:"+1-649"},TV:{phoneCode:"688"},UG:{phoneCode:"256"},UA:{phoneCode:"380"},AE:{phoneCode:"971"},GB:{phoneCode:"44"},US:{phoneCode:"1"},UM:{phoneCode:"1"},UY:{phoneCode:"598"},UZ:{phoneCode:"998"},VU:{phoneCode:"678"},VA:{phoneCode:"379"},VE:{phoneCode:"58"},VN:{phoneCode:"84"},VG:{phoneCode:"+1-284"},VI:{phoneCode:"+1-340"},WF:{phoneCode:"681"},EH:{phoneCode:"212"},YE:{phoneCode:"967"},ZM:{phoneCode:"260"},ZW:{phoneCode:"263"},XK:{phoneCode:"383"},CW:{phoneCode:"599"},SX:{phoneCode:"1721"}},STCode={alabama:"AL",alaska:"AK",arizona:"AZ",arkansas:"AR",california:"CA",colorado:"CO",connecticut:"CT",delaware:"DE",florida:"FL",georgia:"GA",hawaii:"HI",idaho:"ID",illinois:"IL",indiana:"IN",iowa:"IA",kansas:"KS",kentucky:"KY",louisiana:"LA",maine:"ME",maryland:"MD",massachusetts:"MA",michigan:"MI",minnesota:"MN",mississippi:"MS",missouri:"MO",montana:"MT",nebraska:"NE",nevada:"NV","new hampshire":"NH","new jersey":"NJ","new mexico":"NM","new york":"NY","north carolina":"NC","north dakota":"ND",ohio:"OH",oklahoma:"OK",oregon:"OR",pennsylvania:"PA","rhode island":"RI","south carolina":"SC","south dakota":"SD",tennessee:"TN",texas:"TX",utah:"UT",vermont:"VT",virginia:"VA",washington:"WA","west Virginia":"WV",wisconsin:"WI",wyoming:"WY","american samoa":"AS",guam:"GU","northern mariana islands":"MP","puerto rico":"PR","virgin islands":"VI"};let pathname=location.pathname;(function(t){var e={};function n(o){if(e[o])return e[o].exports;var i=e[o]={i:o,l:!1,exports:{}};
1return t[o].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t2,e2,o){n.o(t2,e2)||Object.defineProperty(t2,e2,{enumerable:!0,get:o})},n.r=function(t2){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(t2,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t2,"__esModule",{value:!0})},n.t=function(t2,e2){if(1&e2&&(t2=n(t2)),8&e2||4&e2&&typeof t2=="object"&&t2&&t2.__esModule)return t2;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t2}),2&e2&&typeof t2!="string")for(var i in t2)n.d(o,i,function(e3){return t2[e3]}.bind(null,i));return o},n.n=function(t2){var e2=t2&&t2.__esModule?function(){return t2.default}:function(){return t2};return n.d(e2,"a",e2),e2},n.o=function(t2,e2){return Object.prototype.hasOwnProperty.call(t2,e2)},n.p="/",n(n.s=4)})({"/SWy":function(t,e,n){"use strict";n.r(e);var o,i=n("o0o1"),a=n.n(i);function r(t2,e2,n2,o2,i2,a2,r2){try{var c2=t2[a2](r2),s2=c2.value}catch(t3){return void n2(t3)}c2.done?e2(s2):Promise.resolve(s2).then(o2,i2)}function c(t2){return(function(t3){if(Array.isArray(t3)){for(var e2=0,n2=new Array(t3.length);e2<t3.length;e2++)n2[e2]=t3[e2];return n2}})(t2)||(function(t3){if(Symbol.iterator in Object(t3)||Object.prototype.toString.call(t3)==="[object Arguments]")return Array.from(t3)})(t2)||(function(){throw new TypeError("Invalid attempt to spread non-iterable instance")})()}function s(t2,e2){for(var n2=0;n2<e2.length;n2++){var o2=e2[n2];o2.enumerable=o2.enumerable||!1,o2.configurable=!0,"value"in o2&&(o2.writable=!0),Object.defineProperty(t2,o2.key,o2)}}function u(t2,e2){var n2=Object.keys(t2);if(Object.getOwnPropertySymbols){var o2=Object.getOwnPropertySymbols(t2);e2&&(o2=o2.filter(function(e3){return Object.getOwnPropertyDescriptor(t2,e3).enumerable})),n2.push.apply(n2,o2)}return n2}function l(t2){for(var e2=1;e2<arguments.length;e2++){var n2=arguments[e2]!=null?arguments[e2]:{};e2%2?u(n2,!0).forEach(function(e3){d(t2,e3,n2[e3])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t2,Object.getOwnPropertyDescriptors(n2)):u(n2).forEach(function(e3){Object.defineProperty(t2,e3,Object.getOwnPropertyDescriptor(n2,e3))})}return t2}function d(t2,e2,n2){return e2 in t2?Object.defineProperty(t2,e2,{value:n2,enumerable:!0,configurable:!0,writable:!0}):t2[e2]=n2,t2}var h=150,p="PageView",g="ViewContent",f="AddToCart",v="Purchase",m="InitiateCheckout",y="TrackifyXRetarget",_="Products",w="Orders",k="Collections",C="ThankYou",E="Search",b="ZipifyPage",S="GemProductPage",T="BetterCartCheckoutThankYou",P=(d(o={AF:"afghanistan",AL:"albania",DZ:"algeria",AS:"americansamoa",AD:"andorra",AO:"angola",AI:"anguilla",AQ:"antarctica",AG:"antiguaandbarbuda",AR:"argentina",AM:"armenia",AW:"aruba",AU:"australia",AT:"austria",AZ:"azerbaijan",BS:"bahamas",BH:"bahrain",BD:"bangladesh",BB:"barbados",BY:"belaruz",BE:"belgium",BZ:"belize",BJ:"benin",BM:"bermuda",BT:"bhutan",BO:"bolivia",BA:"bosniaandherzegovina",BW:"botswana",BV:"bouvetisland",BR:"brazil",BN:"brunei",BG:"bulgaria",BF:"burkinafaso",BI:"burundi",KH:"cambodia",CM:"cameroon",CA:"canada",CV:"capeVerde",KY:"caymanislands",CF:"centralafricanrepublic",TD:"chad",CL:"chile",CN:"china",CX:"christmasisland",CC:"cocos",CO:"colombia",KM:"comoros",CG:"congo",CK:"cookislands",CR:"costarica",CI:"cotedivoire",HR:"croatia",CU:"cuba",CY:"cyprus",CZ:"czechrepublic",CS:"czechoslavakia",DK:"denmark",DJ:"djibouti",DM:"dominica",DO:"dominicanrepublic",TP:"easttimor",EC:"ecuador",EG:"egypt",SV:"elsalvador",GQ:"equatorialguinea",ER:"eritrea",EE:"estonia",ET:"ethiopia",FK:"falklandislands",FO:"faroeislands",FJ:"fiji",FI:"finland",FR:"france",GF:"frenchguiana"},"GF","frenchguyana"),d(o,"PF","frencpolynesia"),d(o,"GA","gabon"),d(o,"GM","gambia"),d(o,"GE","georgia"),d(o,"DE","germany"),d(o,"GH","ghana"),d(o,"GI","gibraltar"),d(o,"GB","greatbritain"),d(o,"GB","unitedkingdom"),d(o,"GR","greece"),d(o,"GL","greenland"),d(o,"GD","grenada"),d(o,"GP","guadeloupe"),d(o,"GU","guam"),d(o,"GT","guatemala"),d(o,"GN","guinea"),d(o,"GW","guinea-bissau"),d(o,"GY","guyana"),d(o,"HT","haiti"),d(o,"HM","heardislandandmcdonaldislands"),d(o,"VA","holysee"),d(o,"VA","vaticancity"),d(o,"HN","honduras"),d(o,"HK","hongKong"),d(o,"HU","hungary"),d(o,"IS","iceland"),d(o,"IN","india"),d(o,"ID","indonesia"),d(o,"IR","iran"),d(o,"IR","islamicrepublicOfiran"),d(o,"IQ","iraq"),d(o,"IE","ireland"),d(o,"IL","israel"),d(o,"IT","italy"),d(o,"JM","jamaica"),d(o,"JP","japan"),d(o,"JO","jordan"),d(o,"KZ","kazakstan"),d(o,"KZ","kazakhstan"),d(o,"KE","kenya"),d(o,"KI","kiribati"),d(o,"KP","northkorea"),d(o,"KR","southkorea"),d(o,"KW","kuwait"),d(o,"KG","kyrgyzstan"),d(o,"LA","laos"),d(o,"LV","latvia"),d(o,"LB","lebanon"),d(o,"LS","lesotho"),d(o,"LR","liberia"),d(o,"LY","libya"),d(o,"LI","liechtenstein"),d(o,"LT","lithuania"),d(o,"LU","luxembourg"),d(o,"MO","macau"),d(o,"MK","macedonia"),d(o,"MG","madagascar"),d(o,"MW","malawi"),d(o,"MY","malaysia"),d(o,"MV","maldives"),d(o,"ML","mali"),d(o,"MT","malta"),d(o,"MH","marshallislands"),d(o,"MQ","martinique"),d(o,"MR","mauritania"),d(o,"MU","mauritius"),d(o,"YT","mayotte"),d(o,"MX","mexico"),d(o,"FM","micronesia"),d(o,"MD","moldova"),d(o,"MC","monaco"),d(o,"MN","mongolia"),d(o,"MS","montserrat"),d(o,"MA","morocco"),d(o,"MZ","mozambique"),d(o,"MM","myanmar"),d(o,"NA","namibia"),d(o,"NR","nauru"),d(o,"NP","nepal"),d(o,"NL","netherlands"),d(o,"AN","netherlandsantilles"),d(o,"NC","newcaledonia"),d(o,"NZ","newzealand"),d(o,"NI","nicaragua"),d(o,"NE","niger"),d(o,"NG","nigeria"),d(o,"NU","niue"),d(o,"NF","norfolkisland"),d(o,"MP","northernmarianaislands"),d(o,"NO","norway"),d(o,"OM","oman"),d(o,"PK","pakistan"),d(o,"PW","palau"),d(o,"PS","palestinianstate"),d(o,"PA","panama"),d(o,"PG","papuanewguinea"),d(o,"PY","paraguay"),d(o,"PE","peru"),d(o,"PH","philippines"),d(o,"PN","pitcairnisland"),d(o,"PL","poland"),d(o,"PT","portugal"),d(o,"PR","puertorico"),d(o,"QA","qatar"),d(o,"RO","romania"),d(o,"RU","russianfederation"),d(o,"RW","rwanda"),d(o,"SH","sainthelena"),d(o,"KN","saintKittsandnevis"),d(o,"LC","saintlucia"),d(o,"PM","saintpierreandmiquelon"),d(o,"VC","saintvincentandthegrenadines"),d(o,"WS","samoa"),d(o,"SM","sanmarino"),d(o,"ST","saotomeandtrincipe"),d(o,"SA","saudiarabia"),d(o,"RS","serbia"),d(o,"SN","senegal"),d(o,"SC","seychelles"),d(o,"SL","sierraleone"),d(o,"SG","singapore"),d(o,"SK","slovakia"),d(o,"SI","slovenia"),d(o,"SB","solomon"),d(o,"SO","somalia"),d(o,"ZA","southafrica"),d(o,"GS","southgeorgiaandthesouthsandwichislands"),d(o,"ES","spain"),d(o,"LK","sriLanka"),d(o,"SD","sudan"),d(o,"SR","suriname"),d(o,"SJ","svalbard"),d(o,"SZ","swaziland"),d(o,"SE","sweden"),d(o,"CH","switzerland"),d(o,"SY","syria"),d(o,"TW","taiwan"),d(o,"TJ","tajikistan"),d(o,"TZ","tanzania"),d(o,"TH","thailand"),d(o,"TG","togo"),d(o,"TK","tokelau"),d(o,"TO","tonga"),d(o,"TT","trinidadandtobago"),d(o,"TE","tromelinisland"),d(o,"TN","tunisia"),d(o,"TR","turkey"),d(o,"TM","turkmenistan"),d(o,"TC","turksandcaicosislands"),d(o,"TV","tuvalu"),d(o,"UG","uganda"),d(o,"UA","ukraine"),d(o,"AE","unitedarabemirates"),d(o,"US","unitedstates"),d(o,"UY","uruguay"),d(o,"UZ","uzbekistan"),d(o,"VU","vanuatu"),d(o,"VA","vaticancitystate"),d(o,"VE","venezuela"),d(o,"VN","vietnam"),d(o,"VI","virginislandsbritish"),d(o,"VQ","virginislandsunitedstates"),d(o,"WF","wallisandfutunaislands"),d(o,"EH","westernsahara"),d(o,"YE","yemen"),d(o,"YU","yugoslavia"),d(o,"ZR","zaire"),d(o,"ZM","zambia"),d(o,"ZW","zimbabwe"),o);function L(t2){var e2=null;return window.location.href.indexOf(t2)>-1&&window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi,function(t3,n2,o2){e2=o2}),e2}function O(t2,e2){var n2=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};
1(n2=l({path:"/",SameSite:"Strict"},n2)).expires&&n2.expires.toUTCString&&(n2.expires=n2.expires.toUTCString());var o2=encodeURIComponent(t2)+"="+encodeURIComponent(e2);for(var i2 in n2){o2+="; "+i2;var a2=n2[i2];a2!==!0&&(o2+="="+a2)}document.cookie=o2}function I(t2){var e2=document.cookie.match(new RegExp("(?:^|; )"+t2.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g,"\\$1")+"=([^;]*)"));return e2?decodeURIComponent(e2[1]):null}function F(t2){O(t2,"",{"max-age":-1})}function A(t2,e2){for(var n2=e2.split("."),o2=0,i2=n2.length;o2<i2;o2++){if(!t2||!t2[n2[o2]])return!1;t2=t2[n2[o2]]}return!0}function x(t2,e2){for(var n2=e2.split("."),o2=0,i2=n2.length;o2<i2;o2++){if(!t2||!t2[n2[o2]])return null;t2=t2[n2[o2]]}return t2}function U(t2){var e2=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return new Promise(function(n2,o2){var i2=new XMLHttpRequest;i2.open(e2.method||"GET",t2),e2.headers&&Object.keys(e2.headers).forEach(function(t3){i2.setRequestHeader(t3,e2.headers[t3])}),i2.onload=function(){i2.status>=200&&i2.status<300?n2(i2.response):o2(i2.statusText)},i2.onerror=function(){return o2(i2.statusText)},i2.send(e2.body)})}function UU(t2){var e2=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};let data=JSON.parse(e2.body),IpInfo=e2.client_ip_address;if(["ViewContent","AddToCart","InitiateCheckout"].indexOf(data.ev)<0)return new Promise(function(resolve,reject){resolve(null)});(JSON.stringify(IpInfo)==="{}"||!IpInfo)&&(IpInfo=FaceBook&&FaceBook.IpInfo||{});let PIXELDATA=localStorage.getItem("PIXELDATA");PIXELDATA&&(PIXELDATA=JSON.parse(PIXELDATA));let{am,us,ev,ssed,px}=data,user={country:us.country&&us.country.toUpperCase()||am&&am.country&&am.country.toUpperCase()||IpInfo.country_code&&IpInfo.country_code.toUpperCase(),external_id:(A(window,"ShopifyAnalytics.lib.user")?window.ShopifyAnalytics.lib.user().traits().uniqToken:null)||us.external_id||am.external_id,client_ip_address:IpInfo.ip||data.uip,client_user_agent:navigator.userAgent||window.ua,fbc:FaceBook&&FaceBook.Cookies._fbc||us.fbc||am&&am.fbc,fbp:FaceBook&&FaceBook.Cookies._fbp||us.fbp||am&&am.fbp,em:us.em||am&&am.em||(PIXELDATA?PIXELDATA.em:""),ph:us.ph||(PIXELDATA?PIXELDATA.ph:""),fn:us.fn||(PIXELDATA?PIXELDATA.fn:""),ln:us.ln||(PIXELDATA?PIXELDATA.ln:""),ct:us.ct||(PIXELDATA?PIXELDATA.ct:""),zp:us.zp||(PIXELDATA?PIXELDATA.zp:""),st:us.st||(PIXELDATA?PIXELDATA.st:"")},event={},eventTypeObject={ViewContent:0,AddToCart:1,InitiateCheckout:2,Purchase:3};event.event_type=eventTypeObject[ev],event.event_params={event_name:ev,event_time:parseInt(new Date(data.ts).getTime()/1e3).toString(),event_id:data.evId,event_source_url:data.url};let num_items=ssed.contents.reduce((a2,b2)=>a2+b2.quantity,0);event.custom_params={content_type:ssed.content_type,content_ids:typeof ssed.content_ids!="string"?[ssed.content_ids.toString()]:ssed.content_ids.map(a2=>a2.toString()),content_name:ssed.content_name,currency:ssed.currency,value:ssed.value,num_items:num_items.toString()||ssed.num_items||"1",content_category:ssed.content_category,contents:ssed.contents.map(a2=>(a2.id=a2.id.toString(),a2))},ev==="Purchase"&&(event.custom_params.order_id=Number(data.evId));let extra={pixel_id:px[0],distinct_id:FaceBook.GetCookie()},params={user,events:[event],site:"Commense",extra};return new Promise(function(resolve,reject){fetch("https://capi.thecommense.com/capi/v1/events",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(params)}).then(res=>res.json()).then(res=>{resolve(res)}).catch(e3=>reject(e3))})}function AWSUploadData(r2,pixel_id,event,data,eventID,initData){if(["ViewContent","AddToCart","InitiateCheckout","Purchase"].indexOf(event)>-1){let params={pixel_id,initData,data};params.event=event+"Data",event==="Purchase"&&(params.order_id=eventID.eventID)}}function D(){var t2=new Date().toLocaleString("en-US",{timeZone:"America/New_York"}),e2=new Date(t2),n2=e2.toDateString().split(" "),o2=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"][e2.getDay()];return n2[1]+"_"+e2.getDate()+"_"+e2.getFullYear()+"_"+o2+"_Hour_"+e2.getHours()}function N(t2){return typeof t2!="string"?"":t2.charAt(0).toUpperCase()+t2.slice(1)}function R(t2,e2,n2){e2.split(" ").forEach(function(e3){return t2.addEventListener(e3,n2,!1)})}function q(){var t2,e2={options:[],header:[navigator.platform,navigator.userAgent,navigator.appVersion,navigator.vendor,window.opera],dataos:[{name:"Windows Phone",value:"Windows Phone",version:"OS"},{name:"Windows",value:"Win",version:"NT"},{name:"iPhone",value:"iPhone",version:"OS"},{name:"iPad",value:"iPad",version:"OS"},{name:"Kindle",value:"Silk",version:"Silk"},{name:"Android",value:"Android",version:"Android"},{name:"PlayBook",value:"PlayBook",version:"OS"},{name:"BlackBerry",value:"BlackBerry",version:"/"},{name:"Macintosh",value:"Mac",version:"OS X"},{name:"Linux",value:"Linux",version:"rv"},{name:"Palm",value:"Palm",version:"PalmOS"}],databrowser:[{name:"Chrome",value:"Chrome",version:"Chrome"},{name:"Firefox",value:"Firefox",version:"Firefox"},{name:"Safari",value:"Safari",version:"Version"},{name:"Internet Explorer",value:"MSIE",version:"MSIE"},{name:"Opera",value:"Opera",version:"Opera"},{name:"BlackBerry",value:"CLDC",version:"CLDC"},{name:"Mozilla",value:"Mozilla",version:"Mozilla"}],init:function(){var t3=this.header.join(" ");return{os:this.matchItem(t3,this.dataos),browser:this.matchItem(t3,this.databrowser)}},matchItem:function(t3,e3){var n2,o2,i2,a2=0,r2=0;for(a2=0;a2<e3.length;a2+=1)if(new RegExp(e3[a2].value,"i").test(t3)){if(n2=new RegExp(e3[a2].version+"[- /:;]([\\d._]+)","i"),i2="",(o2=t3.match(n2))&&o2[1]&&(o2=o2[1]),o2)for(o2=o2.split(/[._]+/),r2=0;r2<o2.length;r2+=1)i2+=r2===0?o2[r2]+".":o2[r2];else i2="0";return{name:e3[a2].name,version:parseFloat(i2)}}return{name:"unknown",version:0}}}.init();return{osName:e2.os?e2.os.name:"unknown",osVersion:e2.os?e2.os.version:"unknown",browserName:e2.browser?e2.browser.name:"unknown",browserVersion:e2.browser?e2.browser.version:"unknown",navigatorUserAgent:navigator.version||"unknown",isMobile:(t2=navigator.userAgent||navigator.vendor||window.opera,/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(t2)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|
1sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(t2.substr(0,4))?1:0)}}function j(t2,e2,n2){document.querySelector(t2)||e2<=0?n2(document.querySelector(t2)):window.setTimeout(function(){j(t2,--e2,n2)},250)}function M(t2,e2,n2){document.querySelectorAll(t2)||e2<=0?n2(document.querySelectorAll(t2)):window.setTimeout(function(){M(t2,--e2,n2)},250)}var X=(function(){function t2(){(function(t3,e3){if(!(t3 instanceof e3))throw new TypeError("Cannot call a class as a function")})(this,t2),this.backendURL="https://trackifyx.redretarget.com",this.commenseBaseURL="https://capi.thecommense.com",this.uniqueId="_"+Math.random().toString(36).substr(2,9),this.shopName=null,this.shopHost="",this.shop=null,this.isZipifyTagsCollectionsLoaded=!1,this.isLogingZipifyTagsCollections=!1,this.zipifyProductsTagsCollections=[],this.collections=[],this.tags=[],this.pixels=[],this.initializedPixels=[],this.page=null,this.product=null,this.cart=null,this.checkout=null,this.isTriggeredByState=!1,this.isLoadingProduct=!1,this.isAddingToCart=!1,this.isFetchingShop=!1,this.isFetchingCart=!1,this.user=this.saveEmptyUser(),this.maxAttemps=h,this.debug=!0,this.eventPrefix="",this.timeOnPage=0,this.reloadCartAttemps=5,this.timeOnSite=parseInt(localStorage.getItem("TFX_TIME_ON_SITE")||0),this.isLoaded=!1,this.productIds=[],this.pixelEvent=!0,this.advanceMatching=!0,this.isIOS14=!1,this.viewCategoryEventFire=!0,this.viewContentEventFire=!0,this.viewCartEventFire=!0,this.pageViewEventFire=!0,this.customizeProductEventFire=!0,this.addToCartEventFire=!0,this.initiateCheckoutEventFire=!0,this.addPaymentLeadEventFire=!0,this.addShippingInfoEventFire=!0,this.addPaymentInfoEventFire=!0,this.purchaseEventFire=!0,this.addToWishlistEventFire=!0,this.searchEventFire=!0,this.contactEventFire=!0,this.timerEventFire=!0,this.isScriptInIframe=window.self!==window.top,this.upsellInCartOnce=!0,this.incartForms=0,this.isBetterCart=!1,this.isPageFlyPage=!1,this.isShogunPage=!1,this.interCartEvents=[],this.interCartEvent=null,this.triggerQueue(),this.triggerATCQueue(),this.iscategoryswatchloaded=0,this.client_ip_address={},this.is_client_ip_address_loaded=!1}var e2,n2,o2;return e2=t2,(n2=[{key:"reset",value:function(){this.tags=[],this.collections=[],this.page=null,this.product=null,this.maxAttemps=h}},{key:"init",value:function(){var t3=this,e3=window.location.href;e3=e3.replace("https://",""),!this.is_client_ip_address_loaded&&(e3.includes("/products/")||e3.includes("/cart")||e3.includes("/thank_you")||e3.includes("/checkouts/"))&&(this.is_client_ip_address_loaded=!0,this.getipInfo()),this.isResourcesLoaded()?this.shop.enabled?(this.loadIOSDeviceVersions(),this.setup()):this.consoleLog("This shop is disabled"):(this.maxAttemps===h&&this.load(),setTimeout(function(){if(--t3.maxAttemps<=0){var e4=t3.getFailMessage();t3.consoleLog(e4),t3.consoleLog(t3)}else t3.load(),t3.loadIOSDeviceVersions(),t3.init()},30))}},{key:"getipInfo",value:function(){}},{key:"initTrackingConsent",value:function(){var t3=this;if(t3.consoleLog("init tracking function is called"),x(window,"Shopify.loadFeatures"))t3.consoleLog("Shopify.loadFeatures property loaded"),window.Shopify.loadFeatures([{name:"consent-tracking-api",version:"0.1"}],function(e4){if(e4)throw t3.consoleLog(e4,"Shopify.loadFeatures property error"),e4;t3.initCookieBanner()});else{if(t3.consoleLog("Shopify.loadFeatures property not loaded"),!localStorage.getItem("TFX_CONSENT"))return;t3.consoleLog("TFX Consent available");var e3=JSON.parse(localStorage.getItem("TFX_CONSENT")),n3=e3.userCanBeTracked,o3=e3.userTrackingConsent;if(t3.consoleLog(' tracking consent response : User Can Be Tracked "'.concat(n3,'"')),t3.consoleLog(' tracking consent response : Get Tracking consent "'.concat(o3,'"')),!n3&&o3==="no_interaction"||o3==="no")switch(this.shop.tracking_consent_api){case"all":this.pixelEvent=!1,t3.consoleLog("Pixel Is blocked because tracking consent is not given");break;case"advance":t3.consoleLog("Advance Matching Is blocked because tracking consent is not given"),this.advanceMatching=!1}}}},{key:"initCookieBanner",value:function(){var t3=window.Shopify.customerPrivacy.userCanBeTracked();this.consoleLog("Cookie Banner Function is called");var e3=window.Shopify.customerPrivacy.getTrackingConsent();this.consoleLog(' tracking consent response : User Can Be Tracked "'.concat(t3,'"')),this.consoleLog(' tracking consent response : Get Tracking consent "'.concat(e3,'"'));var n3={userCanBeTracked:t3,userTrackingConsent:e3};if(this.setConsent(n3),!t3&&e3==="no_interaction"||e3==="no")switch(this.shop.tracking_consent_api){case"all":this.pixelEvent=!1,this.consoleLog("Pixel Is blocked because tracking consent is not given");break;case"advance":this.consoleLog("Advance Matching Is blocked because tracking consent is not given"),this.advanceMatching=!1}return!0}},{key:"setConsent",value:function(t3){t3&&localStorage.setItem("TFX_CONSENT",JSON.stringify(t3))}},{key:"load",value:function(){this.setUTMs(),this.user||this.getUserExternalId(),this.page||this.setPage(),this.shopName||this.setShopName(),"fbq"in window||this.loadPixelLibrary(),!this.shop&&this.shopName&&this.loadShopSettings(),this.shop&&!this.product&&this.loadProduct(),this.tags.length||this.loadTags(),this.collections.length||this.loadCollections(),this.cart||this.loadCart(),[C,w,T].indexOf(this.page)===-1||this.checkout||this.loadCheckout(),this.isTriggeredByState&&this.page===_&&this.setTagsCollections(window.location.pathname),this.page!==b||this.isZipifyTagsCollectionsLoaded||this.setZipifyTagsCollections(),this.page==="UpSellPage"&&this.getOCUProduct()}},{key:"loadIOSDeviceVersions",value:function(){}},{key:"getFailMessage",value:function(){var t3=[];switch("fbq"in window||t3.push("FB Pixel script is not loaded"),this.shop||t3.push("Can not get shop info"),this.shopName||t3.push("Can not get shop name"),this.page||t3.push("Can not get page"),this.page){case S:case"PageFly":case"Shogun":case _:this.product||t3.push("Can not get product checking zipify pages"),A(window,"ZipifyPages")&&(this.page=b,this.init());break;case"Cart":this.cart||t3.push("Can not get cart");break;case C:this.checkout||t3.push("Can not get checkout")}return t3.join(`
2* `)}},{key:"isResourcesLoaded",value:function(){var t3="fbq"in window&&this.shopName&&this.shop&&this.page,e3=!0;switch(this.page){case S:case _:e3=this.product;break;case"PageFly":window.__pageflyProducts&&(e3=this.product&&this.collections);break;case"Shogun":window.__shgProducts&&window.__shgProducts.length&&(e3=this.product&&this.collections);break;case"Cart":e3=this.cart;break;case C:e3=this.checkout}return t3&&e3}},{key:"setup",value:function(){if(this.isLoaded)this.consoleLog("TFX already loaded");else{this.setDebugMode(),this.consoleLog("setup function is called"),this.consoleLog("USER",this.user),this.initTrackingConsent();var t3=this;setTimeout(function(){t3.consoleLog("TFX ID: "+t3.uniqueId),t3.isLoaded=!0,t3.setEventsPrefix(),t3.consoleLog("Loaded",t3),t3.consoleLog(' Page is "'.concat(t3.page,'"')),t3.filterPixels()&&t3.pixelEvent?(t3.initPixels(),t3.fireEvents(),t3.isEventsAttached||t3.attachListeners(),t3.shop.time_on_site&&t3.trackTime()):t3.consoleLog("No Attached Pixels to current scenario")},500)}}},{key:"setEventsPrefix",value:function(){A(window,"OCUConfig")&&(this.eventPrefix="OCU")}},{key:"setDebugMode",value:function(){this.debug=this.shop.debug}},{key:"consoleLog",value:function(){if(this&&this.debug){var t3=[];t3.push("TFX:");for(var e3=0;e3<arguments.length;e3++)t3.push(arguments[e3]);console.log.apply(console,t3)}}},{key:"setPage",value:function(){var t3=this,e3=window.location.href,n3=this;if((e3=e3.replace("https://","")).includes("/collections")&&(this.page=k),e3.includes("/products/")&&(this.page=_),e3.
2includes("/cart"))this.page="Cart";else{if((e3.includes("/checkouts/")||e3.includes("/secure-checkout/")&&x(window,"OCUConfig"))&&(this.page="Checkout"),e3.includes("/s/checkout/")&&(this.page="Checkout"),(e3.includes("/secure-checkout/offers/")||e3.includes("/secure-chechout/offers"))&&(this.page="UpSellPage"),e3.includes("/thank_you")&&(this.page=C),e3.includes("/orders/")&&(this.page=w),e3.includes("/secure-checkout/thank_you/")&&(this.page="OCUThankYou"),e3.includes("/account/login")&&(this.page="Login"),e3.includes("/account/register")&&(this.page="SignUp"),e3.includes("/search")&&(this.page=E),e3.includes("apps/fast-checkout/")){e3.includes("checkouts")&&(this.page="BetterCartCheckout");var o3=location.href;setInterval(function(){if(o3!=location.href){o3=location.href;var e4=window.location.href;L("step")!="payment"||I("TFX_BC_PI")||(t3.addPaymentInfoEvent(),O("TFX_BC_PI",!0,{"max-age":60})),(e4.includes("fast-checkout/checkouts")&&e4.includes("order")||e4.includes("fast-checkout/orders")&&e4.includes("thank-you"))&&!window.location.hash&&(window.location=window.location+"#loaded",e4.includes("fast-checkout/orders")&&e4.includes("thank-you")&&(n3.isLoaded=!1,n3.checkout=null,n3.cart=null),n3.reset(),setTimeout(function(){n3.load(),n3.attachListeners(),n3.filterPixels(),n3.initPixels()},500))}},1500),setTimeout(function(){n3.initiateCheckoutEvent()},2e3)}e3.includes("fast-checkout/checkouts")&&e3.includes("order")&&(this.page="BetterCartCheckoutOffer"),e3.includes("fast-checkout/orders")&&e3.includes("thank-you")&&(this.page=T),A(window,"ZipifyPages")&&!e3.includes("/products/")&&(this.page=b),x(window,"CHDataObject.partial_type")==="checkout_page"&&(this.page="CartHookCheckout"),x(window,"CHDataObject.partial_type")==="thank_you_page"&&(this.page="CartHookThankYou"),x(window,"CHDataObject.partial_type")==="upsell_page"&&(this.page="CartHookUpSellPage"),x(window,"CHDataObject.partial_type")==="downsell_page"&&(this.page="CartHookDownSellPage"),x(window,"CHDataObject.partial_type")==="page"&&(this.page="CartHookPage"),document.querySelector("body.gempage")&&e3.includes("/pages/")&&(this.page=S),(e3.includes("/pages/")||e3.includes("/blogs/news/")||e3.includes("/password"))&&document.querySelector('link[href*="pagefly"]')&&(this.page="PageFly"),(e3.includes("/pages/")||e3.includes("/blogs/news/")||e3.includes("/password"))&&document.querySelector('link[href*="shogun"]')&&(this.page="Shogun"),this.page||(this.page="Unknown")}}},{key:"loadPixelLibrary",value:function(){if("fbq"in window)return!0;var t3,e3,n3,o3,i2,a2;t3=window,e3=document,n3="script",t3.fbq||(o3=t3.fbq=function(){o3.callMethod?o3.callMethod.apply(o3,arguments):o3.queue.push(arguments)},t3._fbq||(t3._fbq=o3),o3.push=o3,o3.loaded=!0,o3.version="2.0",o3.queue=[],(i2=e3.createElement(n3)).async=!0,i2.src="https://connect.facebook.net/en_US/fbevents.js",(a2=e3.getElementsByTagName(n3)[0]).parentNode.insertBefore(i2,a2))}},{key:"loadShopSettings",value:function(){if(typeof tfx_shop_settings<"u")console.log("config route not called"),this.shop=tfx_shop_settings,this.product||this.loadProduct();else{var t3=this;if(t3.isFetchingShop)return;t3.isFetchingShop=!0,setTimeout(function(){t3.isFetchingShop=!1},700),console.log("config route called"),U("".concat(this.backendURL,"/pull/config/").concat(this.shopName)).then(function(e3){t3.shop=JSON.parse(e3),t3.isFetchingShop=!1,t3.product||t3.loadProduct()}).catch(function(e3){t3.consoleLog("TFX",e3)})}}},{key:"setShopName",value:function(){this.shopName=x(window,"Shopify.shop")||x(window,"Shopify.Checkout.apiHost")||x(window,"CHDataObject.store_urls.store_url"),window.getOrderRequestObject&&(this.shopName=window.getOrderRequestObject().shop),this.page!="BetterCartCheckout"&&this.page!="BetterCartCheckoutOffer"&&this.page!=T||(this.shopName=window.location.hostname)}},{key:"getUserExternalId",value:function(){var t3=this,e3=5;(function n3(){"Shopify"in window?t3.setUser({external_id:A(window,"ShopifyAnalytics.lib.user")?window.ShopifyAnalytics.lib.user().traits().uniqToken:null}):--e3>=0&&setTimeout(function(){t3.consoleLog("time out for external ID"),n3()},200)})()}},{key:"loadCheckout",value:function(){this.checkout=x(window,"Shopify.checkout"),this.checkout||this.page!=T||(this.checkout=x(window,"bcData.order"),this.checkout.discount=x(window,"bcData.order.coupon"))}},{key:"printTags",value:function(t3){var e3=t3||this.tags||(localStorage.getItem("tags")||"").split(", ");return e3&&e3.length?(t3||(this.tags=e3),c(new Set(e3.map(function(t4){return typeof t4=="string"?t4.toString().trim():t4}).filter(function(t4){return t4.trim()!==""}))).join(", ")):""}},{key:"printCollections",value:function(t3){var e3=t3||this.collections||(localStorage.getItem("collections")||"").split(", ");return e3&&e3.length?(t3||(this.collections=e3),c(new Set(e3.map(function(t4){return typeof t4=="string"?t4.toString().trim():t4}).filter(function(t4){return t4.trim()!==""}))).join(", ")):""}},{key:"clearArray",value:function(t3){return t3&&Array.isArray(t3)?t3.map(function(t4){return t4.trim()}).filter(function(t4){return t4.length>0}):[]}},{key:"loadTags",value:function(){var t3=document.querySelector('meta[name="tfx:tags"]');t3?(this.tags=this.clearArray(t3.content.split(", ")),localStorage.setItem("tags",this.tags.join(", "))):[_,k,S,E,b].indexOf(this.page)===-1&&(this.tags=(localStorage.getItem("tags")||"").split(", "))}},{key:"loadCollections",value:function(){var t3=document.querySelector('meta[name="tfx:collections"]');if(t3)this.collections=t3.content.split(", ").map(function(t4){return t4.trim()}).filter(function(t4){return t4.length>0}),localStorage.setItem("collections",this.collections.join(", "));else{var e3=localStorage.getItem("collections")||"";this.collections=e3.split(", ")}}},{key:"extractTagsCollections",value:function(t3){var e3={tags:[],collections:[]},n3=/<meta name="tfx:tags" content="(.*?)">/g.exec(t3),o3=/<meta name="tfx:collections" content="(.*?)">/g.exec(t3);return n3&&(e3.tags=n3[1].split(", ").map(function(t4){return t4.trim()}).filter(function(t4){return t4.length>0})),o3&&(e3.collections=o3[1].split(", ").map(function(t4){return t4.trim()}).filter(function(t4){return t4.length>0})),e3}},{key:"setTagsCollections",value:function(t3){var e3=this;this.getTagsCollections(t3).then(function(t4){var n3=e3.extractTagsCollections(t4);e3.tags=n3.tags,localStorage.setItem("tags",e3.clearArray(e3.tags).join(", ")),e3.collections=n3.collections,localStorage.setItem("collections",e3.clearArray(e3.collections).join(", "))}).catch(this.consoleLog)}},{key:"getTagsCollections",value:function(t3){return U(t3)}},{key:"setTagsAndCollectionsFromBackend",value:function(t3){var e3=this,n3=this;
2return t3?new Promise(function(o3,i2){U("".concat(e3.backendURL,"/get/").concat(e3.shopName,"/products?ids=")+t3.join(",")).then(function(t4){var a2=JSON.parse(t4);if(a2.products&&a2.products.length){var r2=a2.products.map(function(t5){return new Promise(function(o4,i3){e3.getTagsCollections("".concat(e3.shopHost,"/products/").concat(t5.handle)).then(function(i4){var a3=e3.extractTagsCollections(i4);n3.collections=n3.collections.concat(a3.collections),n3.tags=n3.tags.concat(a3.tags),o4({product_id:t5.id,html:i4})}).catch(function(t6){i3(t6)})})});Promise.all(r2).then(function(){n3.tags=c(new Set(n3.tags)),n3.collections=c(new Set(n3.collections)),n3.filterPixels(),n3.initPixels(),o3()}).catch(function(t5){o3(t5)})}else i2("No products fetched...")}).catch(i2)}):new Promise(function(t4){return t4()})}},{key:"getProduct",value:function(t3){if(t3)return U(t3.endsWith("/")?t3.slice(0,-1):t3+".json")}},{key:"getProductById",value:function(t3){if(t3)return U("".concat(this.backendURL,"/get/").concat(this.shopName,"/products?ids=").concat(t3))}},{key:"loadProduct",value:function(){var t3=this;if(!this.isLoadingProduct){var e3=window.tfxProduct||null;if(setTimeout(function(){t3.incartForms==0&&(t3.incartForms=document.querySelectorAll("form[action='/cart/add'].variants").length,t3.consoleLog(t3.incartForms+" upsell offer"))},1e3),e3)this.product=e3;else{var n3=x(window,"ShopifyAnalytics.meta.page.pageType")?window.ShopifyAnalytics.meta.page.pageType:"Unknown";if(!window.__pageflyProducts||n3!="home"&&n3!="page"&&n3!="article"&&n3!="password"||(this.isPageFlyPage=!0),this.page==="PageFly"){if(!this.shop)return null;if(window.__pageflyProducts)for(var o3 in window.__pageflyProducts)window.__pageflyProducts.hasOwnProperty(o3)&&o3&&(this.product=l({},window.__pageflyProducts[o3].selected_or_first_available_variant),this.shop.report_variants||(this.product.id=parseInt(o3)),this.tags=window.__pageflyProducts[o3].tags,this.setTagsCollections("/products/".concat(window.__pageflyProducts[o3].handle)))}else if(window.__shgProducts!==void 0&&(this.isShogunPage=!0,this.page==="Shogun")){if(!this.shop)return null;if(window.__shgProducts)for(var i2 in this.consoleLog("Is shogun product page"),window.__shgProducts)window.__shgProducts.hasOwnProperty(i2)&&i2&&(this.consoleLog("shogun product"),this.consoleLog(window.__shgProducts[i2]),this.product=window.__shgProducts[i2],this.tags=window.__shgProducts[i2].tags,this.setTagsCollections("/products/".concat(window.__shgProducts[i2].handle)))}this.page==="Cart"&&this.product==null&&this.incartForms>0&&this.getInCartUpsellProduct(this.upsellInCartOnce),this.consoleLog("load product called!!");var a2=document.querySelectorAll("form[action='/cart/add']");if(this.consoleLog("load product addToCartForms.length: "+a2.length),a2.length>0&&this.page!=k&&!this.isPageFlyPage&&!this.isShogunPage){var r2=a2[0],c2=r2.querySelector('input[name="id"]'),s2=r2.getAttribute("id");this.consoleLog("Product Form detected, product id is ".concat(s2)),c2&&c2.getAttribute("data-productid")&&(s2=c2.getAttribute("data-productid")),s2&&(s2=(s2=(s2=(s2=(s2=(s2=(s2=(s2=s2.replace("product_form_","")).replace("upsell_product_form_","")).replace("product-form-","")).replace("product-template","")).replace("AddToCartForm--","")).replace("AddToCartForm-","")).replace("js--","")).replace(/\D/g,""),isNaN(parseInt(s2))&&(s2=r2.getAttribute("data-product_id")),this.consoleLog("Cleared Product ID is: ".concat(parseInt(s2))),parseInt(s2)&&(parseInt(s2)<1e4&&document.querySelector("[product-id]")&&document.querySelector("[product-id]").getAttribute("class").indexOf("arv-collection")!=-1&&(s2=document.querySelector("[product-id]").getAttribute("product-id"),this.consoleLog("more filters with Product ID is: ".concat(parseInt(s2)))),this.isLoadingProduct=!0,this.getProductById(s2).then(function(e4){var n4=JSON.parse(e4);n4.products&&n4.products.length&&(t3.product=n4.products[0],t3.setTagsCollections("/products/".concat(t3.product.handle)),t3.page!=_&&setTimeout(function(){t3.viewContentEvent()},500)),t3.isLoadingProduct=!1}).catch(function(e4){t3.isLoadingProduct=!1,t3.consoleLog("loadProduct",e4)})))}this.product==null&&this.page==="BetterCartCheckoutOffer"&&(this.isLoadingProduct=!0,x(window,"bcData.product")&&this.getProductById(x(window,"bcData.product.product_id")).then(function(e4){var n4=JSON.parse(e4);n4.products&&n4.products.length&&(t3.product=n4.products[0],t3.isLoadingProduct=!1),t3.isLoadingProduct=!1}).then(function(){t3.viewContentEvent()}).catch(function(){t3.isLoadingProduct=!1}))}}}},{key:"getInCartUpsellProduct",value:function(t3){var e3=this;t3&&(this.upsellInCartOnce=!1,document.querySelectorAll("form[action='/cart/add'].variants").forEach(function(t4){var n3=t4.querySelector('*[id^="product-select-"]').options[0].value;parseInt(n3)&&U("".concat(e3.backendURL,"/get/").concat(e3.shopName,"/product/").concat(n3,"/variant")).then((function(){var n4,o3=(n4=a.a.mark(function n5(o4){var i2,r2;return a.a.wrap(function(n6){for(;;)switch(n6.prev=n6.next){case 0:if((i2=JSON.parse(o4)).variant.product_id===void 0){n6.next=6;break}return r2="upsell_product_form_".concat(i2.variant.product_id),t4.setAttribute("id",r2),n6.next=6,e3.getProductById(i2.variant.product_id).then(function(t5){var n7=JSON.parse(t5);n7.products&&n7.products.length&&(e3.product=n7.products[0],e3.consoleLog("upsell offer product set",e3.product))}).catch(function(t5){e3.consoleLog(t5)});case 6:case"end":return n6.stop()}},n5)}),function(){var t5=this,e4=arguments;return new Promise(function(o4,i2){var a2=n4.apply(t5,e4);function c2(t6){r(a2,o4,i2,c2,s2,"next",t6)}function s2(t6){r(a2,o4,i2,c2,s2,"throw",t6)}c2(void 0)})});return function(t5){return o3.apply(this,arguments)}})()).catch(function(t5){e3.consoleLog(t5)})}))}},{key:"setCart",value:function(t3){if(t3){for(var e3 in this.cart||(this.cart={}),t3)t3.hasOwnProperty(e3)&&(this.cart[e3]=t3[e3]);localStorage.setItem("TFX_CART",JSON.stringify(this.cart))}}},{key:"setCartFromStorage",value:function(){var t3=null;if(!localStorage.getItem("TFX_CART"))return t3;try{this.cart=JSON.parse(localStorage.getItem("TFX_CART")),this.consoleLog("Set cart from storage",this.cart),t3=!0}catch(t4){this.consoleLog(t4)}return t3}},{key:"addToCart",value:function(t3){if(t3)try{var e3=JSON.parse(localStorage.getItem("TFX_CART"));e3||(e3={items:[]},localStorage.setItem("TFX_CART",JSON.stringify(e3)));var n3=this.getVariant(t3);n3.line_price=this.shop.value_reporting?this.calculatePrice(n3.price):"0.00",n3.quantity=document.getElementsByName("quantity")[0]?document.getElementsByName("quantity")[0].value:1,n3.product_type=t3.product_type,e3.items.find(function(t4){return t4.id===n3.id})||(e3.items.push(n3),localStorage.setItem("TFX_CART",JSON.stringify(e3))),this.cart=e3}catch(t4){this.consoleLog(t4)}}},{key:"reloadCart",value:function(){var t3=this;if(!this.isFetchingCart&&this.reloadCartAttemps!==0){this.isFetchingCart=!0;
2var e3=x(this.cart,"item_count");U("".concat(this.shopHost,"/cart.json")).then(function(n3){var o3=JSON.parse(n3);t3.isFetchingCart=!1,o3&&(t3.consoleLog("data.items.length",e3),o3.item_count===e3?(t3.reloadCartAttemps--,setTimeout(function(){t3.reloadCart()},500)):(t3.cart=o3,localStorage.setItem("TFX_CART",JSON.stringify(o3))))}).catch(function(e4){t3.consoleLog(e4),t3.isFetchingCart=!1})}}},{key:"loadCart",value:function(){var t3=this;if(!this.isFetchingCart){this.isFetchingCart=!0;var e3=window.tfxCart||null;e3?(this.cart=e3,localStorage.setItem("TFX_CART",JSON.stringify(e3)),this.isFetchingCart=!1):this.setCartFromStorage()?this.isFetchingCart=!1:U("".concat(this.shopHost,"/cart.json")).then(function(e4){var n3=JSON.parse(e4);t3.isFetchingCart=!1,n3&&(t3.cart=n3,localStorage.setItem("TFX_CART",JSON.stringify(n3)))}).catch(function(e4){t3.consoleLog(e4),t3.isFetchingCart=!1})}}},{key:"saveCartProduct",value:function(t3){if(t3)try{var e3=JSON.parse(I("TFX_ATC"));e3.push(t3),O("TFX_ATC",JSON.stringify(c(new Set(e3))),{"max-age":1209600})}catch{O("TFX_ATC",JSON.stringify([t3]),{"max-age":600})}}},{key:"getSavedCartProducts",value:function(){var t3=[];try{t3=JSON.parse(I("TFX_ATC"))}catch(t4){this.consoleLog(t4)}return t3||[]}},{key:"setAdvanceMatchingData",value:function(){this.page===C||this.page===w?x(window,"Shopify.checkout.shipping_address")?this.setUser({em:x(window,"Shopify.checkout.email"),fn:x(window,"Shopify.checkout.shipping_address.first_name")?x(window,"Shopify.checkout.shipping_address.first_name").toLowerCase():"",ln:x(window,"Shopify.checkout.shipping_address.last_name")?x(window,"Shopify.checkout.shipping_address.last_name").toLowerCase():"",ct:x(window,"Shopify.checkout.shipping_address.city")?x(window,"Shopify.checkout.shipping_address.city").toLowerCase().replace(/\s+/g,""):"",zp:x(window,"Shopify.checkout.shipping_address.zip")?x(window,"Shopify.checkout.shipping_address.zip").trim().toLowerCase():"",ph:A(window,"Shopify.checkout.shipping_address.phone")?x(window,"Shopify.checkout.shipping_address.phone"):null}):x(window,"Shopify.checkout.billing_address")?this.setUser({em:x(window,"Shopify.checkout.email"),fn:x(window,"Shopify.checkout.billing_address.first_name")?x(window,"Shopify.checkout.billing_address.first_name").toLowerCase():"",ln:x(window,"Shopify.checkout.billing_address.last_name")?x(window,"Shopify.checkout.billing_address.last_name").toLowerCase():"",ct:x(window,"Shopify.checkout.billing_address.city")?x(window,"Shopify.checkout.billing_address.city").toLowerCase().replace(/\s+/g,""):"",zp:x(window,"Shopify.checkout.billing_address.zip")?x(window,"Shopify.checkout.billing_address.zip").trim().toLowerCase():"",ph:A(window,"Shopify.checkout.billing_address.phone")?x(window,"Shopify.checkout.billing_address.phone"):null}):this.setUser({em:x(window,"Shopify.checkout.email"),fn:"",ln:"",ct:"",zp:"",ph:""}):this.page===T&&x(window,"bcData.order.shipping_address")&&this.setUser({em:x(window,"bcData.order.customer.email"),fn:x(window,"bcData.order.shipping_address.first_name")?x(window,"bcData.order.shipping_address.first_name").toLowerCase():"",ln:x(window,"bcData.order.shipping_address.last_name")?x(window,"bcData.order.shipping_address.last_name").toLowerCase():"",ct:x(window,"bcData.order.shipping_address.city")?x(window,"bcData.order.shipping_address.city").toLowerCase().replace(/\s+/g,""):"",zp:x(window,"bcData.order.shipping_address.zip")?x(window,"bcData.order.shipping_address.zip").trim().toLowerCase():"",ph:A(window,"bcData.order.customer.phone")?x(window,"bcData.order.customer.phone"):""})}},{key:"getAdvanceMatchingData",value:function(){if(this.setAdvanceMatchingData(),!this.shop.advance_matching||!this.advanceMatching)return{};var t3=this.getUser(),e3={};for(var n3 in t3)t3.hasOwnProperty(n3)&&t3[n3]&&"".concat(t3[n3]).trim()&&(e3[n3]=t3[n3].toLowerCase());if(e3.country){var o3=Object.keys(P)[Object.values(P).indexOf(e3.country.toLowerCase().replace(/\s/g,""))];e3.country=o3?o3.toLowerCase().replace(/\s/g,""):""}if(e3.em&&(e3.em=e3.em.toLowerCase().replace(/\s+/g,"")),e3.ph&&(e3.ph=e3.ph.replace(/\s+/g,"").match(/[0-9]/g).join("")),e3.ct&&(e3.ct=e3.ct.toLowerCase().replace(/\s+/g,"")),e3.zp&&(e3.zp=e3.zp.toLowerCase().replace(/\s+/g,"").replace(/\-/g,"")),e3.st&&(e3.st=e3.st.toLowerCase().replace(/\s+/g,"")),Shopify.checkout&&Shopify.checkout.shipping_address){let ShippingAddress=Shopify.checkout.shipping_address;!e3.country&&ShippingAddress.country_code&&(e3.country=ShippingAddress.country_code.toLowerCase().replace(/\s+/g,"")),!e3.st&&ShippingAddress.province&&(e3.st=ShippingAddress.province.toLowerCase().replace(/\s+/g,"")),!e3.zp&&ShippingAddress.zip&&(e3.zp=ShippingAddress.zip.toLowerCase().replace(/\s+/g,"").replace(/\-/g,"")),!e3.ct&&ShippingAddress.city&&(e3.ct=ShippingAddress.city.toLowerCase().replace(/\s+/g,"")),!e3.ph&&ShippingAddress.phone&&(e3.ph=ShippingAddress.phone.replace(/\s+/g,"").match(/[0-9]/g).join("")),!e3.fn&&ShippingAddress.first_name&&(e3.fn=ShippingAddress.first_name.trim().toLowerCase()),!e3.ln&&ShippingAddress.last_name&&(e3.ln=ShippingAddress.last_name.trim().toLowerCase())}let PIXELDATA=localStorage.getItem("PIXELDATA");PIXELDATA&&(PIXELDATA=JSON.parse(PIXELDATA),!e3.em&&PIXELDATA.em&&(e3.em=PIXELDATA.em.toLowerCase().replace(/\s+/g,"")),!e3.ph&&PIXELDATA.ph&&(e3.ph=PIXELDATA.ph.replace(/\s+/g,"").match(/[0-9]/g).join("")),!e3.fn&&PIXELDATA.fn&&(e3.fn=PIXELDATA.fn.trim().toLowerCase()),!e3.ln&&PIXELDATA.ln&&(e3.ln=PIXELDATA.ln.trim().toLowerCase()),!e3.ct&&PIXELDATA.ct&&(e3.ct=PIXELDATA.ct.toLowerCase().replace(/\s+/g,"")),!e3.st&&PIXELDATA.st&&(e3.st=PIXELDATA.st.toLowerCase().replace(/\s+/g,"")),!e3.zp&&PIXELDATA.zp&&(e3.zp=PIXELDATA.zp.toLowerCase().replace(/\s+/g,"").replace(/\-/g,"")),!e3.country&&PIXELDATA.country&&(e3.country=PIXELDATA.country.toLowerCase().replace(/\s+/g,""))),!e3.external_id&&(e3.external_id=A(window,"ShopifyAnalytics.lib.user")?window.ShopifyAnalytics.lib.user().traits().uniqToken:""),!e3.country&&this.client_ip_address.country_code&&(e3.country=this.client_ip_address.country_code.toLowerCase().replace(/\s+/g,"")),!e3.country&&FaceBook&&FaceBook.IpInfo&&(e3.country=FaceBook.IpInfo.country_code.toLowerCase().replace(/\s+/g,"")),!e3.country&&FaceBook&&FaceBook.country&&(e3.country=FaceBook.country.toLowerCase().replace(/\s+/g,"")),!e3.st&&this.client_ip_address.region_code&&(e3.st=this.client_ip_address.region_code.toLowerCase().replace(/\s+/g,"")),!e3.zp&&this.client_ip_address.zip_code&&(e3.zp=this.client_ip_address.zip_code.toLowerCase().replace(/\s+/g,"").replace(/\-/g,"")),!e3.ct&&this.client_ip_address.city&&(e3.ct=this.client_ip_address.city.toLowerCase().replace(/\s+/g,""));let precode=e3.country&&CountryCode[e3.country.toUpperCase()]&&CountryCode[e3.country.toUpperCase()].phoneCode||"";return e3.st&&(e3.st=e3.country=="us"&&STCode[e3.st.toLowerCase()]&&STCode[e3.st.toLowerCase()].toLowerCase()||e3.st),e3.ph&&(precode&&e3.ph.indexOf(precode)==0&&(e3.ph=e3.ph.split(precode).slice(1).join(precode)),e3.ph=e3.ph.replace(/^0+/,""),e3.ph=precode+e3.ph),localStorage.setItem("PIXELDATA",JSON.stringify({em:e3.em,ph:e3.ph,fn:e3.fn,ln:e3.ln,ct:e3.ct,st:e3.st,zp:e3.zp,country:e3.country})),e3}},{key:"filterPixels",value:function(){var t3=this;return t3.consoleLog("Tags: ".concat(t3.tags)),t3.consoleLog("Collections: ".concat(t3.collections)),t3.pixels=t3.shop.pixels.filter(function(e3){var n3=e3.context?e3.context.filter(function(e4){return t3.tags.indexOf(e4.trim())!==-1}):[],o3=e3.context?e3.context.filter(function(e4){return t3.collections.indexOf(e4.trim())!==-1}):[];return t3.consoleLog("".concat(e3.pixel_id," - Matched Tags ").concat(n3.join(", "),", Matched Collections ").concat(o3.join(", "))),e3.type==="master"||e3.type==="tag"&&n3.length||e3.type==="collection"&&o3.length}),t3.pixels.length}},{key:"initPixels",value:function(){var t3=this,e3=t3.getAdvanceMatchingData();
2t3.pixels.forEach(function(n3){t3.shop.ccpa==="geo"&&fbq("dataProcessingOptions",["LDU"],0,0),t3.shop.ccpa==="disabled"&&fbq("dataProcessingOptions",[]),t3.shop.microdata||fbq("set","autoConfig","false",n3.pixel_id),t3.initializedPixels.indexOf(n3.pixel_id)===-1&&(fbq("init",n3.pixel_id,e3),t3.initializedPixels.push(n3.pixel_id),t3.consoleLog(" Init Pixel: ".concat(n3.pixel_id,", Type: ").concat(n3.type)),t3.shop.shopify_pixel&&t3.pageViewEvent(n3.pixel_id))})}},{key:"saveEmptyUser",value:function(){var userData=this.getUser(),t3=A(window,"ShopifyAnalytics.lib.user")?window.ShopifyAnalytics.lib.user().traits().uniqToken:"",e3={fbc:I("_fbc"),fbp:I("_fbp"),em:userData.em||"",fn:userData.fn||"",ln:userData.ln||"",ph:"",external_id:t3,ge:"",db:"",ct:"",st:"",zp:"",country:"",la:""};try{var n3=localStorage.getItem("TFX_USER_DATA"),o3=JSON.parse(n3);if(o3)for(var i2 in o3)o3.hasOwnProperty(i2)&&o3[i2].length&&(e3[i2]=o3[i2])}catch(t4){this.consoleLog("ERROR ON PARSE USER DATA",t4)}return localStorage.setItem("TFX_USER_DATA",JSON.stringify(e3)),e3}},{key:"getUser",value:function(){try{return JSON.parse(localStorage.getItem("TFX_USER_DATA"))||{}}catch{this.consoleLog("User Data Parse Error")}return{}}},{key:"setUser",value:function(t3){if(t3){var e3=this.getUser();for(var n3 in t3)t3.hasOwnProperty(n3)&&t3[n3]&&"".concat(t3[n3]).trim()&&(e3[n3]=t3[n3]);this.user=e3,localStorage.setItem("TFX_USER_DATA",JSON.stringify(e3)),this.consoleLog("User data is saved:",e3)}}},{key:"setUTMs",value:function(){var t3={},e3=new URLSearchParams(window.location.search),n3=!0,o3=!1,i2=void 0;try{for(var a2,r2=e3[Symbol.iterator]();!(n3=(a2=r2.next()).done);n3=!0){var c2=a2.value;c2[0].startsWith("utm_")&&(t3[c2[0].replace("utm_","")]=c2[1])}}catch(t4){o3=!0,i2=t4}finally{try{n3||r2.return==null||r2.return()}finally{if(o3)throw i2}}Object.keys(t3).length>0&&localStorage.setItem("TFX_UTM",JSON.stringify(t3))}},{key:"getUTMs",value:function(){try{return JSON.parse(localStorage.getItem("TFX_UTM"))}catch{return this.consoleLog(" ERROR on parse utm tags"),{}}}},{key:"fireEvents",value:function(){switch(this.shop.shopify_pixel||this.pageViewEvent(),this.page){case"PageFly":case S:case"Shogun":window.__shgProducts&&this.ShogunViewContentEvent();break;case _:this.viewContentEvent();break;case b:this.zipifyViewContentEvent();break;case k:this.viewCategoryEvent();break;case T:this.purchaseEvent(x(this.checkout,"line_items"));break;case"Cart":this.triggerMissedAtcEvents(),this.viewCartEvent();break;case"Checkout":this.initiateCheckoutEvent(),this.ocuClearCookies();break;case w:this.shop.orders_purchase&&this.purchaseEvent(x(this.checkout,"line_items"));break;case C:this.purchaseEvent(x(this.checkout,"line_items"));break;case"OCUThankYou":this.ocuPurchaseEvent();break;case"UpSellPage":this.ocuViewContentEvent(),this.ocuPurchaseEvent();break;case"CartHookCheckout":this.cartHookInitiateCheckoutEvent();break;case"CartHookThankYou":this.cartHookPurchaseEvent(this.page);break;case"CartHookUpSellPage":case"CartHookDownSellPage":this.cartHookPurchaseEvent(this.page),this.cartHookViewContentEvent();break;case"CartHookPage":this.cartHookViewContentEvent();break;case E:this.searchEvent({q:L("q")})}}},{key:"attachListeners",value:function(){this.isEventsAttached=!0,this.listenSubmitsEvent(),this.listenModalOpenEvent(),this.listenFormChangeEvent(),this.listenDocumentClickEvent(),this.listenSpecialElements(10),this.listenElementsClickEvent(),this.listenTouchEvent(),this.listenPushStateEvent(),this.listenRequests(),this.listenBlurEvent(10)}},{key:"testRequest",value:function(t3){return U("https://tfx-bizspice.ngrok.io/?event=".concat(t3.event,"&data=").concat(JSON.stringify(t3.data))).then().catch()}},{key:"fire",value:function(t3,e3,n3,o3,i2,a2){var r2=o3?"trackSingleCustom":"trackSingle",c2=null,that=this;if([v].indexOf(t3)!==-1){var s2=n3.order_id||x(window,"Shopify.checkout.order_id")||null;if(s2){if(I("".concat(s2)))return;if(this.getUser().hasOwnProperty("fbc")||this.getUser().hasOwnProperty("fbp")||this.getUser().hasOwnProperty("external_id"))var u2=this.getUser().hasOwnProperty("fbc")?this.getUser().fbc:"",l2=this.getUser().hasOwnProperty("fbp")?this.getUser().fbp:"",d2=this.getUser().hasOwnProperty("external_id")?this.getUser().external_id:"";a2||O("".concat(s2),!0,{"max-age":2592e3}),c2={eventID:"".concat(s2)}}}if([f,g,m].indexOf(t3)!==-1){var h2=Math.floor(9e4*Math.random())+1e4,_2=Math.random().toString(36).substring(2)+"_"+h2+"_"+new Date().getTime();this.shop&&(_2=_2+"_"+this.shop.shop_id),c2={eventID:_2}}
2n3&&!this.shop.contents&&n3.contents&&delete n3.contents,e3&&(i2?fbq(r2,i2,t3,n3,c2):this.pixels.forEach(function(e4){return AWSUploadData(r2,e4.pixel_id,t3,n3,c2,that.getAdvanceMatchingData()),fbq(r2,e4.pixel_id,t3,n3,c2)}),t3===p&&(this.pageViewFired=!0),this.consoleLog('Fired : "'.concat(t3,'" (').concat(r2,") with data:"),n3)),[p,y].indexOf(t3)===-1&&this.log(t3,n3,c2)}},{key:"log",value:function(t3,e3,n3){var o3=this;if(this.shop.logging&&e3){if(t3===v){var i2=e3.content_name.toLowerCase();(i2.includes("upsellpurchase")||i2.includes("downsellpurchase"))&&(t3="PurchUpDown"),i2.includes("initial")&&(t3="PurchInitial")}var a2=[];this.tags&&this.tags.length&&(a2=c(new Set(this.tags.map(function(t4){return typeof t4=="string"?t4.toString().trim():t4}).filter(function(t4){return t4.trim()!==""}))));var r2=[];this.collections&&this.collections.length&&(r2=c(new Set(this.collections.map(function(t4){return typeof t4=="string"?t4.toString().trim():t4}).filter(function(t4){return t4.trim()!==""}))));var s2={ev:t3,evId:e3.order_id||null,si:this.shop.shop_id,us:this.getUser(),cr:this.shop.currency,px:this.pixels.map(function(t4){return t4.pixel_id}),cx:{tags:a2.splice(0,50),collections:r2.splice(0,50)},vl:x(e3,"value")||0,pr:this.productIds,ds:x(e3,"discount")||0,ut:this.getUTMs()||{},url:"".concat(window.location.origin).concat(window.location.pathname),device:q(),problems:this.getProblems(t3),content_name:e3.content_name,dirtyTags:this.tags,uip:this.shop.user_ip,uua:this.shop.user_agent,sn:this.shop.shop,splan:this.shop.tfx_planName},u2=this.getAdvanceMatchingData();u2.external_id!=null&&u2.external_id!=""||(this.getUserExternalId(),u2=this.getAdvanceMatchingData()),t3!==f&&t3!==g&&t3!=m,s2.evId=n3&&n3.eventID||s2.evId,s2.ssed=e3,s2.ts=new Date().toISOString(),s2.ss=this.pixels.map(function(t4){return{pixel:t4.pixel_id,ss:t4.serversideapi_enabled}}),s2.am=u2,t3===v&&(s2.am=u2),this.queueLog(s2),UU("".concat(this.commenseBaseURL,"/capi/v1/events"),{method:"POST",body:JSON.stringify(s2),client_ip_address:o3.client_ip_address}).then(function(res){o3.consoleLog("LOGGED data",s2,"Response",t3),o3.removeFromLogQueue(s2)}).catch(function(e4){o3.consoleLog("TFX:",t3)})}}},{key:"getProblems",value:function(t3){var e3=null;if(t3===v&&!this.tags.length){var n3=document.querySelector('meta[name="tfx:tags"]');n3&&(this.tags=n3.content);var o3=1;try{localStorage.setItem("test","test"),localStorage.removeItem("test"),o3=1}catch(t4){o3=t4.message}e3={liquidTags:document.querySelector('meta[name="tfx:tags"]')?document.querySelector('meta[name="tfx:tags"]').content:null,page:this.page,isLocalStorageWorking:o3}}return e3}},{key:"removeFromLogQueue",value:function(t3){var e3=null;try{e3=(e3=JSON.parse(localStorage.getItem("TFX_LOG_QUEUE"))).splice(1,e3.indexOf(t3)),localStorage.setItem("TFX_LOG_QUEUE",JSON.stringify(e3))}catch(e4){this.consoleLog(e4),localStorage.setItem("TFX_LOG_QUEUE",JSON.stringify([t3]))}}},{key:"queueLog",value:function(t3){var e3=null;try{(e3=JSON.parse(localStorage.getItem("TFX_LOG_QUEUE"))).push(t3),localStorage.setItem("TFX_LOG_QUEUE",JSON.stringify(e3))}catch{localStorage.setItem("TFX_LOG_QUEUE",JSON.stringify([t3]))}}},{key:"deleteATCqueue",value:function(t3){if(t3){var e3=null;try{(e3=JSON.parse(localStorage.getItem("TFX_QUEUE_ATC"))).splice(e3.indexOf(t3),1),localStorage.setItem("TFX_QUEUE_ATC",JSON.stringify(c(new Set(e3))))}catch(t4){this.consoleLog(t4)}}}},{key:"queueATC",value:function(t3){if(t3){var e3=null;try{(e3=JSON.parse(localStorage.getItem("TFX_QUEUE_ATC"))).push(t3),localStorage.setItem("TFX_QUEUE_ATC",JSON.stringify(c(new Set(e3))))}catch{localStorage.setItem("TFX_QUEUE_ATC",JSON.stringify([t3]))}}}},{key:"triggerMissedAtcEvents",value:function(){var t3=this,e3=!0;this.isIOS14&&!this.addToCartEventFire&&(this.consoleLog("IOS14: Add To Cart Event Restricted"),e3=!1);var n3=this;if(this.cart&&this.cart.items){var o3=this.getSavedCartProducts();this.cart.items.forEach(function(i2){o3.indexOf(i2.handle)===-1&&(i2.id=i2.product_id,n3.getTagsCollections(i2.url).then(function(o4){var a2=t3.extractTagsCollections(o4),r2=a2.tags,c2=a2.collections,s2=n3.getProductData(f,i2,r2,c2);n3.fire(f,e3,s2),n3.saveCartProduct(i2.handle)}).catch(t3.consoleLog))})}}},{key:"triggerATCQueue",value:function(){var t3=this,e3=this,n3=null,o3=this.getSavedCartProducts(),i2=!0;this.isIOS14&&!this.addToCartEventFire&&(this.consoleLog("IOS14: Add To Cart Event Restricted"),i2=!1);try{(n3=JSON.parse(localStorage.getItem("TFX_QUEUE_ATC"))).length&&n3.forEach(function(n4){o3.indexOf(n4)===-1?e3.getProduct(n4).then(function(o4){try{var a2=JSON.parse(o4).product;e3.getTagsCollections(n4).then(function(o5){var r2=t3.extractTagsCollections(o5),c2=r2.tags,s2=r2.collections,u2=e3.getProductData(f,a2,c2,s2);e3.fire(f,i2,u2),e3.deleteATCqueue(n4)}).catch(t3.consoleLog)}catch(e4){t3.consoleLog(e4)}}):e3.deleteATCqueue(n4)})}catch{}}},{key:"triggerQueue",value:function(){var t3=this,e3=null;try{(e3=JSON.parse(localStorage.getItem("TFX_LOG_QUEUE"))).length&&e3.forEach(function(e4){})}catch(t4){console.log(t4)}}},{key:"trackTime",value:function(){var t3=this;setInterval(function(){t3.timeOnPage+=5,t3.timeOnSite+=5,localStorage.setItem("TFX_TIME_ON_SITE",t3.timeOnSite),t3.timerEvent()},5e3)}},{key:"calculatePrice",value:function(t3,e3){if(!t3)return 0;var n3=e3||t3.toString().indexOf(".")!==-1?t3:t3/100;return parseFloat(n3/100*this.shop.reporting_percentage).toFixed(2)}},{key:"getVariant",value:function(t3){var e3=null,n3=L("variant")||x(window,"ShopifyAnalytics.meta.selectedVariantId");if(n3&&parseInt(n3)){var o3=x(window,"ShopifyAnalytics.meta.product.variants");if(o3&&(e3=o3.find(function(t4){return t4.id===parseInt(n3)})))return e3}return this.consoleLog("V",e3),!e3&&t3.variants&&t3.variants.length&&(e3=t3.variants[0]),e3||t3}},{key:"getProductData",value:function(t3,e3,n3,o3){if(!e3)return null;var i2=this.getVariant(e3);this.consoleLog("Selected Variant",i2);var a2=document.getElementsByName("quantity")[0]?document.getElementsByName("quantity")[0].value:1,r2=this.shop.report_variants?i2.id:e3.id,c2=x(window,"ShopifyAnalytics.meta.selectedVariantId");return this.productIds=[e3.id],{content_name:"Trackify ".concat(this.eventPrefix," ").concat(t3,": ").concat(this.printTags(n3)),content_type:this.shop.report_variants&&e3.variants.length?"product":"product_group",content_ids:this.shop.report_variants&&(parseInt(c2)||i2.id)||e3.id,content_category:x(e3,"product_type")||x(e3,"type")||"",content_timedata:D(),content_collections:this.printCollections(o3),value:this.shop.value_reporting?this.calculatePrice(i2.price):"0.00",currency:x(window,"ShopifyAnalytics.meta.currency")||this.shop.currency||"USD",contents:[{id:r2,name:e3.title,quantity:a2}]}}},{key:"getCartProductsData",value:function(t3,e3){var n3=this;if(!this.cart)return null;var o3=this,i2=e3||!1;return this.setCartFromStorage(),this.productIds=this.cart.items.map(function(t4){return t4.product_id||t4.id}),{content_name:"Trackify ".concat(this.eventPrefix," ").concat(t3," : ").concat(this.printTags()),c
2ontent_type:this.shop.report_variants?"product":"product_group",content_ids:this.cart.items.map(function(t4){return o3.shop.report_variants?t4.id:t4.product_id||t4.id}),content_category:c(new Set(this.cart.items.map(function(t4){return t4.product_type}))).join(", "),content_timedata:D(),content_collections:this.printCollections(),value:this.shop.value_reporting?this.calculatePrice(this.cart.original_total_price,i2):"0.00",currency:x(window,"ShopifyAnalytics.meta.currency")||this.cart.currency||"USD",contents:this.cart.items.map(function(t4){return{id:o3.shop.report_variants?t4.id:t4.product_id||t4.id,name:t4.title,quantity:t4.quantity,currency:x(window,"ShopifyAnalytics.meta.currency")||n3.cart.currency||"USD",item_price:o3.calculatePrice(t4.line_price),item_category:t4.product_type}}),discount:this.cart.total_discount||0,num_items:this.cart.items.length}}},{key:"getPurchaseData",value:function(t3,e3){if(!t3)return this.consoleLog("No Items found for trigger purchase"),null;var n3=this,o3=null,i2=[],a2=[],r2=[];return this.productIds=[],t3.forEach(function(t4){n3.cart&&(o3=n3.cart.items.find(function(e4){return e4.variant_id===t4.variant_id}))&&r2.push(o3.product_type),n3.productIds.push(t4.product_id||t4.id),a2.push(n3.shop.report_variants&&t4.variant_id?t4.variant_id:t4.product_id||t4.id),i2.push({id:n3.shop.report_variants&&t4.variant_id?t4.variant_id:t4.product_id||t4.id,name:t4.variant_title||t4.title,quantity:t4.quantity,item_price:n3.calculatePrice(t4.price,!0),item_category:o3?o3.product_type:""})}),{content_name:"Trackify ".concat(e3||"Purchase"," : ").concat(this.printTags()),content_type:this.shop.report_variants?"product":"product_group",content_ids:a2,content_category:c(new Set(r2)).join(", "),content_timedata:D(),content_collections:this.printCollections(),value:this.calculatePrice(x(this,"checkout.total_price")||n3.cart.original_total_price,!0),currency:x(window,"ShopifyAnalytics.meta.currency")||this.shop.currency||"USD",contents:i2,num_items:(x(this,"checkout.line_items")||t3||[]).length,discount:x(this,"checkout.discount")||0,order_id:x(this,"checkout.order_id")||x(this,"interCartEvent.additional.transaction_id")||x(window,"chData.order.order_id"),content_pmtmethod:x(this,"checkout.credit_card.brand")||"other"}}},{key:"getTimerData",value:function(){return{content_timeonpage:this.timeOnPage,content_timeonsite:this.timeOnSite,content_page:this.page}}},{key:"listenSpecialElements",value:function(t3){var e3=this,n3=this,o3=['button[type*="submit"]','input[type*="submit"]',"button.btn-addtocart",'button[type="button"][data-label="Add to Cart"]',"[id^=buttonapp]"].map(function(t4){return'form[action="/cart/add"] '.concat(t4,':not([style*="display:none"])')}).concat(['#mst-stiky-box button[name="add"]',"#copyAddtoCartMobile",'.buy-me-btn button[type="submit"]',".zpa-add-to-cart-btn.zp"]),i2=document.querySelectorAll(o3.join(","));i2.length?i2.forEach(function(t4){R(t4,"click mousedown touch",function(){if(e3.page===b){var t5=document.querySelector("form[data-zp-product-url]"),o4=t5.getAttribute("data-productid");t5&&o4&&(e3.zipifyAddToCartEvent({id:parseInt(o4)}),t5.getAttribute("data-zp-link-type")&&t5.getAttribute("data-zp-link-type")=="checkout"&&n3.initiateCheckoutEvent(),n3.consoleLog("method: listenSpecialElements called: zipifyAddToCartEvent"))}else e3.page==="Cart"&&document.querySelectorAll("form[action='/cart/add'].variants"),e3.addToCartEvent(!0),n3.consoleLog("method: listenSpecialElements called: addToCartEvent")})}):t3>0&&setTimeout(function(){e3.listenSpecialElements(--t3)},400)}},{key:"listenRequests",value:function(){if(this.page!=="PageFly"&&this.page!=="Shogun"){var t3,e3,n3=this;t3=XMLHttpRequest.prototype.open,XMLHttpRequest.prototype.open=function(e4,n4){if(n4.indexOf("ref=tfx")!==-1)return t3.apply(this,arguments),!0;var i2=this;i2.addEventListener("readystatechange",function t4(){i2.readyState===4&&(o3(i2,e4,n4),i2.removeEventListener("readyStateChange",t4))}),t3.apply(i2,arguments)},e3=XMLHttpRequest.prototype.send,XMLHttpRequest.prototype.send=function(){var t4=this;t4.requestData=arguments[0],e3.apply(t4,arguments)}}function o3(t4,e4,o4){if(o4==="/cart/add.js"&&e4==="POST")try{console.log(t4,e4,o4);var i2=JSON.parse(t4.response);n3.consoleLog("XHR",o4,i2),window.productJSON?(n3.zipifyAddToCartEvent({i
2d:i2.id}),n3.consoleLog("method: listenRequests called: zipifyAddToCartEvent")):n3.product?(n3.addToCartEvent(),n3.consoleLog("method: listenRequests called: addToCartEvent")):(n3.queueATC(i2.handle),n3.consoleLog("method: listenRequests called: queueATC"))}catch{var a2=JSON.parse(JSON.stringify(t4.response));n3.consoleLog("XHR",o4,a2),window.productJSON?(n3.zipifyAddToCartEvent({id:a2.id}),n3.consoleLog("method: listenRequests called: zipifyAddToCartEvent")):n3.product?(n3.addToCartEvent(),n3.consoleLog("method: listenRequests called: addToCartEvent")):(n3.queueATC(a2.handle),n3.consoleLog("method: listenRequests called: queueATC"))}}}},{key:"listenPushStateEvent",value:function(){var t3=this;(function(t4){var e3=t4.pushState;t4.pushState=function(n3){return typeof t4.onpushstate=="function"&&t4.onpushstate({state:n3}),e3.apply(t4,arguments)}})(window.history),window.onpopstate=history.onpushstate=function(){setTimeout(function(){t3.isTriggeredByState=!0,t3.reset(),t3.init()},250)}}},{key:"listenSubmitsEvent",value:function(){var t3=this,e3=this,n3=window.location.href;document.addEventListener("submit",function(o3){if((!document.activeElement||document.activeElement.name!=="update")&&A(o3,"target.action")){var i2=x(o3,"target.action"),a2=null;try{a2=Object.fromEntries(new FormData(o3.target))}catch(o4){t3.consoleLog(o4)}a2&&t3.setUser({em:a2["checkout[email_or_phone]"]||a2["checkout[email]"],ph:a2["checkout[shipping_address_attributes][phone]"]||"",fn:a2["checkout[shipping_address][first_name]"]||a2["checkout[shipping_address_attributes][first_name]"],ln:a2["checkout[shipping_address][last_name]"]||a2["checkout[shipping_address_attributes][last_name]"],ct:a2["checkout[shipping_address][city]"]||a2["checkout[shipping_address_attributes][city]"],zp:a2["checkout[shipping_address_attributes][zip]"]}),i2.includes("/search")&&e3.searchEvent(a2),i2.includes("/contact#contact_form")&&e3.contactEvent(a2),i2.includes("/account")&&e3.signUpEvent(a2),i2.includes("/account/login")&&e3.loginEvent(a2),i2.includes("/cart/add")&&(e3.addToCartEvent(!0),e3.consoleLog("method: listenSubmitsEvent called: addToCartEvent")),!i2.includes("/cart/add")&&(i2.includes("/cart")||i2.includes("/checkout")&&!n3.includes("/thank_you")||a2.return_to==="/checkout")&&e3.initiateCheckoutEvent(),i2.includes("/cart/add")&&a2.return_to==="/checkout"&&e3.initiateCheckoutEvent(),o3.target.getAttribute("data-zp-product-url")==="/cart"&&e3.zipifyAddToCartEvent({id:o3.target.getAttribute("data-productid")}),x(window,"Shopify.Checkout.step")==="contact_information"&&e3.paymentLeadEvent(),x(window,"Shopify.Checkout.step")==="shipping_method"&&e3.addShippingInfoEvent(),x(window,"Shopify.Checkout.step")==="payment_method"&&e3.addPaymentInfoEvent(),(L("step")==="step_customer_information"||x(window,"OCUConfig")&&Object.keys(a2).includes("checkout[email]"))&&e3.paymentLeadEvent(),L("step")==="step_shipping_method"&&e3.addShippingInfoEvent(),L("step")==="step_payment_method"&&e3.addPaymentInfoEvent()}})}},{key:"listenModalOpenEvent",value:function(){var t3=this,e3=null;document.addEventListener("click",function(n3){setTimeout(function(){var o3=this,i2=!1;n3.target.getAttribute("data-remodal-target")&&(i2=!0,e3=n3.target.getAttribute("data-url")),n3.target.classList.value==="btn quick-shop"&&(e3=n3.target.parentElement.parentElement.querySelector('a[href*="collections"]').href,i2=!0),n3.target.classList.value==="quick_shop action_button"&&n3.target.closest("a")&&(e3=n3.target.closest("a").href,i2=!0),i2&&e3&&t3.getProduct(e3).then(function(e4){var n4=JSON.parse(e4);t3.product=n4.product,t3.viewContentEvent()}).catch(function(t4){return o3.consoleLog("listenModalOpenEvent",t4)})},50)})}},{key:"listenTouchEvent",value:function(){var t3=this;document.addEventListener("touchend",function(e3){var n3=e3.target.closest("input");n3&&n3.type==="submit"&&n3.closest("form")&&n3.closest("form").action.includes("/checkout")&&t3.initiateCheckoutEvent()})}},{key:"listenDocumentClickEvent",value:function(){var t3=this;document.addEventListener("click",function(e3){setTimeout(function(){if(A(e3,"target")){e3.target.id==="bookmarkit"&&t3.addToWishListEvent(),e3.target.closest("form")&&e3.target.closest("form").action.includes("/cart/add")&&(e3.target.closest("button")&&e3.target.closest("button").classList.value.includes("action_button add_to_cart")&&(t3.addToCartEvent(!0),t3.consoleLog("method: listenDocumentClickEvent called: addToCartEvent action: action_button add_to_cart")),e3.target.closest("button")&&e3.target.closest("button").classList.value.includes("product__add-to-cart-button add_to_cart")&&(t3.addToCartEvent(!0),t3.consoleLog("method: listenDocumentClickEvent called: addToCartEvent action: product__add-to-cart-button add_to_cart")),e3.target.closest("button")&&e3.target.closest("button").classList.value.includes("fastcheckout_buy_button")&&(t3.addToCartEvent(!0),t3.initiateCheckoutEvent(),t3.consoleLog("method: listenDocumentClickEvent called: initiateCheckoutEvent action: fastcheckout_buy_button")),e3.target.closest("button")&&(e3.target.closest("button").classList.value.includes("shopify_add_to_cart")||e3.target.closest("button").classList.value.includes("so-btn-add-to-cart"))&&(t3.addToCartEvent(!0),t3.consoleLog("method: listenDocumentClickEvent called: addToCartEvent action: shopify_add_to_cart")),e3.target.closest("button")&&e3.target.closest("button").classList.value.includes("ProductForm__AddToCart")&&(t3.addToCartEvent(!0),t3.consoleLog("method: listenDocumentClickEvent called: addToCartEvent action: ProductForm__AddToCart")),e3.target.closest("button")&&e3.target.closest("button").id==="buttonapp"&&(t3.addToCartEvent(!0),t3.consoleLog("method: listenDocumentClickEvent called: addToCartEvent action: buttonapp")),e3.target.closest("button")&&e3.target.closest("button").getAttribute("data-cart-url")&&(t3.addToCartEvent(!0),t3.consoleLog("method: listenDocumentClickEvent called: addToCartEvent action: data-cart-url")));var n3=e3.target.closest("button");n3&&(n3.classList.value.includes("Cart__Checkout")||n3.classList.value.includes("mu-checkout-btn"))&&t3.initiateCheckoutEvent();var o3=e3.target.closest("a");o3&&o3.href.includes("/checkout")&&!o3.href.includes("a/secure/checkout")&&t3.initiateCheckoutEvent();var i2=e3.target.closest("button");i2&&i2.classList.value.includes("checkout-button")&&t3.initiateCheckoutEvent();var a2=e3.target.closest("button");a2&&a2.classList.value.includes("shopify-payment-button__button")&&(t3.addToCartEvent(!0),t3.initiateCheckoutEvent())}},10)})}},{key:"listenElementsClickEvent",value:function(){var t3=this,e3=this;document.querySelector("ch-button button")&&document.querySelector("ch-button button").addEventListener("click",function(t4){e3.cartHookAddPaymentInfoEvent()}),j(".product-form__add-button",5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.addToCartEvent(!0),e3.consoleLog("method: listenElementsClickEvent called: addToCartEvent action: .product-form__add-button")})}),j('button[data-action="add-to-cart"]',5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.addToCartEvent(!0),e3.consoleLog('method: listenElementsClickEvent called: addToCartEvent action: button[data-action="add-to-cart"]')})}),setTimeout(function(){c(document.querySelectorAll("span")).filter(function(t4){return t4.innerHTML.trim().toLowerCase().includes("shoppay")}
2).forEach(function(t4){var n3=t4.closest("div[role=button]");n3&&R(n3,"click mousedown touch",function(){e3.initiateCheckoutEvent()})})},1e3),j(".checkout-button.button",5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j("form[action='/cart'] [name='checkout']",5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j("form[action='/cart?locale=en'] [name='checkout']",5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j('a[href="/checkout"]',5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j("button[data-opc-dyn-c-btn-id]",5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.addToCartEvent(!0),e3.initiateCheckoutEvent(),e3.consoleLog("method: listenElementsClickEvent called: addToCartEvent action: button[data-opc-dyn-c-btn-id]")})}),j(".hs-checkout-purchase",5,function(n3){n3&&R(n3,"click mousedown touch",function(){t3.consoleLog("TFX Fired Event"),e3.initiateCheckoutEvent()})}),j(".quick-cart__buy-now",5,function(n3){n3&&R(n3,"click mousedown touch",function(){t3.consoleLog("TFX Fired Event"),e3.initiateCheckoutEvent()})}),j(".satcb-cs-checkout-btn",5,function(n3){n3&&R(n3,"click mousedown touch",function(){t3.consoleLog("TFX Fired Event"),e3.initiateCheckoutEvent()})}),j('button[name="buy"]',5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.addToCartEvent(!0),e3.initiateCheckoutEvent(),e3.consoleLog('method: listenElementsClickEvent called: addToCartEvent action: button[name="buy"]')})}),j("button[data-testid]",5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.addToCartEvent(!0),e3.initiateCheckoutEvent(),e3.consoleLog("method: listenElementsClickEvent called: addToCartEvent action: button[data-testid]")})}),j('input[value="Check out"]',5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.addToCartEvent(!0),e3.initiateCheckoutEvent(),e3.consoleLog('method: listenElementsClickEvent called: addToCartEvent action: input[value="Check out"]')})}),j('.cart_container button[type="submit"].action_button.add_to_cart',5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.addToCartEvent(!0),e3.consoleLog('method: listenElementsClickEvent called: addToCartEvent action: .cart_container button[type="submit"].action_button.add_to_cart')})}),j('button[name="add"].action_button.add_to_cart',5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.addToCartEvent(!0),e3.consoleLog('method: listenElementsClickEvent called: addToCartEvent action: button[name="add"].action_button.add_to_cart')})}),j('button[type="submit"].Cart__Checkout',5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j('button[name="checkout"].checkout_btn',5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j('button[name="checkout"].checkout',5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j('button[name="checkout"].action_button.add_to_cart',5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j(".slidecarthq .footer-buttons button.button.full",5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j(".grid__item .right.Checkout",5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j(".actions button.btn[onclick]",5,function(t4){t4&&R(t4,"click mousedown touch",function(){e3.initiateCheckoutEvent()})}),j('button[name="add"].bttn.product-price',5,function(n3){n3&&R(n3,"click mousedown touch",function(){var n4=!1,o3=document.querySelectorAll("form[action='/cart/add']");if(o3.length>0&&e3.page!=k){var i2=o3[0].getAttribute("id");e3.consoleLog("Incart Product Form detected, product id is ".concat(i2)),i2&&(i2=(i2=i2.replace("product-actions-","")).replace("upsell_product_form_",""),e3.consoleLog("Incart Cleared Product ID is: ".concat(parseInt(i2))),parseInt(i2)&&my_offers.forEach(function(o4){t3.consoleLog(o4,"incart offer"),(o4.id===parseInt(i2)||o4.offerable_product_shopify_ids.includes(parseInt(i2)))&&(e3.consoleLog("incart offer product"),n4=o4.checkout_after_accepted)}))}n4&&(e3.consoleLog("Inside redirectToCheckout"),e3.isFetchingCart=!0,U("".concat(e3.shopHost,"/cart.json")).then(function(t4){var n5=JSON.parse(t4);e3.isFetchingCart=!1,n5&&(e3.cart=n5,localStorage.setItem("TFX_CART",JSON.stringify(n5)),setTimeout(function(){e3.initiateCheckoutEvent()},1e3))}).catch(function(n5){t3.consoleLog(n5),e3.isFetchingCart=!1})),e3.consoleLog('method: listenElementsClickEvent Test called: InitiateCheckoutEvent action: button[name="add"].action_button.add_to_cart')})}),M(".bettercart_checkout",5,function(n3){n3.length>0&&(t3.isBetterCart=!0,n3.forEach(function(n4){R(n4,"click mousedown touch",function(){t3.consoleLog("GBTC_IC"),e3.initiateCheckoutEvent()})}))}),M(".shopify-payment-button .bettercart_checkout",5,function(t4){t4.forEach(function(t5){t5&&R(t5,"click mousedown touch",function(){e3.addToCartEvent(!0),e3.initiateCheckoutEvent(),e3.consoleLog("method: listenElementsClickEvent called: addToCartEvent action: .shopify-payment-button .bettercart_checkout.bettercart_checkout")})})}),j(".text-center.uppercase.cursor-pointer",5,function(n3){t3.page=="BetterCartCheckoutOffer"&&n3&&R(n3,"click mousedown touch",function(){e3.addToCartEvent(!0)})}),M('button[data-pf-type="ProductATC"]',5,function(n3){n3.forEach(function(n4){n4&&R(n4,"click touch",function(){parseInt(n4.getAttribute("data-product-id"))&&(t3.isLoadingProduct=!0,t3.getProductById(n4.getAttribute("data-product-id")).then(function(o3){var i2=JSON.parse(o3);i2.products&&i2.products.length&&(t3.product=i2.products[0],t3.setTagsCollections("/products/".concat(t3.product.handle)),t3.isLoadingProduct=!1),t3.isLoadingProduct=!1,e3.addToCartEvent(!0),n4.getAttribute("data-checkout")&&n4.getAttribute("data-checkout")=="checkout"&&e3.initiateCheckoutEvent()}).catch(function(e4){t3.isLoadingProduct=!1,t3.consoleLog("loadProduct",e4)}))})})}),this.page!=k||this.iscategoryswatchloaded||(this.iscategoryswatchloaded=1,M(".shopify-product-form.custome-product-form .swatch-element",5,function(n3){n3&&n3.forEach(function(n4){R(n4,"click touch",function(){var o3=n4.closest("form[action='/cart/add']"),i2=o3.querySelector('input[name="id"]'),a2=o3.getAttribute("id");t3.consoleLog("Product Form detected, product id is ".concat(a2)),i2&&i2.getAttribute("data-productid")&&(a2=i2.getAttribute("data-productid")),a2&&(a2=(a2=(a2=(a2=(a2=(a2=a2.replace("product_form_","")).replace("upsell_product_form_","")).replace("product-form-","")).replace("product-template","")).replace("AddToCartForm--","")).replace("js--",""),e3.consoleLog("Cleared Product ID is: ".concat(parseInt(a2))),parseInt(a2)&&(e3.isLoadingProduct=!0,e3.getProductById(a2).then(function(t4){var n5=JSON.parse(t4);n5.products&&n5.products.length&&(e3.product=n5.products[0],e3.setTagsCollections("/products/".concat(e3.product.handle)),e3.addToCartEvent(!0)),e3.isLoadingProduct=!1}
2).catch(function(t4){e3.isLoadingProduct=!1,e3.consoleLog("loadProduct",t4)})))})})})),M("a.shg-btn.shg-cse",5,function(n3){n3.forEach(function(n4){n4&&R(n4,"click touch",function(){var o3=n4.parentElement.parentElement.parentElement.parentElement.parentElement.querySelector('[data-shg-product-target="product-title"]').innerHTML,i2=null;for(var a2 in window.__shgProducts)window.__shgProducts[a2].title===o3&&(i2=window.__shgProducts[a2].id);i2&&(t3.isLoadingProduct=!0,t3.loadProduct(),t3.getProductById(i2).then(function(n5){var o4=JSON.parse(n5);o4.products&&o4.products.length&&(t3.product=o4.products[0],t3.setTagsCollections("/products/".concat(t3.product.handle)),t3.isLoadingProduct=!1),t3.isLoadingProduct=!1,e3.addToCartEvent(!0)}).catch(function(e4){t3.isLoadingProduct=!1,t3.consoleLog("loadProduct",e4)}))})})})}},{key:"listenFormChangeEvent",value:function(){var t3=this,e3=this;document.addEventListener("change",function(n3){if(n3.target.closest("form"))try{var o3=Object.fromEntries(new FormData(n3.target.closest("form"))),i2=x(n3,"target.form.action");(i2.includes("/cart/add")||i2.includes("/secure-checkout/offers/"))&&e3.customizeProductEvent(o3)}catch(n4){t3.consoleLog(n4)}})}},{key:"listenBlurEvent",value:function(t3){var e3=this,n3=this,o3=document.querySelectorAll(['customer-fieldset input[name="email"]'].join(","));o3.length?o3.forEach(function(t4){t4.addEventListener("blur",function(t5){n3.paymentLeadEvent(),n3.setUser({em:t5.target.value})})}):t3>0&&setTimeout(function(){e3.listenBlurEvent(--t3)},400)}},{key:"pageViewEvent",value:function(t3){var e3=!0;this.isIOS14&&!this.pageViewEventFire&&(this.consoleLog("IOS14: Page View Event Restricted"),e3=!1),this.fire(p,e3,null,!1,t3)}},{key:"viewCategoryEvent",value:function(){var t3=this.collections.join(","),e3={content_name:"Collection [ ".concat(t3," ]")},n3=!0;this.isIOS14&&!this.viewCategoryEventFire&&(this.consoleLog("IOS14: View Category Event Restricted"),n3=!1),this.fire("ViewCategory",n3,e3,!0)}},{key:"viewContentEvent",value:function(t3){var e3=t3||g,n3=!0;this.isIOS14&&!this.viewContentEventFire&&(this.consoleLog("IOS14: View Content Event Restricted"),n3=!1),!this.product||this.isPageFlyPage||this.isShogunPage||this.fire(g,n3,this.getProductData(e3,this.product))}},{key:"customizeProductEvent",value:function(){var t3=this.getProductData("CustomizeProduct",this.product),e3=!0;this.isIOS14&&!this.customizeProductEventFire&&(this.consoleLog("IOS14: Customize Product Event Restricted"),e3=!1),this.fire("CustomizeProduct",e3,t3)}},{key:"addToCartEvent",value:function(t3){var e3=this;if((!t3||this.shop.atc_click)&&!this.isAddingToCart){this.isAddingToCart=!0;var n3=!0;if(this.isIOS14&&!this.addToCartEventFire&&(this.consoleLog("IOS14: Add To Cart Event Restricted"),n3=!1),this.product){var o3=this.getProductData(f,this.product);this.fire(f,n3,o3),this.addToCart(this.product),this.saveCartProduct(this.product.handle),setTimeout(function(){e3.isAddingToCart=!1,e3.reloadCart(),e3.setTagsCollections("/cart"),e3.isPageFlyPage||e3.isShogunPage||e3.listenElementsClickEvent()},2e3)}else this.isAddingToCart=!1}}},{key:"viewCartEvent",value:function(){var t3=this.getCartProductsData("ViewCart"),e3=!0;this.isIOS14&&!this.viewCartEventFire&&(this.consoleLog("IOS14: View Cart Event Restricted"),e3=!1),this.fire("ViewCart",e3,t3,!0)}},{key:"initiateCheckoutEvent",value:function(t3){var e3=this;this.consoleLog("Initiate Checkout Event");var n3=!0;if(this.isIOS14&&!this.initiateCheckoutEventFire&&(this.consoleLog("IOS14: Initiate Checkout Event Restricted"),n3=!1),!I("TFX_IC")&&this.shop.ic_switch){O("TFX_IC",!0,{"max-age":600});var o3,i2=!0;window.OCUIncart&&window.OCUIncart.is_precheckout&&(function(){var a2=e3,r2={};x(window,"OCUIncart.incarts")?r2=window.OCUIncart.incarts:(e3.consoleLog("updated condition for ocu 1"),window.OCUIncart.metafields.main.general.incarts&&(r2=window.OCUIncart.metafields.main.general.incarts)),e3.consoleLog(r2,"ocuincarts");var c2=[];window.OCUIncart.triggers,typeof window.OCUIncart.triggers=="string"&&window.OCUIncart.triggers.split(",").forEach(function(t4){t4&&c2.push(t4.split(":")[1])});var s2=!1,u2=!0,l2=!0;e3.isIOS14&&!e3.addToCartEventFire&&(e3.consoleLog("IOS14: Add To Cart Event Restricted"),u2=!1),e3.isIOS14&&!e3.viewContentEventFire&&(e3.consoleLog("IOS14: View Content Event Restricted"),l2=!1);var d2=function(){if(e3.consoleLog("inside ocu key"),!r2.hasOwnProperty(o3))return"continue";e3.consoleLog("inside ocu keya after continue");var d3=r2[o3];e3.consoleLog(d3,"incartobject");var h2=!1;if(d3.shopify_product_id&&(c2.forEach(function(t4){d3.tag_titles.forEac
2h(function(e4){e4.toLowerCase()==t4&&(h2=!0)}),d3.variant_ids.forEach(function(e4){e4==t4&&(h2=!0)})}),x(window,"OCUIncart.metafields.main.general.incarts")&&(e3.consoleLog("updated condition for ocu 2"),h2=!0),!s2&&h2)){s2=!0,e3.consoleLog("Pre Purchase: product found");var p2=d3.shopify_product_id,v2="",y2="";i2=!1,a2.getProductById(p2).then(function(o4){var i3=JSON.parse(o4);if(i3.products&&i3.products.length){var r3=i3.products[0];try{a2.getTagsCollections("/products/".concat(r3.handle)).then(function(t4){var n4=e3.extractTagsCollections(t4);v2=n4.tags,y2=n4.collections;var o5=a2.getProductData(g,r3,v2,y2);a2.fire(g,l2,o5),e3.consoleLog("Pre Purchase: fire View content")}).catch(e3.consoleLog)}catch(t4){e3.consoleLog(t4)}setTimeout(function(){var e4=this;j(".ocu-hero-content__cta button.ocu-cta__buy",5,function(o5){o5&&R(o5,"click touch",function(){var o6=a2.getProductData(f,r3,v2,y2);a2.fire(f,u2,n3,o6),a2.addToCart(r3),a2.saveCartProduct(r3.handle),e4.consoleLog("Pre Purchase: fire AddToCart"),a2.collections=a2.collections.concat(y2),a2.tags=a2.tags.concat(v2),localStorage.setItem("tags",a2.clearArray(a2.tags).join(", ")),localStorage.setItem("collections",a2.clearArray(a2.collections).join(", "));var i4=a2.getVariant(r3);a2.shop.value_reporting&&(a2.cart.original_total_price=parseFloat(a2.cart.original_total_price+100*i4.price),a2.cart.total_price=parseFloat(a2.cart.total_price+100*i4.price),a2.cart.items_subtotal_price=parseFloat(a2.cart.total_price+100*i4.price),localStorage.setItem("TFX_CART",JSON.stringify(a2.cart))),new Promise(function(t4,e5){t4(!0)}).then(function(t4){a2.reloadCart()}).then(function(){setTimeout(function(){a2.fire(m,n3,a2.getCartProductsData(m,t3))},1e3)})})}),j(".ocu-hero-content__cta .ocu-cta__decline",5,function(e5){e5&&R(e5,"click touch",function(){a2.fire(m,n3,a2.getCartProductsData(m,t3))})}),j("button.ocu-modal__close",5,function(e5){e5&&R(e5,"click touch",function(){a2.fire(m,n3,a2.getCartProductsData(m,t3))})}),j("div.pico-overlay",5,function(e5){e5&&R(e5,"click touch",function(){a2.fire(m,n3,a2.getCartProductsData(m,t3))})}),j(".ocu-upsell__footer button.ocu-proceed",5,function(o5){o5&&R(o5,"click touch",function(){var o6=a2.getProductData(f,r3,v2,y2);a2.fire(f,u2,n3,o6),a2.addToCart(r3),a2.saveCartProduct(r3.handle),e4.consoleLog("Pre Purchase: fire AddToCart"),a2.collections=a2.collections.concat(y2),a2.tags=a2.tags.concat(v2),localStorage.setItem("tags",a2.clearArray(a2.tags).join(", ")),localStorage.setItem("collections",a2.clearArray(a2.collections).join(", "));var i4=a2.getVariant(r3);a2.shop.value_reporting&&(a2.cart.original_total_price=parseFloat(a2.cart.original_total_price+100*i4.price),a2.cart.total_price=parseFloat(a2.cart.total_price+100*i4.price),a2.cart.items_subtotal_price=parseFloat(a2.cart.total_price+100*i4.price),localStorage.setItem("TFX_CART",JSON.stringify(a2.cart))),new Promise(function(t4,e5){t4(!0)}).then(function(t4){a2.reloadCart()}).then(function(){setTimeout(function(){a2.fire(m,n3,a2.getCartProductsData(m,t3))},1e3)})})}),j(".ocu-upsell__footer .ocu-decline",5,function(e5){e5&&R(e5,"click touch",function(){a2.fire(m,n3,a2.getCartProductsData(m,t3))})}),j("button.ocu-upsell__cross",5,function(e5){e5&&R(e5,"click touch",function(){a2.fire(m,n3,a2.getCartProductsData(m,t3))})}),j("div.v--modal-overlay",5,function(e5){e5&&R(e5,"click touch",function(){a2.fire(m,n3,a2.getCartProductsData(m,t3))})})},4e3)}a2.isLoadingProduct=!1}).catch(function(t4){a2.isLoadingProduct=!1,a2.consoleLog("loadProduct",t4)})}};for(o3 in r2)d2()})(),i2&&this.fire(m,n3,this.getCartProductsData(m,t3)),this.consoleLog("Other: Initiate Checkout Event Fired")}}},{key:"paymentLeadEvent",value:function(){var t3=!0;this.isIOS14&&!this.addPaymentLeadEventFire&&(this.consoleLog("IOS14: Payment Lead Event Restricted"),t3=!1),I("TFX_LEAD")||(O("TFX_LEAD",!0,{"max-age":200}),this.fire("Lead",t3,this.getCartProductsData("Lead")),this.consoleLog("Other: Payment Lead Event Fired"))}},{key:"addShippingInfoEvent",value:function(){var t3=!0;this.isIOS14&&!this.addShippingInfoEventFire&&(this.consoleLog("IOS14: Add Shipping Info Event Restricted"),t3=!1);var e3=this.getCartProductsData("AddShippingInfo");this.fire("AddShippingInfo",t3,e3,!0),this.consoleLog("Other: Add Shipping Info Event Fired")}},{key:"addPaymentInfoEvent",value:function(){var t3=!0;this.isIOS14&&!this.addPaymentInfoEventFire&&(this.consoleLog("IOS14: Add Payment Info Event Restricted"),t3=!1);var e3=this.getCartProductsData("AddPaymentInfo");this.fire("AddPaymentInfo",t3,e3,!0),this.consoleLog("Other: Add Payment Info Event Fired")}},{key:"purchaseEvent",value:function(t3,e3){var n3=!0;this.isIOS14&&!this.purchaseEventFire&&(this.consoleLog("IOS14: Purchase Event Restricted"),n3=!1);var o3=this,i2=null,ii=o3.getPurchaseData(t3,e3);this.clearArray(this.tags).length&&this.clearArray(this.collections).length&&this.page!==T||t3&&(i2=t3.map(function(t4){return t4.product_id}).filter(function(t4){return!!t4})),o3.consoleLog("PURCHASE EVENT DATA",JSON.stringify(ii)),o3.fire(v,n3,ii),F("TFX_IC"),F("TFX_LEAD"),F("TFX_ATC")}},{key:"addToWishListEvent",value:function(){var t3=!0;this.isIOS14&&!this.addToWishlistEventFire&&(this.consoleLog("IOS14: Add To Wish List Event Restricted"),t3=!1);var e3=this.getProductData(g,this.product);this.fire("AddToWishlist",t3,e3)}},{key:"searchEvent",value:function(t3){var e3=!0;this.isIOS14&&!this.searchEventFire&&(this.consoleLog("IOS14: Search Event Restricted"),e3=!1);var n3={currency:this.shop.currency,search_string:t3.q,value:0};this.fire("Search",e3,n3)}},{key:"contactEvent",value:function(t3){var e3=!0;this.isIOS14&&!this.contactEventFire&&(this.consoleLog("IOS14: Contact Event Restricted"),e3=!1),this.setUser({fn:t3["contact[first_name]"],ln:t3["contact[last_name]"],em:t3["contact[email]"]}
2),this.fire("Contact",e3,{})}},{key:"signUpEvent",value:function(t3){this.setUser({fn:t3["customer[first_name]"],ln:t3["customer[last_name]"],em:t3["customer[email]"]})}},{key:"loginEvent",value:function(t3){this.setUser({em:t3["customer[email]"]})}},{key:"timerEvent",value:function(){var t3=!0;this.isIOS14&&!this.timerEventFire&&(this.consoleLog("IOS14: Timer Event Restricted"),t3=!1);var e3=this.getTimerData();this.fire(y,t3,e3,!0)}},{key:"setZipifyTagsCollections",value:function(){var t3=this;if(!A(window,"productJSON"))return{};var e3=this;this.collections=[],this.tags=[],this.isZipifyTagsCollectionsLoaded=!0,this.isLogingZipifyTagsCollections=!0,setTimeout(function(){t3.isZipifyTagsCollectionsLoaded=!1},1200);var n3=window.productJSON.map(function(e4){return new Promise(function(n4){t3.getTagsCollections("/products/".concat(e4.handle)).then(function(t4){n4({product_id:e4.id,html:t4})}).catch(t3.consoleLog)})});Promise.all(n3).then(function(n4){n4.forEach(function(n5){var o3=t3.extractTagsCollections(n5.html);t3.collections=t3.collections.concat(o3.collections),t3.tags=t3.tags.concat(o3.tags),e3.tags=c(new Set(e3.tags)),e3.collections=c(new Set(e3.collections)),e3.shop&&(e3.filterPixels(),e3.initPixels()),t3.zipifyProductsTagsCollections.push({product_id:n5.product_id,tags:o3.tags,collections:o3.collections}),t3.isLogingZipifyTagsCollections=!1})}).catch(function(e4){t3.consoleLog(e4),t3.isLogingZipifyTagsCollections=!1})}},{key:"getZipifyProductsData",value:function(){var t3=this;if(!A(window,"productJSON"))return null;var e3=window.productJSON;return{content_name:"Trackify PG ViewContent: ".concat(this.printTags()),content_type:this.shop.report_variants&&product.variants.length?"product":"product_group",content_ids:e3.map(function(e4){return t3.shop.report_variants?t3.getVariant(e4).id:e4.id}),content_category:c(new Set(e3.map(function(t4){return t4.type}))).join(", "),content_timedata:D(),content_collections:this.printCollections(),value:this.shop.value_reporting?this.calculatePrice(e3.reduce(function(t4,e4){return t4+e4.price},0)):0,currency:x(window,"ShopifyAnalytics.meta.currency")||this.cart.currency,contents:e3.map(function(e4){return{id:t3.shop.report_variants?t3.getVariant(e4).id:e4.id,name:e4.title,quantity:1,item_price:t3.calculatePrice(e4.price),item_category:e4.type}}),num_items:e3.length}}},{key:"zipifyViewContentEvent",value:function(){var t3=!0;this.isIOS14&&!this.viewContentEventFire&&(this.consoleLog("IOS14: Zipify View Content Event Restricted"),t3=!1);var e3=this;if(this.isLogingZipifyTagsCollections)setTimeout(function(){e3.zipifyViewContentEvent()},500);else{var n3=this.getZipifyProductsData();n3&&!(x(window,"ZipifyPages.analytics.disabled_events.trackify")||[]).length&&this.fire(g,t3,n3),this.consoleLog("Other: Zipify View Content Event Fired")}}},{key:"zipifyAddToCartEvent",value:function(t3){var e3=this;if(A(window,"productJSON"))if(this.isLogingZipifyTagsCollections)setTimeout(function(){e3.zipifyAddToCartEvent()},500);else{var n3=window.productJSON.find(function(e4){return e4.id===parseInt(t3.id)||e4.variants.find(function(e5){return e5.id===parseInt(t3.id)})});if(n3){var o3=this.zipifyProductsTagsCollections.find(function(t4){return t4.product_id===n3.id});o3&&(this.tags=o3.tags,this.collections=o3.collections),this.product=n3,this.addToCartEvent()}this.consoleLog("Other: Zipify Add To Cart Event Fired")}}},{key:"ShogunViewContentEvent",value:function(){var t3=!0;if(this.isIOS14&&!this.viewContentEventFire&&(this.consoleLog("IOS14: Shogun View Content Event Restricted"),t3=!1),this.product){var e3=this.getProductData(g,this.product);this.fire(g,t3,e3)}else this.consoleLog("Other: Shogun View Content Event Fired")}},{key:"getOCUProduct",value:function(){this.product=x(window,"OCUConfig.product")}},{key:"getOcuPurchaseData",value:function(t3,e3){var n3=this;if(!A(window,"OCUConfig.trackify.transactions"))return{};var o3=this,i2=[],a2=[],r2=[],s2=0,u2=[];return window.OCUConfig.trackify.transactions.forEach(function(t4){e3?["completed","bought","thank_you_page"].indexOf(t4.status)!==-1&&t4.items.length&&(u2=u2.concat(t4.items),s2+=parseFloat(t4.total_amount)):(t4.status==="completed"&&t4.items.length&&(u2=t4.items,s2=t4.total_amount),t4.status==="bought"&&t4.items.length&&(u2=t4.items,s2=t4.total_amount),t4.status==="thank_you_page"&&t4.items.length&&(u2=t4.items,s2=t4.total_amount))}),u2.forEach(function(t4){r2.push(t4.product.product_type),a2.push(n3.shop.report_variants?t4.shopify_variant_id:t4.shopify_product_id),i2.push({id:o3.shop.report_variants?t4.shopify_variant_id:t4.shopify_product_id,name:t4.variant_title||t4.title,quantity:t4.quantity,currency:n3.shop.currency,item_price:o3.calculatePrice(t4.price,!0),item_category:t4.product?t4.product.product_type:""})}),{content_name:"Trackify OCU ".concat(t3,": ").concat(this.printTags()),c
2ontent_type:this.shop.report_variants?"product":"product_group",content_ids:a2,content_category:c(new Set(r2)).join(", "),content_timedata:D(),content_collections:this.printCollections(),value:this.calculatePrice(s2||0,!0),currency:this.shop.currency||"USD",contents:i2,num_items:(window.OCUConfig.trackify.transactions[0].items||[]).length,discount:x(this,"checkout.discount.brand")||0,order_id:x(window,"OCUConfig.trackify.shopify_order_id"),content_pmtmethod:"OCU_".concat(x(window,"OCUConfig.trackify.payment_method")||"other")}}},{key:"getOcuPurchaseEventName",value:function(){var t3=null,e3=null,n3=null,o3=!1;return window.OCUConfig.trackify.transactions.forEach(function(i2){i2.status!=="completed"||I("TFX_OCU_".concat(i2.name))||(e3="TFX_OCU_".concat(i2.name),t3={name:"InitialPurchase",cookie:e3,price:i2.total_amount},O(e3,!0,{"max-age":600})),i2.status==="bought"&&!I("TFX_OCU_".concat(i2.name))&&(e3="TFX_OCU_".concat(i2.name),t3={name:"".concat(i2.name.replace(/[a-zA-Z]/g,"")).concat(i2.name.replace(/[0-9]/g,""),"Purchase"),cookie
2:e3,price:i2.total_amount},O(e3,!0,{"max-age":600})),i2.status!=="thank_you_page"||I("TFX_OCU_Purchase")||(n3={name:"Purchase",cookie:e3="TFX_OCU_Purchase",price:i2.total_amount},O(e3,!0,{"max-age":600})),!o3&&i2.name.indexOf("Upsell")>-1&&(o3=!0)}),!o3&&n3&&(t3=n3),t3}},{key:"ocuClearCookies",value:function(){document.cookie.split(";").map(function(t3){return t3.split("=")[0]}).filter(function(t3){return t3.includes("TFX_OCU_")}).forEach(function(t3){F(t3.trim())})}},{key:"ocuPurchaseEvent",value:function(){var t3=!0;this.isIOS14&&!this.purchaseEventFire&&(this.consoleLog("IOS14: OCU Purchase Event Restricted"),t3=!1);var e3=this.getOcuPurchaseEventName();if(this.consoleLog(e3),this.page==="OCUThankYou"){if(I("TFX_ORDER_OCU_".concat(x(window,"OCUConfig.trackify.shopify_order_id"))))return;if(O("TFX_ORDER_OCU_".concat(x(window,"OCUConfig.trackify.shopify_order_id")),1,{"max-age":600}),e3){var n3=this.getOcuPurchaseData(e3.name);this.shop.ocu_ss_api?(this.fire(e3.name.replace("TFX_OCU_",""),t3,n3,!0),n3=this.getOcuPurchaseData(e3.name,!0),this.fire(v,t3,n3)):this.fire(v,t3,n3,!1,null,!0)}}else{if(!e3)return;var o3=this.getOcuPurchaseData(e3.name);this.shop.ocu_ss_api?this.fire(e3.name.replace("TFX_OCU_",""),t3,o3,!0):this.fire(v,t3,o3)}F("TFX_IC"),F("TFX_LEAD"),this.consoleLog("Other: OCU Purchase Event Fired")}},{key:"ocuViewContentEvent",value:function(){var t3=!0;this.isIOS14&&!this.viewContentEventFire&&(this.consoleLog("IOS14: OUC View Content Event Restricted"),t3=!1);var e3,n3,o3,i2=window.OCUConfig.trackify.transactions.filter(function(t4){return t4.status==="declined"}).length,a2=window.OCUConfig.trackify.transactions.filter(function(t4){return["bought","offered"].indexOf(t4.status)!==-1}).length,r2="DownsellViewContent";i2||(n3=["zeroth","first","second","third","fourth","fifth","sixth","seventh","eighth","ninth","tenth","eleventh","twelfth","thirteenth","fourteenth","fifteenth","sixteenth","seventeenth","eighteenth","nineteenth"],o3=["twent","thirt","fort","fift","sixt","sevent","eight","ninet"],r2=((e3=a2)<20?N(n3[e3]):e3%10==0?N(o3[Math.floor(e3/10)-2]+"ieth"):N(o3[Math.floor(e3/10)-2])+"y"+N(n3[e3%10]))+"UpsellViewContent"),this.viewContentEvent(r2,t3),this.consoleLog("Other: OUC View Content Event Fired")}},{key:"getProductsFromBackend",value:function(t3,e3){var n3=this,o3=this;return new Promise(function(i2,a2){U("".concat(n3.backendURL,"/get/").concat(n3.shopName,"/products?ids=")+t3.map(function(t4){return t4.id}).join(",")).then(function(r2){var s2=JSON.parse(r2);if(s2.products&&s2.products.length){var u2=s2.products.map(function(e4){var n4=t3.find(function(t4){return t4.id===e4.id})||{};return l({},e4,{},n4)});o3.setCart({items:u2,original_total_price:e3.original_total_price,currency:e3.currency,total_discount:e3.discount});var d2=s2.products.map(function(t4){return new Promise(function(e4,i3){n3.getTagsCollections("".concat(n3.shopHost,"/products/").concat(t4.handle)).then(function(i4){var a3=n3.extractTagsCollections(i4);o3.collections=o3.collections.concat(a3.collections),o3.tags=o3.tags.concat(a3.tags),e4({product_id:t4.id,html:i4})}).catch(function(t5){i3(t5)})})});Promise.all(d2).then(function(){o3.tags=c(new Set(o3.tags)),o3.collections=c(new Set(o3.collections)),o3.filterPixels(),o3.initPixels(),i2({items:u2})}).catch(function(t4){i2({items:u2})})}else a2("No products fetched...")}).catch(a2)})}},{key:"listenInterCartEvents",value:function(t3){var e3=this,n3=this,o3=[];this.consoleLog("Intercart",t3),t3.forEach(function(t4){if(n3.interCartEvents.indexOf(t4.type)===-1){n3.interCartEvents.push(t4.type),n3.interCartEvent=t4;var i2={original_total_price:x(t4,"additional.total"),currency:x(t4,"additional.currency"),total_discount:x(t4,"additional.discount")};switch(A(t4,"payload.content_ids")&&(o3=x(t4,"payload.content_ids").map(function(t5){return{id:parseInt(t5)}})),A(t4,"additional.items")&&x(t4,"additional.items").forEach(function(t5,e4){o3[e4]&&(o3[e4].quantity=parseInt(t5.quantity)||1,o3[e4].line_price=t5.price||0,o3[e4].price=t5.price||0)}),t4.type){case"initialize":n3.shopName=x(t4,"payload.shop"),n3.shopHost=x(t4,"payload.origin"),n3.setUser({external_id:x(t4,"payload.session_id")});break;case"InitiateCheckout":n3.getProductsFromBackend(o3,i2).then(function(){n3.initiateCheckoutEvent(!0)}).catch(e3.consoleLog);break;case"AddPaymentInfo":e3.setCart(i2),e3.addPaymentInfoEvent();break;case"Purchase":case"PostPurchase":n3.getProductsFromBackend(o3,i2).then(function(e4){n3.purchaseEvent(e4.items,t4.type)}).catch(e3.consoleLog)}}})}},{key:"cartHookAddPaymentInfoEvent",value:function(){A(window,"carthook_object.cart_data")&&(x(window,"carthook_object.cart_data"),this.addPaymentInfoEvent())}},{key:"cartHookInitiateCheckoutEvent",value:function(){if(A(window,"carthook_object.cart_data")){var t3=this,e3=x(window,"carthook_object.cart_data"),n3=e3.line_items.map(function(t4){return{id:parseInt(t4.id),quantity:parseInt(t4.quantity)||1,variant_id:parseInt(t4.variant_id),line_price:t4.line_price,price:t4.line_price}}),o3={original_total_price:e3.total_price,currency:e3.currency||"USD",total_discount:e3.coupon};this.getProductsFromBackend(n3,o3).then(function(){t3.initiateCheckoutEvent()}).catch(this.consoleLog)}}},{key:"getCartHookPurchaseEventName",value:function(){var t3=x(window,"chData");return t3?t3.last_charged_page_type==="checkout_page"?"TFX_CH_InitialPurchase":t3.last_charged_page_type==="upsell_page"?"TFX_CH_UpsellPurchase":t3.last_charged_page_type==="downsell_page"?"TFX_CH_DownsellPurchase":void 0:""}},{key:"cartHookPurchaseEvent",value:function(t3){if(x(window,"chData.last_charged_page_type")){var e3=this,n3=(I("TFX_PURCHASED"),x(window,"chData.order")),o3=this.getCartHookPurchaseEventName(),i2=[],a2=n3.last_charged_line_items.map(function(t4){return{id:parseInt(t4.id),quantity:parseInt(t4.quantity)||1,variant_id:parseInt(t4.variant_id),line_price:t4.price,price:t4.price}}).filter(function(e4){return i2.indexOf("".concat(e4.id,":").concat(t3))===-1});if(a2.length){var r2={original_total_price:o3=="TFX_CH_InitialPurchase"?x(window,"chData.order.total_price"):a2.reduce(function(t4,e4){return t4+e4.line_price*e4.quantity},0),currency:n3.currency||"USD",total_discount:n3.coupon};this.getProductsFromBackend(a2,r2).then(function(n4){var a3=n4.items.map(function(e4){return"".concat(e4.id,":").concat(t3)});O("TFX_PURCHASED",[].concat(i2,c(a3)).join(","),{"max-age":200}),e3.purchaseEvent(n4.items,o3)}).catch(this.consoleLog)}else this.consoleLog("No Products, Check TFX_PURCHASED")}}},{key:"cartHookViewContentEvent",value:function(){var t3=this,e3=x(window,"carthook_object.product")||(x(window,"carthook_object.cart_data.line_items")||[])[0];e3&&this.getTagsCollections("/products/".concat(e3.handle)).then(function(n3){var o3=t3.extractTagsCollections(n3);t3.getProduct("/products/".concat(e3.handle)).then(function(n4){t3.tags=o3.tags,t3.collections=o3.collections,localStorage.setItem("tags",t3.tags.join(", ")),localStorage.setItem("collections",t3.collections.join(", ")),t3.product=JSON.parse(n4).product,t3.product.price=e3.line_price,t3.product.variants&&t3.product.variants.length&&(t3.product.variants[0].price=e3.line_price),t3.viewContentEvent()})}).catch(this.consoleLog)}},{key:"listenShopiPayEvents",value:function(t3){switch(this.consoleLog("SHOPIPAY EVENT",JSON.stringify(t3)),this.consoleLog("SHOPIPAY DATA LOADED",this.shop),t3.type){case"Initialize":this.consoleLog("ShopiPay Init...");break;case m:this.shopiPayInitiateCheckoutEvent(t3);break;case v:case"PostPurchase":this.shopiPayPurchaseEvent(t3);break;case g:this.shopiPayViewContentEvent(t3)}}},{key:"shopiPayInitiateCheckoutEvent",value:function(t3){var e3=this,n3=t3.products.map(function(t4){return{id:t4.product_id}});this.getProductsFromBackend(n3,this.cart).then(function(){e3.initiateCheckoutEvent()}).catch(console.log)}},{key:"shopiPayPurchaseEvent",value:function(t3){var e3=[];
2t3.products.forEach(function(t4){t4.product_id?e3.push(t4):t4.id&&(t4.product_id=t4.id,e3.push(t4))}),t3.upsellStep&&t3.accept?this.purchaseEvent(e3,"TFX_SHP_"+t3.upsellStep+" Purchase"):this.purchaseEvent(e3,"TFX_SHP_Initial Purchase")}},{key:"shopiPayViewContentEvent",value:function(t3){var e3=!0;this.isIOS14&&!this.viewContentEventFire&&(this.consoleLog("IOS14: ShopiPay View Content Event Restricted"),e3=!1);var n3=this;t3.products.forEach(function(t4){return n3.fire(g,e3,n3.getProductData(g,t4))}),this.consoleLog("Other: ShopiPay View Content Event Fired")}},{key:"listenBetterCartEvents",value:function(t3){switch(this.consoleLog("BetterCart EVENT",JSON.stringify(t3)),this.consoleLog("BetterCart DATA LOADED",this.shop),t3.type){case"Initialize":this.consoleLog("BetterCart Init...");break;case m:this.betterCartInitiateCheckoutEvent(t3);break;case v:case"PostPurchase":this.betterCartPurchaseEvent(t3);break;case g:this.betterCartViewContentEvent(t3);break;case"AddPaymentInfo":this.betterCartAddpaymentinfoEvent();break;case f:this.betterCartAddToCartEvent(t3)}}},{key:"betterCartInitiateCheckoutEvent",value:function(t3){var e3=this,n3=t3.products.map(function(t4){return{id:t4.id}});this.getProductsFromBackend(n3,this.cart).then(function(){e3.initiateCheckoutEvent(!0)}).catch(console.log)}},{key:"betterCartPurchaseEvent",value:function(t3){var e3=[];t3.products.forEach(function(t4){t4.product_id?e3.push(t4):t4.id&&(t4.product_id=t4.id,e3.push(t4))}),t3.upsellStep&&t3.accept?this.purchaseEvent(e3,"TFX_SHP_"+t3.upsellStep+" Purchase"):this.purchaseEvent(e3,"TFX_SHP_Initial Purchase")}},{key:"betterCartViewContentEvent",value:function(t3){var e3=!0;this.isIOS14&&!this.viewContentEventFire&&(this.consoleLog("IOS14: BetterCart View Content Event Restricted"),e3=!1);var n3=this;t3.products.forEach(function(t4){return n3.fire(g,e3,n3.getProductData(g,t4))}),this.consoleLog("Other: BetterCart View Content Event Fired")}},{key:"betterCartAddToCartEvent",value:function(t3){this.product=t3.products,this.addToCartEvent()}},{key:"betterCartAddpaymentinfoEvent",value:function(){this.setCart(this.cart),this.addPaymentInfoEvent()}}])&&s(e2.prototype,n2),o2&&s(e2,o2),t2})();window.trackify||(window.trackify=new X,window.trackify.init())},4:function(t,e,n){t.exports=n("/SWy")},ls82:function(t,e,n){var o=(function(t2){"use strict";var e2,n2=Object.prototype,o2=n2.hasOwnProperty,i=typeof Symbol=="function"?Symbol:{},a=i.iterator||"@@iterator",r=i.asyncIterator||"@@asyncIterator",c=i.toStringTag||"@@toStringTag";function s(t3,e3,n3,o3){var i2=e3&&e3.prototype instanceof f?e3:f,a2=Object.create(i2.prototype),r2=new P(o3||[]);return a2._invoke=(function(t4,e4,n4){var o4=l;return function(i3,a3){if(o4===h)throw new Error("Generator is already running");if(o4===p){if(i3==="throw")throw a3;return O()}for(n4.method=i3,n4.arg=a3;;){var r3=n4.delegate;if(r3){var c2=b(r3,n4);if(c2){if(c2===g)continue;return c2}}if(n4.method==="next")n4.sent=n4._sent=n4.arg;else if(n4.method==="throw"){if(o4===l)throw o4=p,n4.arg;n4.dispatchException(n4.arg)}else n4.method==="return"&&n4.abrupt("return",n4.arg);o4=h;var s2=u(t4,e4,n4);if(s2.type==="normal"){if(o4=n4.done?p:d,s2.arg===g)continue;return{value:s2.arg,done:n4.done}}s2.type==="throw"&&(o4=p,n4.method="throw",n4.arg=s2.arg)}}})(t3,n3,r2),a2}function u(t3,e3,n3){try{return{type:"normal",arg:t3.call(e3,n3)}}catch(t4){return{type:"throw",arg:t4}}}t2.wrap=s;var l="suspendedStart",d="suspendedYield",h="executing",p="completed",g={};function f(){}function v(){}function m(){}var y={};y[a]=function(){return this};var _=Object.getPrototypeOf,w=_&&_(_(L([])));w&&w!==n2&&o2.call(w,a)&&(y=w);var k=m.prototype=f.prototype=Object.create(y);function C(t3){["next","throw","return"].forEach(function(e3){t3[e3]=function(t4){return this._invoke(e3,t4)}})}function E(t3){var e3;this._invoke=function(n3,i2){function a2(){return new Promise(function(e4,a3){(function e5(n4,i3,a4,r2){var c2=u(t3[n4],t3,i3);if(c2.type!=="throw"){var s2=c2.arg,l2=s2.value;return l2&&typeof l2=="object"&&o2.call(l2,"__await")?Promise.resolve(l2.__await).then(function(t4){e5("next",t4,a4,r2)},function(t4){e5("throw",t4,a4,r2)}):Promise.resolve(l2).then(function(t4){s2.value=t4,a4(s2)},function(t4){return e5("throw",t4,a4,r2)})}r2(c2.arg)})(n3,i2,e4,a3)})}return e3=e3?e3.then(a2,a2):a2()}}function b(t3,n3){var o3=t3.iterator[n3.method];if(o3===e2){if(n3.delegate=null,n3.method==="throw"){if(t3.iterator.return&&
2(n3.method="return",n3.arg=e2,b(t3,n3),n3.method==="throw"))return g;n3.method="throw",n3.arg=new TypeError("The iterator does not provide a 'throw' method")}return g}var i2=u(o3,t3.iterator,n3.arg);if(i2.type==="throw")return n3.method="throw",n3.arg=i2.arg,n3.delegate=null,g;var a2=i2.arg;return a2?a2.done?(n3[t3.resultName]=a2.value,n3.next=t3.nextLoc,n3.method!=="return"&&(n3.method="next",n3.arg=e2),n3.delegate=null,g):a2:(n3.method="throw",n3.arg=new TypeError("iterator result is not an object"),n3.delegate=null,g)}function S(t3){var e3={tryLoc:t3[0]};1 in t3&&(e3.catchLoc=t3[1]),2 in t3&&(e3.finallyLoc=t3[2],e3.afterLoc=t3[3]),this.tryEntries.push(e3)}function T(t3){var e3=t3.completion||{};e3.type="normal",delete e3.arg,t3.completion=e3}function P(t3){this.tryEntries=[{tryLoc:"root"}],t3.forEach(S,this),this.reset(!0)}function L(t3){if(t3){var n3=t3[a];if(n3)return n3.call(t3);if(typeof t3.next=="function")return t3;if(!isNaN(t3.length)){var i2=-1,r2=function n4(){for(;++i2<t3.length;)if(o2.call(t3,i2))return n4.value=t3[i2],n4.done=!1,n4;return n4.value=e2,n4.done=!0,n4};return r2.next=r2}}return{next:O}}function O(){return{value:e2,done:!0}}return v.prototype=k.constructor=m,m.constructor=v,m[c]=v.displayName="GeneratorFunction",t2.isGeneratorFunction=function(t3){var e3=typeof t3=="function"&&t3.constructor;return!!e3&&(e3===v||(e3.displayName||e3.name)==="GeneratorFunction")},t2.mark=function(t3){return Object.setPrototypeOf?Object.setPrototypeOf(t3,m):(t3.__proto__=m,c in t3||(t3[c]="GeneratorFunction")),t3.prototype=Object.create(k),t3},t2.awrap=function(t3){return{__await:t3}},C(E.prototype),E.prototype[r]=function(){return this},t2.AsyncIterator=E,t2.async=function(e3,n3,o3,i2){var a2=new E(s(e3,n3,o3,i2));return t2.isGeneratorFunction(n3)?a2:a2.next().then(function(t3){return t3.done?t3.value:a2.next()})},C(k),k[c]="Generator",k[a]=function(){return this},k.toString=function(){return"[object Generator]"},t2.keys=function(t3){var e3=[];for(var n3 in t3)e3.push(n3);return e3.reverse(),function n4(){for(;e3.length;){var o3=e3.pop();if(o3 in t3)return n4.value=o3,n4.done=!1,n4}return n4.done=!0,n4}},t2.values=L,P.prototype={constructor:P,reset:function(t3){if(this.prev=0,this.next=0,this.sent=this._sent=e2,this.done=!1,this.delegate=null,this.method="next",this.arg=e2,this.tryEntries.forEach(T),!t3)for(var n3 in this)n3.charAt(0)==="t"&&o2.call(this,n3)&&!isNaN(+n3.slice(1))&&(this[n3]=e2)},stop:function(){this.done=!0;var t3=this.tryEntries[0].completion;if(t3.type==="throw")throw t3.arg;return this.rval},dispatchException:function(t3){if(this.done)throw t3;var n3=this;function i2(o3,i3){return c2.type="throw",c2.arg=t3,n3.next=o3,i3&&(n3.method="next",n3.arg=e2),!!i3}for(var a2=this.tryEntries.length-1;a2>=0;--a2){var r2=this.tryEntries[a2],c2=r2.completion;if(r2.tryLoc==="root")return i2("end");if(r2.tryLoc<=this.prev){var s2=o2.call(r2,"catchLoc"),u2=o2.call(r2,"finallyLoc");if(s2&&u2){if(this.prev<r2.catchLoc)return i2(r2.catchLoc,!0);if(this.prev<r2.finallyLoc)return i2(r2.finallyLoc)}else if(s2){if(this.prev<r2.catchLoc)return i2(r2.catchLoc,!0)}else{if(!u2)throw new Error("try statement without catch or finally");if(this.prev<r2.finallyLoc)return i2(r2.finallyLoc)}}}},abrupt:function(t3,e3){for(var n3=this.tryEntries.length-1;n3>=0;--n3){var i2=this.tryEntries[n3];if(i2.tryLoc<=this.prev&&o2.call(i2,"finallyLoc")&&this.prev<i2.finallyLoc){var a2=i2;break}}a2&&(t3==="break"||t3==="continue")&&a2.tryLoc<=e3&&e3<=a2.finallyLoc&&(a2=null);var r2=a2?a2.completion:{};return r2.type=t3,r2.arg=e3,a2?(this.method="next",this.next=a2.finallyLoc,g):this.complete(r2)},complete:function(t3,e3){if(t3.type==="throw")throw t3.arg;return t3.type==="break"||t3.type==="continue"?this.next=t3.arg:t3.type==="return"?(this.rval=this.arg=t3.arg,this.method="return",this.next="end"):t3.type==="normal"&&e3&&(this.next=e3),g},finish:function(t3){for(var e3=this.tryEntries.length-1;e3>=0;--e3){var n3=this.tryEntries[e3];if(n3.finallyLoc===t3)return this.complete(n3.completion,n3.afterLoc),T(n3),g}},catch:function(t3){for(var e3=this.tryEntries.length-1;e3>=0;--e3){var n3=this.tryEntries[e3];if(n3.tryLoc===t3){var o3=n3.completion;if(o3.type==="throw"){var i2=o3.arg;T(n3)}return i2}}throw new Error("illegal catch attempt")},delegateYield:function(t3,n3,o3){return this.delegate={iterator:L(t3),resultName:n3,nextLoc:o3},this.method==="next"&&(this.arg=e2),g}},t2})(t.exports);try{regeneratorRuntime=o}catch{Function("r","regeneratorRuntime = r")(o)}},o0o1:function(t,e,n){t.exports=n("ls82")}});
3//# sourceMappingURL=/cdn/shop/t/7/assets/js-trackifyx.js.map?v=32769155987791644431729424014

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.