W3C home > Mailing lists > Public > public-css-archive@w3.org > February 2019

Re: [csswg-drafts] [css3-page] CSS counter for position fixed elements on paged media (#1879)

From: Tab Atkins Jr. via GitHub <sysbot+gh@w3.org>
Date: Fri, 08 Feb 2019 21:51:05 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-461959118-1549662664-sysbot+gh@w3.org>
Per the current spec <https://drafts.csswg.org/css-lists/#creating-counters> counter values should percolate thru the element tree, same as other styles; it just has a funky "inherit from preceding element in the document" instead of the normal inheritance from its parent element.

That said, I know that Blink, at least, *actually* inherits thru the box tree and attempts to *emulate* inheriting thru the element tree (which results in some bugs, and also some bad perf stuff).

To get a page counter, the *intention* is that you do a counter-reset/increment in @page, then counter() will pick up the correct value based on what page it ends up on. (And presumably will change values in fixpos appearing on multiple pages? This isn't well-defined.)

-- 
GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1879#issuecomment-461959118 using your GitHub account
Received on Friday, 8 February 2019 21:51:07 UTC

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