- From: Robert Flack via GitHub <noreply@w3.org>
- Date: Tue, 24 Mar 2026 14:03:07 +0000
- To: public-css-archive@w3.org
You can detect this with an example case and a bit of javascript, e.g. ([live demo](https://flackr.github.io/web-demos/css-position/sticky-per-axis-feature-detect.html)):
```html
<style>
#outer { position: relative; overflow: hidden; height: 100px; }
#inner { position: relative; overflow-x: hidden; overflow-y: clip; width: 100px; }
#spacer { height: 100px; }
#sticky { width: 100px; height: 100px; position: sticky; bottom: 0; right: 0; background: green; }
</style>
<div id=outer>
<div id=inner>
<div id=spacer></div>
<div id=sticky></div>
</div>
</div>
<script>
if (window.stickyPerAxis = sticky.offsetTop == 0) {
document.documentElement.classList.add('sticky-per-axis-supported');
}
</script>
```
There may be clever ways to do the same without any script. That said, having a feature name would make it much easier.
--
GitHub Notification of comment by flackr
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/13677#issuecomment-4118565796 using your GitHub account
--
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Tuesday, 24 March 2026 14:03:07 UTC