1import{b as g}from"/build/_shared/chunk-2VHJHPYT.js";import{c as p}from"/build/_shared/chunk-PE2RAMGK.js";import{a as f}from"/build/_shared/chunk-RZLDKGLN.js";import{a}from"/build/_shared/chunk-FONEQPGK.js";import{a as d}from"/build/_shared/chunk-DEVQKMWM.js";import{c as m}from"/build/_shared/chunk-L4FEFM7G.js";import{a as u}from"/build/_shared/chunk-H6S7FWVP.js";import{d as l}from"/build/_shared/chunk-T36URGAI.js";var o=l(u());var w=()=>/Mobi/i.test(window.navigator.userAgent)?"mobile":"desktop",I=({pageCategory:t,subCategory:n})=>{let{user:e}=(0,o.useContext)(f),r=(0,o.useContext)(d),v=m(),{setPageCategory:i}=p();(0,o.useEffect)(()=>{t&&i(t)},[t,i]),(0,o.useEffect)(()=>{let s=window.location.href,c=document.referrer;if(t&&s!==c){let y=w();a({event:"beforeSnippet",event_id:g(),page:{pageCategory:t,...n&&{subCategory:n},environment:"",fieldTimestamp:Date.now(),pageReferrer:c,currencyCode:(r==null?void 0:r.currency)||"GBP",url:s},user:{countryStore:"united kingdom",deviceType:y,loggedInStatus:e&&!(e!=null&&e.guest),...e&&!(e!=null&&e.guest)&&{gender:(e==null?void 0:e.gender)||"",userEmailAddress:e==null?void 0:e.email,userId:e==null?void 0:e.id}}})}},[t,n,v])};export{I as a};
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.