@@ -404,57 +404,74 @@ const donationPdfDefinition = (input: {
404404 pageBreak : 'before' ,
405405 text : [
406406 { text : 'RICHMOND CENTRE FOR DISABILITY' , style : 'header' } ,
407- '\n\n ' ,
407+ '\n' ,
408408 {
409409 text : `Official Donation Receipt for Income Tax Purposes - ${ dateIssued . getFullYear ( ) } ` ,
410- style : 'subheaderDonation ' ,
410+ style : 'subheader ' ,
411411 } ,
412412 ] ,
413413 } ,
414+
414415 {
415416 columns : [
416417 {
417- table : {
418- heights : 20 ,
419- body : [
420- [
421- { text : 'Tax Receipt #:' } ,
422- `PPD_${ dateIssued . getFullYear ( ) } ${ dateIssued . getMonth ( ) } ${ dateIssued . getDate ( ) } _${ appNumber } ` ,
423- ] ,
424- [
425- { text : 'Donated by:' } ,
426- {
427- text : [
428- `${ applicantName } \n` ,
429- `${ address . addressLine2 ? `${ address . addressLine2 } - ` : '' } ${
430- address . addressLine1
431- } \n`,
432- `${ address . city } ${ address . province } ${ formatPostalCode ( address . postalCode ) } ` ,
418+ stack : [
419+ {
420+ table : {
421+ heights : 18 ,
422+ body : [
423+ [
424+ { text : 'Tax Receipt #:' } ,
425+ `PPD_${ dateIssued . getFullYear ( ) } ${ dateIssued . getMonth ( ) } ${ dateIssued . getDate ( ) } _${ appNumber } ` ,
433426 ] ,
434- fontSize : 12 ,
435- lineHeight : 1.5 ,
436- } ,
437- ] ,
438- [ { text : '' } , '' ] ,
439- [ { text : '' } , '' ] ,
440- [ { text : '' } , '' ] ,
441- [ { text : 'Email:' } , nonNullEmail ] ,
442- [ { text : 'Date Receipt Issued:' } , formatDateYYYYMMDD ( dateIssued ) ] ,
443- [ { text : 'Location Receipt Issued:' } , 'Richmond, BC' ] ,
444- [ { text : 'Authorized Signature:' } , { image : 'signature' , width : 150 } ] ,
445- ] ,
446- } ,
447- layout : 'noBorders' ,
448- margin : [ 0 , 0 , 20 , 0 ] ,
427+ [
428+ { text : 'Donated by:' } ,
429+ {
430+ text : [
431+ `${ applicantName } \n` ,
432+ `${ address . addressLine2 ? `${ address . addressLine2 } - ` : '' } ${
433+ address . addressLine1
434+ } \n`,
435+ `${ address . city } ${ address . province } ${ formatPostalCode (
436+ address . postalCode
437+ ) } `,
438+ ] ,
439+ lineHeight : 1.4 ,
440+ } ,
441+ ] ,
442+ ] ,
443+ } ,
444+ layout : 'noBorders' ,
445+ margin : [ 0 , 0 , 0 , 40 ] ,
446+ } ,
447+ {
448+ text : [ `Email: ${ nonNullEmail } ` ] ,
449+ margin : [ 0 , 0 , 0 , 8 ] ,
450+ } ,
451+ {
452+ table : {
453+ heights : 18 ,
454+ body : [
455+ [ { text : 'Date Receipt Issued:' } , formatDateYYYYMMDD ( dateIssued ) ] ,
456+ [ { text : 'Location Receipt Issued:' } , 'Richmond, BC' ] ,
457+ ] ,
458+ } ,
459+ margin : [ 0 , 0 , 0 , 15 ] ,
460+ layout : 'noBorders' ,
461+ } ,
462+ { image : 'signature' , width : 200 , margin : [ 0 , 0 , 0 , 5 ] } ,
463+ { text : 'Authorized Signature:' } ,
464+ ] ,
449465 } ,
466+
450467 {
451468 table : {
452- heights : 20 ,
469+ heights : 18 ,
453470 body : [
454471 [ { text : 'Date Donation Received:' } , formatDateYYYYMMDD ( dateDonationRecevied ) ] ,
455472 [ { text : 'Donor Number:' } , `P${ appNumber } ` ] ,
456473 [ { text : 'Total Amount:' } , `$${ donationAmount . toString ( ) } ` ] ,
457- [ { text : 'Value of Product / Services:' } , '' ] ,
474+ [ { text : 'Value of Product / Services:\n\n ' } , '' ] ,
458475 [
459476 { text : 'Eligible Amount of Donation for Tax Purposes:' } ,
460477 `$${ donationAmount . toString ( ) } ` ,
@@ -469,26 +486,26 @@ const donationPdfDefinition = (input: {
469486 'Address of Appraiser:\n\n' ,
470487 ] ,
471488 } ,
472- { image : 'stamp' , width : 85 } ,
489+ { image : 'stamp' , width : 80 } ,
473490 ] ,
474491 ] ,
475492 } ,
476493 layout : 'noBorders' ,
477- margin : [ 20 , 0 , 0 , 0 ] ,
494+ margin : [ 15 , 0 , 0 , 0 ] ,
478495 } ,
479496 ] ,
480- margin : [ 0 , 35 , 0 , 25 ] ,
497+ margin : [ 0 , 25 , 0 , 0 ] ,
481498 } ,
482499 {
483500 text : [
484- `Dear ${ applicantName } \n\n` ,
501+ `Dear ${ applicantName } \n\n\n ` ,
485502 'On behalf of the Richmond Centre for Disability (RCD), we would like to extend our sincere and\n' ,
486503 'heartfelt thanks and appreciation for your donation. Please find your official tax receipt enclosed.\n\n' ,
487504 'Through RCD services and support, we have seen the lives of people with disabilities and their\n' ,
488505 'families changed for the better. Your generosity does make a difference in the delivery of much\n' ,
489506 'coveted services to people with disabilities. The work being undertaken through the RCD is only\n' ,
490- 'possible because of caring people like you.\n\n' ,
491- 'Thank you again for your valued support.\n\n' ,
507+ 'possible because of caring people like you.\n\n\n ' ,
508+ 'Thank you again for your valued support.\n\n\n ' ,
492509 'Sincerely,\n\n\n' ,
493510 'RICHMOND CENTRE FOR DISABILITY\n' ,
494511 '(Charity Number: 88832-8432-RR0001)\n' ,
@@ -498,35 +515,32 @@ const donationPdfDefinition = (input: {
498515 'Website:www.rcdrichmond.org\n' ,
499516 ] ,
500517 margin : [ 0 , 15 , 0 , 0 ] ,
501- fontSize : 12 ,
502518 } ,
503519 ] ) ,
504520 styles : {
505521 header : {
506- fontSize : 28 ,
522+ fontSize : 25.5 ,
507523 bold : true ,
508524 alignment : 'center' ,
525+ lineHeight : 1.5 ,
509526 } ,
510527 tableHeader : {
511528 bold : true ,
512529 alignment : 'center' ,
513530 } ,
514531 subheader : {
515- fontSize : 20 ,
516- bold : false ,
517- alignment : 'center' ,
518- } ,
519- subheaderDonation : {
520- fontSize : 19 ,
532+ fontSize : 17.5 ,
521533 alignment : 'center' ,
522534 } ,
523535 footer : {
524- fontSize : 8 ,
536+ fontSize : 7.5 ,
525537 alignment : 'center' ,
526538 } ,
527539 } ,
528540 defaultStyle : {
529541 font : 'Helvetica' ,
542+ fontSize : 11 ,
543+ lineHeight : 1.2 ,
530544 } ,
531545 images : {
532546 rcd : 'public/assets/logo.png' ,
0 commit comments