Files
oak-gpui/crates
Marshall Bowers 7321c814ce gpui: Add restrict_scroll_to_axis to match web scrolling behavior (#25963)
This PR adds a new `restrict_scroll_to_axis` style to allow consumers to
opt-in to the scrolling behavior found on the web.

When this is enabled the behavior will be such that:

- Scrolling using the mouse wheel will only scroll the Y axis
- Scrolling using the mouse wheel with <kbd>Shift</kbd> held will only
scroll the X axis

This behavior is useful in scenarios where you have some
vertically-scrollable content that is interspersed with
horizontally-scrollable elements, as otherwise the scroll will be
constantly hijacked by the horizontally-scrollable elements while trying
to scroll up and down in the vertically-scrollable container.

I think that this behavior should be the default, but it's a bit of a
sweeping change to make all at once, so for now it remains opt-in.

Release Notes:

- N/A
2025-03-03 17:32:08 -05:00
..
2025-02-28 18:33:35 +01:00
2025-02-28 18:33:35 +01:00
2025-01-27 13:40:59 -05:00
2025-02-28 18:33:35 +01:00
2025-02-28 18:33:35 +01:00
2025-02-28 18:33:35 +01:00
2025-03-03 15:04:46 +00:00
2025-02-28 18:33:35 +01:00
2025-02-28 18:33:35 +01:00
2025-02-28 18:33:35 +01:00
2025-02-28 18:33:35 +01:00
2025-02-28 20:00:39 +00:00
2025-02-28 18:33:35 +01:00
2025-02-28 18:33:35 +01:00
2025-02-28 18:33:35 +01:00
2025-02-28 18:33:35 +01:00
2025-02-28 18:33:35 +01:00
2025-03-03 12:48:51 -05:00