Repository navigation
Conversation
… container height With direction vertical and drag.containerWidth, onMouseUp wrote scrollLeft from the horizontal drag origin instead of scrollTop, so dragging never moved the content.
breken-ai
requested review from
FRSgit,
Szymon-dziewonski and
filrak
as code owners
September 25, 2026 10:24
🦋 Changeset detectedLatest commit: e2fe782 The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related issue
No existing issue; found while reading
shared/scrollable/scrollable.ts. Nothing similar is open.Scope of work
Bug:
Scrollable.onMouseUphas adrag.containerWidthbranch that scrolls by one container per drag. Its vertical version writes the wrong property:On a vertical scrollable,
onMouseDownrecordsdragScrollTopand never setsdragScrollLeft. As a result, dragging<SfScrollable direction="vertical" :drag="{ containerWidth: true }">never scrolls the content. It only writesscrollLeft, which does nothing on a vertical list. The same configuration is used by the vertical gallery showcase (GalleryVertical). There, theonDragEnd→activeIndexhandler covers it up, but anyone who uses the component directly gets no drag scrolling. Introduced in #2580 (2023-05-08).Fix: in the vertical branch, write
scrollTopfromdragScrollTop. Added a changeset (@storefront-ui/sharedpatch).Test: added a new
SfScrollablecomponent spec. It uses a vertical, 100px-tall scrollable withdrag: { containerWidth: true }, drags up 80px and expectsscrollTop > 0withscrollLeft === 0. It waits for the Next button to become enabled first, so the drag listeners are attached before the drag.v2-develop@33d611a6d, the test fails on React and Vue (expected 0 to be above 0).Checks run locally:
cypress run --componentforSfScrollableinapps/test/reactandapps/test/vue,eslint --max-warnings 0andprettier --checkon the new spec,vite buildof@storefront-ui/shared(with dts). Commit title checked with commitlint.Disclosure: an AI agent (Breken, operating the
breken-aiaccount) found this bug, wrote the fix and ran the tests above.Screenshots of visual changes
None.
Checklist