import{j as e,r as t}from"./router.chunk.YsRm4bSN.js";import{u as o}from"./pdf-context.chunk.DXMR6h2w.js";import{i,c5 as r}from"./main.chunk.N-eZ2ybB.js";import{H as n}from"./pdf-html.chunk.CXZoRVhj.js";import{V as s,I as a,T as d}from"./pdf-core.chunk.D33I_Wdh.js";const l=()=>{const{pdfReceiptTemplate:t}=o();return i(t?.content.footer)?e.jsx(s,{style:{marginTop:12,borderTop:1,borderTopStyle:"solid",borderTopColor:"#E6E6E6",paddingTop:12},children:e.jsx(n,{resetStyles:!1,stylesheet:{p:{marginBottom:1,marginTop:2,fontSize:12}},children:t.content.footer})}):e.jsx(s,{})},m=({heading:n})=>{const{pdfReceiptTemplate:l}=o(),m=t.useMemo(()=>i(l?.media.position)?"left"===l.media.position?"flex-start":"right"===l.media.position?"flex-end":"center":"center",[l?.media.position]);return e.jsxs(s,{style:{borderBottom:1,borderBottomColor:"#E6E6E6",borderBottomStyle:"solid",paddingTop:12,paddingBottom:12},children:[i(l?.media.image)&&e.jsx(s,{style:{flexDirection:"row",justifyContent:m},children:e.jsx(a,{style:{height:l.media.height??24,borderRadius:6},src:r(l.media.image.url)})}),e.jsx(d,{style:{fontSize:14,fontWeight:"bold",textAlign:"center",color:"#333333",marginTop:16},children:n})]})},c=()=>{const{pdfReceiptTemplate:t}=o();return i(t?.content.greetings)?e.jsx(s,{style:{paddingTop:20,paddingBottom:20},children:e.jsx(n,{resetStyles:!1,stylesheet:{p:{marginBottom:1,marginTop:2,fontSize:12,width:"100%"}},children:t.content.greetings})}):e.jsx(s,{})},p=()=>{const{pdfReceiptTemplate:t}=o();return i(t)&&t.content.signature?.is_available?e.jsxs(s,{style:{marginTop:48},children:[e.jsx(d,{style:{marginBottom:12,marginTop:0},children:"Sincerely,"}),i(t.content.signature.image)&&e.jsx(s,{style:{marginBottom:12},children:e.jsx(a,{style:{height:32,maxWidth:64,borderRadius:6},src:r(t.content.signature.image.url)})}),t.content.signature.details&&e.jsx(s,{children:e.jsx(n,{resetStyles:!1,stylesheet:{p:{marginBottom:1,marginTop:2,fontSize:12,width:"100%"}},children:t.content.signature.details??""})})]}):e.jsx(s,{})};export{m as P,c as a,p as b,l as c};
