Closed Bug 2020227 Opened 7 months ago Closed 6 months ago

Allow snap target elements, which were the targets on an axis, for the other axis when re-snapping

Categories

(Core :: Layout: Scrolling and Overflow, defect, P2)

defect

Tracking

()

RESOLVED FIXED
151 Branch
Tracking Status
firefox151 --- fixed

People

(Reporter: hiro, Assigned: hiro)

References

Details

Attachments

(2 files)

We disallow such elements on re-snapping, but the spec doesn't mention it clearly. So we can be permissive for such elements.

Assignee: nobody → hikezoe.birchill
Status: NEW → ASSIGNED
Pushed by rperta@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/80d8075443c9 https://hg.mozilla.org/integration/autoland/rev/6f204d007023 Revert "Bug 2020227 - Allow the previous snap target elements even if it was for the other axis. r=botond" for causing mochitest related failures at browser_spinner_keynav.js

Backed out for causing mochitest related failures at browser_spinner_keynav.js
Backout link
Push with failures
Failure log(s)

Flags: needinfo?(hikezoe.birchill)

So the scroll container in the browser test is not horizontally scrollable. But while we are collecting snap targets on resnap, we do collect snap targets even if the scroller is not scrollable on the axis, thus with the check which was dropped in D285438, we did choose an in-appropriate snap target (which is the first element in tree order), that's because in the scroll container all children is positioned at 0 on X axis.

A patch is coming.

Flags: needinfo?(hikezoe.birchill)
Attachment #9553884 - Attachment description: Bug 2020227 - Don't collect snap targets for an axis if the scroll range in that axis is zero on resnap. r?botond → Bug 2020227 - Ignore snap points outside of the viewport while collecting last snap target ids for the next re-snapping. r?botond
Attachment #9548927 - Attachment description: Bug 2020227 - Allow the previous snap target elements even if it was for the other axis. r?botond → Bug 2020227 - Prefer the block-axis snap target for both axes when the inline and block re-snap candidate sets are disjoint. r?botond
Blocks: 2020226
Pushed by hikezoe.birchill@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/1875516aee4a https://hg.mozilla.org/integration/autoland/rev/8db4ba889629 Ignore snap points outside of the viewport while collecting last snap target ids for the next re-snapping. r=botond https://github.com/mozilla-firefox/firefox/commit/dbcf56e06414 https://hg.mozilla.org/integration/autoland/rev/cc8522a45c91 Prefer the block-axis snap target for both axes when the inline and block re-snap candidate sets are disjoint. r=botond https://github.com/mozilla-firefox/firefox/commit/35ce57c04db4 https://hg.mozilla.org/integration/autoland/rev/4bedc9077703 apply code formatting via Lando
Status: ASSIGNED → RESOLVED
Closed: 6 months ago
Resolution: --- → FIXED
Target Milestone: --- → 151 Branch
Blocks: 1885458
Blocks: 2019503
Blocks: 1884967
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/59196 for changes under testing/web-platform/tests
Upstream PR merged by moz-wptsync-bot
QA Whiteboard: [qa-triage-done-c152/b151]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: