ngx-explorer-dnd
Version:
## _Drag & Drop in Angular like in a desktop explorer!_
29 lines (28 loc) • 755 B
TypeScript
export interface Translate3DPosition {
startX: number;
startY: number;
x: number;
y: number;
width: number;
height: number;
halfWidthX: number;
halfHeightY: number;
}
export declare enum DragRowPosition {
SMALLER = 0,
GREATER = 1,
SAME = 2,
UNDEFINED = 3
}
export interface SameDragRow {
sameRow: boolean;
dragRowPosition: DragRowPosition;
sameLineAsMouse: DragRowPosition;
}
/**
* Moves an item one index in an array to another.
* @param array Array in which to move the item.
* @param fromIndex Starting index of the item.
* @param toIndex Index to which the item should be moved.
*/
export declare function moveItemInArray<T = any>(array: T[], fromIndex: number, toIndex: number): void;