svelte-dnd-action 0.9.49 → 0.9.50

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1880,7 +1880,7 @@
1880
1880
  config.dropFromOthersDisabled = dropFromOthersDisabled;
1881
1881
  dzToConfig.set(node, config);
1882
1882
  registerDropZone(node, newType);
1883
- var shadowElIdx = findShadowElementIdx(config.items);
1883
+ var shadowElIdx = isWorkingOnPreviousDrag ? findShadowElementIdx(config.items) : -1;
1884
1884
  for (var idx = 0; idx < node.children.length; idx++) {
1885
1885
  var draggableEl = node.children[idx];
1886
1886
  styleDraggable(draggableEl, dragDisabled);
package/dist/index.mjs CHANGED
@@ -1874,7 +1874,7 @@ function dndzone(node, options) {
1874
1874
  config.dropFromOthersDisabled = dropFromOthersDisabled;
1875
1875
  dzToConfig.set(node, config);
1876
1876
  registerDropZone(node, newType);
1877
- var shadowElIdx = findShadowElementIdx(config.items);
1877
+ var shadowElIdx = isWorkingOnPreviousDrag ? findShadowElementIdx(config.items) : -1;
1878
1878
  for (var idx = 0; idx < node.children.length; idx++) {
1879
1879
  var draggableEl = node.children[idx];
1880
1880
  styleDraggable(draggableEl, dragDisabled);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "svelte-dnd-action",
3
3
  "description": "*An awesome drag and drop library for Svelte 3 and 4 (not using the browser's built-in dnd, thanks god): Rich animations, nested containers, touch support and more *",
4
- "version": "0.9.49",
4
+ "version": "0.9.50",
5
5
  "repository": {
6
6
  "type": "git",
7
7
  "url": "git+https://github.com/isaacHagoel/svelte-dnd-action.git"
@@ -526,7 +526,7 @@ export function dndzone(node, options) {
526
526
 
527
527
  dzToConfig.set(node, config);
528
528
  registerDropZone(node, newType);
529
- const shadowElIdx = findShadowElementIdx(config.items);
529
+ const shadowElIdx = isWorkingOnPreviousDrag ? findShadowElementIdx(config.items) : -1;
530
530
  for (let idx = 0; idx < node.children.length; idx++) {
531
531
  const draggableEl = node.children[idx];
532
532
  styleDraggable(draggableEl, dragDisabled);