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: revert static drop mode for tree grid #3786

Merged
merged 2 commits into from
Oct 11, 2024

Conversation

vursen
Copy link
Contributor

@vursen vursen commented Oct 9, 2024

A while ago, #3444 updated the grid examples to set the drop mode dynamically. However, in tree grids, setting the drop mode dynamically on drag start causes an immediate reset of the scroll position. This completely disrupts the drag-and-drop process unless the grid is at the top. While losing the scroll position is a known limitation in tree grids, we should avoid recommending configurations that result in a reset right at the start of dragging.

Related to vaadin/flow-components#6662

@vursen vursen requested a review from tomivirkki October 9, 2024 13:57
@vursen vursen marked this pull request as ready for review October 9, 2024 13:58
Copy link
Member

@tomivirkki tomivirkki left a comment

Choose a reason for hiding this comment

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

Using a static drop mode also causes some confusing UX, but maybe it's the lesser evil. Ideally tree grid should be fixed to not lose its sroll position on drop mode change.

@vursen
Copy link
Contributor Author

vursen commented Oct 11, 2024

Meanwhile, I created vaadin/flow-components#6713 in which I described a solution that could resolve this issue.

@vursen vursen merged commit 29b41d8 into latest Oct 11, 2024
3 of 4 checks passed
@vursen vursen deleted the revert-static-drop-mode-for-tree-grids branch October 11, 2024 12:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants