-
Notifications
You must be signed in to change notification settings - Fork 672
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[css-backgrounds-3][css-borders-4] Only the principal box should get a shadow #9286
Comments
As I commented in #9296 (review): I was expecting the behavior to be the principal box since that's the simple choice, but I have tried a table: <!DOCTYPE html>
<table style="outline: 3px solid cyan; box-shadow: 0 0 0 6px magenta">
<caption>Tablecaption</caption>
<tr><td>cell</td></tr>
</table> Both Firefox and Chromium apply the shadow to the table grid box, not to the principal table wrapper box. So maybe it should be discussed whether this should change? Or say that it's the principal box unless otherwise defined by the relevant spec (https://www.w3.org/TR/CSS21/tables.html#model would imply table grid box, and seemingly https://drafts.csswg.org/css-tables/#global-style-overrides too) I can't find it now, but I remember some discussion about defaulting properties on a table to apply to the principal wrapper box, with some exceptions that apply to the grid box. Now the default is the grid box, which seems a bit weird. |
#324 (comment) and some other comments in that issue indicate that the table wrapper box should be made the default. Sebastian |
I seem to recall that properties default to the grid box. Only when it would not make sense do they apply on the wrapper box. I hate the existence of the two boxes, but I have stopped fighting over it 😂 This is what the spec says at the moment:
|
https://drafts.csswg.org/css-backgrounds-3/#shadow-layers, https://drafts.csswg.org/css-borders-4/#shadow-layers
This is wrong: only the principal box should get the shadow. If that box has multiple fragments, then all of them get shadows, according to
box-decoration-break
.The text was updated successfully, but these errors were encountered: