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

bug(cdkDrag): Issue scrolling/reordering "reversed" lists #30191

Open
1 task
michaelurban opened this issue Dec 16, 2024 · 1 comment
Open
1 task

bug(cdkDrag): Issue scrolling/reordering "reversed" lists #30191

michaelurban opened this issue Dec 16, 2024 · 1 comment
Labels
area: cdk/drag-drop feature This issue represents a new feature or feature request rather than a bug or bug fix P4 A relatively minor issue that is not relevant to core functions

Comments

@michaelurban
Copy link

Is this a regression?

  • Yes, this behavior used to work in the previous version

The previous version in which this bug was not present was

No response

Description

For design/UX reasons, I'm using cdk/drag-drop on a list with flex-direction: row-reverse applied. Scrolling does not trigger while dragging among other issues.

Can we get a "reversed" option to support this use case?

Reproduction

Steps to reproduce:`

  1. Apply display: flex; flex-direction: row-reverse; to a cdkDropList
  2. Try to drag+scroll an element

Expected Behavior

It would be nice if indexes and scroll behavior could work intuitively by adding a reversed option

Actual Behavior

The drag will not scroll the cdkDropList

Environment

  • Angular: v19.0.0
  • CDK/Material: v19.0.0
  • Browser(s): All
  • Operating System: Ubuntu
@michaelurban michaelurban added the needs triage This issue needs to be triaged by the team label Dec 16, 2024
@amysorto amysorto added feature This issue represents a new feature or feature request rather than a bug or bug fix P4 A relatively minor issue that is not relevant to core functions area: cdk/drag-drop and removed needs triage This issue needs to be triaged by the team labels Dec 17, 2024
@michaelurban
Copy link
Author

michaelurban commented Dec 17, 2024

It looks like it is supported. You need to import BidiModule and apply the dir="rtl" directive to the parent of the list.

It would be good to have this in the cdk/drag-drop documentation.

So much of Angular development is slamming into a wall only to find out that there's was an unmarked/undocumented tunnel a few hundred feet to the left. I appreciate the work you guys do on Angular/Material but the docs are the worst part of being an Angular developer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: cdk/drag-drop feature This issue represents a new feature or feature request rather than a bug or bug fix P4 A relatively minor issue that is not relevant to core functions
Projects
None yet
Development

No branches or pull requests

2 participants