import{proxyCustomElement,HTMLElement,h}from"@stencil/core/internal/client";import{d as defineCustomElement$b}from"./sc-button2.js";import{d as defineCustomElement$a}from"./sc-card2.js";import{d as defineCustomElement$9}from"./sc-cc-logo2.js";import{d as defineCustomElement$8}from"./sc-flex2.js";import{d as defineCustomElement$7}from"./sc-icon2.js";import{d as defineCustomElement$6}from"./sc-payment-method2.js";import{d as defineCustomElement$5}from"./sc-spinner2.js";import{d as defineCustomElement$4}from"./sc-tag2.js";import{d as defineCustomElement$3}from"./sc-text2.js";import{d as defineCustomElement$2}from"./sc-tooltip2.js";const ScPaymentMethodDetails$1=proxyCustomElement(class extends HTMLElement{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.paymentMethod=void 0,this.editHandler=void 0}render(){var e,t,s,o,n,m,c,d,a,i;return h("sc-card",{key:"ade0bcc70772764c638b29235a85603dedc7b1d6"},h("sc-flex",{key:"ceeac22b7781f8f3c70a079b6e7139c6b10ee1a4",alignItems:"center",justifyContent:"flex-start",style:{gap:"0.5em"}},h("sc-payment-method",{key:"bd9fca18eafc3ecad630908e6210fc1896d57c61",paymentMethod:this.paymentMethod}),h("div",{key:"13ba6337ebe96c1cbdc6c4a8baec9b81421c959d"},!!(null===(t=null===(e=this.paymentMethod)||void 0===e?void 0:e.card)||void 0===t?void 0:t.exp_month)&&h("span",{key:"d04ec0f9d49320f0bc9532859c039ae6c45dcfc9"},
// Translators: %d/%d is month and year of expiration.
wp.i18n.sprintf(wp.i18n.__("Exp. %d/%d","surecart"),null===(o=null===(s=this.paymentMethod)||void 0===s?void 0:s.card)||void 0===o?void 0:o.exp_month,null===(m=null===(n=this.paymentMethod)||void 0===n?void 0:n.card)||void 0===m?void 0:m.exp_year)),!!(null===(d=null===(c=this.paymentMethod)||void 0===c?void 0:c.paypal_account)||void 0===d?void 0:d.email)&&(null===(i=null===(a=this.paymentMethod)||void 0===a?void 0:a.paypal_account)||void 0===i?void 0:i.email)),h("sc-button",{key:"0f920f310318785b2c147f1e140055f20159f119",type:"text",circle:!0,onClick:this.editHandler},h("sc-icon",{key:"6e8610037e40b71b855122965b61a607d6db8782",name:"edit-2"}))))}},[1,"sc-payment-method-details",{paymentMethod:[16],editHandler:[16]}]);function defineCustomElement$1(){"undefined"!=typeof customElements&&["sc-payment-method-details","sc-button","sc-card","sc-cc-logo","sc-flex","sc-icon","sc-payment-method","sc-spinner","sc-tag","sc-text","sc-tooltip"].forEach((e=>{switch(e){case"sc-payment-method-details":customElements.get(e)||customElements.define(e,ScPaymentMethodDetails$1);break;case"sc-button":customElements.get(e)||defineCustomElement$b();break;case"sc-card":customElements.get(e)||defineCustomElement$a();break;case"sc-cc-logo":customElements.get(e)||defineCustomElement$9();break;case"sc-flex":customElements.get(e)||defineCustomElement$8();break;case"sc-icon":customElements.get(e)||defineCustomElement$7();break;case"sc-payment-method":customElements.get(e)||defineCustomElement$6();break;case"sc-spinner":customElements.get(e)||defineCustomElement$5();break;case"sc-tag":customElements.get(e)||defineCustomElement$4();break;case"sc-text":customElements.get(e)||defineCustomElement$3();break;case"sc-tooltip":customElements.get(e)||defineCustomElement$2()}}))}const ScPaymentMethodDetails=ScPaymentMethodDetails$1,defineCustomElement=defineCustomElement$1;export{ScPaymentMethodDetails,defineCustomElement};