1 import move from '@proton/utils/move';
4 * Re-order elements in an array inside a group of arrays
6 export const moveInGroup = <T>(
9 { oldIndex, newIndex }: { oldIndex: number; newIndex: number }
11 return collection.map((group, i) => {
12 if (i === groupIndex) {
13 return move(group, oldIndex, newIndex);