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

Inline combinators do not respect canDrop result #702

Closed
trchtrung opened this issue May 20, 2024 · 2 comments · Fixed by #703
Closed

Inline combinators do not respect canDrop result #702

trchtrung opened this issue May 20, 2024 · 2 comments · Fixed by #703

Comments

@trchtrung
Copy link

React Query Builder version

v7.2.0

Platform

Microsoft Edge on Windows 11

Description

I tried to create a querybuilder with drag and drop using react-querybuilder/dnd. I saw the canDrop callback in docs to limit where rules/groups can be dropped. The callback works normally but when I tried to make it always return false in a querybuilder with showCombinatorsBetweenRules enabled, the drag and drop function seems to ignore the callback completely and I can still freely drop elements anywhere

Reproduction

https://codesandbox.io/p/sandbox/xenodochial-brook-37c84t

Expected behavior

Rules/groups cannot be dropped when canDrop always return false in a querybuilder with showCombinatorsBetweenRules enabled

Additional information

No response

@jakeboone02 jakeboone02 changed the title Inline combinators do not respect canDrop result Inline combinators do not respect canDrop result May 20, 2024
@jakeboone02
Copy link
Member

@trchtrung If you want to test the fix from #703, you can use this sandbox. I'll probably merge it tomorrow if I don't hear back from you.

@jakeboone02
Copy link
Member

This is included in v7.4.0.

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 a pull request may close this issue.

2 participants