1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2888],{6840:function(a,l,c){(window.__NEXT_P=window.__NEXT_P||[]).push(["/_app",function(){return c(68834)}])},97498:function(a,l){"use strict";var c,u;Object.defineProperty(l,"__esModule",{value:!0}),function(a,l){for(var c in l)Object.defineProperty(a,c,{enumerable:!0,get:l[c]})}(l,{PrefetchKind:function(){return c},ACTION_REFRESH:function(){return d},ACTION_NAVIGATE:function(){return p},ACTION_RESTORE:function(){return g},ACTION_SERVER_PATCH:function(){return f},ACTION_PREFETCH:function(){return v},ACTION_FAST_REFRESH:function(){return _},ACTION_SERVER_ACTION:function(){return w}});let d="refresh",p="navigate",g="restore",f="server-patch",v="prefetch",_="fast-refresh",w="server-action";(u=c||(c={})).AUTO="auto",u.FULL="full",u.TEMPORARY="temporary",("function"==typeof l.default||"object"==typeof l.default&&null!==l.default)&&void 0===l.default.__esModule&&(Object.defineProperty(l.default,"__esModule",{value:!0}),Object.assign(l.default,l),a.exports=l.default)},10030:function(a,l,c){"use strict";function getDomainLocale(a,l,c,u){return!1}Object.defineProperty(l,"__esModule",{value:!0}),Object.defineProperty(l,"getDomainLocale",{enumerable:!0,get:function(){return getDomainLocale}}),c(22866),("function"==typeof l.default||"object"==typeof l.default&&null!==l.default)&&void 0===l.default.__esModule&&(Object.defineProperty(l.default,"__esModule",{value:!0}),Object.assign(l.default,l),a.exports=l.default)},23271:function(a,l,c){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),Object.defineProperty(l,"Image",{enumerable:!0,get:function(){return N}});let u=c(38754),d=c(61757),p=d._(c(67294)),g=u._(c(73935)),f=u._(c(79201)),v=c(53914),_=c(85494),w=c(30869);c(81905);let x=c(11823),k=u._(c(74545)),S={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1};function handleLoading(a,l,c,u,d,p){let g=null==a?void 0:a.src;if(!a||a["data-loaded-src"]===g)return;a["data-loaded-src"]=g;let f="decode"in a?a.decode():Promise.resolve();f.catch(()=>{}).then(()=>{if(a.parentElement&&a.isConnected){if("empty"!==l&&d(!0),null==c?void 0:c.current){let l=new Event("load");Object.defineProperty(l,"target",{writable:!1,value:a});let u=!1,d=!1;c.current({...l,nativeEvent:l,currentTarget:a,target:a,isDefaultPrevented:()=>u,isPropagationStopped:()=>d,persist:()=>{},preventDefault:()=>{u=!0,l.preventDefault()},stopPropagation:()=>{d=!0,l.stopPropagation()}})}(null==u?void 0:u.current)&&u.current(a)}})}function getDynamicProps(a){let[l,c]=p.version.split("."),u=parseInt(l,10),d=parseInt(c,10);return u>18||18===u&&d>=3?{fetchPriority:a}:{fetchpriority:a}}let $=(0,p.forwardRef)((a,l)=>{let{src:c,srcSet:u,sizes:d,height:g,width:f,decoding:v,className:_,style:w,fetchPriority:x,placeholder:k,loading:S,unoptimized:$,fill:N,onLoadRef:z,onLoadingCompleteRef:U,setBlurComplete:W,setShowAltText:et,onLoad:ei,onError:er,...en}=a;return p.default.createElement("img",{...en,...getDynamicProps(x),loading:S,width:f,height:g,decoding:v,"data-nimg":N?"fill":"1",className:_,style:w,sizes:d,srcSet:u,src:c,ref:(0,p.useCallback)(a=>{l&&("function"==typeof l?l(a):"object"==typeof l&&(l.current=a)),a&&(er&&(a.src=a.src),a.complete&&handleLoading(a,k,z,U,W,$))},[c,k,z,U,W,er,$,l]),onLoad:a=>{let l=a.currentTarget;handleLoading(l,k,z,U,W,$)},onError:a=>{et(!0),"empty"!==k&&W(!0),er&&er(a)}})});function ImagePreload(a){let{isAppRouter:l,imgAttributes:c}=a,u={as:"image",imageSrcSet:c.srcSet,imageSizes:c.sizes,crossOrigin:c.crossOrigin,referrerPolicy:c.referrerPolicy,...getDynamicProps(c.fetchPriority)};return l&&g.default.preload?(g.default.preload(c.src,u),null):p.default.createElement(f.default,null,p.default.createElement("link",{key:"__nimg-"+c.src+c.srcSet+c.sizes,rel:"preload",href:c.srcSet?void 0:c.src,...u}))}let N=(0,p.forwardRef)((a,l)=>{let c=(0,p.useContext)(x.RouterContext),u=(0,p.useContext)(w.ImageConfigContext),d=(0,p.useMemo)(()=>{let a=S||u||_.imageConfigDefault,l=[...a.deviceSizes,...a.imageSizes].sort((a,l)=>a-l),c=a.deviceSizes.sort((a,l)=>a-l);return{...a,allSizes:l,deviceSizes:c}},[u]),{onLoad:g,onLoadingComplete:f}=a,N=(0,p.useRef)(g);(0,p.useEffect)(()=>{N.current=g},[g]);let z=(0,p.useRef)(f);(0,p.useEffect)(()=>{z.current=f},[f]);let[U,W]=(0,p.useState)(!1),[et,ei]=(0,p.useState)(!1),{props:er,meta:en}=(0,v.getImgProps)(a,{defaultLoader:k.default,imgConf:d,blurComplete:U,showAltText:et});return p.default.createElement(p.default.Fragment,null,p.default.createElement($,{...er,unoptimized:en.unoptimized,placeholder:en.placeholder,fill:en.fill,onLoadRef:N,onLoadingCompleteRef:z,setBlurComplete:W,setShowAltText:ei,ref:l}),en.priority?p.default.createElement(ImagePreload,{isAppRouter:!c,imgAttributes:er}):null)});("function"==typeof l.default||"object"==typeof l.default&&null!==l.default)&&void 0===l.default.__esModule&&(Object.defineProperty(l.default,"__esMo
1dule",{value:!0}),Object.assign(l.default,l),a.exports=l.default)},65170:function(a,l,c){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),Object.defineProperty(l,"default",{enumerable:!0,get:function(){return W}});let u=c(38754),d=u._(c(67294)),p=c(74450),g=c(92227),f=c(64364),v=c(10109),_=c(73607),w=c(11823),x=c(89031),k=c(40920),S=c(10030),$=c(77192),N=c(97498),z=new Set;function prefetch(a,l,c,u,d,p){if(!p&&!(0,g.isLocalURL)(l))return;if(!u.bypassPrefetchedCheck){let d=void 0!==u.locale?u.locale:"locale"in a?a.locale:void 0,p=l+"%"+c+"%"+d;if(z.has(p))return;z.add(p)}let f=p?a.prefetch(l,d):a.prefetch(l,c,u);Promise.resolve(f).catch(a=>{})}function formatStringOrUrl(a){return"string"==typeof a?a:(0,f.formatUrl)(a)}let U=d.default.forwardRef(function(a,l){let c,u;let{href:f,as:z,children:U,prefetch:W=null,passHref:et,replace:ei,shallow:er,scroll:en,locale:eo,onClick:ea,onMouseEnter:el,onTouchStart:ec,legacyBehavior:eu=!1,...ed}=a;c=U,eu&&("string"==typeof c||"number"==typeof c)&&(c=d.default.createElement("a",null,c));let eh=d.default.useContext(w.RouterContext),ep=d.default.useContext(x.AppRouterContext),eg=null!=eh?eh:ep,ef=!eh,ev=!1!==W,e_=null===W?N.PrefetchKind.AUTO:N.PrefetchKind.FULL,{href:em,as:ey}=d.default.useMemo(()=>{if(!eh){let a=formatStringOrUrl(f);return{href:a,as:z?formatStringOrUrl(z):a}}let[a,l]=(0,p.resolveHref)(eh,f,!0);return{href:a,as:z?(0,p.resolveHref)(eh,z):l||a}},[eh,f,z]),eb=d.default.useRef(em),ew=d.default.useRef(ey);eu&&(u=d.default.Children.only(c));let ex=eu?u&&"object"==typeof u&&u.ref:l,[ek,eE,eS]=(0,k.useIntersection)({rootMargin:"200px"}),eI=d.default.useCallback(a=>{(ew.current!==ey||eb.current!==em)&&(eS(),ew.current=ey,eb.current=em),ek(a),ex&&("function"==typeof ex?ex(a):"object"==typeof ex&&(ex.current=a))},[ey,ex,em,eS,ek]);d.default.useEffect(()=>{eg&&eE&&ev&&prefetch(eg,em,ey,{locale:eo},{kind:e_},ef)},[ey,em,eE,eo,ev,null==eh?void 0:eh.locale,eg,ef,e_]);let eC={ref:eI,onClick(a){eu||"function"!=typeof ea||ea(a),eu&&u.props&&"function"==typeof u.props.onClick&&u.props.onClick(a),eg&&!a.defaultPrevented&&function(a,l,c,u,p,f,v,_,w,x){let{nodeName:k}=a.currentTarget,S="A"===k.toUpperCase();if(S&&(function(a){let l=a.currentTarget,c=l.getAttribute("target");return c&&"_self"!==c||a.metaKey||a.ctrlKey||a.shiftKey||a.altKey||a.nativeEvent&&2===a.nativeEvent.which}(a)||!w&&!(0,g.isLocalURL)(c)))return;a.preventDefault();let navigate=()=>{let a=null==v||v;"beforePopState"in l?l[p?"replace":"push"](c,u,{shallow:f,locale:_,scroll:a}):l[p?"replace":"push"](u||c,{forceOptimisticNavigation:!x,scroll:a})};w?d.default.startTransition(navigate):navigate()}(a,eg,em,ey,ei,er,en,eo,ef,ev)},onMouseEnter(a){eu||"function"!=typeof el||el(a),eu&&u.props&&"function"==typeof u.props.onMouseEnter&&u.props.onMouseEnter(a),eg&&(ev||!ef)&&prefetch(eg,em,ey,{locale:eo,priority:!0,bypassPrefetchedCheck:!0},{kind:e_},ef)},onTouchStart(a){eu||"function"!=typeof ec||ec(a),eu&&u.props&&"function"==typeof u.props.onTouchStart&&u.props.onTouchStart(a),eg&&(ev||!ef)&&prefetch(eg,em,ey,{locale:eo,priority:!0,bypassPrefetchedCheck:!0},{kind:e_},ef)}};if((0,v.isAbsoluteUrl)(ey))eC.href=ey;else if(!eu||et||"a"===u.type&&!("href"in u.props)){let a=void 0!==eo?eo:null==eh?void 0:eh.locale,l=(null==eh?void 0:eh.isLocaleDomain)&&(0,S.getDomainLocale)(ey,a,null==eh?void 0:eh.locales,null==eh?void 0:eh.domainLocales);eC.href=l||(0,$.addBasePath)((0,_.addLocale)(ey,a,null==eh?void 0:eh.defaultLocale))}return eu?d.default.cloneElement(u,eC):d.default.createElement("a",{...ed,...eC},c)}),W=U;("function"==typeof l.default||"object"==typeof l.default&&null!==l.default)&&void 0===l.default.__esModule&&(Object.defineProperty(l.default,"__esModule",{value:!0}),Object.assign(l.default,l),a.exports=l.default)},40920:function(a,l,c){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),Object.defineProperty(l,"useIntersection",{enumerable:!0,get:function(){return useIntersection}});let u=c(67294),d=c(63436),p="function"==typeof IntersectionObserver,g=new Map,f=[];function useIntersection(a){let{rootRef:l,rootMargin:c,disabled:v}=a,_=v||!p,[w,x]=(0,u.useState)(!1),k=(0,u.useRef)(null),S=(0,u.useCallback)(a=>{k.current=a},[]);(0,u.useEffect)(()=>
1{if(p){if(_||w)return;let a=k.current;if(a&&a.tagName){let u=function(a,l,c){let{id:u,observer:d,elements:p}=function(a){let l;let c={root:a.root||null,margin:a.rootMargin||""},u=f.find(a=>a.root===c.root&&a.margin===c.margin);if(u&&(l=g.get(u)))return l;let d=new Map,p=new IntersectionObserver(a=>{a.forEach(a=>{let l=d.get(a.target),c=a.isIntersecting||a.intersectionRatio>0;l&&c&&l(c)})},a);return l={id:c,observer:p,elements:d},f.push(c),g.set(c,l),l}(c);return p.set(a,l),d.observe(a),function(){if(p.delete(a),d.unobserve(a),0===p.size){d.disconnect(),g.delete(u);let a=f.findIndex(a=>a.root===u.root&&a.margin===u.margin);a>-1&&f.splice(a,1)}}}(a,a=>a&&x(a),{root:null==l?void 0:l.current,rootMargin:c});return u}}else if(!w){let a=(0,d.requestIdleCallback)(()=>x(!0));return()=>(0,d.cancelIdleCallback)(a)}},[_,c,l,w,k.current]);let $=(0,u.useCallback)(()=>{x(!1)},[]);return[S,w,$]}("function"==typeof l.default||"object"==typeof l.default&&null!==l.default)&&void 0===l.default.__esModule&&(Object.defineProperty(l.default,"__esModule",{value:!0}),Object.assign(l.default,l),a.exports=l.default)},53914:function(a,l,c){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),Object.defineProperty(l,"getImgProps",{enumerable:!0,get:function(){return getImgProps}}),c(81905);let u=c(32393),d=c(85494);function isStaticRequire(a){return void 0!==a.default}function getInt(a){return void 0===a?a:"number"==typeof a?Number.isFinite(a)?a:NaN:"string"==typeof a&&/^[0-9]+$/.test(a)?parseInt(a,10):NaN}function getImgProps(a,l){var c;let p,g,f,{src:v,sizes:_,unoptimized:w=!1,priority:x=!1,loading:k,className:S,quality:$,width:N,height:z,fill:U=!1,style:W,onLoad:et,onLoadingComplete:ei,placeholder:er="empty",blurDataURL:en,fetchPriority:eo,layout:ea,objectFit:el,objectPosition:ec,lazyBoundary:eu,lazyRoot:ed,...eh}=a,{imgConf:ep,showAltText:eg,blurComplete:ef,defaultLoader:ev}=l,e_=ep||d.imageConfigDefault;if("allSizes"in e_)p=e_;else{let a=[...e_.deviceSizes,...e_.imageSizes].sort((a,l)=>a-l),l=e_.deviceSizes.sort((a,l)=>a-l);p={...e_,allSizes:a,deviceSizes:l}}let em=eh.loader||ev;delete eh.loader,delete eh.srcSet;let ey="__next_img_default"in em;if(ey){if("custom"===p.loader)throw Error('Image with src "'+v+'" is missing "loader" prop.\nRead more: https://nextjs.org/docs/messages/next-image-missing-loader')}else{let a=em;em=l=>{let{config:c,...u}=l;return a(u)}}if(ea){"fill"===ea&&(U=!0);let a={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}}[ea];a&&(W={...W,...a});let l={responsive:"100vw",fill:"100vw"}[ea];l&&!_&&(_=l)}let eb="",ew=getInt(N),ex=getInt(z);if("object"==typeof(c=v)&&(isStaticRequire(c)||void 0!==c.src)){let a=isStaticRequire(v)?v.default:v;if(!a.src)throw Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received "+JSON.stringify(a));if(!a.height||!a.width)throw Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received "+JSON.stringify(a));if(g=a.blurWidth,f=a.blurHeight,en=en||a.blurDataURL,eb=a.src,!U){if(ew||ex){if(ew&&!ex){let l=ew/a.width;ex=Math.round(a.height*l)}else if(!ew&&ex){let l=ex/a.height;ew=Math.round(a.width*l)}}else ew=a.width,ex=a.height}}let ek=!x&&("lazy"===k||void 0===k);(!(v="string"==typeof v?v:eb)||v.startsWith("data:")||v.startsWith("blob:"))&&(w=!0,ek=!1),p.unoptimized&&(w=!0),ey&&v.endsWith(".svg")&&!p.dangerouslyAllowSVG&&(w=!0),x&&(eo="high");let eE=getInt($),eS=Object.assign(U?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:el,objectPosition:ec}:{},eg?{}:{color:"transparent"},W),eI=ef||"empty"===er?null:"blur"===er?'url("data:image/svg+xml;charset=utf-8,'+(0,u.getImageBlurSvg)({widthInt:ew,heightInt:ex,blurWidth:g,blurHeight:f,blurDataURL:en||"",objectFit:eS.objectFit})+'")':'url("'+er+'")',eC=eI?{backgroundSize:eS.objectFit||"cover",backgroundPosition:eS.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:eI}:{},eR=function(a){let{config:l,src:c,unoptimized:u,width:d,quality:p,sizes:g,loader:f}=a;if(u)return{src:c,srcSet:void 0,sizes:void 0};let{widths:v,kind:_}=function(a,l,c){let{deviceSizes:u,allSizes:d}=a;if(c){let a=/(^|\s)(1?\d?\d)vw/g,l=[];for(let u;u=a.exec(c);u)l.push(parseInt(u[2]));if(l.length){let a=.01*Math.min(...l);return{widths:d.filter(l=>l>=u[0]*a),kind:"w"}}return{widths:d,kind:"w"}}if("number"!=typeof l)return{widths:u,kind:"w"};let p=[...new Set([l,2*l].map(a=>d.find(l=>l>=a)||d[d.length-1]))];return{widths:p,kind:"x"}}(l,d,g),w=v.length-1;return{sizes:g||"w"!==_?g:"100vw",srcSet:v.map((a,u)=>
1f({config:l,src:c,quality:p,width:a})+" "+("w"===_?a:u+1)+_).join(", "),src:f({config:l,src:c,quality:p,width:v[w]})}}({config:p,src:v,unoptimized:w,width:ew,quality:eE,sizes:_,loader:em}),eP={...eh,loading:ek?"lazy":k,fetchPriority:eo,width:ew,height:ex,decoding:"async",className:S,style:{...eS,...eC},sizes:eR.sizes,srcSet:eR.srcSet,src:eR.src},eF={unoptimized:w,priority:x,placeholder:er,fill:U};return{props:eP,meta:eF}}},32393:function(a,l){"use strict";function getImageBlurSvg(a){let{widthInt:l,heightInt:c,blurWidth:u,blurHeight:d,blurDataURL:p,objectFit:g}=a,f=u?40*u:l,v=d?40*d:c,_=f&&v?"viewBox='0 0 "+f+" "+v+"'":"";return"%3Csvg xmlns='http://www.w3.org/2000/svg' "+_+"%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='"+(_?"none":"contain"===g?"xMidYMid":"cover"===g?"xMidYMid slice":"none")+"' style='filter: url(%23b);' href='"+p+"'/%3E%3C/svg%3E"}Object.defineProperty(l,"__esModule",{value:!0}),Object.defineProperty(l,"getImageBlurSvg",{enumerable:!0,get:function(){return getImageBlurSvg}})},645:function(a,l,c){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),function(a,l){for(var c in l)Object.defineProperty(a,c,{enumerable:!0,get:l[c]})}(l,{unstable_getImgProps:function(){return unstable_getImgProps},default:function(){return v}});let u=c(38754),d=c(53914),p=c(81905),g=c(23271),f=u._(c(74545)),unstable_getImgProps=a=>{(0,p.warnOnce)("Warning: unstable_getImgProps() is experimental and may change or be removed at any time. Use at your own risk.");let{props:l}=(0,d.getImgProps)(a,{defaultLoader:f.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1}});for(let[a,c]of Object.entries(l))void 0===c&&delete l[a];return{props:l}},v=g.Image},74545:function(a,l){"use strict";function defaultLoader(a){let{config:l,src:c,width:u,quality:d}=a;return l.path+"?url="+encodeURIComponent(c)+"&w="+u+"&q="+(d||75)}Object.defineProperty(l,"__esModule",{value:!0}),Object.defineProperty(l,"default",{enumerable:!0,get:function(){return c}}),defaultLoader.__next_img_default=!0;let c=defaultLoader},68834:function(a,l,c){"use strict";c.r(l),c.d(l,{default:function(){return App}});var u=c(85893),d=c(67294),p=c(9008),g=c.n(p);c(70415);var f=c(4298),v=c.n(f),_=c(41664),w=c.n(_),x=c(31415);let k=d.forwardRef(function({title:a,titleId:l,...c},u){return d.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:u,"aria-labelledby":l},c),a?d.createElement("title",{id:l},a):null,d.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3.75 6.75h16.5M3.75 12h16.5m-16.5 5.25h16.5"}))});var S=c(25675),$=c.n(S);function Logo(){return(0,u.jsx)("div",{className:"flex items-center","aria-label":"Go to home",children:(0,u.jsx)($(),{role:"img",alt:"SalaryCalculate logo",src:"/logo.png",width:40,height:40,className:"object-contain"})})}var N={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},z=d.createContext&&d.createContext(N),U=["attr","size","title"];function _extends(){return(_extends=Object.assign?Object.assign.bind():function(a){for(var l=1;l<arguments.length;l++){var c=arguments[l];for(var u in c)Object.prototype.hasOwnProperty.call(c,u)&&(a[u]=c[u])}return a}).apply(this,arguments)}function ownKeys(a,l){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(a);l&&(u=u.filter(function(l){return Object.getOwnPropertyDescriptor(a,l).enumerable})),c.push.apply(c,u)}return c}function _objectSpread(a){for(var l=1;l<arguments.length;l++){var c=null!=arguments[l]?arguments[l]:{};
1l%2?ownKeys(Object(c),!0).forEach(function(l){var u,d;u=l,d=c[l],(u=function(a){var l=function(a,l){if("object"!=typeof a||!a)return a;var c=a[Symbol.toPrimitive];if(void 0!==c){var u=c.call(a,l||"default");if("object"!=typeof u)return u;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===l?String:Number)(a)}(a,"string");return"symbol"==typeof l?l:l+""}(u))in a?Object.defineProperty(a,u,{value:d,enumerable:!0,configurable:!0,writable:!0}):a[u]=d}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(c)):ownKeys(Object(c)).forEach(function(l){Object.defineProperty(a,l,Object.getOwnPropertyDescriptor(c,l))})}return a}function iconBase_GenIcon(a){return l=>d.createElement(IconBase,_extends({attr:_objectSpread({},a.attr)},l),function Tree2Element(a){return a&&a.map((a,l)=>d.createElement(a.tag,_objectSpread({key:l},a.attr),Tree2Element(a.child)))}(a.child))}function IconBase(a){var elem=l=>{var c,{attr:u,size:p,title:g}=a,f=function(a,l){if(null==a)return{};var c,u,d=function(a,l){if(null==a)return{};var c={};for(var u in a)if(Object.prototype.hasOwnProperty.call(a,u)){if(l.indexOf(u)>=0)continue;c[u]=a[u]}return c}(a,l);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(a);for(u=0;u<p.length;u++)c=p[u],!(l.indexOf(c)>=0)&&Object.prototype.propertyIsEnumerable.call(a,c)&&(d[c]=a[c])}return d}(a,U),v=p||l.size||"1em";return l.className&&(c=l.className),a.className&&(c=(c?c+" ":"")+a.className),d.createElement("svg",_extends({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},l.attr,u,f,{className:c,style:_objectSpread(_objectSpread({color:a.color||l.color},l.style),a.style),height:v,width:v,xmlns:"http://www.w3.org/2000/svg"}),g&&d.createElement("title",null,g),a.children)};return void 0!==z?d.createElement(z.Consumer,null,a=>elem(a)):elem(N)}function FaMedium(a){return iconBase_GenIcon({tag:"svg",attr:{viewBox:"0 0 640 512"},child:[{tag:"path",attr:{d:"M180.5,74.262C80.813,74.262,0,155.633,0,256S80.819,437.738,180.5,437.738,361,356.373,361,256,280.191,74.262,180.5,74.262Zm288.25,10.646c-49.845,0-90.245,76.619-90.245,171.095s40.406,171.1,90.251,171.1,90.251-76.619,90.251-171.1H559C559,161.5,518.6,84.908,468.752,84.908Zm139.506,17.821c-17.526,0-31.735,68.628-31.735,153.274s14.2,153.274,31.735,153.274S640,340.631,640,256C640,171.351,625.785,102.729,608.258,102.729Z"},child:[]}]})(a)}function FaXTwitter(a){return iconBase_GenIcon({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M389.2 48h70.6L305.6 224.2 487 464H345L233.7 318.6 106.5 464H35.8L200.7 275.5 26.8 48H172.4L272.9 180.9 389.2 48zM364.4 421.8h39.1L151.1 88h-42L364.4 421.8z"},child:[]}]})(a)}function FaYoutube(a){return iconBase_GenIcon({tag:"svg",attr:{viewBox:"0 0 576 512"},child:[{tag:"path",attr:{d:"M549.655 124.083c-6.281-23.65-24.787-42.276-48.284-48.597C458.781 64 288 64 288 64S117.22 64 74.629 75.486c-23.497 6.322-42.003 24.947-48.284 48.597-11.412 42.867-11.412 132.305-11.412 132.305s0 89.438 11.412 132.305c6.281 23.65 24.787 41.5 48.284 47.821C117.22 448 288 448 288 448s170.78 0 213.371-11.486c23.497-6.321 42.003-24.171 48.284-47.821 11.412-42.867 11.412-132.305 11.412-132.305s0-89.438-11.412-132.305zm-317.51 213.508V175.185l142.739 81.205-142.739 81.201z"},child:[]}]})(a)}function SiTiktok(a){return iconBase_GenIcon({tag:"svg",attr:{role:"img",viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M12.525.02c1.31-.02 2.61-.01 3.91-.02.08 1.53.63 3.09 1.75 4.17 1.12 1.11 2.7 1.62 4.24 1.79v4.03c-1.44-.05-2.89-.35-4.2-.97-.57-.26-1.1-.59-1.62-.93-.01 2.92.01 5.84-.02 8.75-.08 1.4-.54 2.79-1.35 3.94-1.31 1.92-3.58 3.17-5.91 3.21-1.43.08-2.86-.31-4.08-1.03-2.02-1.19-3.44-3.37-3.65-5.71-.02-.5-.03-1-.01-1.49.18-1.9 1.12-3.72 2.58-4.96 1.66-1.44 3.98-2.13 6.15-1.72.02 1.48-.04 2.96-.04 4.44-.99-.32-2.15-.23-3.02.37-.63.41-1.11 1.04-1.36 1.75-.21.51-.15 1.07-.14 1.61.24 1.64 1.82 3.02 3.5 2.87 1.12-.01 2.19-.66 2.77-1.61.19-.33.4-.67.41-1.06.1-1.79.06-3.57.07-5.36.01-4.03-.01-8.05.02-12.07z"},child:[]}]})(a)}function SiTrustpilot(a){return iconBase_GenIcon({tag:"svg",attr:{role:"img",viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M17.227 16.67l2.19 6.742-7.413-5.388 5.223-1.354zM24 9.31h-9.165L12.005.589l-2.84 8.723L0 9.3l7.422 5.397-2.84 8.714 7.422-5.388 4.583-3.326L24 9.311z"},child:[]}]})(a)}function Footer(){return(0,u.jsx)("footer",{className:"w-full bg-gray-100 dark:bg-gray-900 text-gray-600 dark:text-gray-300 text-sm transition-colors duration-200",children:(0,u.jsxs)("div",{className:"max-w-4xl mx-auto px-4 py-6 flex flex-col sm:flex-row justify-between items-center gap-4",children:[(0,u.jsxs)("p",{className:"text-center sm:text-left",children:["\xa9 ",new Date().getFullYear()," salarycalculate.com â All rights reserved."]}),(0,u.jsxs)("div",{className:"flex justify-center gap-4 text-2xl",children:[(0,u.jsx)("a",{href:"https://medium.com/@stuart_86736",target:"_blank",rel:"noopener noreferrer nofollow","aria-label":"Medium",className:"hover:text-black dark:hover:text-white",children:(0,u.jsx)(FaMedium,{})}),(0,u.jsx)("a",{href:"https://www.youtube.com/@salarycalculate",target:"_blank",rel:"noopener noreferrer nofollow","aria-label":"YouTube",className:"hover:text-red-600",children:(0,u.jsx)(FaYoutube,{})}),(0,u.jsx)("a",{href:"https://x.com/salarycalculate",target:"_blank",rel:"noopener noreferrer nofollow","aria-label":"X (Twitter)",className:"hover:text-sky-600",children:(0,u.jsx)(FaXTwitter,{})}),(0,u.jsx)("a",{href:"https://www.tiktok.com/@salarycalculate",target:"_blank",rel:"noopener noreferrer nofollow","aria-label":"TikTok",className:"hover:text-gray-800",children:(0,u.jsx)(SiTiktok,{})}),(0,u.jsx)("a",{href:"https://www.trustpilot.com/review/salarycalculate.com",target:"_blank",rel:"noopener noreferrer nofollow","aria-label":"Trustpilot",className:"hover:text-green-600",children:(0,u.jsx)(SiTrustpilot,{})})]}),(0,u.jsxs)("div",{className:"flex flex-wrap gap-4 items-center justify-center sm:justify-end",children:[(0,u.jsx)(w(),{href:"/carnivalofpersonalfinance",className:"inline-flex items-center","aria-label":"Carnival of Personal Finance",children:(0,u.jsx)("img",{src:"/img/copf/cpf-badge.jpg",alt:"Carnival of Personal Finance",className:"h-8 w-auto rounded shadow-sm ring-1 ring-black/5 dark:ring-white/10"})}),(0,u.jsxs)("a",{href:"https://www.cheapfuelnear.me",target:"_blank",rel:"noopener noreferrer nofollow",className:"inline-flex items-center gap-2 hover:opacity-90 transition-opacity","aria-label":"Cheap Fuel Near Me - UK fuel finder app",children:[(0,u.jsx)("img",{src:"/img/logo.png",alt:"",className:"h-8 w-auto rounded shadow-sm ring-1 ring-black/5 dark:ring-white/10"}),(0,u.jsx)("span",{className:"text-gray-600 dark:text-gray-300",children:"Try out new UK cheap fuel finder app"})]}),(0,u.jsx)(w(),{href:"/disclaimer",className:"hover:text-gray-900 dark:hover:text-gray-100",children:"Disclaimer"}),(0,u.jsx)(w(),{href:"/privacy",className:"hover:text-gray-900 dark:hover:text-gray-100",children:"Privacy"}),(0,u.jsx)(w(),{href:"/terms",className:"hover:text-gray-900 dark:hover:text-gray-100",children:"Terms"})]})]})})}function CookieBanner(){let[a,l]=(0,d.useState)(!1);return((0,d.useEffect)(()=>{let a=localStorage.getItem("cookie-consent");a||l(!0)},[]),a)?(0,u.jsx)("div",{className:"fixed bottom-0 w-full bg-[#F2f2f2] text-white text-sm px-4 py-3 z-50 shadow-md",children:(0,u.jsxs)("div",{className:"max-w-4xl mx-auto flex flex-col sm:flex-row justify-between items-center gap-4",children:[(0,u.jsxs)("p",{className:"text-black",children:["We use cookies to enhance your experience. By continuing, you agree to our"," ",(0,u.jsx)("a",{href:"/privacy",className:"underline text-black font-medium",children:"Read our Privacy Policy"})]}),(0,u.jsx)("button",{onClick:()=>{localStorage.setItem("cookie-consent","true"),l(!1)},className:"bg-white text-[#781214] px-4 py-2 rounded font-semibold shadow hover:bg-gray-100",children:"Accept"})]})}):null}let W=d.forwardRef(function({title:a,titleId:l,...c},u){return d.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:u,"aria-labelledby":l},c),a?d.createElement("title",{id:l},a):null,d.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 3v2.25m6.364.386-1.591 1.591M21 12h-2.25m-.386 6.364-1.591-1.591M12 18.75V21m-4.773-4.227-1.591 1.591M5.25 12H3m4.227-4.773L5.636 5.636M15.75 12a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0Z"}))}),et=d.forwardRef(function({title:a,titleId:l,...c},u){return d.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:u,"aria-labelledby":l},c),a?d.createElement("title",{id:l},a):null,d.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21.752 15.002A9.72 9.72 0 0 1 18 15.75c-5.385 0-9.75-4.365-9.75-9.75 0-1.33.266-2.597.748-3.752A9.753 9.753 0 0 0 3 11.25C3 16.635 7.365 21 12.75 21a9.753 9.753 0 0 0 9.002-5.998Z"}))});function ThemeToggle(){let[a,l]=(0,d.useState)(!1),[c,p]=(0,d.useState)("light");return((0,d.useEffect)(()=>
1{l(!0);try{let a=localStorage.getItem("theme");if("dark"===a||"light"===a){p(a),document.documentElement.classList.toggle("dark","dark"===a);return}}catch(a){}let a=window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,c=a?"dark":"light";p(c),document.documentElement.classList.toggle("dark","dark"===c)},[]),a)?(0,u.jsx)("button",{onClick:()=>{let a="dark"===c?"light":"dark";p(a),document.documentElement.classList.toggle("dark","dark"===a);try{localStorage.setItem("theme",a)}catch(a){}},"aria-label":"Toggle dark mode",className:"inline-flex items-center rounded-lg border border-gray-200 dark:border-gray-700 px-2.5 py-1.5 text-sm text-gray-700 dark:text-gray-200 bg-white dark:bg-gray-800 hover:bg-gray-50 dark:hover:bg-gray-700 transition-colors",children:"dark"===c?(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(W,{className:"w-4 h-4 mr-1.5"}),"Light Mode"]}):(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(et,{className:"w-4 h-4 mr-1.5"}),"Dark Mode"]})}):null}function Layout(a){let{children:l}=a,[c,p]=(0,d.useState)(!1);return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(g(),{children:(0,u.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1"})}),(0,u.jsxs)("div",{className:"min-h-screen flex flex-col bg-white dark:bg-gray-900 transition-colors duration-200",children:[(0,u.jsxs)("header",{className:"bg-white dark:bg-gray-900 shadow-sm border-b border-gray-200 dark:border-gray-800 transition-colors duration-200",children:[(0,u.jsx)("div",{className:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8",children:(0,u.jsxs)("div",{className:"flex justify-between items-center h-16",children:[(0,u.jsx)("div",{className:"flex items-center",children:(0,u.jsxs)(w(),{href:"/",className:"flex items-center",children:[(0,u.jsx)(Logo,{}),(0,u.jsx)("span",{className:"ml-2 text-xl font-bold text-gray-900 dark:text-gray-100 transition-colors duration-200",children:"SalaryCalculate"})]})}),(0,u.jsxs)("nav",{className:"space-x-6 text-sm items-center hidden md:flex",children:[(0,u.jsx)(w(),{href:"/tools",className:"text-gray-700 dark:text-gray-300 hover:text-gray-900 dark:hover:text-white transition-colors",children:"Tools"}),(0,u.jsx)(w(),{href:"/blog",className:"text-gray-700 dark:text-gray-300 hover:text-gray-900 dark:hover:text-white transition-colors",children:"Blog"}),(0,u.jsx)(w(),{href:"/about",className:"text-gray-700 dark:text-gray-300 hover:text-gray-900 dark:hover:text-white transition-colors",children:"About"}),(0,u.jsx)(w(),{href:"/contact",className:"text-gray-700 dark:text-gray-300 hover:text-gray-900 dark:hover:text-white transition-colors",children:"Contact"}),(0,u.jsx)(ThemeToggle,{})]}),(0,u.jsx)("button",{type:"button","aria-label":"Toggle navigation menu","aria-expanded":c,onClick:()=>p(a=>!a),className:"md:hidden inline-flex items-center justify-center p-2 rounded-lg text-gray-600 dark:text-gray-300 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus-visible:ring-2 focus-visible:ring-indigo-500",children:c?(0,u.jsx)(x.Z,{className:"h-6 w-6"}):(0,u.jsx)(k,{className:"h-6 w-6"})})]})}),(0,u.jsx)("div",{className:"".concat(c?"block":"hidden"," md:hidden border-t border-gray-200 dark:border-gray-800 bg-white dark:bg-gray-900"),children:(0,u.jsxs)("div",{className:"px-4 py-3 space-y-2",children:[(0,u.jsx)(w(),{href:"/tools",onClick:()=>p(!1),className:"block px-3 py-2 rounded-lg text-gray-800 dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Tools"}),(0,u.jsx)(w(),{href:"/blog",onClick:()=>p(!1),className:"block px-3 py-2 rounded-lg text-gray-800 dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Blog"}),(0,u.jsx)(w(),{href:"/about",onClick:()=>p(!1),className:"block px-3 py-2 rounded-lg text-gray-800 dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-800",children:"About"}),(0,u.jsx)(w(),{href:"/contact",onClick:()=>p(!1),className:"block px-3 py-2 rounded-lg text-gray-800 dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Contact"}),(0,u.jsxs)("div",{className:"pt-2 flex items-center justify-between",children:[(0,u.jsx)("span",{className:"text-sm text-gray-600 dark:text-gray-400",children:"Theme"}),(0,u.jsx)(ThemeToggle,{})]})]})})]}),(0,u.jsx)("main",{className:"flex-grow text-gray-900 dark:text-gray-100 transition-colors duration-200",children:l}),(0,u.jsx)(Footer,{}),(0,u.jsx)(CookieBanner,{})]})]})}let ei=(0,d.createContext)({region:"us",setRegion:()=>{}}),LocationProvider=a=>{let{children:l}=a,[c,p]=(0,d.useState)("us");return(0,d.useEffect)(()=>{let a=localStorage.getItem("region");a&&p(a)}
1,[]),(0,u.jsx)(ei.Provider,{value:{region:c,setRegion:a=>{p(a),localStorage.setItem("region",a)}},children:l})};var er=c(11163);let pageview=a=>{window.gtag&&window.gtag("config","G-7ZFZ4446GW",{page_path:a})};var en="undefined"!=typeof window?window:void 0,eo="undefined"!=typeof globalThis?globalThis:en,ea=Array.prototype,el=ea.forEach,ec=ea.indexOf,eu=null==eo?void 0:eo.navigator,ed=null==eo?void 0:eo.document,eh=null==eo?void 0:eo.location,ep=null==eo?void 0:eo.fetch,eg=null!=eo&&eo.XMLHttpRequest&&"withCredentials"in new eo.XMLHttpRequest?eo.XMLHttpRequest:void 0,ef=null==eo?void 0:eo.AbortController,ev=null==eu?void 0:eu.userAgent,e_=null!=en?en:{},em={DEBUG:!1,LIB_VERSION:"1.257.0"},ey="$copy_autocapture",eb=["$snapshot","$pageview","$pageleave","$set","survey dismissed","survey sent","survey shown","$identify","$groupidentify","$create_alias","$$client_ingestion_warning","$web_experiment_applied","$feature_enrollment_update","$feature_flag_called"],ew=((tk={}).GZipJS="gzip-js",tk.Base64="base64",tk),ex=["fatal","error","warning","log","info","debug"];function m(a,l){return -1!==a.indexOf(l)}var b=function(a){return a.trim()},y=function(a){return a.replace(/^\$/,"")},ek=Array.isArray,eE=Object.prototype,eS=eE.hasOwnProperty,eI=eE.toString,eC=ek||function(a){return"[object Array]"===eI.call(a)},E=a=>"function"==typeof a,I=a=>a===Object(a)&&!eC(a),P=a=>{if(I(a)){for(var l in a)if(eS.call(a,l))return!1;return!0}return!1},R=a=>void 0===a,T=a=>"[object String]"==eI.call(a),M=a=>T(a)&&0===a.trim().length,C=a=>null===a,F=a=>R(a)||C(a),O=a=>"[object Number]"==eI.call(a),A=a=>"[object Boolean]"===eI.call(a),D=a=>a instanceof FormData,L=a=>m(eb,a),j=a=>{var l={t:function(l){if(en&&(em.DEBUG||e_.POSTHOG_DEBUG)&&!R(en.console)&&en.console){for(var c=("__rrweb_original__"in en.console[l])?en.console[l].__rrweb_original__:en.console[l],u=arguments.length,d=Array(u>1?u-1:0),p=1;p<u;p++)d[p-1]=arguments[p];c(a,...d)}},info:function(){for(var a=arguments.length,c=Array(a),u=0;u<a;u++)c[u]=arguments[u];l.t("log",...c)},warn:function(){for(var a=arguments.length,c=Array(a),u=0;u<a;u++)c[u]=arguments[u];l.t("warn",...c)},error:function(){for(var a=arguments.length,c=Array(a),u=0;u<a;u++)c[u]=arguments[u];l.t("error",...c)},critical:function(){for(var l=arguments.length,c=Array(l),u=0;u<l;u++)c[u]=arguments[u];console.error(a,...c)},uninitializedWarning:a=>{l.error("You must initialize PostHog before calling "+a)},createLogger:l=>j(a+" "+l)};return l},eR=j("[PostHog.js]"),eP=eR.createLogger,eF=eP("[ExternalScriptsLoader]"),q=(a,l,c)=>{if(a.config.disable_external_dependency_loading)return eF.warn(l+" was requested but loading of external scripts is disabled."),c("Loading of external scripts is disabled");var u=null==ed?void 0:ed.querySelectorAll("script");if(u){for(var d=0;d<u.length;d++)if(u[d].src===l)return c()}var n=()=>{if(!ed)return c("document not found");var u=ed.createElement("script");if(u.type="text/javascript",u.crossOrigin="anonymous",u.src=l,u.onload=a=>c(void 0,a),u.onerror=a=>c(a),a.config.prepare_external_dependency_script&&(u=a.config.prepare_external_dependency_script(u)),!u)return c("prepare_external_dependency_script returned null");var d,p=ed.querySelectorAll("body > script");p.length>0?null==(d=p[0].parentNode)||d.insertBefore(u,p[0]):ed.body.appendChild(u)};null!=ed&&ed.body?n():null==ed||ed.addEventListener("DOMContentLoaded",n)};function B(){return(B=Object.assign?Object.assign.bind():function(a){for(var l=1;l<arguments.length;l++){var c=arguments[l];for(var u in c)({}).hasOwnProperty.call(c,u)&&(a[u]=c[u])}return a}).apply(null,arguments)}function H(a,l){if(null==a)return{};var c={};for(var u in a)if(({}).hasOwnProperty.call(a,u)){if(-1!==l.indexOf(u))continue;c[u]=a[u]}return c}e_.__PosthogExtensions__=e_.__PosthogExtensions__||{},e_.__PosthogExtensions__.loadExternalDependency=(a,l,c)=>{var u="/static/"+l+".js?v="+a.version;"remote-config"===l&&(u="/array/"+a.config.token+"/config.js"),"toolbar"===l&&(u=u+"&t="+3e5*Math.floor(Date.now()/3e5));var d=a.requestRouter.endpointFor("assets",u);q(a,d,c)},e_.__PosthogExtensions__.loadSiteApp=(a,l,c)=>{var u=a.requestRouter.endpointFor("api",l);q(a,u,c)};var eO={};
vendor: 4,743 bytes, line 1
1function G(a,l,c){if(eC(a)){if(el&&a.forEach===el)a.forEach(l,c);else if("length"in a&&a.length===+a.length){for(var u=0,d=a.length;u<d;u++)if(u in a&&l.call(c,a[u],u)===eO)return}}}function J(a,l,c){if(!F(a)){if(eC(a))return G(a,l,c);if(D(a)){for(var u of a.entries())if(l.call(c,u[1],u[0])===eO)return}else for(var d in a)if(eS.call(a,d)&&l.call(c,a[d],d)===eO)return}}var V=function(a){for(var l=arguments.length,c=Array(l>1?l-1:0),u=1;u<l;u++)c[u-1]=arguments[u];return G(c,function(l){for(var c in l)void 0!==l[c]&&(a[c]=l[c])}),a},K=function(a){for(var l=arguments.length,c=Array(l>1?l-1:0),u=1;u<l;u++)c[u-1]=arguments[u];return G(c,function(l){G(l,function(l){a.push(l)})}),a};function Y(a){for(var l=Object.keys(a),c=l.length,u=Array(c);c--;)u[c]=[l[c],a[l[c]]];return u}var X=function(a){try{return a()}catch(a){return}},Q=function(a){return function(){try{for(var l=arguments.length,c=Array(l),u=0;u<l;u++)c[u]=arguments[u];return a.apply(this,c)}catch(a){eR.critical("Implementation error. Please turn on debug mode and open a ticket on https://app.posthog.com/home#panel=support%3Asupport%3A."),eR.critical(a)}}},Z=function(a){var l={};return J(a,function(a,c){(T(a)&&a.length>0||O(a))&&(l[c]=a)}),l},eT=["herokuapp.com","vercel.app","netlify.app"];function rt(a,l){for(var c=0;c<a.length;c++)if(l(a[c]))return a[c]}function st(a,l,c,u){var{capture:d=!1,passive:p=!0}=null!=u?u:{};null==a||a.addEventListener(l,c,{capture:d,passive:p})}var e$="$people_distinct_id",ej="__alias",eA="__timers",eM="$autocapture_disabled_server_side",eN="$heatmaps_enabled_server_side",eL="$exception_capture_enabled_server_side",eD="$error_tracking_suppression_rules",eB="$web_vitals_enabled_server_side",eH="$dead_clicks_enabled_server_side",eq="$web_vitals_allowed_metrics",ez="$session_recording_enabled_server_side",eU="$console_log_recording_enabled_server_side",eG="$session_recording_network_payload_capture",eV="$session_recording_masking",eW="$session_recording_canvas_recording",eJ="$replay_sample_rate",eY="$replay_minimum_duration",eK="$replay_script_config",eZ="$sesid",eX="$session_is_sampled",eQ="$session_recording_url_trigger_activated_session",e0="$session_recording_event_trigger_activated_session",e1="$enabled_feature_flags",e2="$early_access_features",e3="$feature_flag_details",e4="$stored_person_properties",e5="$stored_group_properties",e6="$surveys",e8="$surveys_activated",e7="$flag_call_reported",e9="$user_state",te="$client_session_props",tt="$capture_rate_limit",tr="$initial_campaign_params",tn="$initial_referrer_info",tl="$initial_person_info",tc="$epp",tu="__POSTHOG_TOOLBAR__",td="$posthog_cookieless",th=[e$,ej,"__cmpns",eA,ez,eN,eZ,e1,eD,e9,e2,e3,e5,e4,e6,e7,te,tt,tr,tn,tc,tl];function Wt(a){return a instanceof Element&&(a.id===tu||!(null==a.closest||!a.closest(".toolbar-global-fade-container")))}function Gt(a){return!!a&&1===a.nodeType}function Jt(a,l){return!!a&&!!a.tagName&&a.tagName.toLowerCase()===l.toLowerCase()}function Vt(a){return!!a&&3===a.nodeType}function Kt(a){return!!a&&11===a.nodeType}function Yt(a){return a?b(a).split(/\s+/):[]}function Xt(a){var l=null==en?void 0:en.location.href;return!!(l&&a&&a.some(a=>l.match(a)))}function Qt(a){var l="";switch(typeof a.className){case"string":l=a.className;break;case"object":l=(a.className&&"baseVal"in a.className?a.className.baseVal:null)||a.getAttribute("class")||"";break;default:l=""}return Yt(l)}function Zt(a){return F(a)?null:b(a).split(/(\s+)/).filter(a=>ci(a)).join("").replace(/[\r\n]/g," ").replace(/[ ]+/g," ").substring(0,255)}function ti(a){var l="";return ni(a)&&!oi(a)&&a.childNodes&&a.childNodes.length&&J(a.childNodes,function(a){var c;Vt(a)&&a.textContent&&(l+=null!==(c=Zt(a.textContent))&&void 0!==c?c:"")}),b(l)}function ii(a){var l;return R(a.target)?a.srcElement||null:null!=(l=a.target)&&l.shadowRoot?a.composedPath()[0]||null:a.target||null}var tp=["a","button","form","input","select","textarea","label"];function ri(a){var l=a.parentNode;return!(!l||!Gt(l))&&l}function ni(a){for(var l=a;l.parentNode&&!Jt(l,"body");l=l.parentNode){var c=Qt(l);if(m(c,"ph-sensitive")||m(c,"ph-no-capture"))return!1}if(m(Qt(a),"ph-include"))return!0;var u=a.type||"";if(T(u))switch(u.toLowerCase()){case"hidden":case"password":return!1}var d=a.name||a.id||"";return!(T(d)&&/^cc|cardnum|ccnum|creditcard|csc|cvc|cvv|exp|pass|pwd|routing|seccode|securitycode|securitynum|socialsec|socsec|ssn/i.test(d.replace(/[^a-zA-Z0-9]/g,"")))}function oi(a){return!!(Jt(a,"input")&&!["button","checkbox","submit","reset"].includes(a.type)||Jt(a,"select")||Jt(a,"textarea")||"true"===a.getAttribute("contenteditable"))}var tg="(4[0-9]{12}(?:[0-9]{3})?)|(5[1-5][0-9]{14})|(6(?:011|5[0-9]{2})[0-9]{12})|(3[47][0-9]{13})|(3(?:0[0-5]|[68][0-9])[0-9]{11}
1)|((?:2131|1800|35[0-9]{3})[0-9]{11})",tf=RegExp("^(?:"+tg+")$"),tv=new RegExp(tg),t_="\\d{3}-?\\d{2}-?\\d{4}",tm=RegExp("^("+t_+")$"),ty=RegExp("("+t_+")");function ci(a,l){return void 0===l&&(l=!0),!(F(a)||T(a)&&(a=b(a),(l?tf:tv).test((a||"").replace(/[- ]/g,""))||(l?tm:ty).test(a)))}function fi(a){var l=ti(a);return ci(l=(l+" "+function pi(a){var l="";return a&&a.childNodes&&a.childNodes.length&&J(a.childNodes,function(a){var c;if(a&&"span"===(null==(c=a.tagName)?void 0:c.toLowerCase()))try{var u=ti(a);l=(l+" "+u).trim(),a.childNodes&&a.childNodes.length&&(l=(l+" "+pi(a)).trim())}catch(a){eR.error("[AutoCapture]",a)}}),l}(a)).trim())?l:""}function _i(a){return a.replace(/"|\\"/g,'\\"')}let bi=class bi{constructor(){this.clicks=[]}isRageClick(a,l,c){var u=this.clicks[this.clicks.length-1];if(u&&Math.abs(a-u.x)+Math.abs(l-u.y)<30&&c-u.timestamp<1e3){if(this.clicks.push({x:a,y:l,timestamp:c}),3===this.clicks.length)return!0}else this.clicks=[{x:a,y:l,timestamp:c}];return!1}};var tb=["localhost","127.0.0.1"],wi=a=>{var l=null==ed?void 0:ed.createElement("a");return R(l)?null:(l.href=a,l)},Si=function(a,l){void 0===l&&(l="&");var c,u,d=[];return J(a,function(a,l){R(a)||R(l)||"undefined"===l||(c=encodeURIComponent(a instanceof File?a.name:a.toString()),u=encodeURIComponent(l),d[d.length]=u+"="+c)}),d.join(l)},$i=function(a,l){for(var c,u=((a.split("#")[0]||"").split(/\?(.*)/)[1]||"").replace(/^\?+/g,"").split("&"),d=0;d<u.length;d++){var p=u[d].split("=");if(p[0]===l){c=p;break}}if(!eC(c)||c.length<2)return"";var g=c[1];try{g=decodeURIComponent(g)}catch(a){eR.error("Skipping decoding for malformed query param: "+g)}return g.replace(/\+/g," ")},ki=function(a,l,c){if(!a||!l||!l.length)return a;for(var u=a.split("#"),d=u[0]||"",p=u[1],g=d.split("?"),f=g[1],v=g[0],_=(f||"").split("&"),w=[],x=0;x<_.length;x++){var k=_[x].split("=");eC(k)&&(l.includes(k[0])?w.push(k[0]+"="+c):w.push(_[x]))}var S=v;return null!=f&&(S+="?"+w.join("&")),null!=p&&(S+="#"+p),S},xi=function(a,l){var c=a.match(RegExp(l+"=([^&]*)"));return c?c[1]:null},tw=eP("[AutoCapture]");function Ii(a,l){return l.length>a?l.slice(0,a)+"...":l}let Mi=class Mi{constructor(a){this.i=!1,this.o=null,this.rageclicks=new bi,this.h=!1,this.instance=a,this.m=null}get S(){var a,l,c=I(this.instance.config.autocapture)?this.instance.config.autocapture:{};return c.url_allowlist=null==(a=c.url_allowlist)?void 0:a.map(a=>new RegExp(a)),c.url_ignorelist=null==(l=c.url_ignorelist)?void 0:l.map(a=>new RegExp(a)),c}$(){if(this.isBrowserSupported()){if(en&&ed){var i=a=>{a=a||(null==en?void 0:en.event);try{this.k(a)}catch(a){tw.error("Failed to capture event",a)}};if(st(ed,"submit",i,{capture:!0}),st(ed,"change",i,{capture:!0}),st(ed,"click",i,{capture:!0}),this.S.capture_copied_text){var e=a=>{a=a||(null==en?void 0:en.event),this.k(a,ey)};st(ed,"copy",e,{capture:!0}),st(ed,"cut",e,{capture:!0})}}}else tw.info("Disabling Automatic Event Collection because this browser is not supported")}startIfEnabled(){this.isEnabled&&!this.i&&(this.$(),this.i=!0)}
1onRemoteConfig(a){a.elementsChainAsString&&(this.h=a.elementsChainAsString),this.instance.persistence&&this.instance.persistence.register({[eM]:!!a.autocapture_opt_out}),this.o=!!a.autocapture_opt_out,this.startIfEnabled()}setElementSelectors(a){this.m=a}getElementSelectors(a){var l,c=[];return null==(l=this.m)||l.forEach(l=>{var u=null==ed?void 0:ed.querySelectorAll(l);null==u||u.forEach(u=>{a===u&&c.push(l)})}),c}get isEnabled(){var a,l,c=null==(a=this.instance.persistence)?void 0:a.props[eM];if(C(this.o)&&!A(c)&&!this.instance.I())return!1;var u=null!==(l=this.o)&&void 0!==l?l:!!c;return!!this.instance.config.autocapture&&!u}k(a,l){if(void 0===l&&(l="$autocapture"),this.isEnabled){var c,u=ii(a);Vt(u)&&(u=u.parentNode||null),"$autocapture"===l&&"click"===a.type&&a instanceof MouseEvent&&this.instance.config.rageclick&&null!=(c=this.rageclicks)&&c.isRageClick(a.clientX,a.clientY,(new Date).getTime())&&this.k(a,"$rageclick");var d=l===ey;if(u&&function(a,l,c,u,d){if(void 0===c&&(c=void 0),!en||!a||Jt(a,"html")||!Gt(a)||null!=(p=c)&&p.url_allowlist&&!Xt(c.url_allowlist)||null!=(g=c)&&g.url_ignorelist&&Xt(c.url_ignorelist))return!1;if(null!=(f=c)&&f.dom_event_allowlist){var p,g,f,v=c.dom_event_allowlist;if(v&&!v.some(a=>l.type===a))return!1}for(var _=!1,w=[a],x=!0,k=a;k.parentNode&&!Jt(k,"body");)if(Kt(k.parentNode))w.push(k.parentNode.host),k=k.parentNode.host;else{if(!(x=ri(k)))break;if(u||tp.indexOf(x.tagName.toLowerCase())>-1)_=!0;else{var S=en.getComputedStyle(x);S&&"pointer"===S.getPropertyValue("cursor")&&(_=!0)}w.push(x),k=x}if(!function(a,l){var c=null==l?void 0:l.element_allowlist;if(R(c))return!0;var u,s=function(a){if(c.some(l=>a.tagName.toLowerCase()===l))return{v:!0}};for(var d of a)if(u=s(d))return u.v;return!1}(w,c)||!function(a,l){var c=null==l?void 0:l.css_selector_allowlist;if(R(c))return!0;var u,s=function(a){if(c.some(l=>a.matches(l)))return{v:!0}};for(var d of a)if(u=s(d))return u.v;return!1}(w,c))return!1;var $=en.getComputedStyle(a);if($&&"pointer"===$.getPropertyValue("cursor")&&"click"===l.type)return!0;var N=a.tagName.toLowerCase();switch(N){case"html":return!1;case"form":return(d||["submit"]).indexOf(l.type)>=0;case"input":case"select":case"textarea":return(d||["change","click"]).indexOf(l.type)>=0;default:return _?(d||["click"]).indexOf(l.type)>=0:(d||["click"]).indexOf(l.type)>=0&&(tp.indexOf(N)>-1||"true"===a.getAttribute("contenteditable"))}}(u,a,this.S,d,d?["copy","cut"]:void 0)){var{props:p,explicitNoCapture:g}=function(a,l){for(var c,u,{e:d,maskAllElementAttributes:p,maskAllText:g,elementAttributeIgnoreList:f,elementsChainAsString:v}=l,_=[a],w=a;w.parentNode&&!Jt(w,"body");)Kt(w.parentNode)?(_.push(w.parentNode.host),w=w.parentNode.host):(_.push(w.parentNode),w=w.parentNode);var x,k=[],S={},$=!1,N=!1;if(J(_,a=>{var l=ni(a);"a"===a.tagName.toLowerCase()&&($=a.getAttribute("href"),$=l&&$&&ci($)&&$),m(Qt(a),"ph-no-capture")&&(N=!0),k.push(function(a,l,c,u){var d=a.tagName.toLowerCase(),p={tag_name:d};tp.indexOf(d)>-1&&!c&&("a"===d.toLowerCase()||"button"===d.toLowerCase()?p.$el_text=Ii(1024,fi(a)):p.$el_text=Ii(1024,ti(a)));var g=Qt(a);g.length>0&&(p.classes=g.filter(function(a){return""!==a})),J(a.attributes,function(c){var d;if((!oi(a)||-1!==["name","id","class","aria-label"].indexOf(c.name))&&(null==u||!u.includes(c.name))&&!l&&ci(c.value)&&(!T(d=c.name)||"_ngcontent"!==d.substring(0,10)&&"_nghost"!==d.substring(0,7))){var g=c.value;"class"===c.name&&(g=Yt(g).join(" ")),p["attr__"+c.name]=Ii(1024,g)}});for(var f=1,v=1,_=a;_=function(a){if(a.previousElementSibling)return a.previousElementSibling;var l=a;do l=l.previousSibling;while(l&&!Gt(l));return l}(_);)f++,_.tagName===a.tagName&&v++;return p.nth_child=f,p.nth_of_type=v,p}(a,p,g,f)),V(S,function(a){if(!ni(a))return{};var l={};return J(a.attributes,function(a){if(a.name&&0===a.name.indexOf("data-ph-capture-attribute")){var c=a.name.replace("data-ph-capture-attribute-",""),u=a.value;c&&u&&ci(u)&&(l[c]=u)}}),l}(a))}),N)return{props:{},explicitNoCapture:N};if(g||("a"===a.tagName.toLowerCase()||"button"===a.tagName.toLowerCase()?k[0].$el_text=fi(a):k[0].$el_text=ti(a)),$){k[0].attr__href=$;var z,U,W=null==(z=wi($))?void 0:z.host,et=null==en||null==(U=en.location)?void 0:U.host;W&&et&&W!==et&&(x=$)}return{props:V({$event_type:d.type,$ce_version:1},v?{}:{$elements:k},{$elements_chain:k.map(a=>{var l,c,u,d={text:null==(c=a.$el_text)?void 0:c.slice(0,400),tag_name:a.tag_name,href:null==(u=a.attr__href)?void 0:u.slice(0,2048),attr_class:(l=a.attr__class)?eC(l)?l:Yt(l):void 0,attr_id:a.attr__id,nth_child:a.nth_child,nth_of_type:a.nth_of_type,attributes:{}};return Y(a).filter(a=>{var[l]=a;return 0===l.indexOf("attr__")}
vendor: 6,234 bytes, line 1
1).forEach(a=>{var[l,c]=a;return d.attributes[l]=c}),d}).map(a=>{var l,c,u="";if(a.tag_name&&(u+=a.tag_name),a.attr_class)for(var d of(a.attr_class.sort(),a.attr_class))u+="."+d.replace(/"/g,"");var p=B({},a.text?{text:a.text}:{},{"nth-child":null!==(l=a.nth_child)&&void 0!==l?l:0,"nth-of-type":null!==(c=a.nth_of_type)&&void 0!==c?c:0},a.href?{href:a.href}:{},a.attr_id?{attr_id:a.attr_id}:{},a.attributes),g={};return Y(p).sort((a,l)=>{var[c]=a,[u]=l;return c.localeCompare(u)}).forEach(a=>{var[l,c]=a;return g[_i(l.toString())]=_i(c.toString())}),u+=":"+Y(g).map(a=>{var[l,c]=a;return l+'="'+c+'"'}).join("")}).join(";")},null!=(c=k[0])&&c.$el_text?{$el_text:null==(u=k[0])?void 0:u.$el_text}:{},x&&"click"===d.type?{$external_click_url:x}:{},S)}}(u,{e:a,maskAllElementAttributes:this.instance.config.mask_all_element_attributes,maskAllText:this.instance.config.mask_all_text,elementAttributeIgnoreList:this.S.element_attribute_ignorelist,elementsChainAsString:this.h});if(g)return!1;var f=this.getElementSelectors(u);if(f&&f.length>0&&(p.$element_selectors=f),l===ey){var v,_=Zt(null==en||null==(v=en.getSelection())?void 0:v.toString()),w=a.type||"clipboard";if(!_)return!1;p.$selected_content=_,p.$copy_type=w}return this.instance.capture(l,p),!0}}}isBrowserSupported(){return E(null==ed?void 0:ed.querySelectorAll)}};Math.trunc||(Math.trunc=function(a){return a<0?Math.ceil(a):Math.floor(a)}),Number.isInteger||(Number.isInteger=function(a){return O(a)&&isFinite(a)&&Math.floor(a)===a});var tx="0123456789abcdef";let Fi=class Fi{constructor(a){if(this.bytes=a,16!==a.length)throw TypeError("not 128-bit length")}static fromFieldsV7(a,l,c,u){if(!Number.isInteger(a)||!Number.isInteger(l)||!Number.isInteger(c)||!Number.isInteger(u)||a<0||l<0||c<0||u<0||a>0xffffffffffff||l>4095||c>1073741823||u>4294967295)throw RangeError("invalid field value");var d=new Uint8Array(16);return d[0]=a/1099511627776,d[1]=a/4294967296,d[2]=a/16777216,d[3]=a/65536,d[4]=a/256,d[5]=a,d[6]=112|l>>>8,d[7]=l,d[8]=128|c>>>24,d[9]=c>>>16,d[10]=c>>>8,d[11]=c,d[12]=u>>>24,d[13]=u>>>16,d[14]=u>>>8,d[15]=u,new Fi(d)}toString(){for(var a="",l=0;l<this.bytes.length;l++)a=a+tx.charAt(this.bytes[l]>>>4)+tx.charAt(15&this.bytes[l]),3!==l&&5!==l&&7!==l&&9!==l||(a+="-");if(36!==a.length)throw Error("Invalid UUIDv7 was generated");return a}clone(){return new Fi(this.bytes.slice(0))}equals(a){return 0===this.compareTo(a)}compareTo(a){for(var l=0;l<16;l++){var c=this.bytes[l]-a.bytes[l];if(0!==c)return Math.sign(c)}return 0}};let Oi=class Oi{constructor(){this.P=0,this.R=0,this.T=new Li}generate(){var a=this.generateOrAbort();if(R(a)){this.P=0;var l=this.generateOrAbort();if(R(l))throw Error("Could not generate UUID after timestamp reset");return l}return a}generateOrAbort(){var a=Date.now();if(a>this.P)this.P=a,this.M();else{if(!(a+1e4>this.P))return;this.R++,this.R>4398046511103&&(this.P++,this.M())}return Fi.fromFieldsV7(this.P,Math.trunc(this.R/1073741824),1073741823&this.R,this.T.nextUint32())}M(){this.R=1024*this.T.nextUint32()+(1023&this.T.nextUint32())}};var tk,tE,Di=a=>{if("undefined"!=typeof UUIDV7_DENY_WEAK_RNG&&UUIDV7_DENY_WEAK_RNG)throw Error("no cryptographically strong RNG available");for(var l=0;l<a.length;l++)a[l]=65536*Math.trunc(65536*Math.random())+Math.trunc(65536*Math.random());return a};en&&!R(en.crypto)&&crypto.getRandomValues&&(Di=a=>crypto.getRandomValues(a));let Li=class Li{constructor(){this.C=new Uint32Array(8),this.F=1/0}nextUint32(){return this.F>=this.C.length&&(Di(this.C),this.F=0),this.C[this.F++]}};var ji=()=>Ni().toString(),Ni=()=>(tE||(tE=new Oi)).generate(),tS="",tI=/[a-z0-9][a-z0-9-]+\.[a-z]{2,}$/i,tC={O:()=>!!ed,A:function(a){eR.error("cookieStore error: "+a)},D:function(a){if(ed){try{for(var l=a+"=",c=ed.cookie.split(";").filter(a=>a.length),u=0;u<c.length;u++){for(var d=c[u];" "==d.charAt(0);)d=d.substring(1,d.length);if(0===d.indexOf(l))return decodeURIComponent(d.substring(l.length,d.length))}}catch(a){}return null}},L:function(a){var l;try{l=JSON.parse(tC.D(a))||{}}catch(a){}return l},j:function(a,l,c,u,d){if(ed)try{var p="",g="",f=function(a,l){if(l){var c=function(a,l){if(void 0===l&&(l=ed),tS)return tS;if(!l||["localhost","127.0.0.1"].includes(a))return"";for(var c=a.split("."),u=Math.min(c.length,8),d="dmn_chk_"+ji();!tS&&u--;){var p=c.slice(u).join("."),g=d+"=1;domain=."+p+";path=/";l.cookie=g+";max-age=3",l.cookie.includes(d)&&(l.cookie=g+";max-age=0",tS=p)}return tS}(a);if(!c){var u,d=(u=a.match(tI))?u[0]:"";d!==c&&eR.info("Warning: cookie subdomain discovery mismatch",d,c),c=d}return c?"; domain=."+c:""}return""}(ed.location.hostname,u);if(c){var v=new Date;v.setTime(v.getTime()+24*c*36e5),p="; expires="+v.toUTCString()}d&&(g="; secure");var _=a+"="+encodeURIComponent(JSON.stringify(l))+p+"; SameSite=Lax; path=/"+f+g;return _.length>3686.4&&eR.warn("cookieStore warning: large cookie, len="+_.length),ed.cookie=_,_}catch(a){return}},N:function(a,l){try{tC.j(a,"",-1,l)}catch(a){return}}},tR=null,tP={O:function(){if(!C(tR))return tR;var a=!0;if(R(en))a=!1;else try{var l="__mplssupport__";tP.j(l,"xyz"),'"xyz"'!==tP.D(l)&&(a=!1),tP.N(l)}catch(l){a=!1}return a||eR.error("localStorage unsupported; falling back to cookie store"),tR=a,a},A:function(a){eR.error("localStorage error: "+a)},D:function(a){try{return null==en?void 0:en.localStorage.getItem(a)}catch(a){tP.A(a)}return null},L:function(a){try{return JSON.parse(tP.D(a))||{}}catch(a){}return null},j:function(a,l){try{null==en||en.localStorage.setItem(a,JSON.stringify(l))}catch(a){tP.A(a)}},N:function(a){try{null==en||en.localStorage.removeItem(a)}catch(a){tP.A(a)}}},tF=["distinct_id",eZ,eX,tc,tl],tO=B({},tP,{L:function(a){try{var l={};try{l=tC.L(a)||{}}catch(a){}var c=V(l,JSON.parse(tP.D(a)||"{}"));return tP.j(a,c),c}catch(a){}return null},j:function(a,l,c,u,d,p){try{tP.j(a,l,void 0,void 0,p);var g={};tF.forEach(a=>{l[a]&&(g[a]=l[a])}),Object.keys(g).length&&tC.j(a,g,c,u,d,p)}catch(a){tP.A(a)}},N:function(a,l){try{null==en||en.localStorage.removeItem(a),tC.N(a,l)}catch(a){tP.A(a)}}}),tT={},t$={O:function(){return!0},A:function(a){eR.error("memoryStorage error: "+a)},D:function(a){return tT[a]||null},L:function(a){return tT[a]||null},j:function(a,l){tT[a]=l},N:function(a){delete tT[a]}}
1,tj=null,tA={O:function(){if(!C(tj))return tj;if(tj=!0,R(en))tj=!1;else try{var a="__support__";tA.j(a,"xyz"),'"xyz"'!==tA.D(a)&&(tj=!1),tA.N(a)}catch(a){tj=!1}return tj},A:function(a){eR.error("sessionStorage error: ",a)},D:function(a){try{return null==en?void 0:en.sessionStorage.getItem(a)}catch(a){tA.A(a)}return null},L:function(a){try{return JSON.parse(tA.D(a))||null}catch(a){}return null},j:function(a,l){try{null==en||en.sessionStorage.setItem(a,JSON.stringify(l))}catch(a){tA.A(a)}},N:function(a){try{null==en||en.sessionStorage.removeItem(a)}catch(a){tA.A(a)}}},tM=((tB={})[tB.PENDING=-1]="PENDING",tB[tB.DENIED=0]="DENIED",tB[tB.GRANTED=1]="GRANTED",tB);let Zi=class Zi{constructor(a){this._instance=a}get S(){return this._instance.config}get consent(){return this.U()?tM.DENIED:this.q}isOptedOut(){return this.consent===tM.DENIED||this.consent===tM.PENDING&&this.S.opt_out_capturing_by_default}isOptedIn(){return!this.isOptedOut()}optInOut(a){this.B.j(this.H,a?1:0,this.S.cookie_expiration,this.S.cross_subdomain_cookie,this.S.secure_cookie)}reset(){this.B.N(this.H,this.S.cross_subdomain_cookie)}get H(){var{token:a,opt_out_capturing_cookie_prefix:l}=this._instance.config;return(l||"__ph_opt_in_out_")+a}get q(){var a=this.B.D(this.H);return"1"===a?tM.GRANTED:"0"===a?tM.DENIED:tM.PENDING}get B(){if(!this.W){var a=this.S.opt_out_capturing_persistence_type;this.W="localStorage"===a?tP:tC;var l="localStorage"===a?tC:tP;l.D(this.H)&&(this.W.D(this.H)||this.optInOut("1"===l.D(this.H)),l.N(this.H,this.S.cross_subdomain_cookie))}return this.W}U(){return!!this.S.respect_dnt&&!!rt([null==eu?void 0:eu.doNotTrack,null==eu?void 0:eu.msDoNotTrack,e_.doNotTrack],a=>m([!0,1,"1","yes"],a))}};var tN=eP("[Dead Clicks]"),ie=()=>!0,ee=a=>{var l,c=!(null==(l=a.instance.persistence)||!l.get_property(eH)),u=a.instance.config.capture_dead_clicks;return A(u)?u:c};let re=class re{get lazyLoadedDeadClicksAutocapture(){return this.G}constructor(a,l,c){this.instance=a,this.isEnabled=l,this.onCapture=c,this.startIfEnabled()}onRemoteConfig(a){this.instance.persistence&&this.instance.persistence.register({[eH]:null==a?void 0:a.captureDeadClicks}),this.startIfEnabled()}startIfEnabled(){this.isEnabled(this)&&this.J(()=>{this.V()})}J(a){var l,c;null!=(l=e_.__PosthogExtensions__)&&l.initDeadClicksAutocapture&&a(),null==(c=e_.__PosthogExtensions__)||null==c.loadExternalDependency||c.loadExternalDependency(this.instance,"dead-clicks-autocapture",l=>{l?tN.error("failed to load script",l):a()})}V(){var a;if(ed){if(!this.G&&null!=(a=e_.__PosthogExtensions__)&&a.initDeadClicksAutocapture){var l=I(this.instance.config.capture_dead_clicks)?this.instance.config.capture_dead_clicks:{};l.__onCapture=this.onCapture,this.G=e_.__PosthogExtensions__.initDeadClicksAutocapture(this.instance,l),this.G.start(ed),tN.info("starting...")}}else tN.error("`document` not found. Cannot start.")}stop(){this.G&&(this.G.stop(),this.G=void 0,tN.info("stopping..."))}};function se(a,l,c,u,d){return l>c&&(eR.warn("min cannot be greater than max."),l=c),O(a)?a>c?(u&&eR.warn(u+" cannot be greater than max: "+c+". Using max value instead."),c):a<l?(u&&eR.warn(u+" cannot be less than min: "+l+". Using min value instead."),l):a:(u&&eR.warn(u+" must be a number. using max or fallback. max: "+c+", fallback: "+d),se(d||c,l,c,u))}let ne=class ne{constructor(a){this.K={},this.Y=()=>{Object.keys(this.K).forEach(a=>{var l=this.X(a)+this.Z;l>=this.tt?delete this.K[a]:this.it(a,l)})},this.X=a=>this.K[String(a)],this.it=(a,l)=>{this.K[String(a)]=l},this.consumeRateLimit=a=>{var l,c=null!==(l=this.X(a))&&void 0!==l?l:this.tt;if(0===(c=Math.max(c-1,0)))return!0;this.it(a,c);var u,d=0===c;return d&&(null==(u=this.et)||u.call(this,a)),d},this.rt=a,this.et=this.rt.et,this.tt=se(this.rt.bucketSize,0,100,"rate limiter bucket size"),this.Z=se(this.rt.refillRate,0,this.tt,"rate limiter refill rate"),this.st=se(this.rt.refillInterval,0,864e5,"rate limiter refill interval"),setInterval(()=>{this.Y()},this.st)}};var tL=eP("[ExceptionAutocapture]");let ae=class ae{constructor(a){var l,c,u;this.nt=()=>{var a;if(en&&this.isEnabled&&null!=(a=e_.__PosthogExtensions__)&&a.errorWrappingFunctions){var l=e_.__PosthogExtensions__.errorWrappingFunctions.wrapOnError,c=e_.__PosthogExtensions__.errorWrappingFunctions.wrapUnhandledRejection,u=e_.__PosthogExtensions__.errorWrappingFunctions.wrapConsoleError;try{!this.ot&&this.S.capture_unhandled_errors&&(this.ot=l(this.captureException.bind(this))),!this.lt&&this.S.capture_unhandled_rejections&&(this.lt=c(this.captureException.bind(this))),!this.ut&&this.S.capture_console_errors&&(this.ut=u(this.captureException.bind(this)))}catch(a){tL.error("failed to start",a),this.ht()}}},this._instance=a,this.dt=!(null==(l=this._instance.persistence)||!l.props[eL]),this.S=this.vt(),this.ct=new ne({refillRate:null!==(c=this._instance.config.error_tracking.__exceptionRateLimiterRefillRate)&&void 0!==c?c:1,bucketSize:null!==(u=this._instance.config.error_tracking.__exceptionRateLimiterBucketSize)&&void 0!==u?u:10,refillInterval:1e4}),this.startIfEnabled()}vt(){var a=this._instance.config.capture_exceptions,l={capture_unhandled_errors:!1,capture_unhandled_rejections:!1,capture_console_errors:!1};return I(a)?l=B({},l,a):(R(a)?this.dt:a)&&(l=B({},l,{capture_unhandled_errors:!0,capture_unhandled_rejections:!0})),l}get isEnabled(){return this.S.capture_console_errors||this.S.capture_unhandled_errors||this.S.capture_unhandled_rejections}startIfEnabled(){this.isEnabled&&(tL.info("enabled"),this.J(this.nt))}J(a){var l,c;null!=(l=e_.__PosthogExtensions__)&&l.errorWrappingFunctions&&a(),null==(c=e_.__PosthogExtensions__)||null==c.loadExternalDependency||c.loadExternalDependency(this._instance,"exception-autocapture",l=>
1{if(l)return tL.error("failed to load script",l);a()})}ht(){var a,l,c;null==(a=this.ot)||a.call(this),this.ot=void 0,null==(l=this.lt)||l.call(this),this.lt=void 0,null==(c=this.ut)||c.call(this),this.ut=void 0}onRemoteConfig(a){var l=a.autocaptureExceptions;this.dt=!!l,this.S=this.vt(),this._instance.persistence&&this._instance.persistence.register({[eL]:this.dt}),this.startIfEnabled()}captureException(a){var l,c=this._instance.requestRouter.endpointFor("ui");a.$exception_personURL=c+"/project/"+this._instance.config.token+"/person/"+this._instance.get_distinct_id();var u=null!==(l=a.$exception_list[0].type)&&void 0!==l?l:"Exception";this.ct.consumeRateLimit(u)?tL.info("Skipping exception capture because of client rate limiting.",{exception:a.$exception_list[0].type}):this._instance.exceptions.sendExceptionEvent(a)}};function le(a){return!R(Event)&&ue(a,Event)}function ue(a,l){try{return a instanceof l}catch(a){return!1}}function he(a){switch(Object.prototype.toString.call(a)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object DOMError]":return!0;default:return ue(a,Error)}}function de(a,l){return Object.prototype.toString.call(a)==="[object "+l+"]"}function ve(a){return de(a,"DOMError")}var tD=/\(error: (.*)\)/;function ge(a,l,c,u){var d={platform:"web:javascript",filename:a,function:"<anonymous>"===l?"?":l,in_app:!0};return R(c)||(d.lineno=c),R(u)||(d.colno=u),d}var tB,tH,tq,tz,tU=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,tG=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,tV=/\((\S*)(?::(\d+))(?::(\d+))\)/,tW=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,tJ=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,tY=function(){for(var a=arguments.length,l=Array(a),c=0;c<a;c++)l[c]=arguments[c];var u=l.sort((a,l)=>a[0]-l[0]).map(a=>a[1]);return function(a,l){void 0===l&&(l=0);for(var c=[],d=a.split("\n"),p=l;p<d.length;p++){var g=d[p];if(!(g.length>1024)){var f=tD.test(g)?g.replace(tD,"$1"):g;if(!f.match(/\S*Error: /)){for(var v of u){var _=v(f);if(_){c.push(_);break}}if(c.length>=50)break}}}return function(a){if(!a.length)return[];var l=Array.from(a);return l.reverse(),l.slice(0,50).map(a=>B({},a,{filename:a.filename||(l[l.length-1]||{}).filename,function:a.function||"?"}))}(c)}}(...[[30,a=>{var l=tU.exec(a);if(l){var[,c,u,d]=l;return ge(c,"?",+u,+d)}var p=tG.exec(a);if(p){if(p[2]&&0===p[2].indexOf("eval")){var g=tV.exec(p[2]);g&&(p[2]=g[1],p[3]=g[2],p[4]=g[3])}var[f,v]=Ie(p[1]||"?",p[2]);return ge(v,f,p[3]?+p[3]:void 0,p[4]?+p[4]:void 0)}}],[50,a=>{var l=tW.exec(a);if(l){if(l[3]&&l[3].indexOf(" > eval")>-1){var c=tJ.exec(l[3]);c&&(l[1]=l[1]||"eval",l[3]=c[1],l[4]=c[2],l[5]="")}var u=l[3],d=l[1]||"?";return[d,u]=Ie(d,u),ge(u,d,l[4]?+l[4]:void 0,l[5]?+l[5]:void 0)}}]]),Ie=(a,l)=>{var c=-1!==a.indexOf("safari-extension"),u=-1!==a.indexOf("safari-web-extension");return c||u?[-1!==a.indexOf("@")?a.split("@")[0]:"?",c?"safari-extension:"+l:"safari-web-extension:"+l]:[a,l]},tK=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;function Re(a,l){void 0===l&&(l=0);var c=a.stacktrace||a.stack||"",u=a&&tZ.test(a.message)?1:0;try{var d,p,g=(d=tY(c,u),p=function(a){var l=globalThis._posthogChunkIds;if(!l)return{};var c=Object.keys(l);return tz&&c.length===tq||(tq=c.length,tz=c.reduce((c,u)=>{tH||(tH={});var d=tH[u];if(d)c[d[0]]=d[1];else for(var p=a(u),g=p.length-1;g>=0;g--){var f=p[g],v=null==f?void 0:f.filename,_=l[u];if(v&&_){c[v]=_,tH[u]=[v,_];break}}return c},{})),tz}(tY),d.forEach(a=>{a.filename&&(a.chunk_id=p[a.filename])}),d);return g.slice(0,g.length-l)}catch(a){}return[]}var tZ=/Minified React error #\d+;/i;function Fe(a,l){return{$exception_list:function Ce(a,l){var c,u,d,p,g,f,v=(p=Re(a),g=null===(u=null==l?void 0:l.handled)||void 0===u||u,f=null!==(d=null==l?void 0:l.synthetic)&&void 0!==d&&d,{type:null!=l&&l.overrideExceptionType?l.overrideExceptionType:a.name,value:(c=a.message).error&&"string"==typeof c.error.message?String(c.error.message):String(c),stacktrace:{frames:p,type:"raw"},mechanism:{handled:g,synthetic:f}});return a.cause&&he(a.cause)&&a.cause!==a?[v,...Ce(a.cause,{handled:null==l?void 0:l.handled,synthetic:null==l?void 0:l.synthetic})]:[v]}(a,l),$exception_level:"error"}}function Oe(a,l){var c,u,d,p=null===(c=null==l?void 0:l.handled)||void 0===c||c,g=null===(u=null==l?void 0:l.synthetic)||void 0===u||u,f={type:null!=l&&l.overrideExceptionType?l.overrideExceptionType:null!==(d=null==l?void 0:l.defaultExceptionType)&&void 0!==d?d:"Error",value:a||(null==l?void 0:l.defaultExceptionMessage),mechanism:{handled:p,synthetic:g}};if(null!=l&&l.syntheticException){var v=Re(l.syntheticException,1);v.length&&(f.stacktrace={frames:v,type:"raw"})}return{$exception_list:[f],$exception_level:"error"}}function je(a,l,c){try{if(!(l in a))return()=>{};var u=a[l],d=c(u);return E(d)&&(d.prototype=d.prototype||{},Object.defineProperties(d,{__posthog_wrapped__:{enumerable:!1,value:!0}})),a[l]=d,()=>{a[l]=u}}catch(a){return()=>{}}}let Ne=class Ne{constructor(a){var l;this._instance=a,this.ft=(null==en||null==(l=en.location)?void 0:l.pathname)||""}get isEnabled(){return"history_change"===this._instance.config.capture_pageview}startIfEnabled(){this.isEnabled&&(eR.info("History API monitoring enabled, starting..."),this.monitorHistoryChanges())}stop(){this.gt&&this.gt(),this.gt=void 0,eR.info("History API monitoring stopped")}monitorHistoryChanges(){var a,l;if(en&&en.history){var c=this;null!=(a=en.history.pushState)&&a.__posthog_wrapped__||je(en.history,"pushState",a=>function(l,u,d){a.call(this,l,u,d),c._t("pushState")}),null!=(l=en.history.replaceState)&&l.__posthog_wrapped__||je(en.history,"replaceState",a=>function(l,u,d){a.call(this,l,u,d),c._t("replaceState")}),this.bt()}}_t(a){try{var l,c=null==en||null==(l=en.location)?void 0:l.pathname;if(!c)return;c!==this.ft&&this.isEnabled&&this._instance.capture("$pageview",{navigation_type:a}),this.ft=c}catch(l){eR.error("Error capturing "+a+" pageview",l)}}
1bt(){if(!this.gt){var i=()=>{this._t("popstate")};st(en,"popstate",i),this.gt=()=>{en&&en.removeEventListener("popstate",i)}}}};function ze(a){var l,c;return(null==(l=JSON.stringify(a,(c=[],function(a,l){if(I(l)){for(;c.length>0&&c[c.length-1]!==this;)c.pop();return c.includes(l)?"[Circular]":(c.push(l),l)}return l})))?void 0:l.length)||0}var tX=((si=tX||{})[si.DomContentLoaded=0]="DomContentLoaded",si[si.Load=1]="Load",si[si.FullSnapshot=2]="FullSnapshot",si[si.IncrementalSnapshot=3]="IncrementalSnapshot",si[si.Meta=4]="Meta",si[si.Custom=5]="Custom",si[si.Plugin=6]="Plugin",si),tQ=((sr=tQ||{})[sr.Mutation=0]="Mutation",sr[sr.MouseMove=1]="MouseMove",sr[sr.MouseInteraction=2]="MouseInteraction",sr[sr.Scroll=3]="Scroll",sr[sr.ViewportResize=4]="ViewportResize",sr[sr.Input=5]="Input",sr[sr.TouchMove=6]="TouchMove",sr[sr.MediaInteraction=7]="MediaInteraction",sr[sr.StyleSheetRule=8]="StyleSheetRule",sr[sr.CanvasMutation=9]="CanvasMutation",sr[sr.Font=10]="Font",sr[sr.Log=11]="Log",sr[sr.Drag=12]="Drag",sr[sr.StyleDeclaration=13]="StyleDeclaration",sr[sr.Selection=14]="Selection",sr[sr.AdoptedStyleSheet=15]="AdoptedStyleSheet",sr[sr.CustomElement=16]="CustomElement",sr),t0="[SessionRecording]",t1="redacted",t2={initiatorTypes:["audio","beacon","body","css","early-hint","embed","fetch","frame","iframe","icon","image","img","input","link","navigation","object","ping","script","track","video","xmlhttprequest"],maskRequestFn:a=>a,recordHeaders:!1,recordBody:!1,recordInitialRequests:!1,recordPerformance:!1,performanceEntryTypeToObserve:["first-input","navigation","paint","resource"],payloadSizeLimitBytes:1e6,payloadHostDenyList:[".lr-ingest.io",".ingest.sentry.io",".clarity.ms","analytics.google.com","bam.nr-data.net"]},t3=["authorization","x-forwarded-for","authorization","cookie","set-cookie","x-api-key","x-real-ip","remote-addr","forwarded","proxy-authorization","x-csrf-token","x-csrftoken","x-xsrf-token"],t4=["password","secret","passwd","api_key","apikey","auth","credentials","mysql_pwd","privatekey","private_key","token"],t5=["/s/","/e/","/i/"];function Ye(a,l,c,u){if(F(a))return a;var d=(null==l?void 0:l["content-length"])||new Blob([a]).size;return T(d)&&(d=parseInt(d)),d>c?t0+" "+u+" body too large to record ("+d+" bytes)":a}function Xe(a,l){if(F(a))return a;var c=a;return ci(c,!1)||(c=t0+" "+l+" body "+t1),J(t4,a=>{var u,d;null!=(u=c)&&u.length&&-1!==(null==(d=c)?void 0:d.indexOf(a))&&(c=t0+" "+l+" body "+t1+" as might contain: "+a)}),c}var Qe=(a,l)=>{var c,u,d={payloadSizeLimitBytes:t2.payloadSizeLimitBytes,performanceEntryTypeToObserve:[...t2.performanceEntryTypeToObserve],payloadHostDenyList:[...l.payloadHostDenyList||[],...t2.payloadHostDenyList]},p=!1!==a.session_recording.recordHeaders&&l.recordHeaders,g=!1!==a.session_recording.recordBody&&l.recordBody,f=!1!==a.capture_performance&&l.recordPerformance,v=(u=Math.min(1e6,null!==(c=d.payloadSizeLimitBytes)&&void 0!==c?c:1e6),a=>(null!=a&&a.requestBody&&(a.requestBody=Ye(a.requestBody,a.requestHeaders,u,"Request")),null!=a&&a.responseBody&&(a.responseBody=Ye(a.responseBody,a.responseHeaders,u,"Response")),a)),h=l=>{var c;return v(((a,l)=>{var c,u=wi(a.name),d=0===l.indexOf("http")?null==(c=wi(l))?void 0:c.pathname:l;"/"===d&&(d="");var p=null==u?void 0:u.pathname.replace(d||"","");if(!(u&&p&&t5.some(a=>0===p.indexOf(a))))return a})((F(c=l.requestHeaders)||J(Object.keys(null!=c?c:{}),a=>{t3.includes(a.toLowerCase())&&(c[a]=t1)}),l),a.api_host))},_=E(a.session_recording.maskNetworkRequestFn);return _&&E(a.session_recording.maskCapturedNetworkRequestFn)&&eR.warn("Both `maskNetworkRequestFn` and `maskCapturedNetworkRequestFn` are defined. `maskNetworkRequestFn` will be ignored."),_&&(a.session_recording.maskCapturedNetworkRequestFn=l=>{var c=a.session_recording.maskNetworkRequestFn({url:l.name});return B({},l,{name:null==c?void 0:c.url})}),d.maskRequestFn=E(a.session_recording.maskCapturedNetworkRequestFn)?l=>{var c,u=h(l);return u&&null!==(c=null==a.session_recording.maskCapturedNetworkRequestFn?void 0:a.session_recording.maskCapturedNetworkRequestFn(u))&&void 0!==c?c:void 0}:a=>
1(function(a){if(!R(a))return a.requestBody=Xe(a.requestBody,"Request"),a.responseBody=Xe(a.responseBody,"Response"),a})(h(a)),B({},t2,d,{recordHeaders:p,recordBody:g,recordPerformance:f,recordInitialRequests:f})};let Ze=class Ze{constructor(a,l){var c,u;void 0===l&&(l={}),this.yt={},this.wt=a=>{if(!this.yt[a]){this.yt[a]=!0;var l,c,u=this.St(a);null==(l=(c=this.rt).onBlockedNode)||l.call(c,a,u)}},this.$t=a=>{var l=this.St(a);if("svg"!==(null==l?void 0:l.nodeName)&&l instanceof Element){var c=l.closest("svg");if(c)return[this._rrweb.mirror.getId(c),c]}return[a,l]},this.St=a=>this._rrweb.mirror.getNode(a),this.kt=a=>{var l,c,u,d,p,g,f,v;return(null!==(l=null==(c=a.removes)?void 0:c.length)&&void 0!==l?l:0)+(null!==(u=null==(d=a.attributes)?void 0:d.length)&&void 0!==u?u:0)+(null!==(p=null==(g=a.texts)?void 0:g.length)&&void 0!==p?p:0)+(null!==(f=null==(v=a.adds)?void 0:v.length)&&void 0!==f?f:0)},this.throttleMutations=a=>{if(3!==a.type||0!==a.data.source)return a;var l=a.data,c=this.kt(l);l.attributes&&(l.attributes=l.attributes.filter(a=>{var[l]=this.$t(a.id);return!this.ct.consumeRateLimit(l)&&a}));var u=this.kt(l);return 0!==u||c===u?a:void 0},this._rrweb=a,this.rt=l,this.ct=new ne({bucketSize:null!==(c=this.rt.bucketSize)&&void 0!==c?c:100,refillRate:null!==(u=this.rt.refillRate)&&void 0!==u?u:10,refillInterval:1e3,et:this.wt})}};var t6=Uint8Array,t8=Uint16Array,t7=Uint32Array,t9=new t6([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),it=new t6([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),ir=new t6([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),or=function(a,l){for(var c=new t8(31),u=0;u<31;++u)c[u]=l+=1<<a[u-1];var d=new t7(c[30]);for(u=1;u<30;++u)for(var p=c[u];p<c[u+1];++p)d[p]=p-c[u]<<5|u;return[c,d]},io=or(t9,2),ia=io[0],il=io[1];ia[28]=258,il[258]=28;for(var ic=or(it,0)[1],iu=new t8(32768),id=0;id<32768;++id){var ih=(43690&id)>>>1|(21845&id)<<1;ih=(61680&(ih=(52428&ih)>>>2|(13107&ih)<<2))>>>4|(3855&ih)<<4,iu[id]=((65280&ih)>>>8|(255&ih)<<8)>>>1}var fr=function(a,l,c){for(var u=a.length,d=0,p=new t8(l);d<u;++d)++p[a[d]-1];var g,f=new t8(l);for(d=0;d<l;++d)f[d]=f[d-1]+p[d-1]<<1;if(c){g=new t8(1<<l);var v=15-l;for(d=0;d<u;++d)if(a[d])for(var _=d<<4|a[d],w=l-a[d],x=f[a[d]-1]++<<w,k=x|(1<<w)-1;x<=k;++x)g[iu[x]>>>v]=_}else for(g=new t8(u),d=0;d<u;++d)g[d]=iu[f[a[d]-1]++]>>>15-a[d];return g},ip=new t6(288);for(id=0;id<144;++id)ip[id]=8;for(id=144;id<256;++id)ip[id]=9;for(id=256;id<280;++id)ip[id]=7;for(id=280;id<288;++id)ip[id]=8;var ig=new t6(32);for(id=0;id<32;++id)ig[id]=5;var iv=fr(ip,9,0),i_=fr(ig,5,0),br=function(a){return(a/8>>0)+(7&a&&1)},yr=function(a,l,c){(null==c||c>a.length)&&(c=a.length);var u=new(a instanceof t8?t8:a instanceof t7?t7:t6)(c-l);return u.set(a.subarray(l,c)),u},wr=function(a,l,c){c<<=7&l;var u=l/8>>0;a[u]|=c,a[u+1]|=c>>>8},Sr=function(a,l,c){c<<=7&l;var u=l/8>>0;a[u]|=c,a[u+1]|=c>>>8,a[u+2]|=c>>>16},$r=function(a,l){for(var c=[],u=0;u<a.length;++u)a[u]&&c.push({s:u,f:a[u]});var d=c.length,p=c.slice();if(!d)return[new t6(0),0];if(1==d){var g=new t6(c[0].s+1);return g[c[0].s]=1,[g,1]}c.sort(function(a,l){return a.f-l.f}),c.push({s:-1,f:25001});var f=c[0],v=c[1],_=0,w=1,x=2;for(c[0]={s:-1,f:f.f+v.f,l:f,r:v};w!=d-1;)f=c[c[_].f<c[x].f?_++:x++],v=c[_!=w&&c[_].f<c[x].f?_++:x++],c[w++]={s:-1,f:f.f+v.f,l:f,r:v};var k=p[0].s;for(u=1;u<d;++u)p[u].s>k&&(k=p[u].s);var S=new t8(k+1),$=kr(c[w-1],S,0);if($>l){u=0;var N=0,z=$-l,U=1<<z;for(p.sort(function(a,l){return S[l.s]-S[a.s]||a.f-l.f});u<d;++u){var W=p[u].s;if(!(S[W]>l))break;N+=U-(1<<$-S[W]),S[W]=l}for(N>>>=z;N>0;){var et=p[u].s;S[et]<l?N-=1<<l-S[et]++-1:++u}for(;u>=0&&N;--u){var ei=p[u].s;S[ei]==l&&(--S[ei],++N)}$=l}return[new t6(S),$]},kr=function(a,l,c){return -1==a.s?Math.max(kr(a.l,l,c+1),kr(a.r,l,c+1)):l[a.s]=c},xr=function(a){for(var l=a.length;l&&!a[--l];);for(var c=new t8(++l),u=0,d=a[0],p=1,o=function(a){c[u++]=a},g=1;g<=l;++g)if(a[g]==d&&g!=l)++p;else{if(!d&&p>2){for(;p>138;p-=138)o(32754);p>2&&(o(p>10?p-11<<5|28690:p-3<<5|12305),p=0)}else if(p>3){for(o(d),--p;p>6;p-=6)o(8304);p>2&&(o(p-3<<5|8208),p=0)}for(;p--;)o(d);p=1,d=a[g]}return[c.subarray(0,u),l]},Er=function(a,l){for(var c=0,u=0;u<l.length;++u)c+=a[u]*l[u];return c},Ir=function(a,l,c){var u=c.length,d=br(l+2);a[d]=255&u,a[d+1]=u>>>8,a[d+2]=255^a[d],a[d+3]=255^a[d+1];for(var p=0;p<u;++p)a[d+p+4]=c[p];return 8*(d+4+u)}
1,Pr=function(a,l,c,u,d,p,g,f,v,_,w){wr(l,w++,c),++d[256];for(var x=$r(d,15),k=x[0],S=x[1],$=$r(p,15),N=$[0],z=$[1],U=xr(k),W=U[0],et=U[1],ei=xr(N),er=ei[0],en=ei[1],eo=new t8(19),ea=0;ea<W.length;++ea)eo[31&W[ea]]++;for(ea=0;ea<er.length;++ea)eo[31&er[ea]]++;for(var el=$r(eo,7),ec=el[0],eu=el[1],ed=19;ed>4&&!ec[ir[ed-1]];--ed);var eh,ep,eg,ef,ev=_+5<<3,e_=Er(d,ip)+Er(p,ig)+g,em=Er(d,k)+Er(p,N)+g+14+3*ed+Er(eo,ec)+(2*eo[16]+3*eo[17]+7*eo[18]);if(ev<=e_&&ev<=em)return Ir(l,w,a.subarray(v,v+_));if(wr(l,w,1+(em<e_)),w+=2,em<e_){eh=fr(k,S,0),ep=k,eg=fr(N,z,0),ef=N;var ey=fr(ec,eu,0);for(wr(l,w,et-257),wr(l,w+5,en-1),wr(l,w+10,ed-4),w+=14,ea=0;ea<ed;++ea)wr(l,w+3*ea,ec[ir[ea]]);w+=3*ed;for(var eb=[W,er],ew=0;ew<2;++ew){var ex=eb[ew];for(ea=0;ea<ex.length;++ea){var ek=31&ex[ea];wr(l,w,ey[ek]),w+=ec[ek],ek>15&&(wr(l,w,ex[ea]>>>5&127),w+=ex[ea]>>>12)}}}else eh=iv,ep=ip,eg=i_,ef=ig;for(ea=0;ea<f;++ea)if(u[ea]>255){Sr(l,w,eh[(ek=u[ea]>>>18&31)+257]),w+=ep[ek+257],ek>7&&(wr(l,w,u[ea]>>>23&31),w+=t9[ek]);var eE=31&u[ea];Sr(l,w,eg[eE]),w+=ef[eE],eE>3&&(Sr(l,w,u[ea]>>>5&8191),w+=it[eE])}else Sr(l,w,eh[u[ea]]),w+=ep[u[ea]];return Sr(l,w,eh[256]),w+ep[256]},im=new t7([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),iy=function(){for(var a=new t7(256),l=0;l<256;++l){for(var c=l,u=9;--u;)c=(1&c&&3988292384)^c>>>1;a[l]=c}return a}(),Mr=function(){var a=4294967295;return{p:function(l){for(var c=a,u=0;u<l.length;++u)c=iy[255&c^l[u]]^c>>>8;a=c},d:function(){return 4294967295^a}}},Fr=function(a,l,c){for(;c;++l)a[l]=c,c>>>=8},Or=function(a,l){var c=l.filename;if(a[0]=31,a[1]=139,a[2]=8,a[8]=l.level<2?4:9==l.level?2:0,a[9]=3,0!=l.mtime&&Fr(a,4,Math.floor(new Date(l.mtime||Date.now())/1e3)),c){a[3]=8;for(var u=0;u<=c.length;++u)a[u+10]=c.charCodeAt(u)}};function Dr(a,l){void 0===l&&(l={});var c,u,d,p=Mr(),g=a.length;p.p(a);var f=(u=l,d=10+((c=l).filename&&c.filename.length+1||0),function(a,l,c,u,d,p){var g=a.length,f=new t6(u+g+5*(1+Math.floor(g/7e3))+d),v=f.subarray(u,f.length-d),_=0;if(!l||g<8)for(var w=0;w<=g;w+=65535){var x=w+65535;x<g?_=Ir(v,_,a.subarray(w,x)):(v[w]=p,_=Ir(v,_,a.subarray(w,g)))}else{for(var k=im[l-1],S=k>>>13,$=8191&k,N=(1<<c)-1,z=new t8(32768),U=new t8(N+1),W=Math.ceil(c/3),et=2*W,y=function(l){return(a[l]^a[l+1]<<W^a[l+2]<<et)&N},ei=new t7(25e3),er=new t8(288),en=new t8(32),eo=0,ea=0,el=(w=0,0),ec=0,eu=0;w<g;++w){var ed=y(w),eh=32767&w,ep=U[ed];if(z[eh]=ep,U[ed]=eh,ec<=w){var eg=g-w;if((eo>7e3||el>24576)&&eg>423){_=Pr(a,v,0,ei,er,en,ea,el,eu,w-eu,_),el=eo=ea=0,eu=w;for(var ef=0;ef<286;++ef)er[ef]=0;for(ef=0;ef<30;++ef)en[ef]=0}var ev=2,e_=0,em=$,ey=eh-ep&32767;if(eg>2&&ed==y(w-ey))for(var eb=Math.min(S,eg)-1,ew=Math.min(32767,w),ex=Math.min(258,eg);ey<=ew&&--em&&eh!=ep;){if(a[w+ev]==a[w+ev-ey]){for(var ek=0;ek<ex&&a[w+ek]==a[w+ek-ey];++ek);if(ek>ev){if(ev=ek,e_=ey,ek>eb)break;var eE=Math.min(ey,ek-2),eS=0;for(ef=0;ef<eE;++ef){var eI=w-ey+ef+32768&32767,eC=eI-z[eI]+32768&32767;eC>eS&&(eS=eC,ep=eI)}}}ey+=(eh=ep)-(ep=z[eh])+32768&32767}if(e_){ei[el++]=268435456|il[ev]<<18|ic[e_];var eR=31&il[ev],eP=31&ic[e_];ea+=t9[eR]+it[eP],++er[257+eR],++en[eP],ec=w+ev,++eo}else ei[el++]=a[w],++er[a[w]]}}_=Pr(a,v,p,ei,er,en,ea,el,eu,w-eu,_)}return yr(f,0,u+br(_)+d)}(a,null==u.level?6:u.level,null==u.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(a.length)))):12+u.mem,d,8,!0)),v=f.length;return Or(f,l),Fr(f,v-8,p.d()),Fr(f,v-4,g),f}function Lr(a,l){var c=a.length;if("undefined"!=typeof TextEncoder)return(new TextEncoder).encode(a);for(var u=new t6(a.length+(a.length>>>1)),d=0,n=function(a){u[d++]=a},p=0;p<c;++p){if(d+5>u.length){var g=new t6(d+8+(c-p<<1));g.set(u),u=g}var f=a.charCodeAt(p);f<128||l?n(f):(f<2048?n(192|f>>>6):(f>55295&&f<57344?(n(240|(f=65536+(1047552&f)|1023&a.charCodeAt(++p))>>>18),n(128|f>>>12&63)):n(224|f>>>12),n(128|f>>>6&63)),n(128|63&f))}return yr(u,0,d)}var ib="disabled",iw="sampled",ix="active",ik="buffering",iE="paused",iS="trigger",iI=iS+"_activated",iC=iS+"_pending",iR=iS+"_"+ib;function Vr(a,l){return l.some(l=>"regex"===l.matching&&new RegExp(l.url).test(a))}let Kr=class Kr{constructor(a){this.xt=a}triggerStatus(a){var l=this.xt.map(l=>
1l.triggerStatus(a));return l.includes(iI)?iI:l.includes(iC)?iC:iR}stop(){this.xt.forEach(a=>a.stop())}};let Yr=class Yr{constructor(a){this.xt=a}triggerStatus(a){var l=new Set;for(var c of this.xt)l.add(c.triggerStatus(a));switch(l.delete(iR),l.size){case 0:return iR;case 1:return Array.from(l)[0];default:return iC}}stop(){this.xt.forEach(a=>a.stop())}};let Xr=class Xr{triggerStatus(){return iC}stop(){}};let Qr=class Qr{constructor(a){this.Et=[],this.It=[],this.urlBlocked=!1,this._instance=a}onRemoteConfig(a){var l,c;this.Et=(null==(l=a.sessionRecording)?void 0:l.urlTriggers)||[],this.It=(null==(c=a.sessionRecording)?void 0:c.urlBlocklist)||[]}Pt(a){var l;return 0===this.Et.length?iR:(null==(l=this._instance)?void 0:l.get_property(eQ))===a?iI:iC}triggerStatus(a){var l=this.Pt(a),c=l===iI?iI:l===iC?iC:iR;return this._instance.register_for_session({$sdk_debug_replay_url_trigger_status:c}),c}checkUrlTriggerConditions(a,l,c){if(void 0!==en&&en.location.href){var u=en.location.href,d=this.urlBlocked,p=Vr(u,this.It);d&&p||(p&&!d?a():!p&&d&&l(),Vr(u,this.Et)&&c("url"))}}stop(){}};let Zr=class Zr{constructor(a){this.linkedFlag=null,this.linkedFlagSeen=!1,this.Rt=()=>{},this._instance=a}triggerStatus(){var a=iC;return F(this.linkedFlag)&&(a=iR),this.linkedFlagSeen&&(a=iI),this._instance.register_for_session({$sdk_debug_replay_linked_flag_trigger_status:a}),a}onRemoteConfig(a,l){var c;if(this.linkedFlag=(null==(c=a.sessionRecording)?void 0:c.linkedFlag)||null,!F(this.linkedFlag)&&!this.linkedFlagSeen){var u=T(this.linkedFlag)?this.linkedFlag:this.linkedFlag.flag,d=T(this.linkedFlag)?null:this.linkedFlag.variant;this.Rt=this._instance.onFeatureFlags((a,c)=>{var p=!1;if(I(c)&&u in c){var g=c[u];p=A(g)?!0===g:d?g===d:!!g}this.linkedFlagSeen=p,p&&l(u,d)})}}stop(){this.Rt()}};let ts=class ts{constructor(a){this.Tt=[],this._instance=a}onRemoteConfig(a){var l;this.Tt=(null==(l=a.sessionRecording)?void 0:l.eventTriggers)||[]}Mt(a){var l;return 0===this.Tt.length?iR:(null==(l=this._instance)?void 0:l.get_property(e0))===a?iI:iC}triggerStatus(a){var l=this.Mt(a),c=l===iI?iI:l===iC?iC:iR;return this._instance.register_for_session({$sdk_debug_replay_event_trigger_status:c}),c}stop(){}};function is(a){return a.isRecordingEnabled?ik:ib}function es(a){if(!a.receivedFlags)return ik;if(!a.isRecordingEnabled)return ib;if(a.urlTriggerMatching.urlBlocked)return iE;var l=!0===a.isSampled,c=new Kr([a.eventTriggerMatching,a.urlTriggerMatching,a.linkedFlagMatching]).triggerStatus(a.sessionId);return l?iw:c===iI?ix:c===iC?ik:!1===a.isSampled?ib:ix}function rs(a){if(!a.receivedFlags)return ik;if(!a.isRecordingEnabled)return ib;if(a.urlTriggerMatching.urlBlocked)return iE;var l=new Yr([a.eventTriggerMatching,a.urlTriggerMatching,a.linkedFlagMatching]).triggerStatus(a.sessionId),c=l!==iR,u=A(a.isSampled);return c&&l===iC?ik:c&&l===iR||u&&!a.isSampled?ib:!0===a.isSampled?iw:ix}var iP="[SessionRecording]",iF=eP(iP);function os(){var a;return null==e_||null==(a=e_.__PosthogExtensions__)||null==(a=a.rrweb)?void 0:a.record}var iO=[tQ.MouseMove,tQ.MouseInteraction,tQ.Scroll,tQ.ViewportResize,tQ.Input,tQ.TouchMove,tQ.MediaInteraction,tQ.Drag],us=a=>({rrwebMethod:a,enqueuedAt:Date.now(),attempt:1});function hs(a){return function(a,l){for(var c="",u=0;u<a.length;){var d=a[u++];d<128||l?c+=String.fromCharCode(d):d<224?c+=String.fromCharCode((31&d)<<6|63&a[u++]):d<240?c+=String.fromCharCode((15&d)<<12|(63&a[u++])<<6|63&a[u++]):c+=String.fromCharCode(55296|(d=((15&d)<<18|(63&a[u++])<<12|(63&a[u++])<<6|63&a[u++])-65536)>>10,56320|1023&d)}return c}(Dr(Lr(JSON.stringify(a))),!0)}function ds(a){return a.type===tX.Custom&&"sessionIdle"===a.data.tag}let vs=class vs{get sessionId(){return this.Ct}get Ft(){return this._instance.config.session_recording.session_idle_threshold_ms||3e5}get started(){return this.Ot}get At(){if(!this._instance.sessionManager)throw Error(iP+" must be started with a valid sessionManager.");return this._instance.sessionManager}get Dt(){var a,l;return this.Lt.triggerStatus(this.sessionId)===iC?6e4:null!==(a=null==(l=this._instance.config.session_recording)?void 0:l.full_snapshot_interval_millis)&&void 0!==a?a:3e5}get jt(){var a=this._instance.get_property(eX);return A(a)?a:null}get Nt(){var a,l,c=null==(a=this.C)?void 0:a.data[(null==(l=this.C)?void 0:l.data.length)-1],{sessionStartTimestamp:u}=this.At.checkAndGetSessionAndWindowId(!0);return c?c.timestamp-u:null}get zt(){var a=!!this._instance.get_property(ez),l=!this._instance.config.disable_session_recording;return en&&a&&l}get Ut(){var a=!!this._instance.get_property(eU),l=this._instance.config.enable_recording_console_log;return null!=l?l:a}get qt(){var a,l,c,u,d,p,g=this._instance.config.session_recording.captureCanvas,f=this._instance.get_property(eW),v=null!==(a=null!==(l=null==g?void 0:g.recordCanvas)&&void 0!==l?l:null==f?void 0:f.enabled)&&void 0!==a&&a,_=null!==(c=null!==(u=null==g?void 0:g.canvasFps)&&void 0!==u?u:null==f?void 0:f.fps)&&void 0!==c?c:4,w=null!==(d=null!==(p=null==g?void 0:g.canvasQuality)&&void 0!==p?p:null==f?void 0:f.quality)&&void 0!==d?d:.4;if("string"==typeof w){var x=parseFloat(w);w=isNaN(x)?.4:x}return{enabled:v,fps:se(_,0,12,"canvas recording fps",4),quality:se(w,0,1,"canvas recording quality",.4)}}get Bt(){var a,l,c=this._instance.get_property(eG),u={recordHeaders:null==(a=this._instance.config.session_recording)?void 0:a.recordHeaders,recordBody:null==(l=this._instance.config.session_recording)?void 0:l.recordBody},d=(null==u?void 0:u.recordHeaders)||(null==c?void 0:c.recordHeaders),p=(null==u?void 0:u.recordBody)||(null==c?void 0:c.recordBody),g=I(this._instance.config.capture_performance)?this._instance.config.capture_performance.network_timing:this._instance.config.capture_performance,f=!!(A(g)?g:null==c?void 0:c.capturePerformance);return d||p||f?{recordHeaders:d,recordBody:p,recordPerformance:f}:void 0}get Ht(){var a,l,c,u,d,p,g=this._instance.get_property(eV),f={maskAllInputs:null==(a=this._instance.config.session_recording)?void 0:a.maskAllInputs,maskTextSelector:null==(l=this._instance.config.session_recording)?void 0:l.maskTextSelector,blockSelector:null==(c=this._instance.config.session_recording)?void 0:c.blockSelector},v=null!==(u=null==f?void 0:f.maskAllInputs)&&void 0!==u?u:null==g?void 0:g.maskAllInputs,_=null!==(d=null==f?void 0:f.maskTextSelector)&&void 0!==d?d:null==g?void 0:g.maskTextSelector,w=null!==(p=null==f?void 0:f.blockSelector)&&void 0!==p?p:null==g?void 0:g.blockSelector;return R(v)&&R(_)&&R(w)?void 0:{maskAllInputs:null==v||v,maskTextSelector:_,blockSelector:w}}get Wt(){var a=this._instance.get_property(eJ);return O(a)?a:null}get Gt(){var a=this._instance.get_property(eY);return O(a)?a:null}get status(){return this.Jt?this.Vt({receivedFlags:this.Jt,isRecordingEnabled:this.zt,isSampled:this.jt,urlTriggerMatching:this.Kt,eventTriggerMatching:this.Yt,linkedFlagMatching:this.Xt,sessionId:this.sessionId}):ik}constructor(a){if(this.Vt=is,this.Jt=!1,this.Qt=[],this.Zt="unknown",this.ti=Date.now(),this.Lt=ne
1w Xr,this.ii=void 0,this.ei=void 0,this.ri=void 0,this.si=void 0,this.ni=void 0,this._forceAllowLocalhostNetworkCapture=!1,this.oi=()=>{this.ai()},this.li=()=>{this.ui("browser offline",{})},this.hi=()=>{this.ui("browser online",{})},this.di=()=>{if(null!=ed&&ed.visibilityState){var a="window "+ed.visibilityState;this.ui(a,{})}},this._instance=a,this.Ot=!1,this.vi="/s/",this.ci=void 0,this.Jt=!1,!this._instance.sessionManager)throw iF.error("started without valid sessionManager"),Error(iP+" started without valid sessionManager. This is a bug.");if(this._instance.config.__preview_experimental_cookieless_mode)throw Error(iP+" cannot be used with __preview_experimental_cookieless_mode.");this.Xt=new Zr(this._instance),this.Kt=new Qr(this._instance),this.Yt=new ts(this._instance);var{sessionId:l,windowId:c}=this.At.checkAndGetSessionAndWindowId();this.Ct=l,this.fi=c,this.C=this.pi(),this.Ft>=this.At.sessionTimeoutMs&&iF.warn("session_idle_threshold_ms ("+this.Ft+") is greater than the session timeout ("+this.At.sessionTimeoutMs+"). Session will never be detected as idle")}startIfEnabledOrStop(a){this.zt?(this.gi(a),st(en,"beforeunload",this.oi),st(en,"offline",this.li),st(en,"online",this.hi),st(en,"visibilitychange",this.di),this.mi(),this.bi(),F(this.ii)&&(this.ii=this._instance.on("eventCaptured",a=>{try{if("$pageview"===a.event){var l=null!=a&&a.properties.$current_url?this.yi(null==a?void 0:a.properties.$current_url):"";if(!l)return;this.ui("$pageview",{href:l})}}catch(a){iF.error("Could not add $pageview to rrweb session",a)}})),this.ei||(this.ei=this.At.onSessionId((a,l,c)=>{var u,d;c&&(this.ui("$session_id_change",{sessionId:a,windowId:l,changeReason:c}),null==(u=this._instance)||null==(u=u.persistence)||u.unregister(e0),null==(d=this._instance)||null==(d=d.persistence)||d.unregister(eQ))}))):this.stopRecording()}stopRecording(){var a,l,c,u;this.Ot&&this.ci&&(this.ci(),this.ci=void 0,this.Ot=!1,null==en||en.removeEventListener("beforeunload",this.oi),null==en||en.removeEventListener("offline",this.li),null==en||en.removeEventListener("online",this.hi),null==en||en.removeEventListener("visibilitychange",this.di),this.pi(),clearInterval(this.wi),null==(a=this.ii)||a.call(this),this.ii=void 0,null==(l=this.ni)||l.call(this),this.ni=void 0,null==(c=this.ei)||c.call(this),this.ei=void 0,null==(u=this.si)||u.call(this),this.si=void 0,this.Yt.stop(),this.Kt.stop(),this.Xt.stop(),iF.info("stopped"))}Si(){var a;null==(a=this._instance.persistence)||a.unregister(eX)}$i(a){var l,c=this.Ct!==a,u=this.Wt;if(O(u)){var d=this.jt,p=c||!A(d),g=p?function(a){for(var l=0,c=0;c<a.length;c++)l=(l<<5)-l+a.charCodeAt(c)|0;return Math.abs(l)}(a)%100<se(100*u,0,100):d;p&&(g?this.ki(iw):iF.warn("Sample rate ("+u+") has determined that this sessionId ("+a+") will not be sent to the server."),this.ui("samplingDecisionMade",{sampleRate:u,isSampled:g})),null==(l=this._instance.persistence)||l.register({[eX]:g})}else this.Si()}onRemoteConfig(a){var l,c,u,d;this.ui("$remote_config_received",a),this.xi(a),null!=(l=a.sessionRecording)&&l.endpoint&&(this.vi=null==(d=a.sessionRecording)?void 0:d.endpoint),this.mi(),"any"===(null==(c=a.sessionRecording)?void 0:c.triggerMatchType)?(this.Vt=es,this.Lt=new Kr([this.Yt,this.Kt])):(this.Vt=rs,this.Lt=new Yr([this.Yt,this.Kt])),this._instance.register_for_session({$sdk_debug_replay_remote_trigger_matching_config:null==(u=a.sessionRecording)?void 0:u.triggerMatchType}),this.Kt.onRemoteConfig(a),this.Yt.onRemoteConfig(a),this.Xt.onRemoteConfig(a,(a,l)=>{this.ki("linked_flag_matched",{flag:a,variant:l})}),this.Jt=!0,this.startIfEnabledOrStop()}mi(){O(this.Wt)&&F(this.si)&&(this.si=this.At.onSessionId(a=>{this.$i(a)}))}
1xi(a){if(this._instance.persistence){var l,c=this._instance.persistence,r=()=>{var l,u,d,p,g,f,v,_,w,x=null==(l=a.sessionRecording)?void 0:l.sampleRate,k=F(x)?null:parseFloat(x);F(k)&&this.Si();var S=null==(u=a.sessionRecording)?void 0:u.minimumDurationMilliseconds;c.register({[ez]:!!a.sessionRecording,[eU]:null==(d=a.sessionRecording)?void 0:d.consoleLogRecordingEnabled,[eG]:B({capturePerformance:a.capturePerformance},null==(p=a.sessionRecording)?void 0:p.networkPayloadCapture),[eV]:null==(g=a.sessionRecording)?void 0:g.masking,[eW]:{enabled:null==(f=a.sessionRecording)?void 0:f.recordCanvas,fps:null==(v=a.sessionRecording)?void 0:v.canvasFps,quality:null==(_=a.sessionRecording)?void 0:_.canvasQuality},[eJ]:k,[eY]:R(S)?null:S,[eK]:null==(w=a.sessionRecording)?void 0:w.scriptConfig})};r(),null==(l=this.ri)||l.call(this),this.ri=this.At.onSessionId(r)}}log(a,l){var c;void 0===l&&(l="log"),null==(c=this._instance.sessionRecording)||c.onRRwebEmit({type:6,data:{plugin:"rrweb/console@1",payload:{level:l,trace:[],payload:[JSON.stringify(a)]}},timestamp:Date.now()})}gi(a){if(!R(Object.assign)&&!R(Array.from)&&!(this.Ot||this._instance.config.disable_session_recording||this._instance.consent.isOptedOut())){var l;(this.Ot=!0,this.At.checkAndGetSessionAndWindowId(),os())?this.Ei():null==(l=e_.__PosthogExtensions__)||null==l.loadExternalDependency||l.loadExternalDependency(this._instance,this.Ii,a=>{if(a)return iF.error("could not load recorder",a);this.Ei()}),iF.info("starting"),this.status===ix&&this.ki(a||"recording_initialized")}}get Ii(){var a;return(null==(a=this._instance)||null==(a=a.persistence)||null==(a=a.get_property(eK))?void 0:a.script)||"recorder"}Pi(a){var l;return 3===a.type&&-1!==iO.indexOf(null==(l=a.data)?void 0:l.source)}Ri(a){var l=this.Pi(a);l||this.Zt||a.timestamp-this.ti>this.Ft&&(this.Zt=!0,clearInterval(this.wi),this.ui("sessionIdle",{eventTimestamp:a.timestamp,lastActivityTimestamp:this.ti,threshold:this.Ft,bufferLength:this.C.data.length,bufferSize:this.C.size}),this.ai());var c=!1;if(l&&(this.ti=a.timestamp,this.Zt)){var u="unknown"===this.Zt;this.Zt=!1,u||(this.ui("sessionNoLongerIdle",{reason:"user activity",type:a.type}),c=!0)}if(!this.Zt){var{windowId:d,sessionId:p}=this.At.checkAndGetSessionAndWindowId(!l,a.timestamp),g=this.Ct!==p,f=this.fi!==d;this.fi=d,this.Ct=p,g||f?(this.stopRecording(),this.startIfEnabledOrStop("session_id_changed")):c&&this.Ti()}}Mi(a){try{return a.rrwebMethod(),!0}catch(l){return this.Qt.length<10?this.Qt.push({enqueuedAt:a.enqueuedAt||Date.now(),attempt:a.attempt++,rrwebMethod:a.rrwebMethod}):iF.warn("could not emit queued rrweb event.",l,a),!1}}ui(a,l){return this.Mi(us(()=>os().addCustomEvent(a,l)))}Ci(){return this.Mi(us(()=>os().takeFullSnapshot()))}Ei(){var a,l,c,u,d={blockClass:"ph-no-capture",blockSelector:void 0,ignoreClass:"ph-ignore-input",maskTextClass:"ph-mask",maskTextSelector:void 0,maskTextFn:void 0,maskAllInputs:!0,maskInputOptions:{password:!0},maskInputFn:void 0,slimDOMOptions:{},collectFonts:!1,inlineStylesheet:!0,recordCrossOriginIframes:!1};for(var[p,g]of Object.entries(this._instance.config.session_recording||{}))p in d&&("maskInputOptions"===p?d.maskInputOptions=B({password:!0},g):d[p]=g);this.qt&&this.qt.enabled&&(d.recordCanvas=!0,d.sampling={canvas:this.qt.fps},d.dataURLOptions={type:"image/webp",quality:this.qt.quality}),this.Ht&&(d.maskAllInputs=null===(l=this.Ht.maskAllInputs)||void 0===l||l,d.maskTextSelector=null!==(c=this.Ht.maskTextSelector)&&void 0!==c?c:void 0,d.blockSelector=null!==(u=this.Ht.blockSelector)&&void 0!==u?u:void 0);var f=os();if(f){this.Fi=null!==(a=this.Fi)&&void 0!==a?a:new Ze(f,{refillRate:this._instance.config.session_recording.__mutationThrottlerRefillRate,bucketSize:this._instance.config.session_recording.__mutationThrottlerBucketSize,onBlockedNode:(a,l)=>{var c="Too many mutations on node '"+a+"'. Rate limiting. This could be due to SVG animations or something similar";iF.info(c,{node:l}),this.log(iP+" "+c,"warn")}});var v=this.Oi();this.ci=f(B({emit:a=>{this.onRRwebEmit(a)},plugins:v},d)),this.ti=Date.now(),this.Zt=A(this.Zt)?this.Zt:"unknown",this.ui("$session_options",{sessionRecordingOptions:d,activePlugins:v.map(a=>null==a?void 0:a.name)}),this.ui("$posthog_config",{config:this._instance.config})}else iF.error("onScriptLoaded was called but rrwebRecord is not available. This indicates something has gone wrong.")}Ti(){if(this.wi&&clearInterval(this.wi),!0!==this.Zt){var a=this.Dt;a&&(this.wi=setInterval(()=>{this.Ci()},a))}}Oi(){var a,l,c=[],u=null==(a=e_.__PosthogExtensions__)||null==(a=a.rrwebPlugins)?void 0:a.getRecordConsolePlugin;u&&this.Ut&&c.push(u());var d=null==(l=e_.__PosthogExtensions__)||null==(l=l.rrwebPlugins)?void 0:l.getRecordNetworkPlugin;return this.Bt&&E(d)&&(!tb.includes(location.hostname)||this._forceAllowLocalhostNetworkCapture?c.push(d(Qe(this._instance.config,this.Bt))):iF.info("NetworkCapture not started because we are on localhost.")),c}onRRwebEmit(a){var l;if(this.Ai(),a&&I(a)){if(a.type===tX.Meta){var c=this.yi(a.data.href);if(this.Di=c,!c)return;a.data.href=c}else this.Li();if(this.Kt.checkUrlTriggerConditions(()=>this.ji(),()=>this.Ni(),a=>this.zi(a)),!this.Kt.urlBlocked||a.type===tX.Custom&&"recording paused"===a.data.tag){a.type===tX.FullSnapshot&&this.Ti(),a.type===tX.FullSnapshot&&this.Jt&&this.Lt.triggerStatus(this.sessionId)===iC&&this.pi();var u=this.Fi?this.Fi.throttleMutations(a):a;
1if(u){var d=function(a){if(a&&I(a)&&6===a.type&&I(a.data)&&"rrweb/console@1"===a.data.plugin){a.data.payload.payload.length>10&&(a.data.payload.payload=a.data.payload.payload.slice(0,10),a.data.payload.payload.push("...[truncated]"));for(var l=[],c=0;c<a.data.payload.payload.length;c++)a.data.payload.payload[c]&&a.data.payload.payload[c].length>2e3?l.push(a.data.payload.payload[c].slice(0,2e3)+"...[truncated]"):l.push(a.data.payload.payload[c]);return a.data.payload.payload=l,a}return a}(u);if(this.Ri(d),!0!==this.Zt||ds(d)){if(ds(d)){var p=d.data.payload;if(p){var g=p.lastActivityTimestamp,f=p.threshold;d.timestamp=g+f}}var v=null===(l=this._instance.config.session_recording.compress_events)||void 0===l||l?function(a){if(1024>ze(a))return a;try{if(a.type===tX.FullSnapshot)return B({},a,{data:hs(a.data),cv:"2024-10"});if(a.type===tX.IncrementalSnapshot&&a.data.source===tQ.Mutation)return B({},a,{cv:"2024-10",data:B({},a.data,{texts:hs(a.data.texts),attributes:hs(a.data.attributes),removes:hs(a.data.removes),adds:hs(a.data.adds)})});if(a.type===tX.IncrementalSnapshot&&a.data.source===tQ.StyleSheetRule)return B({},a,{cv:"2024-10",data:B({},a.data,{adds:a.data.adds?hs(a.data.adds):void 0,removes:a.data.removes?hs(a.data.removes):void 0})})}catch(a){iF.error("could not compress event - will use uncompressed event",a)}return a}(d):d,_={$snapshot_bytes:ze(v),$snapshot_data:v,$session_id:this.Ct,$window_id:this.fi};this.status!==ib?this.Ui(_):this.pi()}}}}}Li(){if(!this._instance.config.capture_pageview&&en){var a=this.yi(en.location.href);this.Di!==a&&(this.ui("$url_changed",{href:a}),this.Di=a)}}Ai(){if(this.Qt.length){var a=[...this.Qt];this.Qt=[],a.forEach(a=>{Date.now()-a.enqueuedAt<=2e3&&this.Mi(a)})}}yi(a){var l=this._instance.config.session_recording;if(l.maskNetworkRequestFn){var c,u={url:a};return null==(c=u=l.maskNetworkRequestFn(u))?void 0:c.url}return a}pi(){return this.C={size:0,data:[],sessionId:this.Ct,windowId:this.fi},this.C}ai(){this.qi&&(clearTimeout(this.qi),this.qi=void 0);var a=this.Gt,l=this.Nt,c=O(l)&&l>=0,u=O(a)&&c&&l<a;return this.status===ik||this.status===iE||this.status===ib||u?(this.qi=setTimeout(()=>{this.ai()},2e3),this.C):(this.C.data.length>0&&(function Ue(a,l){if(void 0===l&&(l=6606028.8),a.size>=l&&a.data.length>1){var c=Math.floor(a.data.length/2),u=a.data.slice(0,c),d=a.data.slice(c);return[Ue({size:ze(u),data:u,sessionId:a.sessionId,windowId:a.windowId}),Ue({size:ze(d),data:d,sessionId:a.sessionId,windowId:a.windowId})].flatMap(a=>a)}return[a]})(this.C).forEach(a=>{this.Bi({$snapshot_bytes:a.size,$snapshot_data:a.data,$session_id:a.sessionId,$window_id:a.windowId,$lib:"web",$lib_version:em.LIB_VERSION})}),this.pi())}Ui(a){var l,c=2+((null==(l=this.C)?void 0:l.data.length)||0);!this.Zt&&(this.C.size+a.$snapshot_bytes+c>943718.4||this.C.sessionId!==this.Ct)&&(this.C=this.ai()),this.C.size+=a.$snapshot_bytes,this.C.data.push(a.$snapshot_data),this.qi||this.Zt||(this.qi=setTimeout(()=>{this.ai()},2e3))}Bi(a){this._instance.capture("$snapshot",a,{_url:this._instance.requestRouter.endpointFor("api",this.vi),_noTruncate:!0,_batchKey:"recordings",skip_client_rate_limiting:!0})}zi(a){var l;this.Lt.triggerStatus(this.sessionId)===iC&&(null==(l=this._instance)||null==(l=l.persistence)||l.register({["url"===a?eQ:e0]:this.Ct}),this.ai(),this.ki(a+"_trigger_matched"))}ji(){this.Kt.urlBlocked||(this.Kt.urlBlocked=!0,clearInterval(this.wi),iF.info("recording paused due to URL blocker"),this.ui("recording paused",{reason:"url blocker"}))}Ni(){this.Kt.urlBlocked&&(this.Kt.urlBlocked=!1,this.Ci(),this.Ti(),this.ui("recording resumed",{reason:"left blocked url"}),iF.info("recording resumed"))}bi(){0!==this.Yt.Tt.length&&F(this.ni)&&(this.ni=this._instance.on("eventCaptured",a=>{try{this.Yt.Tt.includes(a.event)&&this.zi("event")}catch(a){iF.error("Could not activate event trigger",a)}}))}overrideLinkedFlag(){this.Xt.linkedFlagSeen=!0,this.Ci(),this.ki("linked_flag_overridden")}overrideSampling(){var a;null==(a=this._instance.persistence)||a.register({[eX]:!0}),this.Ci(),this.ki("sampling_overridden")}overrideTrigger(a){this.zi(a)}ki(a,l){this._instance.register_for_session({$session_recording_start_reason:a}),iF.info(a.replace("_"," "),l),m(["recording_initialized","session_id_changed"],a)||this.ui(a,l)}get sdkDebugProperties(){var{sessionStartTimestamp:a}=this.At.checkAndGetSessionAndWindowId(!0);return{$recording_status:this.status,$sdk_debug_replay_internal_buffer_length:this.C.data.length,$sdk_debug_replay_internal_buffer_size:this.C.size,$sdk_debug_current_session_duration:this.Nt,$sdk_debug_session_start:a}}};var iT=eP("[SegmentIntegration]"),i$="posthog-js";function gs(a,l){var{organization:c,projectId:u,prefix:d,severityAllowList:p=["error"]}=void 0===l?{}:l;return l=>{if(!("*"===p||p.includes(l.level))||!a.__loaded)return l;l.tags||(l.tags={});
vendor: 11,931 bytes, line 1
1var g,f,v,_,w,x=a.requestRouter.endpointFor("ui","/project/"+a.config.token+"/person/"+a.get_distinct_id());l.tags["PostHog Person URL"]=x,a.sessionRecordingStarted()&&(l.tags["PostHog Recording URL"]=a.get_session_replay_url({withTimestamp:!0}));var k=(null==(g=l.exception)?void 0:g.values)||[],S=k.map(a=>B({},a,{stacktrace:a.stacktrace?B({},a.stacktrace,{type:"raw",frames:(a.stacktrace.frames||[]).map(a=>B({},a,{platform:"web:javascript"}))}):void 0})),$={$exception_message:(null==(f=k[0])?void 0:f.value)||l.message,$exception_type:null==(v=k[0])?void 0:v.type,$exception_personURL:x,$exception_level:l.level,$exception_list:S,$sentry_event_id:l.event_id,$sentry_exception:l.exception,$sentry_exception_message:(null==(_=k[0])?void 0:_.value)||l.message,$sentry_exception_type:null==(w=k[0])?void 0:w.type,$sentry_tags:l.tags};return c&&u&&($.$sentry_url=(d||"https://sentry.io/organizations/")+c+"/issues/?project="+u+"&query="+l.event_id),a.exceptions.sendExceptionEvent($),l}}let _s=class _s{constructor(a,l,c,u,d){this.name=i$,this.setupOnce=function(p){p(gs(a,{organization:l,projectId:c,prefix:u,severityAllowList:d}))}}};var ij=null!=en&&en.location?xi(en.location.hash,"__posthog")||xi(location.hash,"state"):null,iA="_postHogToolbarParams",iM=eP("[Toolbar]"),iN=((ss=iN||{})[ss.UNINITIALIZED=0]="UNINITIALIZED",ss[ss.LOADING=1]="LOADING",ss[ss.LOADED=2]="LOADED",ss);let Ss=class Ss{constructor(a){this.instance=a}Hi(a){e_.ph_toolbar_state=a}Wi(){var a;return null!==(a=e_.ph_toolbar_state)&&void 0!==a?a:iN.UNINITIALIZED}maybeLoadToolbar(a,l,c){if(void 0===a&&(a=void 0),void 0===l&&(l=void 0),void 0===c&&(c=void 0),!en||!ed)return!1;a=null!=a?a:en.location,c=null!=c?c:en.history;try{if(!l){try{en.localStorage.setItem("test","test"),en.localStorage.removeItem("test")}catch(a){return!1}l=null==en?void 0:en.localStorage}var u,d=ij||xi(a.hash,"__posthog")||xi(a.hash,"state"),p=d?X(()=>JSON.parse(atob(decodeURIComponent(d))))||X(()=>JSON.parse(decodeURIComponent(d))):null;return p&&"ph_authorize"===p.action?((u=p).source="url",u&&Object.keys(u).length>0&&(p.desiredHash?a.hash=p.desiredHash:c?c.replaceState(c.state,"",a.pathname+a.search):a.hash="")):((u=JSON.parse(l.getItem(iA)||"{}")).source="localstorage",delete u.userIntent),!(!u.token||this.instance.config.token!==u.token)&&(this.loadToolbar(u),!0)}catch(a){return!1}}Gi(a){var l=e_.ph_load_toolbar||e_.ph_load_editor;!F(l)&&E(l)?l(a,this.instance):iM.warn("No toolbar load function found")}loadToolbar(a){var l,c=!(null==ed||!ed.getElementById(tu));if(!en||c)return!1;var u="custom"===this.instance.requestRouter.region&&this.instance.config.advanced_disable_toolbar_metrics,d=B({token:this.instance.config.token},a,{apiURL:this.instance.requestRouter.endpointFor("ui")},u?{instrument:!1}:{});return(en.localStorage.setItem(iA,JSON.stringify(B({},d,{source:void 0}))),this.Wi()===iN.LOADED)?this.Gi(d):this.Wi()===iN.UNINITIALIZED&&(this.Hi(iN.LOADING),null==(l=e_.__PosthogExtensions__)||null==l.loadExternalDependency||l.loadExternalDependency(this.instance,"toolbar",a=>{if(a)return iM.error("[Toolbar] Failed to load",a),void this.Hi(iN.UNINITIALIZED);this.Hi(iN.LOADED),this.Gi(d)}),st(en,"turbolinks:load",()=>{this.Hi(iN.UNINITIALIZED),this.loadToolbar(d)})),!0}Ji(a){return this.loadToolbar(a)}maybeLoadEditor(a,l,c){return void 0===a&&(a=void 0),void 0===l&&(l=void 0),void 0===c&&(c=void 0),this.maybeLoadToolbar(a,l,c)}};var iL=eP("[TracingHeaders]");let ks=class ks{constructor(a){this.Vi=void 0,this.Ki=void 0,this.nt=()=>{var a,l;R(this.Vi)&&(null==(a=e_.__PosthogExtensions__)||null==(a=a.tracingHeadersPatchFns)||a._patchXHR(this._instance.get_distinct_id(),this._instance.sessionManager)),R(this.Ki)&&(null==(l=e_.__PosthogExtensions__)||null==(l=l.tracingHeadersPatchFns)||l._patchFetch(this._instance.get_distinct_id(),this._instance.sessionManager))},this._instance=a}J(a){var l,c;null!=(l=e_.__PosthogExtensions__)&&l.tracingHeadersPatchFns&&a(),null==(c=e_.__PosthogExtensions__)||null==c.loadExternalDependency||c.loadExternalDependency(this._instance,"tracing-headers",l=>{if(l)return iL.error("failed to load script",l);a()})}startIfEnabledOrStop(){var a,l;this._instance.config.__add_tracing_headers?this.J(this.nt):(null==(a=this.Vi)||a.call(this),null==(l=this.Ki)||l.call(this),this.Vi=void 0,this.Ki=void 0)}};var iD=eP("[Web Vitals]");let Is=class Is{constructor(a){var l;this.Yi=!1,this.i=!1,this.C={url:void 0,metrics:[],firstMetricTimestamp:void 0},this.Xi=()=>{clearTimeout(this.Qi),0!==this.C.metrics.length&&(this._instance.capture("$web_vitals",this.C.metrics.reduce((a,l)=>B({},a,{["$web_vitals_"+l.name+"_event"]:B({},l),["$web_vitals_"+l.name+"_value"]:l.value}),{})),this.C={url:void 0,metrics:[],firstMetricTimestamp:void 0})},this.Zi=a=>{var l,c=null==(l=this._instance.sessionManager)?void 0:l.checkAndGetSessionAndWindowId(!0);if(R(c))iD.error("Could not read session ID. Dropping metrics!");else{this.C=this.C||{url:void 0,metrics:[],firstMetricTimestamp:void 0};var u=this.te();R(u)||(F(null==a?void 0:a.name)||F(null==a?void 0:a.value)?iD.error("Invalid metric received",a):this.ie&&a.value>=this.ie?iD.error("Ignoring metric with value >= "+this.ie,a):(this.C.url!==u&&(this.Xi(),this.Qi=setTimeout(this.Xi,this.flushToCaptureTimeoutMs)),R(this.C.url)&&(this.C.url=u),this.C.firstMetricTimestamp=R(this.C.firstMetricTimestamp)?Date.now():this.C.firstMetricTimestamp,a.attribution&&a.attribution.interactionTargetElement&&(a.attribution.interactionTargetElement=void 0),this.C.metrics.push(B({},a,{$current_url:u,$session_id:c.sessionId,$window_id:c.windowId,timestamp:Date.now()})),this.C.metrics.length===this.allowedMetrics.length&&this.Xi()))}},this.nt=()=>{var a,l,c,u,d=e_.__PosthogExtensions__;R(d)||R(d.postHogWebVitalsCallbacks)||({onLCP:a,onCLS:l,onFCP:c,onINP:u}=d.postHogWebVitalsCallbacks),a&&l&&c&&u?(this.allowedMetrics.indexOf("LCP")>-1&&a(this.Zi.bind(this)),this.allowedMetrics.indexOf("CLS")>-1&&l(this.Zi.bind(this)),this.allowedMetrics.indexOf("FCP")>-1&&c(this.Zi.bind(this)),this.allowedMetrics.indexOf("INP")>-1&&u(this.Zi.bind(this)),this.i=!0):iD.error("web vitals callbacks not loaded - not starting")},this._instance=a,this.Yi=!(null==(l=this._instance.persistence)||!l.props[eB]),this.startIfEnabled()}get allowedMetrics(){var a,l,c=I(this._instance.config.capture_performance)?null==(a=this._instance.config.capture_performance)?void 0:a.web_vitals_allowed_metrics:void 0;return R(c)?(null==(l=this._instance.persistence)?void 0:l.props[eq])||["CLS","FCP","INP","LCP"]:c}get flushToCaptureTimeoutMs(){return(I(this._instance.config.capture_performance)?this._instance.config.capture_performance.web_vitals_delayed_flush_ms:void 0)||5e3}get ie(){var a=I(this._instance.config.capture_performance)&&O(this._instance.config.capture_performance.__web_vitals_max_value)?this._instance.config.capture_performance.__web_vitals_max_value:9e5;return 0<a&&a<=6e4?9e5:a}get isEnabled(){var a=null==eh?void 0:eh.protocol;if("http:"!==a&&"https:"!==a)return iD.info("Web Vitals are disabled on non-http/https protocols"),!1;var l=I(this._instance.config.capture_performance)?this._instance.config.capture_performance.web_vitals:A(this._instance.config.capture_performance)?this._instance.config.capture_performance:void 0;return A(l)?l:this.Yi}startIfEnabled(){this.isEnabled&&!this.i&&(iD.info("enabled, starting..."),this.J(this.nt))}onRemoteConfig(a){var l=I(a.capturePerformance)&&!!a.capturePerformance.web_vitals,c=I(a.capturePerformance)?a.capturePerformance.web_vitals_allowed_metrics:void 0;this._instance.persistence&&(this._instance.persistence.register({[eB]:l}),this._instance.persistence.register({[eq]:c})),this.Yi=l,this.startIfEnabled()}J(a){var l,c;null!=(l=e_.__PosthogExtensions__)&&l.postHogWebVitalsCallbacks&&a(),null==(c=e_.__PosthogExtensions__)||null==c.loadExternalDependency||c.loadExternalDependency(this._instance,"web-vitals",l=>{l?iD.error("failed to load script",l):a()})}te(){var a=en?en.location.href:void 0;return a||iD.error("Could not determine current URL"),a}};var iB=eP("[Heatmaps]");function Rs(a){return I(a)&&"clientX"in a&&"clientY"in a&&O(a.clientX)&&O(a.clientY)}let Ts=class Ts{constructor(a){var l;this.rageclicks=new bi,this.Yi=!1,this.i=!1,this.ee=null,this.instance=a,this.Yi=!(null==(l=this.instance.persistence)||!l.props[eN])}get flushIntervalMilliseconds(){var a=5e3;return I(this.instance.config.capture_heatmaps)&&this.instance.config.capture_heatmaps.flush_interval_milliseconds&&(a=this.instance.config.capture_heatmaps.flush_interval_milliseconds),a}get isEnabled(){return R(this.instance.config.capture_heatmaps)?R(this.instance.config.enable_heatmaps)?this.Yi:this.instance.config.enable_heatmaps:!1!==this.instance.config.capture_heatmaps}startIfEnabled(){if(this.isEnabled)this.i||(iB.info("starting..."),this.re(),this.ee=setInterval(this.se.bind(this),this.flushIntervalMilliseconds));else{var a,l;clearInterval(null!==(a=this.ee)&&void 0!==a?a:void 0),null==(l=this.ne)||l.stop(),this.getAndClearBuffer()}}onRemoteConfig(a){var l=!!a.heatmaps;this.instance.persistence&&this.instance.persistence.register({[eN]:l}),this.Yi=l,this.startIfEnabled()}getAndClearBuffer(){var a=this.C;return this.C=void 0,a}oe(a){this.ae(a.originalEvent,"deadclick")}re(){en&&ed&&(st(en,"beforeunload",this.se.bind(this)),st(ed,"click",a=>this.ae(a||(null==en?void 0:en.event)),{capture:!0}),st(ed,"mousemove",a=>this.le(a||(null==en?void 0:en.event)),{capture:!0}),this.ne=new re(this.instance,ie,this.oe.bind(this)),this.ne.startIfEnabled(),this.i=!0)}ue(a,l){var c=this.instance.scrollManager.scrollY(),u=this.instance.scrollManager.scrollX(),d=this.instance.scrollManager.scrollElement(),p=function(a,l,c){for(var u=a;u&&Gt(u)&&!Jt(u,"body")&&u!==c;){if(m(l,null==en?void 0:en.getComputedStyle(u).position))return!0;u=ri(u)}return!1}(ii(a),["fixed","sticky"],d);return{x:a.clientX+(p?0:u),y:a.clientY+(p?0:c),target_fixed:p,type:l}}ae(a,l){var c;if(void 0===l&&(l="click"),!Wt(a.target)&&Rs(a)){var u=this.ue(a,l);null!=(c=this.rageclicks)&&c.isRageClick(a.clientX,a.clientY,(new Date).getTime())&&this.he(B({},u,{type:"rageclick"})),this.he(u)}}le(a){!Wt(a.target)&&Rs(a)&&(clearTimeout(this.de),this.de=setTimeout(()=>{this.he(this.ue(a,"mousemove"))},500))}he(a){if(en){var l=en.location.href;this.C=this.C||{},this.C[l]||(this.C[l]=[]),this.C[l].push(a)}}se(){this.C&&!P(this.C)&&this.instance.capture("$$heatmap",{$heatmap_data:this.getAndClearBuffer()})}};let Ms=class Ms{constructor(a){this._instance=a}doPageView(a,l){var c,u=this.ve(a,l);return this.ce={pathname:null!==(c=null==en?void 0:en.location.pathname)&&void 0!==c?c:"",pageViewId:l,timestamp:a},this._instance.scrollManager.resetContext(),u}doPageLeave(a){var l;return this.ve(a,null==(l=this.ce)?void 0:l.pageViewId)}doEvent(){var a;return{$pageview_id:null==(a=this.ce)?void 0:a.pageViewId}}ve(a,l){var c=this.ce;if(!c)return{$pageview_id:l};var u={$pageview_id:l,$prev_pageview_id:c.pageViewId},d=this._instance.scrollManager.getContext();if(d&&!this._instance.config.disable_scroll_properties){var{maxScrollHeight:p,lastScrollY:g,maxScrollY:f,maxContentHeight:v,lastContentY:_,maxContentY:w}=d;if(!(R(p)||R(g)||R(f)||R(v)||R(_)||R(w))){p=Math.ceil(p),g=Math.ceil(g),f=Math.ceil(f),v=Math.ceil(v),_=Math.ceil(_),w=Math.ceil(w);var x=p<=1?1:se(g/p,0,1),k=p<=1?1:se(f/p,0,1),S=v<=1?1:se(_/v,0,1),$=v<=1?1:se(w/v,0,1);u=V(u,{$prev_pageview_last_scroll:g,$prev_pageview_last_scroll_percentage:x,$prev_pageview_max_scroll:f,$prev_pageview_max_scroll_percentage:k,$prev_pageview_last_content:_,$prev_pageview_last_content_percentage:S,$prev_pageview_max_content:w,$prev_pageview_max_content_percentage:$})}}return c.pathname&&(u.$prev_pageview_pathname=c.pathname),c.timestamp&&(u.$prev_pageview_duration=(a.getTime()-c.timestamp.getTime())/1e3),u}};var Cs=function(a){var l,c,u,d,p="";for(l=c=0,u=(a=(a+"").replace(/\r\n/g,"\n").replace(/\r/g,"\n")).length,d=0;d<u;
1d++){var g=a.charCodeAt(d),f=null;g<128?c++:f=g>127&&g<2048?String.fromCharCode(g>>6|192,63&g|128):String.fromCharCode(g>>12|224,g>>6&63|128,63&g|128),C(f)||(c>l&&(p+=a.substring(l,c)),p+=f,l=c=d+1)}return c>l&&(p+=a.substring(l,a.length)),p},iH=!!eg||!!ep,iq="text/plain",As=(a,l)=>{var[c,u]=a.split("?"),d=B({},l);null==u||u.split("&").forEach(a=>{var[l]=a.split("=");delete d[l]});var p=Si(d);return c+"?"+(p=p?(u?u+"&":"")+p:u)},Ds=(a,l)=>JSON.stringify(a,(a,l)=>"bigint"==typeof l?l.toString():l,l),Ls=a=>{var{data:l,compression:c}=a;if(l){if(c===ew.GZipJS){var u=Dr(Lr(Ds(l)),{mtime:0}),d=new Blob([u],{type:iq});return{contentType:iq,body:d,estimatedSize:d.size}}if(c===ew.Base64){var p,g="data="+encodeURIComponent("string"==typeof(p=function(a){var l,c,u,d,p,g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",f=0,v=0,_="",w=[];if(!a)return a;a=Cs(a);do l=(p=a.charCodeAt(f++)<<16|a.charCodeAt(f++)<<8|a.charCodeAt(f++))>>18&63,c=p>>12&63,u=p>>6&63,d=63&p,w[v++]=g.charAt(l)+g.charAt(c)+g.charAt(u)+g.charAt(d);while(f<a.length);switch(_=w.join(""),a.length%3){case 1:_=_.slice(0,-2)+"==";break;case 2:_=_.slice(0,-1)+"="}return _}(Ds(l)))?p:Ds(p));return{contentType:"application/x-www-form-urlencoded",body:g,estimatedSize:new Blob([g]).size}}var f=Ds(l);return{contentType:"application/json",body:f,estimatedSize:new Blob([f]).size}}},iz=[];ep&&iz.push({transport:"fetch",method:a=>{var l,c,{contentType:u,body:d,estimatedSize:p}=null!==(l=Ls(a))&&void 0!==l?l:{},g=new Headers;J(a.headers,function(a,l){g.append(l,a)}),u&&g.append("Content-Type",u);var f=a.url,v=null;if(ef){var _=new ef;v={signal:_.signal,timeout:setTimeout(()=>_.abort(),a.timeout)}}ep(f,B({method:(null==a?void 0:a.method)||"GET",headers:g,keepalive:"POST"===a.method&&52428.8>(p||0),body:d,signal:null==(c=v)?void 0:c.signal},a.fetchOptions)).then(l=>l.text().then(c=>{var u={statusCode:l.status,text:c};if(200===l.status)try{u.json=JSON.parse(c)}catch(a){eR.error(a)}null==a.callback||a.callback(u)})).catch(l=>{eR.error(l),null==a.callback||a.callback({statusCode:0,text:l})}).finally(()=>v?clearTimeout(v.timeout):null)}}),eg&&iz.push({transport:"XHR",method:a=>{var l,c=new eg;c.open(a.method||"GET",a.url,!0);var{contentType:u,body:d}=null!==(l=Ls(a))&&void 0!==l?l:{};J(a.headers,function(a,l){c.setRequestHeader(l,a)}),u&&c.setRequestHeader("Content-Type",u),a.timeout&&(c.timeout=a.timeout),c.withCredentials=!0,c.onreadystatechange=()=>{if(4===c.readyState){var l={statusCode:c.status,text:c.responseText};if(200===c.status)try{l.json=JSON.parse(c.responseText)}catch(a){}null==a.callback||a.callback(l)}},c.send(d)}}),null!=eu&&eu.sendBeacon&&iz.push({transport:"sendBeacon",method:a=>{var l=As(a.url,{beacon:"1"});try{var c,{contentType:u,body:d}=null!==(c=Ls(a))&&void 0!==c?c:{},p="string"==typeof d?new Blob([d],{type:u}):d;eu.sendBeacon(l,p)}catch(a){}}});var Ns=function(a,l){if(!function(a){try{new RegExp(a)}catch(a){return!1}return!0}(l))return!1;try{return new RegExp(l).test(a)}catch(a){return!1}};function zs(a,l,c){return Ds({distinct_id:a,userPropertiesToSet:l,userPropertiesToSetOnce:c})}var iU={exact:(a,l)=>l.some(l=>a.some(a=>l===a)),is_not:(a,l)=>l.every(l=>a.every(a=>l!==a)),regex:(a,l)=>l.some(l=>a.some(a=>Ns(l,a))),not_regex:(a,l)=>l.every(l=>a.every(a=>!Ns(l,a))),icontains:(a,l)=>l.map(qs).some(l=>a.map(qs).some(a=>l.includes(a))),not_icontains:(a,l)=>l.map(qs).every(l=>a.map(qs).every(a=>!l.includes(a)))},qs=a=>a.toLowerCase(),iG=eP("[Error tracking]");let Hs=class Hs{constructor(a){var l,c;this.fe=[],this._instance=a,this.fe=null!==(l=null==(c=this._instance.persistence)?void 0:c.get_property(eD))&&void 0!==l?l:[]}onRemoteConfig(a){var l,c,u=null!==(l=null==(c=a.errorTracking)?void 0:c.suppressionRules)&&void 0!==l?l:[];this.fe=u,this._instance.persistence&&this._instance.persistence.register({[eD]:this.fe})}sendExceptionEvent(a){this.pe(a)?iG.info("Skipping exception capture because a suppression rule matched"):this._instance.capture("$exception",a,{_noTruncate:!0,_batchKey:"exceptionEvent"})}pe(a){var l=a.$exception_list;if(!l||!eC(l)||0===l.length)return!1;var c=l.reduce((a,l)=>{var{type:c,value:u}=l;return T(c)&&c.length>0&&a.$exception_types.push(c),T(u)&&u.length>0&&a.$exception_values.push(u),a},{$exception_types:[],$exception_values:[]});return this.fe.some(a=>{var l=a.values.map(a=>{var l,u=iU[a.operator],d=eC(a.value)?a.value:[a.value],p=null!==(l=c[a.key])&&void 0!==l?l:[];return d.length>0&&u(d,p)});return"OR"===a.type?l.some(Boolean):l.every(Boolean)})}};var iV="Mobile",iW="Android",iJ="Tablet",iY=iW+" "+iJ,iK="iPad",iZ="Apple",iX=iZ+" Watch",iQ="Safari",i0="BlackBerry",i1="Samsung",i2=i1+"Browser",i3=i1+" Internet",i4="Chrome",i5=i4+" OS",i6=i4+" iOS",i8="Internet Explorer",i7=i8+" "+iV,i9="Opera",rr=i9+" Mini",rn="Edge",ro="Microsoft "+rn,rl="Firefox",rc=rl+" iOS",ru="Nintendo",rd="PlayStation",rh="Xbox",rp=iW+" "+iV,rg=iV+" "+iQ,rf="Windows",rv=rf+" Phone",r_="Nokia",rm="Ouya",ry="Generic",rb=ry+" "+iV.toLowerCase(),rw=ry+" "+iJ.toLowerCase(),rx="Konqueror",rk="(\\d+(\\.\\d+)?)",rE=RegExp("Version/"+rk),rS=RegExp(rh,"i"),rI=RegExp(rd+" \\w+","i"),rC=RegExp(ru+" \\w+","i"),rR=RegExp(i0+"|PlayBook|BB10","i"),rP={"NT3.51":"NT 3.11","NT4.0":"NT 4.0","5.0":"2000",5.1:"XP",5.2:"XP","6.0":"Vista",6.1:"7",6.2:"8",6.3:"8.1",6.4:"10","10.0":"10"},Dn=(a,l)=>l&&m(l,iZ)||m(a,iQ)&&!m(a,i4)&&!m(a,iW),Ln=function(a,l){return l=l||"",m(a," OPR/")&&m(a,"Mini")?rr:m(a," OPR/")?i9:rR.test(a)?i0:m(a,"IE"+iV)||m(a,"WPDesktop")?i7:m(a,i2)?i3:m(a,rn)||m(a,"Edg/")?ro:m(a,"FBIOS")?"Facebook "+iV:m(a,"UCWEB")||m(a,"UCBrowser")?"UC Browser":m(a,"CriOS")?i6:m(a,"CrMo")||m(a,i4)?i4:m(a,iW)&&m(a,iQ)?rp:m(a,"FxiOS")?rc:m(a.toLowerCase(),rx.toLowerCase())?rx:Dn(a,l)?m(a,iV)?rg:iQ:m(a,rl)?rl:m(a,"MSIE")||m(a,"Tr
1ident/")?i8:m(a,"Gecko")?rl:""},rF={[i7]:[RegExp("rv:"+rk)],[ro]:[RegExp(rn+"?\\/"+rk)],[i4]:[RegExp("("+i4+"|CrMo)\\/"+rk)],[i6]:[RegExp("CriOS\\/"+rk)],"UC Browser":[RegExp("(UCBrowser|UCWEB)\\/"+rk)],[iQ]:[rE],[rg]:[rE],[i9]:[RegExp("(Opera|OPR)\\/"+rk)],[rl]:[RegExp(rl+"\\/"+rk)],[rc]:[RegExp("FxiOS\\/"+rk)],[rx]:[RegExp("Konqueror[:/]?"+rk,"i")],[i0]:[RegExp(i0+" "+rk),rE],[rp]:[RegExp("android\\s"+rk,"i")],[i3]:[RegExp(i2+"\\/"+rk)],[i8]:[RegExp("(rv:|MSIE )"+rk)],Mozilla:[RegExp("rv:"+rk)]},Nn=function(a,l){var c=rF[Ln(a,l)];if(R(c))return null;for(var u=0;u<c.length;u++){var d=c[u],p=a.match(d);if(p)return parseFloat(p[p.length-2])}return null},rO=[[RegExp(rh+"; "+rh+" (.*?)[);]","i"),a=>[rh,a&&a[1]||""]],[RegExp(ru,"i"),[ru,""]],[RegExp(rd,"i"),[rd,""]],[rR,[i0,""]],[RegExp(rf,"i"),(a,l)=>{if(/Phone/.test(l)||/WPDesktop/.test(l))return[rv,""];if(new RegExp(iV).test(l)&&!/IEMobile\b/.test(l))return[rf+" "+iV,""];var c=/Windows NT ([0-9.]+)/i.exec(l);if(c&&c[1]){var u=rP[c[1]]||"";return/arm/i.test(l)&&(u="RT"),[rf,u]}return[rf,""]}],[/((iPhone|iPad|iPod).*?OS (\d+)_(\d+)_?(\d+)?|iPhone)/,a=>a&&a[3]?["iOS",[a[3],a[4],a[5]||"0"].join(".")]:["iOS",""]],[/(watch.*\/(\d+\.\d+\.\d+)|watch os,(\d+\.\d+),)/i,a=>{var l="";return a&&a.length>=3&&(l=R(a[2])?a[3]:a[2]),["watchOS",l]}],[RegExp("("+iW+" (\\d+)\\.(\\d+)\\.?(\\d+)?|"+iW+")","i"),a=>a&&a[2]?[iW,[a[2],a[3],a[4]||"0"].join(".")]:[iW,""]],[/Mac OS X (\d+)[_.](\d+)[_.]?(\d+)?/i,a=>{var l=["Mac OS X",""];if(a&&a[1]){var c=[a[1],a[2],a[3]||"0"];l[1]=c.join(".")}return l}],[/Mac/i,["Mac OS X",""]],[/CrOS/,[i5,""]],[/Linux|debian/i,["Linux",""]]],Un=function(a){return rC.test(a)?ru:rI.test(a)?rd:rS.test(a)?rh:RegExp(rm,"i").test(a)?rm:RegExp("("+rv+"|WPDesktop)","i").test(a)?rv:/iPad/.test(a)?iK:/iPod/.test(a)?"iPod Touch":/iPhone/.test(a)?"iPhone":/(watch)(?: ?os[,/]|\d,\d\/)[\d.]+/i.test(a)?iX:rR.test(a)?i0:/(kobo)\s(ereader|touch)/i.test(a)?"Kobo":RegExp(r_,"i").test(a)?r_:/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i.test(a)||/(kf[a-z]+)( bui|\)).+silk\//i.test(a)?"Kindle Fire":/(Android|ZTE)/i.test(a)?!new RegExp(iV).test(a)||/(9138B|TB782B|Nexus [97]|pixel c|HUAWEISHT|BTV|noble nook|smart ultra 6)/i.test(a)?/pixel[\daxl ]{1,6}/i.test(a)&&!/pixel c/i.test(a)||/(huaweimed-al00|tah-|APA|SM-G92|i980|zte|U304AA)/i.test(a)||/lmy47v/i.test(a)&&!/QTAQZ3/i.test(a)?iW:iY:iW:RegExp("(pda|"+iV+")","i").test(a)?rb:RegExp(iJ,"i").test(a)&&!RegExp(iJ+" pc","i").test(a)?rw:""},rT="https?://(.*)",r$=["gclid","gclsrc","dclid","gbraid","wbraid","fbclid","msclkid","twclid","li_fat_id","igshid","ttclid","rdt_cid","epik","qclid","sccid","irclid","_kx"],rj=K(["utm_source","utm_medium","utm_campaign","utm_content","utm_term","gad_source","mc_cid"],r$),rA="<masked>",rM=["li_fat_id"];function Jn(a,l,c){if(!ed)return{};var u,d=l?K([],r$,c||[]):[],p=Vn(ki(ed.URL,d,rA),a);return V((u={},J(rM,function(a){var l=tC.D(a);u[a]=l||null}),u),p)}function Vn(a,l){var c=rj.concat(l||[]),u={};return J(c,function(l){var c=$i(a,l);u[l]=c||null}),u}function Kn(a){var l=a?0===a.search(rT+"google.([^/?]*)")?"google":0===a.search(rT+"bing.com")?"bing":0===a.search(rT+"yahoo.com")?"yahoo":0===a.search(rT+"duckduckgo.com")?"duckduckgo":null:null,c="yahoo"!=l?"q":"p",u={};if(!C(l)){u.$search_engine=l;var d=ed?$i(ed.referrer,c):"";d.length&&(u.ph_keyword=d)}return u}function Yn(){return navigator.language||navigator.userLanguage}function Xn(){return(null==ed?void 0:ed.referrer)||"$direct"}function Qn(a,l){var c=a?K([],r$,l||[]):[],u=null==eh?void 0:eh.href.substring(0,1e3);return{r:Xn().substring(0,1e3),u:u?ki(u,c,rA):void 0}}function Zn(a){var l,{r:c,u:u}=a,d={$referrer:c,$referring_domain:null==c?void 0:"$direct"==c?"$direct":null==(l=wi(c))?void 0:l.host};if(u){d.$current_url=u;var p=wi(u);d.$host=null==p?void 0:p.host,d.$pathname=null==p?void 0:p.pathname,V(d,Vn(u))}return c&&V(d,Kn(c)),d}function to(){try{return Intl.DateTimeFormat().resolvedOptions().timeZone}catch(a){return}}var rN=eP("[FeatureFlags]"),rL="$active_feature_flags",rD="$override_feature_flags",rB="$feature_flag_payloads",rH="$override_feature_flag_payloads",rq="$feature_flag_request_id",uo=a=>{var l={};for(var[c,u]of Y(a||{}))u&&(l[c]=u);return l},ho=a=>{var l=a.flags;return l?(a.featureFlags=Object.fromEntries(Object.keys(l).map(a=>{var c;return[a,null!==(c=l[a].variant)&&void 0!==c?c:l[a].enabled]})),a.featureFlagPayloads=Object.fromEntries(Object.keys(l).filter(a=>l[a].enabled).filter(a=>{var c;return null==(c=l[a].metadata)?void 0:c.payload}).map(a=>{var c;return[a,null==(c=l[a].metadata)?void 0:c.payload]}))):rN.warn("Using an older version of the feature flags endpoint. Please upgrade your PostHog server to the latest version"),a},rz=((sn={}).FeatureFlags="feature_flags",sn.Recordings="recordings",sn);let co=class co{constructor(a){this.ge=!1,this._e=!1,this.me=!1,this.be=!1,this.ye=!1,this.we=!1,this.Se=!1,this._instance=a,this.featureFlagEventHandlers=[]}flags(){if(this._instance.config.__preview_remote_config)this.we=!0;else{var a=!this.$e&&(this._instance.config.advanced_disable_feature_flags||this._instance.config.advanced_disable_feature_flags_on_first_load);this.ke({disableFlags:a})}}get hasLoadedFlags(){return this._e}getFlags(){return Object.keys(this.getFlagVariants())}getFlagsWithDetails(){var a=this._instance.get_property(e3),l=this._instance.get_property(rD),c=this._instance.get_property(rH);if(!c&&!l)return a||{};var u=V({},a||{});for(var d of[...new Set([...Object.keys(c||{}),...Object.keys(l||{})])]){var p,g,f=u[d],v=null==l?void 0:l[d],_=R(v)?null!==(p=null==f?void 0:f.enabled)&&void 0!==p&&p:!!v,w=R(v)?f.variant:"string"==typeof v?v:void 0,x=null==c?void 0:c[d],k=B({},f,{enabled:_,variant:_?null!=w?w:null==f?void 0:f.variant:void 0});_!==(null==f?void 0:f.enabled)&&(k.original_enabled=null==f?void 0:f.enabled),w!==(null==f?void 0:f.variant)&&(k.original_variant=null==f?void 0:f.variant),x&&(k.metadata=B({},null==f?void 0:f.metadata,{payload:x,original_payload:null==f||null==(g=f.metadata)?void 0:g.payload})),u[d]=k}return this.ge||(rN.warn(" Overriding feature flag details!",{flagDetails:a,overriddenPayloads:c,finalDetails:u}),this.ge=!0),u}getFlagVariants(){var a=this._instance.get_property(e1),l=this._instance.get_property(rD);if(!l)return a||{};for(var c=V({},a),u=Object.keys(l),d=0;d<u.length;
1d++)c[u[d]]=l[u[d]];return this.ge||(rN.warn(" Overriding feature flags!",{enabledFlags:a,overriddenFlags:l,finalFlags:c}),this.ge=!0),c}getFlagPayloads(){var a=this._instance.get_property(rB),l=this._instance.get_property(rH);if(!l)return a||{};for(var c=V({},a||{}),u=Object.keys(l),d=0;d<u.length;d++)c[u[d]]=l[u[d]];return this.ge||(rN.warn(" Overriding feature flag payloads!",{flagPayloads:a,overriddenPayloads:l,finalPayloads:c}),this.ge=!0),c}reloadFeatureFlags(){this.be||this._instance.config.advanced_disable_feature_flags||this.$e||(this.$e=setTimeout(()=>{this.ke()},5))}xe(){clearTimeout(this.$e),this.$e=void 0}ensureFlagsLoaded(){this._e||this.me||this.$e||this.reloadFeatureFlags()}setAnonymousDistinctId(a){this.$anon_distinct_id=a}setReloadingPaused(a){this.be=a}ke(a){var l;if(this.xe(),!this._instance.I()){if(this.me)this.ye=!0;else{var c={token:this._instance.config.token,distinct_id:this._instance.get_distinct_id(),groups:this._instance.getGroups(),$anon_distinct_id:this.$anon_distinct_id,person_properties:B({},(null==(l=this._instance.persistence)?void 0:l.get_initial_props())||{},this._instance.get_property(e4)||{}),group_properties:this._instance.get_property(e5)};(null!=a&&a.disableFlags||this._instance.config.advanced_disable_feature_flags)&&(c.disable_flags=!0);var u=this._instance.config.__preview_remote_config,d=this._instance.config.advanced_only_evaluate_survey_feature_flags?"&only_evaluate_survey_feature_flags=true":"",p=this._instance.requestRouter.endpointFor("api",(u?"/flags/?v=2":"/flags/?v=2&config=true")+d);u&&(c.timezone=to()),this.me=!0,this._instance.Ee({method:"POST",url:p,data:c,compression:this._instance.config.disable_compression?void 0:ew.Base64,timeout:this._instance.config.feature_flag_request_timeout_ms,callback:a=>{var l,u,d,p=!0;200===a.statusCode&&(this.ye||(this.$anon_distinct_id=void 0),p=!1),this.me=!1,this.we||(this.we=!0,this._instance.Ie(null!==(d=a.json)&&void 0!==d?d:{})),(!c.disable_flags||this.ye)&&((this.Se=!p,a.json&&null!=(u=a.json.quotaLimited)&&u.includes(rz.FeatureFlags))?rN.warn("You have hit your feature flags quota limit, and will not be able to load feature flags until the quota is reset. Please visit https://posthog.com/docs/billing/limits-alerts to learn more."):(c.disable_flags||this.receivedFeatureFlags(null!==(l=a.json)&&void 0!==l?l:{},p),this.ye&&(this.ye=!1,this.ke())))}})}}}getFeatureFlag(a,l){if(void 0===l&&(l={}),this._e||this.getFlags()&&this.getFlags().length>0){var c=this.getFlagVariants()[a],u=""+c,d=this._instance.get_property(rq)||void 0,p=this._instance.get_property(e7)||{};if((l.send_event||!("send_event"in l))&&(!(a in p)||!p[a].includes(u))){eC(p[a])?p[a].push(u):p[a]=[u],null==(v=this._instance.persistence)||v.register({[e7]:p});var g=this.getFeatureFlagDetails(a),f={$feature_flag:a,$feature_flag_response:c,$feature_flag_payload:this.getFeatureFlagPayload(a)||null,$feature_flag_request_id:d,$feature_flag_bootstrapped_response:(null==(_=this._instance.config.bootstrap)||null==(_=_.featureFlags)?void 0:_[a])||null,$feature_flag_bootstrapped_payload:(null==(w=this._instance.config.bootstrap)||null==(w=w.featureFlagPayloads)?void 0:w[a])||null,$used_bootstrap_value:!this.Se};R(null==g||null==(x=g.metadata)?void 0:x.version)||(f.$feature_flag_version=g.metadata.version);var v,_,w,x,k,S,$,N,z,U,W=null!==(k=null==g||null==(S=g.reason)?void 0:S.description)&&void 0!==k?k:null==g||null==($=g.reason)?void 0:$.code;W&&(f.$feature_flag_reason=W),null!=g&&null!=(N=g.metadata)&&N.id&&(f.$feature_flag_id=g.metadata.id),R(null==g?void 0:g.original_variant)&&R(null==g?void 0:g.original_enabled)||(f.$feature_flag_original_response=R(g.original_variant)?g.original_enabled:g.original_variant),null!=g&&null!=(z=g.metadata)&&z.original_payload&&(f.$feature_flag_original_payload=null==g||null==(U=g.metadata)?void 0:U.original_payload),this._instance.capture("$feature_flag_called",f)}return c}rN.warn('getFeatureFlag for key "'+a+"\" failed. Feature flags didn't load in time.")}getFeatureFlagDetails(a){return this.getFlagsWithDetails()[a]}getFeatureFlagPayload(a){return this.getFlagPayloads()[a]}getRemoteConfigPayload(a,l){var c=this._instance.config.token;this._instance.Ee({method:"POST",url:this._instance.requestRouter.endpointFor("api","/flags/?v=2&config=true"),data:{distinct_id:this._instance.get_distinct_id(),token:c}
1,compression:this._instance.config.disable_compression?void 0:ew.Base64,timeout:this._instance.config.feature_flag_request_timeout_ms,callback:c=>{var u,d=null==(u=c.json)?void 0:u.featureFlagPayloads;l((null==d?void 0:d[a])||void 0)}})}isFeatureEnabled(a,l){if(void 0===l&&(l={}),this._e||this.getFlags()&&this.getFlags().length>0)return!!this.getFeatureFlag(a,l);rN.warn('isFeatureEnabled for key "'+a+"\" failed. Feature flags didn't load in time.")}addFeatureFlagsHandler(a){this.featureFlagEventHandlers.push(a)}removeFeatureFlagsHandler(a){this.featureFlagEventHandlers=this.featureFlagEventHandlers.filter(l=>l!==a)}receivedFeatureFlags(a,l){if(this._instance.persistence){this._e=!0;var c=this.getFlagVariants(),u=this.getFlagPayloads(),d=this.getFlagsWithDetails();!function(a,l,c,u,d){void 0===c&&(c={}),void 0===u&&(u={}),void 0===d&&(d={});var p=ho(a),g=p.flags,f=p.featureFlags,v=p.featureFlagPayloads;if(f){var _=a.requestId;if(eC(f)){rN.warn("v1 of the feature flags endpoint is deprecated. Please use the latest version.");var w={};if(f)for(var x=0;x<f.length;x++)w[f[x]]=!0;l&&l.register({[rL]:f,[e1]:w})}else{var k=f,S=v,$=g;a.errorsWhileComputingFlags&&(k=B({},c,k),S=B({},u,S),$=B({},d,$)),l&&l.register(B({[rL]:Object.keys(uo(k)),[e1]:k||{},[rB]:S||{},[e3]:$||{}},_?{[rq]:_}:{}))}}}(a,this._instance.persistence,c,u,d),this.Pe(l)}}override(a,l){void 0===l&&(l=!1),rN.warn("override is deprecated. Please use overrideFeatureFlags instead."),this.overrideFeatureFlags({flags:a,suppressWarning:l})}overrideFeatureFlags(a){if(!this._instance.__loaded||!this._instance.persistence)return rN.uninitializedWarning("posthog.featureFlags.overrideFeatureFlags");if(!1===a)return this._instance.persistence.unregister(rD),this._instance.persistence.unregister(rH),void this.Pe();if(a&&"object"==typeof a&&("flags"in a||"payloads"in a)){var l;if(this.ge=!!(null!==(l=a.suppressWarning)&&void 0!==l&&l),"flags"in a){if(!1===a.flags)this._instance.persistence.unregister(rD);else if(a.flags){if(eC(a.flags)){for(var c={},u=0;u<a.flags.length;u++)c[a.flags[u]]=!0;this._instance.persistence.register({[rD]:c})}else this._instance.persistence.register({[rD]:a.flags})}}return"payloads"in a&&(!1===a.payloads?this._instance.persistence.unregister(rH):a.payloads&&this._instance.persistence.register({[rH]:a.payloads})),void this.Pe()}this.Pe()}onFeatureFlags(a){if(this.addFeatureFlagsHandler(a),this._e){var{flags:l,flagVariants:c}=this.Re();a(l,c)}return()=>this.removeFeatureFlagsHandler(a)}updateEarlyAccessFeatureEnrollment(a,l){var c,u=(this._instance.get_property(e2)||[]).find(l=>l.flagKey===a),d={["$feature_enrollment/"+a]:l},p={$feature_flag:a,$feature_enrollment:l,$set:d};u&&(p.$early_access_feature_name=u.name),this._instance.capture("$feature_enrollment_update",p),this.setPersonPropertiesForFlags(d,!1);var g=B({},this.getFlagVariants(),{[a]:l});null==(c=this._instance.persistence)||c.register({[rL]:Object.keys(uo(g)),[e1]:g}),this.Pe()}getEarlyAccessFeatures(a,l,c){void 0===l&&(l=!1);var u=this._instance.get_property(e2),d=c?"&"+c.map(a=>"stage="+a).join("&"):"";if(u&&!l)return a(u);this._instance.Ee({url:this._instance.requestRouter.endpointFor("api","/api/early_access_features/?token="+this._instance.config.token+d),method:"GET",callback:l=>{var c;if(l.json){var u=l.json.earlyAccessFeatures;return null==(c=this._instance.persistence)||c.register({[e2]:u}),a(u)}}})}Re(){var a=this.getFlags(),l=this.getFlagVariants();return{flags:a.filter(a=>l[a]),flagVariants:Object.keys(l).filter(a=>l[a]).reduce((a,c)=>(a[c]=l[c],a),{})}}Pe(a){var{flags:l,flagVariants:c}=this.Re();this.featureFlagEventHandlers.forEach(u=>u(l,c,{errorsLoading:a}))}setPersonPropertiesForFlags(a,l){void 0===l&&(l=!0);var c=this._instance.get_property(e4)||{};this._instance.register({[e4]:B({},c,a)}),l&&this._instance.reloadFeatureFlags()}resetPersonPropertiesForFlags(){this._instance.unregister(e4)}setGroupPropertiesForFlags(a,l){void 0===l&&(l=!0);var c=this._instance.get_property(e5)||{};0!==Object.keys(c).length&&Object.keys(c).forEach(l=>{c[l]=B({},c[l],a[l]),delete a[l]}),this._instance.register({[e5]:B({},c,a)}),l&&this._instance.reloadFeatureFlags()}resetGroupPropertiesForFlags(a){if(a){var l=this._instance.get_property(e5)||{};this._instance.register({[e5]:B({},l,{[a]:{}})})}else this._instance.unregister(e5)}reset(){this._e=!1,this.me=!1,this.be=!1,this.ye=!1,this.we=!1,this.Se=!1,this.$anon_distinct_id=void 0,this.xe(),this.ge=!1}};var rU=["cookie","localstorage","localstorage+cookie","sessionstorage","memory"];let po=class po{constructor(a){var l;this.S=a,this.props={},this.Te=!1,this.Me=(l="",a.token&&(l=a.token.replace(/\+/g,"PL").replace(/\//g,"SL").replace(/=/g,"EQ")),a.persistence_name?"ph_"+a.persistence_name:"ph_"+l+"_posthog"),this.B=this.Ce(a),this.load(),a.debug&&eR.info("Persistence loaded",a.persistence,B({},this.props)),this.update_config(a,a),this.save()}Ce(a){-1===rU.indexOf(a.persistence.toLowerCase())&&(eR.critical("Unknown persistence type "+a.persistence+"; falling back to localStorage+cookie"),a.persistence="localStorage+cookie");var l=a.persistence.toLowerCase();return"localstorage"===l&&tP.O()?tP:"localstorage+cookie"===l&&tO.O()?tO:"sessionstorage"===l&&tA.O()?tA:"memory"===l?t$:"cookie"===l?tC:tO.O()?tO:tC}properties(){var a={};
1return J(this.props,function(l,c){if(c===e1&&I(l))for(var u,d=Object.keys(l),p=0;p<d.length;p++)a["$feature/"+d[p]]=l[d[p]];else u=!1,(C(th)?u:ec&&th.indexOf===ec?-1!=th.indexOf(c):(J(th,function(a){if(u||(u=a===c))return eO}),u))||(a[c]=l)}),a}load(){if(!this.Fe){var a=this.B.L(this.Me);a&&(this.props=V({},a))}}save(){this.Fe||this.B.j(this.Me,this.props,this.Oe,this.Ae,this.De,this.S.debug)}remove(){this.B.N(this.Me,!1),this.B.N(this.Me,!0)}clear(){this.remove(),this.props={}}register_once(a,l,c){if(I(a)){R(l)&&(l="None"),this.Oe=R(c)?this.Le:c;var u=!1;if(J(a,(a,c)=>{this.props.hasOwnProperty(c)&&this.props[c]!==l||(this.props[c]=a,u=!0)}),u)return this.save(),!0}return!1}register(a,l){if(I(a)){this.Oe=R(l)?this.Le:l;var c=!1;if(J(a,(l,u)=>{a.hasOwnProperty(u)&&this.props[u]!==l&&(this.props[u]=l,c=!0)}),c)return this.save(),!0}return!1}unregister(a){a in this.props&&(delete this.props[a],this.save())}update_campaign_params(){if(!this.Te){var a=Jn(this.S.custom_campaign_params,this.S.mask_personal_data_properties,this.S.custom_personal_data_properties);P(Z(a))||this.register(a),this.Te=!0}}update_search_keyword(){var a;this.register((a=null==ed?void 0:ed.referrer)?Kn(a):{})}update_referrer_info(){var a;this.register_once({$referrer:Xn(),$referring_domain:null!=ed&&ed.referrer&&(null==(a=wi(ed.referrer))?void 0:a.host)||"$direct"},void 0)}set_initial_person_info(){this.props[tr]||this.props[tn]||this.register_once({[tl]:Qn(this.S.mask_personal_data_properties,this.S.custom_personal_data_properties)},void 0)}get_initial_props(){var a={};J([tn,tr],l=>{var c=this.props[l];c&&J(c,function(l,c){a["$initial_"+y(c)]=l})});var l,c,u=this.props[tl];return u&&V(a,(l=Zn(u),c={},J(l,function(a,l){c["$initial_"+y(l)]=a}),c)),a}safe_merge(a){return J(this.props,function(l,c){c in a||(a[c]=l)}),a}update_config(a,l){if(this.Le=this.Oe=a.cookie_expiration,this.set_disabled(a.disable_persistence),this.set_cross_subdomain(a.cross_subdomain_cookie),this.set_secure(a.secure_cookie),a.persistence!==l.persistence){var c=this.Ce(a),u=this.props;this.clear(),this.B=c,this.props=u,this.save()}}set_disabled(a){this.Fe=a,this.Fe?this.remove():this.save()}set_cross_subdomain(a){a!==this.Ae&&(this.Ae=a,this.remove(),this.save())}set_secure(a){a!==this.De&&(this.De=a,this.remove(),this.save())}set_event_timer(a,l){var c=this.props[eA]||{};c[a]=l,this.props[eA]=c,this.save()}remove_event_timer(a){var l=(this.props[eA]||{})[a];return R(l)||(delete this.props[eA][a],this.save()),l}get_property(a){return this.props[a]}set_property(a,l){this.props[a]=l,this.save()}};let go=class go{constructor(){this.je={},this.je={}}on(a,l){return this.je[a]||(this.je[a]=[]),this.je[a].push(l),()=>{this.je[a]=this.je[a].filter(a=>a!==l)}}emit(a,l){for(var c of this.je[a]||[])c(l);for(var u of this.je["*"]||[])u(a,l)}};let _o=class _o{constructor(a){this.Ne=new go,this.ze=(a,l)=>this.Ue(a,l)&&this.qe(a,l)&&this.Be(a,l),this.Ue=(a,l)=>null==l||!l.event||(null==a?void 0:a.event)===(null==l?void 0:l.event),this._instance=a,this.He=new Set,this.We=new Set}init(){var a,l;R(null==(a=this._instance)?void 0:a.Ge)||null==(l=this._instance)||l.Ge((a,l)=>{this.on(a,l)})}register(a){var l,c;if(!R(null==(l=this._instance)?void 0:l.Ge)&&(a.forEach(a=>{var l,c;null==(l=this.We)||l.add(a),null==(c=a.steps)||c.forEach(a=>{var l;null==(l=this.He)||l.add((null==a?void 0:a.event)||"")})}),null!=(c=this._instance)&&c.autocapture)){var u,d=new Set;a.forEach(a=>{var l;null==(l=a.steps)||l.forEach(a=>{null!=a&&a.selector&&d.add(null==a?void 0:a.selector)})}),null==(u=this._instance)||u.autocapture.setElementSelectors(d)}}on(a,l){var c;null!=l&&0!=a.length&&(this.He.has(a)||this.He.has(null==l?void 0:l.event))&&this.We&&(null==(c=this.We)?void 0:c.size)>0&&this.We.forEach(a=>{this.Je(l,a)&&this.Ne.emit("actionCaptured",a.name)})}Ve(a){this.onAction("actionCaptured",l=>a(l))}Je(a,l){if(null==(null==l?void 0:l.steps))return!1;for(var c of l.steps)if(this.ze(a,c))return!0;return!1}onAction(a,l){return this.Ne.on(a,l)}qe(a,l){if(null!=l&&l.url){var c,u=null==a||null==(c=a.properties)?void 0:c.$current_url;if(!u||"string"!=typeof u||!_o.Ke(u,null==l?void 0:l.url,(null==l?void 0:l.url_matching)||"contains"))return!1}return!0}static Ke(a,l,c){switch(c){case"regex":return!!en&&Ns(a,l);case"exact":return l===a;case"contains":return Ns(a,_o.Ye(l).replace(/_/g,".").replace(/%/g,".*"));default:return!1}}static Ye(a){return a.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}Be(a,l){if((null!=l&&l.href||null!=l&&l.tag_name||null!=l&&l.text)&&!this.Xe(a).some(a=>!(null!=l&&l.href&&!_o.Ke(a.href||"",null==l?void 0:l.href,(null==l?void 0:l.href_matching)||"exact"))&&(null==l||!l.tag_name||a.tag_name===(null==l?void 0:l.tag_name))&&
1!(null!=l&&l.text&&!_o.Ke(a.text||"",null==l?void 0:l.text,(null==l?void 0:l.text_matching)||"exact")&&!_o.Ke(a.$el_text||"",null==l?void 0:l.text,(null==l?void 0:l.text_matching)||"exact"))))return!1;if(null!=l&&l.selector){var c,u=null==a||null==(c=a.properties)?void 0:c.$element_selectors;if(!u||!u.includes(null==l?void 0:l.selector))return!1}return!0}Xe(a){return null==(null==a?void 0:a.properties.$elements)?[]:null==a?void 0:a.properties.$elements}};var rG=eP("[Surveys]"),rV="seenSurvey_",yo=(a,l)=>{var c="$survey_"+l+"/"+a.id;return a.current_iteration&&a.current_iteration>0&&(c="$survey_"+l+"/"+a.id+"/"+a.current_iteration),c};let wo=class wo{constructor(a){this._instance=a,this.Qe=new Map,this.Ze=new Map}register(a){var l;R(null==(l=this._instance)?void 0:l.Ge)||(this.tr(a),this.ir(a))}ir(a){var l=a.filter(a=>{var l,c;return(null==(l=a.conditions)?void 0:l.actions)&&(null==(c=a.conditions)||null==(c=c.actions)||null==(c=c.values)?void 0:c.length)>0});0!==l.length&&(null==this.er&&(this.er=new _o(this._instance),this.er.init(),this.er.Ve(a=>{this.onAction(a)})),l.forEach(a=>{var l,c,u,d,p;a.conditions&&null!=(l=a.conditions)&&l.actions&&null!=(c=a.conditions)&&null!=(c=c.actions)&&c.values&&(null==(u=a.conditions)||null==(u=u.actions)||null==(u=u.values)?void 0:u.length)>0&&(null==(d=this.er)||d.register(a.conditions.actions.values),null==(p=a.conditions)||null==(p=p.actions)||null==(p=p.values)||p.forEach(l=>{if(l&&l.name){var c=this.Ze.get(l.name);c&&c.push(a.id),this.Ze.set(l.name,c||[a.id])}}))}))}tr(a){var l;0!==a.filter(a=>{var l,c;return(null==(l=a.conditions)?void 0:l.events)&&(null==(c=a.conditions)||null==(c=c.events)||null==(c=c.values)?void 0:c.length)>0}).length&&(null==(l=this._instance)||l.Ge((a,l)=>{this.onEvent(a,l)}),a.forEach(a=>{var l;null==(l=a.conditions)||null==(l=l.events)||null==(l=l.values)||l.forEach(l=>{if(l&&l.name){var c=this.Qe.get(l.name);c&&c.push(a.id),this.Qe.set(l.name,c||[a.id])}})}))}onEvent(a,l){var c,u=(null==(c=this._instance)||null==(c=c.persistence)?void 0:c.props[e8])||[];if("survey shown"===a&&l&&u.length>0){rG.info("survey event matched, removing survey from activated surveys",{event:a,eventPayload:l,existingActivatedSurveys:u});var d,p=null==l||null==(d=l.properties)?void 0:d.$survey_id;if(p){var g=u.indexOf(p);g>=0&&(u.splice(g,1),this.rr(u))}}else this.Qe.has(a)&&(rG.info("survey event matched, updating activated surveys",{event:a,surveys:this.Qe.get(a)}),this.rr(u.concat(this.Qe.get(a)||[])))}onAction(a){var l,c=(null==(l=this._instance)||null==(l=l.persistence)?void 0:l.props[e8])||[];this.Ze.has(a)&&this.rr(c.concat(this.Ze.get(a)||[]))}rr(a){var l;null==(l=this._instance)||null==(l=l.persistence)||l.register({[e8]:[...new Set(a
1)]})}getSurveys(){var a;return(null==(a=this._instance)||null==(a=a.persistence)?void 0:a.props[e8])||[]}getEventToSurveys(){return this.Qe}sr(){return this.er}};let So=class So{constructor(a){this.nr=void 0,this.ar=null,this.lr=!1,this.ur=!1,this.hr=[],this._instance=a,this._surveyEventReceiver=null}onRemoteConfig(a){var l=a.surveys;if(F(l))return rG.warn("Flags not loaded yet. Not loading surveys.");var c=eC(l);this.nr=c?l.length>0:l,rG.info("flags response received, isSurveysEnabled: "+this.nr),this.loadIfEnabled()}reset(){localStorage.removeItem("lastSeenSurveyDate");for(var a=[],l=0;l<localStorage.length;l++){var c=localStorage.key(l);(null!=c&&c.startsWith(rV)||null!=c&&c.startsWith("inProgressSurvey_"))&&a.push(c)}a.forEach(a=>localStorage.removeItem(a))}loadIfEnabled(){if(!this.ar){if(this.ur)rG.info("Already initializing surveys, skipping...");else if(this._instance.config.disable_surveys)rG.info("Disabled. Not loading surveys.");else{var a=null==e_?void 0:e_.__PosthogExtensions__;if(a){var l=this.nr;if(!R(l)){this.ur=!0;try{var c=a.generateSurveys;if(c)return void this.dr(c,l);var u=a.loadExternalDependency;if(!u)return void this.vr("PostHog loadExternalDependency extension not found.");u(this._instance,"surveys",c=>{c||!a.generateSurveys?this.vr("Could not load surveys script",c):this.dr(a.generateSurveys,l)})}catch(a){throw this.vr("Error initializing surveys",a),a}finally{this.ur=!1}}}else rG.error("PostHog Extensions not found.")}}}dr(a,l){this.ar=a(this._instance,l),this._surveyEventReceiver=new wo(this._instance),rG.info("Surveys loaded successfully"),this.cr({isLoaded:!0})}vr(a,l){rG.error(a,l),this.cr({isLoaded:!1,error:a})}onSurveysLoaded(a){return this.hr.push(a),this.ar&&this.cr({isLoaded:!0}),()=>{this.hr=this.hr.filter(l=>l!==a)}}getSurveys(a,l){if(void 0===l&&(l=!1),this._instance.config.disable_surveys)return rG.info("Disabled. Not loading surveys."),a([]);var c=this._instance.get_property(e6);if(c&&!l)return a(c,{isLoaded:!0});if(this.lr)return a([],{isLoaded:!1,error:"Surveys are already being loaded"});try{this.lr=!0,this._instance.Ee({url:this._instance.requestRouter.endpointFor("api","/api/surveys/?token="+this._instance.config.token),method:"GET",timeout:this._instance.config.surveys_request_timeout_ms,callback:l=>{this.lr=!1;var c=l.statusCode;if(200!==c||!l.json){var u="Surveys API could not be loaded, status: "+c;return rG.error(u),a([],{isLoaded:!1,error:u})}var d,p,g=l.json.surveys||[],f=g.filter(a=>{var l,c;return!(!a.start_date||a.end_date)&&(!(null==(l=a.conditions)||null==(l=l.events)||null==(l=l.values)||!l.length)||!(null==(c=a.conditions)||null==(c=c.actions)||null==(c=c.values)||!c.length))});return f.length>0&&(null==(p=this._surveyEventReceiver)||p.register(f)),null==(d=this._instance.persistence)||d.register({[e6]:g}),a(g,{isLoaded:!0})}})}catch(a){throw this.lr=!1,a}}cr(a){for(var l of this.hr)try{a.isLoaded?this.getSurveys(l):l([],a)}catch(a){rG.error("Error in survey callback",a)}}getActiveMatchingSurveys(a,l){if(void 0===l&&(l=!1),!F(this.ar))return this.ar.getActiveMatchingSurveys(a,l);rG.warn("init was not called")}pr(a){var l=null;return this.getSurveys(c=>{var u;l=null!==(u=c.find(l=>l.id===a))&&void 0!==u?u:null}),l}gr(a){if(F(this.ar))return{eligible:!1,reason:"SDK is not enabled or survey functionality is not yet loaded"};var l="string"==typeof a?this.pr(a):a;return l?this.ar.checkSurveyEligibility(l):{eligible:!1,reason:"Survey not found"}}canRenderSurvey(a){if(F(this.ar))return rG.warn("init was not called"),{visible:!1,disabledReason:"SDK is not enabled or survey functionality is not yet loaded"};var l=this.gr(a);return{visible:l.eligible,disabledReason:l.reason}}canRenderSurveyAsync(a,l){return F(this.ar)?(rG.warn("init was not called"),Promise.resolve({visible:!1,disabledReason:"SDK is not enabled or survey functionality is not yet loaded"})):new Promise(c=>{this.getSurveys(l=>{var u,d=null!==(u=l.find(l=>l.id===a))&&void 0!==u?u:null;if(d){var p=this.gr(d);c({visible:p.eligible,disabledReason:p.reason})}else c({visible:!1,disabledReason:"Survey not found"})},l)})}renderSurvey(a,l){if(F(this.ar))rG.warn("init was not called");else{var c=this.pr(a),u=null==ed?void 0:ed.querySelector(l);
1c?u?this.ar.renderSurvey(c,u):rG.warn("Survey element not found"):rG.warn("Survey not found")}}};(so={}).Button="button",so.Tab="tab",so.Selector="selector",(sa={}).TopLeft="top_left",sa.TopRight="top_right",sa.TopCenter="top_center",sa.MiddleLeft="middle_left",sa.MiddleRight="middle_right",sa.MiddleCenter="middle_center",sa.Left="left",sa.Center="center",sa.Right="right",sa.NextToTrigger="next_to_trigger",(sl={}).Popover="popover",sl.API="api",sl.Widget="widget",(sc={}).Open="open",sc.MultipleChoice="multiple_choice",sc.SingleChoice="single_choice",sc.Rating="rating",sc.Link="link",(su={}).NextQuestion="next_question",su.End="end",su.ResponseBased="response_based",su.SpecificQuestion="specific_question",(sd={}).Once="once",sd.Recurring="recurring",sd.Always="always";var rW=((sh={}).SHOWN="survey shown",sh.DISMISSED="survey dismissed",sh.SENT="survey sent",sh),rJ=((sp={}).SURVEY_ID="$survey_id",sp.SURVEY_NAME="$survey_name",sp.SURVEY_RESPONSE="$survey_response",sp.SURVEY_ITERATION="$survey_iteration",sp.SURVEY_ITERATION_START_DATE="$survey_iteration_start_date",sp.SURVEY_PARTIALLY_COMPLETED="$survey_partially_completed",sp.SURVEY_SUBMISSION_ID="$survey_submission_id",sp.SURVEY_QUESTIONS="$survey_questions",sp.SURVEY_COMPLETED="$survey_completed",sp),rY=eP("[RateLimiter]");let Co=class Co{constructor(a){var l,c;this.serverLimits={},this.lastEventRateLimited=!1,this.checkForLimiting=a=>{var l=a.text;if(l&&l.length)try{(JSON.parse(l).quota_limited||[]).forEach(a=>{rY.info((a||"events")+" is quota limited."),this.serverLimits[a]=(new Date).getTime()+6e4})}catch(a){return void rY.warn('could not rate limit - continuing. Error: "'+(null==a?void 0:a.message)+'"',{text:l})}},this.instance=a,this.captureEventsPerSecond=(null==(l=a.config.rate_limiting)?void 0:l.events_per_second)||10,this.captureEventsBurstLimit=Math.max((null==(c=a.config.rate_limiting)?void 0:c.events_burst_limit)||10*this.captureEventsPerSecond,this.captureEventsPerSecond),this.lastEventRateLimited=this.clientRateLimitContext(!0).isRateLimited}clientRateLimitContext(a){void 0===a&&(a=!1);var l,c,u,d=(new Date).getTime(),p=null!==(l=null==(c=this.instance.persistence)?void 0:c.get_property(tt))&&void 0!==l?l:{tokens:this.captureEventsBurstLimit,last:d};p.tokens+=(d-p.last)/1e3*this.captureEventsPerSecond,p.last=d,p.tokens>this.captureEventsBurstLimit&&(p.tokens=this.captureEventsBurstLimit);var g=p.tokens<1;return g||a||(p.tokens=Math.max(0,p.tokens-1)),!g||this.lastEventRateLimited||a||this.instance.capture("$$client_ingestion_warning",{$$client_ingestion_warning_message:"posthog-js client rate limited. Config is set to "+this.captureEventsPerSecond+" events per second and "+this.captureEventsBurstLimit+" events burst limit."},{skip_client_rate_limiting:!0}),this.lastEventRateLimited=g,null==(u=this.instance.persistence)||u.set_property(tt,p),{isRateLimited:g,remainingTokens:p.tokens}}isServerRateLimited(a){var l=this.serverLimits[a||"events"]||!1;return!1!==l&&(new Date).getTime()<l}};var rK=eP("[RemoteConfig]");let Oo=class Oo{constructor(a){this._instance=a}get remoteConfig(){var a;return null==(a=e_._POSTHOG_REMOTE_CONFIG)||null==(a=a[this._instance.config.token])?void 0:a.config}_r(a){var l,c;null!=(l=e_.__PosthogExtensions__)&&l.loadExternalDependency?null==(c=e_.__PosthogExtensions__)||null==c.loadExternalDependency||c.loadExternalDependency(this._instance,"remote-config",()=>a(this.remoteConfig)):(rK.error("PostHog Extensions not found. Cannot load remote config."),a())}mr(a){this._instance.Ee({method:"GET",url:this._instance.requestRouter.endpointFor("assets","/array/"+this._instance.config.token+"/config"),callback:l=>{a(l.json)}})}load(){try{if(this.remoteConfig)return rK.info("Using preloaded remote config",this.remoteConfig),void this.Ie(this.remoteConfig);if(this._instance.I())return void rK.warn("Remote config is disabled. Falling back to local config.");this._r(a=>{if(!a)return rK.info("No config found after loading remote JS config. Falling back to JSON."),void this.mr(a=>{this.Ie(a)});this.Ie(a)})}catch(a){rK.error("Error loading remote config",a)}}Ie(a){a?this._instance.config.__preview_remote_config?(this._instance.Ie(a),!1!==a.hasFeatureFlags&&this._instance.featureFlags.ensureFlagsLoaded()):rK.info("__preview_remote_config is disabled. Logging config instead",a):rK.error("Failed to fetch remote config from PostHog.")}};let Do=class Do{constructor(a,l){this.br=!0,this.yr=[],this.wr=se((null==l?void 0:l.flush_interval_ms)||3e3,250,5e3,"flush interval",3e3),this.Sr=a}enqueue(a){this.yr.push(a),this.$r||this.kr()}unload(){this.Er();var a=Object.values(this.yr.length>0?this.Ir():{});[...a.filter(a=>0===a.url.indexOf("/e")),...a.filter(a=>0!==a.url.indexOf("/e"))].map(a=>{this.Sr(B({},a,{transport:"sendBeacon"}))})}enable(){this.br=!1,this.kr()}kr(){var a=this;this.br||(this.$r=setTimeout(()=>{if(this.Er(),this.yr.length>0){var l=this.Ir();for(var c in l)!function(){var u=l[c],d=(new Date).getTime();u.data&&eC(u.data)&&J(u.data,a=>{a.offset=Math.abs(a.timestamp-d),delete a.timestamp}),a.Sr(u)}()}},this.wr))}Er(){clearTimeout(this.$r),this.$r=void 0}Ir(){var a={};return J(this.yr,l=>{var c,u=(l?l.batchKey:null)||l.url;R(a[u])&&(a[u]=B({},l,{data:[]})),null==(c=a[u].data)||c.push(l.data)}),this.yr=[],a}};var rZ=["retriesPerformedSoFar"];let jo=class jo{constructor(a){this.Pr=!1,this.Rr=3e3,this.yr=[],this._instance=a,this.yr=[],this.Tr=!0,!R(en)&&"onLine"in en.navigator&&(this.Tr=en.navigator.onLine,st(en,"online",()=>{this.Tr=!0,this.se()}),st(en,"offline",()=>{this.Tr=!1}))}get length(){return this.yr.length}retriableRequest(a){var{retriesPerformedSoFar:l}=a,c=H(a,rZ);O(l)&&l>0&&(c.url=As(c.url,{retry_count:l})),this._instance.Ee(B({},c,{callback:a=>{200!==a.statusCode&&(a.statusCode<400||a.statusCode>=500)&&(null!=l?l:0)<10?this.Mr(B({retriesPerformedSoFar:l},c)):null==c.callback||c.callback(a)}}))}Mr(a){var l,c,u,d=a.retriesPerformedSoFar||0;a.retriesPerformedSoFar=d+1;var p=(u=(Math.random()-.5)*((c=Math.min(18e5,l=3e3*Math.pow(2,d)))-l/2),Math.ceil(c+u)),g=Date.now()+p;this.yr.push({retryAt:g,requestOptions:a});var f="Enqueued failed request for retry in "+p;navigator.onLine||(f+=" (Browser is offline)"),eR.warn(f),this.Pr||(this.Pr=!0,this.Cr())}Cr(){this.Fr&&clearTimeout(this.Fr),this.Fr=setTimeout(()=>{this.Tr&&this.yr.length>0&&this.se(),this.Cr()},this.Rr)}se(){var a=Date.now(),l=[],c=this.yr.filter(c=>c.retryAt<a||(l.push(c),!1));if(this.yr=l,c.length>0)for(var{requestOptions:u}of c)this.retriableRequest(u)}unload(){for(var{requestOptions:a}of(this.Fr&&(clearTimeout(this.Fr),this.Fr=void 0),this.yr))try{this._instance.Ee(B({},a,{transport:"sendBeacon"}))}catch(a){eR.error(a)}this.yr=[]}};let No=class No{constructor(a){this.Or=()=>{this.Ar||(this.Ar={});var a,l,c,u,d=this.scrollElement(),p=this.scrollY(),g=d?Math.max(0,d.scrollHeight-d.clientHeight):0,f=p+((null==d?void 0:d.clientHeight)||0),v=(null==d?void 0:d.scrollHeight)||0;this.Ar.lastScrollY=Math.ceil(p),this.Ar.maxScrollY=Math.max(p,null!==(a=this.Ar.maxScrollY)&&void 0!==a?a:0),this.Ar.maxScrollHeight=Math.max(g,null!==(l=this.Ar.maxScrollHeight)&&void 0!==l?l:0),this.Ar.last
1ContentY=f,this.Ar.maxContentY=Math.max(f,null!==(c=this.Ar.maxContentY)&&void 0!==c?c:0),this.Ar.maxContentHeight=Math.max(v,null!==(u=this.Ar.maxContentHeight)&&void 0!==u?u:0)},this._instance=a}getContext(){return this.Ar}resetContext(){var a=this.Ar;return setTimeout(this.Or,0),a}startMeasuringScrollPosition(){st(en,"scroll",this.Or,{capture:!0}),st(en,"scrollend",this.Or,{capture:!0}),st(en,"resize",this.Or)}scrollElement(){if(!this._instance.config.scroll_root_selector)return null==en?void 0:en.document.documentElement;for(var a of eC(this._instance.config.scroll_root_selector)?this._instance.config.scroll_root_selector:[this._instance.config.scroll_root_selector]){var l=null==en?void 0:en.document.querySelector(a);if(l)return l}}scrollY(){if(this._instance.config.scroll_root_selector){var a=this.scrollElement();return a&&a.scrollTop||0}return en&&(en.scrollY||en.pageYOffset||en.document.documentElement.scrollTop)||0}scrollX(){if(this._instance.config.scroll_root_selector){var a=this.scrollElement();return a&&a.scrollLeft||0}return en&&(en.scrollX||en.pageXOffset||en.document.documentElement.scrollLeft)||0}};var zo=a=>Qn(null==a?void 0:a.config.mask_personal_data_properties,null==a?void 0:a.config.custom_personal_data_properties);let Uo=class Uo{constructor(a,l,c,u){this.Dr=a=>{var l=this.Lr();if(!l||l.sessionId!==a){var c={sessionId:a,props:this.jr(this._instance)};this.Nr.register({[te]:c})}},this._instance=a,this.zr=l,this.Nr=c,this.jr=u||zo,this.zr.onSessionId(this.Dr)}Lr(){return this.Nr.props[te]}getSetOnceProps(){var a,l=null==(a=this.Lr())?void 0:a.props;return l?"r"in l?Zn(l):{$referring_domain:l.referringDomain,$pathname:l.initialPathName,utm_source:l.utm_source,utm_campaign:l.utm_campaign,utm_medium:l.utm_medium,utm_content:l.utm_content,utm_term:l.utm_term}:{}}getSessionProps(){var a={};return J(Z(this.getSetOnceProps()),(l,c)=>{"$current_url"===c&&(c="url"),a["$session_entry_"+y(c)]=l}),a}};var rX=eP("[SessionId]");let Bo=class Bo{constructor(a,l,c){if(this.Ur=[],!a.persistence)throw Error("SessionIdManager requires a PostHogPersistence instance");if(a.config.__preview_experimental_cookieless_mode)throw Error("SessionIdManager cannot be used with __preview_experimental_cookieless_mode");this.S=a.config,this.Nr=a.persistence,this.fi=void 0,this.Ct=void 0,this._sessionStartTimestamp=null,this._sessionActivityTimestamp=null,this.qr=l||ji,this.Br=c||ji;var u,d=this.S.persistence_name||this.S.token,p=this.S.session_idle_timeout_seconds||1800;if(this._sessionTimeoutMs=1e3*se(p,60,36e3,"session_idle_timeout_seconds",1800),a.register({$configured_session_timeout_ms:this._sessionTimeoutMs}),this.Hr(),this.Wr="ph_"+d+"_window_id",this.Gr="ph_"+d+"_primary_window_exists",this.Jr()){var g=tA.L(this.Wr),f=tA.L(this.Gr);g&&!f?this.fi=g:tA.N(this.Wr),tA.j(this.Gr,!0)}if(null!=(u=this.S.bootstrap)&&u.sessionID)try{var v=(a=>{var l=a.replace(/-/g,"");if(32!==l.length)throw Error("Not a valid UUID");if("7"!==l[12])throw Error("Not a UUIDv7");return parseInt(l.substring(0,12),16)})(this.S.bootstrap.sessionID);this.Vr(this.S.bootstrap.sessionID,(new Date).getTime(),v)}catch(a){rX.error("Invalid sessionID in bootstrap",a)}this.Kr()}get sessionTimeoutMs(){return this._sessionTimeoutMs}onSessionId(a){return R(this.Ur)&&(this.Ur=[]),this.Ur.push(a),this.Ct&&a(this.Ct,this.fi),()=>{this.Ur=this.Ur.filter(l=>l!==a)}}Jr(){return"memory"!==this.S.persistence&&!this.Nr.Fe&&tA.O()}Yr(a){a!==this.fi&&(this.fi=a,this.Jr()&&tA.j(this.Wr,a))}Xr(){return this.fi?this.fi:this.Jr()?tA.L(this.Wr):null}Vr(a,l,c){a===this.Ct&&l===this._sessionActivityTimestamp&&c===this._sessionStartTimestamp||(this._sessionStartTimestamp=c,this._sessionActivityTimestamp=l,this.Ct=a,this.Nr.register({[eZ]:[l,a,c]}))}Qr(){if(this.Ct&&this._sessionActivityTimestamp&&this._sessionStartTimestamp)return[this._sessionActivityTimestamp,this.Ct,this._sessionStartTimestamp];var a=this.Nr.props[eZ];return eC(a)&&2===a.length&&a.push(a[0]),a||[0,null,0]}resetSessionId(){this.Vr(null,null,null)}Kr(){st(en,"beforeunload",()=>{this.Jr()&&tA.N(this.Gr)},{capture:!1})}
1checkAndGetSessionAndWindowId(a,l){if(void 0===a&&(a=!1),void 0===l&&(l=null),this.S.__preview_experimental_cookieless_mode)throw Error("checkAndGetSessionAndWindowId should not be called in __preview_experimental_cookieless_mode");var c=l||(new Date).getTime(),[u,d,p]=this.Qr(),g=this.Xr(),f=O(p)&&p>0&&Math.abs(c-p)>864e5,v=!1,_=!d,w=!a&&Math.abs(c-u)>this.sessionTimeoutMs;_||w||f?(d=this.qr(),g=this.Br(),rX.info("new session ID generated",{sessionId:d,windowId:g,changeReason:{noSessionId:_,activityTimeout:w,sessionPastMaximumLength:f}}),p=c,v=!0):g||(g=this.Br(),v=!0);var x=0===u||!a||f?c:u,k=0===p?(new Date).getTime():p;return this.Yr(g),this.Vr(d,x,k),a||this.Hr(),v&&this.Ur.forEach(a=>a(d,g,v?{noSessionId:_,activityTimeout:w,sessionPastMaximumLength:f}:void 0)),{sessionId:d,windowId:g,sessionStartTimestamp:k,changeReason:v?{noSessionId:_,activityTimeout:w,sessionPastMaximumLength:f}:void 0,lastActivityTimestamp:u}}Hr(){clearTimeout(this.Zr),this.Zr=setTimeout(()=>{this.resetSessionId()},1.1*this.sessionTimeoutMs)}};var rQ=["$set_once","$set"],r0=eP("[SiteApps]");let Go=class Go{constructor(a){this._instance=a,this.ts=[],this.apps={}}get isEnabled(){return!!this._instance.config.opt_in_site_apps}es(a,l){if(l){var c=this.globalsForEvent(l);this.ts.push(c),this.ts.length>1e3&&(this.ts=this.ts.slice(10))}}get siteAppLoaders(){var a;return null==(a=e_._POSTHOG_REMOTE_CONFIG)||null==(a=a[this._instance.config.token])?void 0:a.siteApps}init(){if(this.isEnabled){var a=this._instance.Ge(this.es.bind(this));this.rs=()=>{a(),this.ts=[],this.rs=void 0}}}globalsForEvent(a){if(!a)throw Error("Event payload is required");var l,c,u,d,p,g,f,v={},_=this._instance.get_property("$groups")||[];for(var[w,x]of Object.entries(this._instance.get_property("$stored_group_properties")||{}))v[w]={id:_[w],type:w,properties:x};var{$set_once:k,$set:S}=a;return{event:B({},H(a,rQ),{properties:B({},a.properties,S?{$set:B({},null!==(l=null==(c=a.properties)?void 0:c.$set)&&void 0!==l?l:{},S)}:{},k?{$set_once:B({},null!==(u=null==(d=a.properties)?void 0:d.$set_once)&&void 0!==u?u:{},k)}:{}),elements_chain:null!==(p=null==(g=a.properties)?void 0:g.$elements_chain)&&void 0!==p?p:"",distinct_id:null==(f=a.properties)?void 0:f.distinct_id}),person:{properties:this._instance.get_property("$stored_person_properties")},groups:v}}setupSiteApp(a){var l=this.apps[a.id],e=()=>{var c;!l.errored&&this.ts.length&&(r0.info("Processing "+this.ts.length+" events for site app with id "+a.id),this.ts.forEach(a=>null==l.processEvent?void 0:l.processEvent(a)),l.processedBuffer=!0),Object.values(this.apps).every(a=>a.processedBuffer||a.errored)&&(null==(c=this.rs)||c.call(this))},c=!1,s=u=>{l.errored=!u,l.loaded=!0,r0.info("Site app with id "+a.id+" "+(u?"loaded":"errored")),c&&e()};try{var{processEvent:u}=a.init({posthog:this._instance,callback:a=>{s(a)}});u&&(l.processEvent=u),c=!0}catch(l){r0.error("Error while initializing PostHog app with config id "+a.id,l),s(!1)}if(c&&l.loaded)try{e()}catch(c){r0.error("Error while processing buffered events PostHog app with config id "+a.id,c),l.errored=!0}}ss(){var a=this.siteAppLoaders||[];for(var l of a)this.apps[l.id]={id:l.id,loaded:!1,errored:!1,processedBuffer:!1};for(var c of a)this.setupSiteApp(c)}ns(a){if(0!==Object.keys(this.apps).length){var l=this.globalsForEvent(a);for(var c of Object.values(this.apps))try{null==c.processEvent||c.processEvent(l)}catch(l){r0.error("Error while processing event "+a.event+" for site app "+c.id,l)}}}onRemoteConfig(a){var l,c,u,d=this;if(null!=(l=this.siteAppLoaders)&&l.length)return this.isEnabled?(this.ss(),void this._instance.on("eventCaptured",a=>this.ns(a))):void r0.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.');if(null==(c=this.rs)||c.call(this),null!=(u=a.siteApps)&&u.length){if(this.isEnabled){var n=function(a){var l;e_["__$$ph_site_app_"+a]=d._instance,null==(l=e_.__PosthogExtensions__)||null==l.loadSiteApp||l.loadSiteApp(d._instance,g,l=>{if(l)return r0.error("Error while initializing PostHog app with config id "+a,l)})};for(var{id:p,url:g}of a.siteApps)n(p)}else r0.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.')}}};var r1=["amazonbot","amazonproductbot","app.hypefactors.com","applebot","archive.org_bot","awariobot","backlinksextendedbot","baiduspider","bingbot","bingpreview","chrome-lighthouse","dataforseobot","deepscan","duckduckbot","facebookexternal","facebookcatalog","http://yandex.com/bots","hub
1spot","ia_archiver","leikibot","linkedinbot","meta-externalagent","mj12bot","msnbot","nessus","petalbot","pinterest","prerender","rogerbot","screaming frog","sebot-wa","sitebulb","slackbot","slurp","trendictionbot","turnitin","twitterbot","vercelbot","yahoo! slurp","yandexbot","zoombot","bot.htm","bot.php","(bot;","bot/","crawler","ahrefsbot","ahrefssiteaudit","semrushbot","siteauditbot","splitsignalbot","gptbot","oai-searchbot","chatgpt-user","perplexitybot","better uptime bot","sentryuptimebot","uptimerobot","headlesschrome","cypress","google-hoteladsverifier","adsbot-google","apis-google","duplexweb-google","feedfetcher-google","google favicon","google web preview","google-read-aloud","googlebot","googleother","google-cloudvertexbot","googleweblight","mediapartners-google","storebot-google","google-inspectiontool","bytespider"],Vo=function(a,l){if(!a)return!1;var c=a.toLowerCase();return r1.concat(l||[]).some(a=>{var l=a.toLowerCase();return -1!==c.indexOf(l)})},Ko=function(a,l){if(!a)return!1;var c=a.userAgent;if(c&&Vo(c,l))return!0;try{var u=null==a?void 0:a.userAgentData;if(null!=u&&u.brands&&u.brands.some(a=>Vo(null==a?void 0:a.brand,l)))return!0}catch(a){}return!!a.webdriver},r2=((sg={}).US="us",sg.EU="eu",sg.CUSTOM="custom",sg),r3="i.posthog.com";let Qo=class Qo{constructor(a){this.os={},this.instance=a}get apiHost(){var a=this.instance.config.api_host.trim().replace(/\/$/,"");return"https://app.posthog.com"===a?"https://us.i.posthog.com":a}get uiHost(){var a,l=null==(a=this.instance.config.ui_host)?void 0:a.replace(/\/$/,"");return l||(l=this.apiHost.replace("."+r3,".posthog.com")),"https://app.posthog.com"===l?"https://us.posthog.com":l}get region(){return this.os[this.apiHost]||(/https:\/\/(app|us|us-assets)(\.i)?\.posthog\.com/i.test(this.apiHost)?this.os[this.apiHost]=r2.US:/https:\/\/(eu|eu-assets)(\.i)?\.posthog\.com/i.test(this.apiHost)?this.os[this.apiHost]=r2.EU:this.os[this.apiHost]=r2.CUSTOM),this.os[this.apiHost]}endpointFor(a,l){if(void 0===l&&(l=""),l&&(l="/"===l[0]?l:"/"+l),"ui"===a)return this.uiHost+l;if(this.region===r2.CUSTOM)return this.apiHost+l;var c=r3+l;switch(a){case"assets":return"https://"+this.region+"-assets."+c;case"api":return"https://"+this.region+"."+c}}};var r4={icontains:(a,l)=>!!en&&l.href.toLowerCase().indexOf(a.toLowerCase())>-1,not_icontains:(a,l)=>!!en&&-1===l.href.toLowerCase().indexOf(a.toLowerCase()),regex:(a,l)=>!!en&&Ns(l.href,a),not_regex:(a,l)=>!!en&&!Ns(l.href,a),exact:(a,l)=>l.href===a,is_not:(a,l)=>l.href!==a};let ta=class ta{constructor(a){var l=this;this.getWebExperimentsAndEvaluateDisplayLogic=function(a){void 0===a&&(a=!1),l.getWebExperiments(a=>{ta.ls("retrieved web experiments from the server"),l.us=new Map,a.forEach(a=>{if(a.feature_flag_key){l.us&&(ta.ls("setting flag key ",a.feature_flag_key," to web experiment ",a),null==(c=l.us)||c.set(a.feature_flag_key,a));var c,u=l._instance.getFeatureFlag(a.feature_flag_key);T(u)&&a.variants[u]&&l.hs(a.name,u,a.variants[u].transforms)}else if(a.variants)for(var d in a.variants){var p=a.variants[d];ta.ds(p)&&l.hs(a.name,d,p.transforms)}})},a)},this._instance=a,this._instance.onFeatureFlags(a=>{this.onFeatureFlags(a)})}onFeatureFlags(a){if(this._is_bot())ta.ls("Refusing to render web experiment since the viewer is a likely bot");else if(!this._instance.config.disable_web_experiments){if(F(this.us))return this.us=new Map,this.loadIfEnabled(),void this.previewWebExperiment();ta.ls("applying feature flags",a),a.forEach(a=>{var l;if(this.us&&null!=(l=this.us)&&l.has(a)){var c,u=this._instance.getFeatureFlag(a),d=null==(c=this.us)?void 0:c.get(a);u&&null!=d&&d.variants[u]&&this.hs(d.name,u,d.variants[u].transforms)}})}}previewWebExperiment(){var a=ta.getWindowLocation();if(null!=a&&a.search){var l=$i(null==a?void 0:a.search,"__experiment_id"),c=$i(null==a?void 0:a.search,"__experiment_variant");l&&c&&(ta.ls("previewing web experiments "+l+" && "+c),this.getWebExperiments(a=>{this.vs(parseInt(l),c,a)},!1,!0))}}loadIfEnabled(){this._instance.config.disable_web_experiments||this.getWebExperimentsAndEvaluateDisplayLogic()}getWebExperiments(a,l,c){if(this._instance.config.disable_web_experiments&&!c)return a([]);var u=this._instance.get_property("$web_experiments");if(u&&!l)return a(u);this._instance.Ee({url:this._instance.requestRouter.endpointFor("api","/api/web_experiments/?token="+this._instance.config.token),method:"GET",callback:l=>200===l.statusCode&&l.json?a(l.json.experiments||[]):a([])})}vs(a,l,c){var u=c.filter(l=>l.id===a);u&&u.length>0&&(ta.ls("Previewing web experiment ["+u[0].name+"] with variant ["+l+"]"),this.hs(u[0].name,l,u[0].variants[l].transforms))}static ds(a){return!F(a.conditions)&&ta.cs(a)&&ta.fs(a)}
1static cs(a){if(F(a.conditions)||F(null==(l=a.conditions)?void 0:l.url))return!0;var l,c,u,d,p=ta.getWindowLocation();return!!p&&(null==(c=a.conditions)||!c.url||r4[null!==(u=null==(d=a.conditions)?void 0:d.urlMatchType)&&void 0!==u?u:"icontains"](a.conditions.url,p))}static getWindowLocation(){return null==en?void 0:en.location}static fs(a){if(F(a.conditions)||F(null==(c=a.conditions)?void 0:c.utm))return!0;var l=Jn();if(l.utm_source){var c,u,d,p,g,f,v,_,w,x=null==(u=a.conditions)||null==(u=u.utm)||!u.utm_campaign||(null==(d=a.conditions)||null==(d=d.utm)?void 0:d.utm_campaign)==l.utm_campaign,k=null==(p=a.conditions)||null==(p=p.utm)||!p.utm_source||(null==(g=a.conditions)||null==(g=g.utm)?void 0:g.utm_source)==l.utm_source,S=null==(f=a.conditions)||null==(f=f.utm)||!f.utm_medium||(null==(v=a.conditions)||null==(v=v.utm)?void 0:v.utm_medium)==l.utm_medium,$=null==(_=a.conditions)||null==(_=_.utm)||!_.utm_term||(null==(w=a.conditions)||null==(w=w.utm)?void 0:w.utm_term)==l.utm_term;return x&&S&&$&&k}return!1}static ls(a){for(var l=arguments.length,c=Array(l>1?l-1:0),u=1;u<l;u++)c[u-1]=arguments[u];eR.info("[WebExperiments] "+a,c)}hs(a,l,c){this._is_bot()?ta.ls("Refusing to render web experiment since the viewer is a likely bot"):"control"!==l?c.forEach(c=>{if(c.selector){ta.ls("applying transform of variant "+l+" for experiment "+a+" ",c);var u,d=null==(u=document)?void 0:u.querySelectorAll(c.selector);null==d||d.forEach(a=>{c.html&&(a.innerHTML=c.html),c.css&&a.setAttribute("style",c.css)})}}):ta.ls("Control variants leave the page unmodified.")}_is_bot(){return eu&&this._instance?Ko(eu,this._instance.config.custom_blocked_useragents):void 0}};var r5=eP("[PostHog ExternalIntegrations]"),r6={intercom:"intercom-integration",crispChat:"crisp-chat-integration"};let ra=class ra{constructor(a){this._instance=a}J(a,l){var c;null==(c=e_.__PosthogExtensions__)||null==c.loadExternalDependency||c.loadExternalDependency(this._instance,a,a=>{if(a)return r5.error("failed to load script",a);l()})}startIfEnabledOrStop(){var a,l=this,i=function(a){var c,d,p;!u||null!=(c=e_.__PosthogExtensions__)&&null!=(c=c.integrations)&&c[a]||l.J(r6[a],()=>{var c;null==(c=e_.__PosthogExtensions__)||null==(c=c.integrations)||null==(c=c[a])||c.start(l._instance)}),!u&&null!=(d=e_.__PosthogExtensions__)&&null!=(d=d.integrations)&&d[a]&&(null==(p=e_.__PosthogExtensions__)||null==(p=p.integrations)||null==(p=p[a])||p.stop())};for(var[c,u]of Object.entries(null!==(a=this._instance.config.integrations)&&void 0!==a?a:{}))i(c)}};var r8={},na=()=>{},r7="posthog",r9=!iH&&-1===(null==ev?void 0:ev.indexOf("MSIE"))&&-1===(null==ev?void 0:ev.indexOf("Mozilla")),la=a=>{var l;return{api_host:"https://us.i.posthog.com",ui_host:null,token:"",autocapture:!0,rageclick:!0,cross_subdomain_cookie:function(a){var l=null==a?void 0:a.hostname;if(!T(l))return!1;var c=l.split(".").slice(-2).join(".");for(var u of eT)if(c===u)return!1;return!0}(null==ed?void 0:ed.location),persistence:"localStorage+cookie",persistence_name:"",loaded:na,save_campaign_params:!0,custom_campaign_params:[],custom_blocked_useragents:[],save_referrer:!0,capture_pageview:"2025-05-24"!==a||"history_change",capture_pageleave:"if_capture_pageview",defaults:null!=a?a:"unset",debug:eh&&T(null==eh?void 0:eh.search)&&-1!==eh.search.indexOf("__posthog_debug=true")||!1,cookie_expiration:365,upgrade:!1,disable_session_recording:!1,disable_persistence:!1,disable_web_experiments:!0,disable_surveys:!1,disable_surveys_automatic_display:!1,disable_external_dependency_loading:!1,enable_recording_console_log:void 0,secure_cookie:"https:"===(null==en||null==(l=en.location)?void 0:l.protocol),ip:!1,opt_out_capturing_by_default:!1,opt_out_persistence_by_default:!1,opt_out_useragent_filter:!1,opt_out_capturing_persistence_type:"localStorage",opt_out_capturing_cookie_prefix:null,opt_in_site_apps:!1,property_denylist:[],respect_dnt:!1,sanitize_properties:null,request_headers:{},request_batching:!0,properties_string_max_length:65535,session_recording:{},mask_all_element_attributes:!1,mask_all_text:!1,mask_personal_data_properties:!1,custom_personal_data_properties:[],advanced_disable_flags:!1,advanced_disable_decide:!1,advanced_disable_feature_flags:!1,advanced_disable_feature_flags_on_first_load:!1,advanced_only_evaluate_survey_feature_flags:!1,advanced_disable_toolbar_metrics:!1,feature_flag_request_timeout_ms:3e3,surveys_request_timeout_ms:1e4,on_request_error:a=>{var l="Bad HTTP status: "+a.statusCode+" "+a.text;eR.error(l)},get_device_id:a=>a,capture_performance:void 0,name:"posthog",bootstrap:{},disable_compression:!1,session_idle_timeout_seconds:1800,person_profiles:"identified_only",before_send:void 0,request_queue_config:{flush_interval_ms:3e3},error_tracking:{},_onCapture:na}},ua=a=>{var l={};R(a.process_person)||(l.person_profiles=a.process_person),R(a.xhr_headers)||(l.request_headers=a.xhr_headers),R(a.c
1ookie_name)||(l.persistence_name=a.cookie_name),R(a.disable_cookie)||(l.disable_persistence=a.disable_cookie),R(a.store_google)||(l.save_campaign_params=a.store_google),R(a.verbose)||(l.debug=a.verbose);var c=V({},l,a);return eC(a.property_blacklist)&&(R(a.property_denylist)?c.property_denylist=a.property_blacklist:eC(a.property_denylist)?c.property_denylist=[...a.property_blacklist,...a.property_denylist]:eR.error("Invalid value for property_denylist config: "+a.property_denylist)),c};let ha=class ha{constructor(){this.__forceAllowLocalhost=!1}get ps(){return this.__forceAllowLocalhost}set ps(a){eR.error("WebPerformanceObserver is deprecated and has no impact on network capture. Use `_forceAllowLocalhostNetworkCapture` on `posthog.sessionRecording`"),this.__forceAllowLocalhost=a}};let da=class da{get decideEndpointWasHit(){var a,l;return null!==(a=null==(l=this.featureFlags)?void 0:l.hasLoadedFlags)&&void 0!==a&&a}get flagsEndpointWasHit(){var a,l;return null!==(a=null==(l=this.featureFlags)?void 0:l.hasLoadedFlags)&&void 0!==a&&a}constructor(){this.webPerformance=new ha,this.gs=!1,this.version=em.LIB_VERSION,this._s=new go,this._calculate_event_properties=this.calculateEventProperties.bind(this),this.config=la(),this.SentryIntegration=_s,this.sentryIntegration=a=>{var l;return l=gs(this,a),{name:i$,processEvent:a=>l(a)}},this.__request_queue=[],this.__loaded=!1,this.analyticsDefaultEndpoint="/e/",this.bs=!1,this.ys=null,this.ws=null,this.Ss=null,this.featureFlags=new co(this),this.toolbar=new Ss(this),this.scrollManager=new No(this),this.pageViewManager=new Ms(this),this.surveys=new So(this),this.experiments=new ta(this),this.exceptions=new Hs(this),this.rateLimiter=new Co(this),this.requestRouter=new Qo(this),this.consent=new Zi(this),this.externalIntegrations=new ra(this),this.people={set:(a,l,c)=>{var u=T(a)?{[a]:l}:a;this.setPersonProperties(u),null==c||c({})},set_once:(a,l,c)=>{var u=T(a)?{[a]:l}:a;this.setPersonProperties(void 0,u),null==c||c({})}},this.on("eventCaptured",a=>eR.info('send "'+(null==a?void 0:a.event)+'"',a))}init(a,l,c){if(c&&c!==r7){var u,d=null!==(u=r8[c])&&void 0!==u?u:new da;return d._init(a,l,c),r8[c]=d,r8[r7][c]=d,d}return this._init(a,l,c)}_init(a,l,c){if(void 0===l&&(l={}),R(a)||M(a))return eR.critical("PostHog was initialized without a token. This likely indicates a misconfiguration. Please check the first argument passed to posthog.init()"),this;if(this.__loaded)return eR.warn("You have already initialized PostHog! Re-initializing is a no-op"),this;this.__loaded=!0,this.config={},this.$s=l,this.ks=[],l.person_profiles&&(this.ws=l.person_profiles),this.set_config(V({},la(l.defaults),ua(l),{name:c,token:a})),this.config.on_xhr_error&&eR.error("on_xhr_error is deprecated. Use on_request_error instead"),this.compression=l.disable_compression?void 0:ew.GZipJS,this.persistence=new po(this.config),this.sessionPersistence="sessionStorage"===this.config.persistence||"memory"===this.config.persistence?this.persistence:new po(B({},this.config,{persistence:"sessionStorage"}));var u=B({},this.persistence.props),d=B({},this.sessionPersistence.props);if(this.register({$initialization_time:(new Date).toISOString()}),this.xs=new Do(a=>this.Es(a),this.config.request_queue_config),this.Is=new jo(this),this.__request_queue=[],this.config.__preview_experimental_cookieless_mode||(this.sessionManager=new Bo(this),this.sessionPropsManager=new Uo(this,this.sessionManager,this.persistence)),new ks(this).startIfEnabledOrStop(),this.siteApps=new Go(this),null==(p=this.siteApps)||p.init(),this.config.__preview_experimental_cookieless_mode||(this.sessionRecording=new vs(this),this.sessionRecording.startIfEnabledOrStop()),this.config.disable_scroll_properties||this.scrollManager.startMeasuringScrollPosition(),this.autocapture=new Mi(this),this.autocapture.startIfEnabled(),this.surveys.loadIfEnabled(),this.heatmaps=new Ts(this),this.heatmaps.startIfEnabled(),this.webVitalsAutocapture=new Is(this),this.exceptionObserver=new ae(this),this.exceptionObserver.startIfEnabled(),this.deadClicksAutocapture=new re(this,ee),this.deadClicksAutocapture.startIfEnabled(),this.historyAutocapture=new Ne(this),this.historyAutocapture.startIfEnabled(),em.DEBUG=em.DEBUG||this.config.debug,em.DEBUG&&eR.info("Starting in debug mode",{this:this,config:l,thisC:B({},this.config),p:u,s:d}),this.Ps(),void 0!==(null==(g=l.bootstrap)?void 0:g.distinctID)
vendor: 4,904 bytes, line 1
1){var p,g,f,v,_=this.config.get_device_id(ji()),w=null!=(f=l.bootstrap)&&f.isIdentifiedID?_:l.bootstrap.distinctID;this.persistence.set_property(e9,null!=(v=l.bootstrap)&&v.isIdentifiedID?"identified":"anonymous"),this.register({distinct_id:l.bootstrap.distinctID,$device_id:w})}if(this.Rs()){var x,k,S=Object.keys((null==(x=l.bootstrap)?void 0:x.featureFlags)||{}).filter(a=>{var c;return!(null==(c=l.bootstrap)||null==(c=c.featureFlags)||!c[a])}).reduce((a,c)=>{var u;return a[c]=(null==(u=l.bootstrap)||null==(u=u.featureFlags)?void 0:u[c])||!1,a},{}),$=Object.keys((null==(k=l.bootstrap)?void 0:k.featureFlagPayloads)||{}).filter(a=>S[a]).reduce((a,c)=>{var u,d;return null!=(u=l.bootstrap)&&null!=(u=u.featureFlagPayloads)&&u[c]&&(a[c]=null==(d=l.bootstrap)||null==(d=d.featureFlagPayloads)?void 0:d[c]),a},{});this.featureFlags.receivedFeatureFlags({featureFlags:S,featureFlagPayloads:$})}if(this.config.__preview_experimental_cookieless_mode)this.register_once({distinct_id:td,$device_id:null},"");else if(!this.get_distinct_id()){var N=this.config.get_device_id(ji());this.register_once({distinct_id:N,$device_id:N},""),this.persistence.set_property(e9,"anonymous")}return st(en,"onpagehide"in self?"pagehide":"unload",this._handle_unload.bind(this),{passive:!1}),this.toolbar.maybeLoadToolbar(),l.segment?function(a,l){var c=a.config.segment;if(!c)return l();!function(a,l){var c=a.config.segment;if(!c)return l();var r=c=>{var r=()=>c.anonymousId()||ji();a.config.get_device_id=r,c.id()&&(a.register({distinct_id:c.id(),$device_id:r()}),a.persistence.set_property(e9,"identified")),l()},u=c.user();"then"in u&&E(u.then)?u.then(a=>r(a)):r(u)}(a,()=>{var u;c.register((Promise&&Promise.resolve||iT.warn("This browser does not have Promise support, and can not use the segment integration"),u=(l,c)=>{if(!c)return l;l.event.userId||l.event.anonymousId===a.get_distinct_id()||(iT.info("No userId set, resetting PostHog"),a.reset()),l.event.userId&&l.event.userId!==a.get_distinct_id()&&(iT.info("UserId set, identifying with PostHog"),a.identify(l.event.userId));var u=a.calculateEventProperties(c,l.event.properties);return l.event.properties=Object.assign({},u,l.event.properties),l},{name:"PostHog JS",type:"enrichment",version:"1.0.0",isLoaded:()=>!0,load:()=>Promise.resolve(),track:a=>u(a,a.event.event),page:a=>u(a,"$pageview"),identify:a=>u(a,"$identify"),screen:a=>u(a,"$screen")})).then(()=>{l()})})}(this,()=>this.Ts()):this.Ts(),E(this.config._onCapture)&&this.config._onCapture!==na&&(eR.warn("onCapture is deprecated. Please use `before_send` instead"),this.on("eventCaptured",a=>this.config._onCapture(a.event,a))),this.config.ip&&eR.warn('The `ip` config option has NO EFFECT AT ALL and has been deprecated. Use a custom transformation or "Discard IP data" project setting instead. See https://posthog.com/tutorials/web-redact-properties#hiding-customer-ip-address for more information.'),this}Ie(a){var l,c,u,d,p,g,f,v;if(!ed||!ed.body)return eR.info("document not ready yet, trying again in 500 milliseconds..."),void setTimeout(()=>{this.Ie(a)},500);this.compression=void 0,a.supportedCompression&&!this.config.disable_compression&&(this.compression=m(a.supportedCompression,ew.GZipJS)?ew.GZipJS:m(a.supportedCompression,ew.Base64)?ew.Base64:void 0),null!=(l=a.analytics)&&l.endpoint&&(this.analyticsDefaultEndpoint=a.analytics.endpoint),this.set_config({person_profiles:this.ws?this.ws:"identified_only"}),null==(c=this.siteApps)||c.onRemoteConfig(a),null==(u=this.sessionRecording)||u.onRemoteConfig(a),null==(d=this.autocapture)||d.onRemoteConfig(a),null==(p=this.heatmaps)||p.onRemoteConfig(a),this.surveys.onRemoteConfig(a),null==(g=this.webVitalsAutocapture)||g.onRemoteConfig(a),null==(f=this.exceptionObserver)||f.onRemoteConfig(a),this.exceptions.onRemoteConfig(a),null==(v=this.deadClicksAutocapture)||v.onRemoteConfig(a)}Ts(){try{this.config.loaded(this)}catch(a){eR.critical("`loaded` function failed",a)}this.Ms(),this.config.capture_pageview&&setTimeout(()=>{this.consent.isOptedIn()&&this.Cs()},1),new Oo(this).load(),this.featureFlags.flags()}Ms(){var a;this.has_opted_out_capturing()||this.config.request_batching&&(null==(a=this.xs)||a.enable())}_dom_loaded(){this.has_opted_out_capturing()||G(this.__request_queue,a=>this.Es(a)),this.__request_queue=[],this.Ms()}_handle_unload(){var a,l;this.config.request_batching?(this.Fs()&&this.capture("$pageleave"),null==(a=this.xs)||a.unload(),null==(l=this.Is)||l.unload()):this.Fs()&&this.capture("$pageleave",null,{transport:"sendBeacon"})}Ee(a){this.__loaded&&(r9?this.__request_queue.push(a):this.rateLimiter.isServerRateLimited(a.batchKey)||(a.transport=a.transport||this.config.api_transport,a.url=As(a.url,{ip:this.config.ip?1:0}),a.headers=B({},this.config.request_headers),a.compression="best-available"===a.compression?this.compression:a.compression,a.fetchOptions=a.fetchOptions||this.config.fetch_options,
1(a=>{var l,c,u,d=B({},a);d.timeout=d.timeout||6e4,d.url=As(d.url,{_:(new Date).getTime().toString(),ver:em.LIB_VERSION,compression:d.compression});var p=null!==(l=d.transport)&&void 0!==l?l:"fetch",g=null!==(c=null==(u=rt(iz,a=>a.transport===p))?void 0:u.method)&&void 0!==c?c:iz[0].method;if(!g)throw Error("No available transport method");g(d)})(B({},a,{callback:l=>{var c,u;this.rateLimiter.checkForLimiting(l),l.statusCode>=400&&(null==(c=(u=this.config).on_request_error)||c.call(u,l)),null==a.callback||a.callback(l)}}))))}Es(a){this.Is?this.Is.retriableRequest(a):this.Ee(a)}_execute_array(a){var l,c=[],u=[],d=[];G(a,a=>{a&&(eC(l=a[0])?d.push(a):E(a)?a.call(this):eC(a)&&"alias"===l?c.push(a):eC(a)&&-1!==l.indexOf("capture")&&E(this[l])?d.push(a):u.push(a))});var n=function(a,l){G(a,function(a){if(eC(a[0])){var c=l;J(a,function(a){c=c[a[0]].apply(c,a.slice(1))})}else this[a[0]].apply(this,a.slice(1))},l)};n(c,this),n(u,this),n(d,this)}Rs(){var a,l;return(null==(a=this.config.bootstrap)?void 0:a.featureFlags)&&Object.keys(null==(l=this.config.bootstrap)?void 0:l.featureFlags).length>0||!1}push(a){this._execute_array([a])}capture(a,l,c){var u;if(this.__loaded&&this.persistence&&this.sessionPersistence&&this.xs){if(!this.consent.isOptedOut()){if(!R(a)&&T(a)){if(this.config.opt_out_useragent_filter||!this._is_bot()){var d=null!=c&&c.skip_client_rate_limiting?void 0:this.rateLimiter.clientRateLimitContext();if(null==d||!d.isRateLimited){null!=l&&l.$current_url&&!T(null==l?void 0:l.$current_url)&&(eR.error("Invalid `$current_url` property provided to `posthog.capture`. Input must be a string. Ignoring provided value."),null==l||delete l.$current_url),this.sessionPersistence.update_search_keyword(),this.config.save_campaign_params&&this.sessionPersistence.update_campaign_params(),this.config.save_referrer&&this.sessionPersistence.update_referrer_info(),(this.config.save_campaign_params||this.config.save_referrer)&&this.persistence.set_initial_person_info();var p,g,f,v,_=new Date,w=(null==c?void 0:c.timestamp)||_,x=ji(),k={uuid:x,event:a,properties:this.calculateEventProperties(a,l||{},w,x)};d&&(k.properties.$lib_rate_limit_remaining_tokens=d.remainingTokens),(null==c?void 0:c.$set)&&(k.$set=null==c?void 0:c.$set);var S,$,N=this.Os(null==c?void 0:c.$set_once);if(N&&(k.$set_once=N),(p=k,g=null!=c&&c._noTruncate?null:this.config.properties_string_max_length,f=a=>T(a)&&!C(g)?a.slice(0,g):a,v=new Set,k=function t(a,l){var c;return a!==Object(a)?f?f(a,l):a:v.has(a)?void 0:(v.add(a),eC(a)?(c=[],G(a,a=>{c.push(t(a))})):(c={},J(a,(a,l)=>{v.has(a)||(c[l]=t(a,l))})),c)}(p)).timestamp=w,R(null==c?void 0:c.timestamp)||(k.properties.$event_time_override_provided=!0,k.properties.$event_time_override_system_time=_),a===rW.DISMISSED||a===rW.SENT){var z=null==l?void 0:l[rJ.SURVEY_ID],U=null==l?void 0:l[rJ.SURVEY_ITERATION];localStorage.setItem(($=""+rV+(S={id:z,current_iteration:U}).id,S.current_iteration&&S.current_iteration>0&&($=""+rV+S.id+"_"+S.current_iteration),$),"true"),k.$set=B({},k.$set,{[yo({id:z,current_iteration:U},a===rW.SENT?"responded":"dismissed")]:!0})}var W=B({},k.properties.$set,k.$set);if(P(W)||this.setPersonPropertiesForFlags(W),!F(this.config.before_send)){var et=this.As(k);if(!et)return;k=et}this._s.emit("eventCaptured",k);var ei={method:"POST",url:null!==(u=null==c?void 0:c._url)&&void 0!==u?u:this.requestRouter.endpointFor("api",this.analyticsDefaultEndpoint),data:k,compression:"best-available",batchKey:null==c?void 0:c._batchKey};return!this.config.request_batching||c&&(null==c||!c._batchKey)||null!=c&&c.send_instantly?this.Es(ei):this.xs.enqueue(ei),k}eR.critical("This capture call is ignored due to client rate limiting.")}}else eR.error("No event name provided to posthog.capture")}}else eR.uninitializedWarning("posthog.capture")}Ge(a){return this.on("eventCaptured",l=>a(l.event,l))}calculateEventProperties(a,l,c,u,d){if(c=c||new Date,!this.persistence||!this.sessionPersistence)return l;var p,g=d?void 0:this.persistence.remove_event_timer(a),f=B({},l);if(f.token=this.config.token,f.$config_defaults=this.config.defaults,this.config.__preview_experimental_cookieless_mode&&(f.$cookieless_mode=!0),"$snapshot"===a){var v=B({},this.persistence.properties(),this.sessionPersistence.properties());return f.distinct_id=v.distinct_id,(!T(f.distinct_id)&&!O(f.distinct_id)||M(f.distinct_id))&&eR.error("Invalid distinct_id for replay event. This indicates a bug in your implementation"),f}var _,w=function(a,l){if(!ev)return{};var c,u,d=a?K([],r$,l||[]):[],[p,g]=function(a){for(var l=0;l<rO.length;l++){var[c,u]=rO[l],d=c.exec(a),p=d&&(E(u)?u(d,a):u);if(p)return p}return["",""]}(ev);return V(Z({$os:p,$os_version:g,$browser:Ln(ev,navigator.vendor),$device:Un(ev),$device_type:(u=Un(ev))===iK||u===iY||"Kobo"===u||"Kindle Fire"===u||u===rw?iJ:u===ru||u===rh||u===rd||u===rm?"Console":u===iX?"Wearable":u?iV:"Desktop",$timezone:to(),$timezone_offset:function(){try{return(new Date).getTimezoneOffset()}catch(a){return}}()}),{$current_url:ki(null==eh?void 0:eh.href,d,rA),$host:null==eh?void 0:eh.host,$pathname:null==eh?void 0:eh.pathname,$raw_user_agent:ev.length>1e3?ev.substring(0,997)+"...":ev,$browser_version:Nn(ev,navigator.vendor),$browser_language:Yn(),$browser_language_prefix:"string"==typeof(c=Yn())?c.split("-")[0]:void 0,$screen_height:null==en?void 0:en.screen.height,$screen_width:null==en?void 0:en.screen.width,$viewport_height:null==en?void 0:en.innerHeight,$viewport_width:null==en?void 0:en.innerWidth,$lib:"web",$lib_version:em.LIB_VERSION,$insert_id:Math.random().toString(36).substring(2,10)+Math.random().toString(36).substring(2,10),$time:Date.now()/1e3})}(this.config.mask_personal_data_properties,this.config.custom_personal_data_properties);if(this.sessionManager){var{sessionId:x,windowId:k}=this.sessionManager.checkAndGetSessionAndWindowId(d,c.getTime());f.$session_id=x,f.$window_id=k}this.sessionPropsManager&&V(f,this.sessionPropsManager.getSessionProps());try{this.sessionRecording&&V(f,this.sessionRecording.sdkDebugProperties),f.$sdk_debug_retry_queue_size=null==(p=this.Is)?void 0:p.length}catch(a){f.$sdk_debug_error_capturing_properties=String(a)}if(this.requestRouter.region===r2.CUSTOM&&(f.$lib_custom_api_host=this.config.api_host),_="$pageview"!==a||d?"$pageleave"!==a||d?this.pageViewM
1anager.doEvent():this.pageViewManager.doPageLeave(c):this.pageViewManager.doPageView(c,u),f=V(f,_),"$pageview"===a&&ed&&(f.title=ed.title),!R(g)){var S=c.getTime()-g;f.$duration=parseFloat((S/1e3).toFixed(3))}ev&&this.config.opt_out_useragent_filter&&(f.$browser_type=this._is_bot()?"bot":"browser"),(f=V({},w,this.persistence.properties(),this.sessionPersistence.properties(),f)).$is_identified=this._isIdentified(),eC(this.config.property_denylist)?J(this.config.property_denylist,function(a){delete f[a]}):eR.error("Invalid value for property_denylist config: "+this.config.property_denylist+" or property_blacklist config: "+this.config.property_blacklist);var $=this.config.sanitize_properties;$&&(eR.error("sanitize_properties is deprecated. Use before_send instead"),f=$(f,a));var N=this.Ds();return f.$process_person_profile=N,N&&!d&&this.Ls("_calculate_event_properties"),f}Os(a){if(!this.persistence||!this.Ds()||this.gs)return a;var l,c=V({},this.persistence.get_initial_props(),(null==(l=this.sessionPropsManager)?void 0:l.getSetOnceProps())||{},a||{}),u=this.config.sanitize_properties;return u&&(eR.error("sanitize_properties is deprecated. Use before_send instead"),c=u(c,"$set_once")),this.gs=!0,P(c)?void 0:c}register(a,l){var c;null==(c=this.persistence)||c.register(a,l)}register_once(a,l,c){var u;null==(u=this.persistence)||u.register_once(a,l,c)}register_for_session(a){var l;null==(l=this.sessionPersistence)||l.register(a)}unregister(a){var l;null==(l=this.persistence)||l.unregister(a)}unregister_for_session(a){var l;null==(l=this.sessionPersistence)||l.unregister(a)}js(a,l){this.register({[a]:l})}getFeatureFlag(a,l){return this.featureFlags.getFeatureFlag(a,l)}getFeatureFlagPayload(a){var l=this.featureFlags.getFeatureFlagPayload(a);try{return JSON.parse(l)}catch(a){return l}}isFeatureEnabled(a,l){return this.featureFlags.isFeatureEnabled(a,l)}reloadFeatureFlags(){this.featureFlags.reloadFeatureFlags()}updateEarlyAccessFeatureEnrollment(a,l){this.featureFlags.updateEarlyAccessFeatureEnrollment(a,l)}getEarlyAccessFeatures(a,l,c){return void 0===l&&(l=!1),this.featureFlags.getEarlyAccessFeatures(a,l,c)}on(a,l){return this._s.on(a,l)}onFeatureFlags(a){return this.featureFlags.onFeatureFlags(a)}onSurveysLoaded(a){return this.surveys.onSurveysLoaded(a)}onSessionId(a){var l,c;return null!==(l=null==(c=this.sessionManager)?void 0:c.onSessionId(a))&&void 0!==l?l:()=>{}}getSurveys(a,l){void 0===l&&(l=!1),this.surveys.getSurveys(a,l)}getActiveMatchingSurveys(a,l){void 0===l&&(l=!1),this.surveys.getActiveMatchingSurveys(a,l)}renderSurvey(a,l){this.surveys.renderSurvey(a,l)}canRenderSurvey(a){return this.surveys.canRenderSurvey(a)}canRenderSurveyAsync(a,l){return void 0===l&&(l=!1),this.surveys.canRenderSurveyAsync(a,l)}identify(a,l,c){if(!this.__loaded||!this.persistence)return eR.uninitializedWarning("posthog.identify");if(O(a)&&(a=a.toString(),eR.warn("The first argument to posthog.identify was a number, but it should be a string. It has been converted to a string.")),a){if(["distinct_id","distinctid"].includes(a.toLowerCase()))eR.critical('The string "'+a+'" was set in posthog.identify which indicates an error. This ID should be unique to the user and not a hardcoded string.');else if(a!==td){if(this.Ls("posthog.identify")){var u=this.get_distinct_id();this.register({$user_id:a}),this.get_property("$device_id")||this.register_once({$had_persisted_distinct_id:!0,$device_id:u},""),a!==u&&a!==this.get_property(ej)&&(this.unregister(ej),this.register({distinct_id:a}));var d="anonymous"===(this.persistence.get_property(e9)||"anonymous");a!==u&&d?(this.persistence.set_property(e9,"identified"),this.setPersonPropertiesForFlags(B({},c||{},l||{}),!1),this.capture("$identify",{distinct_id:a,$anon_distinct_id:u},{$set:l||{},$set_once:c||{}}),this.Ss=zs(a,l,c),this.featureFlags.setAnonymousDistinctId(u)):(l||c)&&this.setPersonProperties(l,c),a!==u&&(this.reloadFeatureFlags(),this.unregister(e7))}}else eR.critical('The string "'+td+'" was set in posthog.identify which indicates an error. This ID is only used as a sentinel value.')}else eR.error("Unique user id has not been set in posthog.identify")}setPersonProperties(a,l){if((a||l)&&this.Ls("posthog.setPersonProperties")){var c=zs(this.get_distinct_id(),a,l);this.Ss!==c?(this.setPersonPropertiesForFlags(B({},l||{},a||{})),this.capture("$set",{$set:a||{},$set_once:l||{}}),this.Ss=c):eR.info("A duplicate setPersonProperties call was made with the same properties. It has been ignored.")}}group(a,l,c){if(a&&l){if(this.Ls("posthog.group")){var u=this.getGroups();u[a]!==l&&this.resetGroupPropertiesForFlags(a),this.register({$groups:B({},u,{[a]:l})}),c&&(this.capture("$groupidentify",{$group_type:a,$group_key:l,$group_set:c}),this.setGroupPropertiesForFlags({[a]:c})),u[a]===l||c||this.reloadFeatureFlags()}}else eR.error("posthog.group requires a group type and group key")}resetGroups(){this.register({$groups:{}}),this.resetGroupPropertiesForFlags(),this.reloadFeatureFlags()}setPersonPropertiesForFlags(a,l){void 0===l&&(l=!0),this.featureFlags.setPersonPropertiesForFlags(a,l)}resetPersonPropertiesForFlags(){this.featureFlags.resetPersonPropertiesForFlags()}setGroupPropertiesForFlags(a,l){void 0===l&&(l=!0),this.Ls("posthog.setGroupPropertiesForFlags")&&this.featureFlags.setGroupPropertiesForFlags(a,l)}resetGroupPropertiesForFlags(a){this.featureFlags.resetGroupPropertiesForFlags(a)}reset(a){if(eR.info("reset"),!this.__loaded)return eR.uninitializedWarning("posthog.reset");var l,c,u,d,p=this.get_property("$device_id");if(this.consent.reset(),null==(l=this.persistence)||l.clear(),null==(c=this.sessionPersistence)||c.clear(),this.surveys.reset(),this.featureFlags.reset(),null==(u=this.persistence)||u.set_property(e9,"anonymous"),null==(d=this.sessionManager)||d.resetSessionId(),this.Ss=null,this.config.__preview_experimental_cookieless_mode)this.register_once({distinct_id:td,$device_id:null},"");else{var g=this.config.get_device_id(ji());this.register_once({distinct_id:g,$device_id:a?g:p},"")}this.register({$last_posthog_reset:(new Date).toISOString()},1)}get_distinct_id(){return this.get_property("distinct_id")}getGroups(){return this.get_property("$groups")||{}}get_session_id(){var a,l;return null!==(a=null==(l=this.sessionManager)?void 0:l.checkAndGetSessionAndWindowId(!0).sessionId)&&void 0!==a?a:""}get_session_replay_url(a){if(!this.sessionManager)return"";var{sessionId:l,sessionStartTimestamp:c}=this.sessionManager.checkAndGetSessionAndWindowId(!0),u=this.requestRouter.endpointFor("ui","/project/"+this.config.token+"/replay/"+l);if(null!=a&&a.withTimestamp&&c){var d,p=null!==(d=a.timestampLookBack)&&void 0!==d?d:10;if(!c)return u;u+="?t="+Math.max(Math.floor(((new Date).getTime()-c)/1e3)-p,0)}return u}alias(a,l){return a===this.get_property(e$)?(eR.critical("Attempting to create alias for existing People user - aborting."),-2):this.Ls("posthog.alias")?(R(l)&&(l=this.get_distinct_id()),a!==l?(this.js(ej,a),this.capture("$create_alias",{alias:a,distinct_id:l})):(eR.warn("alias matches current distinct_id - skipping api call."),this.identify(a),-1)):void 0}set_config(a){var l,c,u,d,p,g=B({},this.config);I(a)&&(V(this.config,ua(a)),null==(l=this.persistence)||l.update_config(this.config,g),this.sessionPersistence="sessionStorage"===this.config.persistence||"memory"===this.config.persistence?this.persistence:new po(B({},this.config,{persistence:"sessionStorage"})),tP.O()&&"true"===tP.D("ph_debug")&&(this.config.debug=!0),this.config.debug&&(em.DEBUG=!0,eR.info("set_config",{config:a,oldConfig:g,newConfig:B({},this.config)})),null==(c=this.sessionRecording)||c.startIfEnabledOrStop(),null==(u=this.autocapture)||u.startIfEnabled(),null==(d=this.heatmaps)||d.startIfEnabled(),this.surveys.loadIfEnabled(),this.Ps(),null==(p=this.externalIntegrations)||p.startIfEnabledOrStop())}startSessionRecording(a){var l,c,u,d,p,g=!0===a,f={sampling:g||!(null==a||!a.sampling),linked_flag:g||!(null==a||!a.linked_flag),url_trigger:g||!(null==a||!a.url_trigger),event_trigger:g||!(null==a||!a.event_trigger)};Object.values(f).some(Boolean)&&(null==(l=this.sessionManager)||l.checkAndGetSessionAndWindowId(),f.sampling&&(null==(c=this.sessionRecording)||c.overrideSampling()),f.linked_flag&&(null==(u=this.sessionRecording)||u.overrideLinkedFlag()),f.url_trigger&&(null==(d=this.sessionRecording)||d.overrideTrigger("url")),f.event_trigger&&(null==(p=this.sessionRecording)||p.overrideTrigger("event"))),this.set_config({disable_session_recording:!1})}stopSessionRecording(){this.set_config({disable_session_recording:!0})}sessionRecordingStarted(){var a;return!(null==(a=this.sessionRecording)||!a.started)}captureException(a,l){var c=Error("PostHog syntheticException");this.exceptions.sendExceptionEvent(B({},function(a,l){var{error:c,event:u}=a,d={$exception_list:[]},p=c||u;if(ve(p)||de(p,"DOMException")){if("stack"in p)d=Fe(p,l);else{var g=p.name||(ve(p)?"DOMError":"DOMException"),f=p.message?g+": "+p.message:g;d=Oe(f,B({},l,{overrideExceptionType:ve(p)?"DOMError":"DOMException",defaultExceptionMessage:f}))}return"code"in p&&(d.$exception_DOMException_code=""+p.code),d}if(de(p,"ErrorEvent")&&p.error)return Fe(p.error,l);if(he(p))return Fe(p,l);if(de(p,"Object")||le(p))return function(a,l){var c,u,d,p=null===(u=null==l?void 0:l.handled)||void 0===u||u,g=null===(d=null==l?void 0:l.synthetic)||void 0===d||d,f={type:null!=l&&l.overrideExceptionType?l.overrideExceptionType:le(a)?a.constructor.name:"Error",value:"Non-Error 'exception' captured with keys: "+function(a,l){void 0===l&&(l=40);var c=Object.keys(a);if(c.sort(),!c.length)return"[object has no keys]";for(var u=c.length;u>0;u--){var d=c.slice(0,u).join(", ");
1if(!(d.length>l))return u===c.length||d.length<=l?d:d.slice(0,l)+"..."}return""}(a),mechanism:{handled:p,synthetic:g}};if(null!=l&&l.syntheticException){var v=Re(null==l?void 0:l.syntheticException,1);v.length&&(f.stacktrace={frames:v,type:"raw"})}return{$exception_list:[f],$exception_level:T(c=a.level)&&!M(c)&&ex.indexOf(c)>=0?a.level:"error"}}(p,l);if(R(c)&&T(u)){var v="Error",_=u,w=u.match(tK);return w&&(v=w[1],_=w[2]),Oe(_,B({},l,{overrideExceptionType:v,defaultExceptionMessage:_}))}return Oe(p,l)}(a instanceof Error?{error:a,event:a.message}:{event:a},{syntheticException:c}),l))}loadToolbar(a){return this.toolbar.loadToolbar(a)}get_property(a){var l;return null==(l=this.persistence)?void 0:l.props[a]}getSessionProperty(a){var l;return null==(l=this.sessionPersistence)?void 0:l.props[a]}toString(){var a,l=null!==(a=this.config.name)&&void 0!==a?a:r7;return l!==r7&&(l=r7+"."+l),l}_isIdentified(){var a,l;return"identified"===(null==(a=this.persistence)?void 0:a.get_property(e9))||"identified"===(null==(l=this.sessionPersistence)?void 0:l.get_property(e9))}Ds(){var a,l;return!("never"===this.config.person_profiles||"identified_only"===this.config.person_profiles&&!this._isIdentified()&&P(this.getGroups())&&(null==(a=this.persistence)||null==(a=a.props)||!a[ej])&&(null==(l=this.persistence)||null==(l=l.props)||!l[tc]))}Fs(){return!0===this.config.capture_pageleave||"if_capture_pageview"===this.config.capture_pageleave&&(!0===this.config.capture_pageview||"history_change"===this.config.capture_pageview)}createPersonProfile(){this.Ds()||this.Ls("posthog.createPersonProfile")&&this.setPersonProperties({},{})}Ls(a){return"never"===this.config.person_profiles?(eR.error(a+' was called, but process_person is set to "never". This call will be ignored.'),!1):(this.js(tc,!0),!0)}Ps(){var a,l,c,u,d=this.consent.isOptedOut(),p=this.config.opt_out_persistence_by_default,g=this.config.disable_persistence||d&&!!p;(null==(a=this.persistence)?void 0:a.Fe)!==g&&(null==(c=this.persistence)||c.set_disabled(g)),(null==(l=this.sessionPersistence)?void 0:l.Fe)!==g&&(null==(u=this.sessionPersistence)||u.set_disabled(g))}opt_in_capturing(a){var l;this.consent.optInOut(!0),this.Ps(),(R(null==a?void 0:a.captureEventName)||null!=a&&a.captureEventName)&&this.capture(null!==(l=null==a?void 0:a.captureEventName)&&void 0!==l?l:"$opt_in",null==a?void 0:a.captureProperties,{send_instantly:!0}),this.config.capture_pageview&&this.Cs()}opt_out_capturing(){this.consent.optInOut(!1),this.Ps()}has_opted_in_capturing(){return this.consent.isOptedIn()}has_opted_out_capturing(){return this.consent.isOptedOut()}clear_opt_in_out_capturing(){this.consent.reset(),this.Ps()}_is_bot(){return eu?Ko(eu,this.config.custom_blocked_useragents):void 0}Cs(){ed&&("visible"===ed.visibilityState?this.bs||(this.bs=!0,this.capture("$pageview",{title:ed.title},{send_instantly:!0}),this.ys&&(ed.removeEventListener("visibilitychange",this.ys),this.ys=null)):this.ys||(this.ys=this.Cs.bind(this),st(ed,"visibilitychange",this.ys)))}debug(a){!1===a?(null==en||en.console.log("You've disabled debug mode."),localStorage&&localStorage.removeItem("ph_debug"),this.set_config({debug:!1})):(null==en||en.console.log("You're now in debug mode. All calls to PostHog will be logged in your console.\nYou can disable this with `posthog.debug(false)`."),localStorage&&localStorage.setItem("ph_debug","true"),this.set_config({debug:!0}))}I(){var a,l,c,u,d=this.$s||{};return"advanced_disable_flags"in d?!!d.advanced_disable_flags:!1!==this.config.advanced_disable_flags?!!this.config.advanced_disable_flags:!0===this.config.advanced_disable_decide?(eR.warn("Config field 'advanced_disable_decide' is deprecated. Please use 'advanced_disable_flags' instead. The old field will be removed in a future major version."),!0):(l="advanced_disable_decide",c=(a="advanced_disable_flags")in d&&!R(d[a]),u=l in d&&!R(d[l]),c?d[a]:!!u&&(eR&&eR.warn("Config field '"+l+"' is deprecated. Please use '"+a+"' instead. The old field will be removed in a future major version."),d[l]))}As(a){if(F(this.config.before_send))return a;var l=eC(this.config.before_send)?this.config.before_send:[this.config.before_send],c=a;for(var u of l){if(F(c=u(c))){var d="Event '"+a.event+"' was rejected in beforeSend function";return L(a.event)?eR.warn(d+". This can cause unexpected behavior."):eR.info(d),null}c.properties&&!P(c.properties)||eR.warn("Event '"+a.event+"' has no properties after beforeSend function, this is likely an error.")}return c}getPageViewId(){var a;
1return null==(a=this.pageViewManager.ce)?void 0:a.pageViewId}captureTraceFeedback(a,l){this.capture("$ai_feedback",{$ai_trace_id:String(a),$ai_feedback_text:l})}captureTraceMetric(a,l,c){this.capture("$ai_metric",{$ai_trace_id:String(a),$ai_metric_name:l,$ai_metric_value:String(c)})}};!function(a,l){for(var c=0;c<l.length;c++)a.prototype[l[c]]=Q(a.prototype[l[c]])}(da,["identify"]);var si,sr,ss,sn,so,sa,sl,sc,su,sd,sh,sp,sg,sf,sv=(sf=r8[r7]=new da,function(){function i(){i.done||(i.done=!0,r9=!1,J(r8,function(a){a._dom_loaded()}))}null!=ed&&ed.addEventListener?"complete"===ed.readyState?i():st(ed,"DOMContentLoaded",i,{capture:!1}):en&&eR.error("Browser doesn't support `document.addEventListener` so PostHog couldn't be initialized")}(),sf),s_=(0,d.createContext)({client:sv});function PostHogProvider(a){var l=a.children,c=a.client,u=a.apiKey,p=a.options,g=(0,d.useRef)(null),f=(0,d.useMemo)(function(){return c?(u&&console.warn("[PostHog.js] You have provided both `client` and `apiKey` to `PostHogProvider`. `apiKey` will be ignored in favour of `client`."),p&&console.warn("[PostHog.js] You have provided both `client` and `options` to `PostHogProvider`. `options` will be ignored in favour of `client`."),c):(u||console.warn("[PostHog.js] No `apiKey` or `client` were provided to `PostHogProvider`. Using default global `window.posthog` instance. You must initialize it manually. This is not recommended behavior."),sv)},[c,u,JSON.stringify(p)]);return(0,d.useEffect)(function(){if(!c){var a=g.current;a?(u!==a.apiKey&&console.warn("[PostHog.js] You have provided a different `apiKey` to `PostHogProvider` than the one that was already initialized. This is not supported by our provider and we'll keep using the previous key. If you need to toggle between API Keys you need to control the `client` yourself and pass it in as a prop rather than an `apiKey` prop."),p&&!function isDeepEqual(a,l,c){if(void 0===c&&(c=new WeakMap),a===l)return!0;if("object"!=typeof a||null===a||"object"!=typeof l||null===l)return!1;if(c.has(a)&&c.get(a)===l)return!0;c.set(a,l);var u=Object.keys(a),d=Object.keys(l);if(u.length!==d.length)return!1;for(var p=0;p<u.length;p++){var g=u[p];if(!d.includes(g)||!isDeepEqual(a[g],l[g],c))return!1}return!0}(p,a.options)&&sv.set_config(p)):(sv.__loaded&&console.warn("[PostHog.js] `posthog` was already loaded elsewhere. This may cause issues."),sv.init(u,p)),g.current={apiKey:u,options:null!=p?p:{}}}},[c,u,JSON.stringify(p)]),d.createElement(s_.Provider,{value:{client:f}},l)}var extendStatics=function(a,l){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(a,l){a.__proto__=l}||function(a,l){for(var c in l)Object.prototype.hasOwnProperty.call(l,c)&&(a[c]=l[c])})(a,l)};"function"==typeof SuppressedError&&SuppressedError;var isFunction=function(a){return"function"==typeof a},sm={componentStack:null,error:null};function App(a){let{Component:l,pageProps:c}=a,p=(0,er.useRouter)();return(0,d.useEffect)(()=>{let handleRouteChange=a=>{pageview(a)};return p.events.on("routeChangeComplete",handleRouteChange),()=>{p.events.off("routeChangeComplete",handleRouteChange)}},[p.events]),(0,d.useEffect)(()=>{"serviceWorker"in navigator&&navigator.serviceWorker.register("/sw.js").then(a=>console.log("SW registered:",a)).catch(a=>console.error("SW failed:",a))},[]),(0,d.useEffect)(()=>{console.log("initilaising posthog"),sv.init("phc_Ro1PdPM6NXsfDWtiP0mbWWQFSCT3aMeI4NPndGfnJmy",{api_host:"/ingest",ui_host:"https://eu.posthog.com",defaults:"2025-05-24",capture_exceptions:!0})},[]),(0,u.jsxs)(u.Fragment,{children:[(0,u.jsxs)(g(),{children:[(0,u.jsx)("link",{rel:"preconnect",href:"https://fonts.googleapis.com"}),(0,u.jsx)("link",{rel:"preconnect",href:"https://fonts.gstatic.com",crossOrigin:"anonymous"}),(0,u.jsx)("link",{href:"https://fonts.googleapis.com/css2?family=Source+Sans+3:ital,wght@0,200..900;1,200..900&display=swap",rel:"stylesheet"}),(0,u.jsx)("link",{rel:"manifest",href:"/manifest.json"}),(0,u.jsx)("link",{rel:"icon",href:"/favicon.ico"}),(0,u.jsx)("meta",{name:"theme-color",content:"#ffffff"}),(0,u.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),(0,u.jsx)("meta",{name:"apple-mobile-web-app-capable",content:"yes"}),(0,u.jsx)("meta",{name:"mobile-web-app-capable",content:"yes"}),(0,u.jsx)("link",{rel:"apple-touch-icon",sizes:"192x192",href:"/icons/favicon-192x192.png"}),(0,u.jsx)("link",{rel:"icon",type:"image/png",sizes:"32x32",href:"/icons/favicon-32x32.png"}),(0,u.jsx)("link",{rel:"icon",type:"image/png",sizes:"16x16",href:"/icons/favicon-16x16.png"})]}),(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(v(),{src:"https://www.googletagmanager.com/gtag/js?i
1d=G-7ZFZ4446GW",strategy:"afterInteractive"}),(0,u.jsx)(v(),{id:"gtag-init",strategy:"afterInteractive",children:"\n window.dataLayer = window.dataLayer || [];\n function gtag(){dataLayer.push(arguments);} \n gtag('js', new Date());\n gtag('config', 'G-7ZFZ4446GW');\n "}),(0,u.jsx)(v(),{src:"https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3121733259087338",strategy:"afterInteractive",crossOrigin:"anonymous"})]}),(0,u.jsx)(PostHogProvider,{client:sv,children:(0,u.jsx)(LocationProvider,{children:(0,u.jsx)(Layout,{children:(0,u.jsx)(l,{...c})})})})]})}!function(a){function PostHogErrorBoundary(l){var c=a.call(this,l)||this;return c.state=sm,c}!function(a,l){if("function"!=typeof l&&null!==l)throw TypeError("Class extends value "+String(l)+" is not a constructor or null");function __(){this.constructor=a}extendStatics(a,l),a.prototype=null===l?Object.create(l):(__.prototype=l.prototype,new __)}(PostHogErrorBoundary,a),PostHogErrorBoundary.prototype.componentDidCatch=function(a,l){var c,u=l.componentStack,d=this.props.additionalProperties;this.setState({error:a,componentStack:u}),isFunction(d)?c=d(a):"object"==typeof d&&(c=d),this.context.client.captureException(a,c)},PostHogErrorBoundary.prototype.render=function(){var a=this.props,l=a.children,c=a.fallback,u=this.state;if(null==u.componentStack)return isFunction(l)?l():l;var p=isFunction(c)?d.createElement(c,{error:u.error,componentStack:u.componentStack}):c;return d.isValidElement(p)?p:(console.warn("[PostHog.js][PostHogErrorBoundary] Invalid fallback prop, provide a valid React element or a function that returns a valid React element."),d.createElement(d.Fragment,null))},PostHogErrorBoundary.contextType=s_}(d.Component)},70415:function(){},9008:function(a,l,c){a.exports=c(79201)},25675:function(a,l,c){a.exports=c(645)},41664:function(a,l,c){a.exports=c(65170)},11163:function(a,l,c){a.exports=c(59974)},4298:function(a,l,c){a.exports=c(85354)},31415:function(a,l,c){"use strict";var u=c(67294);let d=u.forwardRef(function({title:a,titleId:l,...c},d){return u.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:d,"aria-labelledby":l},c),a?u.createElement("title",{id:l},a):null,u.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18 18 6M6 6l12 12"}))});l.Z=d}},function(a){var __webpack_exec__=function(l){return a(a.s=l)};a.O(0,[9774,179],function(){return __webpack_exec__(6840),__webpack_exec__(59974)}),_N_E=a.O()}]);
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.