import{h,v as b}from"./vendor-vue-runtime-dom-B2rky8vu.js";import{r as g}from"./card_payment-wDsgHahi.js";import{u as k}from"./PaymentList.vue_vue_type_style_index_0_lang-CtXgs8lX.js";import{u as C}from"./settingsStore-8bwiLMEn.js";import{k as x,u as w}from"./fieldsStore-CQRN0FvQ.js";import{d as B,a as D,f as I,i as R,x as t,B as l}from"./vendor-vue-runtime-core-DwK6Ry68.js";import{t as z,r as p,u as n,i as E}from"./vendor-vue-reactivity-CheHbvBM.js";import{_ as F}from"./vendor-vue3-html2pdf-KR020wX8.js";import"./vendor-vue-shared-DrzsEcag.js";import"./translationsStore-D6vLzgNA.js";import"./vendor-pinia-BSPefQhS.js";import"./convert-case-to-camel-case.utils-CK5dBN7n.js";import"./ProBadge.vue_vue_type_style_index_0_lang-DqDXUf8-.js";import"./appStore-CFAkQG2b.js";import"./OrderFormList.vue_vue_type_style_index_0_lang-D2j7UvcI.js";import"./Button.vue_vue_type_style_index_0_lang-CxqKrtR4.js";import"./RequiredHint.vue_vue_type_style_index_0_lang-DGTCbwUk.js";import"./widget-BSjzAbGy.js";import"./appearanceStore-Cp-euDX2.js";import"./pageBreakerStore-BevSHYnU.js";import"./vendor-vueform-slider-CCH9_7pb.js";import"./vendor-moment-Cv92BTSA.js";import"./vendor-bootstrap-CCU-90um.js";import"./vendor-jspdf-UFhKzYHA.js";import"./vendor-php-date-formatter-DSpPwBF8.js";import"./callbackStore-BhxBUA6V.js";import"./vendor-html2pdf.js-B-tok4Ns.js";import"./vendor-html2canvas-BfYXEYrK.js";const M={class:"ccb-payment-header"},P={class:"ccb-payment-header__label"},V=["name"],q={class:"calc-payment_header__img"},L=["src"],N={class:"ccb-payment-body"},T=B({__name:"Stripe",props:{name:{}},setup(d){const u=d,{name:f}=z(u),o=x(),_=C(),{paymentType:s}=k(),v=p(!1),y=w(),m=p(null),c=p(null);D(async()=>{var e,r;const a=_.getStripeData;if(await o.initializeStripe(a),v.value=!0,o.stripeInstance){c.value=(e=o.stripeInstance)==null?void 0:e.elements();const i=(r=c.value)==null?void 0:r.create("card");i==null||i.mount(m.value),o.setCardComponent(i)}});const S=a=>{y.checkRequiredFields()||a.preventDefault()};return(a,e)=>(R(),I("div",{class:"ccb-payment",onClick:S},[t("label",null,[t("div",M,[t("div",P,[l(t("input",{type:"radio",name:n(f),value:"stripe","onUpdate:modelValue":e[0]||(e[0]=r=>E(s)?s.value=r:null)},null,8,V),[[h,n(s)]]),e[1]||(e[1]=t("span",{class:"ccb-radio-label"},"Stripe",-1))]),t("div",q,[t("img",{src:n(g),alt:"card-payment-image",style:{"max-width":"112px"}},null,8,L)])]),l(t("div",N,[t("div",{ref_key:"cardComponent",ref:m},null,512)],512),[[b,n(s)==="stripe"]])])]))}}),ft=F(T,[["__scopeId","data-v-f643b7d4"]]);export{ft as default};
//# sourceMappingURL=Stripe-CO4C6yD5.js.map
