Skip to content

[css-gaps-1] Asymmetric start and end offsets #12603

@kbabbitt

Description

@kbabbitt

We have a couple of use cases from author feedback where there's a desire to have asymmetric starts and ends for decoration offsets. Examples:


MicrosoftEdge/MSEdgeExplainers#996

Image

MicrosoftEdge/MSEdgeExplainers#1100 (comment) - from https://dribbble.com/shots/3768565-Photography-Portfolio-Masonry-Gallery-Grid / https://www.northlandscapes.com/

Image

This is related, but I think distinct, from #12024 which contemplates having the offset behavior at the edges be distinct from the rest of the container.

The second case above actually might be better served with something other than a gap decoration, at least as they're defined today. The use case calls for a line segment of a specific length, and we define the endpoints of gap decorations relative to the locations of intersections.

But the first case I think makes a good argument for *-rule-offset to take two values, or perhaps to turn it into a shorthand of *-rule-offset-start and *-rule-offset-end to control these values separately.

Metadata

Metadata

Assignees

Type

No type

Projects

Status

Wednesday Afternoon

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions