W3C home > Mailing lists > Public > public-css-archive@w3.org > March 2017

[csswg-drafts] [css-display] [css-text-decor] Propagation of text-decoration with display:contents

From: Loirooriol via GitHub <sysbot+gh@w3.org>
Date: Tue, 28 Mar 2017 14:22:06 +0000
To: public-css-archive@w3.org
Message-ID: <issues.opened-217576855-1490710924-sysbot+gh@w3.org>
Loirooriol has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-display] [css-text-decor] Propagation of text-decoration with display:contents ==
>From [CSS Text Decoration](https://drafts.csswg.org/css-text-decor-3/#line-decoration),

>  the decorations are propagated to all in-flow children.

>From [CSS Display](https://drafts.csswg.org/css-display/#valdef-display-contents), `display: contents` means

> The element itself does not generate any boxes, but its children and pseudo-elements still generate boxes as normal.

Then, if a decoration is specified in an element which does not generate boxes, does the decoration propagate to the descendants which generate boxes?

`display: contents` does not affect inheritance, but text decorations are special because they propagate using a mechanism different than inheritance. I'm not sure if it is an element-tree thing, and thus the decoration should still propagate, or if it's a box-tree thing, and thus it shouldn't.

Example: https://jsfiddle.net/203oz4jr/

div {
  display: contents;
  text-decoration: underline;

Should Foo be underlined? It's underlined on Chrome, but not on Firefox.

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1136 using your GitHub account
Received on Tuesday, 28 March 2017 14:22:13 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:09 UTC