react-sortablejs
Advanced tools
Comparing version 6.1.0 to 6.1.1
@@ -172,9 +172,7 @@ var $8zHUo$sortablejs = require("sortablejs"); | ||
...props.list | ||
]; | ||
newList.forEach((item)=>{ | ||
Object.assign(item, { | ||
].map((item)=>Object.assign(item, { | ||
chosen: false, | ||
selected: false | ||
}); | ||
}); | ||
}) | ||
); | ||
props.setList(newList, this.sortable, $7fe8e3ea572bda7a$var$store); | ||
@@ -309,8 +307,6 @@ ($parcel$interopDefault($8zHUo$tinyinvariant))(//@ts-expect-error: Doesn't exist. Will deprecate soon. | ||
$eb03e74f8f7db1f3$export$77f49a256021c8de(customs); | ||
const newList = $eb03e74f8f7db1f3$export$eca851ee65ae17e4(customs, list, evt, clone); | ||
newList.forEach((item)=>{ | ||
Object.assign(item, { | ||
const newList = $eb03e74f8f7db1f3$export$eca851ee65ae17e4(customs, list, evt, clone).map((item)=>Object.assign(item, { | ||
selected: false | ||
}); | ||
}); | ||
}) | ||
); | ||
setList(newList, this.sortable, $7fe8e3ea572bda7a$var$store); | ||
@@ -359,7 +355,6 @@ } | ||
// remove item.selected from list | ||
newList.forEach((item)=>{ | ||
Object.assign(item, { | ||
newList = newList.map((item)=>Object.assign(item, { | ||
selected: false | ||
}); | ||
}); | ||
}) | ||
); | ||
setList(newList, this.sortable, $7fe8e3ea572bda7a$var$store); | ||
@@ -384,6 +379,7 @@ } | ||
const newList = list.map((item, index)=>{ | ||
if (index === evt.oldIndex) Object.assign(item, { | ||
let newItem = item; | ||
if (index === evt.oldIndex) newItem = Object.assign(item, { | ||
chosen: true | ||
}); | ||
return item; | ||
return newItem; | ||
}); | ||
@@ -395,6 +391,7 @@ setList(newList, this.sortable, $7fe8e3ea572bda7a$var$store); | ||
const newList = list.map((item, index)=>{ | ||
if (index === evt.oldIndex) Object.assign(item, { | ||
let newItem = item; | ||
if (index === evt.oldIndex) newItem = Object.assign(newItem, { | ||
chosen: false | ||
}); | ||
return item; | ||
return newItem; | ||
}); | ||
@@ -409,10 +406,6 @@ setList(newList, this.sortable, $7fe8e3ea572bda7a$var$store); | ||
const { list: list , setList: setList } = this.props; | ||
const newList = [ | ||
...list | ||
]; | ||
newList.forEach((item)=>{ | ||
Object.assign(item, { | ||
chosen: false | ||
}); | ||
}); | ||
const newList = list.map((item)=>Object.assign(item, { | ||
selected: false | ||
}) | ||
); | ||
evt.newIndicies.forEach((curr)=>{ | ||
@@ -431,10 +424,6 @@ const index = curr.index; | ||
const { list: list , setList: setList } = this.props; | ||
const newList = [ | ||
...list | ||
]; | ||
newList.forEach((item)=>{ | ||
Object.assign(item, { | ||
chosen: false | ||
}); | ||
}); | ||
const newList = list.map((item)=>Object.assign(item, { | ||
selected: false | ||
}) | ||
); | ||
evt.newIndicies.forEach((curr)=>{ | ||
@@ -441,0 +430,0 @@ const index = curr.index; |
{ | ||
"name": "react-sortablejs", | ||
"version": "6.1.0", | ||
"version": "6.1.1", | ||
"author": { | ||
@@ -5,0 +5,0 @@ "name": "Wayne Van Son", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
73845
544