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

fix(drag-drop): unable to drop into connected sibling that was scrolled into view #16681

Merged
merged 1 commit into from
Aug 27, 2019

Conversation

crisbeto
Copy link
Member

@crisbeto crisbeto commented Aug 4, 2019

In the scenario where two drop lists are connected and one of them is scrolled out of view, even if the user scrolls it into view, the list won't accept the dragged item until the user starts a new drag sequence. The issue comes from the fact that we only update the cached dimensions of the list in which we're currently dragging, but not the ones that it's connected to. These changes fix the issue by also updating the dimensions of all connected lists.

…ed into view

In the scenario where two drop lists are connected and one of them is scrolled out of view, even if the user scrolls it into view, the list won't accept the dragged item until the user starts a new drag sequence. The issue comes from the fact that we only update the cached dimensions of the list in which we're currently dragging, but not the ones that it's connected to. These changes fix the issue by also updating the dimensions of all connected lists.
@crisbeto crisbeto added P2 The issue is important to a large percentage of users, with a workaround target: patch This PR is targeted for the next patch release labels Aug 4, 2019
@googlebot googlebot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Aug 4, 2019
Copy link
Member

@jelbourn jelbourn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jelbourn jelbourn added pr: lgtm action: merge The PR is ready for merge by the caretaker labels Aug 21, 2019
@jelbourn jelbourn merged commit dd59044 into angular:master Aug 27, 2019
mmalerba pushed a commit to mmalerba/components that referenced this pull request Aug 27, 2019
…ed into view (angular#16681)

In the scenario where two drop lists are connected and one of them is scrolled out of view, even if the user scrolls it into view, the list won't accept the dragged item until the user starts a new drag sequence. The issue comes from the fact that we only update the cached dimensions of the list in which we're currently dragging, but not the ones that it's connected to. These changes fix the issue by also updating the dimensions of all connected lists.
@janaukema
Copy link

janaukema commented Sep 12, 2019

Since v 8.2.0 was released, the issue #16648 was not fixed.
Using the stackblitz example given in the mentioned issue, the example works the same as before.

crisbeto added a commit to crisbeto/material2 that referenced this pull request Sep 21, 2019
… into view via the parent

In angular#16681 we added some logic that updates the cached dimensions if the document is scrolled while dragging, however it didn't account for any scrollable parent nodes that might've been scrolled. These changes switch the event listener to use capturing so that we can pick up all of the elements being scrolled.

Fixes angular#17144.
andrewseguin pushed a commit that referenced this pull request Sep 27, 2019
… into view via the parent (#17162)

In #16681 we added some logic that updates the cached dimensions if the document is scrolled while dragging, however it didn't account for any scrollable parent nodes that might've been scrolled. These changes switch the event listener to use capturing so that we can pick up all of the elements being scrolled.

Fixes #17144.
andrewseguin pushed a commit that referenced this pull request Sep 30, 2019
… into view via the parent (#17162)

In #16681 we added some logic that updates the cached dimensions if the document is scrolled while dragging, however it didn't account for any scrollable parent nodes that might've been scrolled. These changes switch the event listener to use capturing so that we can pick up all of the elements being scrolled.

Fixes #17144.

(cherry picked from commit 2c1c30a)
@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 Oct 13, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker cla: yes PR author has agreed to Google's Contributor License Agreement P2 The issue is important to a large percentage of users, with a workaround target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants