import{a as g}from"./asyncComputed.1c2e733f.js";import{d as y,eE as _,o as w,u as e,b as l,c as b,ew as x,f as a,w as o,as as p,bG as h,e as C,eH as I}from"./outputWidgets.f4ff73cb.js";import{c}from"./router.579c91e6.js";import"./index.4ca46dd8.js";import{O as k}from"./organization.6b95fee3.js";import{L as v}from"./LoadingContainer.b1642792.js";import{A}from"./Title.8356c432.js";import{A as B}from"./index.38a388d2.js";import{A as D}from"./index.cead1e00.js";import{C as N}from"./Card.c86b7818.js";import"./Form.c8ea7c3d.js";import"./hasIn.c05f2ad3.js";import"./popupNotifcation.d7d31af4.js";import"./record.06ee4427.js";import"./pubsub.f8e50115.js";import"./Base.2cf6cca2.js";import"./TabPane.12230f18.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},n=new Error().stack;n&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[n]="a751c35c-d987-4e4f-bcb0-95a22eefa58a",t._sentryDebugIdIdentifier="sentry-dbid-a751c35c-d987-4e4f-bcb0-95a22eefa58a")}catch{}})();const z={key:1},M={style:{display:"flex","justify-content":"flex-start","font-size":"24px"}},Y=y({__name:"Billing",setup(t){const r=_().params.organizationId,{loading:f,result:m}=g(()=>k.get(r));w(()=>{location.search.includes("upgrade")&&c.showNewMessage("I want to upgrade my plan")});const u=()=>c.showNewMessage("I want to upgrade my plan");return(E,V)=>e(f)?(l(),b(v,{key:0})):(l(),x("div",z,[a(e(B),{justify:"space-between",align:"center"},{default:o(()=>[a(e(A),{level:3},{default:o(()=>[p("Current plan")]),_:1})]),_:1}),a(e(D),{style:{"margin-top":"0"}}),a(e(N),{style:{width:"300px"},title:"Plan"},{extra:o(()=>[a(e(h),{onClick:u},{default:o(()=>[p("Upgrade")]),_:1})]),default:o(()=>{var s,i,d;return[C("div",M,I((d=(i=(s=e(m))==null?void 0:s.billingMetadata)==null?void 0:i.plan)!=null?d:"No active plan"),1)]}),_:1})]))}});export{Y as default};
//# sourceMappingURL=Billing.9cfcc4fa.js.map
