PageSourceSearch

https://app.calypsocopilot.com/static/js/auth-callback.39f44d87.chunk.js

js calypsocopilot.com collected 2026-10-05 11:30:31 UTC 2,080 bytes, 2 lines download raw bytes

1"use strict";(self.webpackChunkcalypso=self.webpackChunkcalypso||[]).push([[8987],{71140:(e,a,t)=>{t.r(a),t.d(a,{default:()=>u});var s=t(65043),i=t(73216),o=t(48879),n=t(29619),r=t(16032),c=t(22024),l=t(70579);const u=()=>{const e=(0,i.Zp)(),[a,t]=(0,s.useState)("Processing authentication...");return(0,s.useEffect)((()=>{(async()=>{try{const a=new URLSearchParams(window.location.search),s=a.get("code"),i=a.get("state"),c=sessionStorage.getItem("auth_state");if(!s)throw new Error("No authorization code received");if(i!==c)throw new Error("Invalid state parameter");t("Exchanging authorization code...");const l=await fetch("https://exchangeauthcode-ykqcqjd5ja-uc.a.run.app",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({code:s})});if(!l.ok)throw new Error("Failed to exchange authorization code");const{customToken:u,userInfo:d}=await l.json();t("Signing in to Firebase...");const h=(await(0,n.p)(o.auth,u)).user;t("Setting up user profile...");const p=(0,r.aU)(),m=(0,r.H9)(p,"users",h.uid),w=await(0,r.x7)(m);w.exists()&&w.data().email&&!1!==w.data().hasPaid||await(0,r.BN)(m,{email:d.email,hasPaid:!1,professional:!1,signUpTime:(0,r.O5)(),displayName:d.name},{merge:!0}),e("/live"),sessionStorage.removeItem("auth_state")}catch(a){console.error("Authentication callback error:",a),t("Authentication failed: ".concat(a.message)),setTimeout((()=>{e("/")}),3e3)}})()}),[e]),(0,l.jsx)("main",{className:"app-route-canvas flex min-h-screen items-center justify-center p-6",children:(0,l.jsxs)("section",{className:"app-route-surface app-route-border flex w-full max-w-md flex-col items-center gap-5 rounded-lg border px-6 py-10 text-center shadow-sm","aria-live":"polite","aria-busy":"true",children:[(0,l.jsx)(c.A,{className:"h-9 w-9 animate-spin text-indigo-500","aria-hidden":"true"}),(0,l.jsx)("h1",{className:"text-lg font-semibold",children:a}),(0,l.jsx)("p",{className:"app-route-muted text-sm leading-6",children:"Please wait while we complete your authentication."})]})})}}}]);
2//# sourceMappingURL=auth-callback.39f44d87.chunk.js.map

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.