Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[css-overflow] Remove prev and next scroll-button-direction #11249

Open
danielsakhapov opened this issue Nov 20, 2024 · 2 comments
Open

[css-overflow] Remove prev and next scroll-button-direction #11249

danielsakhapov opened this issue Nov 20, 2024 · 2 comments

Comments

@danielsakhapov
Copy link
Contributor

prev and next <scroll-button-direction> values make ::scroll-button() selectors layout dependent, but the spec doesn't define the time and the way browsers should match it.

I want to discuss if we really need them at all, and then either remove them or better specify what and when to do.
This layout dependency for CSS selectors is a new thing, so, I want to also discuss the complexity vs the usefullness of it.

cc: @tabatkins @flackr @lilles

@flackr
Copy link
Contributor

flackr commented Nov 21, 2024

I think one way we could get rid of the layout dependency is to have prev and next be separate from the other scroll-button pseudo-elements. Then the selector always refers to the "prev" and "next" pseudo, whose direction only needs to be known when the button is activated.

That said, I think we could make these work in a similar way to scroll state queries where we rerun style and layout if the matched pseudo changes from the initially matched one.

@tabatkins
Copy link
Member

Hm, so having six buttons - block-axis, inline-axis, and longest-axis? That could work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants