neos-ui
neos-ui copied to clipboard
Drag-n-Drop in content canvas
The simplest implementation could be just to add move handle to the inline toolbar and drop targets to before and after elements in CCs. Should work exactly as it does in the tree. The smooth scrolling would be done with the plugin that we use in the tree. We can even make draging work from the tree into inline and vice versa.
@aertmann had an idea back in the ages to show a map of zoomed-out view of all elements on the page on drag. But this would be ofc way harder to implement, and I'm not even sure it would be beneficial, since with a good smooth scroll in place it should be no problem to move elements all over the page.
UX tasks: design the look of the drag handle and of drop targets.
someone actually implemented a wip idea here in slack: https://neos-project.slack.com/archives/C0U0KEGDQ/p1711020584197129
A plugin does something similar with https://github.com/patriceckhart/NeosRulez.Neos.MoveableNodes
While working on the prototype I ran into issues due to https://github.com/ckeditor/ckeditor5/issues/16898 CK5 v40 stop all drag events from bubbling up, which is the reason I cannot drag anything over an element with an inline editable properly. Thinking about patching this until they fix it.