-
Notifications
You must be signed in to change notification settings - Fork 642
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
[4.x]: Drag and drop not working on Neo child blocks #12896
Comments
Extra context: I had assumed it's a Craft bug because it worked properly with Craft 4.3. I've just done some quick testing and found that it was working as late as 4.4.0-beta.4 and specifically seems to have been introduced with a6eeabf. |
Hi, thanks for reporting and for the additional info. I created a PR to fix this. |
3.8.3 and 4.4.3 are out with the fix! |
Just FYI, this has broken Navigation (just for Craft 3) which uses a manual structure setup. Refer to verbb/navigation#348 We revamped the navigation builder in Craft 4, so it's not an issue there. We render Navigation nodes within a fake element index, rather than constructing things ourselves, manually like in Craft 3. What I don't quite understand is the thinking here, because according to StructureDrag.js you can have multiple selectors for the handles of the drag trigger: this.base($items, {
handle: '.element:first, .move:first',
helper: this.getHelper.bind(this),
}); Because this has been changed to use only To put this visually, you can see the difference when calling: console.log($(this.settings.handle, item));
console.log($(this.settings.handle, item).first()); ![]() So the ![]() I'm looking into how this still seems to work for Sections which use the structure layout, so it's certainly a Navigation-specific thing, but I'm sure others might be using the Of course, none of this has to do with the Neo issue listed here, which I'm not across. |
@engram-design I have a few ideas on this; we’ll discuss it internally, and I’ll get back to you. |
@engram-design We released Craft 3.8.12 today with a fix for that 🎉 |
Seems to have sorted it, thanks! |
What happened?
Description
When attempting to grab a Neo child block and reorder it, the entire parent block is grabbed instead.
An issue was opened in the Neo repo, but it was closed with an assumption that it is a Craft bug.
However, I tested with Matrix fields, and I can drag and drop child blocks as expected. Even a Matrix field within a Neo block works, too.
So, it might not be a Craft bug, but I wanted to open an issue just in case.
Craft CMS version
4.4.1
Installed plugins and versions
The text was updated successfully, but these errors were encountered: