@syncfusion/ej2-lists 28.1.33 → 28.1.37

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.
@@ -4224,6 +4224,7 @@ let Sortable = Sortable_1 = class Sortable extends Base {
4224
4224
  const isPlaceHolderPresent = this.isPlaceHolderPresent(dropInst);
4225
4225
  if (isPlaceHolderPresent) {
4226
4226
  const curIdx = this.getIndex(dropInst.placeHolderElement, dropInst);
4227
+ prevIdx = this === dropInst && (prevIdx - curIdx) >= 1 ? prevIdx - 1 : prevIdx;
4227
4228
  const args = {
4228
4229
  previousIndex: prevIdx, currentIndex: curIdx, target: e.target, droppedElement: this.target,
4229
4230
  helper: e.helper, cancel: false, handled: false
@@ -4239,7 +4240,7 @@ let Sortable = Sortable_1 = class Sortable extends Base {
4239
4240
  }
4240
4241
  dropInst.element.insertBefore(this.target, dropInst.placeHolderElement);
4241
4242
  const curIdx = this.getIndex(this.target, dropInst);
4242
- prevIdx = this === dropInst && (prevIdx - curIdx) > 1 ? prevIdx - 1 : prevIdx;
4243
+ prevIdx = this === dropInst && (prevIdx - curIdx) >= 1 ? prevIdx - 1 : prevIdx;
4243
4244
  this.trigger('drop', {
4244
4245
  event: e.event, element: dropInst.element, previousIndex: prevIdx, currentIndex: curIdx,
4245
4246
  target: e.target, helper: e.helper, droppedElement: this.target, scopeName: this.scope, handled: handled