-
Notifications
You must be signed in to change notification settings - Fork 707
[css-overflow-5] Active marker in 2d scroller? #11198
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
Comments
I think I'd propose we go with option 2, choosing the direction with more scrollable overflow, as the primary axis and in the case of a tie choosing the block axis. I could be convinced that for predictability we should go with option 1, however I am somewhat concerned with doing this if we don't have the mechanism for changing the primary axis as many of the use cases we're imagining would be in the non-default horizontal axis. |
The CSS Working Group just discussed
The full IRC log of that discussion<andreubotella> flackr: deterrmining what is the current target is typically done in a single access in most scrollers<andreubotella> flackr: however, you can have a scroller that scrolls both horizontally and vertically <andreubotella> flackr: we need to define something that works well for the plain horizontal and vertical cases, as well as combined cases <andreubotella> flackr: proposal to have a primary direction, where we choose that axis first and choose the current position in that axis <andreubotella> flackr: and for every target which is current in that axis, you check the secondary direction <andreubotella> flackr: currently primary axis follows writing-mode, but we have discussed horizontal scrolling <andreubotella> astearns: using the primary direction first is simpler, but are there case where the proximity in the minor axis is much closer and it'd make sense to use that? <andreubotella> flackr: my temptation is to avoid having too much complexity until we determine there's a need <andreubotella> flackr: my preference is to do this major, then major axis solution, and only consider other things if there are use cases <andreubotella> PROPOSED RESOLUTION: Define this algorithm in terms of the primary direction, which would be the block axis <andreubotella> flackr: this is in the spec as a recommended algorithm <andreubotella> flackr: maybe we should have a separate issue for making it normative <andreubotella> flackr: maybe the best thing would be to put the requirements normative, but the algorihtm non-normative <andreubotella> fantasai: this seems resonable for document that primarily scroll in one direction <andreubotella> fantasai: but what if you have a small viewport in a larger one? <andreubotella> flackr: as long as the tiles are aligned in the primary axis, it'd work as expected <andreubotella> flackr: this gets less good if your tiles are not aligned in a grid (e.g. staggered) <andreubotella> flackr: that would select based on the primary axis, which might not be best always <andreubotella> fantasai: we should take into account what's on the screen <andreubotella> fantasai: based on primary direction, it'd be good as long as you can't target thigns you can't see <andreubotella> flackr: targetting things you can see is important for headers of a section, which might be scrolled out of view while in the section <andreubotella> flackr: if you're making soemthing 2d, maybe you dont' want scroll markers <andreubotella> flackr: most use cases would be 1d <kizu> q+ <andreubotella> florian: what if there's a 1d path laid out through 2d in some way? <astearns> ack kizu <andreubotella> kizu: maybe we could have a switch for behavior, selecting one marker vs several <andreubotella> kizu: in 2d it could be useful if you have multiple selected elements in a grid <andreubotella> kizu: but we can experiment later <andreubotella> flackr: we have had mentions of a different selector to match multiple, which could be useful in that case (e.g. :target-visible) <andreubotella> PROPOSED RESOLUTION: For a 2D scroller, we will define an algorithm that uses a primary direction that defaults to the block axis <andreubotella> RESOLVED: For a 2D scroller, we will define an algorithm that uses a primary direction that defaults to the block axis |
The CSS working group resolution[1], as clarified in the linked bug, is to use the block axis as the primary axis when selecting the active scroll-marker in 2-D. [1] w3c/csswg-drafts#11198 (comment) Bug: 391612675 Change-Id: I3b9ecb5e2d2ef4c58dcb47c6e06b45c66ccd6f2b
The CSS working group resolution[1], as clarified in the linked bug, is to use the block axis as the primary axis when selecting the active scroll-marker in 2-D. [1] w3c/csswg-drafts#11198 (comment) Bug: 391612675 Change-Id: I3b9ecb5e2d2ef4c58dcb47c6e06b45c66ccd6f2b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6310080 Commit-Queue: David Awogbemila <awogbemila@chromium.org> Reviewed-by: Steve Kobes <skobes@chromium.org> Cr-Commit-Position: refs/heads/main@{#1426563}
The CSS working group resolution[1], as clarified in the linked bug, is to use the block axis as the primary axis when selecting the active scroll-marker in 2-D. [1] w3c/csswg-drafts#11198 (comment) Bug: 391612675 Change-Id: I3b9ecb5e2d2ef4c58dcb47c6e06b45c66ccd6f2b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6310080 Commit-Queue: David Awogbemila <awogbemila@chromium.org> Reviewed-by: Steve Kobes <skobes@chromium.org> Cr-Commit-Position: refs/heads/main@{#1426563}
The CSS working group resolution[1], as clarified in the linked bug, is to use the block axis as the primary axis when selecting the active scroll-marker in 2-D. [1] w3c/csswg-drafts#11198 (comment) Bug: 391612675 Change-Id: I3b9ecb5e2d2ef4c58dcb47c6e06b45c66ccd6f2b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6310080 Commit-Queue: David Awogbemila <awogbemila@chromium.org> Reviewed-by: Steve Kobes <skobes@chromium.org> Cr-Commit-Position: refs/heads/main@{#1426563}
…oll-marker selection axis, a=testonly Automatic update from web-platform-tests [carousel] Use block axis as primary scroll-marker selection axis The CSS working group resolution[1], as clarified in the linked bug, is to use the block axis as the primary axis when selecting the active scroll-marker in 2-D. [1] w3c/csswg-drafts#11198 (comment) Bug: 391612675 Change-Id: I3b9ecb5e2d2ef4c58dcb47c6e06b45c66ccd6f2b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6310080 Commit-Queue: David Awogbemila <awogbemila@chromium.org> Reviewed-by: Steve Kobes <skobes@chromium.org> Cr-Commit-Position: refs/heads/main@{#1426563} -- wpt-commits: 40cb124446cf4ea531462116c1a19eb219dfbf21 wpt-pr: 51032
…oll-marker selection axis, a=testonly Automatic update from web-platform-tests [carousel] Use block axis as primary scroll-marker selection axis The CSS working group resolution[1], as clarified in the linked bug, is to use the block axis as the primary axis when selecting the active scroll-marker in 2-D. [1] w3c/csswg-drafts#11198 (comment) Bug: 391612675 Change-Id: I3b9ecb5e2d2ef4c58dcb47c6e06b45c66ccd6f2b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6310080 Commit-Queue: David Awogbemila <awogbemila@chromium.org> Reviewed-by: Steve Kobes <skobes@chromium.org> Cr-Commit-Position: refs/heads/main@{#1426563} -- wpt-commits: 40cb124446cf4ea531462116c1a19eb219dfbf21 wpt-pr: 51032
…oll-marker selection axis, a=testonly Automatic update from web-platform-tests [carousel] Use block axis as primary scroll-marker selection axis The CSS working group resolution[1], as clarified in the linked bug, is to use the block axis as the primary axis when selecting the active scroll-marker in 2-D. [1] w3c/csswg-drafts#11198 (comment) Bug: 391612675 Change-Id: I3b9ecb5e2d2ef4c58dcb47c6e06b45c66ccd6f2b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6310080 Commit-Queue: David Awogbemila <awogbemila@chromium.org> Reviewed-by: Steve Kobes <skobes@chromium.org> Cr-Commit-Position: refs/heads/main@{#1426563} -- wpt-commits: 40cb124446cf4ea531462116c1a19eb219dfbf21 wpt-pr: 51032
When you have a group of scroll targets in a scroller that can scroll in multiple directions, how do you determine which one is active?
Options:
primary-overflow-direction
from Setting the primary scrolling direction for a scroll container #10060.With options 1 and 2, we could use the single direction as the primary direction but still use the secondary direction when the targeted location in the primary direction is the same. E.g. the first step could be determining the active set of markers on the primary direction, then repeat with the secondary direction.
The text was updated successfully, but these errors were encountered: