1.2.0 • Published 4 years ago

tushar-ng-drag-drop v1.2.0

Weekly downloads
9
License
MIT
Repository
github
Last release
4 years ago

Angular Drag and Drop

A simple drag and drop library that help to move data from draggable to droppable.

Demo

npm.io

Demo.

Installation

As a prerequisite, you need boostrap 3.X library.

npm i ngx-drag-drop
npm i tushar-ng-drag-drop

Usage

App Module

import {DragDropModule} from 'drag-drop'

imports: [
  DragDropModule
],

Html file

<tushar-ng-drag-drop 
   [documentList]="documentList"
   [documentTypeList]="documentTypeList"
   (onDraggable) ="onDraggableData($event)"
   (onLeftDraggableDrop)="onLeftDraggableDrop($event)"
   (onRightDraggableDrop)="onRightDraggableDrop($event)"
></tushar-ng-drag-drop>

Ts file

public documentList: any = [];
public documentTypeList: any = [];
constructor(){      
}
onDraggableData(itemObj:any){
  console.log(itemObj);  
}
onLeftDraggableDrop(leftItemArr:any){
  console.log(leftItemArr);
}
onRightDraggableDrop(rightItemArr:any){
  console.log(rightItemArr);
}

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Ref

NgxDragDrop

License

MIT

1.2.0

4 years ago

1.1.1

4 years ago

1.1.0

4 years ago

1.0.0

4 years ago