Hi!
I can't find anything about validating drop targets. The only example in the demos checks the validity in the onDrop event. A bit late ...
Here are a few alternatives what will be useful for the TreeView to have:
1) new event OnDrag which fires when item is dragged over and dragged out of another item. Returns boolean indicating dropping is enabled. Requires a lot of roundtrips...
2) new properties of the TreeView items (DragType, DropTypes). Disables drop when DragType not in DropTypes.
3) a more generic DropZone component as in 2) which also could be used in TreeView templates.
https://chrissainty.com/investigating-drag-and-drop-with-blazor/ wrote an interesting article (sponsored by Telerik Blazor!)
https://github.com/chrissainty/SimpleDragAndDropWithBlazor
Could be a inspiration for a generic DropZone component!
Best regards,
Jan