Skip to content

fix: certificate PDF layout, partner logo capture, and download size#118

Open
choeying-10 wants to merge 1 commit into
wbc-ulmo1-stagefrom
fix/certificate-white-spacing-course-provider-logo-in-download-page
Open

fix: certificate PDF layout, partner logo capture, and download size#118
choeying-10 wants to merge 1 commit into
wbc-ulmo1-stagefrom
fix/certificate-white-spacing-course-provider-logo-in-download-page

Conversation

@choeying-10

Copy link
Copy Markdown
Collaborator

Summary

  • Fix downloaded certificate PDFs showing white gaps top/bottom by sizing the jsPDF page to the screenshot instead of forcing A4 letterboxing.
  • Fix missing course provider (partner) logo in the PDF by inlining the logo as base64 so html2canvas can paint it without CORS issues; wait for images before capture and tighten capture-mode CSS so the orange panel stays flush.
  • Reduce download size from ~15MB to ~1.2MB by embedding JPEG (quality 1) at scale 2 instead of lossless PNG.

#Note: checked the prod certificate and the result is same.

@choeying-10 choeying-10 self-assigned this Jul 17, 2026

@yogeshbhagatcode yogeshbhagatcode left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I hope this was tested and compared with current production certificate preview & print functionality.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants