Re: [csswg-drafts] [css-text-decor] selective toggling in the text-decoration-skip property. (#843)

@fantasai Thanks, this looks great.

I do have a few remarks. If you think any of these is an obvious bugfix, please fold that in and tick it off below. After that, I'm happy to re-file the rest into separate issues so that we can track them individually. For now, I'm dumping it all here as the result of a one-pass review, but I do expect most of these to move to separate issue.

* [ ] `text-decoration-skip-self` says “Applies to: all elements”, but its `object` value's definition says: “Skip this element [...] if it is an atomic inline”. I wonder if this should be changed to “Applies to: atomic inlines”, or if you also envision a value that that skips the element even if it is not an atomic inline? If so, we may need to rename the existing value.
* [ ] `text-decoration-skip-inset`'s `auto` has “The UA should [...]”. Are you sure this is a should? As much as it makes sense to leave the size of the inset UA defined (and possibly context dependent), I'm not sure what the benefit is to allow UAs to implement this on/off switch at the syntax level and yet have no effect.
* [ ] The grammar of `text-decoration-skip-spaces` defines `start` and `end`, but the initial value and prose calls them `leading` and `trailing`. I don't strongly care which one we pick (and we can bikeshed that separately if need be, as noted in the inline issue), but the spec should be self-consistent.
* [ ] Safari and Firefox both have built-in default behavior that's sort of like `text-decoration-skip-spaces: end`, but not quite the same as the one specified, and not quite the same as each other:
  * Safari skips _all_ preserved U+0020 (but not  , or U+3000, or U+2007) on the end side if `white-space` is `pre-wrap`, but not `pre` or `break-spaces`
  * Firefox skips _overflowing_ preserved U+0020 (but not  , or U+3000, or U+2007) on the end side if `white-space` is `pre-wrap`, but not `pre` or `break-spaces`
  I wonder if we need to make the `end` value (and maybe other values) smarter, or if we need an `auto` of some kind in addition, or if this is just historical accident and all UAs will align on the specified behavior of `end`
* [ ] The spec says that the initial value of `text-decoration-skip-spaces` is `start end`, which is consistent with what level 3 said in prose. However, Chrome behaves as if the initial value was `none`, and Firefox / Safari behave as if the initial value was `magic-end` (see previous point) and don't skip leading spaces at all. Not sure if the spec should align with the browsers or the other way around, but the discrepancy is worth noting. We do have a [resolution in favor of what the spec says](https://lists.w3.org/Archives/Public/www-style/2015May/0314.html), so it's probably just a matter of writing tests and filing bugs…
* [ ] I suspect some or all of these properties should also apply to the `::marker` pseudo. 


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

Received on Monday, 6 January 2020 09:11:00 UTC