Re: [csswg-drafts] [css-grid] Introducing overlapping cells in grid-template-areas syntax (#2808)

I just had an idea for a different approach to this. Currently, the grid area for an item can be definied using integers for the grid lines in `grid-area`. This syntax could also be used in `grid-template-area`.

@Dan503's [example](https://github.com/w3c/csswg-drafts/issues/2808#issuecomment-592776106) could then look like this:

```css
.grid {
  display: grid;
  grid-template: repeat(3, 1fr) / repeat(3, 1fr);
  grid-template-areas:
    a-alpha 1 / 1 / -1 / 3,
    b-beta-beta 1 / 2 / 3 / -1,
    c-long-name-because-reality 1 / 1 / 3 / 3,
    d-deltorino 2 / 2 / -1 / -1;
}

.cell-a {
  grid-area: a-alpha;
}

.cell-b {
  grid-area: b-beta-beta;
}

.cell-c {
  grid-area: c-long-name-because-reality;
}

.cell-d {
  grid-area: d-deltorino;
}
```

Sebastian

-- 
GitHub Notification of comment by SebastianZ
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/2808#issuecomment-1399989358 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 23 January 2023 08:53:46 UTC