- Notifications
You must be signed in to change notification settings - Fork 760
Open
Labels
Description
https://drafts.csswg.org/css-tables/#drawing-cell-backgrounds
In addition to its own background, table-cell boxes also render the backgrounds of the table-track and table-track-group boxes in which they belong. This is actually different from simply inheriting their background because the
background-originandbackground-sizecomputations will actually be done on the bounds of the grouping boxes, and not on those of the cell.
What about the background-clip of the grouping boxes? Do they use the border and padding of the cell? https://drafts.csswg.org/css-backgrounds-3/#background-clip
<!DOCTYPE html> <style> table { border-spacing: 5px } col { background: linear-gradient(to bottom, rgba(0, 255, 255, 0.5), rgba(255, 255, 0, 0.5)) content-box } tr { background: linear-gradient(to right, rgba(0, 255, 255, 0.5), rgba(255, 0, 255, 0.5)) content-box } td { padding: 10px; border: 10px solid rgba(0, 0, 0, 0.2); } td:nth-of-type(1) { border-width: 10px } td:nth-of-type(2) { border-width: 5px } td:nth-of-type(3) { border-width: 0px } tr:nth-of-type(1) > td { padding: 10px } tr:nth-of-type(2) > td { padding: 5px } tr:nth-of-type(3) > td { padding: 0px } </style> <table> <col></col> <col></col> <col></col> <tr><td>A</td><td>B</td><td>B</td></tr> <tr><td>A</td><td>B</td><td>B</td></tr> <tr><td>A</td><td>B</td><td>B</td></tr> </table>| Gecko | Blink | WebKit |
|---|---|---|
![]() | ![]() | ![]() |
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
Tuesday afternoon


