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

Tree: DragNode/DropNodes are wrong when user filters the tree in TreeDragDropEvent object #7698

Open
ozanbatuhanceylan opened this issue Feb 13, 2025 · 2 comments
Labels
Type: Bug Issue contains a defect related to a specific component.

Comments

@ozanbatuhanceylan
Copy link

ozanbatuhanceylan commented Feb 13, 2025

Describe the bug

When the user filters anything in the tree, the tree renders with the filtered result well, and when the user drags and drops a node, node infos in the TreeDragDropEvent object show old values and set dragNode and dropNode with old indexes. so we couldn't find the drag or drop node.

Reproducer

https://stackblitz.com/edit/vitejs-vite-lvecvsfn?file=src%2FApp.tsx

System Information

"react": "^18.2.0",
"primereact": "^10.9.1",

Steps to reproduce the behavior

  1. Enable drag & drop
  2. Enable filtering
  3. Filter anything
  4. Drag and drop
  5. Track the TreeDragDropEvent

Expected behavior

DragNode and DropNode should be exact nodes that the user handles

@ozanbatuhanceylan ozanbatuhanceylan added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Feb 13, 2025
@melloware melloware added Status: Needs Reproducer Issue needs a runnable reproducer and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Feb 13, 2025
Copy link

Please fork the Stackblitz project and create a case demonstrating your bug report. This issue will be closed if no activities in 20 days.

@ozanbatuhanceylan
Copy link
Author

I updated the issue with forked stackblitz project

@melloware melloware added Type: Bug Issue contains a defect related to a specific component. and removed Status: Needs Reproducer Issue needs a runnable reproducer labels Feb 13, 2025
@melloware melloware changed the title Tree Component: DragNode and DropNodes are wrong when user filters the tree in TreeDragDropEvent object Tree: DragNode and DropNodes are wrong when user filters the tree in TreeDragDropEvent object Feb 13, 2025
@melloware melloware changed the title Tree: DragNode and DropNodes are wrong when user filters the tree in TreeDragDropEvent object Tree: DragNode/DropNodes are wrong when user filters the tree in TreeDragDropEvent object Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Issue contains a defect related to a specific component.
Projects
None yet
Development

No branches or pull requests

2 participants