@anoki/fse-ui
Version:
FSE UI components library
3 lines (2 loc) • 3.42 kB
JavaScript
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('./components/ui/CardPaymentDocument/CardPaymentDocument.css');const n=require("./index.cjs278.js"),a=require("./index.cjs280.js");;/* empty css */const w=require("./index.cjs104.js"),i=require("./index.cjs219.js"),j=require("./index.cjs82.js"),y=require("./index.cjs117.js"),E=require("./index.cjs183.js"),N=require("./index.cjs36.js"),v=({headerText:h,beforeTitle:x,title:R,subtitle:c,footer:s,isLoading:e,asLink:g="a"})=>{var t,m,l,u,p,r;const d=g;return n.jsxRuntimeExports.jsxs("div",{className:a.clsx("ui-card-payment shadow br-x4 fw-semibold text-slate-28 fs-7"),children:[n.jsxRuntimeExports.jsx(i.Row,{"max-h":"x40","min-h":"x40",as:"header",justifyContent:"flex-end",alignItems:"center",px:"x24",className:"ui-card-payment-header",children:n.jsxRuntimeExports.jsx(i.Row,{className:"fw-semibold fs-7",children:h})}),n.jsxRuntimeExports.jsxs("div",{className:"ui-card-payment-main py-x16 px-x24",children:[n.jsxRuntimeExports.jsxs(j.Col,{pb:"x32",justifyContent:"space-between",gap:"x8",children:[n.jsxRuntimeExports.jsxs(i.Row,{justifyContent:x!=null&&x.rightBadgeText?"space-between":"flex-end",alignItems:"center",children:[x&&n.jsxRuntimeExports.jsx("div",{className:"fw-semibold",children:x==null?void 0:x.leftText}),(x==null?void 0:x.rightBadgeText)&&n.jsxRuntimeExports.jsx("div",{className:a.clsx("rounded py-x4 px-x16"),style:{backgroundColor:x.rightBadgeColor||"#000",color:"#fff",width:"max-content"},children:x.rightBadgeText})]}),n.jsxRuntimeExports.jsx("h3",{className:a.clsx("ui-card-payment-title fs-4 text-slate-20","cursor-pointer hover-underline"),children:n.jsxRuntimeExports.jsx(d,{className:"link-unstyled",href:((t=s==null?void 0:s.ctaRight)==null?void 0:t.href)??"#",children:R})}),c&&n.jsxRuntimeExports.jsx("div",{style:{fontWeight:500},children:c})]}),s&&n.jsxRuntimeExports.jsxs(j.Col,{mt:"x16",className:"ui-card-payment-footer",children:[(s==null?void 0:s.descriptionText)&&n.jsxRuntimeExports.jsx("div",{children:(s==null?void 0:s.descriptionText)&&n.jsxRuntimeExports.jsx("p",{className:"fw-regular fs-7 text-slate-28 mb-x8",children:s.descriptionText})}),n.jsxRuntimeExports.jsxs(i.Row,{className:"ui-card-payment-footer-actions",justifyContent:s!=null&&s.downloadDoc?"space-between":"flex-end",alignItems:"center",children:[(s==null?void 0:s.downloadDoc)&&n.jsxRuntimeExports.jsxs(i.Row,{alignItems:"center",className:a.clsx(!e&&"cursor-pointer","text-decoration-none text-primary","ui-card-payment-download-row"),onClick:e||(m=s==null?void 0:s.downloadDoc)==null?void 0:m.clickCta,children:[n.jsxRuntimeExports.jsx(y.Download,{}),n.jsxRuntimeExports.jsx("p",{children:(l=s==null?void 0:s.downloadDoc)==null?void 0:l.label}),n.jsxRuntimeExports.jsx(E.Loader,{loading:e,className:"ml-x8"})]}),(s==null?void 0:s.ctaRight)&&((u=s==null?void 0:s.ctaRight)==null?void 0:u.href)&&n.jsxRuntimeExports.jsxs(n.jsxRuntimeExports.Fragment,{children:[n.jsxRuntimeExports.jsx(w.Divider,{bg:"border-divider",className:"ui-document-divider"}),n.jsxRuntimeExports.jsx(N.Button,{fwClassName:"fw-semibold",className:"ui-card-payment-cta px-x12",variant:"secondary",size:"5",asLink:d,href:((p=s==null?void 0:s.ctaRight)==null?void 0:p.href)??void 0,children:(r=s==null?void 0:s.ctaRight)==null?void 0:r.label})]})]})]})]})]})};exports.CardPaymentDocument=v;
//# sourceMappingURL=index.cjs57.js.map