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

[csswg-drafts] [css-display][css-pseudo] Interaction of run-in and ::first-line

From: Loirooriol via GitHub <sysbot+gh@w3.org>
Date: Mon, 22 May 2017 18:54:27 +0000
To: public-css-archive@w3.org
Message-ID: <issues.opened-230486283-1495479265-sysbot+gh@w3.org>
Loirooriol has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-display][css-pseudo] Interaction of run-in and ::first-line ==
In [Run-In Layout](https://drafts.csswg.org/css-display-3/#run-in-layout), CSS Display says

> If a [run-in sequence](https://drafts.csswg.org/css-display-3/#run-in-sequence) is immediately followed by a block box that does not establish a new [block formatting context](https://drafts.csswg.org/css-display-3/#block-formatting-context), it is inserted as direct children of the block box after its [`::marker`](https://drafts.csswg.org/css-pseudo-4/#selectordef-marker) pseudo-element’s boxes (if any), but preceding any other boxes generated by the contents of the block (including the box generated by the [`::before`](https://drafts.csswg.org/css-pseudo-4/#selectordef-before) pseudo-element, if any).
> The reparented content is then formatted as if originally parented there. Note that only layout is affected, not inheritance, because property inheritance for non-anonymous boxes is based only on the element tree.

First, does "boxes generated by the contents of the block" include block's `::first-line`? If yes, what about `::first-line`s generated by ancestor blocks?

Second, the premise in the last sentence is false. A non-anonymous box fragment can inherit some properties from a `::first-line` pseudo-element, which is based on the box tree. So it's not clear whether a run-in inserted into the next block is supposed to ignore that block's `::first-line` styles or not.


section { color: red }
div::first-line { color: green; background: blue }

What color does Foo have? Does it have a blue background behind?

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1441 using your GitHub account
Received on Monday, 22 May 2017 18:54:38 UTC

This archive was generated by hypermail 2.3.1 : Monday, 23 October 2017 10:12:53 UTC