Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 40 additions & 13 deletions CSSGapDecorations/explainer.md
Original file line number Diff line number Diff line change
Expand Up @@ -220,25 +220,52 @@ The "zero point" is the edge of the intersection, with positive values extending
into the intersection and negative values receding from it.

```css
.outset-0px {
column-rule-outset: 0px;
.inset-0px {
column-rule-inset: 0px;
}
```
<image src="images/example-column-outset-0px.png">
<image src="images/example-column-inset-0px.png">

```css
.outset-5px {
column-rule-outset: 5px;
.inset-5px {
column-rule-inset: 5px;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to flip signs on inset values in example text? And/or update example image names to reflect the insets they're depicting?

}
```
<image src="images/example-column-outset-5px.png">
<image src="images/example-column-inset-5px.png">

```css
.outset-negative-5px {
column-rule-outset: -5px;
.inset-negative-5px {
column-rule-inset: -5px;
}
```
<image src="images/example-column-outset-minus-5px.png">
<image src="images/example-column-inset-minus-5px.png">

Authors may also adjust endpoints more granularly, making a distinction between "edge"
endpoints (which fall on the edge of the container),
and "interior" endpoints (any endpoint that is not an "edge").

```css
.edge-interior-insets {
column-rule-edge-inset: 0px;
column-rule-interior-inset: 5px;
}
```

<image src="images/example-column-interior-inset-5px.png">

Similarly, authors can have even more granular control to adjust the positions of endpoints,
making a distinction between "start" and "end" endpoints, in addition to the "edge" and "interior" distinction.

```css
.start-end-edge-interior-insets {
column-rule-start-edge-inset: 0px;
column-rule-end-edge-inset: 8px;
column-rule-start-interior-inset: 0px;
column-rule-end-interior-inset: 8px;
}
```

<image src="images/example-column-start-end-edge-interior-insets.png">

### Interaction with spanning items

Expand All @@ -249,15 +276,15 @@ In the latter case, gap decorations paint "behind" items in the container.
```css
.t-intersections {
gap-rule-break: spanning-item;
gap-rule-outset: 0px;
gap-rule-inset: 0px;
}
```
<image src="images/example-break-spanning-item.png">

```css
.all-intersections {
gap-rule-break: intersection;
gap-rule-outset: 0px;
gap-rule-inset: 0px;
}
```
<image src="images/example-break-intersection.png">
Expand Down Expand Up @@ -337,7 +364,7 @@ example
```css
.container {
rule: 1px solid black;
column-rule-outset: 0px;
column-rule-inset: 0px;
}
```

Expand Down Expand Up @@ -471,7 +498,7 @@ https://github.com/MicrosoftEdge/MSEdgeExplainers/issues/1099
". . content social";
rule-areas: --left 1 / 1 / 2 / -1;
rule: 1px solid gray [--left] none;
rule-outset: 3px;
rule-inset: 3px;
border-top: 1px solid gray;
}
```
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.