Fix print preview to display all 6 rows for 6-week months

The print preview was only showing 5 rows for months requiring 6 rows
(like November 2025). The issue was that the .calendar container uses
flexbox layout, but the grid wasn't properly constrained to fit within
the fixed paper height.

Changes:
- Set explicit height: 100% on .print-preview-paper .calendar
- Use flex: 1 on calendar-grid to fill remaining space after header
- Add min-height: 0 to both calendar-grid and calendar-day to allow
  flexbox items to shrink below their content size

This allows the CSS Grid's repeat(6, 1fr) to properly distribute all
6 rows evenly within the available space while maintaining the fixed
paper dimensions for consistent printing.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Connor Johnstone
2025-11-07 16:30:26 -05:00
parent 13702d8c30
commit 1701a95183

View File

@@ -201,6 +201,21 @@
overflow: hidden;
}
/* Ensure calendar and grid have proper height constraints for row distribution */
.print-preview-paper .calendar {
height: 100%;
}
.print-preview-paper .calendar-grid {
flex: 1 !important; /* Fill remaining space after header in flex container */
min-height: 0 !important; /* Allow grid to shrink below content size in flexbox */
height: auto !important; /* Override the calc() from base styles */
}
.print-preview-paper .calendar-day {
min-height: 0 !important; /* Allow day cells to shrink to fit in grid rows */
}
/* Hide UI elements in preview */
.print-preview-paper .app-sidebar,
.print-preview-paper .print-button,