W3C home > Mailing lists > Public > public-css-archive@w3.org > January 2021

Re: [csswg-drafts] [css-contain-2] Allow scroll position to be restored when element becomes un-skipped with content-visibility (#5869)

From: Robert Flack via GitHub <sysbot+gh@w3.org>
Date: Wed, 13 Jan 2021 21:25:09 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-759748934-1610573108-sysbot+gh@w3.org>
At a high level this makes sense, but a few thoughts come to mind which may complicate the design of this.

It seems as though you should be able to query the offset (e.g. scrollTop and scrollLeft) and size (scrollHeight and scrollWidth) forcing a layout if these are no longer fresh. This is similar to querying the bounds of an element within the display locked tree.

When contents change I think we should be as consistent as possible with the behavior where the tree is not locked. I.e. with scroll anchoring we would attempt to anchor to the element at the top of the scroller. I think the same should happen here, where we anchor to the last element that was at the top of the scroller when it was locked.

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

Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 13 January 2021 21:25:10 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:42:25 UTC