PageSourceSearch

https://talktoedgar.ai/_next/static/chunks/pages/account/details/[teamId]-5cb7a55a0b01a635.js

js talktoedgar.ai collected 2026-10-05 12:43:42 UTC 16,873 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[73],{3240:(e,s,r)=>{"use strict";r.r(s),r.d(s,{__N_SSP:()=>M,default:()=>C});var t=r(37876),l=r(77328),i=r.n(l),a=r(50774),n=r(70203),c=r(74539),d=r(59419),o=r(1476),m=r(42360),u=r(48230),p=r.n(u),x=r(43461),h=r(14232),f=r(32980),b=r(61902),j=r(56680),g=r(26283),_=r(4241),v=r(30552),N=r(18498),y=r(82951),w=r(62538),k=r(89099),P=r(20899);let A=e=>{let{open:s,onOpenChange:r,currentTeamPlanKey:l,isRenewal:i,replaceUrl:a}=e,n=(0,k.useRouter)(),c=h.useCallback(()=>{if(!l)return[];let e=f.kz[l],s=[];return s.push("".concat(Intl.NumberFormat("en-US",{}).format(e.max_users||0)," users")),s.push("".concat(e.max_messages.unlimitedQueries?"Unlimited":Intl.NumberFormat("en-US",{}).format(e.max_messages.queries||0)," queries per month")),"free"===l?(s.push("Access to filings and news releases from the last 12 months"),s.push("Share your AI chat transcripts")):(s.push("Unlimited access to filings and news releases"),s.push("Share your AI chat transcripts"),s.push("Export reports"),s.push("Highlight document sections for targeted AI analysis"),"premium"===l?s.push("AI document comparison for 2 documents"):"pro"===l&&(s.push("AI document comparison for multiple documents"),s.push("AI company comparison"))),s},[l]),d=h.useCallback(()=>{r(!1),a&&n.replace(a,void 0,{shallow:!0})},[r,a,n]);return(0,t.jsx)(P.Lt,{open:s,onOpenChange:r,children:(0,t.jsxs)(P.EO,{className:"max-w-md",children:[(0,t.jsx)(P.wd,{children:(0,t.jsxs)(P.r7,{className:"text-center",children:["Subscription Successfully ",i?"Renewed":"Updated"]})}),l&&(0,t.jsxs)("div",{className:"mt-2 text-center",children:[(0,t.jsxs)("p",{className:"mb-2 font-semibold text-primary",children:["Your"," ",l.charAt(0).toUpperCase()+l.slice(1)," ","plan includes:"]}),(0,t.jsx)("ul",{className:"list-disc space-y-1 pl-6 text-left",children:c().map((e,s)=>(0,t.jsx)("li",{children:e},s))})]}),(0,t.jsx)(P.ck,{children:(0,t.jsx)(P.Rx,{className:"w-full",onClick:d,children:"Continue"})})]})})},I=(0,_.c)(x._.NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY);var M=!0;let C=e=>{var s,r,l,u,_,P,M,C,E,S,R,U,T,D,q;let{app:F}=e,O=(0,k.useRouter)(),{selectedTeam:z}=(0,w.dA)(),{data:B}=(0,a.wV)(),L=(0,f.yz)();h.useEffect(()=>{var e,s;let r=null==B||null==(e=B.user)?void 0:e.primaryTeamConnection;(null==z||null==(s=z.team)?void 0:s.id)!==(null==r?void 0:r.team.id)&&O.push("/account/team")},[B,z]);let Q=null==B||null==(l=B.user)||null==(r=l.primaryTeamConnection)||null==(s=r.team)?void 0:s.id,X=null==B||null==(P=B.user)||null==(_=P.primaryTeamConnection)||null==(u=_.team)?void 0:u.subscription,Y=null==X?void 0:X.stripeProductId;null==B||null==(C=B.user)||null==(M=C.primaryTeamConnection)||M.teamRole;let G=h.useMemo(()=>(0,f.CE)(Y),[Y]),$=null==G?void 0:G.key,[H,J]=h.useState(!1),[W,K]=h.useState(null),{showSuccessDialog:V,setShowSuccessDialog:Z,storeSubscriptionData:ee}=function(e){let{currentSubscription:s,successQueryParam:r="subscription-success",localStorageKey:t="previousSubscription"}=e,l=(0,k.useRouter)(),[i,a]=(0,h.useState)(!1),[n,c]=(0,h.useState)(null);return(0,h.useEffect)(()=>{s&&!n?c(s):s&&n&&s.stripeProductId!==n.stripeProductId&&(a(!0),c(s))},[s,n]),(0,h.useEffect)(()=>{let e=localStorage.getItem(t);if("1"===l.query[r]&&s)if(e)try{let r=JSON.parse(e);r.stripeProductId&&r.stripeProductId===s.stripeProductId||a(!0),localStorage.removeItem(t)}catch(e){console.error("Error parsing stored subscription",e),localStorage.removeItem(t)}else a(!0)},[l.query,s,l,r,t]),{showSuccessDialog:i,setShowSuccessDialog:a,storeSubscriptionData:(0,h.useCallback)(()=>{s&&localStorage.setItem(t,JSON.stringify({id:s.id,stripeProductId:s.stripeProductId}))},[s,t]),isSubscriptionChanged:n&&s&&n.stripeProductId!==s.stripeProductId}}({currentSubscription:X});h.useEffect(()=>{J(!1)},[Q]);let es=o.F.stripe.createCheckoutSession.useMutation({onSuccess:e=>{K({stripe_client_secret:e.stripe_client_secret,team_id:e.team_id,product_id:e.product_id})}});h.useEffect(()=>{H&&(null==es||es.mutate({product_id:H,team_id:Q}))},[H]);let er=!((null==W?void 0:W.stripe_client_secret)&&(null==W?void 0:W.product_id)===H&&(!Q||Q===(null==W?void 0:W.team_id))),et=o.F.stripe.createPortalSession.useMutation({onSuccess:e=>{console.log("createPortalSession onSuccess",e),e.url&&(ee(),window.location.href=e.url)},onError:e=>{console.error("Error accessing customer portal:",e)}}),el=h.useCallback(async()=>{var e;(null==z||null==(e=z.team)?void 0:e.id)&&et.mutate({teamId:z.team.id,returnUrl:"".concat(x._.NEXT_PUBLIC_APP_URL,"/account/details/").concat(z.team.id,"?subscription-success=1")})},[et,null==z||null==(E=z.team)?void 0:E.id]),ei=h.useMemo(()=>!!X&&!!X.endedAt,[X]),ea=e=>(0,t.jsx)("ul",{className:"text-body ai-pricing-list ai-pricing-list--checkmark primary list-none text-base font-medium",children:f.MY.map(s=>{let r=s.plans[e];if(!1===r||void 0===r)return null;let l=s.getDisplayText?s.getDisplayText(e,r):s.text;return(0,t.jsx)("li",{children:l},s.id)})}),{data:en}=o.F.beta.status.useQuery();return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(i(),{children:(0,t.jsxs)("title",{children:["Manage Account - Account Details - ",m.mZ[F]]})}),(0,t.jsxs)(c.A,{className:"gradient-light-bg",containerClassName:"container flex-1 w-full px-4 md:px-10 pt-5 md:pt-5 flex flex-col gap-5",withAuth:!0,children:[(0,t.jsx)(v.Qp,{children:(0,t.jsxs)(v.AB,{children:[(0,t.jsx)(v.J5,{children:(0,t.jsx)(v.w1,{asChild:!0,children:(0,t.jsx)(p(),{href:"/dashboard",children:"Home"})})}),(0,t.jsx)(v.tH,{children:"/"}),(0,t.jsx)(v.J5,{children:(0,t.jsx)(v.tJ,{children:"Manage Account"})})]})}),(0,t.jsx)("h1",{className:"font-body text-xl font-bold md:text-3xl",children:"Manage Account"}),(0,t.jsxs)("div",{className:"container mx-auto mb-8 max-w-[960px]",children:[(0,t.jsx)(n.tU,{defaultValue:"account-details",className:"mb-6 w-full overflow-x-auto",variant:"underline-secondary",children:(0,t.jsxs)(n.j7,{className:"w-full min-w-[500px]",align:"start",children:[(0,t.jsx)(n.Xi,{value:"my-profile",asChild:!0,children:(0,t.jsx)(p(),{href:"/account/profile",children:"My Profile"})}),(0,t.jsx)(y.A,{teamId:null!=(D=null==z||null==(S=z.team)?void 0:S.id)?D:"",allowedRoles:["OWNER"],checkMembers:!1,children:(0,t.jsx)(n.Xi,{value:"account-details",asChild:!0,children:(0,t.jsx)(p(),{href:"/account/details/".concat(null==z||null==(R=z.team)?void 0:R.id),children:"Account Details"})})}),(0,t.jsx)(y.A,{teamId:null!=(q=null==z||null==(U=z.team)?void 0:U.id)?q:"",allowedRoles:["OWNER"],checkMembers:!1,children:(0,t.jsx)(n.Xi,{value:"billing",asChild:!0,children:(0,t.jsx)(p(),{href:"/account/billing/".concat(null==z||null==(T=z.team)?void 0:T.id),children:"Billing"})})}),(0,t.jsx)(n.Xi,{value:"team",asChild:!0,children:(0,t.jsx)(p(),{href:"/account/team",children:"Team"})})]})}),(0,t.jsxs)("div",{className:"space-y-6",children:[(null==en?void 0:en.isBeta)&&(0,t.jsx)("div",{className:"rounded-xl border border-purple-200 bg-purple-50 p-6 dark:border-purple-900 dark:bg-purple-950/20",children:(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"text-lg font-bold text-purple-900 dark:text-purple-100",children:"Beta Program"}),(0,t.jsx)("p",{className:"mt-1 text-sm text-purple-700 dark:text-purple-300",children:"You are enrolled in the Beta Program."})]}),(0,t.jsxs)("div",{className:"text-right",children:[(0,t.jsxs)("span",{className:"text-2xl font-bold text-purple-700 dark:text-purple-300",children:[Math.max(0,(en.credits||0)-(en.spent||0))," / ",en.credits]}),(0,t.jsx)("span",{className:"block text-xs uppercase tracking-wider text-purple-600/70",children:"Remaining Credits"})]})]})}),H?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(g.$,{variant:"link-secondary",onClick:()=>J(!1),className:"mb-4",children:"Back to Account Details"}),er?(0,t.jsx)("div",{className:"flex h-[400px] w-full items-center justify-center p-8",children:(0,t.jsx)(d.default,{})}):(0,t.jsx)("div",{id:"checkout",children:(0,t.jsx)(b.EmbeddedCheckoutProvider,{stripe:I,options:{clientSecret:null==W?void 0:W.stripe_client_secret},children:(0,t.jsx)(b.EmbeddedCheckout,{})})})]}):(0,t.jsxs)("div",{className:"items-strech mb-5 flex min-h-[772px] w-full justify-between max-md:flex-wrap md:mb-20",children:[(0,t.jsxs)("div",{className:(0,j.cn)("max-md:mb-10 max-md:basis-full","flex shrink-0 grow-0 basis-[calc(33.33%-13.33px)] flex-col justify-start overflow-hidden rounded-xl"),children:[(0,t.jsxs)("div",{className:"flex flex-col p-6 md:min-
1h-[275px]",children:[(0,t.jsxs)("div",{className:"mb-3 flex items-center justify-between border-b-2 pb-3",children:[(0,t.jsx)("h2",{className:"font-body text-md font-bold",children:"Free"}),(0,t.jsxs)("span",{className:"border-primary font-body text-lg font-bold",children:[L," $",f.kz.free.price]})]}),(0,t.jsxs)("div",{className:"flex flex-1 flex-col",children:[(0,t.jsx)("p",{className:"mb-4 font-body text-base font-medium text-primary",children:"Individual investors conducting basic research and exploring recent filings and news releases."}),(0,t.jsx)("div",{className:"mt-auto",children:(0,t.jsx)(g.$,{className:"w-full rounded-full disabled:opacity-90",variant:"outline-cool-slate-dark",size:"md",onClick:()=>{"free"===$||ei||el()},disabled:ei,children:"free"===$?"Current Plan":"Downgrade to Free"})})]})]}),(0,t.jsxs)("div",{className:(0,j.cn)("p-[20px_30px] md:min-h-[420px]"),children:[(0,t.jsx)("h3",{className:"mb-2.5 font-body text-base font-bold leading-none tracking-[-0.18px]",children:"Plan Includes:"}),ea("free")]})]}),(0,t.jsxs)("div",{className:(0,j.cn)("max-md:mb-10 max-md:basis-full","flex shrink-0 grow-0 basis-[calc(33.33%-13.33px)] flex-col justify-start overflow-hidden rounded-xl"),children:[(0,t.jsxs)("div",{className:"flex flex-col p-6 md:min-h-[275px]",children:[(0,t.jsxs)("div",{className:"mb-3 flex items-start justify-between border-b-2 pb-3",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h2",{className:"font-body text-md font-bold",children:"Premium"}),"premium"===$&&(null==X?void 0:X.currentPeriodEnd)&&(0,t.jsx)("div",{className:"font-body text-xs text-primary",children:X.endedAt?"Expired on ".concat((0,N.GP)(new Date(X.endedAt),"MMMM dd")):X.canceledAt?"Canceled at ".concat((0,N.GP)(new Date(X.canceledAt),"MMMM dd"),", Ends on ").concat((0,N.GP)(new Date(X.currentPeriodEnd),"MMMM dd")):"Renews on ".concat((0,N.GP)(new Date(X.currentPeriodEnd),"MMMM dd"))})]}),(0,t.jsxs)("span",{className:"border-primary font-body text-lg font-bold",children:[L," $",f.kz.premium.price,"/mth"]})]}),(0,t.jsxs)("div",{className:"flex flex-1 flex-col",children:[(0,t.jsx)("p",{className:"mb-4 font-body text-base font-medium text-primary",children:"Professionals or small teams conducting moderate filing research."}),(0,t.jsx)("div",{className:"mt-auto",children:(0,t.jsx)(g.$,{className:"w-full rounded-full",variant:("premium"!==$||ei)&&("pro"!==$||ei)?"cool-slate-dark":"outline-cool-slate-dark",size:"md",onClick:()=>{"free"===$||ei?J(f.kz.premium.stripe_product_id):el()},children:"premium"===$?ei?"Renew":"Current Plan":"pro"===$?"Downgrade":"Upgrade to Premium"})})]})]}),(0,t.jsxs)("div",{className:(0,j.cn)("p-[20px_30px] md:min-h-[420px]"),children:[(0,t.jsx)("h3",{className:"mb-2.5 font-body text-base font-bold leading-none tracking-[-0.18px]",children:"Plan Includes:"}),ea("premium")]})]}),(0,t.jsxs)("div",{className:(0,j.cn)("max-md:mb-10 max-md:basis-full","flex shrink-0 grow-0 basis-[calc(33.33%-13.33px)] flex-col justify-start overflow-hidden rounded-xl"),children:[(0,t.jsxs)("div",{className:"flex flex-col p-6 md:min-h-[275px]",children:[(0,t.jsxs)("div",{className:"mb-3 flex items-start justify-between border-b-2 pb-3",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h2",{className:"font-body text-md font-bold",children:"Pro"}),"pro"===$&&(null==X?void 0:X.currentPeriodEnd)&&(0,t.jsx)("div",{className:"font-body text-xs text-primary",children:X.endedAt?"Expired on ".concat((0,N.GP)(new Date(X.endedAt),"MMMM dd")):X.canceledAt?"Canceled at ".concat((0,N.GP)(new Date(X.canceledAt),"MMMM dd"),", Ends on ").concat((0,N.GP)(new Date(X.currentPeriodEnd),"MMMM dd")):"Renews on ".concat((0,N.GP)(new Date(X.currentPeriodEnd),"MMMM dd"))})]}),(0,t.jsxs)("span",{className:"border-primary font-body text-lg font-bold",children:[L," $",f.kz.pro.price,"/mth"]})]}),(0,t.jsxs)("div",{className:"flex flex-1 flex-col",children:[(0,t.jsx)("p",{className:"mb-4 font-body text-base font-medium text-primary",children:"Large teams, institutional investors, or legal departments needing extensive research and advanced tools."}),(0,t.jsx)("div",{className:"mt-auto",children:(0,t.jsx)(g.$,{className:"w-full rounded-full",variant:"pro"!==$||ei?"cool-slate-dark":"outline-cool-slate-dark",size:"md",onClick:()=>{"free"===$||ei?J(f.kz.pro.stripe_product_id):el()},children:"pro"===$?ei?"Renew":"Current Plan":["free","premium"].includes($)?"Upgrade to Pro":"Current Plan"})})]})]}
1),(0,t.jsxs)("div",{className:(0,j.cn)("p-[20px_30px] md:min-h-[420px]"),children:[(0,t.jsx)("h3",{className:"mb-2.5 font-body text-base font-bold leading-none tracking-[-0.18px]",children:"Plan Includes:"}),ea("pro")]})]})]})]})]}),(0,t.jsx)(A,{open:V,onOpenChange:Z,currentTeamPlanKey:$,isRenewal:!!(null==X?void 0:X.endedAt),replaceUrl:{pathname:O.pathname,query:{teamId:O.query.teamId}}})]})]})}},32980:(e,s,r)=>{"use strict";r.d(s,{CE:()=>u,MY:()=>c,kz:()=>i,yz:()=>m});var t=r(43461);let l=t._.NEXT_PUBLIC_APP,i={free:{key:"free",level:1,title:"Free",stripe_product_id:void 0,price:0,max_users:1,max_messages:{queries:25,unlimitedQueries:!1},shareTranscripts:!0,exportReports:!1,compareFeature:{enabled:!0,maxDocuments:2}},premium:{key:"premium",level:2,title:"Premium",stripe_product_id:d("premium"),price:29,max_users:3,max_messages:{queries:250,unlimitedQueries:!1},shareTranscripts:!0,exportReports:!0,compareFeature:{enabled:!0,maxDocuments:2}},pro:{key:"pro",level:3,title:"Pro",stripe_product_id:d("pro"),price:79,max_users:10,max_messages:{queries:600,unlimitedQueries:!0},shareTranscripts:!0,exportReports:!0,compareFeature:{enabled:!0,maxDocuments:6}}},a=(e,s)=>({id:e,text:s,plans:{free:!0,premium:!0,pro:!0}}),n=(e,s,r)=>({id:e,text:s,plans:{free:i.free[r],premium:i.premium[r],pro:i.pro[r]}}),c=Object.values({users:{id:"users",text:"users",plans:{free:i.free.max_users,premium:i.premium.max_users,pro:i.pro.max_users},getDisplayText:(e,s)=>"".concat(Intl.NumberFormat("en-US",{}).format(s||0)," users")},queries:{id:"queries",text:"queries per month",plans:{free:i.free.max_messages.unlimitedQueries?"Unlimited":i.free.max_messages.queries,premium:i.premium.max_messages.unlimitedQueries?"Unlimited":i.premium.max_messages.queries,pro:i.pro.max_messages.unlimitedQueries?"Unlimited":i.pro.max_messages.queries},getDisplayText:(e,s)=>{let r=i[e].max_messages.unlimitedQueries?"Unlimited":Intl.NumberFormat("en-US",{}).format(i[e].max_messages.queries||0);return"".concat(r," queries per month")}},filings_access:{id:"filings_access",text:"Access to filings and news releases",plans:{free:"from the last 12 months",premium:"Unlimited access to filings and news releases",pro:"Unlimited access to filings and news releases"},getDisplayText:(e,s)=>s.startsWith("Unlimited")?s:"Access to filings and news releases ".concat(s)},document_comparison:{id:"document_comparison",text:"AI document comparison",plans:{free:!0,premium:!0,pro:!0},getDisplayText:(e,s)=>"AI document comparison ".concat("string"==typeof s&&"true"!==s?s:"")},company_comparison:a("company_comparison","AI company comparison"),highlight_sections:a("highlight_sections","Highlight document sections for targeted AI analysis"),share_transcripts:n("share_transcripts","Share your AI chat transcripts","shareTranscripts"),export_reports:n("export_reports","Export reports","exportReports")});function d(e){if("free"!==e)return({sedar:{dev:{premium:"prod_RfcvuLLVacsZq3",pro:"prod_RfcwxrahiFIwWN"},production:{premium:"prod_RgYj8eg2PCtwcO",pro:"prod_RgYkk9Ww985hER"}},edgar:{dev:{premium:"prod_RfczjUKCatT3xi",pro:"prod_Rfd17ZOwuNKHJf"},production:{premium:"prod_RgYkktuOM3nFle",pro:"prod_RgYkvdSf37utOa"}}})[l][t._.NEXT_PUBLIC_DATA_ENV][e]}let o=Object.values(i);function m(){return"sedar"===l?"CA":"US"}let u=e=>e&&o.find(s=>s.stripe_product_id===e)||i.free},57825:(e,s,r)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/account/details/[teamId]",function(){return r(3240)}])},59419:(e,s,r)=>{"use strict";r.r(s),r.d(s,{default:()=>d});var t=r(37876),l=r(56680),i=r(12853),a=r(3653),n=r(4482),c=r(18500);let d=e=>{let s,{className:r,type:d="pinwheel"}=e;switch(d){case"elipsis":s=i.A;break;case"lines":s=a.A;break;case"pinwheel":s=n.A;break;default:s=c.A}return(0,t.jsx)(s,{className:(0,l.cn)("elipsis"===d?"elipsis-jump":"animate-spin",r)})}}},e=>{e.O(0,[4008,8230,1279,8246,5332,8498,2082,2681,8813,2648,4539,1568,636,6593,8792],()=>e(e.s=57825)),_N_E=e.O()}]);

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.