Skip to content

[css-grid-2] option to specify an optional sequence of track sizes #3328

Open
@pmccloghrylaing

Description

@pmccloghrylaing

Spec: https://www.w3.org/TR/css-grid-1/#auto-repeat

In a number of scenarios flexbox and grid are able to respond to their content and container to achieve layouts that people want container queries for (which seem unlikely to happen). Being able to define a completely collapsible sequence of tracks would allow things like switching from a layout of X columns * 1 row to 1 column wide * X rows depending on the size of the container. In my case I'm looking at ways to switch between a 3×1 and 1×3. This would also allow things like odd numbers of columns/rows down to 1 instead of 3.

This could work with repeat so it could be used with auto-fill/fit, maybe as an additional keyword - repeat(3 optional, ...) or repeat(auto-fit optional, ...)?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions