Skip to content

Fix overlapping lines in header of submission PDF#4567

Merged
frjo merged 1 commit into
HyphaApp:mainfrom
bmispelon:fix-pdf-layout-meta-multiple-lines
Jun 4, 2025
Merged

Fix overlapping lines in header of submission PDF#4567
frjo merged 1 commit into
HyphaApp:mainfrom
bmispelon:fix-pdf-layout-meta-multiple-lines

Conversation

@bmispelon

Copy link
Copy Markdown
Contributor

I noticed that when the name of the lead on an application is quite long, the "meta" text in the PDF goes over several lines and ends up overlapping (see attached screenshots).

I tracked it down to what I believe is a missing line in apply/utils/pdfs.py (compared to the similar logic in handling split_title in the same function).

This seemed like a minor change so I didn't create an issue, please let me know if you'd prefer I did that.

Screenshots

Before

Screenshot 2025-06-03 at 15-30-51 asdf - asdf-11 pdf

After

Screenshot 2025-06-03 at 15-30-34 asdf - asdf-12 pdf

Test Steps

  1. Set up a hypha instance (with USE_PROJECTS=True for PDF download to work, see PDF download of submission fails when projects are not enabled #4566)
  2. Log in as an admin user (so you have access to PDF download)
  3. Change your display name to something fairly long (~80 characters, with spaces)
  4. Go to a submission's detail page and download the PDF (Actions to take > More actions > Download PDF)

@sandeepsajan0 sandeepsajan0 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!
Nice catch on the meta text wrapping. It was happening when any of the meta fields like workflow, round name, lead name, etc., were long enough to wrap it in multiple lines.

@frjo frjo added Type: Bug Bugs! Things that are broken :-/ Type: Patch Mini change, used in release drafter labels Jun 4, 2025
@frjo frjo merged commit 6634fc2 into HyphaApp:main Jun 4, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Type: Bug Bugs! Things that are broken :-/ Type: Patch Mini change, used in release drafter

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants