try{let e=typeof window<`u`?window:typeof global<`u`?global:typeof globalThis<`u`?globalThis:typeof self<`u`?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]=`feaf8a21-53d0-4a06-ad3d-4215acd53a2f`,e._sentryDebugIdIdentifier=`sentry-dbid-feaf8a21-53d0-4a06-ad3d-4215acd53a2f`)}catch{}import{$d as e,Dg as t,Em as n,Fg as r,Gf as i,Kf as a,No as o,Um as s,fh as c,gf as l,st as u}from"./entry.client-dr7r6s9a.js";var d=r(),f=()=>{let r=(0,d.c)(2),i=n(),a;r[0]===i.queries.UNSAFE_anonymousOnlyConfiguration?a=r[1]:(a=i.queries.UNSAFE_anonymousOnlyConfiguration.getOptions(`enableAuthTemporaryV2`),r[0]=i.queries.UNSAFE_anonymousOnlyConfiguration,r[1]=a);let{data:o}=t(a);return o?e.auth.msaV2:e.auth.msa},p=e=>{let r=(0,d.c)(7),i=f(),{pathname:a}=s(),o=n(),c;r[0]===o.queries.UNSAFE_anonymousOnlyConfiguration?c=r[1]:(c=o.queries.UNSAFE_anonymousOnlyConfiguration.getOptions(`auth.xbox.sandboxId`),r[0]=o.queries.UNSAFE_anonymousOnlyConfiguration,r[1]=c);let{data:u}=t(c),p;if(r[2]!==u||r[3]!==e||r[4]!==a||r[5]!==i.login){let t=l(u,`auth.xbox.sandboxId`)||void 0;p=i.login.$buildPath({searchParams:{returnUrl:e??a,sandboxId:t}}),r[2]=u,r[3]=e,r[4]=a,r[5]=i.login,r[6]=p}else p=r[6];return p},m=t=>{let n=(0,d.c)(10),r;n[0]===t?r=n[1]:(r=t===void 0?{}:t,n[0]=t,n[1]=r);let{innerLocation:l,returnUrl:f}=r,{trackEvent:m,location:h}=c(l),g=u(),{pathname:_}=s(),{isSupportedTVBrowser:v}=o(),y=p(f??_),b;return n[2]!==h||n[3]!==v||n[4]!==y||n[5]!==m||n[6]!==g||n[7]!==f||n[8]!==_?(b=()=>{m({name:i.AttemptToSignIn,subType:a.UserInitiated,location:h,targetAuthRoute:v?e.auth.deviceCode.$path():y.split(`?`)[0]}),g(v?e.auth.deviceCode.$buildPath({searchParams:{returnUrl:f??_}}):y)},n[2]=h,n[3]=v,n[4]=y,n[5]=m,n[6]=g,n[7]=f,n[8]=_,n[9]=b):b=n[9],b},h=e=>{let t=(0,d.c)(4),n=f(),{pathname:r}=s(),i;return t[0]!==e||t[1]!==r||t[2]!==n.logout?(i=n.logout.$buildPath({searchParams:{returnUrl:e??r}}),t[0]=e,t[1]=r,t[2]=n.logout,t[3]=i):i=t[3],i},g=t=>{let n=(0,d.c)(10),r;n[0]===t?r=n[1]:(r=t===void 0?{}:t,n[0]=t,n[1]=r);let{returnUrl:i}=r,a=u(),o;n[2]===i?o=n[3]:(o=i??e.home.$path(),n[2]=i,n[3]=o);let s=h(o),c;n[4]!==a||n[5]!==s?(c=()=>{a(s)},n[4]=a,n[5]=s,n[6]=c):c=n[6];let l=c,f;return n[7]!==l||n[8]!==s?(f={signOut:l,signOutUrl:s},n[7]=l,n[8]=s,n[9]=f):f=n[9],f};export{m as n,g as t};