Skip to content

cdkDrag element prevents native drag interactions even when there is a drag handle #13779

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

Closed
atscott opened this issue Oct 23, 2018 · 1 comment

Comments

@atscott
Copy link
Contributor

atscott commented Oct 23, 2018

Bug, feature request, or proposal:

The cdkDrag element prevents native drag interactions even when there is a valid cdkDragHandle in that cdkDrag

What is the expected behavior?

When there is a cdkDragHandle inside a cdkDrag, native drag interactions are only disabled for the drag handle. If you can't drag without using the drag handle, I don't see why native drag interactions should be disabled on anything other than the drag handle.

What is the current behavior?

native drag interactions are disabled for the main cdkDrag and the drag handle

What are the steps to reproduce?

Providing a StackBlitz reproduction is the best way to share your issue.

StackBlitz starter: https://stackblitz.com/edit/angular-91ym56

Using an android phone or chrome dev tools device simulator and try to scroll down on the demo, using the box as a start position. You cannot scroll down, but I would have expected that you can unless you start the drag on the drag handle.

What is the use-case or motivation for changing an existing behavior?

On mobile, it is really hard to scroll the page when the cdkDrag element is large. A drag handle helps limit the drag/drop size so the user can still scroll when touching the cdkDrag element and not the cdkDragHandle.

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

Reproduced on android chrome and desktop chrome device emulator (in developer tools). For whatever reason, this is not reproducible on iOS (which may indicate the native drag interactions are not being disabled correctly for iOS).

Is there anything else we should know?

atscott added a commit to atscott/components that referenced this issue Oct 24, 2018
If there is a drag handle, do not disable native drag events on the cdkDrag
element.

Fixes angular#13779.
atscott added a commit to atscott/components that referenced this issue Oct 24, 2018
If there is a drag handle, do not disable native drag events on the cdkDrag
element.

Fixes angular#13779.
atscott added a commit to atscott/components that referenced this issue Nov 5, 2018
If there is a drag handle, do not disable native drag events on the cdkDrag
element.

Fixes angular#13779.
atscott added a commit to atscott/components that referenced this issue Nov 5, 2018
If there is a drag handle, do not disable native drag events on the cdkDrag
element.

Fixes angular#13779.
vivian-hu-zz pushed a commit that referenced this issue Nov 6, 2018
If there is a drag handle, do not disable native drag events on the cdkDrag
element.

Fixes #13779.
atscott added a commit to atscott/components that referenced this issue Nov 7, 2018
If there is a drag handle, do not disable native drag events on the cdkDrag
element.

Fixes angular#13779.
vivian-hu-zz pushed a commit that referenced this issue Nov 12, 2018
…13780)

If there is a drag handle, do not disable native drag events on the cdkDrag
element.

Fixes #13779.
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants