angular-multiple-drag
v0.0.1
Published
Simplest way to make your angular items movable
Downloads
79
Maintainers
Readme
Angular Multiple Drag Module
Simplest way to make your angular items movable
This module uses Angular Multiple Selection Module
##Installation
###Using npm
npm install angular-multiple-drag###Using bower
bower install angular-multiple-drag###From source
Download source from github.com
##Usage
- Add
multiple-selection.min.jsandmultiple-drag.min.jsfiles to your application
<script type="text/javascript" src="multiple-selection.min.js"></script>
<script type="text/javascript" src="multiple-drag.min.js"></script>- Add module to your app
angular.module('app', ['multipleDrag']) - Add
multiple-selection-zoneattribute to element where selectable items will be located - Add
multiple-selection-itemattribute to each selectable item - Add
multiple-drag-itemattribute to each selectable item that can move - Customize css
##How it works Each draggable item has it`s own angular scope with variables
| Name | Description |
| ------------- | ------------- |
| isDraggable | true if element can be movable |
| isDragging | true if element now moving |
###How to customize
- Add
ng-classto your item
<div multiple-drag-item ng-class="{'dragging': isDragging}"></div>- Customizing
.draggingin your css
.selected {
background-color: red !important;
}