fix(highlight): stop Happening Now card from stretching feed row#6033
Merged
idoshamun merged 2 commits intoMay 12, 2026
Merged
Conversation
The HighlightGrid card's intrinsic content (5 highlights with break-words headlines) was contributing its full size to the CSS grid track, pushing the feed row taller and stretching neighboring post cards. Wrapping the content in an absolutely-positioned container removes its contribution to track sizing, so the row is sized by the other cards instead. min-h-card keeps the card from collapsing when it is alone in a row. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Drop the `min-h-0 overflow-y-auto` from the list variant of HighlightCardContent. Those classes were carried over from the grid variant fix but never activate here — the list card stacks vertically with no parent height constraint, so content should grow as needed. Also captures the grid vs list scoping rule in AGENTS.md. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The Happening Now grid card was pushing the feed row taller than its neighbors. Its inner content (5 highlights with
break-wordsheadlines) had amax-contentsize larger than typical post cards, and even thoughmax-h-cardLargecapped the visual height, that size still contributed to CSS Grid'sauto-rowstrack sizing — stretching the row and forcing every other card in it to grow too.Changes
HighlightCardContentin anabsolute inset-0container inHighlightGridso the content is out-of-flow and contributes nothing to the article's intrinsic size.min-h-card(24rem) to matchArticleGridso the card has a sensible baseline when it's alone in a row (mobile single-column).flex h-full flex-colfrom the override since they're already on theCardprimitive.Test plan
pnpm --filter @dailydotdev/shared exec jest src/components/cards/highlight/(18/18 passing)Closes ENG-1432
Created by Huginn 🐦⬛
Preview domain
https://eng-1432-happening-now-row-stret.preview.app.daily.dev