Re: [csswg-drafts] [css-overflow-5] Scroll button pseudo-elements (#10722)

> Do you have an example? The way that we avoid this issue for carousel experiences is by ensuring that we have appropriate snap areas. I.e. we will target scrolling 85% but given `scroll-snap-type: x mandatory` it will force it to align to the nearest snap area. I think that defining snap areas would be the recommended way to avoid the scroll resting between lines.

I made a quick example here: https://codepen.io/johannesodland/pen/WNqmoYy

Before scrolling: the 3rd item is partially visible on the right side. 
<img width="441" alt="image" src="https://github.com/user-attachments/assets/af6cc89f-16f9-4967-a32b-0a6ccbf96635">


After scrolling 85%: it snaps to item 4, leaving item 3 partially visible on the left side.
<img width="433" alt="image" src="https://github.com/user-attachments/assets/c83dd5c9-ffc5-4393-8626-ea53c27ab905">


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


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 16 September 2024 18:40:11 UTC