1import{a as e,i as t,l as n,t as r}from"./functions-GsqwgWIZ.js";import{$ as i,D as a,E as o,L as s,M as c,Q as l,T as u,V as d,Z as f,it as p,j as m,jt as h,w as g,x as _}from"./preload-helper-Bq2w3q-Z.js";import{g as v,t as y}from"./api-BBdzACyN.js";import{i as b}from"./vue-router-DZfuHnfm.js";var x=c({__name:`IconClose`,setup(e){return(e,t)=>(d(),a(`svg`,s(e.$attrs,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`2`,"stroke-linecap":`round`,"stroke-linejoin":`round`,xmlns:`http://www.w3.org/2000/svg`}),[...t[0]||=[g(`path`,{d:`M6 18L18 6M6 6l12 12`},null,-1)]],16))}}),S={key:0},C={class:`fixed inset-0 z-50 flex items-center justify-center p-4`},w={class:`mb-6`},T={class:`text-[#e8eef5] mb-2`},E={class:`text-sm text-[#9ca9ba] leading-relaxed`},D={class:`space-y-6`},O={key:0,class:`bg-[#20b2aa]/10 border border-[#20b2aa]/30 rounded-lg p-4`},k={class:`text-sm text-[#20b2aa] leading-relaxed`},A={class:`flex items-start gap-3`},j=[`innerHTML`],M={class:`flex gap-3 pt-2`},N=[`disabled`],P=c({__name:`guest-login-dialog`,props:{isOpen:{type:Boolean},itch:{type:Boolean,default:!1},steam:{type:Boolean,default:!1}},emits:[`close`],setup(s,{emit:c}){let P=b(),F=c,I=s,L=p(!1),R=p(!1);async function z(){if(!L.value){alert(`Please agree to the Terms and Conditions and Privacy Policy to continue`);return}if(R.value)return;R.value=!0;let e=await v();if(!e||!e.status){alert(`Server is down`),R.value=!1;return}r.storage(`set`,`session`,e.sessionToken),await y(),P.replace(`/entry`)}let B=()=>{I.steam||R.value||(L.value=!1,F(`close`),I.itch&&P.push(`/login`))},V=()=>{window.close()};return f(()=>I.isOpen,e=>{e||(L.value=!1,R.value=!1)}),(r,c)=>(d(),u(_,{to:`body`},[m(t,{"enter-active-class":`transition-opacity duration-200`,"leave-active-class":`transition-opacity duration-200`,"enter-from-class":`opacity-0`,"leave-to-class":`opacity-0`},{default:l(()=>[I.isOpen?(d(),a(`div`,S,[g(`div`,{class:`fixed inset-0 bg-black/60 backdrop-blur-sm z-50`,onClick:B}),g(`div`,C,[m(t,{"enter-active-class":`transition-all duration-200`,"leave-active-class":`transition-all duration-200`,"enter-from-class":`opacity-0 scale-95 translate-y-5`,"leave-to-class":`opacity-0 scale-95 translate-y-5`},{default:l(()=>[s.isOpen?(d(),a(`div`,{key:0,class:`bg-[#253447]/95 backdrop-blur-md rounded-lg p-6 border border-white/10 shadow-2xl max-w-md w-full relative`,onClick:c[2]||=n(()=>{},[`stop`])},[I.steam?o(``,!0):(d(),a(`button`,{key:0,class:`absolute top-4 right-4 text-[#9ca9ba] hover:text-[#e8eef5] transition-colors`,onClick:B},[m(x,{class:`w-5 h-5`})])),g(`div`,w,[g(`h2`,T,h(I.steam?r.$t(`login.acceptTermsTitle`):r.$t(`login.playerAsGuest`)),1),g(`p`,E,h(r.$t(`login.beforeStartReviewTerms`)),1)]),g(`div`,D,[I.steam?o(``,!0):(d(),a(`div`,O,[g(`p`,k,h(r.$t(`login.guestNotice`)),1)])),g(`div`,A,[i(g(`input`,{id:`guest-terms`,"onUpdate:modelValue":c[0]||=e=>L.value=e,type:`checkbox`,class:`mt-1 w-4 h-4 rounded border-white/20 bg-[#1a2332]/60 text-[#20b2aa] focus:ring-2 focus:ring-[#20b2aa]/50 focus:ring-offset-0 cursor-pointer`},null,512),[[e,L.value]]),g(`label`,{for:`guest-terms`,class:`register-tos cursor-pointer`,innerHTML:r.$t(`register.agreeLegal`)},null,8,j)]),g(`div`,M,[g(`button`,{disabled:!L.value||R.value,class:`flex-1 px-6 py-3 bg-[#20b2aa] hover:bg-[#2dd4cb] disabled:bg-[#20b2aa]/30 disabled:cursor-not-allowed text-white rounded-md transition-all duration-200 shadow-lg hover:shadow-[#20b2aa]/50 hover:scale-[1.02] active:scale-[0.98] disabled:hover:scale-100 disabled:shadow-none`,onClick:z},h(I.steam?r.$t(`login.continue`):r.$t(`login.continueAsGuest`)),9,N),g(`button`,{class:`px-6 py-3 bg-[#3a4a5f]/60 hover:bg-[#3a4a5f] text-[#e8eef5] rounded-md transition-all duration-200 border border-white/10`,onClick:c[1]||=e=>I.steam?V():B()},h(I.steam?r.$t(`login.closeApp`):I.itch?r.$t(`login.signIn`):r.$t(`global.cancel`)),1)])])])):o(``,!0)]),_:1})])])):o(``,!0)]),_:1})]))}});export{x as n,P as t};
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.