fix: prevent print layout from truncating recipe content#307
Conversation
The print styles had overly broad CSS selectors that caused recipe content to be cut off when printing: - `.flex-1` rule forced all flex-1 elements to width:100%/flex:none, pushing ingredient quantities off-screen. Now scoped to shopping list. - `.bg-white` rule stripped padding from recipe containers. - `.truncate` class clipped ingredient notes in print; now overridden to show full text. Fixes #304
Code ReviewPR: fix: prevent print layout from truncating recipe content Overall this is a clean, targeted fix for a genuine print layout regression. A few observations: What's good
Concerns
The .truncate {
overflow: visible !important;
text-overflow: unset !important;
white-space: normal !important;
max-width: none !important;
/* display: inline only if element is already inline/inline-block */
}Or scope it more tightly to the elements that actually use Selector fragility: This depends on the current HTML structure having a Minor
Test coveragePer CLAUDE.md there are no automated tests, which is fine for this kind of CSS fix. The test plan in the PR description is appropriate — manually verifying print preview on recipe and shopping list pages covers the regression well. Overall: Approve with the suggestion to reconsider |
Summary
.flex-1print CSS rule to only affect shopping list layout, preventing ingredient quantities from being pushed off-screenpadding: 0from.bg-whiteprint rule that was stripping padding from recipe containers.truncateprint override so ingredient notes and step text display fully instead of being clippedTest plan
Fixes #304