Re: [csswg-drafts] [css-contain] Add contain-paint-margin CSS property (#4934)

Reopening, as I think @tabatkins' edits don't quite nail it.
Fixes I've done already:
* Define negative values to be invalid (in prose and using the range syntax)
* Move the description of the interaction between paint-overflow and overflow-clip-margin from css-contain L1 to L2 (L1 is at REC already, and doesn't need to define interaction with features introduced after it)

Things I haven't done yet, but think we should consider:
* The current way this is set up in spec terms is awkward, due to action at a distance: overflow-clip and paint containment are defined in terms of the padding edge, which is not defined to be affected by oveflow-clip-margin. Then overflow-clip-margin says it changes where these properties apply, and paint containment (but not overflow-clip) has an extra bit of text that contradicts the earlier statement that we clip at the padding edge, and says we clip further out taking overflow-clip-margin into account. Instead of doing this, I suggest:
  - defining a new term, like `overflow clip edge`
  - defining `overflow-clip` and `paint overflow` to clip at the `overflow clip edge`, instead of the `padding edge`
  - define how `overflow-clip-margin` makes the `overflow clip edge` expand outwards from the `padding edge`



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

Received on Friday, 29 May 2020 07:03:53 UTC