amendx / vue-dndrop

:herb: A vue library for drag and drop :sparkles:
https://amendx.github.io/vue-dndrop
MIT License
207 stars 21 forks source link

Behaviour prop is not reactive. #82

Open z0lo13 opened 1 year ago

z0lo13 commented 1 year ago
<Container class="scroll-content dragContainer" group-name="1" :behaviour="allowDropToAll ? 'move' : 'copy'" @drop="onDrop('remove', $event)" :get-child-payload="(index) => items[index]" @drag-start="handleDragStart" @drag-end="() => allowDropToAll = false">
  <Draggable v-for="(item, i) in items" :key="item.id" class="dragItem" ref="dragItems">
    <ItemCard :item="item" @change="(itemData) => handleItemChange(i, itemData)" :tags="tags" />
  </Draggable>
</Container>

I want to accept drop only if is allowed. I am not sure if i am missing anything here. Otherwise it must copy from it.