Skip to content

grid does not stretch cells to equal height (no items-stretch for grid) #126

Description

@anilcancakir

Problem

Wind's grid sizes each cell to its own content; cells in the same row are NOT stretched to the row's tallest (CSS Grid's default align-items: stretch). A row of cards where one has an extra line ends up ragged.

Current behavior

Grid is built with Wrap + a per-item SizedBox constraining width only (lib/src/widgets/w_div.dart:1032-1086; the comment at ~:1028 notes the deliberate Wrap-based intrinsic-height choice). Height is never equalized across a row, and h-full on a cell has no bounded parent height to resolve against.

Proposed direction

Support equal-height grid rows: an items-stretch-equivalent, or a grid layout mode that stretches cells in a row to the max height. Relatedly, make h-full resolvable inside a grid cell. (Related to the IntrinsicHeight limitation documentation issue.)

Workaround

Reserve equal content in each cell (e.g. always render placeholder footer rows) so intrinsic heights match.


Surfaced with a KPI stat-card row in uptizm: one card had a delta row and rendered taller than the rest.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestpending triageIssue / PR needs initial triage

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions