ListBox does not throw onDrop event if there are no items in it
When you drag&drop items from one ListBox to another, if the target ListBox does not have items, the onDrop event does not fire. This is due to the fact that the onDrop event fires either from a target item or from the container ("k-list-scroller"). However, the height of one of the nested elements is "inherit" and it expands over the entire "k-list-scroller" container and prevents the onDrop to ever be fired.
To replicate the problem:
- Open the example: https://stackblitz.com/edit/react-c53cvn?file=app%2Fmain.jsx
- Drag all items from one of the ListBox components and try to drag one item back to it
Expected behavior: User should be able to drag item in empty ListBox
Workaround (fix):
<style>
.k-listbox .k-list-scroller .k-list.k-list-md{
height: auto;
max-height: 100%;
}
https://stackblitz.com/edit/react-dtq4qp?file=app%2Fmain.jsx,index.html
Mentioned in Ticket ID: 1581945
The issue is still reproducible with the latest version (5.11.0): https://stackblitz.com/edit/react-c53cvn-9x3xtg?file=app%2Fmain.jsx
Reported in Ticket ID: 1609527
Also reported in Ticket ID: 1619795
Fixed in dev version v7.0.0-develop.5