W3C home > Mailing lists > Public > public-css-archive@w3.org > August 2020

Re: [csswg-drafts] [css3 positioning] support position:sticky inside an overflow:hidden|auto on general parents (#865)

From: Merkhad Luigton via GitHub <sysbot+gh@w3.org>
Date: Wed, 19 Aug 2020 18:10:14 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-676580107-1597860613-sysbot+gh@w3.org>
for anyone looking for a solution for native html table i have posted on stackoverflow here:https://stackoverflow.com/questions/63384685/overflowauto-doesnt-work-as-expected-with-positionsticky and also a jsfiddle here: https://jsfiddle.net/uf468ocy/
basically it  has a copy table with only the headers which is shown as the header is scrolled out of position.

it possible way i was thinking to make it work better to have ti work natively i would think to put sticky op the scrolling container with overflow such that when the container is scrolled out of view the top "sticks" while the actual container continues to scroll.......if that makes sense

for example say i have a div #data like this

<div id="data" style="overflow:auto;position:sticky;top:0;">
<div id="sticky-element" style="position:sticky;top:0;">
then we scrolling would stick data to the top of viewport instead of scrolling it past, while the content of data is then scolled which sticks the element at the top of the data which is the top of the screen or something like that

curremtly if the sticky element is larger than the view port it just scrolls past

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

Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 19 August 2020 18:10:15 UTC

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