Skip to content

T3646 FIX: Compose letter issues, allow overlay on project gift letters - #2204

Merged
ecino merged 6 commits into
18.0from
T3616-translation-page-after-scan
Nov 5, 2026
Merged

ecino merged 6 commits into
18.0from
T3616-translation-page-after-scan

Conversation

@Danielgergely

@Danielgergely Danielgergely commented Nov 5, 2026 •

Copy link
Copy Markdown
Member

Translations saved on extra scanned pages were missing from the PDF.

  • Spread the translation into the boxes before printing, like v14 (writes once per letter).
  • Text under 5 characters stays put, so no more empty pages.
  • FIX background images sometimes drifting accross pages because of wrong cloudinary cuts
  • Allow using any source PDF to be overlaid on top of it (for project gift letters)

Tickets: T3616, T3646
Related PR: CompassionCH/compassion-switzerland#1891 (sbc_switzerland, T3646)

Translations saved on extra scanned pages were missing from the PDF.
- Spread the translation into the boxes before printing, like v14 (writes once per letter).
- Text under 5 characters stays put, so no more empty pages.
@Danielgergely
Danielgergely requested a review from ecino November 5, 2026 08:08
@Danielgergely

Copy link
Copy Markdown
Member Author

@ecino If you agree with this change I will test on stage and the merge into prod

@Danielgergely
Danielgergely marked this pull request as draft November 5, 2026 08:09

@ecino ecino left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks good to me.

ecino added 3 commits November 5, 2026 10:05
Print the page images at an absolute width so that they never overflow
on the next page, and fetch the page from Connect first when the
Cloudinary image is a crop of a stack of pages (pages of different
heights were cut wrongly).

Assisted-by: claude-sonnet-5-5, medium, claude-code
Assisted-by: claude-sonnet-5-5, medium, claude-code
Assisted-by: claude-sonnet-5-5, medium, claude-code
@ecino ecino changed the title [T3616] FIX: lay out the B2S translation before printing, as in v14 T3646 FIX: Compose letter issues, allow overlay on project gift letters Nov 5, 2026
ecino added 2 commits November 5, 2026 11:31
The Source PDF is never modified and the translation is composed on top of
it at 150 dpi, until a final letter PDF is set, which is then used as it is.

Assisted-by: claude-sonnet-5-5, medium, claude-code
A blank line adds one line to the gap and several blank lines in a row are
reduced to one. The measure of the text boxes follows the same rule.
@ecino
ecino marked this pull request as ready for review November 5, 2026 11:10
@ecino
ecino merged commit 8172b38 into 18.0 Nov 5, 2026
1 check passed
@ecino
ecino deleted the T3616-translation-page-after-scan branch November 5, 2026 11:11
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