Skip to content

Fix PDF report layout: hazard name overlap, disclaimer page break, and data source cleanup - #1055

Merged
ronitjadhav merged 1 commit into
masterfrom
fix/pdf-report-layout
Apr 15, 2026
Merged

ronitjadhav merged 1 commit into
masterfrom
fix/pdf-report-layout

Conversation

@ronitjadhav

Copy link
Copy Markdown
Collaborator

Description

After updating hazard names (e.g. "Tropical cyclone", "Water scarcity", "Extreme heat"), the PDF cover page had overlapping text labels because report.less enforces a fixed width on hazard list items. Additionally, the disclaimer section was splitting across two pages, and the data source section was still visible in the PDF despite being commented out in the web report.

This PR resolves the layout issues by adjusting the PDF print styles so that hazard items size dynamically to fit their content with appropriate padding, and forces a page break before the disclaimer section. The data source snippet has also been commented out in the PDF report template to match the rest of the application.

Screenshots

  1. Hazard List
BeforeAfterLandscape copy (1) (3)
  1. Disclaimer Split
BeforeAfterLandscape copy (1) (4)
  1. Data Source
BeforeAfterLandscape copy (1) (5)

- Fix hazard name overlap on cover page by overriding fixed 72px width
  with auto sizing, reducing font-size, and adding horizontal padding
- Prevent disclaimer from splitting across pages with page-break-before
- Comment out data source section in PDF report (already disabled elsewhere)
- Adjust footer margin on cover page
@ronitjadhav
ronitjadhav merged commit 9f1951f into master Apr 15, 2026
1 check passed
@ronitjadhav
ronitjadhav deleted the fix/pdf-report-layout branch April 15, 2026 13:43
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