1import{m as c,r as m,j as t,S as d,T as e,bi as i,h as x,P as j}from"./index-Ece0SzLF.js";import{d as h}from"./CheckCircle-B4ReeFHk.js";import{d as f}from"./InfoOutlined-CtvbudJx.js";import{u as v}from"./usePricingPlansInfo-Dwjn18Vg.js";import{D as y}from"./DialogContent-CXY4PECt.js";import{C as g}from"./Check-BzZCGlGZ.js";import{T as b}from"./Tooltip-qdTI5Uu7.js";import{D as p}from"./Divider-Bs8bn83h.js";import{D as P}from"./DialogActions-BQQjYYyh.js";import"./index-DZJ5gjct.js";import"./Popper-BtfpxQmG.js";const $=()=>{const{checkoutPlan:n,topupValue:o}=c(r=>r.pricingDialog.checkoutDetails),{planInfo:a}=v(),{planDetails:s}=c(r=>r.workspace),l=m.useMemo(()=>Number((s?.availableDollars||0)+o).toFixed(2),[s?.availableDollars,o]);return t.jsxs(t.Fragment,{children:[t.jsxs(y,{sx:{p:3},children:[t.jsxs(d,{alignItems:"center",justifyContent:"center",mb:3,children:[t.jsx(h,{color:"success",sx:{fontSize:64}}),t.jsxs(e,{variant:"h6",textAlign:"center",children:[n?.entryPoint===i.PRICING_PLANS?"Upgrade":"Top-up"," ","successful"]})]}),t.jsx(d,{direction:"row",alignItems:"flex-start",gap:5,justifyContent:"center",children:n?.entryPoint===i.PRICING_PLANS?t.jsxs(t.Fragment,{children:[t.jsxs("div",{children:[t.jsx(e,{mb:2,variant:"subtitle1",children:"Youâve unlocked:"}),a[n.category].planSummary.map((r,u)=>t.jsxs(e,{variant:"body2",mb:2,display:"flex",alignItems:"center",gap:1,color:"text.secondary",children:[t.jsx(g,{}),typeof r.text=="string"?r.text:r.text(n),r.tooltipText?t.jsx(b,{title:r.tooltipText,children:t.jsx(f,{fontSize:"small"})}):null]},`${n.category}--${u}`))]}),t.jsx(p,{orientation:"vertical",flexItem:!0}),t.jsxs("div",{children:[t.jsx(e,{color:"text.secondary",variant:"body2",mt:2,children:"Current Plan"}),t.jsx(e,{mb:3,variant:"subtitle1",children:a[n.category].title}),t.jsx(e,{color:"text.secondary",variant:"body2",children:"Funds in your account"}),t.jsxs(e,{mb:3,variant:"subtitle1",children:["$",l]})]})]}):t.jsxs(t.Fragment,{children:[t.jsxs("div",{children:[t.jsx(e,{color:"text.secondary",variant:"body2",children:"Top-up amount"}),t.jsxs(e,{variant:"subtitle1",children:["$",o]})]}),t.jsx(p,{orientation:"vertical",flexItem:!0}),t.jsxs("div",{children:[t.jsx(e,{color:"text.secondary",variant:"body2",children:"Current balance"}),t.jsxs(e,{variant:"subtitle1",children:["$",l]})]})]})})]}),t.jsxs(P,{sx:{p:4,gap:2},disableSpacing:!0,children:[n?.entryPoint===i.PRICING_PLANS&&t.jsx(x,{href:j+"/api/reference",variant:"contained",color:"secondary",reloadDocument:!0,children:"Read API Docs"}),t.jsx(x,{onClick:()=>{window.location.reload()},variant:"contained",children:"Continue"})]})]})};export{$ 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.