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]=`712b7548-1046-45a1-9429-579fed2ff4b0`,e._sentryDebugIdIdentifier=`sentry-dbid-712b7548-1046-45a1-9429-579fed2ff4b0`)}catch{}import{o as e}from"./rolldown-runtime-eb2nym32.js";import{Ag as t,Fg as n,ch as r,dn as i,eh as a,lh as o,or as s,pr as c,sh as l,wg as u}from"./entry.client-dr7r6s9a.js";import{n as d}from"./DialogShell-k2jpaw9r.js";import{t as f}from"./ConfirmationDialog-lzvdkfji.js";var p=e(s(),1),m=n(),h=t(),g=i(e=>{let t=(0,m.c)(19),{onQuit:n,onCancel:r}=e,{t:i}=o(`AppQuitDialog`),{locCancel:s}=a(),c;t[0]===i?c=t[1]:(c=i(`Quit the Xbox app?`,{shortKey:`quit_app`}),t[0]=i,t[1]=c);let l;t[2]===i?l=t[3]:(l=i(`Thanks for playing!`,{shortKey:`quit_app_body`}),t[2]=i,t[3]=l);let u;t[4]===i?u=t[5]:(u=i(`Quit app`,{shortKey:`quit_app_quit_button`}),t[4]=i,t[5]=u);let d;t[6]!==u||t[7]!==n?(d={text:u,onPress:n,kind:`destructive`},t[6]=u,t[7]=n,t[8]=d):d=t[8];let p;t[9]===s?p=t[10]:(p=s(),t[9]=s,t[10]=p);let g;t[11]!==p||t[12]!==r?(g={text:p,onPress:r},t[11]=p,t[12]=r,t[13]=g):g=t[13];let _;return t[14]!==c||t[15]!==l||t[16]!==d||t[17]!==g?(_=(0,h.jsx)(f,{title:c,prompt:l,firstButton:d,secondButton:g}),t[14]=c,t[15]=l,t[16]=d,t[17]=g,t[18]=_):_=t[18],_},()=>{let{applicationLifecycle:{mutations:e},dialog:{mutations:t}}=l(),{mutate:n}=u(e.quitApp.getOptions()),{mutate:i}=u(t.goBack.getOptions()),{trackUserAction:a}=r();return{onQuit:()=>{n()},onCancel:()=>{a(`AppQuitCancelQuit`,{},`Press`,{location:`AppQuitDialog`}),i()}}}),_=()=>{let e=(0,m.c)(9),t=d.useComponent(),n=g.useComponent(),{t:r}=o(`AppQuitDialog`),i;e[0]===r?i=e[1]:(i=r(`Quit App Dialog`,{shortKey:`app_quit_dialog_accessible_title`}),e[0]=r,e[1]=i);let a;e[2]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,p.default)(f.CONTAINER_CLASSNAME,`modal-medium modal-floating`),e[2]=a):a=e[2];let s;e[3]===n?s=e[4]:(s=(0,h.jsx)(c,{location:`AppQuitDialog`,children:(0,h.jsx)(n,{})}),e[3]=n,e[4]=s);let l;return e[5]!==t||e[6]!==i||e[7]!==s?(l=(0,h.jsx)(t,{autoHeight:!0,accessibleTitle:i,className:a,children:s}),e[5]=t,e[6]=i,e[7]=s,e[8]=l):l=e[8],l};export{_ as AppQuitDialog,_ as default};