PageSourceSearch

https://tesana.com/assets/DevicesAppsPage-_ExWtn9X.js

js tesana.com collected 2026-10-09 22:40:31 UTC 11,678 bytes, 1 lines download raw bytes

1import{j as e}from"./vendor-motion-hRg_q8lq.js";import{r as l}from"./vendor-react-E98sgxjj.js";import{u as A,a as S}from"./vendor-query-bOUN_gKe.js";import{du as n}from"./vendor-fa-Bn2dnpnC.js";import{v as D,s as p,j as h,A as P,u as T,b as _,c as C,P as O,d as f}from"./index-BKzE8EQ8.js";import{u as U}from"./useNotifications-CrW-0d5F.js";import{u as E}from"./useCanUseDesktopApp-CjJ0K-dR.js";import{U as L}from"./index-i1nPji9k.js";import{P as Y}from"./paywall-CG7xVZtx.js";import{S as F}from"./SettingsPageShell-wmP4-RpH.js";import"./plans-CbMJY2XS.js";import"./pricingExperiments-zMZby8z7.js";import"./useLocaleNavigate-BNriJdRU.js";import"./organization-BuGhuc22.js";function I(){const[s,o]=l.useState(!1),[m,r]=l.useState(null);return{download:l.useCallback(async a=>{o(!0),r(null),D("Desktop Download Started",{platform:a,in_app:p});try{const{download_url:i}=await h.desktopDownloadToken(a);p?await P(i):window.location.href=i}catch(i){console.warn("[desktop-download] token mint failed",i),r("Could not start the download — please try again.")}finally{o(!1)}},[]),downloading:s,error:m}}const v="https://apps.apple.com/us/app/ai-game-maker-tesana/id6747117832",M=[{id:"macos",label:"macOS (Apple Silicon)",icon:"apple",iconType:"fab",platform:"macos"},{id:"macos-intel",label:"macOS (Intel)",icon:"apple",iconType:"fab",platform:null,comingSoon:!0},{id:"windows",label:"Windows",icon:"windows",iconType:"fab",platform:null,comingSoon:!0},{id:"ios",label:"iPhone",icon:"app-store-ios",iconType:"fab",platform:null,href:v}];function ee(){const{t:s}=T("settings"),{user:o}=_(),{isLight:m}=C(),r=E(),{download:g,downloading:a}=I(),[i,u]=l.useState(!1),{permission:d,requestPermission:N,loading:b}=U(),{data:c,refetch:w}=A({queryKey:["notification-preferences"],queryFn:h.getNotificationPreferences,enabled:!!o}),y=S({mutationFn:h.updateNotificationPreferences,onSuccess:()=>{w()}}),x=o?!o.has_password:!1,j=t=>{if(!a){if(!r){u(!0);return}g(t)}};return e.jsxs(F,{title:s("pages.devicesApps.pageTitle","Devices & apps | Tesana"),heading:s("pages.devicesApps.heading","Devices & apps"),subtitle:s("pages.devicesApps.subtitle","Install Tesana on your devices, and manage what’s connected to your account."),children:[e.jsxs("section",{className:"mb-8",children:[e.jsx("h2",{className:"text-lg text-foreground",children:s("devicesApps.onYourDesktop","On your desktop")}),e.jsx("p",{className:"text-sm text-muted-foreground mt-1 mb-4",children:s("devicesApps.onYourDesktopSub","Native 3D, local builds, and a synced code editor.")}),e.jsxs("div",{className:"relative overflow-hidden rounded-lg border border-border bg-card",children:[e.jsx("div",{"aria-hidden":!0,className:"pointer-events-none absolute inset-y-0 right-0 w-2/3 bg-gradient-to-l from-accent/[0.14] via-accent/[0.05] to-transparent"}),e.jsx("div",{"aria-hidden":!0,className:"pointer-events-none absolute -right-[136px] -top-[152px] h-[368px] w-[368px] bg-[radial-gradient(closest-side,color-mix(in_srgb,var(--color-accent)_8%,transparent),transparent)]"}),e.jsxs("div",{className:"relative p-6 sm:max-w-[70%]",children:[e.jsx("span",{className:"mb-4 flex h-11 w-11 items-center justify-center rounded-xl bg-foreground
1/[0.06] ring-1 ring-border",children:e.jsx(O,{src:m?"/logos/logo-black.png":"/logos/logo.png",alt:"","aria-hidden":!0,className:"h-6 w-6 object-contain"})}),e.jsx("h3",{className:"text-base text-foreground",children:s("devicesApps.desktopTitle","Tesana for macOS")}),e.jsx("p",{className:"mt-1 mb-5 text-sm text-muted-foreground",children:p?s("devicesApps.desktopInstalled","You’re using the desktop app on this device."):r?s("devicesApps.desktopAvailable","Build cinematic 3D games that go beyond the browser, with your project files synced to your machine."):s("devicesApps.desktopLocked","Build cinematic 3D games that go beyond the browser, with your project files synced to your machine. Available on Ultra.")}),p?e.jsxs("span",{className:"inline-flex h-9 items-center gap-2 rounded-md bg-emerald-500/15 px-3 text-sm font-medium text-emerald-400",children:[e.jsx(n,{icon:["far","circle-check"],className:"text-xs"}),s("devicesApps.installed","Installed")]}):r?e.jsxs("button",{onClick:()=>j("macos"),disabled:a,className:"inline-flex h-9 cursor-pointer items-center gap-2 rounded-md bg-foreground px-4 text-sm font-medium text-background transition-opacity hover:opacity-80 disabled:opacity-30",children:[a?e.jsx("span",{className:"h-3 w-3 animate-spin rounded-full border-2 border-background/30 border-t-background"}):e.jsx(n,{icon:["fab","apple"],className:"text-sm"}),s("devicesApps.downloadForMac","Download for macOS (Apple Silicon)")]}):e.jsxs("button",{onClick:()=>u(!0),className:"inline-flex h-9 cursor-pointer items-center gap-2 rounded-md bg-amber-500 px-4 text-sm font-medium text-black transition-opacity hover:opacity-90",children:[e.jsx(n,{icon:["fas","lock"],className:"text-xs"}),s("devicesApps.unlockWithUltra","Unlock with Ultra")]})]})]})]}),e.jsxs("section",{className:"mb-8",children:[e.jsx("h2",{className:"text-lg text-foreground",children:s("devicesApps.onYourPhone","On your phone")}),e.jsx("p",{className:"text-sm text-muted-foreground mt-1 mb-4",children:s("devicesApps.onYourPhoneSub","Make and play games wherever you are.")}),e.jsxs("div",{className:"flex items-center justify-between gap-4 rounded-lg border border-border bg-card p-6",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("span",{className:"flex h-11 w-11 shrink-0 items-center justify-center rounded-xl bg-foreground
1/[0.06] text-foreground ring-1 ring-border",children:e.jsx(n,{icon:["far","mobile"],className:"text-lg"})}),e.jsxs("div",{children:[e.jsx("p",{className:"text-base text-foreground",children:s("devicesApps.mobileTitle","Tesana for iPhone")}),e.jsx("p",{className:"mt-0.5 text-sm text-muted-foreground",children:s("devicesApps.mobileSub","Free on the App Store. Android is coming soon.")})]})]}),e.jsxs("a",{href:v,target:"_blank",rel:"noopener noreferrer",className:"inline-flex h-9 shrink-0 items-center gap-2 rounded-md bg-foreground/[0.06] px-4 text-sm font-medium text-foreground transition-colors hover:bg-foreground/10",children:[e.jsx(n,{icon:["fab","app-store-ios"],className:"text-sm"}),s("devicesApps.appStore","App Store")]})]})]}),e.jsxs("section",{className:"mb-8",children:[e.jsx("h2",{className:"text-lg text-foreground",children:s("devicesApps.allDownloads","All downloads")}),e.jsx("p",{className:"text-sm text-muted-foreground mt-1 mb-4",children:s("devicesApps.allDownloadsSub","Pick the installer that matches your machine.")}),e.jsx("div",{className:"rounded-lg border border-border bg-card",children:M.map((t,k)=>e.jsxs("div",{className:f("flex items-center justify-between gap-4 px-6 py-4",k>0&&"border-t border-border"),children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx(n,{icon:[t.iconType,t.icon],className:f("w-4 text-center text-sm",t.comingSoon?"text-muted-foreground/50":"text-muted-foreground")}),e.jsx("span",{className:f("text-sm",t.comingSoon?"text-muted-foreground":"text-foreground"),children:t.label})]}),t.comingSoon?e.jsx("span",{className:"text-xs text-muted-foreground/70",children:s("devicesApps.comingSoon","Coming soon")}):t.href?e.jsx("a",{href:t.href,target:"_blank",rel:"noopener noreferrer",className:"inline-flex h-8 items-center rounded-md bg-foreground
1/[0.06] px-3 text-xs font-medium text-foreground transition-colors hover:bg-foreground/10",children:s("devicesApps.getApp","Get")}):e.jsxs("button",{onClick:()=>t.platform&&j(t.platform),disabled:a,className:"inline-flex h-8 cursor-pointer items-center gap-1.5 rounded-md bg-foreground/[0.06] px-3 text-xs font-medium text-foreground transition-colors hover:bg-foreground/10 disabled:opacity-40",children:[!r&&e.jsx(n,{icon:["fas","lock"],className:"text-[9px] text-amber-500"}),s("devicesApps.download","Download")]})]},t.id))})]}),e.jsxs("section",{className:"mb-8",children:[e.jsx("h2",{className:"text-lg text-foreground mb-4",children:s("devicesApps.thisDevice","This device")}),e.jsx("div",{className:"bg-card rounded-md border border-border p-6",children:e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsxs("div",{children:[e.jsx("p",{className:"text-base text-foreground",children:s("notifications.pushNotifications")}),e.jsx("p",{className:"text-sm text-muted-foreground mt-1",children:s(d==="granted"?"notifications.pushGranted":d==="denied"?"notifications.pushDenied":"notifications.pushDefault")})]}),d==="granted"?e.jsx("button",{onClick:()=>y.mutate({push_enabled:!c?.push_enabled}),className:"relative w-14 h-8 rounded-full transition-colors duration-300 cursor-pointer flex-shrink-0",style:{backgroundColor:c?.push_enabled?"var(--color-green-500)":"var(--color-surface)"},children:e.jsx("div",{className:`absolute top-1 w-6 h-6 rounded-full ${c?.push_enabled?"bg-foreground":"bg-background"} shadow-sm transition-all duration-300`,style:{left:c?.push_enabled?"calc(100% - 28px)":"4px"}})}):e.jsxs("button",{onClick:N,disabled:b||d==="denied",className:"h-9 px-4 rounded-md text-sm bg-foreground text-background hover:opacity-80 transition-opacity disabled:opacity-30 flex items-center gap-2 cursor-pointer",children:[b&&e.jsx("span",{className:"w-3 h-3 border-2 border-white/30 border-t-white rounded-full animate-spin"}),s(d==="denied"?"notifications.blocked":"notifications.enable")]})]})})]}),e.jsxs("section",{className:"mb-8",children:[e.jsx("h2",{className:"text-lg text-foreground mb-4",children:s("devicesApps.connectedApps","Connected apps")}),e.jsxs("div",{className:"bg-card rounded-md border border-border",children:[e.jsxs("div",{className:"flex items-center justify-between p-6 border-b border-border",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-9 h-9 rounded-full bg-[#5865F2]/15 text-[#5865F2] flex items-center justify-center text-sm shrink-0",children:e.jsx(n,{icon:["fab","discord"]})}),e.jsxs("div",{children:[e.jsx("p",{className:"text-base text-foreground",children:"Discord"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",children:x?s("devicesApps.discordConnected","You sign in to Tesana with Discord."):s("devicesApps.discordNotConnected","Not connected — you sign in with email and password.")})]})]}),e.jsx("span",{className:`text-xs px-2.5 py-1 rounded-full font-medium shrink-0 ${x?"bg-emerald-500/15 text-emerald-400":"bg-foreground
1/8 text-muted-foreground"}`,children:x?s("devicesApps.connected","Connected"):s("devicesApps.notConnected","Not connected")})]}),e.jsxs("div",{className:"flex items-center justify-between p-6",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-9 h-9 rounded-full bg-foreground/5 text-muted-foreground flex items-center justify-center text-sm shrink-0",children:e.jsx(n,{icon:["far","envelope"]})}),e.jsxs("div",{children:[e.jsx("p",{className:"text-base text-foreground",children:s("devicesApps.emailPassword","Email & password")}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",children:o?.has_password?s("devicesApps.emailPasswordSet","You can sign in with your email and password."):s("devicesApps.emailPasswordUnset","No password set — add one under Account & Security to also sign in with email.")})]})]}),e.jsx("span",{className:`text-xs px-2.5 py-1 rounded-full font-medium shrink-0 ${o?.has_password?"bg-emerald-500/15 text-emerald-400":"bg-foreground/8 text-muted-foreground"}`,children:o?.has_password?s("devicesApps.enabled","Enabled"):s("devicesApps.notSet","Not set")})]})]})]}),e.jsx(L,{isOpen:i,onClose:()=>u(!1),context:Y.desktopDownloadLocked})]})}export{ee as default};

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.