You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I guess this ties in a bit with a feature you've named obstacles. As commonly seen in website-builders, or todo-lists, it'd be really useful to have a feature that prevents elements being dragged on top of other elements.
I guess the slight divergence from the obstacles feature would be the behaviour here. I'd like to be able to choose to either prevent dropping of an object by changing the cursor/otherwise indicating that it isn't possible, but more importantly - and this works better if you've got a grid enabled, and if you're restricting movement to a single direction, but I'd like to be able to tell other elements to move out of the way, allowing me space to drop the element. In the case that I dropped it there, the elements would move completely out of the way to accommodate the dropped one.
It's useful when you have a set of blocks and you just want them to be re-arrange-able.
Hopefully this is clear enough but if not, I can find an example!
The text was updated successfully, but these errors were encountered:
Not sure if this is fully in the scope of the library. I could add an option beforeCollide which fires when it is about to hit the obstacle area, and you could perform your logic in that.
Rewriting v3 to be fully modular, you can write your own plugins to implement this. As for the obstacles feature, it will be moved under regions with allow and block properties. Either happening in v3 or v3.x.
If you do write such a plugin, would love for you to publish so I could feature on the site 😄
I guess this ties in a bit with a feature you've named obstacles. As commonly seen in website-builders, or todo-lists, it'd be really useful to have a feature that prevents elements being dragged on top of other elements.
I guess the slight divergence from the obstacles feature would be the behaviour here. I'd like to be able to choose to either prevent dropping of an object by changing the cursor/otherwise indicating that it isn't possible, but more importantly - and this works better if you've got a grid enabled, and if you're restricting movement to a single direction, but I'd like to be able to tell other elements to move out of the way, allowing me space to drop the element. In the case that I dropped it there, the elements would move completely out of the way to accommodate the dropped one.
It's useful when you have a set of blocks and you just want them to be re-arrange-able.
Hopefully this is clear enough but if not, I can find an example!
The text was updated successfully, but these errors were encountered: