1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,31333,e=>{"use strict";var t=e.i(24892),r=e.i(50634),i=t["useId".toString()]||(()=>void 0),s=0;function a(e){let[a,n]=t.useState(i());return(0,r.useLayoutEffect)(()=>{e||n(e=>e??String(s++))},[e]),e||(a?`radix-${a}`:"")}e.s(["useId",()=>a])},67881,e=>{"use strict";var t=e.i(88636),r=e.i(91926),i=e.i(94237),s=e.i(47163);let a=(0,i.cva)("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",sm:"h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-9","icon-sm":"size-8","icon-lg":"size-10"}},defaultVariants:{variant:"default",size:"default"}});function n({className:e,variant:i,size:n,asChild:o=!1,...d}){let l=o?r.Slot:"button";return(0,t.jsx)(l,{"data-slot":"button",className:(0,s.cn)(a({variant:i,size:n,className:e})),...d})}e.s(["Button",()=>n])},90768,e=>{"use strict";let t=(0,e.i(10965).default)("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);e.s(["Loader2",()=>t],90768)},69296,e=>{"use strict";var t=e.i(33905);function r(){let e=(0,t.getStackClientApp)();return e||null}async function i(e,t){let i=r();if(!i)return{isError:!0,error:{message:"Stack Auth not configured",code:"NOT_CONFIGURED"}};try{return await i.signInWithCredential({email:e,password:t,noRedirect:!0})}catch(e){return{isError:!0,error:{message:e.message||"Sign in failed",code:e.code||"UNKNOWN_ERROR"}}}}async function s(){let e=r();e&&await e.auth.signOut()}e.s(["signInWithPassword",()=>i,"signOut",()=>s])},15469,e=>{"use strict";var t=e.i(88636),r=e.i(24892),i=e.i(77020),s=e.i(67881),a=e.i(47163);function n({className:e,type:r,...i}){return(0,t.jsx)("input",{type:r,"data-slot":"input",className:(0,a.cn)("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm","focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]","aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",e),...i})}var o=e.i(12262);function d({className:e,...r}){return(0,t.jsx)(o.Root,{"data-slot":"label",className:(0,a.cn)("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",e),...r})}let l=(0,e.i(94237).cva)("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90"}},defaultVariants:{variant:"default"}});function c({className:e,variant:r,...i}){return(0,t.jsx)("div",{"data-slot":"alert",role:"alert",className:(0,a.cn)(l({variant:r}),e),...i})}function u({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"alert-description",className:(0,a.cn)("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",e),...r})}var g=e.i(69296),v=e.i(90768),p=e.i(61655),m=e.i(88105);function f({initialError:e}){let[a,o]=(0,r.useState)(""),[l,f]=(0,r.useState)(""),[x,h]=(0,r.useState)(!1),[b,y]=(0,r.useState)(e||null),j=(0,i.useRouter)(),w=(0,m.useStackApp)(),N=async e=>{e.preventDefault(),h(!0),y(null);try{let e=a.trim(),t=await (0,g.signInWithPassword)(e,l);if(t.isError&&t.error)return void y(t.error.message||"Sign in failed");t.isError||(j.push("/admin"),j.refresh())}catch(e){y(e instanceof Error?e.message:"Failed to sign in. Please check your credentials.")}finally{h(!1)}};return(0,t.jsxs)("div",{className:"w-full space-y-6",children:[b&&(0,t.jsx)(c,{variant:"destructive",children:(0,t.jsx)(u,{children:b})}),(0,t.jsx)("div",{className:"space-y-3",children:w?(0,t.jsx)(p.OAuthButtonGroup,{onLoadingChange:h,onError:e=>y(e.message||"OAuth sign in failed")}):(0,t.jsx)("div",{className:"text-sm text-muted-foreground text-center p-4",children:"OAuth providers are not available. Please check your Stack Auth configuration."})}),(0,t.jsxs)("div",{className:"relative",children:[(0,t.jsx)("div",{className:"absolute inset-0 flex items-center",children:(0,t.jsx)("span",{className:"w-full border-t"})}),(0,t.jsx)("div",{className:"relative flex justify-center text-xs uppercase",children:(0,t.jsx)("span",{className:"bg-background px-2 text-muted-foreground",children:"Or continue with"})})]}),(0,t.jsxs)("form",{onSubmit:N,className:"space-y-4",children:[(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)(d,{htmlFor:"email",children:"Email"}),(0,t.jsx)(n,{id:"email",type:"email",placeholder:"[email protected]",value:a,onChange:e=>o(e.target.value),required:!0,disabled:x,className:"w-full",autoComplete:"email"})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)(d,{htmlFor:"password",children:"Password"}),(0,t.jsx)(n,{id:"password",type:"password",placeholder:"Enter your password",value:l,onCh
1ange:e=>f(e.target.value),required:!0,disabled:x,className:"w-full",autoComplete:"current-password"})]}),(0,t.jsxs)(s.Button,{type:"submit",className:"w-full",disabled:x,children:[x&&(0,t.jsx)(v.Loader2,{className:"mr-2 h-4 w-4 animate-spin"}),"Sign In"]})]})]})}e.s(["LoginForm",()=>f],15469)}]);
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.