diff --git a/bower.json b/bower.json index cdcfa372..05f1c732 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "dragular", - "version": "4.1.0", + "version": "4.2.0", "description": "Angular drag and drop library based on dragula, but full featured. For light-weight angular wrap of dragula look for angular-dragula", "main": [ "dist/dragular.min.js", diff --git a/changelog.markdown b/changelog.markdown index d9178961..607aae02 100644 --- a/changelog.markdown +++ b/changelog.markdown @@ -1,8 +1,12 @@ # X.X.X planned - not implemented -- **[Braking change!]** rename 'shared' property to 'state' - **[Braking change!]** rename 'dragulardrag' event to 'dragulardragstart' - new event 'dragulardrag' emited each iteration while dragging +# 4.2.0 Bad Moms +- UMD compatible #79 +- options.onInit, on init callback function, closes #65 +- Fixed examples #83 (Filtered model in nested ng-repeat) + # 4.1.0 Dora - IE bug fixes #68 - compileItemOnDrop fixes #71 diff --git a/dist/dragular.js b/dist/dragular.js index 2063eeca..dc6d28a6 100644 --- a/dist/dragular.js +++ b/dist/dragular.js @@ -1,4 +1,14 @@ -/******/ (function(modules) { // webpackBootstrap +(function webpackUniversalModuleDefinition(root, factory) { + if(typeof exports === 'object' && typeof module === 'object') + module.exports = factory(); + else if(typeof define === 'function' && define.amd) + define([], factory); + else { + var a = factory(); + for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i]; + } +})(this, function() { +return /******/ (function(modules) { // webpackBootstrap /******/ // The module cache /******/ var installedModules = {}; @@ -50,7 +60,7 @@ var dragularService = __webpack_require__(2); /** - * Dragular 4.1.0 by Luckylooke https://github.com/luckylooke/dragular + * Dragular 4.2.0 by Luckylooke https://github.com/luckylooke/dragular * Angular version of dragula https://github.com/bevacqua/dragula */ module.exports = 'dragularModule'; @@ -110,6 +120,10 @@ options.nameSpace = iAttrs.dragularNameSpace.split(' '); } + if(iAttrs.dragularOnInit){ + options.onInit = $scope.$eval(iAttrs.dragularOnInit); + } + drake = dragularService(iElm[0], options); } }; @@ -236,7 +250,8 @@ boundingBox: false, // lock movement inside this element boundaries mirrorContainer: doc.body, // element for appending mirror ignoreInputTextSelection: true, // text selection in inputs wont be considered as drag - compileItemOnDrop: false + compileItemOnDrop: false, + onInit: false // function callback called after dragular initialisation and providing drake as first argument }, drake = { containers: shared.containers, @@ -255,6 +270,10 @@ extendOptions(); processOptionsObject(); registerEvents(); + + if(o.onInit){ + o.onInit(drake); + } return drake; @@ -1305,4 +1324,6 @@ /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }()))) /***/ } -/******/ ]); \ No newline at end of file +/******/ ]) +}); +; \ No newline at end of file diff --git a/dist/dragular.min.js b/dist/dragular.min.js index 9b3566c3..50a8833e 100644 --- a/dist/dragular.min.js +++ b/dist/dragular.min.js @@ -1,2 +1,2 @@ -!function(e){function r(n){if(t[n])return t[n].exports;var o=t[n]={exports:{},id:n,loaded:!1};return e[n].call(o.exports,o,o.exports,r),o.loaded=!0,o.exports}var t={};return r.m=e,r.c=t,r.p="",r(0)}([function(e,r,t){"use strict";var n=t(1),o=t(2);e.exports="dragularModule",angular.module("dragularModule",[]).factory("dragularService",o).directive("dragular",n)},function(e,r){"use strict";var t=function(e){return{restrict:"A",link:function(r,t,n){function o(e){try{return JSON.parse(e)}catch(r){return}}var i,a=r.$eval(n.dragular)||o(n.dragular)||{};a&&a.containersModel&&"string"==typeof a.containersModel&&(a.containersModel=r.$eval(a.containersModel)),a&&a.dynamicModelAttribute?r.$watch(function(){return r.$eval(n.dragularModel)},function(e){e&&(i.containersModel=i.sanitizeContainersModel(r.$eval(e)))}):n.dragularModel&&(a.containersModel=r.$eval(n.dragularModel)),n.dragularNameSpace&&(a.nameSpace=n.dragularNameSpace.split(" ")),i=e(t[0],a)}}};t.$inject=["dragularService"],e.exports=t},function(e,r){(function(r){"use strict";var t={classesCache:{},containersCtx:{},containers:{},mirror:null,source:null,item:null,copy:null,sourceItem:null,sourceModel:null,sourceFilteredModel:null,target:null,targetCtx:null,targetModel:null,lastDropTarget:null,offsetX:null,offsetY:null,moveX:null,moveY:null,offsetXr:null,offsetYb:null,clientX:null,clientY:null,mirrorWidth:null,mirrorHeight:null,initialSibling:null,currentSibling:null,initialIndex:null,currentIndex:null,tempModel:null,dragOverEvents:{},lastElementBehindCursor:null,grabbed:null},n=function(e,n){function o(r,o){function d(e){return"function"==typeof e?e:Array.isArray(e)?Array.isArray(e[0])?e:[e]:[]}function y(){1!==arguments.length||Array.isArray(r)||angular.isElement(r)||r[0]||"string"==typeof r?"string"==typeof r&&(ce=document.querySelectorAll(r)):(ue=r||{},ce=[]),le=ue.copyOptions?angular.copy(ue):ue}function b(){var e=angular.extend({},ge,le);angular.extend(le,e),le.classes&&(e=angular.extend({},de,le.classes),angular.extend(le.classes,e)),le.eventNames&&(e=angular.extend({},me,le.eventNames),angular.extend(le.eventNames,e))}function N(){h(le.boundingBox)||(le.boundingBox=!1),le.containers&&(ce=le.containers),ce=c(ce),le.containersModel=d(le.containersModel),Array.isArray(le.containersFilteredModel)?le.containersFilteredModel=Array.isArray(le.containersFilteredModel[0])?le.containersFilteredModel:[le.containersFilteredModel]:le.containersFilteredModel=[],le.nameSpace||(le.nameSpace=["dragularCommon"]),Array.isArray(le.nameSpace)||(le.nameSpace=[le.nameSpace]),le.nameSpace.forEach(function(e){t.containers[e]||(t.containers[e]=[],t.containersCtx[e]=[]);for(var r=ce.length,n=t.containers[e].length,o=0;r>o;o++)t.containers[e][o+n]=ce[o],t.containersCtx[e][o+n]={o:le,m:F()[o],fm:le.containersFilteredModel[o]}})}function A(e){var r=e?"off":"on";i(T,r,"mouseup",B),ce.forEach(function(e){i(e,"on","mousedown",$)}),e||angular.forEach(["dragularenter","dragularleave","dragularrelease"],function(e){var r=le.eventNames[e];t.dragOverEvents[r]||(O.createEvent?(t.dragOverEvents[r]=O.createEvent("HTMLEvents"),t.dragOverEvents[r].initEvent(r,!0,!0)):(t.dragOverEvents[r]=O.createEventObject(),t.dragOverEvents[r].eventType=r))})}function $(e){if(1===u(e)&&!e.metaKey&&!e.ctrlKey){t.moveX=e.clientX,t.moveY=e.clientY;var r=j(e.target);r&&r.item&&(t.grabbed=r,H(),"mousedown"===e.type&&(S(r.item)?r.item.focus():e.preventDefault()))}}function B(e){if(K(),fe.dragging){e.originalEvent&&(e=e.originalEvent),t.clientX=E("clientX",e),t.clientY=E("clientY",e);var r=ae(t.mirror,t.clientX,t.clientY),n=V(r,t.clientX,t.clientY);n&&(t.copy&&se(le.copySortSource)||!t.copy||n!==t.source)?U(t.item,n):se(le.removeOnSpill)?q():J(),t.target=null,t.lastElementBehindCursor&&Y(t.lastElementBehindCursor,t.dragOverEvents.dragularrelease,r),le.scope&&le.scope.$emit(le.eventNames.dragularrelease,t.item,t.source)}}function w(e){if(!e)return!1;for(var r=le.nameSpace.length;r--;)if(-1!==t.containers[le.nameSpace[r]].indexOf(e))return!0;return le.isContainer(e)?(t.tempModel=le.isContainerModel(e),!0):(t.tempModel=null,!1)}function F(){return"function"==typeof le.containersModel?d(le.containersModel(fe,t)):le.containersModel}function D(r){e.$applyAsync(function(){var e=Array.isArray(r)?r:c(r);e.forEach(function(e){angular.forEach(le.nameSpace,function(r){var n;n=t.containers[r].indexOf(e),t.containers[r].splice(n,1),t.containersCtx[r].splice(n,1)})})})}function H(e){var r=e?"off":"on";i(T,r,"mousemove",R)}function P(e){var r=e?"off":"on";i(T,r,"selectstart",s),i(T,r,"click",s),i(T,r,"touchmove",s)}function k(){A(!0),D(ce),B({})}function R(e){if(t.grabbed&&!fe.dragging){if(e.originalEvent&&(e=e.originalEvent),0===u(e))return void B({});if(!e.clientX||e.clientX!==t.moveX||!e.clientY||e.clientY!==t.moveY){if(se(le.ignoreInputTextSelection)){var r=E("clientX",e),n=E("clientY",e),o=O.elementFromPoint(r,n);if(S(o))return}var i=t.grabbed;if(H("remove"),P(),z(),W(i),!le.direction&&C(t.sourceItem)){var a=t.sourceItem.parentNode,l=a.offsetHeight,c=a.offsetWidth,s=t.sourceItem.clientHeight,d=t.sourceItem.clientWidth;le.direction=c/d>l/s?"horizontal":"vertical"}var g=m(t.sourceItem);t.offsetX=E("pageX",e)-g.left,t.offsetY=E("pageY",e)-g.top,t.clientX=E("clientX",e),t.clientY=E("clientY",e),le.boundingBox&&(t.offsetXr=E("pageX",e)-g.right,t.offsetYb=E("pageY",e)-g.bottom),e.preventDefault(),x(t.item,le.classes.transit),te(),t.mirror.style.left=t.clientX-t.offsetX+"px",t.mirror.style.top=t.clientY-t.offsetY+"px",Z(e)}}}function j(e){if(!fe.dragging||!t.mirror){for(var r=e;C(e)&&!w(C(e));){if(le.invalid(e,r))return;if(e=C(e),!e)return}var n=C(e);if(n&&!le.invalid(e,r)&&le.moves(e,n,r,v(e)))return{item:e,source:n}}}function L(e){var r=j(e);r&&W(r)}function W(e){t.sourceItem=t.item=e.item,t.source=e.source,t.initialSibling=t.currentSibling=v(e.item),se(le.copy,[e.item,e.source])?(t.item=e.item.cloneNode(!0),t.copy=!0,le.scope&&le.scope.$emit(le.eventNames.dragularcloned,t.item,e.item)):t.copy=!1;var r=ce.indexOf(e.source);return t.sourceModel=F()[r],t.sourceFilteredModel=le.containersFilteredModel[r],t.initialIndex=X(e.item,e.source),fe.dragging=!0,le.scope&&le.scope.$emit(le.eventNames.dragulardrag,t.sourceItem,t.source),!0}function z(){fe.dragging&&t.item&&U(t.item,C(t.item))}function K(){t.grabbed=!1,H("remove"),P("remove")}function U(r,o){function i(){if(le.compileItemOnDrop){var e=angular.element(o).scope();e.$applyAsync(function(){var i=n(t.copy?a.cloneNode(!0):a)(e);r.parentNode===o&&o.removeChild(r),o.insertBefore(i[0],l)})}le.scope&&(Q(o)?le.scope.$emit(le.eventNames.dragularcancel,r,t.source,t.sourceModel,t.initialIndex):le.scope.$emit(le.eventNames.dragulardrop,r,o,t.source,t.sourceModel,t.initialIndex,t.targetModel,c)),G()}var a=t.sourceItem,l=t.currentSibling;if(t.copy&&se(le.copySortSource)&&o===t.source&&C(r)&&r.parentNode.removeChild(t.sourceItem),t.sourceModel&&!Q(o)){var c=X(r,o);t.targetCtx.fm&&(c=t.targetCtx.m.indexOf(t.targetCtx.fm[c])),t.sourceFilteredModel&&(t.initialIndex=t.sourceModel.indexOf(t.sourceFilteredModel[t.initialIndex])),e.$applyAsync(function(){t.sourceModel&&(o===t.source?t.sourceModel.splice(c,0,t.sourceModel.splice(t.initialIndex,1)[0]):(t.dropElmModel=t.copy&&!le.dontCopyModel?angular.copy(t.sourceModel[t.initialIndex]):t.sourceModel[t.initialIndex],t.tempModel?t.targetModel=t.tempModel:t.targetModel=t.targetCtx.m,o.removeChild(r),t.copy||t.sourceModel.splice(t.initialIndex,1),t.targetModel.splice(c,0,t.dropElmModel)),C(r)&&r.parentNode.removeChild(r),i())})}else i()}function q(){if(fe.dragging){var r=C(t.item);r&&r.removeChild(t.item),t.sourceModel&&e.$applyAsync(function(){t.sourceModel.splice(t.initialIndex,1),G()}),le.scope&&le.scope.$emit(t.copy?le.eventNames.dragularcancel:le.eventNames.dragularremove,t.item,r,t.sourceModel,t.initialIndex),t.sourceModel||G()}}function J(e){if(fe.dragging){var r=arguments.length>0?e:se(le.revertOnSpill),n=C(t.item),o=Q(n);o||t.copy||!r||t.source.insertBefore(t.item,t.initialSibling),!t.sourceModel||t.copy||r?le.scope&&(o||r)&&le.scope.$emit(le.eventNames.dragularcancel,t.item,t.source):U(t.item,n),(!t.sourceModel||t.copy||r||o)&&G()}}function G(){K(),ne(),t.item&&M(t.item,le.classes.transit),fe.dragging=!1,se(le.removeOnSpill)===!0&&ee(),le.scope&&(t.lastDropTarget&&le.scope.$emit(le.eventNames.dragularout,t.item,t.lastDropTarget,t.source),le.scope.$emit(le.eventNames.dragulardragend,t.item)),t.source=t.item=t.sourceItem=t.initialSibling=t.currentSibling=t.sourceModel=null,t.initialIndex=t.currentIndex=t.lastDropTarget=t.tempModel=t.targetModel=null,t.dropElmModel=t.targetCtx=t.copy=t.moveX=t.moveY=null}function Q(e,r){var n=r||(t.mirror?t.currentSibling:v(t.item));return e===t.source&&n===t.initialSibling}function V(e,r,n){function o(){var o=!1;if(w(i)){for(var a=oe(i,e),l=ie(i,a,r,n),c=Q(i,l),u=le.nameSpace.length;u--;){if(-1!==t.containers[le.nameSpace[u]].indexOf(i)){t.targetCtx=t.containersCtx[le.nameSpace[u]][t.containers[le.nameSpace[u]].indexOf(i)];break}t.targetCtx||(t.targetCtx=t.containersCtx.dragularCommon[t.containers.dragularCommon.indexOf(i)])}o=c||t.targetCtx.o.accepts(t.item,i,t.source,l,t.sourceModel,t.initialIndex)&&le.canBeAccepted(t.item,i,t.source,l,t.sourceModel,t.initialIndex),t.target!==i&&(t.target=i)}return o}for(var i=e;i&&!o();)i=C(i);return i}function Z(e){function r(e){le.scope&&le.scope.$emit(le.eventNames["dragular"+e],t.item,t.lastDropTarget,t.source),se(le.removeOnSpill)===!0&&("over"===e?_():ee())}if(t.mirror){e.originalEvent&&(e=e.originalEvent),t.clientX=E("clientX",e),t.clientY=E("clientY",e);var n,o,i,a=t.clientX-t.offsetX,l=t.clientY-t.offsetY;le.boundingBox&&(n=E("pageX",e),o=E("pageY",e),i=m(le.boundingBox)),le.lockY||(!le.boundingBox||n>i.left+t.offsetX&&ni.top+t.offsetY&&or;r++){if(o=e.children[r],i=o.getBoundingClientRect(),l&&i.left>t)return o;if(!l&&i.top>n)return o}return null}function i(){var e=r.getBoundingClientRect();return a(l?t>e.left+g(e)/2:n>e.top+f(e)/2)}function a(e){return e?v(r):r}var l="horizontal"===le.direction;return r!==e?i():o()}function ae(e,r,t){var n,o=e||{},i=o.className;return o.className+=" "+le.classes.hide,n=O.elementFromPoint(r,t),o.className=i,n}var le,ce=r||[],ue=o||{},se=I,de={mirror:"gu-mirror",hide:"gu-hide",unselectable:"gu-unselectable",transit:"gu-transit"},me={dragularenter:"dragularenter",dragularleave:"dragularleave",dragularrelease:"dragularrelease",dragularcloned:"dragularcloned",dragulardrag:"dragulardrag",dragularcancel:"dragularcancel",dragulardrop:"dragulardrop",dragularremove:"dragularremove",dragulardragend:"dragulardragend",dragularshadow:"dragularshadow",dragularover:"dragularover",dragularout:"dragularout"},ge={copyOptions:!1,classes:de,eventNames:me,containers:!1,containersModel:!1,containersFilteredModel:!1,isContainer:a,isContainerModel:p,moves:l,accepts:l,canBeAccepted:l,copy:!1,copySortSource:!1,dontCopyModel:!1,invalid:a,revertOnSpill:!1,removeOnSpill:!1,lockX:!1,lockY:!1,boundingBox:!1,mirrorContainer:O.body,ignoreInputTextSelection:!0,compileItemOnDrop:!1},fe={containers:t.containers,containersCtx:t.containersCtx,sanitizeContainersModel:d,isContainer:w,start:L,end:z,cancel:J,remove:q,destroy:k,dragging:!1};return y(),b(),N(),A(),fe}function i(e,t,n,o){var i={mouseup:"touchend",mousedown:"touchstart",mousemove:"touchmove"},a={mouseup:"pointerup",mousedown:"pointerdown",mousemove:"pointermove"},l={mouseup:"MSPointerUp",mousedown:"MSPointerDown",mousemove:"MSPointerMove"},c=angular.element(e);r.navigator.pointerEnabled&&a[n]?c[t](a[n],o):r.navigator.msPointerEnabled&&l[n]?c[t](l[n],o):i[n]&&c[t](i[n],o),c[t](n,o)}function a(){return!1}function l(){return!0}function c(e,r){return Array.isArray(e)?e:e.length?Array.prototype.slice.call(e,r):[e]}function u(e){if(e.touches)return e.touches.length;if(e.originalEvent&&e.originalEvent.touches)return e.originalEvent.touches.length;if(void 0!==e.buttons)return e.buttons;if(void 0!==e.which)return e.which;var r=e.button;return void 0!==r?1&r?1:2&r?3:4&r?2:0:void 0}function s(e){e.originalEvent&&(e=e.originalEvent),t.grabbed&&e.preventDefault()}function d(e,r){return"undefined"!=typeof window[r]?window[r]:T.clientHeight?T[e]:O.body[e]}function m(e){var r=e.getBoundingClientRect(),t=d("scrollTop","pageYOffset"),n=d("scrollLeft","pageXOffset");return{left:r.left+n,right:r.right+n,top:r.top+t,bottom:r.bottom+t}}function g(e){return e.width||e.right-e.left}function f(e){return e.height||e.bottom-e.top}function p(){return{}}function v(e){function r(){var r=e;do r=r.nextSibling;while(r&&1!==r.nodeType);return r}return e.nextElementSibling||r()}function h(e){return"object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&null!==e&&1===e.nodeType&&"string"==typeof e.nodeName}function y(e){var r=t.classesCache[e];return r?r.lastIndex=0:t.classesCache[e]=r=new RegExp("(?:^|\\s)"+e+"(?:\\s|$)","g"),r}function x(e,r){var t=e.className;t.length?y(r).test(t)||(e.className+=" "+r):e.className=r}function M(e,r){e.className=e.className.replace(y(r)," ").trim()}function b(e){return e.targetTouches&&e.targetTouches.length?e.targetTouches[0]:e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e}function E(e,r){var t=b(r),n={pageX:"clientX",pageY:"clientY"};return e in n&&!(e in t)&&n[e]in t&&(e=n[e]),!t.type||t.type.indexOf("touch")<0?t[e]:-1===t.type.indexOf("end")?t.originalEvent.touches[0][e.replace("client","page")]:!1}function C(e){return e.parentNode===document?null:e.parentNode}function S(e){return"INPUT"===e.tagName||"TEXTAREA"===e.tagName||"SELECT"===e.tagName||N(e)}function N(e){return e?"false"===e.contentEditable?!1:"true"===e.contentEditable?!0:N(C(e)):!1}function X(e,r){return Array.prototype.indexOf.call(angular.element(r).children(),e)}function Y(e,r,n){e&&(t.extra=n,e.dispatchEvent?e.dispatchEvent(r):e.fireEvent("on"+r.eventType,r))}function I(e,r,n){return angular.isFunction(e)?!!e.apply(n||this,r||t):!!e}var O=document,T=O.documentElement;return o.cleanEnviroment=function(){t.classesCache={},t.containersCtx={},t.containers={},t.mirror=void 0},o.shared=t,o};n.$inject=["$rootScope","$compile"],e.exports=n}).call(r,function(){return this}())}]); +!function(e,r){if("object"==typeof exports&&"object"==typeof module)module.exports=r();else if("function"==typeof define&&define.amd)define([],r);else{var t=r();for(var n in t)("object"==typeof exports?exports:e)[n]=t[n]}}(this,function(){return function(e){function r(n){if(t[n])return t[n].exports;var o=t[n]={exports:{},id:n,loaded:!1};return e[n].call(o.exports,o,o.exports,r),o.loaded=!0,o.exports}var t={};return r.m=e,r.c=t,r.p="",r(0)}([function(e,r,t){"use strict";var n=t(1),o=t(2);e.exports="dragularModule",angular.module("dragularModule",[]).factory("dragularService",o).directive("dragular",n)},function(e,r){"use strict";var t=function(e){return{restrict:"A",link:function(r,t,n){function o(e){try{return JSON.parse(e)}catch(r){return}}var i,a=r.$eval(n.dragular)||o(n.dragular)||{};a&&a.containersModel&&"string"==typeof a.containersModel&&(a.containersModel=r.$eval(a.containersModel)),a&&a.dynamicModelAttribute?r.$watch(function(){return r.$eval(n.dragularModel)},function(e){e&&(i.containersModel=i.sanitizeContainersModel(r.$eval(e)))}):n.dragularModel&&(a.containersModel=r.$eval(n.dragularModel)),n.dragularNameSpace&&(a.nameSpace=n.dragularNameSpace.split(" ")),n.dragularOnInit&&(a.onInit=r.$eval(n.dragularOnInit)),i=e(t[0],a)}}};t.$inject=["dragularService"],e.exports=t},function(e,r){(function(r){"use strict";var t={classesCache:{},containersCtx:{},containers:{},mirror:null,source:null,item:null,copy:null,sourceItem:null,sourceModel:null,sourceFilteredModel:null,target:null,targetCtx:null,targetModel:null,lastDropTarget:null,offsetX:null,offsetY:null,moveX:null,moveY:null,offsetXr:null,offsetYb:null,clientX:null,clientY:null,mirrorWidth:null,mirrorHeight:null,initialSibling:null,currentSibling:null,initialIndex:null,currentIndex:null,tempModel:null,dragOverEvents:{},lastElementBehindCursor:null,grabbed:null},n=function(e,n){function o(r,o){function d(e){return"function"==typeof e?e:Array.isArray(e)?Array.isArray(e[0])?e:[e]:[]}function y(){1!==arguments.length||Array.isArray(r)||angular.isElement(r)||r[0]||"string"==typeof r?"string"==typeof r&&(ce=document.querySelectorAll(r)):(ue=r||{},ce=[]),le=ue.copyOptions?angular.copy(ue):ue}function b(){var e=angular.extend({},ge,le);angular.extend(le,e),le.classes&&(e=angular.extend({},de,le.classes),angular.extend(le.classes,e)),le.eventNames&&(e=angular.extend({},me,le.eventNames),angular.extend(le.eventNames,e))}function N(){h(le.boundingBox)||(le.boundingBox=!1),le.containers&&(ce=le.containers),ce=c(ce),le.containersModel=d(le.containersModel),Array.isArray(le.containersFilteredModel)?le.containersFilteredModel=Array.isArray(le.containersFilteredModel[0])?le.containersFilteredModel:[le.containersFilteredModel]:le.containersFilteredModel=[],le.nameSpace||(le.nameSpace=["dragularCommon"]),Array.isArray(le.nameSpace)||(le.nameSpace=[le.nameSpace]),le.nameSpace.forEach(function(e){t.containers[e]||(t.containers[e]=[],t.containersCtx[e]=[]);for(var r=ce.length,n=t.containers[e].length,o=0;r>o;o++)t.containers[e][o+n]=ce[o],t.containersCtx[e][o+n]={o:le,m:F()[o],fm:le.containersFilteredModel[o]}})}function A(e){var r=e?"off":"on";i(T,r,"mouseup",B),ce.forEach(function(e){i(e,"on","mousedown",$)}),e||angular.forEach(["dragularenter","dragularleave","dragularrelease"],function(e){var r=le.eventNames[e];t.dragOverEvents[r]||(O.createEvent?(t.dragOverEvents[r]=O.createEvent("HTMLEvents"),t.dragOverEvents[r].initEvent(r,!0,!0)):(t.dragOverEvents[r]=O.createEventObject(),t.dragOverEvents[r].eventType=r))})}function $(e){if(1===u(e)&&!e.metaKey&&!e.ctrlKey){t.moveX=e.clientX,t.moveY=e.clientY;var r=R(e.target);r&&r.item&&(t.grabbed=r,H(),"mousedown"===e.type&&(S(r.item)?r.item.focus():e.preventDefault()))}}function B(e){if(K(),fe.dragging){e.originalEvent&&(e=e.originalEvent),t.clientX=E("clientX",e),t.clientY=E("clientY",e);var r=ae(t.mirror,t.clientX,t.clientY),n=V(r,t.clientX,t.clientY);n&&(t.copy&&se(le.copySortSource)||!t.copy||n!==t.source)?U(t.item,n):se(le.removeOnSpill)?q():J(),t.target=null,t.lastElementBehindCursor&&X(t.lastElementBehindCursor,t.dragOverEvents.dragularrelease,r),le.scope&&le.scope.$emit(le.eventNames.dragularrelease,t.item,t.source)}}function w(e){if(!e)return!1;for(var r=le.nameSpace.length;r--;)if(-1!==t.containers[le.nameSpace[r]].indexOf(e))return!0;return le.isContainer(e)?(t.tempModel=le.isContainerModel(e),!0):(t.tempModel=null,!1)}function F(){return"function"==typeof le.containersModel?d(le.containersModel(fe,t)):le.containersModel}function D(r){e.$applyAsync(function(){var e=Array.isArray(r)?r:c(r);e.forEach(function(e){angular.forEach(le.nameSpace,function(r){var n;n=t.containers[r].indexOf(e),t.containers[r].splice(n,1),t.containersCtx[r].splice(n,1)})})})}function H(e){var r=e?"off":"on";i(T,r,"mousemove",k)}function j(e){var r=e?"off":"on";i(T,r,"selectstart",s),i(T,r,"click",s),i(T,r,"touchmove",s)}function P(){A(!0),D(ce),B({})}function k(e){if(t.grabbed&&!fe.dragging){if(e.originalEvent&&(e=e.originalEvent),0===u(e))return void B({});if(!e.clientX||e.clientX!==t.moveX||!e.clientY||e.clientY!==t.moveY){if(se(le.ignoreInputTextSelection)){var r=E("clientX",e),n=E("clientY",e),o=O.elementFromPoint(r,n);if(S(o))return}var i=t.grabbed;if(H("remove"),j(),z(),W(i),!le.direction&&C(t.sourceItem)){var a=t.sourceItem.parentNode,l=a.offsetHeight,c=a.offsetWidth,s=t.sourceItem.clientHeight,d=t.sourceItem.clientWidth;le.direction=c/d>l/s?"horizontal":"vertical"}var g=m(t.sourceItem);t.offsetX=E("pageX",e)-g.left,t.offsetY=E("pageY",e)-g.top,t.clientX=E("clientX",e),t.clientY=E("clientY",e),le.boundingBox&&(t.offsetXr=E("pageX",e)-g.right,t.offsetYb=E("pageY",e)-g.bottom),e.preventDefault(),x(t.item,le.classes.transit),te(),t.mirror.style.left=t.clientX-t.offsetX+"px",t.mirror.style.top=t.clientY-t.offsetY+"px",Z(e)}}}function R(e){if(!fe.dragging||!t.mirror){for(var r=e;C(e)&&!w(C(e));){if(le.invalid(e,r))return;if(e=C(e),!e)return}var n=C(e);if(n&&!le.invalid(e,r)&&le.moves(e,n,r,v(e)))return{item:e,source:n}}}function L(e){var r=R(e);r&&W(r)}function W(e){t.sourceItem=t.item=e.item,t.source=e.source,t.initialSibling=t.currentSibling=v(e.item),se(le.copy,[e.item,e.source])?(t.item=e.item.cloneNode(!0),t.copy=!0,le.scope&&le.scope.$emit(le.eventNames.dragularcloned,t.item,e.item)):t.copy=!1;var r=ce.indexOf(e.source);return t.sourceModel=F()[r],t.sourceFilteredModel=le.containersFilteredModel[r],t.initialIndex=I(e.item,e.source),fe.dragging=!0,le.scope&&le.scope.$emit(le.eventNames.dragulardrag,t.sourceItem,t.source),!0}function z(){fe.dragging&&t.item&&U(t.item,C(t.item))}function K(){t.grabbed=!1,H("remove"),j("remove")}function U(r,o){function i(){if(le.compileItemOnDrop){var e=angular.element(o).scope();e.$applyAsync(function(){var i=n(t.copy?a.cloneNode(!0):a)(e);r.parentNode===o&&o.removeChild(r),o.insertBefore(i[0],l)})}le.scope&&(Q(o)?le.scope.$emit(le.eventNames.dragularcancel,r,t.source,t.sourceModel,t.initialIndex):le.scope.$emit(le.eventNames.dragulardrop,r,o,t.source,t.sourceModel,t.initialIndex,t.targetModel,c)),G()}var a=t.sourceItem,l=t.currentSibling;if(t.copy&&se(le.copySortSource)&&o===t.source&&C(r)&&r.parentNode.removeChild(t.sourceItem),t.sourceModel&&!Q(o)){var c=I(r,o);t.targetCtx.fm&&(c=t.targetCtx.m.indexOf(t.targetCtx.fm[c])),t.sourceFilteredModel&&(t.initialIndex=t.sourceModel.indexOf(t.sourceFilteredModel[t.initialIndex])),e.$applyAsync(function(){t.sourceModel&&(o===t.source?t.sourceModel.splice(c,0,t.sourceModel.splice(t.initialIndex,1)[0]):(t.dropElmModel=t.copy&&!le.dontCopyModel?angular.copy(t.sourceModel[t.initialIndex]):t.sourceModel[t.initialIndex],t.tempModel?t.targetModel=t.tempModel:t.targetModel=t.targetCtx.m,o.removeChild(r),t.copy||t.sourceModel.splice(t.initialIndex,1),t.targetModel.splice(c,0,t.dropElmModel)),C(r)&&r.parentNode.removeChild(r),i())})}else i()}function q(){if(fe.dragging){var r=C(t.item);r&&r.removeChild(t.item),t.sourceModel&&e.$applyAsync(function(){t.sourceModel.splice(t.initialIndex,1),G()}),le.scope&&le.scope.$emit(t.copy?le.eventNames.dragularcancel:le.eventNames.dragularremove,t.item,r,t.sourceModel,t.initialIndex),t.sourceModel||G()}}function J(e){if(fe.dragging){var r=arguments.length>0?e:se(le.revertOnSpill),n=C(t.item),o=Q(n);o||t.copy||!r||t.source.insertBefore(t.item,t.initialSibling),!t.sourceModel||t.copy||r?le.scope&&(o||r)&&le.scope.$emit(le.eventNames.dragularcancel,t.item,t.source):U(t.item,n),(!t.sourceModel||t.copy||r||o)&&G()}}function G(){K(),ne(),t.item&&M(t.item,le.classes.transit),fe.dragging=!1,se(le.removeOnSpill)===!0&&ee(),le.scope&&(t.lastDropTarget&&le.scope.$emit(le.eventNames.dragularout,t.item,t.lastDropTarget,t.source),le.scope.$emit(le.eventNames.dragulardragend,t.item)),t.source=t.item=t.sourceItem=t.initialSibling=t.currentSibling=t.sourceModel=null,t.initialIndex=t.currentIndex=t.lastDropTarget=t.tempModel=t.targetModel=null,t.dropElmModel=t.targetCtx=t.copy=t.moveX=t.moveY=null}function Q(e,r){var n=r||(t.mirror?t.currentSibling:v(t.item));return e===t.source&&n===t.initialSibling}function V(e,r,n){function o(){var o=!1;if(w(i)){for(var a=oe(i,e),l=ie(i,a,r,n),c=Q(i,l),u=le.nameSpace.length;u--;){if(-1!==t.containers[le.nameSpace[u]].indexOf(i)){t.targetCtx=t.containersCtx[le.nameSpace[u]][t.containers[le.nameSpace[u]].indexOf(i)];break}t.targetCtx||(t.targetCtx=t.containersCtx.dragularCommon[t.containers.dragularCommon.indexOf(i)])}o=c||t.targetCtx.o.accepts(t.item,i,t.source,l,t.sourceModel,t.initialIndex)&&le.canBeAccepted(t.item,i,t.source,l,t.sourceModel,t.initialIndex),t.target!==i&&(t.target=i)}return o}for(var i=e;i&&!o();)i=C(i);return i}function Z(e){function r(e){le.scope&&le.scope.$emit(le.eventNames["dragular"+e],t.item,t.lastDropTarget,t.source),se(le.removeOnSpill)===!0&&("over"===e?_():ee())}if(t.mirror){e.originalEvent&&(e=e.originalEvent),t.clientX=E("clientX",e),t.clientY=E("clientY",e);var n,o,i,a=t.clientX-t.offsetX,l=t.clientY-t.offsetY;le.boundingBox&&(n=E("pageX",e),o=E("pageY",e),i=m(le.boundingBox)),le.lockY||(!le.boundingBox||n>i.left+t.offsetX&&ni.top+t.offsetY&&or;r++){if(o=e.children[r],i=o.getBoundingClientRect(),l&&i.left>t)return o;if(!l&&i.top>n)return o}return null}function i(){var e=r.getBoundingClientRect();return a(l?t>e.left+g(e)/2:n>e.top+f(e)/2)}function a(e){return e?v(r):r}var l="horizontal"===le.direction;return r!==e?i():o()}function ae(e,r,t){var n,o=e||{},i=o.className;return o.className+=" "+le.classes.hide,n=O.elementFromPoint(r,t),o.className=i,n}var le,ce=r||[],ue=o||{},se=Y,de={mirror:"gu-mirror",hide:"gu-hide",unselectable:"gu-unselectable",transit:"gu-transit"},me={dragularenter:"dragularenter",dragularleave:"dragularleave",dragularrelease:"dragularrelease",dragularcloned:"dragularcloned",dragulardrag:"dragulardrag",dragularcancel:"dragularcancel",dragulardrop:"dragulardrop",dragularremove:"dragularremove",dragulardragend:"dragulardragend",dragularshadow:"dragularshadow",dragularover:"dragularover",dragularout:"dragularout"},ge={copyOptions:!1,classes:de,eventNames:me,containers:!1,containersModel:!1,containersFilteredModel:!1,isContainer:a,isContainerModel:p,moves:l,accepts:l,canBeAccepted:l,copy:!1,copySortSource:!1,dontCopyModel:!1,invalid:a,revertOnSpill:!1,removeOnSpill:!1,lockX:!1,lockY:!1,boundingBox:!1,mirrorContainer:O.body,ignoreInputTextSelection:!0,compileItemOnDrop:!1,onInit:!1},fe={containers:t.containers,containersCtx:t.containersCtx,sanitizeContainersModel:d,isContainer:w,start:L,end:z,cancel:J,remove:q,destroy:P,dragging:!1};return y(),b(),N(),A(),le.onInit&&le.onInit(fe),fe}function i(e,t,n,o){var i={mouseup:"touchend",mousedown:"touchstart",mousemove:"touchmove"},a={mouseup:"pointerup",mousedown:"pointerdown",mousemove:"pointermove"},l={mouseup:"MSPointerUp",mousedown:"MSPointerDown",mousemove:"MSPointerMove"},c=angular.element(e);r.navigator.pointerEnabled&&a[n]?c[t](a[n],o):r.navigator.msPointerEnabled&&l[n]?c[t](l[n],o):i[n]&&c[t](i[n],o),c[t](n,o)}function a(){return!1}function l(){return!0}function c(e,r){return Array.isArray(e)?e:e.length?Array.prototype.slice.call(e,r):[e]}function u(e){if(e.touches)return e.touches.length;if(e.originalEvent&&e.originalEvent.touches)return e.originalEvent.touches.length;if(void 0!==e.buttons)return e.buttons;if(void 0!==e.which)return e.which;var r=e.button;return void 0!==r?1&r?1:2&r?3:4&r?2:0:void 0}function s(e){e.originalEvent&&(e=e.originalEvent),t.grabbed&&e.preventDefault()}function d(e,r){return"undefined"!=typeof window[r]?window[r]:T.clientHeight?T[e]:O.body[e]}function m(e){var r=e.getBoundingClientRect(),t=d("scrollTop","pageYOffset"),n=d("scrollLeft","pageXOffset");return{left:r.left+n,right:r.right+n,top:r.top+t,bottom:r.bottom+t}}function g(e){return e.width||e.right-e.left}function f(e){return e.height||e.bottom-e.top}function p(){return{}}function v(e){function r(){var r=e;do r=r.nextSibling;while(r&&1!==r.nodeType);return r}return e.nextElementSibling||r()}function h(e){return"object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&null!==e&&1===e.nodeType&&"string"==typeof e.nodeName}function y(e){var r=t.classesCache[e];return r?r.lastIndex=0:t.classesCache[e]=r=new RegExp("(?:^|\\s)"+e+"(?:\\s|$)","g"),r}function x(e,r){var t=e.className;t.length?y(r).test(t)||(e.className+=" "+r):e.className=r}function M(e,r){e.className=e.className.replace(y(r)," ").trim()}function b(e){return e.targetTouches&&e.targetTouches.length?e.targetTouches[0]:e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e}function E(e,r){var t=b(r),n={pageX:"clientX",pageY:"clientY"};return e in n&&!(e in t)&&n[e]in t&&(e=n[e]),!t.type||t.type.indexOf("touch")<0?t[e]:-1===t.type.indexOf("end")?t.originalEvent.touches[0][e.replace("client","page")]:!1}function C(e){return e.parentNode===document?null:e.parentNode}function S(e){return"INPUT"===e.tagName||"TEXTAREA"===e.tagName||"SELECT"===e.tagName||N(e)}function N(e){return e?"false"===e.contentEditable?!1:"true"===e.contentEditable?!0:N(C(e)):!1}function I(e,r){return Array.prototype.indexOf.call(angular.element(r).children(),e)}function X(e,r,n){e&&(t.extra=n,e.dispatchEvent?e.dispatchEvent(r):e.fireEvent("on"+r.eventType,r))}function Y(e,r,n){return angular.isFunction(e)?!!e.apply(n||this,r||t):!!e}var O=document,T=O.documentElement;return o.cleanEnviroment=function(){t.classesCache={},t.containersCtx={},t.containers={},t.mirror=void 0},o.shared=t,o};n.$inject=["$rootScope","$compile"],e.exports=n}).call(r,function(){return this}())}])}); //# sourceMappingURL=dragular.min.js.map diff --git a/dist/dragular.min.js.map b/dist/dragular.min.js.map index 0e207164..97ac4faa 100644 --- a/dist/dragular.min.js.map +++ b/dist/dragular.min.js.map @@ -1 +1 @@ -{"version":3,"sources":["dragular.js"],"names":["modules","__webpack_require__","moduleId","installedModules","exports","module","id","loaded","call","m","c","p","dragularDirective","dragularService","angular","factory","directive","dragular","restrict","link","$scope","iElm","iAttrs","tryJson","json","JSON","parse","e","drake","options","$eval","containersModel","dynamicModelAttribute","$watch","dragularModel","newVal","sanitizeContainersModel","dragularNameSpace","nameSpace","split","$inject","global","shared","classesCache","containersCtx","containers","mirror","source","item","copy","sourceItem","sourceModel","sourceFilteredModel","target","targetCtx","targetModel","lastDropTarget","offsetX","offsetY","moveX","moveY","offsetXr","offsetYb","clientX","clientY","mirrorWidth","mirrorHeight","initialSibling","currentSibling","initialIndex","currentIndex","tempModel","dragOverEvents","lastElementBehindCursor","grabbed","$rootScope","$compile","service","arg0","arg1","Array","isArray","processServiceArguments","arguments","length","isElement","initialContainers","document","querySelectorAll","o","copyOptions","extendOptions","tmp","extend","defaultOptions","classes","defaultClasses","eventNames","defaultEventNames","processOptionsObject","boundingBox","makeArray","containersFilteredModel","forEach","len","shLen","i","getContainersModel","fm","registerEvents","remove","op","regEvent","docElm","release","container","grab","name","eventName","doc","createEvent","initEvent","createEventObject","eventType","whichMouseButton","metaKey","ctrlKey","context","canStart","eventualMovements","type","isInput","focus","preventDefault","ungrab","dragging","originalEvent","getCoord","elementBehindCursor","getElementBehindPoint","dropTarget","findDropTarget","g","copySortSource","drop","removeOnSpill","cancel","fireEvent","dragularrelease","scope","$emit","isContainer","el","indexOf","isContainerModel","removeContainers","all","$applyAsync","changes","index","splice","startBecauseMouseMoved","movements","preventGrabbed","destroy","ignoreInputTextSelection","elementFromPoint","end","start","direction","getParent","parent","parentNode","parentHeight","offsetHeight","parentWidth","offsetWidth","childHeight","clientHeight","childWidth","clientWidth","offset","getOffset","left","top","right","bottom","addClass","transit","renderMirrorImage","style","drag","handle","invalid","moves","nextEl","manualStart","cloneNode","dragularcloned","containerIndex","domIndexOf","dragulardrag","afterDrop","compileItemOnDrop","element","content","removeChild","insertBefore","isInitialPlacement","dragularcancel","dragulardrop","dropIndex","cleanup","dropElmModel","dontCopyModel","dragularremove","revert","reverts","revertOnSpill","initial","removeMirrorImage","rmClass","spillOut","dragularout","dragulardragend","s","sibling","accepted","accepts","immediate","getImmediateChild","reference","getReference","dragularCommon","canBeAccepted","moved","spillOver","pageX","pageY","offsetBox","x","y","lockY","lockX","changed","dragularenter","dragularleave","dragularshadow","hide","scrollContainer","before","scrollTop","deltaY","stopPropagation","rect","getBoundingClientRect","width","height","getRectWidth","getRectHeight","mirrorContainer","appendChild","body","unselectable","outside","children","horizontal","inside","resolve","after","point","state","className","getBool","dragularover","never","getEmptyObject","always","fn","touch","mouseup","mousedown","mousemove","pointers","microsoft","$el","navigator","pointerEnabled","msPointerEnabled","startIndex","prototype","slice","touches","undefined","buttons","which","button","getScroll","scrollProp","offsetProp","window","scrollLeft","manually","nextSibling","nodeType","nextElementSibling","obj","HTMLElement","nodeName","lookupClass","cached","lastIndex","RegExp","current","test","replace","trim","getEventHost","targetTouches","changedTouches","coord","host","missMap","tagName","isEditable","contentEditable","child","extra","dispatchEvent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,EAAEgG,UAAWhG,IAIzC,QAASsP,GAAQwD,EAAMC,EAAM3M,GAC3B,MAAGjH,SAAQ6T,WAAWF,KACXA,EAAKG,MAAM7M,GAAW8M,KAAMH,GAAQhS,KAEpC+R,EAnmCb,GAAIlN,GAAMhC,SACN0B,EAASM,EAAIuN,eAYjB,OATAjQ,GAAQkQ,gBAAkB,WACxBrS,EAAOC,gBACPD,EAAOE,iBACPF,EAAOG,cACPH,EAAOI,OAASuP,QAGlBxN,EAAQnC,OAASA,EAEVmC,EA4lCThE,GAAgB2B,SAAW,aAAc,YAEzCnC,EAAOD,QAAUS,IAEYL,KAAKJ,EAAU,WAAa,MAAOyU","file":"dragular.min.js","sourcesContent":["/******/ (function(modules) { // webpackBootstrap\n/******/ \t// The module cache\n/******/ \tvar installedModules = {};\n\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId])\n/******/ \t\t\treturn installedModules[moduleId].exports;\n\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\texports: {},\n/******/ \t\t\tid: moduleId,\n/******/ \t\t\tloaded: false\n/******/ \t\t};\n\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.loaded = true;\n\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n\n\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(0);\n/******/ })\n/************************************************************************/\n/******/ ([\n/* 0 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t/* global angular */\n\t'use strict';\n\tvar dragularDirective = __webpack_require__(1);\n\tvar dragularService = __webpack_require__(2);\n\n\t/**\n\t * Dragular 4.1.0 by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\tmodule.exports = 'dragularModule';\n\n\tangular\n\t .module('dragularModule', [])\n\t .factory('dragularService', dragularService)\n\t .directive('dragular', dragularDirective);\n\n\n/***/ },\n/* 1 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\t/**\n\t * dragular Directive by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\n\tvar dragular = function (dragularService) {\n\t return {\n\t restrict: 'A',\n\t link: function($scope, iElm, iAttrs) {\n\n\t var drake,\n\t options = $scope.$eval(iAttrs.dragular) || tryJson(iAttrs.dragular) || {};\n\n\t function tryJson(json) {\n\t try { // I dont like try catch solutions but I havent find sattisfying way of chcecking json validity.\n\t return JSON.parse(json);\n\t } catch (e) {\n\t return undefined;\n\t }\n\t }\n\n\t if(options && options.containersModel && typeof options.containersModel === 'string'){\n\t options.containersModel = $scope.$eval(options.containersModel);\n\t }\n\n\t if(options && options.dynamicModelAttribute){\n\t // watch for model changes\n\t $scope.$watch(function () {\n\t return $scope.$eval(iAttrs.dragularModel);\n\t }, function (newVal) {\n\t if(newVal){\n\t drake.containersModel = drake.sanitizeContainersModel($scope.$eval(newVal));\n\t }\n\t });\n\t }else if(iAttrs.dragularModel){\n\t // bind once and keep reference\n\t options.containersModel = $scope.$eval(iAttrs.dragularModel);\n\t }\n\n\t if(iAttrs.dragularNameSpace){\n\t options.nameSpace = iAttrs.dragularNameSpace.split(' ');\n\t }\n\n\t drake = dragularService(iElm[0], options);\n\t }\n\t };\n\t};\n\n\tdragular.$inject = ['dragularService'];\n\n\tmodule.exports = dragular;\n\n\n/***/ },\n/* 2 */\n/***/ function(module, exports) {\n\n\t/* WEBPACK VAR INJECTION */(function(global) {/* global angular */\n\t'use strict';\n\n\t/**\n\t * dragular Service by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\n\tvar shared = { // sahred object between all service instances\n\t classesCache: {}, // classes lookup cache\n\t containersCtx: {}, // containers model\n\t containers: {}, // containers\n\t mirror: null, // mirror image\n\t source: null, // source container\n\t item: null, // item being dragged\n\t copy: null, // copy flag\n\t sourceItem: null, // item originaly dragged if copy is enabled\n\t sourceModel: null, // source container model\n\t sourceFilteredModel: null, // source container filtered model if relevant\n\t target: null, // droppable container under drag item\n\t targetCtx: null, // target container context\n\t targetModel: null, // target container model\n\t lastDropTarget: null, // last container item was over\n\t offsetX: null, // reference x\n\t offsetY: null, // reference y\n\t moveX: null, // reference move x\n\t moveY: null, // reference move y\n\t offsetXr: null, // reference x right for boundingBox feature\n\t offsetYb: null, // reference y bottom for boundingBox feature\n\t clientX: null, // cache client x, init at grab, update at drag\n\t clientY: null, // cache client y, init at grab, update at drag\n\t mirrorWidth: null, // mirror width for boundingBox feature\n\t mirrorHeight: null, // mirror height for boundingBox feature\n\t initialSibling: null, // reference sibling when grabbed\n\t currentSibling: null, // reference sibling now\n\t initialIndex: null, // reference model index when grabbed\n\t currentIndex: null, // reference model index now\n\t tempModel: null, // if o.isContainer is used, model can be provided as well, it is temporary saved here during drags\n\t dragOverEvents: {}, // drag over events fired on element behind cursor\n\t lastElementBehindCursor: null, // last element behind cursor\n\t grabbed: null // holds mousedown context until first mousemove\n\t};\n\n\tvar dragularService = function ($rootScope, $compile) {\n\t // abbreviations\n\t var doc = document,\n\t docElm = doc.documentElement;\n\n\t // clean common/shared objects\n\t service.cleanEnviroment = function cleanEnviroment() {\n\t shared.classesCache = {};\n\t shared.containersCtx = {};\n\t shared.containers = {};\n\t shared.mirror = undefined;\n\t };\n\n\t service.shared = shared;\n\n\t return service;\n\n\t // service definition\n\t function service(arg0, arg1) {\n\t var initialContainers = arg0 || [],\n\t options = arg1 || {},\n\t o, // shorthand for options\n\t g = getBool, // shorthand for getBool\n\t // defaults\n\t defaultClasses = {\n\t mirror: 'gu-mirror',\n\t hide: 'gu-hide',\n\t unselectable: 'gu-unselectable',\n\t transit: 'gu-transit'\n\t },\n\t defaultEventNames = {\n\t // drag-over DOM events\n\t dragularenter: 'dragularenter',\n\t dragularleave: 'dragularleave',\n\t dragularrelease: 'dragularrelease',\n\t // $scope events\n\t dragularcloned: 'dragularcloned',\n\t dragulardrag: 'dragulardrag',\n\t dragularcancel: 'dragularcancel',\n\t dragulardrop: 'dragulardrop',\n\t dragularremove: 'dragularremove',\n\t dragulardragend: 'dragulardragend',\n\t dragularshadow: 'dragularshadow',\n\t dragularover: 'dragularover',\n\t dragularout: 'dragularout'\n\t },\n\t defaultOptions = { // options with defaults\n\t copyOptions: false, // copy options object when provided\n\t classes: defaultClasses, // classes used by dragular\n\t eventNames: defaultEventNames, // event names used by dragular\n\t containers: false, // initial containers provided via options object (are provided via parameter by default)\n\t containersModel: false, // if provided, model will be synced with DOM\n\t containersFilteredModel: false, // if provided, dragular will handle filtered model cases\n\t isContainer: never, // potential target can be forced to be container by custom logic\n\t isContainerModel: getEmptyObject, // if isContainer function is provided, you can provide also respective model\n\t moves: always, // can drag start?\n\t accepts: always, // can target accept dragged item? (target context used)\n\t canBeAccepted: always, // can be dragged item accepted by target? (source context used)\n\t copy: false, // dragged item will be copy of source? flag or function\n\t copySortSource: false, // enable sorting in source when copying item\n\t dontCopyModel: false, // dont make copy of model when coping item (#61)\n\t invalid: never, // target (in)validity function\n\t revertOnSpill: false, // item returns to original place\n\t removeOnSpill: false, // item will be removed if not placed into valid target\n\t lockX: false, // lock movement into x-axis\n\t lockY: false, // lock movement into y-axis\n\t boundingBox: false, // lock movement inside this element boundaries\n\t mirrorContainer: doc.body, // element for appending mirror\n\t ignoreInputTextSelection: true, // text selection in inputs wont be considered as drag\n\t compileItemOnDrop: false\n\t },\n\t drake = {\n\t containers: shared.containers,\n\t containersCtx: shared.containersCtx,\n\t sanitizeContainersModel: sanitizeContainersModel,\n\t isContainer: isContainer,\n\t start: manualStart,\n\t end: end,\n\t cancel: cancel,\n\t remove: remove,\n\t destroy: destroy,\n\t dragging: false\n\t };\n\n\t processServiceArguments(); // both arguments (containers and options) are optional, this function handle this\n\t extendOptions();\n\t processOptionsObject();\n\t registerEvents();\n\n\t return drake;\n\n\t // Function definitions: ==============================================================================================================\n\t // Initial functions: -----------------------------------------------------------------------------------------------------------------\n\n\t function sanitizeContainersModel(containersModel) {\n\t if (typeof(containersModel) === 'function') {\n\t return containersModel;\n\t }\n\t if (Array.isArray(containersModel)) {\n\t // |-------- is 2D array? -----------|\n\t return Array.isArray(containersModel[0]) ? containersModel : [containersModel];\n\t } else {\n\t return [];\n\t }\n\t }\n\n\t function processServiceArguments(){\n\t if (arguments.length === 1 && // if there is only one argument we need to distinguish if it is options object or container(s) reference\n\t !Array.isArray(arg0) && // array of containers elements\n\t !angular.isElement(arg0) && // one container element\n\t !arg0[0] && // array-like object with containers elements\n\t typeof arg0 !== 'string') { // selector\n\t // then arg0 is options object\n\t options = arg0 || {};\n\t initialContainers = []; // containers are not provided on init\n\t } else if (typeof arg0 === 'string') {\n\t initialContainers = document.querySelectorAll(arg0);\n\t }\n\t o = options.copyOptions ? angular.copy(options) : options;\n\t }\n\n\t function extendOptions(){\n\t var tmp = angular.extend({}, defaultOptions, o); // tmp for keeping defaults untouched\n\t angular.extend(o, tmp); // merge defaults back into options\n\t if(o.classes){\n\t tmp = angular.extend({}, defaultClasses, o.classes);\n\t angular.extend(o.classes, tmp);\n\t }\n\t if(o.eventNames){\n\t tmp = angular.extend({}, defaultEventNames, o.eventNames);\n\t angular.extend(o.eventNames, tmp);\n\t }\n\t }\n\n\t function processOptionsObject(){\n\t // bounding box must be pure DOM element, not jQuery wrapper or something else..\n\t if (!isElement(o.boundingBox)) {\n\t o.boundingBox = false;\n\t }\n\n\t // initial containers provided via options are higher priority then by parameter\n\t if(o.containers){\n\t initialContainers = o.containers;\n\t }\n\t // sanitize initialContainers\n\t initialContainers = makeArray(initialContainers);\n\n\t // sanitize o.containersModel\n\t o.containersModel = sanitizeContainersModel(o.containersModel);\n\n\t // sanitize o.containersFilteredModel\n\t if (Array.isArray(o.containersFilteredModel)) {\n\t // |-------- is 2D array? -----------|\n\t o.containersFilteredModel = Array.isArray(o.containersFilteredModel[0]) ? o.containersFilteredModel : [o.containersFilteredModel];\n\t } else {\n\t o.containersFilteredModel = [];\n\t }\n\n\t // feed containers groups and optionaly do same for models\n\t if (!o.nameSpace) {\n\t o.nameSpace = ['dragularCommon'];\n\t }\n\t if (!Array.isArray(o.nameSpace)) {\n\t o.nameSpace = [o.nameSpace];\n\t }\n\t o.nameSpace.forEach(function eachNameSpace(nameSpace) {\n\t if (!shared.containers[nameSpace]) {\n\t shared.containers[nameSpace] = [];\n\t shared.containersCtx[nameSpace] = [];\n\t }\n\t var len = initialContainers.length,\n\t shLen = shared.containers[nameSpace].length;\n\t for (var i = 0; i < len; i++) {\n\t shared.containers[nameSpace][i + shLen] = initialContainers[i];\n\t shared.containersCtx[nameSpace][i + shLen] = {\n\t o: o,\n\t m: getContainersModel()[i], // can be undefined\n\t fm: o.containersFilteredModel[i] // can be undefined\n\t };\n\t }\n\t });\n\t }\n\n\t function registerEvents(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'mouseup', release);\n\n\t initialContainers.forEach(function addMouseDown(container) {\n\t regEvent(container, 'on', 'mousedown', grab);\n\t });\n\n\t if(!remove){ // create dragular DOM events\n\t angular.forEach(['dragularenter', 'dragularleave', 'dragularrelease'], function prepareDragOverEvents(name) {\n\t var eventName = o.eventNames[name];\n\t if(!shared.dragOverEvents[eventName]){\n\t if (doc.createEvent) {\n\t shared.dragOverEvents[eventName] = doc.createEvent('HTMLEvents');\n\t shared.dragOverEvents[eventName].initEvent(eventName, true, true);\n\t } else {\n\t shared.dragOverEvents[eventName] = doc.createEventObject();\n\t shared.dragOverEvents[eventName].eventType = eventName;\n\t }\n\t }\n\t });\n\t }\n\t }\n\n\t // Event handlers functions (end of initial functions): -----------------------------------------------------------------------------------------------------------------\n\n\t function grab(e) {\n\t // filter some odd situations\n\t if (whichMouseButton(e) !== 1 || e.metaKey || e.ctrlKey) {\n\t return; // we only care about honest-to-god left clicks and touch events\n\t }\n\n\t // set itial values\n\t shared.moveX = e.clientX;\n\t shared.moveY = e.clientY;\n\n\t var context = canStart(e.target);\n\t if (!context || !context.item) {\n\t return;\n\t }\n\n\t shared.grabbed = context;\n\t eventualMovements();\n\t if (e.type === 'mousedown') {\n\t if (isInput(context.item)) { // see also: https://github.com/bevacqua/dragula/issues/208\n\t context.item.focus(); // fixes https://github.com/bevacqua/dragula/issues/176\n\t } else {\n\t e.preventDefault(); // fixes https://github.com/bevacqua/dragula/issues/155\n\t }\n\t }\n\t }\n\n\t function release(e) {\n\t ungrab();\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t var elementBehindCursor = getElementBehindPoint(shared.mirror, shared.clientX, shared.clientY),\n\t dropTarget = findDropTarget(elementBehindCursor, shared.clientX, shared.clientY);\n\n\t if (dropTarget && ((shared.copy && g(o.copySortSource)) || (!shared.copy || dropTarget !== shared.source))) {\n\t // found valid target and (is not copy case or target is not initial container)\n\t drop(shared.item, dropTarget);\n\t } else if (g(o.removeOnSpill)) {\n\t remove();\n\t } else {\n\t cancel();\n\t }\n\n\t // after release there is no container hovered\n\t shared.target = null;\n\n\t if (shared.lastElementBehindCursor) {\n\t fireEvent(shared.lastElementBehindCursor, shared.dragOverEvents.dragularrelease, elementBehindCursor);\n\t }\n\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularrelease, shared.item, shared.source);\n\t }\n\t }\n\n\t // Main logic functions (end of event handler functions): -----------------------------------------------------------------------------------------------------------------\n\n\t function isContainer(el) {\n\t if(!el){\n\t return false;\n\t }\n\t var i = o.nameSpace.length;\n\t while (i--) {\n\t if (shared.containers[o.nameSpace[i]].indexOf(el) !== -1) {\n\t return true;\n\t }\n\t }\n\t if (o.isContainer(el)) {\n\t shared.tempModel = o.isContainerModel(el);\n\t return true;\n\t } else {\n\t shared.tempModel = null;\n\t }\n\t return false;\n\t }\n\n\t function getContainersModel() {\n\t return (typeof(o.containersModel) === 'function') ? sanitizeContainersModel(o.containersModel(drake, shared)) : o.containersModel;\n\t }\n\n\t function removeContainers(all) {\n\t $rootScope.$applyAsync(function applyDestroyed() {\n\t var changes = Array.isArray(all) ? all : makeArray(all);\n\t changes.forEach(function forEachContainer(container) {\n\t angular.forEach(o.nameSpace, function forEachNs(nameSpace) {\n\t var index;\n\t index = shared.containers[nameSpace].indexOf(container);\n\t shared.containers[nameSpace].splice(index, 1);\n\t shared.containersCtx[nameSpace].splice(index, 1);\n\t });\n\t });\n\t });\n\t }\n\n\t function eventualMovements(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'mousemove', startBecauseMouseMoved);\n\t }\n\n\t function movements(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'selectstart', preventGrabbed); // IE8\n\t regEvent(docElm, op, 'click', preventGrabbed);\n\t regEvent(docElm, op, 'touchmove', preventGrabbed); // fixes touch devices scrolling while drag\n\t }\n\n\t function destroy() {\n\t registerEvents(true);\n\t removeContainers(initialContainers);\n\t release({});\n\t }\n\n\t function startBecauseMouseMoved(e) {\n\t if (!shared.grabbed || drake.dragging) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t if (whichMouseButton(e) === 0) {\n\t release({});\n\t return; // when text is selected on an input and then dragged, mouseup doesn't fire. this is our only hope\n\t }\n\t // truthy check fixes dragula-#239, equality fixes dragula-#207\n\t if (e.clientX && e.clientX === shared.moveX && e.clientY && e.clientY === shared.moveY) {\n\t return;\n\t }\n\t if (g(o.ignoreInputTextSelection)) {\n\t var clientX = getCoord('clientX', e),\n\t clientY = getCoord('clientY', e),\n\t elementBehindCursor = doc.elementFromPoint(clientX, clientY);\n\t if (isInput(elementBehindCursor)) {\n\t return;\n\t }\n\t }\n\n\t var grabbed = shared.grabbed; // calling end() unsets shared.grabbed\n\t eventualMovements('remove'); // remove mousemove listener\n\t movements();\n\t end();\n\t start(grabbed);\n\n\t // automaticly detect direction of elements if not set in options\n\t if (!o.direction && getParent(shared.sourceItem)) {\n\t var parent = shared.sourceItem.parentNode,\n\t parentHeight = parent.offsetHeight,\n\t parentWidth = parent.offsetWidth,\n\t childHeight = shared.sourceItem.clientHeight,\n\t childWidth = shared.sourceItem.clientWidth;\n\t o.direction = parentHeight / childHeight < parentWidth / childWidth ? 'horizontal' : 'vertical';\n\t }\n\n\t // get initial coordinates, used to render shared.mirror for first time\n\t var offset = getOffset(shared.sourceItem);\n\t shared.offsetX = getCoord('pageX', e) - offset.left;\n\t shared.offsetY = getCoord('pageY', e) - offset.top;\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t // limiting area of shared.mirror movement, get initial coordinates\n\t if (o.boundingBox) {\n\t shared.offsetXr = getCoord('pageX', e) - offset.right;\n\t shared.offsetYb = getCoord('pageY', e) - offset.bottom;\n\t }\n\n\t e.preventDefault();\n\n\t addClass(shared.item, o.classes.transit);\n\t renderMirrorImage();\n\t // initial position\n\t shared.mirror.style.left = shared.clientX - shared.offsetX + 'px';\n\t shared.mirror.style.top = shared.clientY - shared.offsetY + 'px';\n\n\t drag(e);\n\t }\n\n\t function canStart(item) {\n\t if (drake.dragging && shared.mirror) {\n\t console.log('usecase?');\n\t return; // already dragging\n\t }\n\n\t var handle = item;\n\t while (getParent(item) && !isContainer(getParent(item))) {\n\t // break loop if user tries to drag item which is considered invalid handle\n\t if (o.invalid(item, handle)) {\n\t return;\n\t }\n\t item = getParent(item); // drag target should be immediate child of container\n\t if (!item) {\n\t return;\n\t }\n\t }\n\n\t var source = getParent(item);\n\t if (!source ||\n\t o.invalid(item, handle) ||\n\t !o.moves(item, source, handle, nextEl(item))) {\n\t return;\n\t }\n\n\t return {\n\t item: item,\n\t source: source\n\t };\n\t }\n\n\t function manualStart(item) {\n\t var context = canStart(item);\n\t if (context) {\n\t start(context);\n\t }\n\t }\n\n\t function start(context) {\n\t shared.sourceItem = shared.item = context.item;\n\t shared.source = context.source;\n\t shared.initialSibling = shared.currentSibling = nextEl(context.item);\n\n\t if (g(o.copy, [context.item, context.source])) {\n\t shared.item = context.item.cloneNode(true);\n\t shared.copy = true;\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularcloned, shared.item, context.item);\n\t }\n\t } else {\n\t shared.copy = false;\n\t }\n\n\t // prepare models operations\n\t var containerIndex = initialContainers.indexOf(context.source);\n\t shared.sourceModel = getContainersModel()[containerIndex];\n\n\t shared.sourceFilteredModel = o.containersFilteredModel[containerIndex];\n\t shared.initialIndex = domIndexOf(context.item, context.source);\n\n\t drake.dragging = true;\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragulardrag, shared.sourceItem, shared.source);\n\t }\n\n\t return true;\n\t }\n\n\t function end() {\n\t if (!drake.dragging || !shared.item) {\n\t return;\n\t }\n\t drop(shared.item, getParent(shared.item));\n\t }\n\n\t function ungrab() {\n\t shared.grabbed = false;\n\t eventualMovements('remove');\n\t movements('remove');\n\t }\n\n\t function drop(item, target) {\n\t var sourceItem = shared.sourceItem,\n\t currentSibling = shared.currentSibling;\n\t \n\t if (shared.copy && g(o.copySortSource) && target === shared.source && getParent(item)) {\n\t item.parentNode.removeChild(shared.sourceItem);\n\t }\n\n\t if (shared.sourceModel && !isInitialPlacement(target)) {\n\n\t var dropIndex = domIndexOf(item, target);\n\t if(shared.targetCtx.fm){ // target has filtered model\n\t // convert index from index-in-filteredModel to index-in-model\n\t dropIndex = shared.targetCtx.m.indexOf(shared.targetCtx.fm[dropIndex]);\n\t }\n\t if(shared.sourceFilteredModel){ // target has filtered model\n\t // convert index from index-in-filteredModel to index-in-model\n\t shared.initialIndex = shared.sourceModel.indexOf(shared.sourceFilteredModel[shared.initialIndex]);\n\t }\n\t $rootScope.$applyAsync(function applyDrop() {\n\t if(!shared.sourceModel){\n\t return;\n\t }\n\t if (target === shared.source) {\n\t shared.sourceModel.splice(dropIndex, 0, shared.sourceModel.splice(shared.initialIndex, 1)[0]);\n\t } else {\n\t shared.dropElmModel = shared.copy && !o.dontCopyModel ? angular.copy(shared.sourceModel[shared.initialIndex]) : shared.sourceModel[shared.initialIndex];\n\n\t if (!shared.tempModel) {\n\t shared.targetModel = shared.targetCtx.m;\n\t } else {\n\t shared.targetModel = shared.tempModel;\n\t }\n\t \n\t target.removeChild(item); // element must be removed for ngRepeat to apply correctly\n\n\t if (!shared.copy) {\n\t shared.sourceModel.splice(shared.initialIndex, 1);\n\t }\n\t shared.targetModel.splice(dropIndex, 0, shared.dropElmModel);\n\t }\n\n\t if (getParent(item)) {\n\t item.parentNode.removeChild(item);\n\t }\n\n\t afterDrop();\n\t });\n\t } else {\n\t afterDrop();\n\t }\n\n\t function afterDrop() {\n\t if(o.compileItemOnDrop){\n\t var scope = angular.element(target).scope();\n\t scope.$applyAsync(function(){\n\t var content = $compile(shared.copy ? sourceItem.cloneNode(true) : sourceItem)(scope); \n\t if(item.parentNode === target){\n\t target.removeChild(item);\n\t }\n\t target.insertBefore(content[0], currentSibling);\n\t });\n\t }\n\t \n\t if (o.scope) {\n\t if (isInitialPlacement(target)) {\n\t o.scope.$emit(o.eventNames.dragularcancel, item, shared.source, shared.sourceModel, shared.initialIndex);\n\t } else {\n\t o.scope.$emit(o.eventNames.dragulardrop, item, target, shared.source, shared.sourceModel, shared.initialIndex, shared.targetModel, dropIndex);\n\t }\n\t }\n\t \n\t cleanup();\n\t }\n\t }\n\n\t function remove() {\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t var parent = getParent(shared.item);\n\n\t if (parent) {\n\t parent.removeChild(shared.item);\n\t }\n\n\t if (shared.sourceModel) {\n\t $rootScope.$applyAsync(function removeModel() {\n\t shared.sourceModel.splice(shared.initialIndex, 1);\n\t cleanup();\n\t });\n\t }\n\n\t if (o.scope) {\n\t o.scope.$emit(shared.copy ? o.eventNames.dragularcancel : o.eventNames.dragularremove, shared.item, parent, shared.sourceModel, shared.initialIndex);\n\t }\n\t if (!shared.sourceModel) {\n\t cleanup();\n\t }\n\t }\n\n\t function cancel(revert) {\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t var reverts = arguments.length > 0 ? revert : g(o.revertOnSpill),\n\t parent = getParent(shared.item);\n\n\t var initial = isInitialPlacement(parent);\n\t if (!initial && !shared.copy && reverts) {\n\t shared.source.insertBefore(shared.item, shared.initialSibling);\n\t }\n\t if (shared.sourceModel && !shared.copy && !reverts) {\n\t drop(shared.item, parent);\n\t } else if (o.scope) {\n\t if (initial || reverts) {\n\t o.scope.$emit(o.eventNames.dragularcancel, shared.item, shared.source);\n\t }\n\t }\n\n\t if (!shared.sourceModel || shared.copy || reverts || initial) {\n\t cleanup();\n\t }\n\t }\n\n\t function cleanup() {\n\t ungrab();\n\t removeMirrorImage();\n\n\t if (shared.item) {\n\t rmClass(shared.item, o.classes.transit);\n\t }\n\n\t drake.dragging = false;\n\n\t if (g(o.removeOnSpill) === true) {\n\t spillOut();\n\t }\n\n\t if (o.scope) {\n\t if(shared.lastDropTarget){\n\t o.scope.$emit(o.eventNames.dragularout, shared.item, shared.lastDropTarget, shared.source);\n\t }\n\t o.scope.$emit(o.eventNames.dragulardragend, shared.item);\n\t }\n\n\t shared.source = shared.item = shared.sourceItem = shared.initialSibling = shared.currentSibling = shared.sourceModel = null;\n\t shared.initialIndex = shared.currentIndex = shared.lastDropTarget = shared.tempModel = shared.targetModel = null;\n\t shared.dropElmModel = shared.targetCtx = shared.copy = shared.moveX = shared.moveY = null;\n\t }\n\n\t // is item currently placed in original container and original position?\n\t function isInitialPlacement(target, s) { // watch performance - running each move several times!\n\t var sibling = s || (shared.mirror ? shared.currentSibling : nextEl(shared.item));\n\t return target === shared.source && sibling === shared.initialSibling;\n\t }\n\n\t // find valid drop container\n\t function findDropTarget(elementBehindCursor, clientX, clientY) { // watch performance - running each move!\n\t var target = elementBehindCursor;\n\n\t while (target && !accepted()) {\n\t target = getParent(target);\n\t }\n\t return target;\n\n\t function accepted() {\n\t var accepts = false;\n\n\t if (isContainer(target)) { // is droppable?\n\n\t var immediate = getImmediateChild(target, elementBehindCursor),\n\t reference = getReference(target, immediate, clientX, clientY),\n\t initial = isInitialPlacement(target, reference),\n\t i = o.nameSpace.length;\n\n\t while (i--) {\n\t if (shared.containers[o.nameSpace[i]].indexOf(target) !== -1) {\n\t shared.targetCtx = shared.containersCtx[o.nameSpace[i]][shared.containers[o.nameSpace[i]].indexOf(target)];\n\t break;\n\t }\n\t if (!shared.targetCtx) {\n\t shared.targetCtx = shared.containersCtx.dragularCommon[shared.containers.dragularCommon.indexOf(target)];\n\t }\n\t }\n\n\t accepts = initial ||\n\t (shared.targetCtx.o.accepts(shared.item, target, shared.source, reference, shared.sourceModel, shared.initialIndex) &&\n\t o.canBeAccepted(shared.item, target, shared.source, reference, shared.sourceModel, shared.initialIndex));\n\n\t if (shared.target !== target) { // used for scroll issue\n\t shared.target = target;\n\t }\n\t }\n\t return accepts;\n\t }\n\t }\n\n\t function drag(e) { // watch performance - running each move!\n\t if (!shared.mirror) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\n\t // update coordinates\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t // count mirror coordiates\n\t var x = shared.clientX - shared.offsetX,\n\t y = shared.clientY - shared.offsetY,\n\t pageX,\n\t pageY,\n\t offsetBox;\n\n\t // fill extra properties if boundingBox is used\n\t if (o.boundingBox) {\n\t pageX = getCoord('pageX', e);\n\t pageY = getCoord('pageY', e);\n\t offsetBox = getOffset(o.boundingBox);\n\t }\n\n\t if (!o.lockY) {\n\t if (!o.boundingBox || (pageX > offsetBox.left + shared.offsetX && pageX < offsetBox.right + shared.offsetXr)) {\n\t shared.mirror.style.left = x + 'px';\n\t } else if (o.boundingBox) { // check again in case user scrolled the view\n\t if (pageX < offsetBox.left + shared.offsetX) {\n\t shared.mirror.style.left = shared.clientX - (pageX - offsetBox.left) + 'px';\n\t } else {\n\t shared.mirror.style.left = shared.clientX - shared.mirrorWidth - (pageX - offsetBox.right) + 'px';\n\t }\n\t }\n\t }\n\t if (!o.lockX) {\n\t if (!o.boundingBox || (pageY > offsetBox.top + shared.offsetY && pageY < offsetBox.bottom + shared.offsetYb)) {\n\t shared.mirror.style.top = y + 'px';\n\t } else if (o.boundingBox) { // check again in case user scrolled the view\n\t if (pageY < offsetBox.top + shared.offsetY) {\n\t shared.mirror.style.top = shared.clientY - (pageY - offsetBox.top) + 'px';\n\t } else {\n\t shared.mirror.style.top = shared.clientY - shared.mirrorHeight - (pageY - offsetBox.bottom) + 'px';\n\t }\n\t }\n\t }\n\n\t var elementBehindCursor = getElementBehindPoint(shared.mirror, shared.clientX, shared.clientY),\n\t dropTarget = findDropTarget(elementBehindCursor, shared.clientX, shared.clientY),\n\t changed = dropTarget !== shared.lastDropTarget;\n\n\t if (elementBehindCursor !== shared.lastElementBehindCursor) {\n\t fireEvent(elementBehindCursor, shared.dragOverEvents.dragularenter, !!dropTarget);\n\t if (shared.lastElementBehindCursor) {\n\t fireEvent(shared.lastElementBehindCursor, shared.dragOverEvents.dragularleave, elementBehindCursor);\n\t }\n\t shared.lastElementBehindCursor = elementBehindCursor;\n\t }\n\n\t if (changed) {\n\t if (shared.lastDropTarget) {\n\t moved('out');\n\t }\n\t shared.lastDropTarget = dropTarget;\n\t moved('over');\n\t }\n\n\t // do not copy in same container\n\t if (dropTarget === shared.source && shared.copy && !g(o.copySortSource)) {\n\t if (getParent(shared.item)) {\n\t shared.item.parentNode.removeChild(shared.item);\n\t }\n\t return;\n\t }\n\n\t var reference,\n\t immediate = getImmediateChild(dropTarget, elementBehindCursor);\n\n\t if (immediate !== null) {\n\t reference = getReference(dropTarget, immediate, shared.clientX, shared.clientY);\n\t } else if (g(o.revertOnSpill) === true && !shared.copy) {\n\t // the case that mirror is not over valid target and reverting is on and copy is off\n\t reference = shared.initialSibling;\n\t dropTarget = shared.source;\n\t } else {\n\t // the case that mirror is not over valid target and removing is on or copy is on\n\t if (shared.copy && getParent(shared.item)) {\n\t // remove item or copy of item\n\t shared.item.parentNode.removeChild(shared.item);\n\t }\n\t return;\n\t }\n\n\t if (reference === null ||\n\t reference !== shared.item &&\n\t reference !== nextEl(shared.item) &&\n\t reference !== shared.currentSibling) {\n\t // moving item/copy to new container from previous one\n\t shared.currentSibling = reference;\n\n\t dropTarget.insertBefore(shared.item, reference); // if reference is null item is inserted at the end\n\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularshadow, shared.item, dropTarget);\n\t }\n\t }\n\n\t function moved(type) {\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames['dragular' + type], shared.item, shared.lastDropTarget, shared.source);\n\t }\n\t if (g(o.removeOnSpill) === true) {\n\t type === 'over' ? spillOver() : spillOut();\n\t }\n\t }\n\t }\n\n\t function spillOver() {\n\t rmClass(shared.item, o.classes.hide);\n\t }\n\n\t function spillOut() {\n\t if (drake.dragging) {\n\t addClass(shared.item, o.classes.hide);\n\t }\n\t }\n\n\t function scrollContainer(e) {\n\t if (shared.target) {\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t var before = shared.target.scrollTop;\n\t shared.target.scrollTop += e.deltaY;\n\t // block scroll of the document when container can be scrolled\n\t if (before !== shared.target.scrollTop) {\n\t e.stopPropagation();\n\t e.preventDefault();\n\t }\n\t }\n\t }\n\n\t function renderMirrorImage() {\n\t if (shared.mirror) {\n\t return;\n\t }\n\t var rect = shared.sourceItem.getBoundingClientRect();\n\t shared.mirror = shared.sourceItem.cloneNode(true);\n\t shared.mirrorWidth = rect.width;\n\t shared.mirrorHeight = rect.height;\n\t shared.mirror.style.width = getRectWidth(rect) + 'px';\n\t shared.mirror.style.height = getRectHeight(rect) + 'px';\n\t rmClass(shared.mirror, o.classes.transit);\n\t addClass(shared.mirror, o.classes.mirror);\n\t o.mirrorContainer.appendChild(shared.mirror);\n\t regEvent(docElm, 'on', 'mousemove', drag);\n\t addClass(doc.body, o.classes.unselectable);\n\t regEvent(shared.mirror, 'on', 'wheel', scrollContainer);\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularcloned, shared.mirror, shared.sourceItem);\n\t }\n\t }\n\n\t function removeMirrorImage() {\n\t if (shared.mirror) {\n\t rmClass(doc.body, o.classes.unselectable);\n\t regEvent(docElm, 'off', 'mousemove', drag);\n\t regEvent(shared.mirror, 'off', 'wheel', scrollContainer);\n\t if(getParent(shared.mirror)){\n\t shared.mirror.parentNode.removeChild(shared.mirror);\n\t }\n\t shared.mirror = null;\n\t }\n\t }\n\n\t function getImmediateChild(dropTarget, target) { // watch performance - running each move several times!\n\t var immediate = target;\n\t while (immediate !== dropTarget && getParent(immediate) !== dropTarget) {\n\t immediate = getParent(immediate);\n\t }\n\t if (immediate === docElm) {\n\t return null;\n\t }\n\t return immediate;\n\t }\n\n\t function getReference(dropTarget, target, x, y) { // watch performance - running each move several times!\n\t var horizontal = o.direction === 'horizontal';\n\t return target !== dropTarget ? inside() : outside();\n\n\t function outside() { // slower, but able to figure out any position\n\t var len = dropTarget.children.length,\n\t i, el, rect;\n\t for (i = 0; i < len; i++) {\n\t el = dropTarget.children[i];\n\t rect = el.getBoundingClientRect();\n\t if (horizontal && rect.left > x) {\n\t return el;\n\t }\n\t if (!horizontal && rect.top > y) {\n\t return el;\n\t }\n\t }\n\t return null;\n\t }\n\n\t function inside() { // faster, but only available if dropped inside a child element\n\t var rect = target.getBoundingClientRect();\n\t if (horizontal) {\n\t return resolve(x > rect.left + getRectWidth(rect) / 2);\n\t }\n\t return resolve(y > rect.top + getRectHeight(rect) / 2);\n\t }\n\n\t function resolve(after) {\n\t return after ? nextEl(target) : target;\n\t }\n\t }\n\n\t function getElementBehindPoint(point, x, y) { // watch performance - running each move!\n\t var p = point || {},\n\t state = p.className,\n\t el;\n\t p.className += ' ' + o.classes.hide;\n\t el = doc.elementFromPoint(x, y);\n\t p.className = state;\n\t return el;\n\t }\n\t } // end of service\n\n\t /****************************************************************************************************************************/\n\t /****************************************************************************************************************************/\n\t /****************************************************************************************************************************/\n\n\t // HELPERS FUNCTIONS:\n\n\t function regEvent(el, op, type, fn) {\n\t var touch = {\n\t mouseup: 'touchend',\n\t mousedown: 'touchstart',\n\t mousemove: 'touchmove'\n\t },\n\t pointers = {\n\t mouseup: 'pointerup',\n\t mousedown: 'pointerdown',\n\t mousemove: 'pointermove'\n\t },\n\t microsoft = {\n\t mouseup: 'MSPointerUp',\n\t mousedown: 'MSPointerDown',\n\t mousemove: 'MSPointerMove'\n\t },\n\t $el = angular.element(el);\n\n\t if (global.navigator.pointerEnabled && pointers[type]) {\n\t $el[op](pointers[type], fn);\n\t } else if (global.navigator.msPointerEnabled && microsoft[type]) {\n\t $el[op](microsoft[type], fn);\n\t } else if (touch[type]) {\n\t $el[op](touch[type], fn);\n\t }\n\t $el[op](type, fn);\n\t }\n\n\t function never() {\n\t return false;\n\t }\n\n\t function always() {\n\t return true;\n\t }\n\n\t // make array from array-like objects or from single element (based on bevacqua/atoa)\n\t function makeArray(all, startIndex) {\n\t if (Array.isArray(all)) {\n\t return all;\n\t }\n\t if (all.length) { // is array-like\n\t return Array.prototype.slice.call(all, startIndex); // convert to vanilla js array\n\t } else { // is one element\n\t return [all];\n\t }\n\t }\n\n\t function whichMouseButton (e) {\n\t if (e.touches) { return e.touches.length; }\n\t if (e.originalEvent && e.originalEvent.touches) { return e.originalEvent.touches.length; }\n\t if (e.buttons !== undefined) { return e.buttons; }\n\t if (e.which !== undefined) { return e.which; }\n\t var button = e.button;\n\t if (button !== undefined) { // see https://github.com/jquery/jquery/blob/99e8ff1baa7ae341e94bb89c3e84570c7c3ad9ea/src/event.js#L573-L575\n\t return button & 1 ? 1 : button & 2 ? 3 : (button & 4 ? 2 : 0);\n\t }\n\t }\n\n\t function preventGrabbed(e) {\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t if (shared.grabbed) {\n\t e.preventDefault();\n\t }\n\t }\n\n\t function getScroll(scrollProp, offsetProp) {\n\t if (typeof window[offsetProp] !== 'undefined') {\n\t return window[offsetProp];\n\t }\n\t if (docElm.clientHeight) {\n\t return docElm[scrollProp];\n\t }\n\t return doc.body[scrollProp];\n\t }\n\n\t function getOffset(el) { // watch performance - running each move!\n\t var rect = el.getBoundingClientRect(),\n\t scrollTop = getScroll('scrollTop', 'pageYOffset'),\n\t scrollLeft = getScroll('scrollLeft', 'pageXOffset');\n\t return {\n\t left: rect.left + scrollLeft,\n\t right: rect.right + scrollLeft,\n\t top: rect.top + scrollTop,\n\t bottom: rect.bottom + scrollTop\n\t };\n\t }\n\n\t function getRectWidth(rect) {\n\t return rect.width || (rect.right - rect.left);\n\t }\n\n\t function getRectHeight(rect) {\n\t return rect.height || (rect.bottom - rect.top);\n\t }\n\n\t function getEmptyObject() {\n\t return {};\n\t }\n\n\t function nextEl(el) {\n\t return el.nextElementSibling || manually();\n\n\t function manually() {\n\t var sibling = el;\n\t do {\n\t sibling = sibling.nextSibling;\n\t } while (sibling && sibling.nodeType !== 1);\n\t return sibling;\n\t }\n\t }\n\n\t //Cannot use angular.isElement because we need to check plain dom element, no jQlite wrapped\n\t function isElement(obj) {\n\t return (\n\t typeof HTMLElement === 'object' ? obj instanceof HTMLElement : //DOM2\n\t obj && typeof obj === 'object' && obj !== null && obj.nodeType === 1 && typeof obj.nodeName === 'string'\n\t );\n\t }\n\n\t function lookupClass(className) {\n\t var cached = shared.classesCache[className];\n\t if (cached) {\n\t cached.lastIndex = 0;\n\t } else {\n\t shared.classesCache[className] = cached = new RegExp('(?:^|\\\\s)' + className + '(?:\\\\s|$)', 'g');\n\t }\n\t return cached;\n\t }\n\n\t function addClass(el, className) {\n\t var current = el.className;\n\t if (!current.length) {\n\t el.className = className;\n\t } else if (!lookupClass(className).test(current)) {\n\t el.className += ' ' + className;\n\t }\n\t }\n\n\t function rmClass(el, className) {\n\t el.className = el.className.replace(lookupClass(className), ' ').trim();\n\t }\n\n\t function getEventHost(e) {\n\t // on touchend event, we have to use `e.changedTouches`\n\t // see http://stackoverflow.com/questions/7192563/touchend-event-properties\n\t // see https://github.com/bevacqua/dragula/issues/34\n\t if (e.targetTouches && e.targetTouches.length) {\n\t return e.targetTouches[0];\n\t }\n\t if (e.changedTouches && e.changedTouches.length) {\n\t return e.changedTouches[0];\n\t }\n\t return e;\n\t }\n\n\t function getCoord(coord, e) { // watch performance - running each move several times!\n\t var host = getEventHost(e);\n\t var missMap = {\n\t pageX: 'clientX', // IE8\n\t pageY: 'clientY' // IE8\n\t };\n\t if (coord in missMap && !(coord in host) && missMap[coord] in host) {\n\t coord = missMap[coord];\n\t }\n\n\t // Adding support for touch events, as they are not functional in the original\n\t if (!host.type || host.type.indexOf('touch') < 0) {\n\t return host[coord];\n\t } else {\n\t if (host.type.indexOf('end') === -1) {\n\t // No clientX or clientY in a touch event\n\t return host.originalEvent.touches[0][coord.replace('client', 'page')];\n\t }\n\t // Nothing should happen for touchend\n\t return false;\n\t }\n\t }\n\n\t function getParent (el) { // watch performance - running each move!\n\t return el.parentNode === document ? null : el.parentNode;\n\t }\n\n\t function isInput (el) {\n\t return el.tagName === 'INPUT' || el.tagName === 'TEXTAREA' || el.tagName === 'SELECT' || isEditable(el);\n\t }\n\n\t function isEditable (el) {\n\t if (!el) { return false; } // no parents were editable\n\t if (el.contentEditable === 'false') { return false; } // stop the lookup\n\t if (el.contentEditable === 'true') { return true; } // found a contentEditable element in the chain\n\t return isEditable(getParent(el)); // contentEditable is set to 'inherit'\n\t }\n\n\t function domIndexOf(child, parent) {\n\t return Array.prototype.indexOf.call(angular.element(parent).children(), child);\n\t }\n\n\t function fireEvent(target, e, extra) { // watch performance - running each move!\n\t if (!target) {\n\t return;\n\t }\n\t shared.extra = extra;\n\t if (target.dispatchEvent) {\n\t target.dispatchEvent(e);\n\t } else {\n\t target.fireEvent('on' + e.eventType, e);\n\t }\n\t }\n\n\t function getBool(prop, args, context){\n\t if(angular.isFunction(prop)){\n\t return !!prop.apply(context || this, args || shared);\n\t }else{\n\t return !!prop;\n\t }\n\t }\n\n\t};\n\n\tdragularService.$inject = ['$rootScope', '$compile'];\n\n\tmodule.exports = dragularService;\n\n\t/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))\n\n/***/ }\n/******/ ]);"],"sourceRoot":"/source/"} \ No newline at end of file +{"version":3,"sources":["dragular.js"],"names":["root","factory","exports","module","define","amd","a","i","this","modules","__webpack_require__","moduleId","installedModules","id","loaded","call","m","c","p","dragularDirective","dragularService","angular","directive","dragular","restrict","link","$scope","iElm","iAttrs","tryJson","json","JSON","parse","e","drake","options","$eval","containersModel","dynamicModelAttribute","$watch","dragularModel","newVal","sanitizeContainersModel","dragularNameSpace","nameSpace","split","dragularOnInit","onInit","$inject","global","shared","classesCache","containersCtx","containers","mirror","source","item","copy","sourceItem","sourceModel","sourceFilteredModel","target","targetCtx","targetModel","lastDropTarget","offsetX","offsetY","moveX","moveY","offsetXr","offsetYb","clientX","clientY","mirrorWidth","mirrorHeight","initialSibling","currentSibling","initialIndex","currentIndex","tempModel","dragOverEvents","lastElementBehindCursor","grabbed","$rootScope","$compile","service","arg0","arg1","Array","isArray","processServiceArguments","arguments","length","isElement","initialContainers","document","querySelectorAll","o","copyOptions","extendOptions","tmp","extend","defaultOptions","classes","defaultClasses","eventNames","defaultEventNames","processOptionsObject","boundingBox","makeArray","containersFilteredModel","forEach","len","shLen","getContainersModel","fm","registerEvents","remove","op","regEvent","docElm","release","container","grab","name","eventName","doc","createEvent","initEvent","createEventObject","eventType","whichMouseButton","metaKey","ctrlKey","context","canStart","eventualMovements","type","isInput","focus","preventDefault","ungrab","dragging","originalEvent","getCoord","elementBehindCursor","getElementBehindPoint","dropTarget","findDropTarget","g","copySortSource","drop","removeOnSpill","cancel","fireEvent","dragularrelease","scope","$emit","isContainer","el","indexOf","isContainerModel","removeContainers","all","$applyAsync","changes","index","splice","startBecauseMouseMoved","movements","preventGrabbed","destroy","ignoreInputTextSelection","elementFromPoint","end","start","direction","getParent","parent","parentNode","parentHeight","offsetHeight","parentWidth","offsetWidth","childHeight","clientHeight","childWidth","clientWidth","offset","getOffset","left","top","right","bottom","addClass","transit","renderMirrorImage","style","drag","handle","invalid","moves","nextEl","manualStart","cloneNode","dragularcloned","containerIndex","domIndexOf","dragulardrag","afterDrop","compileItemOnDrop","element","content","removeChild","insertBefore","isInitialPlacement","dragularcancel","dragulardrop","dropIndex","cleanup","dropElmModel","dontCopyModel","dragularremove","revert","reverts","revertOnSpill","initial","removeMirrorImage","rmClass","spillOut","dragularout","dragulardragend","s","sibling","accepted","accepts","immediate","getImmediateChild","reference","getReference","dragularCommon","canBeAccepted","moved","spillOver","pageX","pageY","offsetBox","x","y","lockY","lockX","changed","dragularenter","dragularleave","dragularshadow","hide","scrollContainer","before","scrollTop","deltaY","stopPropagation","rect","getBoundingClientRect","width","height","getRectWidth","getRectHeight","mirrorContainer","appendChild","body","unselectable","outside","children","horizontal","inside","resolve","after","point","state","className","getBool","dragularover","never","getEmptyObject","always","fn","touch","mouseup","mousedown","mousemove","pointers","microsoft","$el","navigator","pointerEnabled","msPointerEnabled","startIndex","prototype","slice","touches","undefined","buttons","which","button","getScroll","scrollProp","offsetProp","window","scrollLeft","manually","nextSibling","nodeType","nextElementSibling","obj","HTMLElement","nodeName","lookupClass","cached","lastIndex","RegExp","current","test","replace","trim","getEventHost","targetTouches","changedTouches","coord","host","missMap","tagName","isEditable","contentEditable","child","extra","dispatchEvent","prop","args","isFunction","apply","documentElement","cleanEnviroment"],"mappings":"CAAA,SAA2CA,EAAMC,GAChD,GAAsB,gBAAZC,UAA0C,gBAAXC,QACxCA,OAAOD,QAAUD,QACb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D,EAAW1J,EAAUlB,KAHV,EAMpB,QAASgD,GAAW8H,EAAO3J,GACzB,MAAO1F,OAAMiN,UAAUzI,QAAQjJ,KAAKM,QAAQ8L,QAAQjC,GAAQ8F,WAAY6D,GAG1E,QAASnL,GAAU7F,EAAQ5B,EAAG6S,GACvBjR,IAGLX,EAAO4R,MAAQA,EACXjR,EAAOkR,cACTlR,EAAOkR,cAAc9S,GAErB4B,EAAO6F,UAAU,KAAOzH,EAAEiG,UAAWjG,IAIzC,QAASuP,GAAQwD,EAAMC,EAAM3M,GAC3B,MAAGjH,SAAQ6T,WAAWF,KACXA,EAAKG,MAAM7M,GAAW9H,KAAMyU,GAAQ/R,KAEpC8R,EAxmCb,GAAIlN,GAAM/B,SACNyB,EAASM,EAAIsN,eAYjB,OATA/P,GAAQgQ,gBAAkB,WACxBnS,EAAOC,gBACPD,EAAOE,iBACPF,EAAOG,cACPH,EAAOI,OAASsP,QAGlBvN,EAAQnC,OAASA,EAEVmC,EAimCTjE,GAAgB4B,SAAW,aAAc,YAEzC7C,EAAOD,QAAUkB,IAEYL,KAAKb,EAAU,WAAa,MAAOM","file":"dragular.min.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse {\n\t\tvar a = factory();\n\t\tfor(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];\n\t}\n})(this, function() {\nreturn /******/ (function(modules) { // webpackBootstrap\n/******/ \t// The module cache\n/******/ \tvar installedModules = {};\n\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId])\n/******/ \t\t\treturn installedModules[moduleId].exports;\n\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\texports: {},\n/******/ \t\t\tid: moduleId,\n/******/ \t\t\tloaded: false\n/******/ \t\t};\n\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.loaded = true;\n\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n\n\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(0);\n/******/ })\n/************************************************************************/\n/******/ ([\n/* 0 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t/* global angular */\n\t'use strict';\n\tvar dragularDirective = __webpack_require__(1);\n\tvar dragularService = __webpack_require__(2);\n\n\t/**\n\t * Dragular 4.2.0 by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\tmodule.exports = 'dragularModule';\n\n\tangular\n\t .module('dragularModule', [])\n\t .factory('dragularService', dragularService)\n\t .directive('dragular', dragularDirective);\n\n\n/***/ },\n/* 1 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\t/**\n\t * dragular Directive by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\n\tvar dragular = function (dragularService) {\n\t return {\n\t restrict: 'A',\n\t link: function($scope, iElm, iAttrs) {\n\n\t var drake,\n\t options = $scope.$eval(iAttrs.dragular) || tryJson(iAttrs.dragular) || {};\n\n\t function tryJson(json) {\n\t try { // I dont like try catch solutions but I havent find sattisfying way of chcecking json validity.\n\t return JSON.parse(json);\n\t } catch (e) {\n\t return undefined;\n\t }\n\t }\n\n\t if(options && options.containersModel && typeof options.containersModel === 'string'){\n\t options.containersModel = $scope.$eval(options.containersModel);\n\t }\n\n\t if(options && options.dynamicModelAttribute){\n\t // watch for model changes\n\t $scope.$watch(function () {\n\t return $scope.$eval(iAttrs.dragularModel);\n\t }, function (newVal) {\n\t if(newVal){\n\t drake.containersModel = drake.sanitizeContainersModel($scope.$eval(newVal));\n\t }\n\t });\n\t }else if(iAttrs.dragularModel){\n\t // bind once and keep reference\n\t options.containersModel = $scope.$eval(iAttrs.dragularModel);\n\t }\n\n\t if(iAttrs.dragularNameSpace){\n\t options.nameSpace = iAttrs.dragularNameSpace.split(' ');\n\t }\n\n\t if(iAttrs.dragularOnInit){\n\t options.onInit = $scope.$eval(iAttrs.dragularOnInit);\n\t }\n\n\t drake = dragularService(iElm[0], options);\n\t }\n\t };\n\t};\n\n\tdragular.$inject = ['dragularService'];\n\n\tmodule.exports = dragular;\n\n\n/***/ },\n/* 2 */\n/***/ function(module, exports) {\n\n\t/* WEBPACK VAR INJECTION */(function(global) {/* global angular */\n\t'use strict';\n\n\t/**\n\t * dragular Service by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\n\tvar shared = { // sahred object between all service instances\n\t classesCache: {}, // classes lookup cache\n\t containersCtx: {}, // containers model\n\t containers: {}, // containers\n\t mirror: null, // mirror image\n\t source: null, // source container\n\t item: null, // item being dragged\n\t copy: null, // copy flag\n\t sourceItem: null, // item originaly dragged if copy is enabled\n\t sourceModel: null, // source container model\n\t sourceFilteredModel: null, // source container filtered model if relevant\n\t target: null, // droppable container under drag item\n\t targetCtx: null, // target container context\n\t targetModel: null, // target container model\n\t lastDropTarget: null, // last container item was over\n\t offsetX: null, // reference x\n\t offsetY: null, // reference y\n\t moveX: null, // reference move x\n\t moveY: null, // reference move y\n\t offsetXr: null, // reference x right for boundingBox feature\n\t offsetYb: null, // reference y bottom for boundingBox feature\n\t clientX: null, // cache client x, init at grab, update at drag\n\t clientY: null, // cache client y, init at grab, update at drag\n\t mirrorWidth: null, // mirror width for boundingBox feature\n\t mirrorHeight: null, // mirror height for boundingBox feature\n\t initialSibling: null, // reference sibling when grabbed\n\t currentSibling: null, // reference sibling now\n\t initialIndex: null, // reference model index when grabbed\n\t currentIndex: null, // reference model index now\n\t tempModel: null, // if o.isContainer is used, model can be provided as well, it is temporary saved here during drags\n\t dragOverEvents: {}, // drag over events fired on element behind cursor\n\t lastElementBehindCursor: null, // last element behind cursor\n\t grabbed: null // holds mousedown context until first mousemove\n\t};\n\n\tvar dragularService = function ($rootScope, $compile) {\n\t // abbreviations\n\t var doc = document,\n\t docElm = doc.documentElement;\n\n\t // clean common/shared objects\n\t service.cleanEnviroment = function cleanEnviroment() {\n\t shared.classesCache = {};\n\t shared.containersCtx = {};\n\t shared.containers = {};\n\t shared.mirror = undefined;\n\t };\n\n\t service.shared = shared;\n\n\t return service;\n\n\t // service definition\n\t function service(arg0, arg1) {\n\t var initialContainers = arg0 || [],\n\t options = arg1 || {},\n\t o, // shorthand for options\n\t g = getBool, // shorthand for getBool\n\t // defaults\n\t defaultClasses = {\n\t mirror: 'gu-mirror',\n\t hide: 'gu-hide',\n\t unselectable: 'gu-unselectable',\n\t transit: 'gu-transit'\n\t },\n\t defaultEventNames = {\n\t // drag-over DOM events\n\t dragularenter: 'dragularenter',\n\t dragularleave: 'dragularleave',\n\t dragularrelease: 'dragularrelease',\n\t // $scope events\n\t dragularcloned: 'dragularcloned',\n\t dragulardrag: 'dragulardrag',\n\t dragularcancel: 'dragularcancel',\n\t dragulardrop: 'dragulardrop',\n\t dragularremove: 'dragularremove',\n\t dragulardragend: 'dragulardragend',\n\t dragularshadow: 'dragularshadow',\n\t dragularover: 'dragularover',\n\t dragularout: 'dragularout'\n\t },\n\t defaultOptions = { // options with defaults\n\t copyOptions: false, // copy options object when provided\n\t classes: defaultClasses, // classes used by dragular\n\t eventNames: defaultEventNames, // event names used by dragular\n\t containers: false, // initial containers provided via options object (are provided via parameter by default)\n\t containersModel: false, // if provided, model will be synced with DOM\n\t containersFilteredModel: false, // if provided, dragular will handle filtered model cases\n\t isContainer: never, // potential target can be forced to be container by custom logic\n\t isContainerModel: getEmptyObject, // if isContainer function is provided, you can provide also respective model\n\t moves: always, // can drag start?\n\t accepts: always, // can target accept dragged item? (target context used)\n\t canBeAccepted: always, // can be dragged item accepted by target? (source context used)\n\t copy: false, // dragged item will be copy of source? flag or function\n\t copySortSource: false, // enable sorting in source when copying item\n\t dontCopyModel: false, // dont make copy of model when coping item (#61)\n\t invalid: never, // target (in)validity function\n\t revertOnSpill: false, // item returns to original place\n\t removeOnSpill: false, // item will be removed if not placed into valid target\n\t lockX: false, // lock movement into x-axis\n\t lockY: false, // lock movement into y-axis\n\t boundingBox: false, // lock movement inside this element boundaries\n\t mirrorContainer: doc.body, // element for appending mirror\n\t ignoreInputTextSelection: true, // text selection in inputs wont be considered as drag\n\t compileItemOnDrop: false,\n\t onInit: false // function callback called after dragular initialisation and providing drake as first argument\n\t },\n\t drake = {\n\t containers: shared.containers,\n\t containersCtx: shared.containersCtx,\n\t sanitizeContainersModel: sanitizeContainersModel,\n\t isContainer: isContainer,\n\t start: manualStart,\n\t end: end,\n\t cancel: cancel,\n\t remove: remove,\n\t destroy: destroy,\n\t dragging: false\n\t };\n\n\t processServiceArguments(); // both arguments (containers and options) are optional, this function handle this\n\t extendOptions();\n\t processOptionsObject();\n\t registerEvents();\n\t \n\t if(o.onInit){\n\t o.onInit(drake); \n\t }\n\n\t return drake;\n\n\t // Function definitions: ==============================================================================================================\n\t // Initial functions: -----------------------------------------------------------------------------------------------------------------\n\n\t function sanitizeContainersModel(containersModel) {\n\t if (typeof(containersModel) === 'function') {\n\t return containersModel;\n\t }\n\t if (Array.isArray(containersModel)) {\n\t // |-------- is 2D array? -----------|\n\t return Array.isArray(containersModel[0]) ? containersModel : [containersModel];\n\t } else {\n\t return [];\n\t }\n\t }\n\n\t function processServiceArguments(){\n\t if (arguments.length === 1 && // if there is only one argument we need to distinguish if it is options object or container(s) reference\n\t !Array.isArray(arg0) && // array of containers elements\n\t !angular.isElement(arg0) && // one container element\n\t !arg0[0] && // array-like object with containers elements\n\t typeof arg0 !== 'string') { // selector\n\t // then arg0 is options object\n\t options = arg0 || {};\n\t initialContainers = []; // containers are not provided on init\n\t } else if (typeof arg0 === 'string') {\n\t initialContainers = document.querySelectorAll(arg0);\n\t }\n\t o = options.copyOptions ? angular.copy(options) : options;\n\t }\n\n\t function extendOptions(){\n\t var tmp = angular.extend({}, defaultOptions, o); // tmp for keeping defaults untouched\n\t angular.extend(o, tmp); // merge defaults back into options\n\t if(o.classes){\n\t tmp = angular.extend({}, defaultClasses, o.classes);\n\t angular.extend(o.classes, tmp);\n\t }\n\t if(o.eventNames){\n\t tmp = angular.extend({}, defaultEventNames, o.eventNames);\n\t angular.extend(o.eventNames, tmp);\n\t }\n\t }\n\n\t function processOptionsObject(){\n\t // bounding box must be pure DOM element, not jQuery wrapper or something else..\n\t if (!isElement(o.boundingBox)) {\n\t o.boundingBox = false;\n\t }\n\n\t // initial containers provided via options are higher priority then by parameter\n\t if(o.containers){\n\t initialContainers = o.containers;\n\t }\n\t // sanitize initialContainers\n\t initialContainers = makeArray(initialContainers);\n\n\t // sanitize o.containersModel\n\t o.containersModel = sanitizeContainersModel(o.containersModel);\n\n\t // sanitize o.containersFilteredModel\n\t if (Array.isArray(o.containersFilteredModel)) {\n\t // |-------- is 2D array? -----------|\n\t o.containersFilteredModel = Array.isArray(o.containersFilteredModel[0]) ? o.containersFilteredModel : [o.containersFilteredModel];\n\t } else {\n\t o.containersFilteredModel = [];\n\t }\n\n\t // feed containers groups and optionaly do same for models\n\t if (!o.nameSpace) {\n\t o.nameSpace = ['dragularCommon'];\n\t }\n\t if (!Array.isArray(o.nameSpace)) {\n\t o.nameSpace = [o.nameSpace];\n\t }\n\t o.nameSpace.forEach(function eachNameSpace(nameSpace) {\n\t if (!shared.containers[nameSpace]) {\n\t shared.containers[nameSpace] = [];\n\t shared.containersCtx[nameSpace] = [];\n\t }\n\t var len = initialContainers.length,\n\t shLen = shared.containers[nameSpace].length;\n\t for (var i = 0; i < len; i++) {\n\t shared.containers[nameSpace][i + shLen] = initialContainers[i];\n\t shared.containersCtx[nameSpace][i + shLen] = {\n\t o: o,\n\t m: getContainersModel()[i], // can be undefined\n\t fm: o.containersFilteredModel[i] // can be undefined\n\t };\n\t }\n\t });\n\t }\n\n\t function registerEvents(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'mouseup', release);\n\n\t initialContainers.forEach(function addMouseDown(container) {\n\t regEvent(container, 'on', 'mousedown', grab);\n\t });\n\n\t if(!remove){ // create dragular DOM events\n\t angular.forEach(['dragularenter', 'dragularleave', 'dragularrelease'], function prepareDragOverEvents(name) {\n\t var eventName = o.eventNames[name];\n\t if(!shared.dragOverEvents[eventName]){\n\t if (doc.createEvent) {\n\t shared.dragOverEvents[eventName] = doc.createEvent('HTMLEvents');\n\t shared.dragOverEvents[eventName].initEvent(eventName, true, true);\n\t } else {\n\t shared.dragOverEvents[eventName] = doc.createEventObject();\n\t shared.dragOverEvents[eventName].eventType = eventName;\n\t }\n\t }\n\t });\n\t }\n\t }\n\n\t // Event handlers functions (end of initial functions): -----------------------------------------------------------------------------------------------------------------\n\n\t function grab(e) {\n\t // filter some odd situations\n\t if (whichMouseButton(e) !== 1 || e.metaKey || e.ctrlKey) {\n\t return; // we only care about honest-to-god left clicks and touch events\n\t }\n\n\t // set itial values\n\t shared.moveX = e.clientX;\n\t shared.moveY = e.clientY;\n\n\t var context = canStart(e.target);\n\t if (!context || !context.item) {\n\t return;\n\t }\n\n\t shared.grabbed = context;\n\t eventualMovements();\n\t if (e.type === 'mousedown') {\n\t if (isInput(context.item)) { // see also: https://github.com/bevacqua/dragula/issues/208\n\t context.item.focus(); // fixes https://github.com/bevacqua/dragula/issues/176\n\t } else {\n\t e.preventDefault(); // fixes https://github.com/bevacqua/dragula/issues/155\n\t }\n\t }\n\t }\n\n\t function release(e) {\n\t ungrab();\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t var elementBehindCursor = getElementBehindPoint(shared.mirror, shared.clientX, shared.clientY),\n\t dropTarget = findDropTarget(elementBehindCursor, shared.clientX, shared.clientY);\n\n\t if (dropTarget && ((shared.copy && g(o.copySortSource)) || (!shared.copy || dropTarget !== shared.source))) {\n\t // found valid target and (is not copy case or target is not initial container)\n\t drop(shared.item, dropTarget);\n\t } else if (g(o.removeOnSpill)) {\n\t remove();\n\t } else {\n\t cancel();\n\t }\n\n\t // after release there is no container hovered\n\t shared.target = null;\n\n\t if (shared.lastElementBehindCursor) {\n\t fireEvent(shared.lastElementBehindCursor, shared.dragOverEvents.dragularrelease, elementBehindCursor);\n\t }\n\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularrelease, shared.item, shared.source);\n\t }\n\t }\n\n\t // Main logic functions (end of event handler functions): -----------------------------------------------------------------------------------------------------------------\n\n\t function isContainer(el) {\n\t if(!el){\n\t return false;\n\t }\n\t var i = o.nameSpace.length;\n\t while (i--) {\n\t if (shared.containers[o.nameSpace[i]].indexOf(el) !== -1) {\n\t return true;\n\t }\n\t }\n\t if (o.isContainer(el)) {\n\t shared.tempModel = o.isContainerModel(el);\n\t return true;\n\t } else {\n\t shared.tempModel = null;\n\t }\n\t return false;\n\t }\n\n\t function getContainersModel() {\n\t return (typeof(o.containersModel) === 'function') ? sanitizeContainersModel(o.containersModel(drake, shared)) : o.containersModel;\n\t }\n\n\t function removeContainers(all) {\n\t $rootScope.$applyAsync(function applyDestroyed() {\n\t var changes = Array.isArray(all) ? all : makeArray(all);\n\t changes.forEach(function forEachContainer(container) {\n\t angular.forEach(o.nameSpace, function forEachNs(nameSpace) {\n\t var index;\n\t index = shared.containers[nameSpace].indexOf(container);\n\t shared.containers[nameSpace].splice(index, 1);\n\t shared.containersCtx[nameSpace].splice(index, 1);\n\t });\n\t });\n\t });\n\t }\n\n\t function eventualMovements(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'mousemove', startBecauseMouseMoved);\n\t }\n\n\t function movements(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'selectstart', preventGrabbed); // IE8\n\t regEvent(docElm, op, 'click', preventGrabbed);\n\t regEvent(docElm, op, 'touchmove', preventGrabbed); // fixes touch devices scrolling while drag\n\t }\n\n\t function destroy() {\n\t registerEvents(true);\n\t removeContainers(initialContainers);\n\t release({});\n\t }\n\n\t function startBecauseMouseMoved(e) {\n\t if (!shared.grabbed || drake.dragging) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t if (whichMouseButton(e) === 0) {\n\t release({});\n\t return; // when text is selected on an input and then dragged, mouseup doesn't fire. this is our only hope\n\t }\n\t // truthy check fixes dragula-#239, equality fixes dragula-#207\n\t if (e.clientX && e.clientX === shared.moveX && e.clientY && e.clientY === shared.moveY) {\n\t return;\n\t }\n\t if (g(o.ignoreInputTextSelection)) {\n\t var clientX = getCoord('clientX', e),\n\t clientY = getCoord('clientY', e),\n\t elementBehindCursor = doc.elementFromPoint(clientX, clientY);\n\t if (isInput(elementBehindCursor)) {\n\t return;\n\t }\n\t }\n\n\t var grabbed = shared.grabbed; // calling end() unsets shared.grabbed\n\t eventualMovements('remove'); // remove mousemove listener\n\t movements();\n\t end();\n\t start(grabbed);\n\n\t // automaticly detect direction of elements if not set in options\n\t if (!o.direction && getParent(shared.sourceItem)) {\n\t var parent = shared.sourceItem.parentNode,\n\t parentHeight = parent.offsetHeight,\n\t parentWidth = parent.offsetWidth,\n\t childHeight = shared.sourceItem.clientHeight,\n\t childWidth = shared.sourceItem.clientWidth;\n\t o.direction = parentHeight / childHeight < parentWidth / childWidth ? 'horizontal' : 'vertical';\n\t }\n\n\t // get initial coordinates, used to render shared.mirror for first time\n\t var offset = getOffset(shared.sourceItem);\n\t shared.offsetX = getCoord('pageX', e) - offset.left;\n\t shared.offsetY = getCoord('pageY', e) - offset.top;\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t // limiting area of shared.mirror movement, get initial coordinates\n\t if (o.boundingBox) {\n\t shared.offsetXr = getCoord('pageX', e) - offset.right;\n\t shared.offsetYb = getCoord('pageY', e) - offset.bottom;\n\t }\n\n\t e.preventDefault();\n\n\t addClass(shared.item, o.classes.transit);\n\t renderMirrorImage();\n\t // initial position\n\t shared.mirror.style.left = shared.clientX - shared.offsetX + 'px';\n\t shared.mirror.style.top = shared.clientY - shared.offsetY + 'px';\n\n\t drag(e);\n\t }\n\n\t function canStart(item) {\n\t if (drake.dragging && shared.mirror) {\n\t console.log('usecase?');\n\t return; // already dragging\n\t }\n\n\t var handle = item;\n\t while (getParent(item) && !isContainer(getParent(item))) {\n\t // break loop if user tries to drag item which is considered invalid handle\n\t if (o.invalid(item, handle)) {\n\t return;\n\t }\n\t item = getParent(item); // drag target should be immediate child of container\n\t if (!item) {\n\t return;\n\t }\n\t }\n\n\t var source = getParent(item);\n\t if (!source ||\n\t o.invalid(item, handle) ||\n\t !o.moves(item, source, handle, nextEl(item))) {\n\t return;\n\t }\n\n\t return {\n\t item: item,\n\t source: source\n\t };\n\t }\n\n\t function manualStart(item) {\n\t var context = canStart(item);\n\t if (context) {\n\t start(context);\n\t }\n\t }\n\n\t function start(context) {\n\t shared.sourceItem = shared.item = context.item;\n\t shared.source = context.source;\n\t shared.initialSibling = shared.currentSibling = nextEl(context.item);\n\n\t if (g(o.copy, [context.item, context.source])) {\n\t shared.item = context.item.cloneNode(true);\n\t shared.copy = true;\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularcloned, shared.item, context.item);\n\t }\n\t } else {\n\t shared.copy = false;\n\t }\n\n\t // prepare models operations\n\t var containerIndex = initialContainers.indexOf(context.source);\n\t shared.sourceModel = getContainersModel()[containerIndex];\n\n\t shared.sourceFilteredModel = o.containersFilteredModel[containerIndex];\n\t shared.initialIndex = domIndexOf(context.item, context.source);\n\n\t drake.dragging = true;\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragulardrag, shared.sourceItem, shared.source);\n\t }\n\n\t return true;\n\t }\n\n\t function end() {\n\t if (!drake.dragging || !shared.item) {\n\t return;\n\t }\n\t drop(shared.item, getParent(shared.item));\n\t }\n\n\t function ungrab() {\n\t shared.grabbed = false;\n\t eventualMovements('remove');\n\t movements('remove');\n\t }\n\n\t function drop(item, target) {\n\t var sourceItem = shared.sourceItem,\n\t currentSibling = shared.currentSibling;\n\t \n\t if (shared.copy && g(o.copySortSource) && target === shared.source && getParent(item)) {\n\t item.parentNode.removeChild(shared.sourceItem);\n\t }\n\n\t if (shared.sourceModel && !isInitialPlacement(target)) {\n\n\t var dropIndex = domIndexOf(item, target);\n\t if(shared.targetCtx.fm){ // target has filtered model\n\t // convert index from index-in-filteredModel to index-in-model\n\t dropIndex = shared.targetCtx.m.indexOf(shared.targetCtx.fm[dropIndex]);\n\t }\n\t if(shared.sourceFilteredModel){ // target has filtered model\n\t // convert index from index-in-filteredModel to index-in-model\n\t shared.initialIndex = shared.sourceModel.indexOf(shared.sourceFilteredModel[shared.initialIndex]);\n\t }\n\t $rootScope.$applyAsync(function applyDrop() {\n\t if(!shared.sourceModel){\n\t return;\n\t }\n\t if (target === shared.source) {\n\t shared.sourceModel.splice(dropIndex, 0, shared.sourceModel.splice(shared.initialIndex, 1)[0]);\n\t } else {\n\t shared.dropElmModel = shared.copy && !o.dontCopyModel ? angular.copy(shared.sourceModel[shared.initialIndex]) : shared.sourceModel[shared.initialIndex];\n\n\t if (!shared.tempModel) {\n\t shared.targetModel = shared.targetCtx.m;\n\t } else {\n\t shared.targetModel = shared.tempModel;\n\t }\n\t \n\t target.removeChild(item); // element must be removed for ngRepeat to apply correctly\n\n\t if (!shared.copy) {\n\t shared.sourceModel.splice(shared.initialIndex, 1);\n\t }\n\t shared.targetModel.splice(dropIndex, 0, shared.dropElmModel);\n\t }\n\n\t if (getParent(item)) {\n\t item.parentNode.removeChild(item);\n\t }\n\n\t afterDrop();\n\t });\n\t } else {\n\t afterDrop();\n\t }\n\n\t function afterDrop() {\n\t if(o.compileItemOnDrop){\n\t var scope = angular.element(target).scope();\n\t scope.$applyAsync(function(){\n\t var content = $compile(shared.copy ? sourceItem.cloneNode(true) : sourceItem)(scope); \n\t if(item.parentNode === target){\n\t target.removeChild(item);\n\t }\n\t target.insertBefore(content[0], currentSibling);\n\t });\n\t }\n\t \n\t if (o.scope) {\n\t if (isInitialPlacement(target)) {\n\t o.scope.$emit(o.eventNames.dragularcancel, item, shared.source, shared.sourceModel, shared.initialIndex);\n\t } else {\n\t o.scope.$emit(o.eventNames.dragulardrop, item, target, shared.source, shared.sourceModel, shared.initialIndex, shared.targetModel, dropIndex);\n\t }\n\t }\n\t \n\t cleanup();\n\t }\n\t }\n\n\t function remove() {\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t var parent = getParent(shared.item);\n\n\t if (parent) {\n\t parent.removeChild(shared.item);\n\t }\n\n\t if (shared.sourceModel) {\n\t $rootScope.$applyAsync(function removeModel() {\n\t shared.sourceModel.splice(shared.initialIndex, 1);\n\t cleanup();\n\t });\n\t }\n\n\t if (o.scope) {\n\t o.scope.$emit(shared.copy ? o.eventNames.dragularcancel : o.eventNames.dragularremove, shared.item, parent, shared.sourceModel, shared.initialIndex);\n\t }\n\t if (!shared.sourceModel) {\n\t cleanup();\n\t }\n\t }\n\n\t function cancel(revert) {\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t var reverts = arguments.length > 0 ? revert : g(o.revertOnSpill),\n\t parent = getParent(shared.item);\n\n\t var initial = isInitialPlacement(parent);\n\t if (!initial && !shared.copy && reverts) {\n\t shared.source.insertBefore(shared.item, shared.initialSibling);\n\t }\n\t if (shared.sourceModel && !shared.copy && !reverts) {\n\t drop(shared.item, parent);\n\t } else if (o.scope) {\n\t if (initial || reverts) {\n\t o.scope.$emit(o.eventNames.dragularcancel, shared.item, shared.source);\n\t }\n\t }\n\n\t if (!shared.sourceModel || shared.copy || reverts || initial) {\n\t cleanup();\n\t }\n\t }\n\n\t function cleanup() {\n\t ungrab();\n\t removeMirrorImage();\n\n\t if (shared.item) {\n\t rmClass(shared.item, o.classes.transit);\n\t }\n\n\t drake.dragging = false;\n\n\t if (g(o.removeOnSpill) === true) {\n\t spillOut();\n\t }\n\n\t if (o.scope) {\n\t if(shared.lastDropTarget){\n\t o.scope.$emit(o.eventNames.dragularout, shared.item, shared.lastDropTarget, shared.source);\n\t }\n\t o.scope.$emit(o.eventNames.dragulardragend, shared.item);\n\t }\n\n\t shared.source = shared.item = shared.sourceItem = shared.initialSibling = shared.currentSibling = shared.sourceModel = null;\n\t shared.initialIndex = shared.currentIndex = shared.lastDropTarget = shared.tempModel = shared.targetModel = null;\n\t shared.dropElmModel = shared.targetCtx = shared.copy = shared.moveX = shared.moveY = null;\n\t }\n\n\t // is item currently placed in original container and original position?\n\t function isInitialPlacement(target, s) { // watch performance - running each move several times!\n\t var sibling = s || (shared.mirror ? shared.currentSibling : nextEl(shared.item));\n\t return target === shared.source && sibling === shared.initialSibling;\n\t }\n\n\t // find valid drop container\n\t function findDropTarget(elementBehindCursor, clientX, clientY) { // watch performance - running each move!\n\t var target = elementBehindCursor;\n\n\t while (target && !accepted()) {\n\t target = getParent(target);\n\t }\n\t return target;\n\n\t function accepted() {\n\t var accepts = false;\n\n\t if (isContainer(target)) { // is droppable?\n\n\t var immediate = getImmediateChild(target, elementBehindCursor),\n\t reference = getReference(target, immediate, clientX, clientY),\n\t initial = isInitialPlacement(target, reference),\n\t i = o.nameSpace.length;\n\n\t while (i--) {\n\t if (shared.containers[o.nameSpace[i]].indexOf(target) !== -1) {\n\t shared.targetCtx = shared.containersCtx[o.nameSpace[i]][shared.containers[o.nameSpace[i]].indexOf(target)];\n\t break;\n\t }\n\t if (!shared.targetCtx) {\n\t shared.targetCtx = shared.containersCtx.dragularCommon[shared.containers.dragularCommon.indexOf(target)];\n\t }\n\t }\n\n\t accepts = initial ||\n\t (shared.targetCtx.o.accepts(shared.item, target, shared.source, reference, shared.sourceModel, shared.initialIndex) &&\n\t o.canBeAccepted(shared.item, target, shared.source, reference, shared.sourceModel, shared.initialIndex));\n\n\t if (shared.target !== target) { // used for scroll issue\n\t shared.target = target;\n\t }\n\t }\n\t return accepts;\n\t }\n\t }\n\n\t function drag(e) { // watch performance - running each move!\n\t if (!shared.mirror) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\n\t // update coordinates\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t // count mirror coordiates\n\t var x = shared.clientX - shared.offsetX,\n\t y = shared.clientY - shared.offsetY,\n\t pageX,\n\t pageY,\n\t offsetBox;\n\n\t // fill extra properties if boundingBox is used\n\t if (o.boundingBox) {\n\t pageX = getCoord('pageX', e);\n\t pageY = getCoord('pageY', e);\n\t offsetBox = getOffset(o.boundingBox);\n\t }\n\n\t if (!o.lockY) {\n\t if (!o.boundingBox || (pageX > offsetBox.left + shared.offsetX && pageX < offsetBox.right + shared.offsetXr)) {\n\t shared.mirror.style.left = x + 'px';\n\t } else if (o.boundingBox) { // check again in case user scrolled the view\n\t if (pageX < offsetBox.left + shared.offsetX) {\n\t shared.mirror.style.left = shared.clientX - (pageX - offsetBox.left) + 'px';\n\t } else {\n\t shared.mirror.style.left = shared.clientX - shared.mirrorWidth - (pageX - offsetBox.right) + 'px';\n\t }\n\t }\n\t }\n\t if (!o.lockX) {\n\t if (!o.boundingBox || (pageY > offsetBox.top + shared.offsetY && pageY < offsetBox.bottom + shared.offsetYb)) {\n\t shared.mirror.style.top = y + 'px';\n\t } else if (o.boundingBox) { // check again in case user scrolled the view\n\t if (pageY < offsetBox.top + shared.offsetY) {\n\t shared.mirror.style.top = shared.clientY - (pageY - offsetBox.top) + 'px';\n\t } else {\n\t shared.mirror.style.top = shared.clientY - shared.mirrorHeight - (pageY - offsetBox.bottom) + 'px';\n\t }\n\t }\n\t }\n\n\t var elementBehindCursor = getElementBehindPoint(shared.mirror, shared.clientX, shared.clientY),\n\t dropTarget = findDropTarget(elementBehindCursor, shared.clientX, shared.clientY),\n\t changed = dropTarget !== shared.lastDropTarget;\n\n\t if (elementBehindCursor !== shared.lastElementBehindCursor) {\n\t fireEvent(elementBehindCursor, shared.dragOverEvents.dragularenter, !!dropTarget);\n\t if (shared.lastElementBehindCursor) {\n\t fireEvent(shared.lastElementBehindCursor, shared.dragOverEvents.dragularleave, elementBehindCursor);\n\t }\n\t shared.lastElementBehindCursor = elementBehindCursor;\n\t }\n\n\t if (changed) {\n\t if (shared.lastDropTarget) {\n\t moved('out');\n\t }\n\t shared.lastDropTarget = dropTarget;\n\t moved('over');\n\t }\n\n\t // do not copy in same container\n\t if (dropTarget === shared.source && shared.copy && !g(o.copySortSource)) {\n\t if (getParent(shared.item)) {\n\t shared.item.parentNode.removeChild(shared.item);\n\t }\n\t return;\n\t }\n\n\t var reference,\n\t immediate = getImmediateChild(dropTarget, elementBehindCursor);\n\n\t if (immediate !== null) {\n\t reference = getReference(dropTarget, immediate, shared.clientX, shared.clientY);\n\t } else if (g(o.revertOnSpill) === true && !shared.copy) {\n\t // the case that mirror is not over valid target and reverting is on and copy is off\n\t reference = shared.initialSibling;\n\t dropTarget = shared.source;\n\t } else {\n\t // the case that mirror is not over valid target and removing is on or copy is on\n\t if (shared.copy && getParent(shared.item)) {\n\t // remove item or copy of item\n\t shared.item.parentNode.removeChild(shared.item);\n\t }\n\t return;\n\t }\n\n\t if (reference === null ||\n\t reference !== shared.item &&\n\t reference !== nextEl(shared.item) &&\n\t reference !== shared.currentSibling) {\n\t // moving item/copy to new container from previous one\n\t shared.currentSibling = reference;\n\n\t dropTarget.insertBefore(shared.item, reference); // if reference is null item is inserted at the end\n\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularshadow, shared.item, dropTarget);\n\t }\n\t }\n\n\t function moved(type) {\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames['dragular' + type], shared.item, shared.lastDropTarget, shared.source);\n\t }\n\t if (g(o.removeOnSpill) === true) {\n\t type === 'over' ? spillOver() : spillOut();\n\t }\n\t }\n\t }\n\n\t function spillOver() {\n\t rmClass(shared.item, o.classes.hide);\n\t }\n\n\t function spillOut() {\n\t if (drake.dragging) {\n\t addClass(shared.item, o.classes.hide);\n\t }\n\t }\n\n\t function scrollContainer(e) {\n\t if (shared.target) {\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t var before = shared.target.scrollTop;\n\t shared.target.scrollTop += e.deltaY;\n\t // block scroll of the document when container can be scrolled\n\t if (before !== shared.target.scrollTop) {\n\t e.stopPropagation();\n\t e.preventDefault();\n\t }\n\t }\n\t }\n\n\t function renderMirrorImage() {\n\t if (shared.mirror) {\n\t return;\n\t }\n\t var rect = shared.sourceItem.getBoundingClientRect();\n\t shared.mirror = shared.sourceItem.cloneNode(true);\n\t shared.mirrorWidth = rect.width;\n\t shared.mirrorHeight = rect.height;\n\t shared.mirror.style.width = getRectWidth(rect) + 'px';\n\t shared.mirror.style.height = getRectHeight(rect) + 'px';\n\t rmClass(shared.mirror, o.classes.transit);\n\t addClass(shared.mirror, o.classes.mirror);\n\t o.mirrorContainer.appendChild(shared.mirror);\n\t regEvent(docElm, 'on', 'mousemove', drag);\n\t addClass(doc.body, o.classes.unselectable);\n\t regEvent(shared.mirror, 'on', 'wheel', scrollContainer);\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularcloned, shared.mirror, shared.sourceItem);\n\t }\n\t }\n\n\t function removeMirrorImage() {\n\t if (shared.mirror) {\n\t rmClass(doc.body, o.classes.unselectable);\n\t regEvent(docElm, 'off', 'mousemove', drag);\n\t regEvent(shared.mirror, 'off', 'wheel', scrollContainer);\n\t if(getParent(shared.mirror)){\n\t shared.mirror.parentNode.removeChild(shared.mirror);\n\t }\n\t shared.mirror = null;\n\t }\n\t }\n\n\t function getImmediateChild(dropTarget, target) { // watch performance - running each move several times!\n\t var immediate = target;\n\t while (immediate !== dropTarget && getParent(immediate) !== dropTarget) {\n\t immediate = getParent(immediate);\n\t }\n\t if (immediate === docElm) {\n\t return null;\n\t }\n\t return immediate;\n\t }\n\n\t function getReference(dropTarget, target, x, y) { // watch performance - running each move several times!\n\t var horizontal = o.direction === 'horizontal';\n\t return target !== dropTarget ? inside() : outside();\n\n\t function outside() { // slower, but able to figure out any position\n\t var len = dropTarget.children.length,\n\t i, el, rect;\n\t for (i = 0; i < len; i++) {\n\t el = dropTarget.children[i];\n\t rect = el.getBoundingClientRect();\n\t if (horizontal && rect.left > x) {\n\t return el;\n\t }\n\t if (!horizontal && rect.top > y) {\n\t return el;\n\t }\n\t }\n\t return null;\n\t }\n\n\t function inside() { // faster, but only available if dropped inside a child element\n\t var rect = target.getBoundingClientRect();\n\t if (horizontal) {\n\t return resolve(x > rect.left + getRectWidth(rect) / 2);\n\t }\n\t return resolve(y > rect.top + getRectHeight(rect) / 2);\n\t }\n\n\t function resolve(after) {\n\t return after ? nextEl(target) : target;\n\t }\n\t }\n\n\t function getElementBehindPoint(point, x, y) { // watch performance - running each move!\n\t var p = point || {},\n\t state = p.className,\n\t el;\n\t p.className += ' ' + o.classes.hide;\n\t el = doc.elementFromPoint(x, y);\n\t p.className = state;\n\t return el;\n\t }\n\t } // end of service\n\n\t /****************************************************************************************************************************/\n\t /****************************************************************************************************************************/\n\t /****************************************************************************************************************************/\n\n\t // HELPERS FUNCTIONS:\n\n\t function regEvent(el, op, type, fn) {\n\t var touch = {\n\t mouseup: 'touchend',\n\t mousedown: 'touchstart',\n\t mousemove: 'touchmove'\n\t },\n\t pointers = {\n\t mouseup: 'pointerup',\n\t mousedown: 'pointerdown',\n\t mousemove: 'pointermove'\n\t },\n\t microsoft = {\n\t mouseup: 'MSPointerUp',\n\t mousedown: 'MSPointerDown',\n\t mousemove: 'MSPointerMove'\n\t },\n\t $el = angular.element(el);\n\n\t if (global.navigator.pointerEnabled && pointers[type]) {\n\t $el[op](pointers[type], fn);\n\t } else if (global.navigator.msPointerEnabled && microsoft[type]) {\n\t $el[op](microsoft[type], fn);\n\t } else if (touch[type]) {\n\t $el[op](touch[type], fn);\n\t }\n\t $el[op](type, fn);\n\t }\n\n\t function never() {\n\t return false;\n\t }\n\n\t function always() {\n\t return true;\n\t }\n\n\t // make array from array-like objects or from single element (based on bevacqua/atoa)\n\t function makeArray(all, startIndex) {\n\t if (Array.isArray(all)) {\n\t return all;\n\t }\n\t if (all.length) { // is array-like\n\t return Array.prototype.slice.call(all, startIndex); // convert to vanilla js array\n\t } else { // is one element\n\t return [all];\n\t }\n\t }\n\n\t function whichMouseButton (e) {\n\t if (e.touches) { return e.touches.length; }\n\t if (e.originalEvent && e.originalEvent.touches) { return e.originalEvent.touches.length; }\n\t if (e.buttons !== undefined) { return e.buttons; }\n\t if (e.which !== undefined) { return e.which; }\n\t var button = e.button;\n\t if (button !== undefined) { // see https://github.com/jquery/jquery/blob/99e8ff1baa7ae341e94bb89c3e84570c7c3ad9ea/src/event.js#L573-L575\n\t return button & 1 ? 1 : button & 2 ? 3 : (button & 4 ? 2 : 0);\n\t }\n\t }\n\n\t function preventGrabbed(e) {\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t if (shared.grabbed) {\n\t e.preventDefault();\n\t }\n\t }\n\n\t function getScroll(scrollProp, offsetProp) {\n\t if (typeof window[offsetProp] !== 'undefined') {\n\t return window[offsetProp];\n\t }\n\t if (docElm.clientHeight) {\n\t return docElm[scrollProp];\n\t }\n\t return doc.body[scrollProp];\n\t }\n\n\t function getOffset(el) { // watch performance - running each move!\n\t var rect = el.getBoundingClientRect(),\n\t scrollTop = getScroll('scrollTop', 'pageYOffset'),\n\t scrollLeft = getScroll('scrollLeft', 'pageXOffset');\n\t return {\n\t left: rect.left + scrollLeft,\n\t right: rect.right + scrollLeft,\n\t top: rect.top + scrollTop,\n\t bottom: rect.bottom + scrollTop\n\t };\n\t }\n\n\t function getRectWidth(rect) {\n\t return rect.width || (rect.right - rect.left);\n\t }\n\n\t function getRectHeight(rect) {\n\t return rect.height || (rect.bottom - rect.top);\n\t }\n\n\t function getEmptyObject() {\n\t return {};\n\t }\n\n\t function nextEl(el) {\n\t return el.nextElementSibling || manually();\n\n\t function manually() {\n\t var sibling = el;\n\t do {\n\t sibling = sibling.nextSibling;\n\t } while (sibling && sibling.nodeType !== 1);\n\t return sibling;\n\t }\n\t }\n\n\t //Cannot use angular.isElement because we need to check plain dom element, no jQlite wrapped\n\t function isElement(obj) {\n\t return (\n\t typeof HTMLElement === 'object' ? obj instanceof HTMLElement : //DOM2\n\t obj && typeof obj === 'object' && obj !== null && obj.nodeType === 1 && typeof obj.nodeName === 'string'\n\t );\n\t }\n\n\t function lookupClass(className) {\n\t var cached = shared.classesCache[className];\n\t if (cached) {\n\t cached.lastIndex = 0;\n\t } else {\n\t shared.classesCache[className] = cached = new RegExp('(?:^|\\\\s)' + className + '(?:\\\\s|$)', 'g');\n\t }\n\t return cached;\n\t }\n\n\t function addClass(el, className) {\n\t var current = el.className;\n\t if (!current.length) {\n\t el.className = className;\n\t } else if (!lookupClass(className).test(current)) {\n\t el.className += ' ' + className;\n\t }\n\t }\n\n\t function rmClass(el, className) {\n\t el.className = el.className.replace(lookupClass(className), ' ').trim();\n\t }\n\n\t function getEventHost(e) {\n\t // on touchend event, we have to use `e.changedTouches`\n\t // see http://stackoverflow.com/questions/7192563/touchend-event-properties\n\t // see https://github.com/bevacqua/dragula/issues/34\n\t if (e.targetTouches && e.targetTouches.length) {\n\t return e.targetTouches[0];\n\t }\n\t if (e.changedTouches && e.changedTouches.length) {\n\t return e.changedTouches[0];\n\t }\n\t return e;\n\t }\n\n\t function getCoord(coord, e) { // watch performance - running each move several times!\n\t var host = getEventHost(e);\n\t var missMap = {\n\t pageX: 'clientX', // IE8\n\t pageY: 'clientY' // IE8\n\t };\n\t if (coord in missMap && !(coord in host) && missMap[coord] in host) {\n\t coord = missMap[coord];\n\t }\n\n\t // Adding support for touch events, as they are not functional in the original\n\t if (!host.type || host.type.indexOf('touch') < 0) {\n\t return host[coord];\n\t } else {\n\t if (host.type.indexOf('end') === -1) {\n\t // No clientX or clientY in a touch event\n\t return host.originalEvent.touches[0][coord.replace('client', 'page')];\n\t }\n\t // Nothing should happen for touchend\n\t return false;\n\t }\n\t }\n\n\t function getParent (el) { // watch performance - running each move!\n\t return el.parentNode === document ? null : el.parentNode;\n\t }\n\n\t function isInput (el) {\n\t return el.tagName === 'INPUT' || el.tagName === 'TEXTAREA' || el.tagName === 'SELECT' || isEditable(el);\n\t }\n\n\t function isEditable (el) {\n\t if (!el) { return false; } // no parents were editable\n\t if (el.contentEditable === 'false') { return false; } // stop the lookup\n\t if (el.contentEditable === 'true') { return true; } // found a contentEditable element in the chain\n\t return isEditable(getParent(el)); // contentEditable is set to 'inherit'\n\t }\n\n\t function domIndexOf(child, parent) {\n\t return Array.prototype.indexOf.call(angular.element(parent).children(), child);\n\t }\n\n\t function fireEvent(target, e, extra) { // watch performance - running each move!\n\t if (!target) {\n\t return;\n\t }\n\t shared.extra = extra;\n\t if (target.dispatchEvent) {\n\t target.dispatchEvent(e);\n\t } else {\n\t target.fireEvent('on' + e.eventType, e);\n\t }\n\t }\n\n\t function getBool(prop, args, context){\n\t if(angular.isFunction(prop)){\n\t return !!prop.apply(context || this, args || shared);\n\t }else{\n\t return !!prop;\n\t }\n\t }\n\n\t};\n\n\tdragularService.$inject = ['$rootScope', '$compile'];\n\n\tmodule.exports = dragularService;\n\n\t/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))\n\n/***/ }\n/******/ ])\n});\n;"],"sourceRoot":"/source/"} \ No newline at end of file diff --git a/docs/dist/examples.css b/docs/dist/examples.css index 4fc9838a..7a682045 100644 --- a/docs/dist/examples.css +++ b/docs/dist/examples.css @@ -1,3 +1,25 @@ +.gu-mirror { + position: fixed !important; + margin: 0 !important; + z-index: 9999 !important; + opacity: 0.8; +} + +.gu-hide { + display: none !important; +} + +.gu-unselectable { + -webkit-user-select: none !important; + -moz-user-select: none !important; + -ms-user-select: none !important; + user-select: none !important; +} + +.gu-transit { + opacity: 0.2; +} + .gh-fork { position: fixed; top: 0; @@ -419,25 +441,3 @@ div.scrollBar { text-align: center; padding: 1px; } - -.gu-mirror { - position: fixed !important; - margin: 0 !important; - z-index: 9999 !important; - opacity: 0.8; -} - -.gu-hide { - display: none !important; -} - -.gu-unselectable { - -webkit-user-select: none !important; - -moz-user-select: none !important; - -ms-user-select: none !important; - user-select: none !important; -} - -.gu-transit { - opacity: 0.2; -} diff --git a/docs/dist/examples.js b/docs/dist/examples.js index 9305f7d4..dc667b77 100644 --- a/docs/dist/examples.js +++ b/docs/dist/examples.js @@ -1,4 +1,14 @@ -/******/ (function(modules) { // webpackBootstrap +(function webpackUniversalModuleDefinition(root, factory) { + if(typeof exports === 'object' && typeof module === 'object') + module.exports = factory(); + else if(typeof define === 'function' && define.amd) + define([], factory); + else { + var a = factory(); + for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i]; + } +})(this, function() { +return /******/ (function(modules) { // webpackBootstrap /******/ // The module cache /******/ var installedModules = {}; @@ -70,13 +80,13 @@ var NestedNgRepeatCtrl = __webpack_require__(21); var NestedNgRepeatWithModelCtrl = __webpack_require__(22); var NgRepeatCtrl = __webpack_require__(23); - var NgRepeatFilteredWithModelCtrl = __webpack_require__(23); - var NgRepeatWithModelCtrl = __webpack_require__(24); - var RemoveOnSpillCtrl = __webpack_require__(25); - var RemoveOnSpillWithModelCtrl = __webpack_require__(26); - var RevertOnSpillCtrl = __webpack_require__(27); - var ScrollingDragCtrl = __webpack_require__(28); - __webpack_require__(29); + var NgRepeatFilteredWithModelCtrl = __webpack_require__(24); + var NgRepeatWithModelCtrl = __webpack_require__(25); + var RemoveOnSpillCtrl = __webpack_require__(26); + var RemoveOnSpillWithModelCtrl = __webpack_require__(27); + var RevertOnSpillCtrl = __webpack_require__(28); + var ScrollingDragCtrl = __webpack_require__(29); + __webpack_require__(30); /** * Module Example App @@ -249,7 +259,7 @@ var dragularService = __webpack_require__(3); /** - * Dragular 4.1.0 by Luckylooke https://github.com/luckylooke/dragular + * Dragular 4.2.0 by Luckylooke https://github.com/luckylooke/dragular * Angular version of dragula https://github.com/bevacqua/dragula */ module.exports = 'dragularModule'; @@ -309,6 +319,10 @@ options.nameSpace = iAttrs.dragularNameSpace.split(' '); } + if(iAttrs.dragularOnInit){ + options.onInit = $scope.$eval(iAttrs.dragularOnInit); + } + drake = dragularService(iElm[0], options); } }; @@ -435,7 +449,8 @@ boundingBox: false, // lock movement inside this element boundaries mirrorContainer: doc.body, // element for appending mirror ignoreInputTextSelection: true, // text selection in inputs wont be considered as drag - compileItemOnDrop: false + compileItemOnDrop: false, + onInit: false // function callback called after dragular initialisation and providing drake as first argument }, drake = { containers: shared.containers, @@ -454,6 +469,10 @@ extendOptions(); processOptionsObject(); registerEvents(); + + if(o.onInit){ + o.onInit(drake); + } return drake; @@ -2225,6 +2244,83 @@ 'use strict'; + var NgRepeatFilteredWithModelCtrl = function ($scope, $element, dragularService, $filter) { + $scope.items1 = [{ + content: 'Move me, but you can only drop me in one of these containers.' + }, { + content: 'If you try to drop me somewhere other than these containers, I\'ll just come back.' + }, { + content: 'Apple 3' + }, { + content: 'Orange 4' + }, { + content: 'Orange 5' + }, { + content: 'Apple 6' + }, { + content: 'Apple 7' + }, { + content: 'Apple 8' + }]; + $scope.items2 = [{ + content: 'Apple 9' + }, { + content: 'Orange 10' + }, { + content: 'Orange 11' + }, { + content: 'Apple 12' + }, { + content: 'Orange 13' + }, { + content: 'Apple 14' + }]; + $scope.filter1query = 'Orange'; + $scope.filter2query = 'Orange'; + $scope.filteredModel1 = []; + $scope.filteredModel2 = []; + $scope.getFilteredModel = function (filteredModel, items, filterQuery) { + filteredModel.length = 0; + /* + * Following one-liner is same like: + * var filteredModelTemp = $filter('filter')(items, filterQuery); + * angular.forEach(filteredModelTemp, function(item){ + * filteredModel.push(item); + * }); + * Or like: + * var filteredModelTemp = $filter('filter')(items, filterQuery); + * for(var i; i < filteredModelTemp.length; i++){ + * filteredModel.push(filteredModelTemp[i]); + * } + * + * You cannot just assign filtered array to filteredModel like this: + * filteredModel = $filter('filter')(items, filterQuery); + * Because you would replace the array object you provide to dragular with new one. + * So dragular will continue to use the one it was provided on init. + * Hopefully I make it clear. :) + */ + [].push.apply(filteredModel, $filter('filter')(items, filterQuery)); + return filteredModel; + }; + var containers = $element.children().eq(1).children(); + dragularService.cleanEnviroment(); + dragularService([containers[0],containers[1]],{ + containersModel: [$scope.items1, $scope.items2], + containersFilteredModel: [$scope.filteredModel1, $scope.filteredModel2] + }); + }; + + NgRepeatFilteredWithModelCtrl.$inject = ['$scope', '$element', 'dragularService', '$filter']; + + module.exports = NgRepeatFilteredWithModelCtrl; + + +/***/ }, +/* 25 */ +/***/ function(module, exports) { + + 'use strict'; + var NgRepeatWithModelCtrl = function ($scope, $element, dragularService) { $scope.items = [{ content: 'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.' @@ -2255,7 +2351,7 @@ /***/ }, -/* 25 */ +/* 26 */ /***/ function(module, exports) { 'use strict'; @@ -2273,7 +2369,7 @@ /***/ }, -/* 26 */ +/* 27 */ /***/ function(module, exports) { 'use strict'; @@ -2311,7 +2407,7 @@ /***/ }, -/* 27 */ +/* 28 */ /***/ function(module, exports) { 'use strict'; @@ -2329,7 +2425,7 @@ /***/ }, -/* 28 */ +/* 29 */ /***/ function(module, exports) { /* global angular */ @@ -2374,12 +2470,12 @@ /***/ }, -/* 29 */ +/* 30 */ /***/ function(module, exports) { 'use strict'; module.exports = angular.module("templates", []).run(["$templateCache", function($templateCache) {$templateCache.put("docsInstall/docsInstall.html","

Install

\n

download dragular.js and dragular.css from dist folder

\n

OR clone git

\n
\ngit clone http://github.com/luckylooke/dragular.git\n
\n

OR use npm

\n
\n[sudo] npm install dragular\n
\n

OR use bower

\n
\nbower install dragular\n
\n

AND include files into your project

\n
\n<link href=\'styles/dragular.css\' rel=\'stylesheet\' type=\'text/css\' />\n<script src=\'scripts/dragular.js\'></script>\n
\n

AND put dragularModule into dependency array

\n
\nvar app = angular.module(\'myApp\', [\'dragularModule\', \'otherDependencies\']);\n
\n

DONE :)

\n"); - $templateCache.put("exampleBasicWithModel/exampleBasicWithModel.html","
\n

Basic - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  controller(\'BasicModel\', [\'$scope\', \'$element\', \'dragularService\', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: \'Move me, but you can only drop me in one of these containers.\'\n    }, {\n      content: \'If you try to drop me somewhere other than these containers, I\\\'ll just come back.\'\n    }, {\n      content: \'Item 3\'\n    }, {\n      content: \'Item 4\'\n    }];\n    $scope.items2 = [{\n      content: \'Item 5\'\n    }, {\n      content: \'Item 6\'\n    }, {\n      content: \'Item 7\'\n    }, {\n      content: \'Item 8\'\n    }];\n    var containers = $element.children().children();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2]\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class=\'wrapper\' ng-controller="Basic">\n    <div class=\'tableRow\'>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items1">{{item.content}}</div>\n        </div>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items2">{{item.content}}</div>\n        </div>\n    </div>\n    <div class="tableRow">\n        <div class="container">\n            <div>Items1:\n                <br/>{{items1 | json}}</div>\n        </div>\n        <div class="container">\n            <div>Items2:\n                <br/>{{items2 | json}}</div>\n        </div>\n    </div>\n</div>\n        \n      
\n
\n"); $templateCache.put("exampleBasic/exampleBasic.html","
\n

Basic

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I\'ll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I\'ll stay here.
\n
Try to click me, dragular distinguish drag from click
\n
Item 5.
\n
\n
\n
\n        \n// JS\n  controller(\'Basic\', [\'$element\', \'dragularService\', function TodoCtrl($element, dragularService) {\n    dragularService(\'.containerVertical\');\n  }])\n        \n        \n// CSS\n.clickedClass {\n  background-color: orange !important;\n}\n        \n        \n<!-- HTML -->\n  <div class=\'wrapper\' ng-controller="Basic">\n    <div class=\'containerVertical\'>\n        <div>Move me, but you can only drop me in one of these containers.</div>\n        <div>If you try to drop me somewhere other than these containers, I\'ll just come back.</div>\n        <div>Item 3.</div>\n        <div>Item 6.</div>\n    </div>\n    <div class=\'containerVertical\'>\n        <div>You can drop me in the left container, otherwise I\'ll stay here.</div>\n        <div ng-click=\"clicked = !clicked\" ng-class=\"clicked && \'clickedClass\'\">Try to click me, dragular distinguish drag from click</div>\n        <div>Item 5.</div>\n    </div>\n</div>\n        \n      
\n
\n"); + $templateCache.put("exampleBasicWithModel/exampleBasicWithModel.html","
\n

Basic - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  controller(\'BasicModel\', [\'$scope\', \'$element\', \'dragularService\', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: \'Move me, but you can only drop me in one of these containers.\'\n    }, {\n      content: \'If you try to drop me somewhere other than these containers, I\\\'ll just come back.\'\n    }, {\n      content: \'Item 3\'\n    }, {\n      content: \'Item 4\'\n    }];\n    $scope.items2 = [{\n      content: \'Item 5\'\n    }, {\n      content: \'Item 6\'\n    }, {\n      content: \'Item 7\'\n    }, {\n      content: \'Item 8\'\n    }];\n    var containers = $element.children().children();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2]\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class=\'wrapper\' ng-controller="Basic">\n    <div class=\'tableRow\'>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items1">{{item.content}}</div>\n        </div>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items2">{{item.content}}</div>\n        </div>\n    </div>\n    <div class="tableRow">\n        <div class="container">\n            <div>Items1:\n                <br/>{{items1 | json}}</div>\n        </div>\n        <div class="container">\n            <div>Items2:\n                <br/>{{items2 | json}}</div>\n        </div>\n    </div>\n</div>\n        \n      
\n
\n"); $templateCache.put("exampleBoundingBox/exampleBoundingBox.html","
\n

BoundingBox

\n \n
\n
\n
This items cannot cross its example element, just try it your selves.
\n
Item 2.
\n
Item 3.
\n
Item 6.
\n
\n
\n
This items cannot cross its example element, just try it your selves.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n  dragularService([$element.children(), {\n    boundingBox: $element\n  });\n        \n      
\n
"); $templateCache.put("exampleBoundingBoxLockX/exampleBoundingBoxLockX.html","
\n

BoundingBox and lockX

\n \n
\n
\n
\n
Items are locked in X axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
\n
item 2
\n
item 3
\n
item 4
\n
\n
\n
\n
\n        \n  dragularService([$element.children()[0].children(), {\n    boundingBox: $element.children()[0],\n    lockX: true\n  });\n        \n      
\n
"); $templateCache.put("exampleBoundingBoxLockY/exampleBoundingBoxLockY.html","
\n

BoundingBox and LockY

\n \n
\n
\n
\n
Items are locked in Y axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
\n
item 2
\n
item 3
\n
item 4
\n
item 5
\n
item 6
\n
\n
\n
\n
\n        \n  dragularService([$element.children()[0].children(), {\n    boundingBox: $element.children()[0],\n    lockY: true\n  });\n        \n      
\n
"); @@ -2399,14 +2495,16 @@ $templateCache.put("exampleNgRepeat/exampleNgRepeat.html","
\n

ngRepeat

\n \n
\n
\n
\n {{item.content}}\n
\n
\n
\n
\n        \n  // HTML:\n  <div class=\'containerVertical\'>\n    <div ng-repeat="item in items">\n      {{item.content}}\n    </div>\n  </div>\n\n  // JS:\n  dragularService($element.children());\n  $scope.items = [{\n    content: \'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.\'\n  },{\n    content: \'Item 2\'\n  },{\n    content: \'Item 3\'\n  },{\n    content: \'Item 4\'\n  }];\n        \n      
\n
\n"); $templateCache.put("exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel.html","
\n

Filtered ngRepeat - with model

\n \n
\n
\n
\n \n
\n
\n \n
\n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  .controller(\'NgRepeatFilteredWithModel\', [\'$scope\', \'$element\', \'dragularService\', \'$filter\', function TodoCtrl($scope, $element, dragularService, $filter) {\n    $scope.items1 = [{\n      content: \'Move me, but you can only drop me in one of these containers.\'\n    }, {\n      content: \'If you try to drop me somewhere other than these containers, I\\\'ll just come back.\'\n    }, {\n      content: \'Apple 3\'\n    }, {\n      content: \'Orange 4\'\n    }, {\n      content: \'Orange 5\'\n    }, {\n      content: \'Apple 6\'\n    }, {\n      content: \'Apple 7\'\n    }, {\n      content: \'Apple 8\'\n    }];\n    $scope.items2 = [{\n      content: \'Apple 9\'\n    }, {\n      content: \'Orange 10\'\n    }, {\n      content: \'Orange 11\'\n    }, {\n      content: \'Apple 12\'\n    }, {\n      content: \'Orange 13\'\n    }, {\n      content: \'Apple 14\'\n    }];\n    $scope.filter1query = \'Orange\';\n    $scope.filter2query = \'Orange\';\n    $scope.filteredModel1 = [];\n    $scope.filteredModel2 = [];\n    $scope.getFilteredModel = function (filteredModel, items, filterQuery) {\n      filteredModel.length = 0;\n      /*\n      * Following one-liner is same like:\n      *   var filteredModelTemp = $filter(\'filter\')(items, filterQuery);\n      *   angular.forEach(filteredModelTemp, function(item){\n      *     filteredModel.push(item);\n      *   });\n      * Or like:\n      *   var filteredModelTemp = $filter(\'filter\')(items, filterQuery);\n      *   for(var i; i < filteredModelTemp.length; i++){\n      *     filteredModel.push(filteredModelTemp[i]);\n      *   }\n      *\n      * You cannot just assign filtered array to filteredModel like this:\n      *   filteredModel = $filter(\'filter\')(items, filterQuery);\n      * Because you would replace the array object you provide to dragular with new one.\n      * So dragular will continue to use the one it was provided on init.\n      * Hopefully I make it clear. :)\n       */\n      [].push.apply(filteredModel, $filter(\'filter\')(items, filterQuery));\n      return filteredModel;\n    };\n    var containers = $element.children().eq(1).children();\n    dragularService.cleanEnviroment();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2],\n      containersFilteredModel: [$scope.filteredModel1, $scope.filteredModel2]\n    });\n  }]);\n\n        \n        \n<!-- HTML -->\n  <div class=\'wrapper\' ng-controller="NgRepeatFilteredWithModel">\n    <div class="tableRow">\n      <div class=\'containerVertical\'>\n        <input ng-model="filter1query" style="margin:10px 10px">\n      </div>\n      <div class=\'containerVertical\'>\n        <input ng-model="filter2query" style="margin:10px 10px">\n      </div>\n    </div>\n    <div class=\'tableRow\'>\n      <div class=\'containerVertical\'>\n        <div ng-repeat="item in getFilteredModel(filteredModel1, items1, filter1query)">{{item.content}}</div>\n      </div>\n      <div class=\'containerVertical\'>\n        <div ng-repeat="item in getFilteredModel(filteredModel2, items2, filter2query)">{{item.content}}</div>\n      </div>\n    </div>\n    <div class="tableRow">\n      <div class=\'containerVertical\'>\n        <pre>Items1:\n          <br/>{{items1 | json}}</pre>\n      </div>\n      <div class=\'containerVertical\'>\n        <pre>Items2:\n          <br/>{{items2 | json}}</pre>\n      </div>\n    </div>\n  </div>\n        \n      
\n
\n"); $templateCache.put("exampleNgRepeatWithModel/exampleNgRepeatWithModel.html","
\n

ngRepeat - with model

\n \n
\n
\n
\n
\n {{item.content}}\n \n \n
\n
\n
\n
\n
\n
Items:\n
{{items | json}}
\n
\n
\n
\n
\n    \n  // HTML:\n   <div class=\'wrapper\' ng-controller="NgRepeatWithModel">\n      <div class=\'containerVertical\'>\n        <div ng-repeat="item in items">\n          {{item.content}}\n          <button class=\'cursorDefault\' ng-click="addItem()">+</button>\n          <button class=\'cursorDefault\' ng-click="removeItem()">x</button>\n        </div>\n    </div>\n  </div>\n    \n  
\n
\n    \n  // JS:\n  controller(\'NgRepeatWithModel\', [\'$scope\', \'$element\', \'dragularService\', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items = [{\n      content: \'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.\'\n    }, {\n      content: \'Item 2\'\n    }, {\n      content: \'Item 3\'\n    }, {\n      content: \'Item 4\'\n    }];\n    dragularService($element.children().eq(0).children(), {containersModel: $scope.items});\n    $scope.addItem = function addItem() {\n      var index = $scope.items.indexOf(this.item) + 1;\n      $scope.items.splice(index, 0, {\n        content: this.item.content + \'-copy\'\n      });\n    };\n    $scope.removeItem = function removeItem() {\n      var index = $scope.items.indexOf(this.item);\n      $scope.items.splice(index, 1);\n    };\n  }])\n    \n  
\n
\n"); - $templateCache.put("exampleRemoveOnSpill/exampleRemoveOnSpill.html","
\n

Remove on spill

\n \n
\n
\n
Move me, but you can only drop me in containers.
\n
If you try to drop me somewhere other than containers, I\'ll die a fiery death.
\n
Item 3.
\n
Item 6.
\n
Item 4.
\n
Item 5.
\n
\n
\n
You can drop me in the left container.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n  dragularService([document.getElementById(single)], { removeOnSpill: true });\n        \n      
\n
"); $templateCache.put("exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel.html","
\n

Remove on spill - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  .controller(\'RemoveOnSpillWithModel\', [\'$scope\', \'$element\', \'dragularService\', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: \'Move me, but you can only drop me in containers.\'\n    }, {\n      content: \'If you try to drop me somewhere other than containers, I\\\'ll die a fiery death.\'\n    }, {\n      content: \'Item 3\'\n    }, {\n      content: \'Item 4\'\n    }];\n    $scope.items2 = [{\n      content: \'You can drop me in the left container.\'\n    }, {\n      content: \'Item 6\'\n    }, {\n      content: \'Item 7\'\n    }, {\n      content: \'Item 8\'\n    }];\n    var containers = $element.children().eq(0).children();\n    dragularService.cleanEnviroment();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2],\n      removeOnSpill: true\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class=\'wrapper\' ng-controller="Basic">\n    <div class=\'tableRow\'>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items1">{{item.content}}</div>\n        </div>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items2">{{item.content}}</div>\n        </div>\n    </div>\n    <div class="tableRow">\n        <div class="container">\n            <div>Items1:\n                <br/>{{items1 | json}}</div>\n        </div>\n        <div class="container">\n            <div>Items2:\n                <br/>{{items2 | json}}</div>\n        </div>\n    </div>\n</div>\n        \n      
\n
\n"); + $templateCache.put("exampleRemoveOnSpill/exampleRemoveOnSpill.html","
\n

Remove on spill

\n \n
\n
\n
Move me, but you can only drop me in containers.
\n
If you try to drop me somewhere other than containers, I\'ll die a fiery death.
\n
Item 3.
\n
Item 6.
\n
Item 4.
\n
Item 5.
\n
\n
\n
You can drop me in the left container.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n  dragularService([document.getElementById(single)], { removeOnSpill: true });\n        \n      
\n
"); $templateCache.put("exampleRevertOnSpill/exampleRevertOnSpill.html","
\n

Revert on spill

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I\'ll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I\'ll stay here.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n  dragularService([document.getElementById(left), document.getElementById(right)], { revertOnSpill: true });\n        \n      
\n
"); $templateCache.put("exampleScrollingDrag/exampleScrollingDrag.html","
\n

Scrolling drag

\n \n
\n
\n
up
\n
\n
Item 1.
\n
Item 2.
\n
Item 3.
\n
Item 4.
\n
Item 5.
\n
Item 6.
\n
Item 7.
\n
Item 9.
\n
Item 10.
\n
Item 11.
\n
Item 12.
\n
Item 13.
\n
\n
down
\n
\n
\n
\n
\n
Item 1.
\n
Item 2.
\n
Item 3.
\n
Item 4.
\n
Item 5.
\n
Item 6.
\n
Item 7.
\n
Item 9.
\n
Item 10.
\n
Item 11.
\n
Item 12.
\n
Item 13.
\n
\n
\n
\n
\n
\n        \n// JS\ncontroller(\'ScrollingDrag\', [\'$interval\', \'$element\', \'dragularService\', function TodoCtrl($interval, $element, dragularService) {\n\n\n    var timer,\n      leftScrollContainer = document.getElementById(\'leftScroll\'),\n      rightScrollContainer = document.getElementById(\'rightScroll\'),\n      leftTopBar = document.getElementById(\'leftTopBar\'),\n      leftBottomBar = document.getElementById(\'leftBottomBar\'),\n      rightTopBar = document.getElementById(\'rightTopBar\'),\n      rightBottomBar = document.getElementById(\'rightBottomBar\');\n\n    dragularService.cleanEnviroment();\n    dragularService([leftScrollContainer, rightScrollContainer]);\n\n    registerEvents(leftTopBar, leftScrollContainer, -5);\n    registerEvents(leftBottomBar, leftScrollContainer, 5);\n    registerEvents(rightTopBar, rightScrollContainer, -5);\n    registerEvents(rightBottomBar, rightScrollContainer, 5);\n\n    function registerEvents(bar, container, inc, speed) {\n      if (!speed) {\n        speed = 20;\n      }\n      angular.element(bar).on(\'dragularenter\', function() {\n        container.scrollTop += inc;\n        timer = $interval(function moveScroll() {\n          container.scrollTop += inc;\n        }, speed);\n      });\n      angular.element(bar).on(\'dragularleave dragularrelease\', function() {\n        $interval.cancel(timer);\n      });\n    }\n  }])\n        \n      
\n
\n        \n<!-- HTML -->\n<div ng-controller="ScrollingDrag">\n    <div class="containerVertical scrollingDrag">\n      <div class="scrollBar" id="leftTopBar">up</div>\n      <div id="leftScroll" class="scrollingDragInner">\n        <div>Item 1</div>\n        <div>Item 2</div>\n            ...\n      </div>\n      <div class="scrollBar" id="leftBottomBar">down</div>\n    </div>\n    <div class="containerVertical scrollingDrag">\n      <div class="scrollBar" id="rightTopBar">up</div>\n      <div id="rightScroll" class="scrollingDragInner">\n        <div>Item 1</div>\n        <div>Item 2</div>\n            ...\n      </div>\n      <div class="scrollBar" id="rightBottomBar">down</div>\n    </div>\n  </div>\n        \n      
\n
\n        \n// CSS\n.scrollingDrag {\n  width: 45%;\n  display: inline-block;\n}\n\n.scrollingDragInner {\n  max-height: 200px;\n  overflow-y: auto;\n}\n\n#rightTopBar,\n#rightBottomBar {\n  background: transparent;\n  position: relative;\n  height: 20px;\n}\n\n#rightTopBar {\n  top: 10px;\n}\n\n#rightBottomBar {\n  bottom: 10px;\n}\n\ndiv.scrollBar {\n  background: yellow;\n  text-align: center;\n  padding: 1px;\n}\n\n        \n      
\n
\n"); $templateCache.put("partials/partial-contribute.html","
\n
\n
\n \n
\n
\n
\n"); $templateCache.put("partials/partial-docs.html","
\n
\n
\n \n
\n \n
\n

\n \n

\n \n
\n
\n \n
\n \n
\n"); - $templateCache.put("partials/partial-home.html","
\n
\n \n
\n
\n

DRAGULAR

\n

Angular drag&drop based on dragula.

\n

Live examples in docs

\n
\n
\n
\n

Browser support includes every sane browser and **IE7+**. _(Granted you polyfill the functional `Array` methods in ES5)_

\n

Inspiration

\n

I am working on huge angular project and I am using several drag&drop libraries in it, one for UI, one for lists, etc.. I want to use one full-featured drag&drop library for whole project. As I could not find any suitable, I decided to create one. I have choosen great library dragula by Nicolas Bevacqua as my starting point, make it more angular and started to put features in it! If you wish light-weight angular version of dragula, there is official angular version of dragula.

\n

Actual version 4.1.0 is based on dragula 3.6.3 and tested with angular 1.4.9.

\n

Differences of dragular (against dragula)

\n
    \n
  • replaced dragula crossvent with angulars event binding
  • \n
  • replaced dragula contra.emitter with $scope.$emit if scope provided in options (options.scope)
  • \n
  • provided as service or directive dragular where options can be passed via atribute dragular
  • \n
  • automatic direction if not provided in options, instead of default vertical
  • \n
  • accepting arraylike objects as containers array (jQuery, jQlite collections etc..)
  • \n
  • accepting custom classes via option.classes
  • \n
  • namespaced containers groups available via option.nameSpace (containers in same nameSpace cooperate)
  • \n
  • boundingBox (dragging element can me moved only in specific area)
  • \n
  • lockX/Y (dragging element can me moved only in specific direction)
  • \n
  • DOM can be synced with scope model
  • \n
  • support css selectors to define containers
  • \n
  • added syntax highlighter to example codes
  • \n
  • etc..
  • \n
\n

Todo

\n
    \n
  • improve docs
  • \n
\n

Features

\n
    \n
  • provided as service and also as directive
  • \n
  • Super easy to set up
  • \n
  • No bloated dependencies
  • \n
  • Figures out sort order on its own
  • \n
  • A shadow where the item would be dropped offers visual feedback
  • \n
  • Touch events!
  • \n
\n

For installation, usage and examples go to docs

\n
\n
\n \n
\n \n
\n \n
\n"); + $templateCache.put("partials/partial-home.html","
\n
\n \n
\n
\n

DRAGULAR

\n

Angular drag&drop based on dragula.

\n

Live examples in docs

\n
\n
\n
\n

Browser support includes every sane browser and **IE7+**. _(Granted you polyfill the functional `Array` methods in ES5)_

\n

Inspiration

\n

I am working on huge angular project and I am using several drag&drop libraries in it, one for UI, one for lists, etc.. I want to use one full-featured drag&drop library for whole project. As I could not find any suitable, I decided to create one. I have choosen great library dragula by Nicolas Bevacqua as my starting point, make it more angular and started to put features in it! If you wish light-weight angular version of dragula, there is official angular version of dragula.

\n

Actual version 4.2.0 is based on dragula 3.6.3 and tested with angular 1.5.5.

\n

Differences of dragular (against dragula)

\n
    \n
  • replaced dragula crossvent with angulars event binding
  • \n
  • replaced dragula contra.emitter with $scope.$emit if scope provided in options (options.scope)
  • \n
  • provided as service or directive dragular where options can be passed via atribute dragular
  • \n
  • automatic direction if not provided in options, instead of default vertical
  • \n
  • accepting arraylike objects as containers array (jQuery, jQlite collections etc..)
  • \n
  • accepting custom classes via option.classes
  • \n
  • namespaced containers groups available via option.nameSpace (containers in same nameSpace cooperate)
  • \n
  • boundingBox (dragging element can me moved only in specific area)
  • \n
  • lockX/Y (dragging element can me moved only in specific direction)
  • \n
  • DOM can be synced with scope model
  • \n
  • support css selectors to define containers
  • \n
  • added syntax highlighter to example codes
  • \n
  • etc..
  • \n
\n

Todo

\n
    \n
  • improve docs
  • \n
\n

Features

\n
    \n
  • provided as service and also as directive
  • \n
  • Super easy to set up
  • \n
  • No bloated dependencies
  • \n
  • Figures out sort order on its own
  • \n
  • A shadow where the item would be dropped offers visual feedback
  • \n
  • Touch events!
  • \n
\n

For installation, usage and examples go to docs

\n
\n
\n \n
\n \n
\n \n
\n"); $templateCache.put("partials/autogenerated/contribute.html","

How to contribute

\n

It's important to us that you feel you can contribute towards the evolution of Dragular. This can take many forms: from helping to fix bugs or improve the docs, to adding in new features to the source. This guide should help you in making that process as smooth as possible.

\n

Before contributing, please read the code of conduct.

\n

Reporting issues

\n

GitHub Issues is the place to report bugs you may have found in either the core library or any of the examples that are part of the repository. When submitting a bug please do the following:

\n

1. Search for existing issues. Your bug may have already been fixed or addressed in a development branch version of Dragular, so be sure to search the issues first before putting in a duplicate issue.

\n

2. Not sure if it's a bug?. Then please ask via issues and tag it [question].

\n

3. Create an isolated and reproducible test case. If you are reporting a bug, make sure you also have a minimal, runnable, code example that reproduces the problem you have.

\n

4. Include a live example. After narrowing your code down to only the problem areas, make use of jsFiddle, jsBin, or a link to your live site so that we can view a live example of the problem. (you can start by forking this fiddle)

\n

5. Share as much information as possible. Include browser version affected, your OS, version of the library, steps to reproduce, etc. "X isn't working!!!1!" will probably just be closed.

\n

Dev vs. Master

\n

The dev branch of Dragular is our 'current working' version. It is always ahead of the master branch in terms of features and fixes. However it's also bleeding-edge and experimental and we cannot and do not guarantee it will compile or work for you. Very often we have to break things for a few days while we rebuild and patch. So by all means please export the dev branch and contribute towards it, indeed that is where all Pull Requests should be sent, but do so understanding the API may change beneath you.

\n

Making Changes

\n

To take advantage of our npm build script and jshint config it will be easiest for you if you have node.js installed locally.

\n

You can download node.js from nodejs.org.

\n

After that you can clone the repository and run npm i inside the cloned folder. This will install dependencies necessary for building the project. For development workflow automation dragular uses gulp >= 3.9.0. Before starting development, make sure that gulp is installed on your machine globally: npm i -g gulp.

\n

Developing

\n

There are several gulp tasks that are used for generating different builds:

\n
    \n
  • gulp dev - Serves files with BrowserSync server, watches & automatically refreshes connected browsers on changes, generates non-minified but concatenated styles & scripts from the dragular source.
  • \n
  • gulp dev:docs - Does exactly the same as gulp dev, except it works with the documentation source.
  • \n
  • gulp build - Concatenates and minifies dragular source files.
  • \n
  • gulp build:docs - Concatenates and minifies documentation source files.
  • \n
\n

Linting

\n
    \n
  • gulp lint & gulp lint:docs - Lint JavaScript files.
  • \n
\n

Making a pull request

\n

Once that is ready, make your changes and submit a Pull Request:

\n
    \n
  • Send Pull Requests to the dev branch. All Pull Requests must be sent to the dev branch, master is the latest release and PRs to that branch will be closed.

    \n
  • \n
  • Ensure changes are jshint validated. Our JSHint configuration file is provided in the repository and you should check against it before submitting.

    \n
  • \n
  • Only commit relevant changes. Don't include changes that are not directly relevant to the fix you are making. The more focused a PR is, the faster it will get attention and be merged. Extra files changing only whitespace or trash files will likely get your PR closed.

    \n
  • \n
\n

Dependencies for building from source and running tests:

\n

Coding style preferences are not contributions

\n

If your PR is doing little more than changing the Dragular source code into a format / coding style that you prefer then we will automatically close it. All PRs must adhere to the coding style already set-out across the lines of code in Dragular. Your personal preferences for how things should "look" or be structured do not apply here, sorry. PRs should fix bugs, fix documentation or add features. No changes for the sake of change.

\n

I don't really like git / node.js, but I can fix this bug

\n

That is fine too. While Pull Requests are the best thing in the world for us, they are not the only way to help. You're welcome to post fixes to our forum or even just email them to us. All we ask is that you still adhere to the guidelines presented here re: JSHint, etc.

\n");}]); /***/ } -/******/ ]); \ No newline at end of file +/******/ ]) +}); +; \ No newline at end of file diff --git a/docs/dist/examples.min.css b/docs/dist/examples.min.css new file mode 100644 index 00000000..9c3ce2cf --- /dev/null +++ b/docs/dist/examples.min.css @@ -0,0 +1,5 @@ +.gh-fork,hr,img{border:0}.jumbotron,footer{text-align:center}.label,sub,sup{vertical-align:baseline}.navbar-fixed-bottom .navbar-collapse,.navbar-fixed-top .navbar-collapse,.pre-scrollable{max-height:340px}.gu-mirror{position:fixed!important;margin:0!important;z-index:9999!important;opacity:.8}.gu-hide{display:none!important}.gu-transit{opacity:.2}.gh-fork{position:fixed;top:0;right:0;z-index:10000}.wrapper{display:table;table-layout:fixed;width:100%}.containerVertical{display:table-cell;background-color:rgba(255,255,255,.2);width:50%}.containerHorizontal{display:table-row;background-color:rgba(255,255,255,.2)}.containerHorizontal div,.containerVertical:nth-child(odd){background-color:rgba(0,0,0,.2)}.containerHorizontal div{border-spacing:5px;display:table-cell;margin:10px;padding:10px;-webkit-transition:opacity .4s ease-in-out;transition:opacity .4s ease-in-out;cursor:move;cursor:grab;cursor:-webkit-grab}.width25{width:25%}.containerVertical:nth-child(even){background-color:rgba(0,0,0,.4)}.containerVertical pre{border:0;background-color:transparent}label b{color:#ff8c00}.containerVertical div,.gu-mirror{margin:10px;padding:10px;background-color:rgba(0,0,0,.2);-webkit-transition:opacity .4s ease-in-out;transition:opacity .4s ease-in-out;cursor:move;cursor:grab;cursor:-webkit-grab}.gu-unselectable{-webkit-user-select:none!important;-moz-user-select:none!important;-ms-user-select:none!important;user-select:none!important;cursor:grabbing;cursor:-webkit-grabbing}.containerVertical .ex-moved{background-color:#e74c3c}.handle{padding:0 5px;margin-right:5px;background-color:rgba(0,0,0,.4);cursor:move}.custom-green-mirror{background-color:#56AB1C;padding:10px;cursor:move;cursor:grab;cursor:-webkit-grab;opacity:.8;position:fixed!important;margin:0!important;z-index:9999!important}.containerVertical.width25.gu-over-active.gu-over-accept{background-color:green!important}.containerVertical.width25.gu-over-active.gu-over-decline{background-color:red!important}pre.gu-over-active.gu-over-decline{background-color:#ff0!important}div.limitBox{margin:0;padding:0;background:0 0}.cursorDefault{cursor:default!important}.exampleRow{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row}.exampleCell{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1}.exampleCell,.exampleRow{margin:10px;padding:10px;background-color:rgba(0,0,0,.2);cursor:move;cursor:grab;cursor:-webkit-grab}body,figure{margin:0}.tableRow{display:table-row}body,html{overflow-x:hidden}body{padding-top:70px}footer{padding:30px 0}@media screen and (max-width:767px){.gh-fork{top:50px!important;z-index:auto}.row-offcanvas{position:relative;-webkit-transition:all .25s ease-out;transition:all .25s ease-out}.row-offcanvas-right{right:0}.row-offcanvas-left{left:0}.row-offcanvas-right .sidebar-offcanvas{right:-50%}.row-offcanvas-left .sidebar-offcanvas{left:-50%}.row-offcanvas-right.active{right:50%}.row-offcanvas-left.active{left:50%}.sidebar-offcanvas{position:absolute!important;top:0;width:50%}}/*! + * Bootstrap v3.3.5 (http://getbootstrap.com) + * Copyright 2011-2015 Twitter, Inc. + * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) + *//*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}article,aside,details,figcaption,figure,footer,header,hgroup,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background-color:transparent}a:active,a:hover{outline:0}b,optgroup,strong{font-weight:700}dfn{font-style:italic}h1{margin:.67em 0}mark{color:#000;background:#ff0}sub,sup{position:relative;font-size:75%;line-height:0}sup{top:-.5em}sub{bottom:-.25em}img{vertical-align:middle}svg:not(:root){overflow:hidden}hr{height:0;-webkit-box-sizing:content-box;box-sizing:content-box}pre,textarea{overflow:auto}code,kbd,pre,samp{font-size:1em}button,input,optgroup,select,textarea{margin:0;font:inherit;color:inherit}.glyphicon,address{font-style:normal}button{overflow:visible}button,select{text-transform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{padding:0;border:0}input[type=checkbox],input[type=radio]{-webkit-box-sizing:border-box;box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}table{border-spacing:0;border-collapse:collapse}td,th{padding:0}/*! Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css */@media print{blockquote,img,pre,tr{page-break-inside:avoid}*,:after,:before{color:#000!important;text-shadow:none!important;background:0 0!important;-webkit-box-shadow:none!important;box-shadow:none!important}a,a:visited{text-decoration:underline}a[href]:after{content:" (" attr(href) ")"}abbr[title]:after{content:" (" attr(title) ")"}a[href^="javascript:"]:after,a[href^="#"]:after{content:""}blockquote,pre{border:1px solid #999}thead{display:table-header-group}img{max-width:100%!important}h2,h3,p{orphans:3;widows:3}h2,h3{page-break-after:avoid}.navbar{display:none}.btn>.caret,.dropup>.btn>.caret{border-top-color:#000!important}.label{border:1px solid #000}.table{border-collapse:collapse!important}.table td,.table th{background-color:#fff!important}.table-bordered td,.table-bordered th{border:1px solid #ddd!important}}.btn,.btn-danger.active,.btn-danger:active,.btn-default.active,.btn-default:active,.btn-info.active,.btn-info:active,.btn-primary.active,.btn-primary:active,.btn-warning.active,.btn-warning:active,.btn.active,.btn:active,.dropdown-menu>.disabled>a:focus,.dropdown-menu>.disabled>a:hover,.form-control,.navbar-toggle,.open>.dropdown-toggle.btn-danger,.open>.dropdown-toggle.btn-default,.open>.dropdown-toggle.btn-info,.open>.dropdown-toggle.btn-primary,.open>.dropdown-toggle.btn-warning{background-image:none}.img-thumbnail,body{background-color:#fff}.img-rounded,.input-lg{-webkit-border-radius:6px}@font-face{font-family:'Glyphicons Halflings';src:url(../fonts/glyphicons-halflings-regular.eot);src:url(../fonts/glyphicons-halflings-regular.eot?#iefix) format('embedded-opentype'),url(../fonts/glyphicons-halflings-regular.woff2) format('woff2'),url(../fonts/glyphicons-halflings-regular.woff) format('woff'),url(../fonts/glyphicons-halflings-regular.ttf) format('truetype'),url(../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular) format('svg')}.glyphicon{position:relative;top:1px;display:inline-block;font-family:'Glyphicons Halflings';font-weight:400;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.glyphicon-asterisk:before{content:"\2a"}.glyphicon-plus:before{content:"\2b"}.glyphicon-eur:before,.glyphicon-euro:before{content:"\20ac"}.glyphicon-minus:before{content:"\2212"}.glyphicon-cloud:before{content:"\2601"}.glyphicon-envelope:before{content:"\2709"}.glyphicon-pencil:before{content:"\270f"}.glyphicon-glass:before{content:"\e001"}.glyphicon-music:before{content:"\e002"}.glyphicon-search:before{content:"\e003"}.glyphicon-heart:before{content:"\e005"}.glyphicon-star:before{content:"\e006"}.glyphicon-star-empty:before{content:"\e007"}.glyphicon-user:before{content:"\e008"}.glyphicon-film:before{content:"\e009"}.glyphicon-th-large:before{content:"\e010"}.glyphicon-th:before{content:"\e011"}.glyphicon-th-list:before{content:"\e012"}.glyphicon-ok:before{content:"\e013"}.glyphicon-remove:before{content:"\e014"}.glyphicon-zoom-in:before{content:"\e015"}.glyphicon-zoom-out:before{content:"\e016"}.glyphicon-off:before{content:"\e017"}.glyphicon-signal:before{content:"\e018"}.glyphicon-cog:before{content:"\e019"}.glyphicon-trash:before{content:"\e020"}.glyphicon-home:before{content:"\e021"}.glyphicon-file:before{content:"\e022"}.glyphicon-time:before{content:"\e023"}.glyphicon-road:before{content:"\e024"}.glyphicon-download-alt:before{content:"\e025"}.glyphicon-download:before{content:"\e026"}.glyphicon-upload:before{content:"\e027"}.glyphicon-inbox:before{content:"\e028"}.glyphicon-play-circle:before{content:"\e029"}.glyphicon-repeat:before{content:"\e030"}.glyphicon-refresh:before{content:"\e031"}.glyphicon-list-alt:before{content:"\e032"}.glyphicon-lock:before{content:"\e033"}.glyphicon-flag:before{content:"\e034"}.glyphicon-headphones:before{content:"\e035"}.glyphicon-volume-off:before{content:"\e036"}.glyphicon-volume-down:before{content:"\e037"}.glyphicon-volume-up:before{content:"\e038"}.glyphicon-qrcode:before{content:"\e039"}.glyphicon-barcode:before{content:"\e040"}.glyphicon-tag:before{content:"\e041"}.glyphicon-tags:before{content:"\e042"}.glyphicon-book:before{content:"\e043"}.glyphicon-bookmark:before{content:"\e044"}.glyphicon-print:before{content:"\e045"}.glyphicon-camera:before{content:"\e046"}.glyphicon-font:before{content:"\e047"}.glyphicon-bold:before{content:"\e048"}.glyphicon-italic:before{content:"\e049"}.glyphicon-text-height:before{content:"\e050"}.glyphicon-text-width:before{content:"\e051"}.glyphicon-align-left:before{content:"\e052"}.glyphicon-align-center:before{content:"\e053"}.glyphicon-align-right:before{content:"\e054"}.glyphicon-align-justify:before{content:"\e055"}.glyphicon-list:before{content:"\e056"}.glyphicon-indent-left:before{content:"\e057"}.glyphicon-indent-right:before{content:"\e058"}.glyphicon-facetime-video:before{content:"\e059"}.glyphicon-picture:before{content:"\e060"}.glyphicon-map-marker:before{content:"\e062"}.glyphicon-adjust:before{content:"\e063"}.glyphicon-tint:before{content:"\e064"}.glyphicon-edit:before{content:"\e065"}.glyphicon-share:before{content:"\e066"}.glyphicon-check:before{content:"\e067"}.glyphicon-move:before{content:"\e068"}.glyphicon-step-backward:before{content:"\e069"}.glyphicon-fast-backward:before{content:"\e070"}.glyphicon-backward:before{content:"\e071"}.glyphicon-play:before{content:"\e072"}.glyphicon-pause:before{content:"\e073"}.glyphicon-stop:before{content:"\e074"}.glyphicon-forward:before{content:"\e075"}.glyphicon-fast-forward:before{content:"\e076"}.glyphicon-step-forward:before{content:"\e077"}.glyphicon-eject:before{content:"\e078"}.glyphicon-chevron-left:before{content:"\e079"}.glyphicon-chevron-right:before{content:"\e080"}.glyphicon-plus-sign:before{content:"\e081"}.glyphicon-minus-sign:before{content:"\e082"}.glyphicon-remove-sign:before{content:"\e083"}.glyphicon-ok-sign:before{content:"\e084"}.glyphicon-question-sign:before{content:"\e085"}.glyphicon-info-sign:before{content:"\e086"}.glyphicon-screenshot:before{content:"\e087"}.glyphicon-remove-circle:before{content:"\e088"}.glyphicon-ok-circle:before{content:"\e089"}.glyphicon-ban-circle:before{content:"\e090"}.glyphicon-arrow-left:before{content:"\e091"}.glyphicon-arrow-right:before{content:"\e092"}.glyphicon-arrow-up:before{content:"\e093"}.glyphicon-arrow-down:before{content:"\e094"}.glyphicon-share-alt:before{content:"\e095"}.glyphicon-resize-full:before{content:"\e096"}.glyphicon-resize-small:before{content:"\e097"}.glyphicon-exclamation-sign:before{content:"\e101"}.glyphicon-gift:before{content:"\e102"}.glyphicon-leaf:before{content:"\e103"}.glyphicon-fire:before{content:"\e104"}.glyphicon-eye-open:before{content:"\e105"}.glyphicon-eye-close:before{content:"\e106"}.glyphicon-warning-sign:before{content:"\e107"}.glyphicon-plane:before{content:"\e108"}.glyphicon-calendar:before{content:"\e109"}.glyphicon-random:before{content:"\e110"}.glyphicon-comment:before{content:"\e111"}.glyphicon-magnet:before{content:"\e112"}.glyphicon-chevron-up:before{content:"\e113"}.glyphicon-chevron-down:before{content:"\e114"}.glyphicon-retweet:before{content:"\e115"}.glyphicon-shopping-cart:before{content:"\e116"}.glyphicon-folder-close:before{content:"\e117"}.glyphicon-folder-open:before{content:"\e118"}.glyphicon-resize-vertical:before{content:"\e119"}.glyphicon-resize-horizontal:before{content:"\e120"}.glyphicon-hdd:before{content:"\e121"}.glyphicon-bullhorn:before{content:"\e122"}.glyphicon-bell:before{content:"\e123"}.glyphicon-certificate:before{content:"\e124"}.glyphicon-thumbs-up:before{content:"\e125"}.glyphicon-thumbs-down:before{content:"\e126"}.glyphicon-hand-right:before{content:"\e127"}.glyphicon-hand-left:before{content:"\e128"}.glyphicon-hand-up:before{content:"\e129"}.glyphicon-hand-down:before{content:"\e130"}.glyphicon-circle-arrow-right:before{content:"\e131"}.glyphicon-circle-arrow-left:before{content:"\e132"}.glyphicon-circle-arrow-up:before{content:"\e133"}.glyphicon-circle-arrow-down:before{content:"\e134"}.glyphicon-globe:before{content:"\e135"}.glyphicon-wrench:before{content:"\e136"}.glyphicon-tasks:before{content:"\e137"}.glyphicon-filter:before{content:"\e138"}.glyphicon-briefcase:before{content:"\e139"}.glyphicon-fullscreen:before{content:"\e140"}.glyphicon-dashboard:before{content:"\e141"}.glyphicon-paperclip:before{content:"\e142"}.glyphicon-heart-empty:before{content:"\e143"}.glyphicon-link:before{content:"\e144"}.glyphicon-phone:before{content:"\e145"}.glyphicon-pushpin:before{content:"\e146"}.glyphicon-usd:before{content:"\e148"}.glyphicon-gbp:before{content:"\e149"}.glyphicon-sort:before{content:"\e150"}.glyphicon-sort-by-alphabet:before{content:"\e151"}.glyphicon-sort-by-alphabet-alt:before{content:"\e152"}.glyphicon-sort-by-order:before{content:"\e153"}.glyphicon-sort-by-order-alt:before{content:"\e154"}.glyphicon-sort-by-attributes:before{content:"\e155"}.glyphicon-sort-by-attributes-alt:before{content:"\e156"}.glyphicon-unchecked:before{content:"\e157"}.glyphicon-expand:before{content:"\e158"}.glyphicon-collapse-down:before{content:"\e159"}.glyphicon-collapse-up:before{content:"\e160"}.glyphicon-log-in:before{content:"\e161"}.glyphicon-flash:before{content:"\e162"}.glyphicon-log-out:before{content:"\e163"}.glyphicon-new-window:before{content:"\e164"}.glyphicon-record:before{content:"\e165"}.glyphicon-save:before{content:"\e166"}.glyphicon-open:before{content:"\e167"}.glyphicon-saved:before{content:"\e168"}.glyphicon-import:before{content:"\e169"}.glyphicon-export:before{content:"\e170"}.glyphicon-send:before{content:"\e171"}.glyphicon-floppy-disk:before{content:"\e172"}.glyphicon-floppy-saved:before{content:"\e173"}.glyphicon-floppy-remove:before{content:"\e174"}.glyphicon-floppy-save:before{content:"\e175"}.glyphicon-floppy-open:before{content:"\e176"}.glyphicon-credit-card:before{content:"\e177"}.glyphicon-transfer:before{content:"\e178"}.glyphicon-cutlery:before{content:"\e179"}.glyphicon-header:before{content:"\e180"}.glyphicon-compressed:before{content:"\e181"}.glyphicon-earphone:before{content:"\e182"}.glyphicon-phone-alt:before{content:"\e183"}.glyphicon-tower:before{content:"\e184"}.glyphicon-stats:before{content:"\e185"}.glyphicon-sd-video:before{content:"\e186"}.glyphicon-hd-video:before{content:"\e187"}.glyphicon-subtitles:before{content:"\e188"}.glyphicon-sound-stereo:before{content:"\e189"}.glyphicon-sound-dolby:before{content:"\e190"}.glyphicon-sound-5-1:before{content:"\e191"}.glyphicon-sound-6-1:before{content:"\e192"}.glyphicon-sound-7-1:before{content:"\e193"}.glyphicon-copyright-mark:before{content:"\e194"}.glyphicon-registration-mark:before{content:"\e195"}.glyphicon-cloud-download:before{content:"\e197"}.glyphicon-cloud-upload:before{content:"\e198"}.glyphicon-tree-conifer:before{content:"\e199"}.glyphicon-tree-deciduous:before{content:"\e200"}.glyphicon-cd:before{content:"\e201"}.glyphicon-save-file:before{content:"\e202"}.glyphicon-open-file:before{content:"\e203"}.glyphicon-level-up:before{content:"\e204"}.glyphicon-copy:before{content:"\e205"}.glyphicon-paste:before{content:"\e206"}.glyphicon-alert:before{content:"\e209"}.glyphicon-equalizer:before{content:"\e210"}.glyphicon-king:before{content:"\e211"}.glyphicon-queen:before{content:"\e212"}.glyphicon-pawn:before{content:"\e213"}.glyphicon-bishop:before{content:"\e214"}.glyphicon-knight:before{content:"\e215"}.glyphicon-baby-formula:before{content:"\e216"}.glyphicon-tent:before{content:"\26fa"}.glyphicon-blackboard:before{content:"\e218"}.glyphicon-bed:before{content:"\e219"}.glyphicon-apple:before{content:"\f8ff"}.glyphicon-erase:before{content:"\e221"}.glyphicon-hourglass:before{content:"\231b"}.glyphicon-lamp:before{content:"\e223"}.glyphicon-duplicate:before{content:"\e224"}.glyphicon-piggy-bank:before{content:"\e225"}.glyphicon-scissors:before{content:"\e226"}.glyphicon-bitcoin:before,.glyphicon-btc:before,.glyphicon-xbt:before{content:"\e227"}.glyphicon-jpy:before,.glyphicon-yen:before{content:"\00a5"}.glyphicon-rub:before,.glyphicon-ruble:before{content:"\20bd"}.glyphicon-scale:before{content:"\e230"}.glyphicon-ice-lolly:before{content:"\e231"}.glyphicon-ice-lolly-tasted:before{content:"\e232"}.glyphicon-education:before{content:"\e233"}.glyphicon-option-horizontal:before{content:"\e234"}.glyphicon-option-vertical:before{content:"\e235"}.glyphicon-menu-hamburger:before{content:"\e236"}.glyphicon-modal-window:before{content:"\e237"}.glyphicon-oil:before{content:"\e238"}.glyphicon-grain:before{content:"\e239"}.glyphicon-sunglasses:before{content:"\e240"}.glyphicon-text-size:before{content:"\e241"}.glyphicon-text-color:before{content:"\e242"}.glyphicon-text-background:before{content:"\e243"}.glyphicon-object-align-top:before{content:"\e244"}.glyphicon-object-align-bottom:before{content:"\e245"}.glyphicon-object-align-horizontal:before{content:"\e246"}.glyphicon-object-align-left:before{content:"\e247"}.glyphicon-object-align-vertical:before{content:"\e248"}.glyphicon-object-align-right:before{content:"\e249"}.glyphicon-triangle-right:before{content:"\e250"}.glyphicon-triangle-left:before{content:"\e251"}.glyphicon-triangle-bottom:before{content:"\e252"}.glyphicon-triangle-top:before{content:"\e253"}.glyphicon-console:before{content:"\e254"}.glyphicon-superscript:before{content:"\e255"}.glyphicon-subscript:before{content:"\e256"}.glyphicon-menu-left:before{content:"\e257"}.glyphicon-menu-right:before{content:"\e258"}.glyphicon-menu-down:before{content:"\e259"}.glyphicon-menu-up:before{content:"\e260"}*,:after,:before{-webkit-box-sizing:border-box;box-sizing:border-box}html{font-size:10px;-webkit-tap-highlight-color:transparent}body{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:1.42857143;color:#333}button,input,select,textarea{font-family:inherit;font-size:inherit;line-height:inherit}a{color:#337ab7;text-decoration:none}a:focus,a:hover{color:#23527c;text-decoration:underline}a:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.carousel-inner>.item>a>img,.carousel-inner>.item>img,.img-responsive,.thumbnail a>img,.thumbnail>img{display:block;max-width:100%;height:auto}.img-rounded{border-radius:6px}.img-thumbnail{display:inline-block;max-width:100%;height:auto;padding:4px;line-height:1.42857143;border:1px solid #ddd;-webkit-border-radius:4px;border-radius:4px;-webkit-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.img-circle{-webkit-border-radius:50%;border-radius:50%}hr{margin-top:20px;margin-bottom:20px;border-top:1px solid #eee}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto}[role=button]{cursor:pointer}.h1,.h2,.h3,.h4,.h5,.h6,h1,h2,h3,h4,h5,h6{font-family:inherit;font-weight:500;line-height:1.1;color:inherit}.h1 .small,.h1 small,.h2 .small,.h2 small,.h3 .small,.h3 small,.h4 .small,.h4 small,.h5 .small,.h5 small,.h6 .small,.h6 small,h1 .small,h1 small,h2 .small,h2 small,h3 .small,h3 small,h4 .small,h4 small,h5 .small,h5 small,h6 .small,h6 small{font-weight:400;line-height:1;color:#777}.h1,.h2,.h3,h1,h2,h3{margin-top:20px;margin-bottom:10px}.h1 .small,.h1 small,.h2 .small,.h2 small,.h3 .small,.h3 small,h1 .small,h1 small,h2 .small,h2 small,h3 .small,h3 small{font-size:65%}.h4,.h5,.h6,h4,h5,h6{margin-top:10px;margin-bottom:10px}.h4 .small,.h4 small,.h5 .small,.h5 small,.h6 .small,.h6 small,h4 .small,h4 small,h5 .small,h5 small,h6 .small,h6 small{font-size:75%}.h1,h1{font-size:36px}.h2,h2{font-size:30px}.h3,h3{font-size:24px}.h4,h4{font-size:18px}.h5,h5{font-size:14px}.h6,h6{font-size:12px}p{margin:0 0 10px}.lead{margin-bottom:20px;font-size:16px;font-weight:300;line-height:1.4}dt,kbd kbd,label{font-weight:700}address,blockquote .small,blockquote footer,blockquote small,dd,dt,pre{line-height:1.42857143}@media (min-width:768px){.lead{font-size:21px}}.small,small{font-size:85%}.mark,mark{padding:.2em;background-color:#fcf8e3}.list-inline,.list-unstyled{padding-left:0;list-style:none}.text-left{text-align:left}.text-right{text-align:right}.text-center{text-align:center}.text-justify{text-align:justify}.text-nowrap{white-space:nowrap}.text-lowercase{text-transform:lowercase}.text-uppercase{text-transform:uppercase}.text-capitalize{text-transform:capitalize}.text-muted{color:#777}.text-primary{color:#337ab7}a.text-primary:focus,a.text-primary:hover{color:#286090}.text-success{color:#3c763d}a.text-success:focus,a.text-success:hover{color:#2b542c}.text-info{color:#31708f}a.text-info:focus,a.text-info:hover{color:#245269}.text-warning{color:#8a6d3b}a.text-warning:focus,a.text-warning:hover{color:#66512c}.text-danger{color:#a94442}a.text-danger:focus,a.text-danger:hover{color:#843534}.bg-primary{color:#fff;background-color:#337ab7}a.bg-primary:focus,a.bg-primary:hover{background-color:#286090}.bg-success{background-color:#dff0d8}a.bg-success:focus,a.bg-success:hover{background-color:#c1e2b3}.bg-info{background-color:#d9edf7}a.bg-info:focus,a.bg-info:hover{background-color:#afd9ee}.bg-warning{background-color:#fcf8e3}a.bg-warning:focus,a.bg-warning:hover{background-color:#f7ecb5}.bg-danger{background-color:#f2dede}a.bg-danger:focus,a.bg-danger:hover{background-color:#e4b9b9}pre code,table{background-color:transparent}.page-header{padding-bottom:9px;margin:40px 0 20px;border-bottom:1px solid #eee}dl,ol,ul{margin-top:0}blockquote ol:last-child,blockquote p:last-child,blockquote ul:last-child,ol ol,ol ul,ul ol,ul ul{margin-bottom:0}address,dl{margin-bottom:20px}ol,ul{margin-bottom:10px}.list-inline{margin-left:-5px}.list-inline>li{display:inline-block;padding-right:5px;padding-left:5px}dd{margin-left:0}@media (min-width:768px){.dl-horizontal dt{float:left;width:160px;overflow:hidden;clear:left;text-align:right;text-overflow:ellipsis;white-space:nowrap}.dl-horizontal dd{margin-left:180px}.container{width:750px}}abbr[data-original-title],abbr[title]{cursor:help;border-bottom:1px dotted #777}.initialism{font-size:90%;text-transform:uppercase}blockquote{padding:10px 20px;margin:0 0 20px;font-size:17.5px;border-left:5px solid #eee}blockquote .small,blockquote footer,blockquote small{display:block;font-size:80%;color:#777}legend,pre{display:block;color:#333}blockquote .small:before,blockquote footer:before,blockquote small:before{content:'\2014 \00A0'}.blockquote-reverse,blockquote.pull-right{padding-right:15px;padding-left:0;text-align:right;border-right:5px solid #eee;border-left:0}code,kbd{padding:2px 4px;font-size:90%}caption,th{text-align:left}.blockquote-reverse .small:before,.blockquote-reverse footer:before,.blockquote-reverse small:before,blockquote.pull-right .small:before,blockquote.pull-right footer:before,blockquote.pull-right small:before{content:''}.blockquote-reverse .small:after,.blockquote-reverse footer:after,.blockquote-reverse small:after,blockquote.pull-right .small:after,blockquote.pull-right footer:after,blockquote.pull-right small:after{content:'\00A0 \2014'}code,kbd,pre,samp{font-family:Menlo,Monaco,Consolas,"Courier New",monospace}code{color:#c7254e;background-color:#f9f2f4;-webkit-border-radius:4px;border-radius:4px}.input-sm,kbd{-webkit-border-radius:3px}kbd{color:#fff;background-color:#333;border-radius:3px;-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,.25);box-shadow:inset 0 -1px 0 rgba(0,0,0,.25)}kbd kbd{padding:0;font-size:100%;-webkit-box-shadow:none;box-shadow:none}pre{padding:9.5px;margin:0 0 10px;font-size:13px;word-break:break-all;word-wrap:break-word;background-color:#f5f5f5;border:1px solid #ccc;-webkit-border-radius:4px;border-radius:4px}.container,.container-fluid{margin-right:auto;margin-left:auto}pre code{padding:0;font-size:inherit;color:inherit;white-space:pre-wrap;-webkit-border-radius:0;border-radius:0}.container,.container-fluid{padding-right:15px;padding-left:15px}.pre-scrollable{overflow-y:scroll}@media (min-width:992px){.container{width:970px}}@media (min-width:1200px){.container{width:1170px}}.row{margin-right:-15px;margin-left:-15px}.col-lg-1,.col-lg-10,.col-lg-11,.col-lg-12,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7,.col-lg-8,.col-lg-9,.col-md-1,.col-md-10,.col-md-11,.col-md-12,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,.col-md-8,.col-md-9,.col-sm-1,.col-sm-10,.col-sm-11,.col-sm-12,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,.col-sm-8,.col-sm-9,.col-xs-1,.col-xs-10,.col-xs-11,.col-xs-12,.col-xs-2,.col-xs-3,.col-xs-4,.col-xs-5,.col-xs-6,.col-xs-7,.col-xs-8,.col-xs-9{position:relative;min-height:1px;padding-right:15px;padding-left:15px}.col-xs-1,.col-xs-10,.col-xs-11,.col-xs-12,.col-xs-2,.col-xs-3,.col-xs-4,.col-xs-5,.col-xs-6,.col-xs-7,.col-xs-8,.col-xs-9{float:left}.col-xs-12{width:100%}.col-xs-11{width:91.66666667%}.col-xs-10{width:83.33333333%}.col-xs-9{width:75%}.col-xs-8{width:66.66666667%}.col-xs-7{width:58.33333333%}.col-xs-6{width:50%}.col-xs-5{width:41.66666667%}.col-xs-4{width:33.33333333%}.col-xs-3{width:25%}.col-xs-2{width:16.66666667%}.col-xs-1{width:8.33333333%}.col-xs-pull-12{right:100%}.col-xs-pull-11{right:91.66666667%}.col-xs-pull-10{right:83.33333333%}.col-xs-pull-9{right:75%}.col-xs-pull-8{right:66.66666667%}.col-xs-pull-7{right:58.33333333%}.col-xs-pull-6{right:50%}.col-xs-pull-5{right:41.66666667%}.col-xs-pull-4{right:33.33333333%}.col-xs-pull-3{right:25%}.col-xs-pull-2{right:16.66666667%}.col-xs-pull-1{right:8.33333333%}.col-xs-pull-0{right:auto}.col-xs-push-12{left:100%}.col-xs-push-11{left:91.66666667%}.col-xs-push-10{left:83.33333333%}.col-xs-push-9{left:75%}.col-xs-push-8{left:66.66666667%}.col-xs-push-7{left:58.33333333%}.col-xs-push-6{left:50%}.col-xs-push-5{left:41.66666667%}.col-xs-push-4{left:33.33333333%}.col-xs-push-3{left:25%}.col-xs-push-2{left:16.66666667%}.col-xs-push-1{left:8.33333333%}.col-xs-push-0{left:auto}.col-xs-offset-12{margin-left:100%}.col-xs-offset-11{margin-left:91.66666667%}.col-xs-offset-10{margin-left:83.33333333%}.col-xs-offset-9{margin-left:75%}.col-xs-offset-8{margin-left:66.66666667%}.col-xs-offset-7{margin-left:58.33333333%}.col-xs-offset-6{margin-left:50%}.col-xs-offset-5{margin-left:41.66666667%}.col-xs-offset-4{margin-left:33.33333333%}.col-xs-offset-3{margin-left:25%}.col-xs-offset-2{margin-left:16.66666667%}.col-xs-offset-1{margin-left:8.33333333%}.col-xs-offset-0{margin-left:0}@media (min-width:768px){.col-sm-1,.col-sm-10,.col-sm-11,.col-sm-12,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,.col-sm-8,.col-sm-9{float:left}.col-sm-12{width:100%}.col-sm-11{width:91.66666667%}.col-sm-10{width:83.33333333%}.col-sm-9{width:75%}.col-sm-8{width:66.66666667%}.col-sm-7{width:58.33333333%}.col-sm-6{width:50%}.col-sm-5{width:41.66666667%}.col-sm-4{width:33.33333333%}.col-sm-3{width:25%}.col-sm-2{width:16.66666667%}.col-sm-1{width:8.33333333%}.col-sm-pull-12{right:100%}.col-sm-pull-11{right:91.66666667%}.col-sm-pull-10{right:83.33333333%}.col-sm-pull-9{right:75%}.col-sm-pull-8{right:66.66666667%}.col-sm-pull-7{right:58.33333333%}.col-sm-pull-6{right:50%}.col-sm-pull-5{right:41.66666667%}.col-sm-pull-4{right:33.33333333%}.col-sm-pull-3{right:25%}.col-sm-pull-2{right:16.66666667%}.col-sm-pull-1{right:8.33333333%}.col-sm-pull-0{right:auto}.col-sm-push-12{left:100%}.col-sm-push-11{left:91.66666667%}.col-sm-push-10{left:83.33333333%}.col-sm-push-9{left:75%}.col-sm-push-8{left:66.66666667%}.col-sm-push-7{left:58.33333333%}.col-sm-push-6{left:50%}.col-sm-push-5{left:41.66666667%}.col-sm-push-4{left:33.33333333%}.col-sm-push-3{left:25%}.col-sm-push-2{left:16.66666667%}.col-sm-push-1{left:8.33333333%}.col-sm-push-0{left:auto}.col-sm-offset-12{margin-left:100%}.col-sm-offset-11{margin-left:91.66666667%}.col-sm-offset-10{margin-left:83.33333333%}.col-sm-offset-9{margin-left:75%}.col-sm-offset-8{margin-left:66.66666667%}.col-sm-offset-7{margin-left:58.33333333%}.col-sm-offset-6{margin-left:50%}.col-sm-offset-5{margin-left:41.66666667%}.col-sm-offset-4{margin-left:33.33333333%}.col-sm-offset-3{margin-left:25%}.col-sm-offset-2{margin-left:16.66666667%}.col-sm-offset-1{margin-left:8.33333333%}.col-sm-offset-0{margin-left:0}}@media (min-width:992px){.col-md-1,.col-md-10,.col-md-11,.col-md-12,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,.col-md-8,.col-md-9{float:left}.col-md-12{width:100%}.col-md-11{width:91.66666667%}.col-md-10{width:83.33333333%}.col-md-9{width:75%}.col-md-8{width:66.66666667%}.col-md-7{width:58.33333333%}.col-md-6{width:50%}.col-md-5{width:41.66666667%}.col-md-4{width:33.33333333%}.col-md-3{width:25%}.col-md-2{width:16.66666667%}.col-md-1{width:8.33333333%}.col-md-pull-12{right:100%}.col-md-pull-11{right:91.66666667%}.col-md-pull-10{right:83.33333333%}.col-md-pull-9{right:75%}.col-md-pull-8{right:66.66666667%}.col-md-pull-7{right:58.33333333%}.col-md-pull-6{right:50%}.col-md-pull-5{right:41.66666667%}.col-md-pull-4{right:33.33333333%}.col-md-pull-3{right:25%}.col-md-pull-2{right:16.66666667%}.col-md-pull-1{right:8.33333333%}.col-md-pull-0{right:auto}.col-md-push-12{left:100%}.col-md-push-11{left:91.66666667%}.col-md-push-10{left:83.33333333%}.col-md-push-9{left:75%}.col-md-push-8{left:66.66666667%}.col-md-push-7{left:58.33333333%}.col-md-push-6{left:50%}.col-md-push-5{left:41.66666667%}.col-md-push-4{left:33.33333333%}.col-md-push-3{left:25%}.col-md-push-2{left:16.66666667%}.col-md-push-1{left:8.33333333%}.col-md-push-0{left:auto}.col-md-offset-12{margin-left:100%}.col-md-offset-11{margin-left:91.66666667%}.col-md-offset-10{margin-left:83.33333333%}.col-md-offset-9{margin-left:75%}.col-md-offset-8{margin-left:66.66666667%}.col-md-offset-7{margin-left:58.33333333%}.col-md-offset-6{margin-left:50%}.col-md-offset-5{margin-left:41.66666667%}.col-md-offset-4{margin-left:33.33333333%}.col-md-offset-3{margin-left:25%}.col-md-offset-2{margin-left:16.66666667%}.col-md-offset-1{margin-left:8.33333333%}.col-md-offset-0{margin-left:0}}@media (min-width:1200px){.col-lg-1,.col-lg-10,.col-lg-11,.col-lg-12,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7,.col-lg-8,.col-lg-9{float:left}.col-lg-12{width:100%}.col-lg-11{width:91.66666667%}.col-lg-10{width:83.33333333%}.col-lg-9{width:75%}.col-lg-8{width:66.66666667%}.col-lg-7{width:58.33333333%}.col-lg-6{width:50%}.col-lg-5{width:41.66666667%}.col-lg-4{width:33.33333333%}.col-lg-3{width:25%}.col-lg-2{width:16.66666667%}.col-lg-1{width:8.33333333%}.col-lg-pull-12{right:100%}.col-lg-pull-11{right:91.66666667%}.col-lg-pull-10{right:83.33333333%}.col-lg-pull-9{right:75%}.col-lg-pull-8{right:66.66666667%}.col-lg-pull-7{right:58.33333333%}.col-lg-pull-6{right:50%}.col-lg-pull-5{right:41.66666667%}.col-lg-pull-4{right:33.33333333%}.col-lg-pull-3{right:25%}.col-lg-pull-2{right:16.66666667%}.col-lg-pull-1{right:8.33333333%}.col-lg-pull-0{right:auto}.col-lg-push-12{left:100%}.col-lg-push-11{left:91.66666667%}.col-lg-push-10{left:83.33333333%}.col-lg-push-9{left:75%}.col-lg-push-8{left:66.66666667%}.col-lg-push-7{left:58.33333333%}.col-lg-push-6{left:50%}.col-lg-push-5{left:41.66666667%}.col-lg-push-4{left:33.33333333%}.col-lg-push-3{left:25%}.col-lg-push-2{left:16.66666667%}.col-lg-push-1{left:8.33333333%}.col-lg-push-0{left:auto}.col-lg-offset-12{margin-left:100%}.col-lg-offset-11{margin-left:91.66666667%}.col-lg-offset-10{margin-left:83.33333333%}.col-lg-offset-9{margin-left:75%}.col-lg-offset-8{margin-left:66.66666667%}.col-lg-offset-7{margin-left:58.33333333%}.col-lg-offset-6{margin-left:50%}.col-lg-offset-5{margin-left:41.66666667%}.col-lg-offset-4{margin-left:33.33333333%}.col-lg-offset-3{margin-left:25%}.col-lg-offset-2{margin-left:16.66666667%}.col-lg-offset-1{margin-left:8.33333333%}.col-lg-offset-0{margin-left:0}}caption{padding-top:8px;padding-bottom:8px;color:#777}.table{width:100%;max-width:100%;margin-bottom:20px}.table>tbody>tr>td,.table>tbody>tr>th,.table>tfoot>tr>td,.table>tfoot>tr>th,.table>thead>tr>td,.table>thead>tr>th{padding:8px;line-height:1.42857143;vertical-align:top;border-top:1px solid #ddd}.table>thead>tr>th{vertical-align:bottom;border-bottom:2px solid #ddd}.table>caption+thead>tr:first-child>td,.table>caption+thead>tr:first-child>th,.table>colgroup+thead>tr:first-child>td,.table>colgroup+thead>tr:first-child>th,.table>thead:first-child>tr:first-child>td,.table>thead:first-child>tr:first-child>th{border-top:0}.table>tbody+tbody{border-top:2px solid #ddd}.table .table{background-color:#fff}.table-condensed>tbody>tr>td,.table-condensed>tbody>tr>th,.table-condensed>tfoot>tr>td,.table-condensed>tfoot>tr>th,.table-condensed>thead>tr>td,.table-condensed>thead>tr>th{padding:5px}.table-bordered,.table-bordered>tbody>tr>td,.table-bordered>tbody>tr>th,.table-bordered>tfoot>tr>td,.table-bordered>tfoot>tr>th,.table-bordered>thead>tr>td,.table-bordered>thead>tr>th{border:1px solid #ddd}.table-bordered>thead>tr>td,.table-bordered>thead>tr>th{border-bottom-width:2px}.table-striped>tbody>tr:nth-of-type(odd){background-color:#f9f9f9}.table-hover>tbody>tr:hover,.table>tbody>tr.active>td,.table>tbody>tr.active>th,.table>tbody>tr>td.active,.table>tbody>tr>th.active,.table>tfoot>tr.active>td,.table>tfoot>tr.active>th,.table>tfoot>tr>td.active,.table>tfoot>tr>th.active,.table>thead>tr.active>td,.table>thead>tr.active>th,.table>thead>tr>td.active,.table>thead>tr>th.active{background-color:#f5f5f5}table col[class*=col-]{position:static;display:table-column;float:none}table td[class*=col-],table th[class*=col-]{position:static;display:table-cell;float:none}.btn-group>.btn-group,.btn-toolbar .btn,.btn-toolbar .btn-group,.btn-toolbar .input-group,.dropdown-menu{float:left}.table-hover>tbody>tr.active:hover>td,.table-hover>tbody>tr.active:hover>th,.table-hover>tbody>tr:hover>.active,.table-hover>tbody>tr>td.active:hover,.table-hover>tbody>tr>th.active:hover{background-color:#e8e8e8}.table>tbody>tr.success>td,.table>tbody>tr.success>th,.table>tbody>tr>td.success,.table>tbody>tr>th.success,.table>tfoot>tr.success>td,.table>tfoot>tr.success>th,.table>tfoot>tr>td.success,.table>tfoot>tr>th.success,.table>thead>tr.success>td,.table>thead>tr.success>th,.table>thead>tr>td.success,.table>thead>tr>th.success{background-color:#dff0d8}.table-hover>tbody>tr.success:hover>td,.table-hover>tbody>tr.success:hover>th,.table-hover>tbody>tr:hover>.success,.table-hover>tbody>tr>td.success:hover,.table-hover>tbody>tr>th.success:hover{background-color:#d0e9c6}.table>tbody>tr.info>td,.table>tbody>tr.info>th,.table>tbody>tr>td.info,.table>tbody>tr>th.info,.table>tfoot>tr.info>td,.table>tfoot>tr.info>th,.table>tfoot>tr>td.info,.table>tfoot>tr>th.info,.table>thead>tr.info>td,.table>thead>tr.info>th,.table>thead>tr>td.info,.table>thead>tr>th.info{background-color:#d9edf7}.table-hover>tbody>tr.info:hover>td,.table-hover>tbody>tr.info:hover>th,.table-hover>tbody>tr:hover>.info,.table-hover>tbody>tr>td.info:hover,.table-hover>tbody>tr>th.info:hover{background-color:#c4e3f3}.table>tbody>tr.warning>td,.table>tbody>tr.warning>th,.table>tbody>tr>td.warning,.table>tbody>tr>th.warning,.table>tfoot>tr.warning>td,.table>tfoot>tr.warning>th,.table>tfoot>tr>td.warning,.table>tfoot>tr>th.warning,.table>thead>tr.warning>td,.table>thead>tr.warning>th,.table>thead>tr>td.warning,.table>thead>tr>th.warning{background-color:#fcf8e3}.table-hover>tbody>tr.warning:hover>td,.table-hover>tbody>tr.warning:hover>th,.table-hover>tbody>tr:hover>.warning,.table-hover>tbody>tr>td.warning:hover,.table-hover>tbody>tr>th.warning:hover{background-color:#faf2cc}.table>tbody>tr.danger>td,.table>tbody>tr.danger>th,.table>tbody>tr>td.danger,.table>tbody>tr>th.danger,.table>tfoot>tr.danger>td,.table>tfoot>tr.danger>th,.table>tfoot>tr>td.danger,.table>tfoot>tr>th.danger,.table>thead>tr.danger>td,.table>thead>tr.danger>th,.table>thead>tr>td.danger,.table>thead>tr>th.danger{background-color:#f2dede}.table-hover>tbody>tr.danger:hover>td,.table-hover>tbody>tr.danger:hover>th,.table-hover>tbody>tr:hover>.danger,.table-hover>tbody>tr>td.danger:hover,.table-hover>tbody>tr>th.danger:hover{background-color:#ebcccc}.table-responsive{min-height:.01%;overflow-x:auto}@media screen and (max-width:767px){.table-responsive{width:100%;margin-bottom:15px;overflow-y:hidden;-ms-overflow-style:-ms-autohiding-scrollbar;border:1px solid #ddd}.table-responsive>.table{margin-bottom:0}.table-responsive>.table>tbody>tr>td,.table-responsive>.table>tbody>tr>th,.table-responsive>.table>tfoot>tr>td,.table-responsive>.table>tfoot>tr>th,.table-responsive>.table>thead>tr>td,.table-responsive>.table>thead>tr>th{white-space:nowrap}.table-responsive>.table-bordered{border:0}.table-responsive>.table-bordered>tbody>tr>td:first-child,.table-responsive>.table-bordered>tbody>tr>th:first-child,.table-responsive>.table-bordered>tfoot>tr>td:first-child,.table-responsive>.table-bordered>tfoot>tr>th:first-child,.table-responsive>.table-bordered>thead>tr>td:first-child,.table-responsive>.table-bordered>thead>tr>th:first-child{border-left:0}.table-responsive>.table-bordered>tbody>tr>td:last-child,.table-responsive>.table-bordered>tbody>tr>th:last-child,.table-responsive>.table-bordered>tfoot>tr>td:last-child,.table-responsive>.table-bordered>tfoot>tr>th:last-child,.table-responsive>.table-bordered>thead>tr>td:last-child,.table-responsive>.table-bordered>thead>tr>th:last-child{border-right:0}.table-responsive>.table-bordered>tbody>tr:last-child>td,.table-responsive>.table-bordered>tbody>tr:last-child>th,.table-responsive>.table-bordered>tfoot>tr:last-child>td,.table-responsive>.table-bordered>tfoot>tr:last-child>th{border-bottom:0}}fieldset,legend{padding:0;border:0}fieldset{min-width:0;margin:0}legend{width:100%;margin-bottom:20px;font-size:21px;line-height:inherit;border-bottom:1px solid #e5e5e5}label{display:inline-block;max-width:100%;margin-bottom:5px}input[type=search]{-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:none}input[type=checkbox],input[type=radio]{margin:4px 0 0;margin-top:1px\9;line-height:normal}.form-control,output{font-size:14px;line-height:1.42857143;color:#555;display:block}input[type=file]{display:block}input[type=range]{display:block;width:100%}select[multiple],select[size]{height:auto}input[type=checkbox]:focus,input[type=file]:focus,input[type=radio]:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}output{padding-top:7px}.form-control{width:100%;height:34px;padding:6px 12px;background-color:#fff;border:1px solid #ccc;-webkit-border-radius:4px;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075);-webkit-transition:border-color ease-in-out .15s,-webkit-box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s}.form-control:focus{border-color:#66afe9;outline:0;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6)}.form-control::-moz-placeholder{color:#999;opacity:1}.form-control:-ms-input-placeholder{color:#999}.form-control::-webkit-input-placeholder{color:#999}.has-success .checkbox,.has-success .checkbox-inline,.has-success .control-label,.has-success .form-control-feedback,.has-success .help-block,.has-success .radio,.has-success .radio-inline,.has-success.checkbox label,.has-success.checkbox-inline label,.has-success.radio label,.has-success.radio-inline label{color:#3c763d}.form-control[disabled],.form-control[readonly],fieldset[disabled] .form-control{background-color:#eee;opacity:1}.form-control[disabled],fieldset[disabled] .form-control{cursor:not-allowed}textarea.form-control{height:auto}@media screen and (-webkit-min-device-pixel-ratio:0){input[type=date].form-control,input[type=datetime-local].form-control,input[type=month].form-control,input[type=time].form-control{line-height:34px}.input-group-sm input[type=date],.input-group-sm input[type=datetime-local],.input-group-sm input[type=month],.input-group-sm input[type=time],input[type=date].input-sm,input[type=datetime-local].input-sm,input[type=month].input-sm,input[type=time].input-sm{line-height:30px}.input-group-lg input[type=date],.input-group-lg input[type=datetime-local],.input-group-lg input[type=month],.input-group-lg input[type=time],input[type=date].input-lg,input[type=datetime-local].input-lg,input[type=month].input-lg,input[type=time].input-lg{line-height:46px}}.form-group{margin-bottom:15px}.checkbox,.radio{position:relative;display:block;margin-top:10px;margin-bottom:10px}.checkbox label,.radio label{min-height:20px;padding-left:20px;margin-bottom:0;font-weight:400;cursor:pointer}.checkbox input[type=checkbox],.checkbox-inline input[type=checkbox],.radio input[type=radio],.radio-inline input[type=radio]{position:absolute;margin-top:4px\9;margin-left:-20px}.checkbox+.checkbox,.radio+.radio{margin-top:-5px}.checkbox-inline,.radio-inline{position:relative;display:inline-block;padding-left:20px;margin-bottom:0;font-weight:400;vertical-align:middle;cursor:pointer}.checkbox-inline+.checkbox-inline,.radio-inline+.radio-inline{margin-top:0;margin-left:10px}.checkbox-inline.disabled,.checkbox.disabled label,.radio-inline.disabled,.radio.disabled label,fieldset[disabled] .checkbox label,fieldset[disabled] .checkbox-inline,fieldset[disabled] .radio label,fieldset[disabled] .radio-inline,fieldset[disabled] input[type=checkbox],fieldset[disabled] input[type=radio],input[type=checkbox].disabled,input[type=checkbox][disabled],input[type=radio].disabled,input[type=radio][disabled]{cursor:not-allowed}.form-control-static{min-height:34px;padding-top:7px;padding-bottom:7px;margin-bottom:0}.form-control-static.input-lg,.form-control-static.input-sm{padding-right:0;padding-left:0}.input-sm{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-sm{height:30px;line-height:30px}select[multiple].input-sm,textarea.input-sm{height:auto}.form-group-sm .form-control{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;-webkit-border-radius:3px;border-radius:3px}.form-group-sm select.form-control{height:30px;line-height:30px}.form-group-sm select[multiple].form-control,.form-group-sm textarea.form-control{height:auto}.form-group-sm .form-control-static{height:30px;min-height:32px;padding:6px 10px;font-size:12px;line-height:1.5}.input-lg{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:6px}select.input-lg{height:46px;line-height:46px}select[multiple].input-lg,textarea.input-lg{height:auto}.form-group-lg .form-control{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;-webkit-border-radius:6px;border-radius:6px}.form-group-lg select.form-control{height:46px;line-height:46px}.form-group-lg select[multiple].form-control,.form-group-lg textarea.form-control{height:auto}.form-group-lg .form-control-static{height:46px;min-height:38px;padding:11px 16px;font-size:18px;line-height:1.3333333}.has-feedback{position:relative}.has-feedback .form-control{padding-right:42.5px}.form-control-feedback{position:absolute;top:0;right:0;z-index:2;display:block;width:34px;height:34px;line-height:34px;text-align:center;pointer-events:none}.collapsing,.dropdown,.dropup{position:relative}.form-group-lg .form-control+.form-control-feedback,.input-group-lg+.form-control-feedback,.input-lg+.form-control-feedback{width:46px;height:46px;line-height:46px}.form-group-sm .form-control+.form-control-feedback,.input-group-sm+.form-control-feedback,.input-sm+.form-control-feedback{width:30px;height:30px;line-height:30px}.has-success .form-control{border-color:#3c763d;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-success .form-control:focus{border-color:#2b542c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168}.has-success .input-group-addon{color:#3c763d;background-color:#dff0d8;border-color:#3c763d}.has-warning .checkbox,.has-warning .checkbox-inline,.has-warning .control-label,.has-warning .form-control-feedback,.has-warning .help-block,.has-warning .radio,.has-warning .radio-inline,.has-warning.checkbox label,.has-warning.checkbox-inline label,.has-warning.radio label,.has-warning.radio-inline label{color:#8a6d3b}.has-warning .form-control{border-color:#8a6d3b;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-warning .form-control:focus{border-color:#66512c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b}.has-warning .input-group-addon{color:#8a6d3b;background-color:#fcf8e3;border-color:#8a6d3b}.has-error .checkbox,.has-error .checkbox-inline,.has-error .control-label,.has-error .form-control-feedback,.has-error .help-block,.has-error .radio,.has-error .radio-inline,.has-error.checkbox label,.has-error.checkbox-inline label,.has-error.radio label,.has-error.radio-inline label{color:#a94442}.has-error .form-control{border-color:#a94442;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-error .form-control:focus{border-color:#843534;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483}.has-error .input-group-addon{color:#a94442;background-color:#f2dede;border-color:#a94442}.has-feedback label~.form-control-feedback{top:25px}.has-feedback label.sr-only~.form-control-feedback{top:0}.help-block{display:block;margin-top:5px;margin-bottom:10px;color:#737373}@media (min-width:768px){.form-inline .form-control-static,.form-inline .form-group{display:inline-block}.form-inline .control-label,.form-inline .form-group{margin-bottom:0;vertical-align:middle}.form-inline .form-control{display:inline-block;width:auto;vertical-align:middle}.form-inline .input-group{display:inline-table;vertical-align:middle}.form-inline .input-group .form-control,.form-inline .input-group .input-group-addon,.form-inline .input-group .input-group-btn{width:auto}.form-inline .input-group>.form-control{width:100%}.form-inline .checkbox,.form-inline .radio{display:inline-block;margin-top:0;margin-bottom:0;vertical-align:middle}.form-inline .checkbox label,.form-inline .radio label{padding-left:0}.form-inline .checkbox input[type=checkbox],.form-inline .radio input[type=radio]{position:relative;margin-left:0}.form-inline .has-feedback .form-control-feedback{top:0}.form-horizontal .control-label{padding-top:7px;margin-bottom:0;text-align:right}}.btn-block,input[type=button].btn-block,input[type=reset].btn-block,input[type=submit].btn-block{width:100%}.form-horizontal .checkbox,.form-horizontal .checkbox-inline,.form-horizontal .radio,.form-horizontal .radio-inline{padding-top:7px;margin-top:0;margin-bottom:0}.form-horizontal .checkbox,.form-horizontal .radio{min-height:27px}.form-horizontal .form-group{margin-right:-15px;margin-left:-15px}.form-horizontal .has-feedback .form-control-feedback{right:15px}@media (min-width:768px){.form-horizontal .form-group-lg .control-label{padding-top:14.33px;font-size:18px}.form-horizontal .form-group-sm .control-label{padding-top:6px;font-size:12px}}.btn{display:inline-block;padding:6px 12px;margin-bottom:0;font-size:14px;font-weight:400;line-height:1.42857143;text-align:center;white-space:nowrap;vertical-align:middle;-ms-touch-action:manipulation;touch-action:manipulation;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;border:1px solid transparent;-webkit-border-radius:4px;border-radius:4px}.btn.active.focus,.btn.active:focus,.btn.focus,.btn:active.focus,.btn:active:focus,.btn:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.btn.focus,.btn:focus,.btn:hover{color:#333;text-decoration:none}.btn.active,.btn:active{outline:0;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn.disabled,.btn[disabled],fieldset[disabled] .btn{cursor:not-allowed;filter:alpha(opacity=65);-webkit-box-shadow:none;box-shadow:none;opacity:.65}a.btn.disabled,fieldset[disabled] a.btn{pointer-events:none}.btn-default{color:#333;background-color:#fff;border-color:#ccc}.btn-default.focus,.btn-default:focus{color:#333;background-color:#e6e6e6;border-color:#8c8c8c}.btn-default.active,.btn-default:active,.btn-default:hover,.open>.dropdown-toggle.btn-default{color:#333;background-color:#e6e6e6;border-color:#adadad}.btn-default.active.focus,.btn-default.active:focus,.btn-default.active:hover,.btn-default:active.focus,.btn-default:active:focus,.btn-default:active:hover,.open>.dropdown-toggle.btn-default.focus,.open>.dropdown-toggle.btn-default:focus,.open>.dropdown-toggle.btn-default:hover{color:#333;background-color:#d4d4d4;border-color:#8c8c8c}.btn-default.disabled,.btn-default.disabled.active,.btn-default.disabled.focus,.btn-default.disabled:active,.btn-default.disabled:focus,.btn-default.disabled:hover,.btn-default[disabled],.btn-default[disabled].active,.btn-default[disabled].focus,.btn-default[disabled]:active,.btn-default[disabled]:focus,.btn-default[disabled]:hover,fieldset[disabled] .btn-default,fieldset[disabled] .btn-default.active,fieldset[disabled] .btn-default.focus,fieldset[disabled] .btn-default:active,fieldset[disabled] .btn-default:focus,fieldset[disabled] .btn-default:hover{background-color:#fff;border-color:#ccc}.btn-default .badge{color:#fff;background-color:#333}.btn-primary{color:#fff;background-color:#337ab7;border-color:#2e6da4}.btn-primary.focus,.btn-primary:focus{color:#fff;background-color:#286090;border-color:#122b40}.btn-primary.active,.btn-primary:active,.btn-primary:hover,.open>.dropdown-toggle.btn-primary{color:#fff;background-color:#286090;border-color:#204d74}.btn-primary.active.focus,.btn-primary.active:focus,.btn-primary.active:hover,.btn-primary:active.focus,.btn-primary:active:focus,.btn-primary:active:hover,.open>.dropdown-toggle.btn-primary.focus,.open>.dropdown-toggle.btn-primary:focus,.open>.dropdown-toggle.btn-primary:hover{color:#fff;background-color:#204d74;border-color:#122b40}.btn-primary.disabled,.btn-primary.disabled.active,.btn-primary.disabled.focus,.btn-primary.disabled:active,.btn-primary.disabled:focus,.btn-primary.disabled:hover,.btn-primary[disabled],.btn-primary[disabled].active,.btn-primary[disabled].focus,.btn-primary[disabled]:active,.btn-primary[disabled]:focus,.btn-primary[disabled]:hover,fieldset[disabled] .btn-primary,fieldset[disabled] .btn-primary.active,fieldset[disabled] .btn-primary.focus,fieldset[disabled] .btn-primary:active,fieldset[disabled] .btn-primary:focus,fieldset[disabled] .btn-primary:hover{background-color:#337ab7;border-color:#2e6da4}.btn-primary .badge{color:#337ab7;background-color:#fff}.btn-success{color:#fff;background-color:#5cb85c;border-color:#4cae4c}.btn-success.focus,.btn-success:focus{color:#fff;background-color:#449d44;border-color:#255625}.btn-success.active,.btn-success:active,.btn-success:hover,.open>.dropdown-toggle.btn-success{color:#fff;background-color:#449d44;border-color:#398439}.btn-success.active.focus,.btn-success.active:focus,.btn-success.active:hover,.btn-success:active.focus,.btn-success:active:focus,.btn-success:active:hover,.open>.dropdown-toggle.btn-success.focus,.open>.dropdown-toggle.btn-success:focus,.open>.dropdown-toggle.btn-success:hover{color:#fff;background-color:#398439;border-color:#255625}.btn-success.active,.btn-success:active,.open>.dropdown-toggle.btn-success{background-image:none}.btn-success.disabled,.btn-success.disabled.active,.btn-success.disabled.focus,.btn-success.disabled:active,.btn-success.disabled:focus,.btn-success.disabled:hover,.btn-success[disabled],.btn-success[disabled].active,.btn-success[disabled].focus,.btn-success[disabled]:active,.btn-success[disabled]:focus,.btn-success[disabled]:hover,fieldset[disabled] .btn-success,fieldset[disabled] .btn-success.active,fieldset[disabled] .btn-success.focus,fieldset[disabled] .btn-success:active,fieldset[disabled] .btn-success:focus,fieldset[disabled] .btn-success:hover{background-color:#5cb85c;border-color:#4cae4c}.btn-success .badge{color:#5cb85c;background-color:#fff}.btn-info{color:#fff;background-color:#5bc0de;border-color:#46b8da}.btn-info.focus,.btn-info:focus{color:#fff;background-color:#31b0d5;border-color:#1b6d85}.btn-info.active,.btn-info:active,.btn-info:hover,.open>.dropdown-toggle.btn-info{color:#fff;background-color:#31b0d5;border-color:#269abc}.btn-info.active.focus,.btn-info.active:focus,.btn-info.active:hover,.btn-info:active.focus,.btn-info:active:focus,.btn-info:active:hover,.open>.dropdown-toggle.btn-info.focus,.open>.dropdown-toggle.btn-info:focus,.open>.dropdown-toggle.btn-info:hover{color:#fff;background-color:#269abc;border-color:#1b6d85}.btn-info.disabled,.btn-info.disabled.active,.btn-info.disabled.focus,.btn-info.disabled:active,.btn-info.disabled:focus,.btn-info.disabled:hover,.btn-info[disabled],.btn-info[disabled].active,.btn-info[disabled].focus,.btn-info[disabled]:active,.btn-info[disabled]:focus,.btn-info[disabled]:hover,fieldset[disabled] .btn-info,fieldset[disabled] .btn-info.active,fieldset[disabled] .btn-info.focus,fieldset[disabled] .btn-info:active,fieldset[disabled] .btn-info:focus,fieldset[disabled] .btn-info:hover{background-color:#5bc0de;border-color:#46b8da}.btn-info .badge{color:#5bc0de;background-color:#fff}.btn-warning{color:#fff;background-color:#f0ad4e;border-color:#eea236}.btn-warning.focus,.btn-warning:focus{color:#fff;background-color:#ec971f;border-color:#985f0d}.btn-warning.active,.btn-warning:active,.btn-warning:hover,.open>.dropdown-toggle.btn-warning{color:#fff;background-color:#ec971f;border-color:#d58512}.btn-warning.active.focus,.btn-warning.active:focus,.btn-warning.active:hover,.btn-warning:active.focus,.btn-warning:active:focus,.btn-warning:active:hover,.open>.dropdown-toggle.btn-warning.focus,.open>.dropdown-toggle.btn-warning:focus,.open>.dropdown-toggle.btn-warning:hover{color:#fff;background-color:#d58512;border-color:#985f0d}.btn-warning.disabled,.btn-warning.disabled.active,.btn-warning.disabled.focus,.btn-warning.disabled:active,.btn-warning.disabled:focus,.btn-warning.disabled:hover,.btn-warning[disabled],.btn-warning[disabled].active,.btn-warning[disabled].focus,.btn-warning[disabled]:active,.btn-warning[disabled]:focus,.btn-warning[disabled]:hover,fieldset[disabled] .btn-warning,fieldset[disabled] .btn-warning.active,fieldset[disabled] .btn-warning.focus,fieldset[disabled] .btn-warning:active,fieldset[disabled] .btn-warning:focus,fieldset[disabled] .btn-warning:hover{background-color:#f0ad4e;border-color:#eea236}.btn-warning .badge{color:#f0ad4e;background-color:#fff}.btn-danger{color:#fff;background-color:#d9534f;border-color:#d43f3a}.btn-danger.focus,.btn-danger:focus{color:#fff;background-color:#c9302c;border-color:#761c19}.btn-danger.active,.btn-danger:active,.btn-danger:hover,.open>.dropdown-toggle.btn-danger{color:#fff;background-color:#c9302c;border-color:#ac2925}.btn-danger.active.focus,.btn-danger.active:focus,.btn-danger.active:hover,.btn-danger:active.focus,.btn-danger:active:focus,.btn-danger:active:hover,.open>.dropdown-toggle.btn-danger.focus,.open>.dropdown-toggle.btn-danger:focus,.open>.dropdown-toggle.btn-danger:hover{color:#fff;background-color:#ac2925;border-color:#761c19}.btn-danger.disabled,.btn-danger.disabled.active,.btn-danger.disabled.focus,.btn-danger.disabled:active,.btn-danger.disabled:focus,.btn-danger.disabled:hover,.btn-danger[disabled],.btn-danger[disabled].active,.btn-danger[disabled].focus,.btn-danger[disabled]:active,.btn-danger[disabled]:focus,.btn-danger[disabled]:hover,fieldset[disabled] .btn-danger,fieldset[disabled] .btn-danger.active,fieldset[disabled] .btn-danger.focus,fieldset[disabled] .btn-danger:active,fieldset[disabled] .btn-danger:focus,fieldset[disabled] .btn-danger:hover{background-color:#d9534f;border-color:#d43f3a}.btn-danger .badge{color:#d9534f;background-color:#fff}.btn-link{font-weight:400;color:#337ab7;-webkit-border-radius:0;border-radius:0}.btn-link,.btn-link.active,.btn-link:active,.btn-link[disabled],fieldset[disabled] .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.btn-link,.btn-link:active,.btn-link:focus,.btn-link:hover{border-color:transparent}.btn-link:focus,.btn-link:hover{color:#23527c;text-decoration:underline;background-color:transparent}.btn-link[disabled]:focus,.btn-link[disabled]:hover,fieldset[disabled] .btn-link:focus,fieldset[disabled] .btn-link:hover{color:#777;text-decoration:none}.btn-group-lg>.btn,.btn-lg{padding:10px 16px;font-size:18px;line-height:1.3333333;-webkit-border-radius:6px;border-radius:6px}.btn-group-sm>.btn,.btn-sm{padding:5px 10px;font-size:12px;line-height:1.5;-webkit-border-radius:3px;border-radius:3px}.btn-group-xs>.btn,.btn-xs{padding:1px 5px;font-size:12px;line-height:1.5;-webkit-border-radius:3px;border-radius:3px}.btn-block{display:block}.btn-block+.btn-block{margin-top:5px}.fade{opacity:0;-webkit-transition:opacity .15s linear;transition:opacity .15s linear}.fade.in{opacity:1}.collapse{display:none}.collapse.in{display:block}tr.collapse.in{display:table-row}tbody.collapse.in{display:table-row-group}.collapsing{height:0;overflow:hidden;-webkit-transition-timing-function:ease;transition-timing-function:ease;-webkit-transition-duration:.35s;transition-duration:.35s;-webkit-transition-property:height,visibility;transition-property:height,visibility}.caret{display:inline-block;width:0;height:0;margin-left:2px;vertical-align:middle;border-top:4px dashed;border-top:4px solid\9;border-right:4px solid transparent;border-left:4px solid transparent}.dropdown-toggle:focus{outline:0}.dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;display:none;min-width:160px;padding:5px 0;margin:2px 0 0;font-size:14px;text-align:left;list-style:none;background-color:#fff;background-clip:padding-box;border:1px solid #ccc;border:1px solid rgba(0,0,0,.15);-webkit-border-radius:4px;border-radius:4px;-webkit-box-shadow:0 6px 12px rgba(0,0,0,.175);box-shadow:0 6px 12px rgba(0,0,0,.175)}.dropdown-menu-right,.dropdown-menu.pull-right{right:0;left:auto}.dropdown-header,.dropdown-menu>li>a{display:block;padding:3px 20px;line-height:1.42857143;white-space:nowrap}.dropdown-menu .divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.dropdown-menu>li>a{clear:both;font-weight:400;color:#333}.dropdown-menu>li>a:focus,.dropdown-menu>li>a:hover{color:#262626;text-decoration:none;background-color:#f5f5f5}.dropdown-menu>.active>a,.dropdown-menu>.active>a:focus,.dropdown-menu>.active>a:hover{color:#fff;text-decoration:none;background-color:#337ab7;outline:0}.dropdown-menu>.disabled>a,.dropdown-menu>.disabled>a:focus,.dropdown-menu>.disabled>a:hover{color:#777}.dropdown-menu>.disabled>a:focus,.dropdown-menu>.disabled>a:hover{text-decoration:none;cursor:not-allowed;background-color:transparent;filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.open>.dropdown-menu{display:block}.open>a{outline:0}.dropdown-menu-left{right:auto;left:0}.dropdown-header{font-size:12px;color:#777}.dropdown-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:990}.nav-justified>.dropdown .dropdown-menu,.nav-tabs.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}.pull-right>.dropdown-menu{right:0;left:auto}.dropup .caret,.navbar-fixed-bottom .dropdown .caret{content:"";border-top:0;border-bottom:4px dashed;border-bottom:4px solid\9}.dropup .dropdown-menu,.navbar-fixed-bottom .dropdown .dropdown-menu{top:auto;bottom:100%;margin-bottom:2px}@media (min-width:768px){.navbar-right .dropdown-menu{right:0;left:auto}.navbar-right .dropdown-menu-left{right:auto;left:0}}.btn-group,.btn-group-vertical{position:relative;display:inline-block;vertical-align:middle}.btn-group-vertical>.btn,.btn-group>.btn{position:relative;float:left}.btn-group-vertical>.btn.active,.btn-group-vertical>.btn:active,.btn-group-vertical>.btn:focus,.btn-group-vertical>.btn:hover,.btn-group>.btn.active,.btn-group>.btn:active,.btn-group>.btn:focus,.btn-group>.btn:hover{z-index:2}.btn-group .btn+.btn,.btn-group .btn+.btn-group,.btn-group .btn-group+.btn,.btn-group .btn-group+.btn-group{margin-left:-1px}.btn-toolbar{margin-left:-5px}.btn-toolbar>.btn,.btn-toolbar>.btn-group,.btn-toolbar>.input-group{margin-left:5px}.btn .caret,.btn-group>.btn:first-child{margin-left:0}.btn-group>.btn:not(:first-child):not(:last-child):not(.dropdown-toggle){-webkit-border-radius:0;border-radius:0}.btn-group>.btn:first-child:not(:last-child):not(.dropdown-toggle){-webkit-border-top-right-radius:0;border-top-right-radius:0;-webkit-border-bottom-right-radius:0;border-bottom-right-radius:0}.btn-group>.btn:last-child:not(:first-child),.btn-group>.dropdown-toggle:not(:first-child){-webkit-border-top-left-radius:0;border-top-left-radius:0;-webkit-border-bottom-left-radius:0;border-bottom-left-radius:0}.btn-group>.btn-group:not(:first-child):not(:last-child)>.btn{-webkit-border-radius:0;border-radius:0}.btn-group>.btn-group:first-child:not(:last-child)>.btn:last-child,.btn-group>.btn-group:first-child:not(:last-child)>.dropdown-toggle{-webkit-border-top-right-radius:0;border-top-right-radius:0;-webkit-border-bottom-right-radius:0;border-bottom-right-radius:0}.btn-group>.btn-group:last-child:not(:first-child)>.btn:first-child{-webkit-border-top-left-radius:0;border-top-left-radius:0;-webkit-border-bottom-left-radius:0;border-bottom-left-radius:0}.btn-group .dropdown-toggle:active,.btn-group.open .dropdown-toggle{outline:0}.btn-group>.btn+.dropdown-toggle{padding-right:8px;padding-left:8px}.btn-group>.btn-lg+.dropdown-toggle{padding-right:12px;padding-left:12px}.btn-group.open .dropdown-toggle{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn-group.open .dropdown-toggle.btn-link{-webkit-box-shadow:none;box-shadow:none}.btn-lg .caret{border-width:5px 5px 0}.dropup .btn-lg .caret{border-width:0 5px 5px}.btn-group-vertical>.btn,.btn-group-vertical>.btn-group,.btn-group-vertical>.btn-group>.btn{display:block;float:none;width:100%;max-width:100%}.btn-group-vertical>.btn-group>.btn{float:none}.btn-group-vertical>.btn+.btn,.btn-group-vertical>.btn+.btn-group,.btn-group-vertical>.btn-group+.btn,.btn-group-vertical>.btn-group+.btn-group{margin-top:-1px;margin-left:0}.btn-group-vertical>.btn:not(:first-child):not(:last-child){-webkit-border-radius:0;border-radius:0}.btn-group-vertical>.btn:first-child:not(:last-child){-webkit-border-top-right-radius:4px;border-top-right-radius:4px;-webkit-border-bottom-right-radius:0;border-bottom-right-radius:0;-webkit-border-bottom-left-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn:last-child:not(:first-child){-webkit-border-top-left-radius:0;border-top-left-radius:0;-webkit-border-top-right-radius:0;border-top-right-radius:0;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px}.btn-group-vertical>.btn-group:not(:first-child):not(:last-child)>.btn{-webkit-border-radius:0;border-radius:0}.btn-group-vertical>.btn-group:first-child:not(:last-child)>.btn:last-child,.btn-group-vertical>.btn-group:first-child:not(:last-child)>.dropdown-toggle{-webkit-border-bottom-right-radius:0;border-bottom-right-radius:0;-webkit-border-bottom-left-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn-group:last-child:not(:first-child)>.btn:first-child{-webkit-border-top-left-radius:0;border-top-left-radius:0;-webkit-border-top-right-radius:0;border-top-right-radius:0}.btn-group-justified{display:table;width:100%;table-layout:fixed;border-collapse:separate}.btn-group-justified>.btn,.btn-group-justified>.btn-group{display:table-cell;float:none;width:1%}.btn-group-justified>.btn-group .btn{width:100%}.btn-group-justified>.btn-group .dropdown-menu{left:auto}[data-toggle=buttons]>.btn input[type=checkbox],[data-toggle=buttons]>.btn input[type=radio],[data-toggle=buttons]>.btn-group>.btn input[type=checkbox],[data-toggle=buttons]>.btn-group>.btn input[type=radio]{position:absolute;clip:rect(0,0,0,0);pointer-events:none}.input-group{position:relative;display:table;border-collapse:separate}.input-group[class*=col-]{float:none;padding-right:0;padding-left:0}.input-group .form-control{position:relative;z-index:2;float:left;width:100%;margin-bottom:0}.input-group-lg>.form-control,.input-group-lg>.input-group-addon,.input-group-lg>.input-group-btn>.btn{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;-webkit-border-radius:6px;border-radius:6px}select.input-group-lg>.form-control,select.input-group-lg>.input-group-addon,select.input-group-lg>.input-group-btn>.btn{height:46px;line-height:46px}select[multiple].input-group-lg>.form-control,select[multiple].input-group-lg>.input-group-addon,select[multiple].input-group-lg>.input-group-btn>.btn,textarea.input-group-lg>.form-control,textarea.input-group-lg>.input-group-addon,textarea.input-group-lg>.input-group-btn>.btn{height:auto}.input-group-sm>.form-control,.input-group-sm>.input-group-addon,.input-group-sm>.input-group-btn>.btn{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;-webkit-border-radius:3px;border-radius:3px}select.input-group-sm>.form-control,select.input-group-sm>.input-group-addon,select.input-group-sm>.input-group-btn>.btn{height:30px;line-height:30px}select[multiple].input-group-sm>.form-control,select[multiple].input-group-sm>.input-group-addon,select[multiple].input-group-sm>.input-group-btn>.btn,textarea.input-group-sm>.form-control,textarea.input-group-sm>.input-group-addon,textarea.input-group-sm>.input-group-btn>.btn{height:auto}.input-group .form-control,.input-group-addon,.input-group-btn{display:table-cell}.nav>li,.nav>li>a{display:block;position:relative}.input-group .form-control:not(:first-child):not(:last-child),.input-group-addon:not(:first-child):not(:last-child),.input-group-btn:not(:first-child):not(:last-child){-webkit-border-radius:0;border-radius:0}.input-group-addon,.input-group-btn{width:1%;white-space:nowrap;vertical-align:middle}.input-group-addon{padding:6px 12px;font-size:14px;font-weight:400;line-height:1;color:#555;text-align:center;background-color:#eee;border:1px solid #ccc;-webkit-border-radius:4px;border-radius:4px}.input-group-addon.input-sm{padding:5px 10px;font-size:12px;-webkit-border-radius:3px;border-radius:3px}.input-group-addon.input-lg{padding:10px 16px;font-size:18px;-webkit-border-radius:6px;border-radius:6px}.input-group-addon input[type=checkbox],.input-group-addon input[type=radio]{margin-top:0}.input-group .form-control:first-child,.input-group-addon:first-child,.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group>.btn,.input-group-btn:first-child>.dropdown-toggle,.input-group-btn:last-child>.btn-group:not(:last-child)>.btn,.input-group-btn:last-child>.btn:not(:last-child):not(.dropdown-toggle){-webkit-border-top-right-radius:0;border-top-right-radius:0;-webkit-border-bottom-right-radius:0;border-bottom-right-radius:0}.input-group-addon:first-child{border-right:0}.input-group .form-control:last-child,.input-group-addon:last-child,.input-group-btn:first-child>.btn-group:not(:first-child)>.btn,.input-group-btn:first-child>.btn:not(:first-child),.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group>.btn,.input-group-btn:last-child>.dropdown-toggle{-webkit-border-top-left-radius:0;border-top-left-radius:0;-webkit-border-bottom-left-radius:0;border-bottom-left-radius:0}.input-group-addon:last-child{border-left:0}.input-group-btn{position:relative;font-size:0;white-space:nowrap}.input-group-btn>.btn{position:relative}.input-group-btn>.btn+.btn{margin-left:-1px}.input-group-btn>.btn:active,.input-group-btn>.btn:focus,.input-group-btn>.btn:hover{z-index:2}.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group{margin-right:-1px}.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group{z-index:2;margin-left:-1px}.nav{padding-left:0;margin-bottom:0;list-style:none}.nav>li>a{padding:10px 15px}.nav>li>a:focus,.nav>li>a:hover{text-decoration:none;background-color:#eee}.nav>li.disabled>a{color:#777}.nav>li.disabled>a:focus,.nav>li.disabled>a:hover{color:#777;text-decoration:none;cursor:not-allowed;background-color:transparent}.nav .open>a,.nav .open>a:focus,.nav .open>a:hover{background-color:#eee;border-color:#337ab7}.nav .nav-divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.nav>li>a>img{max-width:none}.nav-tabs{border-bottom:1px solid #ddd}.nav-tabs>li{float:left;margin-bottom:-1px}.nav-tabs>li>a{margin-right:2px;line-height:1.42857143;border:1px solid transparent;-webkit-border-radius:4px 4px 0 0;border-radius:4px 4px 0 0}.nav-tabs>li>a:hover{border-color:#eee #eee #ddd}.nav-tabs>li.active>a,.nav-tabs>li.active>a:focus,.nav-tabs>li.active>a:hover{color:#555;cursor:default;background-color:#fff;border:1px solid #ddd;border-bottom-color:transparent}.nav-tabs.nav-justified{width:100%;border-bottom:0}.nav-tabs.nav-justified>li{float:none}.nav-tabs.nav-justified>li>a{margin-bottom:5px;text-align:center;margin-right:0;-webkit-border-radius:4px;border-radius:4px}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:focus,.nav-tabs.nav-justified>.active>a:hover{border:1px solid #ddd}@media (min-width:768px){.nav-tabs.nav-justified>li{display:table-cell;width:1%}.nav-tabs.nav-justified>li>a{margin-bottom:0;border-bottom:1px solid #ddd;-webkit-border-radius:4px 4px 0 0;border-radius:4px 4px 0 0}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:focus,.nav-tabs.nav-justified>.active>a:hover{border-bottom-color:#fff}}.nav-pills>li{float:left}.nav-justified>li,.nav-stacked>li{float:none}.nav-pills>li>a{-webkit-border-radius:4px;border-radius:4px}.nav-pills>li+li{margin-left:2px}.nav-pills>li.active>a,.nav-pills>li.active>a:focus,.nav-pills>li.active>a:hover{color:#fff;background-color:#337ab7}.nav-stacked>li+li{margin-top:2px;margin-left:0}.nav-justified{width:100%}.nav-justified>li>a{margin-bottom:5px;text-align:center}.nav-tabs-justified{border-bottom:0}.nav-tabs-justified>li>a{margin-right:0;-webkit-border-radius:4px;border-radius:4px}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:focus,.nav-tabs-justified>.active>a:hover{border:1px solid #ddd}@media (min-width:768px){.nav-justified>li{display:table-cell;width:1%}.nav-justified>li>a{margin-bottom:0}.nav-tabs-justified>li>a{border-bottom:1px solid #ddd;-webkit-border-radius:4px 4px 0 0;border-radius:4px 4px 0 0}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:focus,.nav-tabs-justified>.active>a:hover{border-bottom-color:#fff}}.tab-content>.tab-pane{display:none}.tab-content>.active{display:block}.nav-tabs .dropdown-menu{margin-top:-1px;-webkit-border-top-left-radius:0;border-top-left-radius:0;-webkit-border-top-right-radius:0;border-top-right-radius:0}.navbar{position:relative;min-height:50px;margin-bottom:20px;border:1px solid transparent}.navbar-collapse{padding-right:15px;padding-left:15px;overflow-x:visible;-webkit-overflow-scrolling:touch;border-top:1px solid transparent;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 0 rgba(255,255,255,.1)}.navbar-collapse.in{overflow-y:auto}@media (min-width:768px){.navbar{-webkit-border-radius:4px;border-radius:4px}.navbar-header{float:left}.navbar-collapse{width:auto;border-top:0;-webkit-box-shadow:none;box-shadow:none}.navbar-collapse.collapse{display:block!important;height:auto!important;padding-bottom:0;overflow:visible!important}.navbar-collapse.in{overflow-y:visible}.navbar-fixed-bottom .navbar-collapse,.navbar-fixed-top .navbar-collapse,.navbar-static-top .navbar-collapse{padding-right:0;padding-left:0}}.embed-responsive,.modal,.modal-open,.progress{overflow:hidden}@media (max-device-width:480px) and (orientation:landscape){.navbar-fixed-bottom .navbar-collapse,.navbar-fixed-top .navbar-collapse{max-height:200px}}.container-fluid>.navbar-collapse,.container-fluid>.navbar-header,.container>.navbar-collapse,.container>.navbar-header{margin-right:-15px;margin-left:-15px}.navbar-static-top{z-index:1000;border-width:0 0 1px}.navbar-fixed-bottom,.navbar-fixed-top{position:fixed;right:0;left:0;z-index:1030}.navbar-fixed-top{top:0;border-width:0 0 1px}.navbar-fixed-bottom{bottom:0;margin-bottom:0;border-width:1px 0 0}.navbar-brand{float:left;height:50px;padding:15px;font-size:18px;line-height:20px}.navbar-brand:focus,.navbar-brand:hover{text-decoration:none}.navbar-brand>img{display:block}@media (min-width:768px){.container-fluid>.navbar-collapse,.container-fluid>.navbar-header,.container>.navbar-collapse,.container>.navbar-header{margin-right:0;margin-left:0}.navbar-fixed-bottom,.navbar-fixed-top,.navbar-static-top{-webkit-border-radius:0;border-radius:0}.navbar>.container .navbar-brand,.navbar>.container-fluid .navbar-brand{margin-left:-15px}}.navbar-toggle{position:relative;float:right;padding:9px 10px;margin-top:8px;margin-right:15px;margin-bottom:8px;background-color:transparent;border:1px solid transparent;-webkit-border-radius:4px;border-radius:4px}.navbar-toggle:focus{outline:0}.navbar-toggle .icon-bar{display:block;width:22px;height:2px;-webkit-border-radius:1px;border-radius:1px}.navbar-toggle .icon-bar+.icon-bar{margin-top:4px}.navbar-nav{margin:7.5px -15px}.navbar-nav>li>a{padding-top:10px;padding-bottom:10px;line-height:20px}@media (max-width:767px){.navbar-nav .open .dropdown-menu{position:static;float:none;width:auto;margin-top:0;background-color:transparent;border:0;-webkit-box-shadow:none;box-shadow:none}.navbar-nav .open .dropdown-menu .dropdown-header,.navbar-nav .open .dropdown-menu>li>a{padding:5px 15px 5px 25px}.navbar-nav .open .dropdown-menu>li>a{line-height:20px}.navbar-nav .open .dropdown-menu>li>a:focus,.navbar-nav .open .dropdown-menu>li>a:hover{background-image:none}}.progress-bar-striped,.progress-striped .progress-bar,.progress-striped .progress-bar-success{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}@media (min-width:768px){.navbar-toggle{display:none}.navbar-nav{float:left;margin:0}.navbar-nav>li{float:left}.navbar-nav>li>a{padding-top:15px;padding-bottom:15px}}.navbar-form{padding:10px 15px;border-top:1px solid transparent;border-bottom:1px solid transparent;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1);margin:8px -15px}@media (min-width:768px){.navbar-form .form-control-static,.navbar-form .form-group{display:inline-block}.navbar-form .control-label,.navbar-form .form-group{margin-bottom:0;vertical-align:middle}.navbar-form .form-control{display:inline-block;width:auto;vertical-align:middle}.navbar-form .input-group{display:inline-table;vertical-align:middle}.navbar-form .input-group .form-control,.navbar-form .input-group .input-group-addon,.navbar-form .input-group .input-group-btn{width:auto}.navbar-form .input-group>.form-control{width:100%}.navbar-form .checkbox,.navbar-form .radio{display:inline-block;margin-top:0;margin-bottom:0;vertical-align:middle}.navbar-form .checkbox label,.navbar-form .radio label{padding-left:0}.navbar-form .checkbox input[type=checkbox],.navbar-form .radio input[type=radio]{position:relative;margin-left:0}.navbar-form .has-feedback .form-control-feedback{top:0}.navbar-form{width:auto;padding-top:0;padding-bottom:0;margin-right:0;margin-left:0;border:0;-webkit-box-shadow:none;box-shadow:none}}.breadcrumb>li,.pagination{display:inline-block}.btn .badge,.btn .label{top:-1px;position:relative}@media (max-width:767px){.navbar-form .form-group{margin-bottom:5px}.navbar-form .form-group:last-child{margin-bottom:0}}.navbar-nav>li>.dropdown-menu{margin-top:0;-webkit-border-top-left-radius:0;border-top-left-radius:0;-webkit-border-top-right-radius:0;border-top-right-radius:0}.navbar-fixed-bottom .navbar-nav>li>.dropdown-menu{margin-bottom:0;-webkit-border-radius:4px 4px 0 0;border-radius:4px 4px 0 0}.navbar-btn{margin-top:8px;margin-bottom:8px}.navbar-btn.btn-sm{margin-top:10px;margin-bottom:10px}.navbar-btn.btn-xs{margin-top:14px;margin-bottom:14px}.navbar-text{margin-top:15px;margin-bottom:15px}@media (min-width:768px){.navbar-text{float:left;margin-right:15px;margin-left:15px}.navbar-left{float:left!important}.navbar-right{float:right!important;margin-right:-15px}.navbar-right~.navbar-right{margin-right:0}}.navbar-default{background-color:#f8f8f8;border-color:#e7e7e7}.navbar-default .navbar-brand{color:#777}.navbar-default .navbar-brand:focus,.navbar-default .navbar-brand:hover{color:#5e5e5e;background-color:transparent}.navbar-default .navbar-nav>li>a,.navbar-default .navbar-text{color:#777}.navbar-default .navbar-nav>li>a:focus,.navbar-default .navbar-nav>li>a:hover{color:#333;background-color:transparent}.navbar-default .navbar-nav>.active>a,.navbar-default .navbar-nav>.active>a:focus,.navbar-default .navbar-nav>.active>a:hover{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav>.disabled>a,.navbar-default .navbar-nav>.disabled>a:focus,.navbar-default .navbar-nav>.disabled>a:hover{color:#ccc;background-color:transparent}.navbar-default .navbar-toggle{border-color:#ddd}.navbar-default .navbar-toggle:focus,.navbar-default .navbar-toggle:hover{background-color:#ddd}.navbar-default .navbar-toggle .icon-bar{background-color:#888}.navbar-default .navbar-collapse,.navbar-default .navbar-form{border-color:#e7e7e7}.navbar-default .navbar-nav>.open>a,.navbar-default .navbar-nav>.open>a:focus,.navbar-default .navbar-nav>.open>a:hover{color:#555;background-color:#e7e7e7}@media (max-width:767px){.navbar-default .navbar-nav .open .dropdown-menu>li>a{color:#777}.navbar-default .navbar-nav .open .dropdown-menu>li>a:focus,.navbar-default .navbar-nav .open .dropdown-menu>li>a:hover{color:#333;background-color:transparent}.navbar-default .navbar-nav .open .dropdown-menu>.active>a,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:focus,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:hover{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:focus,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:hover{color:#ccc;background-color:transparent}}.navbar-default .navbar-link{color:#777}.navbar-default .navbar-link:hover{color:#333}.navbar-default .btn-link{color:#777}.navbar-default .btn-link:focus,.navbar-default .btn-link:hover{color:#333}.navbar-default .btn-link[disabled]:focus,.navbar-default .btn-link[disabled]:hover,fieldset[disabled] .navbar-default .btn-link:focus,fieldset[disabled] .navbar-default .btn-link:hover{color:#ccc}.navbar-inverse{background-color:#222;border-color:#080808}.navbar-inverse .navbar-brand{color:#9d9d9d}.navbar-inverse .navbar-brand:focus,.navbar-inverse .navbar-brand:hover{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav>li>a,.navbar-inverse .navbar-text{color:#9d9d9d}.navbar-inverse .navbar-nav>li>a:focus,.navbar-inverse .navbar-nav>li>a:hover{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav>.active>a,.navbar-inverse .navbar-nav>.active>a:focus,.navbar-inverse .navbar-nav>.active>a:hover{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav>.disabled>a,.navbar-inverse .navbar-nav>.disabled>a:focus,.navbar-inverse .navbar-nav>.disabled>a:hover{color:#444;background-color:transparent}.navbar-inverse .navbar-toggle{border-color:#333}.navbar-inverse .navbar-toggle:focus,.navbar-inverse .navbar-toggle:hover{background-color:#333}.navbar-inverse .navbar-toggle .icon-bar{background-color:#fff}.navbar-inverse .navbar-collapse,.navbar-inverse .navbar-form{border-color:#101010}.navbar-inverse .navbar-nav>.open>a,.navbar-inverse .navbar-nav>.open>a:focus,.navbar-inverse .navbar-nav>.open>a:hover{color:#fff;background-color:#080808}@media (max-width:767px){.navbar-inverse .navbar-nav .open .dropdown-menu>.dropdown-header{border-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu .divider{background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a{color:#9d9d9d}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:focus,.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:hover{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:focus,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:hover{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:focus,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:hover{color:#444;background-color:transparent}}.navbar-inverse .navbar-link{color:#9d9d9d}.navbar-inverse .navbar-link:hover{color:#fff}.navbar-inverse .btn-link{color:#9d9d9d}.navbar-inverse .btn-link:focus,.navbar-inverse .btn-link:hover{color:#fff}.navbar-inverse .btn-link[disabled]:focus,.navbar-inverse .btn-link[disabled]:hover,fieldset[disabled] .navbar-inverse .btn-link:focus,fieldset[disabled] .navbar-inverse .btn-link:hover{color:#444}.breadcrumb{padding:8px 15px;margin-bottom:20px;list-style:none;background-color:#f5f5f5;-webkit-border-radius:4px;border-radius:4px}.breadcrumb>li+li:before{padding:0 5px;color:#ccc;content:"/\00a0"}.breadcrumb>.active{color:#777}.pagination{padding-left:0;margin:20px 0;-webkit-border-radius:4px;border-radius:4px}.pager li,.pagination>li{display:inline}.pagination>li>a,.pagination>li>span{position:relative;float:left;padding:6px 12px;margin-left:-1px;line-height:1.42857143;color:#337ab7;text-decoration:none;background-color:#fff;border:1px solid #ddd}.pagination>li:first-child>a,.pagination>li:first-child>span{margin-left:0;-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px}.pagination>li:last-child>a,.pagination>li:last-child>span{-webkit-border-top-right-radius:4px;border-top-right-radius:4px;-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px}.pagination>li>a:focus,.pagination>li>a:hover,.pagination>li>span:focus,.pagination>li>span:hover{z-index:3;color:#23527c;background-color:#eee;border-color:#ddd}.pagination>.active>a,.pagination>.active>a:focus,.pagination>.active>a:hover,.pagination>.active>span,.pagination>.active>span:focus,.pagination>.active>span:hover{z-index:2;color:#fff;cursor:default;background-color:#337ab7;border-color:#337ab7}.pagination>.disabled>a,.pagination>.disabled>a:focus,.pagination>.disabled>a:hover,.pagination>.disabled>span,.pagination>.disabled>span:focus,.pagination>.disabled>span:hover{color:#777;cursor:not-allowed;background-color:#fff;border-color:#ddd}.pagination-lg>li>a,.pagination-lg>li>span{padding:10px 16px;font-size:18px;line-height:1.3333333}.pagination-lg>li:first-child>a,.pagination-lg>li:first-child>span{-webkit-border-top-left-radius:6px;border-top-left-radius:6px;-webkit-border-bottom-left-radius:6px;border-bottom-left-radius:6px}.pagination-lg>li:last-child>a,.pagination-lg>li:last-child>span{-webkit-border-top-right-radius:6px;border-top-right-radius:6px;-webkit-border-bottom-right-radius:6px;border-bottom-right-radius:6px}.pagination-sm>li>a,.pagination-sm>li>span{padding:5px 10px;font-size:12px;line-height:1.5}.badge,.label{font-weight:700;line-height:1;white-space:nowrap;text-align:center}.pagination-sm>li:first-child>a,.pagination-sm>li:first-child>span{-webkit-border-top-left-radius:3px;border-top-left-radius:3px;-webkit-border-bottom-left-radius:3px;border-bottom-left-radius:3px}.pagination-sm>li:last-child>a,.pagination-sm>li:last-child>span{-webkit-border-top-right-radius:3px;border-top-right-radius:3px;-webkit-border-bottom-right-radius:3px;border-bottom-right-radius:3px}.pager{padding-left:0;margin:20px 0;text-align:center;list-style:none}.pager li>a,.pager li>span{display:inline-block;padding:5px 14px;background-color:#fff;border:1px solid #ddd;-webkit-border-radius:15px;border-radius:15px}.pager li>a:focus,.pager li>a:hover{text-decoration:none;background-color:#eee}.pager .next>a,.pager .next>span{float:right}.pager .previous>a,.pager .previous>span{float:left}.pager .disabled>a,.pager .disabled>a:focus,.pager .disabled>a:hover,.pager .disabled>span{color:#777;cursor:not-allowed;background-color:#fff}.label{display:inline;padding:.2em .6em .3em;font-size:75%;color:#fff;-webkit-border-radius:.25em;border-radius:.25em}a.label:focus,a.label:hover{color:#fff;text-decoration:none;cursor:pointer}.label:empty{display:none}.label-default{background-color:#777}.label-default[href]:focus,.label-default[href]:hover{background-color:#5e5e5e}.label-primary{background-color:#337ab7}.label-primary[href]:focus,.label-primary[href]:hover{background-color:#286090}.label-success{background-color:#5cb85c}.label-success[href]:focus,.label-success[href]:hover{background-color:#449d44}.label-info{background-color:#5bc0de}.label-info[href]:focus,.label-info[href]:hover{background-color:#31b0d5}.label-warning{background-color:#f0ad4e}.label-warning[href]:focus,.label-warning[href]:hover{background-color:#ec971f}.label-danger{background-color:#d9534f}.label-danger[href]:focus,.label-danger[href]:hover{background-color:#c9302c}.badge{display:inline-block;min-width:10px;padding:3px 7px;font-size:12px;color:#fff;vertical-align:middle;background-color:#777;-webkit-border-radius:10px;border-radius:10px}.badge:empty{display:none}.media-object,.thumbnail{display:block}.btn-group-xs>.btn .badge,.btn-xs .badge{top:0;padding:1px 5px}a.badge:focus,a.badge:hover{color:#fff;text-decoration:none;cursor:pointer}.list-group-item.active>.badge,.nav-pills>.active>a>.badge{color:#337ab7;background-color:#fff}.jumbotron,.jumbotron .h1,.jumbotron h1{color:inherit}.list-group-item>.badge{float:right}.list-group-item>.badge+.badge{margin-right:5px}.nav-pills>li>a>.badge{margin-left:3px}.jumbotron{padding-top:30px;padding-bottom:30px;margin-bottom:30px;background-color:#eee}.jumbotron p{margin-bottom:15px;font-size:21px;font-weight:200}.alert,.thumbnail{margin-bottom:20px}.alert .alert-link,.close{font-weight:700}.jumbotron>hr{border-top-color:#d5d5d5}.container .jumbotron,.container-fluid .jumbotron{-webkit-border-radius:6px;border-radius:6px}.jumbotron .container{max-width:100%}@media screen and (min-width:768px){.jumbotron{padding-top:48px;padding-bottom:48px}.container .jumbotron,.container-fluid .jumbotron{padding-right:60px;padding-left:60px}.jumbotron .h1,.jumbotron h1{font-size:63px}}.thumbnail{padding:4px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;-webkit-border-radius:4px;border-radius:4px;-webkit-transition:border .2s ease-in-out;transition:border .2s ease-in-out}.thumbnail a>img,.thumbnail>img{margin-right:auto;margin-left:auto}a.thumbnail.active,a.thumbnail:focus,a.thumbnail:hover{border-color:#337ab7}.thumbnail .caption{padding:9px;color:#333}.alert{padding:15px;border:1px solid transparent;-webkit-border-radius:4px;border-radius:4px}.alert h4{margin-top:0;color:inherit}.alert>p,.alert>ul{margin-bottom:0}.alert>p+p{margin-top:5px}.alert-dismissable,.alert-dismissible{padding-right:35px}.alert-dismissable .close,.alert-dismissible .close{position:relative;top:-2px;right:-21px;color:inherit}.modal,.modal-backdrop{top:0;right:0;bottom:0;left:0}.alert-success{color:#3c763d;background-color:#dff0d8;border-color:#d6e9c6}.alert-success hr{border-top-color:#c9e2b3}.alert-success .alert-link{color:#2b542c}.alert-info{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.alert-info hr{border-top-color:#a6e1ec}.alert-info .alert-link{color:#245269}.alert-warning{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}.alert-warning hr{border-top-color:#f7e1b5}.alert-warning .alert-link{color:#66512c}.alert-danger{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.alert-danger hr{border-top-color:#e4b9c0}.alert-danger .alert-link{color:#843534}@-webkit-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}.progress{height:20px;margin-bottom:20px;background-color:#f5f5f5;-webkit-border-radius:4px;border-radius:4px;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1)}.progress-bar{float:left;width:0;height:100%;font-size:12px;line-height:20px;color:#fff;text-align:center;background-color:#337ab7;-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);-webkit-transition:width .6s ease;transition:width .6s ease}.progress-bar-striped,.progress-striped .progress-bar{background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-size:40px 40px}.progress-bar.active,.progress.active .progress-bar{-webkit-animation:progress-bar-stripes 2s linear infinite;animation:progress-bar-stripes 2s linear infinite}.progress-bar-success{background-color:#5cb85c}.progress-striped .progress-bar-success{background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-striped .progress-bar-info,.progress-striped .progress-bar-warning{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-info{background-color:#5bc0de}.progress-striped .progress-bar-info{background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-warning{background-color:#f0ad4e}.progress-striped .progress-bar-warning{background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-danger{background-color:#d9534f}.progress-striped .progress-bar-danger{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.media{margin-top:15px}.media:first-child{margin-top:0}.media,.media-body{overflow:hidden;zoom:1}.media-body{width:10000px}.media-object.img-thumbnail{max-width:none}.media-right,.media>.pull-right{padding-left:10px}.media-left,.media>.pull-left{padding-right:10px}.media-body,.media-left,.media-right{display:table-cell;vertical-align:top}.media-middle{vertical-align:middle}.media-bottom{vertical-align:bottom}.media-heading{margin-top:0;margin-bottom:5px}.media-list{padding-left:0;list-style:none}.list-group{padding-left:0;margin-bottom:20px}.list-group-item{position:relative;display:block;padding:10px 15px;margin-bottom:-1px;background-color:#fff;border:1px solid #ddd}.list-group-item:first-child{-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-webkit-border-top-right-radius:4px;border-top-right-radius:4px}.list-group-item:last-child{margin-bottom:0;-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px}a.list-group-item,button.list-group-item{color:#555}a.list-group-item .list-group-item-heading,button.list-group-item .list-group-item-heading{color:#333}a.list-group-item:focus,a.list-group-item:hover,button.list-group-item:focus,button.list-group-item:hover{color:#555;text-decoration:none;background-color:#f5f5f5}button.list-group-item{width:100%;text-align:left}.list-group-item.disabled,.list-group-item.disabled:focus,.list-group-item.disabled:hover{color:#777;cursor:not-allowed;background-color:#eee}.list-group-item.disabled .list-group-item-heading,.list-group-item.disabled:focus .list-group-item-heading,.list-group-item.disabled:hover .list-group-item-heading{color:inherit}.list-group-item.disabled .list-group-item-text,.list-group-item.disabled:focus .list-group-item-text,.list-group-item.disabled:hover .list-group-item-text{color:#777}.list-group-item.active,.list-group-item.active:focus,.list-group-item.active:hover{z-index:2;color:#fff;background-color:#337ab7;border-color:#337ab7}.list-group-item.active .list-group-item-heading,.list-group-item.active .list-group-item-heading>.small,.list-group-item.active .list-group-item-heading>small,.list-group-item.active:focus .list-group-item-heading,.list-group-item.active:focus .list-group-item-heading>.small,.list-group-item.active:focus .list-group-item-heading>small,.list-group-item.active:hover .list-group-item-heading,.list-group-item.active:hover .list-group-item-heading>.small,.list-group-item.active:hover .list-group-item-heading>small{color:inherit}.list-group-item.active .list-group-item-text,.list-group-item.active:focus .list-group-item-text,.list-group-item.active:hover .list-group-item-text{color:#c7ddef}.list-group-item-success{color:#3c763d;background-color:#dff0d8}a.list-group-item-success,button.list-group-item-success{color:#3c763d}a.list-group-item-success .list-group-item-heading,button.list-group-item-success .list-group-item-heading{color:inherit}a.list-group-item-success:focus,a.list-group-item-success:hover,button.list-group-item-success:focus,button.list-group-item-success:hover{color:#3c763d;background-color:#d0e9c6}a.list-group-item-success.active,a.list-group-item-success.active:focus,a.list-group-item-success.active:hover,button.list-group-item-success.active,button.list-group-item-success.active:focus,button.list-group-item-success.active:hover{color:#fff;background-color:#3c763d;border-color:#3c763d}.list-group-item-info{color:#31708f;background-color:#d9edf7}a.list-group-item-info,button.list-group-item-info{color:#31708f}a.list-group-item-info .list-group-item-heading,button.list-group-item-info .list-group-item-heading{color:inherit}a.list-group-item-info:focus,a.list-group-item-info:hover,button.list-group-item-info:focus,button.list-group-item-info:hover{color:#31708f;background-color:#c4e3f3}a.list-group-item-info.active,a.list-group-item-info.active:focus,a.list-group-item-info.active:hover,button.list-group-item-info.active,button.list-group-item-info.active:focus,button.list-group-item-info.active:hover{color:#fff;background-color:#31708f;border-color:#31708f}.list-group-item-warning{color:#8a6d3b;background-color:#fcf8e3}a.list-group-item-warning,button.list-group-item-warning{color:#8a6d3b}a.list-group-item-warning .list-group-item-heading,button.list-group-item-warning .list-group-item-heading{color:inherit}a.list-group-item-warning:focus,a.list-group-item-warning:hover,button.list-group-item-warning:focus,button.list-group-item-warning:hover{color:#8a6d3b;background-color:#faf2cc}a.list-group-item-warning.active,a.list-group-item-warning.active:focus,a.list-group-item-warning.active:hover,button.list-group-item-warning.active,button.list-group-item-warning.active:focus,button.list-group-item-warning.active:hover{color:#fff;background-color:#8a6d3b;border-color:#8a6d3b}.list-group-item-danger{color:#a94442;background-color:#f2dede}a.list-group-item-danger,button.list-group-item-danger{color:#a94442}a.list-group-item-danger .list-group-item-heading,button.list-group-item-danger .list-group-item-heading{color:inherit}a.list-group-item-danger:focus,a.list-group-item-danger:hover,button.list-group-item-danger:focus,button.list-group-item-danger:hover{color:#a94442;background-color:#ebcccc}a.list-group-item-danger.active,a.list-group-item-danger.active:focus,a.list-group-item-danger.active:hover,button.list-group-item-danger.active,button.list-group-item-danger.active:focus,button.list-group-item-danger.active:hover{color:#fff;background-color:#a94442;border-color:#a94442}.panel-heading>.dropdown .dropdown-toggle,.panel-title,.panel-title>.small,.panel-title>.small>a,.panel-title>a,.panel-title>small,.panel-title>small>a{color:inherit}.list-group-item-heading{margin-top:0;margin-bottom:5px}.list-group-item-text{margin-bottom:0;line-height:1.3}.carousel-inner>.item>a>img,.carousel-inner>.item>img,.close{line-height:1}.panel{margin-bottom:20px;background-color:#fff;border:1px solid transparent;-webkit-border-radius:4px;border-radius:4px;-webkit-box-shadow:0 1px 1px rgba(0,0,0,.05);box-shadow:0 1px 1px rgba(0,0,0,.05)}.panel-title,.panel>.list-group,.panel>.panel-collapse>.list-group,.panel>.panel-collapse>.table,.panel>.table,.panel>.table-responsive>.table{margin-bottom:0}.panel-body{padding:15px}.panel-heading{padding:10px 15px;border-bottom:1px solid transparent;-webkit-border-top-left-radius:3px;border-top-left-radius:3px;-webkit-border-top-right-radius:3px;border-top-right-radius:3px}.panel-title{margin-top:0;font-size:16px}.panel-footer{padding:10px 15px;background-color:#f5f5f5;border-top:1px solid #ddd;-webkit-border-bottom-right-radius:3px;border-bottom-right-radius:3px;-webkit-border-bottom-left-radius:3px;border-bottom-left-radius:3px}.panel>.list-group .list-group-item,.panel>.panel-collapse>.list-group .list-group-item{border-width:1px 0;-webkit-border-radius:0;border-radius:0}.panel-group .panel-heading,.panel>.table-bordered>tbody>tr:first-child>td,.panel>.table-bordered>tbody>tr:first-child>th,.panel>.table-bordered>tbody>tr:last-child>td,.panel>.table-bordered>tbody>tr:last-child>th,.panel>.table-bordered>tfoot>tr:last-child>td,.panel>.table-bordered>tfoot>tr:last-child>th,.panel>.table-bordered>thead>tr:first-child>td,.panel>.table-bordered>thead>tr:first-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:first-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:first-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>th,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>td,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>th,.panel>.table-responsive>.table-bordered>thead>tr:first-child>td,.panel>.table-responsive>.table-bordered>thead>tr:first-child>th{border-bottom:0}.panel>.list-group:first-child .list-group-item:first-child,.panel>.panel-collapse>.list-group:first-child .list-group-item:first-child{border-top:0;-webkit-border-top-left-radius:3px;border-top-left-radius:3px;-webkit-border-top-right-radius:3px;border-top-right-radius:3px}.panel>.list-group:last-child .list-group-item:last-child,.panel>.panel-collapse>.list-group:last-child .list-group-item:last-child{border-bottom:0;-webkit-border-bottom-right-radius:3px;border-bottom-right-radius:3px;-webkit-border-bottom-left-radius:3px;border-bottom-left-radius:3px}.panel>.panel-heading+.panel-collapse>.list-group .list-group-item:first-child{-webkit-border-top-left-radius:0;border-top-left-radius:0;-webkit-border-top-right-radius:0;border-top-right-radius:0}.list-group+.panel-footer,.panel-heading+.list-group .list-group-item:first-child{border-top-width:0}.panel>.panel-collapse>.table caption,.panel>.table caption,.panel>.table-responsive>.table caption{padding-right:15px;padding-left:15px}.panel>.table-responsive:first-child>.table:first-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child,.panel>.table:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child,.panel>.table:first-child>thead:first-child>tr:first-child{-webkit-border-top-left-radius:3px;border-top-left-radius:3px;-webkit-border-top-right-radius:3px;border-top-right-radius:3px}.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child td:first-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child th:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child td:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child th:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child td:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child th:first-child,.panel>.table:first-child>thead:first-child>tr:first-child td:first-child,.panel>.table:first-child>thead:first-child>tr:first-child th:first-child{-webkit-border-top-left-radius:3px;border-top-left-radius:3px}.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child td:last-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child th:last-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child td:last-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child th:last-child,.panel>.table:first-child>tbody:first-child>tr:first-child td:last-child,.panel>.table:first-child>tbody:first-child>tr:first-child th:last-child,.panel>.table:first-child>thead:first-child>tr:first-child td:last-child,.panel>.table:first-child>thead:first-child>tr:first-child th:last-child{-webkit-border-top-right-radius:3px;border-top-right-radius:3px}.panel>.table-responsive:last-child>.table:last-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child,.panel>.table:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child{-webkit-border-bottom-right-radius:3px;border-bottom-right-radius:3px;-webkit-border-bottom-left-radius:3px;border-bottom-left-radius:3px}.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child td:first-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child th:first-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child td:first-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child th:first-child,.panel>.table:last-child>tbody:last-child>tr:last-child td:first-child,.panel>.table:last-child>tbody:last-child>tr:last-child th:first-child,.panel>.table:last-child>tfoot:last-child>tr:last-child td:first-child,.panel>.table:last-child>tfoot:last-child>tr:last-child th:first-child{-webkit-border-bottom-left-radius:3px;border-bottom-left-radius:3px}.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child td:last-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child th:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child td:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child th:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child td:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child th:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child td:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child th:last-child{-webkit-border-bottom-right-radius:3px;border-bottom-right-radius:3px}.panel>.panel-body+.table,.panel>.panel-body+.table-responsive,.panel>.table+.panel-body,.panel>.table-responsive+.panel-body{border-top:1px solid #ddd}.panel>.table>tbody:first-child>tr:first-child td,.panel>.table>tbody:first-child>tr:first-child th{border-top:0}.panel>.table-bordered,.panel>.table-responsive>.table-bordered{border:0}.panel>.table-bordered>tbody>tr>td:first-child,.panel>.table-bordered>tbody>tr>th:first-child,.panel>.table-bordered>tfoot>tr>td:first-child,.panel>.table-bordered>tfoot>tr>th:first-child,.panel>.table-bordered>thead>tr>td:first-child,.panel>.table-bordered>thead>tr>th:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:first-child,.panel>.table-responsive>.table-bordered>thead>tr>td:first-child,.panel>.table-responsive>.table-bordered>thead>tr>th:first-child{border-left:0}.panel>.table-bordered>tbody>tr>td:last-child,.panel>.table-bordered>tbody>tr>th:last-child,.panel>.table-bordered>tfoot>tr>td:last-child,.panel>.table-bordered>tfoot>tr>th:last-child,.panel>.table-bordered>thead>tr>td:last-child,.panel>.table-bordered>thead>tr>th:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:last-child,.panel>.table-responsive>.table-bordered>thead>tr>td:last-child,.panel>.table-responsive>.table-bordered>thead>tr>th:last-child{border-right:0}.panel>.table-responsive{margin-bottom:0;border:0}.panel-group{margin-bottom:20px}.panel-group .panel{margin-bottom:0;-webkit-border-radius:4px;border-radius:4px}.panel-group .panel+.panel{margin-top:5px}.panel-group .panel-heading+.panel-collapse>.list-group,.panel-group .panel-heading+.panel-collapse>.panel-body{border-top:1px solid #ddd}.panel-group .panel-footer{border-top:0}.panel-group .panel-footer+.panel-collapse .panel-body{border-bottom:1px solid #ddd}.panel-default{border-color:#ddd}.panel-default>.panel-heading{color:#333;background-color:#f5f5f5;border-color:#ddd}.panel-default>.panel-heading+.panel-collapse>.panel-body{border-top-color:#ddd}.panel-default>.panel-heading .badge{color:#f5f5f5;background-color:#333}.panel-default>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#ddd}.panel-primary{border-color:#337ab7}.panel-primary>.panel-heading{color:#fff;background-color:#337ab7;border-color:#337ab7}.panel-primary>.panel-heading+.panel-collapse>.panel-body{border-top-color:#337ab7}.panel-primary>.panel-heading .badge{color:#337ab7;background-color:#fff}.panel-primary>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#337ab7}.panel-success{border-color:#d6e9c6}.panel-success>.panel-heading{color:#3c763d;background-color:#dff0d8;border-color:#d6e9c6}.panel-success>.panel-heading+.panel-collapse>.panel-body{border-top-color:#d6e9c6}.panel-success>.panel-heading .badge{color:#dff0d8;background-color:#3c763d}.panel-success>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#d6e9c6}.panel-info{border-color:#bce8f1}.panel-info>.panel-heading{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.panel-info>.panel-heading+.panel-collapse>.panel-body{border-top-color:#bce8f1}.panel-info>.panel-heading .badge{color:#d9edf7;background-color:#31708f}.panel-info>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#bce8f1}.panel-warning{border-color:#faebcc}.panel-warning>.panel-heading{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}.panel-warning>.panel-heading+.panel-collapse>.panel-body{border-top-color:#faebcc}.panel-warning>.panel-heading .badge{color:#fcf8e3;background-color:#8a6d3b}.panel-warning>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#faebcc}.panel-danger{border-color:#ebccd1}.panel-danger>.panel-heading{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.panel-danger>.panel-heading+.panel-collapse>.panel-body{border-top-color:#ebccd1}.panel-danger>.panel-heading .badge{color:#f2dede;background-color:#a94442}.panel-danger>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#ebccd1}.embed-responsive{position:relative;display:block;height:0;padding:0}.embed-responsive .embed-responsive-item,.embed-responsive embed,.embed-responsive iframe,.embed-responsive object,.embed-responsive video{position:absolute;top:0;bottom:0;left:0;width:100%;height:100%;border:0}.embed-responsive-16by9{padding-bottom:56.25%}.embed-responsive-4by3{padding-bottom:75%}.well{min-height:20px;padding:19px;margin-bottom:20px;background-color:#f5f5f5;border:1px solid #e3e3e3;-webkit-border-radius:4px;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.05);box-shadow:inset 0 1px 1px rgba(0,0,0,.05)}.well blockquote{border-color:#ddd;border-color:rgba(0,0,0,.15)}.well-lg{padding:24px;-webkit-border-radius:6px;border-radius:6px}.well-sm{padding:9px;-webkit-border-radius:3px;border-radius:3px}.close{float:right;font-size:21px;color:#000;text-shadow:0 1px 0 #fff;filter:alpha(opacity=20);opacity:.2}.popover,.tooltip{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-style:normal;font-weight:400;line-height:1.42857143;text-shadow:none;text-transform:none;letter-spacing:normal;word-break:normal;word-spacing:normal;word-wrap:normal;white-space:normal;line-break:auto;text-decoration:none}.close:focus,.close:hover{color:#000;text-decoration:none;cursor:pointer;filter:alpha(opacity=50);opacity:.5}button.close{-webkit-appearance:none;padding:0;cursor:pointer;background:0 0;border:0}.modal-content,.popover{background-clip:padding-box}.modal{position:fixed;z-index:1050;display:none;-webkit-overflow-scrolling:touch;outline:0}.modal.fade .modal-dialog{-webkit-transition:-webkit-transform .3s ease-out;transition:transform .3s ease-out;-webkit-transform:translate(0,-25%);-ms-transform:translate(0,-25%);transform:translate(0,-25%)}.modal.in .modal-dialog{-webkit-transform:translate(0,0);-ms-transform:translate(0,0);transform:translate(0,0)}.modal-open .modal{overflow-x:hidden;overflow-y:auto}.modal-dialog{position:relative;width:auto;margin:10px}.modal-content{position:relative;background-color:#fff;border:1px solid #999;border:1px solid rgba(0,0,0,.2);-webkit-border-radius:6px;border-radius:6px;outline:0;-webkit-box-shadow:0 3px 9px rgba(0,0,0,.5);box-shadow:0 3px 9px rgba(0,0,0,.5)}.modal-backdrop{position:fixed;z-index:1040;background-color:#000}.modal-backdrop.fade{filter:alpha(opacity=0);opacity:0}.modal-backdrop.in{filter:alpha(opacity=50);opacity:.5}.modal-header{min-height:16.43px;padding:15px;border-bottom:1px solid #e5e5e5}.modal-header .close{margin-top:-2px}.modal-title{margin:0;line-height:1.42857143}.modal-body{position:relative;padding:15px}.modal-footer{padding:15px;text-align:right;border-top:1px solid #e5e5e5}.modal-footer .btn+.btn{margin-bottom:0;margin-left:5px}.modal-footer .btn-group .btn+.btn{margin-left:-1px}.modal-footer .btn-block+.btn-block{margin-left:0}.modal-scrollbar-measure{position:absolute;top:-9999px;width:50px;height:50px;overflow:scroll}@media (min-width:768px){.modal-dialog{width:600px;margin:30px auto}.modal-content{-webkit-box-shadow:0 5px 15px rgba(0,0,0,.5);box-shadow:0 5px 15px rgba(0,0,0,.5)}.modal-sm{width:300px}}.tooltip.top-left .tooltip-arrow,.tooltip.top-right .tooltip-arrow{bottom:0;margin-bottom:-5px;border-width:5px 5px 0;border-top-color:#000}@media (min-width:992px){.modal-lg{width:900px}}.tooltip{position:absolute;z-index:1070;display:block;font-size:12px;text-align:left;text-align:start;filter:alpha(opacity=0);opacity:0}.tooltip.in{filter:alpha(opacity=90);opacity:.9}.tooltip.top{padding:5px 0;margin-top:-3px}.tooltip.right{padding:0 5px;margin-left:3px}.tooltip.bottom{padding:5px 0;margin-top:3px}.tooltip.left{padding:0 5px;margin-left:-3px}.tooltip-inner{max-width:200px;padding:3px 8px;color:#fff;text-align:center;background-color:#000;-webkit-border-radius:4px;border-radius:4px}.tooltip-arrow{position:absolute;width:0;height:0;border-color:transparent;border-style:solid}.tooltip.top .tooltip-arrow{bottom:0;left:50%;margin-left:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-left .tooltip-arrow{right:5px}.tooltip.top-right .tooltip-arrow{left:5px}.tooltip.right .tooltip-arrow{top:50%;left:0;margin-top:-5px;border-width:5px 5px 5px 0;border-right-color:#000}.tooltip.left .tooltip-arrow{top:50%;right:0;margin-top:-5px;border-width:5px 0 5px 5px;border-left-color:#000}.tooltip.bottom .tooltip-arrow,.tooltip.bottom-left .tooltip-arrow,.tooltip.bottom-right .tooltip-arrow{border-width:0 5px 5px;border-bottom-color:#000;top:0}.tooltip.bottom .tooltip-arrow{left:50%;margin-left:-5px}.tooltip.bottom-left .tooltip-arrow{right:5px;margin-top:-5px}.tooltip.bottom-right .tooltip-arrow{left:5px;margin-top:-5px}.popover{position:absolute;top:0;left:0;z-index:1060;display:none;max-width:276px;padding:1px;font-size:14px;text-align:left;text-align:start;background-color:#fff;border:1px solid #ccc;border:1px solid rgba(0,0,0,.2);-webkit-border-radius:6px;border-radius:6px;-webkit-box-shadow:0 5px 10px rgba(0,0,0,.2);box-shadow:0 5px 10px rgba(0,0,0,.2)}.carousel-caption,.carousel-control{color:#fff;text-shadow:0 1px 2px rgba(0,0,0,.6);text-align:center}.popover.top{margin-top:-10px}.popover.right{margin-left:10px}.popover.bottom{margin-top:10px}.popover.left{margin-left:-10px}.popover-title{padding:8px 14px;margin:0;font-size:14px;background-color:#f7f7f7;border-bottom:1px solid #ebebeb;-webkit-border-radius:5px 5px 0 0;border-radius:5px 5px 0 0}.popover-content{padding:9px 14px}.popover>.arrow,.popover>.arrow:after{position:absolute;display:block;width:0;height:0;border-color:transparent;border-style:solid}.carousel,.carousel-inner{position:relative}.popover>.arrow{border-width:11px}.popover>.arrow:after{content:"";border-width:10px}.popover.top>.arrow{bottom:-11px;left:50%;margin-left:-11px;border-top-color:#999;border-top-color:rgba(0,0,0,.25);border-bottom-width:0}.popover.top>.arrow:after{bottom:1px;margin-left:-10px;content:" ";border-top-color:#fff;border-bottom-width:0}.popover.left>.arrow:after,.popover.right>.arrow:after{bottom:-10px;content:" "}.popover.right>.arrow{top:50%;left:-11px;margin-top:-11px;border-right-color:#999;border-right-color:rgba(0,0,0,.25);border-left-width:0}.popover.right>.arrow:after{left:1px;border-right-color:#fff;border-left-width:0}.popover.bottom>.arrow{top:-11px;left:50%;margin-left:-11px;border-top-width:0;border-bottom-color:#999;border-bottom-color:rgba(0,0,0,.25)}.popover.bottom>.arrow:after{top:1px;margin-left:-10px;content:" ";border-top-width:0;border-bottom-color:#fff}.popover.left>.arrow{top:50%;right:-11px;margin-top:-11px;border-right-width:0;border-left-color:#999;border-left-color:rgba(0,0,0,.25)}.popover.left>.arrow:after{right:1px;border-right-width:0;border-left-color:#fff}.carousel-inner{width:100%;overflow:hidden}.carousel-inner>.item{position:relative;display:none;-webkit-transition:.6s ease-in-out left;transition:.6s ease-in-out left}@media all and (transform-3d),(-webkit-transform-3d){.carousel-inner>.item{-webkit-transition:-webkit-transform .6s ease-in-out;transition:transform .6s ease-in-out;-webkit-backface-visibility:hidden;backface-visibility:hidden;-webkit-perspective:1000px;perspective:1000px}.carousel-inner>.item.active.right,.carousel-inner>.item.next{left:0;-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}.carousel-inner>.item.active.left,.carousel-inner>.item.prev{left:0;-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}.carousel-inner>.item.active,.carousel-inner>.item.next.left,.carousel-inner>.item.prev.right{left:0;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}}.carousel-inner>.active,.carousel-inner>.next,.carousel-inner>.prev{display:block}.carousel-inner>.active{left:0}.carousel-inner>.next,.carousel-inner>.prev{position:absolute;top:0;width:100%}.carousel-inner>.next{left:100%}.carousel-inner>.prev{left:-100%}.carousel-inner>.next.left,.carousel-inner>.prev.right{left:0}.carousel-inner>.active.left{left:-100%}.carousel-inner>.active.right{left:100%}.carousel-control{position:absolute;top:0;bottom:0;left:0;width:15%;font-size:20px;filter:alpha(opacity=50);opacity:.5}.carousel-control.left{background-image:-webkit-gradient(linear,left top,right top,color-stop(0,rgba(0,0,0,.5)),to(rgba(0,0,0,.0001)));background-image:-webkit-linear-gradient(left,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);background-image:linear-gradient(to right,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1);background-repeat:repeat-x}.carousel-control.right{right:0;left:auto;background-image:-webkit-gradient(linear,left top,right top,color-stop(0,rgba(0,0,0,.0001)),to(rgba(0,0,0,.5)));background-image:-webkit-linear-gradient(left,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);background-image:linear-gradient(to right,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1);background-repeat:repeat-x}.carousel-control:focus,.carousel-control:hover{color:#fff;text-decoration:none;filter:alpha(opacity=90);outline:0;opacity:.9}.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next,.carousel-control .icon-prev{position:absolute;top:50%;z-index:5;display:inline-block;margin-top:-10px}.carousel-control .glyphicon-chevron-left,.carousel-control .icon-prev{left:50%;margin-left:-10px}.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next{right:50%;margin-right:-10px}.carousel-control .icon-next,.carousel-control .icon-prev{width:20px;height:20px;font-family:serif;line-height:1}.carousel-control .icon-prev:before{content:'\2039'}.carousel-control .icon-next:before{content:'\203a'}.carousel-indicators{position:absolute;bottom:10px;left:50%;z-index:15;width:60%;padding-left:0;margin-left:-30%;text-align:center;list-style:none}.carousel-indicators li{display:inline-block;width:10px;height:10px;margin:1px;text-indent:-999px;cursor:pointer;background-color:#000\9;background-color:rgba(0,0,0,0);border:1px solid #fff;-webkit-border-radius:10px;border-radius:10px}.carousel-indicators .active{width:12px;height:12px;margin:0;background-color:#fff}.carousel-caption{position:absolute;right:15%;bottom:20px;left:15%;z-index:10;padding-top:20px;padding-bottom:20px}.carousel-caption .btn,.text-hide{text-shadow:none}@media screen and (min-width:768px){.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next,.carousel-control .icon-prev{width:30px;height:30px;margin-top:-15px;font-size:30px}.carousel-control .glyphicon-chevron-left,.carousel-control .icon-prev{margin-left:-15px}.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next{margin-right:-15px}.carousel-caption{right:20%;left:20%;padding-bottom:30px}.carousel-indicators{bottom:20px}}.btn-group-vertical>.btn-group:after,.btn-group-vertical>.btn-group:before,.btn-toolbar:after,.btn-toolbar:before,.clearfix:after,.clearfix:before,.container-fluid:after,.container-fluid:before,.container:after,.container:before,.dl-horizontal dd:after,.dl-horizontal dd:before,.form-horizontal .form-group:after,.form-horizontal .form-group:before,.modal-footer:after,.modal-footer:before,.nav:after,.nav:before,.navbar-collapse:after,.navbar-collapse:before,.navbar-header:after,.navbar-header:before,.navbar:after,.navbar:before,.pager:after,.pager:before,.panel-body:after,.panel-body:before,.row:after,.row:before{display:table;content:" "}.btn-group-vertical>.btn-group:after,.btn-toolbar:after,.clearfix:after,.container-fluid:after,.container:after,.dl-horizontal dd:after,.form-horizontal .form-group:after,.modal-footer:after,.nav:after,.navbar-collapse:after,.navbar-header:after,.navbar:after,.pager:after,.panel-body:after,.row:after{clear:both}.center-block{display:block;margin-right:auto;margin-left:auto}.pull-right{float:right!important}.pull-left{float:left!important}.hide{display:none!important}.show{display:block!important}.hidden,.visible-lg,.visible-lg-block,.visible-lg-inline,.visible-lg-inline-block,.visible-md,.visible-md-block,.visible-md-inline,.visible-md-inline-block,.visible-sm,.visible-sm-block,.visible-sm-inline,.visible-sm-inline-block,.visible-xs,.visible-xs-block,.visible-xs-inline,.visible-xs-inline-block{display:none!important}.invisible{visibility:hidden}.text-hide{font:0/0 a;color:transparent;background-color:transparent;border:0}.affix{position:fixed}@-ms-viewport{width:device-width}@media (max-width:767px){.visible-xs{display:block!important}table.visible-xs{display:table!important}tr.visible-xs{display:table-row!important}td.visible-xs,th.visible-xs{display:table-cell!important}.visible-xs-block{display:block!important}.visible-xs-inline{display:inline!important}.visible-xs-inline-block{display:inline-block!important}}@media (min-width:768px) and (max-width:991px){.visible-sm{display:block!important}table.visible-sm{display:table!important}tr.visible-sm{display:table-row!important}td.visible-sm,th.visible-sm{display:table-cell!important}.visible-sm-block{display:block!important}.visible-sm-inline{display:inline!important}.visible-sm-inline-block{display:inline-block!important}}@media (min-width:992px) and (max-width:1199px){.visible-md{display:block!important}table.visible-md{display:table!important}tr.visible-md{display:table-row!important}td.visible-md,th.visible-md{display:table-cell!important}.visible-md-block{display:block!important}.visible-md-inline{display:inline!important}.visible-md-inline-block{display:inline-block!important}}@media (min-width:1200px){.visible-lg{display:block!important}table.visible-lg{display:table!important}tr.visible-lg{display:table-row!important}td.visible-lg,th.visible-lg{display:table-cell!important}.visible-lg-block{display:block!important}.visible-lg-inline{display:inline!important}.visible-lg-inline-block{display:inline-block!important}.hidden-lg{display:none!important}}@media (max-width:767px){.hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.hidden-md{display:none!important}}.visible-print{display:none!important}@media print{.visible-print{display:block!important}table.visible-print{display:table!important}tr.visible-print{display:table-row!important}td.visible-print,th.visible-print{display:table-cell!important}}.visible-print-block{display:none!important}@media print{.visible-print-block{display:block!important}}.visible-print-inline{display:none!important}@media print{.visible-print-inline{display:inline!important}}.visible-print-inline-block{display:none!important}@media print{.visible-print-inline-block{display:inline-block!important}.hidden-print{display:none!important}}.hljs{display:block;overflow-x:auto;padding:.5em;color:#333;background:#f8f8f8;-webkit-text-size-adjust:none}.diff .hljs-header,.hljs-comment{color:#998;font-style:italic}.css .rule .hljs-keyword,.hljs-keyword,.hljs-request,.hljs-status,.hljs-subst,.hljs-winutils,.nginx .hljs-title{color:#333;font-weight:700}.hljs-hexcolor,.hljs-number,.ruby .hljs-constant{color:teal}.hljs-doctag,.hljs-string,.hljs-tag .hljs-value,.tex .hljs-formula{color:#d14}.hljs-id,.hljs-title,.scss .hljs-preprocessor{color:#900;font-weight:700}.hljs-list .hljs-keyword,.hljs-subst{font-weight:400}.hljs-class .hljs-title,.hljs-type,.tex .hljs-command,.vhdl .hljs-literal{color:#458;font-weight:700}.django .hljs-tag .hljs-keyword,.hljs-rule .hljs-property,.hljs-tag,.hljs-tag .hljs-title{color:navy;font-weight:400}.hljs-attribute,.hljs-name,.hljs-variable,.lisp .hljs-body{color:teal}.hljs-regexp{color:#009926}.clojure .hljs-keyword,.hljs-prompt,.hljs-symbol,.lisp .hljs-keyword,.ruby .hljs-symbol .hljs-string,.scheme .hljs-keyword,.tex .hljs-special{color:#990073}.hljs-built_in{color:#0086b3}.hljs-cdata,.hljs-doctype,.hljs-pi,.hljs-pragma,.hljs-preprocessor,.hljs-shebang{color:#999;font-weight:700}.hljs-deletion{background:#fdd}.hljs-addition{background:#dfd}.diff .hljs-change{background:#0086b3}.hljs-chunk{color:#aaa}.clickedClass{background-color:orange!important}.notContainer{width:100%;padding:1em;margin-top:1em;margin-bottom:1em;text-align:center;background-color:rgba(0,0,0,.2)}.notContainer.gu-over{background-color:#ff0}.containerVertical.gu-over-accept{background-color:green}.containerVertical.gu-over-decline{background-color:red}.scrollingDrag{width:45%;display:inline-block}.scrollingDragInner{max-height:200px;overflow-y:auto}#rightBottomBar,#rightTopBar{background:0 0;position:relative;height:20px}#rightTopBar{top:10px}#rightBottomBar{bottom:10px}div.scrollBar{background:#ff0;text-align:center;padding:1px} \ No newline at end of file diff --git a/docs/dist/examples.min.js b/docs/dist/examples.min.js index 8320b25c..5b90079f 100644 --- a/docs/dist/examples.min.js +++ b/docs/dist/examples.min.js @@ -1,5 +1,5 @@ -!function(e){function n(o){if(t[o])return t[o].exports;var i=t[o]={exports:{},id:o,loaded:!1};return e[o].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}var t={};return n.m=e,n.c=t,n.p="",n(0)}([function(e,n,t){"use strict";var o=t(1),i=t(4),r=t(5),l=t(6),a=t(7),c=t(8),s=t(9),d=t(10),m=t(11),u=t(12),v=t(13),p=t(14),g=t(15),h=t(16),f=t(17),b=t(18),y=t(19),x=t(20),I=t(21),w=t(22),S=t(23),M=t(23),$=t(24),q=t(25),C=t(26),B=t(27),k=t(28);t(29),angular.module("examplesApp",[o,"templates","ui.router"]).config(i).controller("Basic",r).controller("BasicModel",l).controller("BoundingBox",a).controller("BoundingBoxLockX",c).controller("BoundingBoxLockY",s).controller("Copy",d).controller("CopyModel",m).controller("CustomClasses",u).controller("DifferentOptionsModel",v).controller("Directive",p).controller("DirectiveModel",g).controller("DragOverEvents",h).controller("Events",f).controller("Handle",b).controller("IsContainerModel",y).controller("NameSpaces",x).controller("NestedNgRepeat",I).controller("NestedNgRepeatWithModel",w).controller("NgRepeat",S).controller("NgRepeatFilteredWithModel",M).controller("NgRepeatWithModel",$).controller("RemoveOnSpill",q).controller("RemoveOnSpillWithModel",C).controller("RevertOnSpill",B).controller("ScrollingDrag",k).controller("ExAppCtrl",["$scope",function(e){e.examplesList=[{template:"docsInstall/docsInstall.html",link:"docsInstall",title:"Installation"},{template:"exampleBasic/exampleBasic.html",link:"exampleBasic",title:"Basic"},{template:"exampleBasicWithModel/exampleBasicWithModel.html",link:"exampleBasicWithModel",title:"Basic - with model"},{template:"exampleDifferentOptionsWithModel/exampleDifferentOptionsWithModel.html",link:"exampleDifferentOptionsWithModel",title:"Different options - with model"},{template:"exampleDirective/exampleDirective.html",link:"exampleDirective",title:"Directive"},{template:"exampleDirectiveWithModel/exampleDirectiveWithModel.html",link:"exampleDirectiveWithModel",title:"Directive - with model"},{template:"exampleEvents/exampleEvents.html",link:"exampleEvents",title:"Events"},{template:"exampleRemoveOnSpill/exampleRemoveOnSpill.html",link:"exampleRemoveOnSpill",title:"Remove on spill"},{template:"exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel.html",link:"exampleRemoveOnSpillWithModel",title:"Remove on spill - with model"},{template:"exampleRevertOnSpill/exampleRevertOnSpill.html",link:"exampleRevertOnSpill",title:"Revert on spill"},{template:"exampleCopy/exampleCopy.html",link:"exampleCopy",title:"Copy"},{template:"exampleCopyWithModel/exampleCopyWithModel.html",link:"exampleCopyWithModel",title:"Copy - with model"},{template:"exampleHandle/exampleHandle.html",link:"exampleHandle",title:"Handle"},{template:"exampleIsContainerWithModel/exampleIsContainerWithModel.html",link:"exampleIsContainerWithModel",title:"isContainer - with model"},{template:"exampleCustomClasses/exampleCustomClasses.html",link:"exampleCustomClasses",title:"Custom classes"},{template:"exampleNameSpaces/exampleNameSpaces.html",link:"exampleNameSpaces",title:"NameSpaces"},{template:"exampleDragOverEvents/exampleDragOverEvents.html",link:"exampleDragOverEvents",title:"Drag-over events"},{template:"exampleBoundingBox/exampleBoundingBox.html",link:"exampleBoundingBox",title:"BoundingBox"},{template:"exampleBoundingBoxLockX/exampleBoundingBoxLockX.html",link:"exampleBoundingBoxLockX",title:"BoundingBox + LockX"},{template:"exampleBoundingBoxLockY/exampleBoundingBoxLockY.html",link:"exampleBoundingBoxLockY",title:"BoundingBox + LockY"},{template:"exampleNgRepeat/exampleNgRepeat.html",link:"exampleNgRepeat",title:"ngRepeat"},{template:"exampleNgRepeatWithModel/exampleNgRepeatWithModel.html",link:"exampleNgRepeatWithModel",title:"ngRepeat - with model"},{template:"exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel.html",link:"exampleNgRepeatFilteredWithModel",title:"Filtered ngRepeat - with model"},{template:"exampleNestedNgRepeat/exampleNestedNgRepeat.html",link:"exampleNestedNgRepeat",title:"Nested ngRepead"},{template:"exampleNestedNgRepeatWithModel/exampleNestedNgRepeatWithModel.html",link:"exampleNestedNgRepeatWithModel",title:"Nested ngRepead - with model"},{template:"exampleScrollingDrag/exampleScrollingDrag.html",link:"exampleScrollingDrag",title:"Scrolling drag"}],e.highlightCode=function(){if(document.getElementsByTagName("code").length)for(var e=document.getElementsByTagName("code"),n=e.length-1;n>=0;n--)hljs.highlightBlock(e[n])};var n;e.toggleSidebar=function(){n||(n=angular.element(document.getElementById("rowOffcanvas"))),n.toggleClass("active")}}])},function(e,n,t){"use strict";var o=t(2),i=t(3);e.exports="dragularModule",angular.module("dragularModule",[]).factory("dragularService",i).directive("dragular",o)},function(e,n){"use strict";var t=function(e){return{restrict:"A",link:function(n,t,o){function i(e){try{return JSON.parse(e)}catch(n){return}}var r,l=n.$eval(o.dragular)||i(o.dragular)||{};l&&l.containersModel&&"string"==typeof l.containersModel&&(l.containersModel=n.$eval(l.containersModel)),l&&l.dynamicModelAttribute?n.$watch(function(){return n.$eval(o.dragularModel)},function(e){e&&(r.containersModel=r.sanitizeContainersModel(n.$eval(e)))}):o.dragularModel&&(l.containersModel=n.$eval(o.dragularModel)),o.dragularNameSpace&&(l.nameSpace=o.dragularNameSpace.split(" ")),r=e(t[0],l)}}};t.$inject=["dragularService"],e.exports=t},function(e,n){(function(n){"use strict";var t={classesCache:{},containersCtx:{},containers:{},mirror:null,source:null,item:null,copy:null,sourceItem:null,sourceModel:null,sourceFilteredModel:null,target:null,targetCtx:null,targetModel:null,lastDropTarget:null,offsetX:null,offsetY:null,moveX:null,moveY:null,offsetXr:null,offsetYb:null,clientX:null,clientY:null,mirrorWidth:null,mirrorHeight:null,initialSibling:null,currentSibling:null,initialIndex:null,currentIndex:null,tempModel:null,dragOverEvents:{},lastElementBehindCursor:null,grabbed:null},o=function(e,o){function i(n,i){function m(e){return"function"==typeof e?e:Array.isArray(e)?Array.isArray(e[0])?e:[e]:[]}function b(){1!==arguments.length||Array.isArray(n)||angular.isElement(n)||n[0]||"string"==typeof n?"string"==typeof n&&(ce=document.querySelectorAll(n)):(se=n||{},ce=[]),ae=se.copyOptions?angular.copy(se):se}function I(){var e=angular.extend({},ve,ae);angular.extend(ae,e),ae.classes&&(e=angular.extend({},me,ae.classes),angular.extend(ae.classes,e)),ae.eventNames&&(e=angular.extend({},ue,ae.eventNames),angular.extend(ae.eventNames,e))}function $(){f(ae.boundingBox)||(ae.boundingBox=!1),ae.containers&&(ce=ae.containers),ce=c(ce),ae.containersModel=m(ae.containersModel),Array.isArray(ae.containersFilteredModel)?ae.containersFilteredModel=Array.isArray(ae.containersFilteredModel[0])?ae.containersFilteredModel:[ae.containersFilteredModel]:ae.containersFilteredModel=[],ae.nameSpace||(ae.nameSpace=["dragularCommon"]),Array.isArray(ae.nameSpace)||(ae.nameSpace=[ae.nameSpace]),ae.nameSpace.forEach(function(e){t.containers[e]||(t.containers[e]=[],t.containersCtx[e]=[]);for(var n=ce.length,o=t.containers[e].length,i=0;n>i;i++)t.containers[e][i+o]=ce[i],t.containersCtx[e][i+o]={o:ae,m:T()[i],fm:ae.containersFilteredModel[i]}})}function R(e){var n=e?"off":"on";r(E,n,"mouseup",O),ce.forEach(function(e){r(e,"on","mousedown",N)}),e||angular.forEach(["dragularenter","dragularleave","dragularrelease"],function(e){var n=ae.eventNames[e];t.dragOverEvents[n]||(k.createEvent?(t.dragOverEvents[n]=k.createEvent("HTMLEvents"),t.dragOverEvents[n].initEvent(n,!0,!0)):(t.dragOverEvents[n]=k.createEventObject(),t.dragOverEvents[n].eventType=n))})}function N(e){if(1===s(e)&&!e.metaKey&&!e.ctrlKey){t.moveX=e.clientX,t.moveY=e.clientY;var n=A(e.target);n&&n.item&&(t.grabbed=n,V(),"mousedown"===e.type&&(M(n.item)?n.item.focus():e.preventDefault()))}}function O(e){if(P(),pe.dragging){e.originalEvent&&(e=e.originalEvent),t.clientX=w("clientX",e),t.clientY=w("clientY",e);var n=le(t.mirror,t.clientX,t.clientY),o=_(n,t.clientX,t.clientY);o&&(t.copy&&de(ae.copySortSource)||!t.copy||o!==t.source)?J(t.item,o):de(ae.removeOnSpill)?U():z(),t.target=null,t.lastElementBehindCursor&&C(t.lastElementBehindCursor,t.dragOverEvents.dragularrelease,n),ae.scope&&ae.scope.$emit(ae.eventNames.dragularrelease,t.item,t.source)}}function j(e){if(!e)return!1;for(var n=ae.nameSpace.length;n--;)if(-1!==t.containers[ae.nameSpace[n]].indexOf(e))return!0;return ae.isContainer(e)?(t.tempModel=ae.isContainerModel(e),!0):(t.tempModel=null,!1)}function T(){return"function"==typeof ae.containersModel?m(ae.containersModel(pe,t)):ae.containersModel}function D(n){e.$applyAsync(function(){var e=Array.isArray(n)?n:c(n);e.forEach(function(e){angular.forEach(ae.nameSpace,function(n){var o;o=t.containers[n].indexOf(e),t.containers[n].splice(o,1),t.containersCtx[n].splice(o,1)})})})}function V(e){var n=e?"off":"on";r(E,n,"mousemove",L)}function Y(e){var n=e?"off":"on";r(E,n,"selectstart",d),r(E,n,"click",d),r(E,n,"touchmove",d)}function W(){R(!0),D(ce),O({})}function L(e){if(t.grabbed&&!pe.dragging){if(e.originalEvent&&(e=e.originalEvent),0===s(e))return void O({});if(!e.clientX||e.clientX!==t.moveX||!e.clientY||e.clientY!==t.moveY){if(de(ae.ignoreInputTextSelection)){var n=w("clientX",e),o=w("clientY",e),i=k.elementFromPoint(n,o);if(M(i))return}var r=t.grabbed;if(V("remove"),Y(),H(),F(r),!ae.direction&&S(t.sourceItem)){var l=t.sourceItem.parentNode,a=l.offsetHeight,c=l.offsetWidth,d=t.sourceItem.clientHeight,m=t.sourceItem.clientWidth;ae.direction=c/m>a/d?"horizontal":"vertical"}var v=u(t.sourceItem);t.offsetX=w("pageX",e)-v.left,t.offsetY=w("pageY",e)-v.top,t.clientX=w("clientX",e),t.clientY=w("clientY",e),ae.boundingBox&&(t.offsetXr=w("pageX",e)-v.right,t.offsetYb=w("pageY",e)-v.bottom),e.preventDefault(),y(t.item,ae.classes.transit),te(),t.mirror.style.left=t.clientX-t.offsetX+"px",t.mirror.style.top=t.clientY-t.offsetY+"px",K(e)}}}function A(e){if(!pe.dragging||!t.mirror){for(var n=e;S(e)&&!j(S(e));){if(ae.invalid(e,n))return;if(e=S(e),!e)return}var o=S(e);if(o&&!ae.invalid(e,n)&&ae.moves(e,o,n,h(e)))return{item:e,source:o}}}function X(e){var n=A(e);n&&F(n)}function F(e){t.sourceItem=t.item=e.item,t.source=e.source,t.initialSibling=t.currentSibling=h(e.item),de(ae.copy,[e.item,e.source])?(t.item=e.item.cloneNode(!0),t.copy=!0,ae.scope&&ae.scope.$emit(ae.eventNames.dragularcloned,t.item,e.item)):t.copy=!1;var n=ce.indexOf(e.source);return t.sourceModel=T()[n],t.sourceFilteredModel=ae.containersFilteredModel[n],t.initialIndex=q(e.item,e.source),pe.dragging=!0,ae.scope&&ae.scope.$emit(ae.eventNames.dragulardrag,t.sourceItem,t.source),!0}function H(){pe.dragging&&t.item&&J(t.item,S(t.item))}function P(){t.grabbed=!1,V("remove"),Y("remove")}function J(n,i){function r(){if(ae.compileItemOnDrop){var e=angular.element(i).scope();e.$applyAsync(function(){var r=o(t.copy?l.cloneNode(!0):l)(e);n.parentNode===i&&i.removeChild(n),i.insertBefore(r[0],a)})}ae.scope&&(G(i)?ae.scope.$emit(ae.eventNames.dragularcancel,n,t.source,t.sourceModel,t.initialIndex):ae.scope.$emit(ae.eventNames.dragulardrop,n,i,t.source,t.sourceModel,t.initialIndex,t.targetModel,c)),Q()}var l=t.sourceItem,a=t.currentSibling;if(t.copy&&de(ae.copySortSource)&&i===t.source&&S(n)&&n.parentNode.removeChild(t.sourceItem),t.sourceModel&&!G(i)){var c=q(n,i);t.targetCtx.fm&&(c=t.targetCtx.m.indexOf(t.targetCtx.fm[c])),t.sourceFilteredModel&&(t.initialIndex=t.sourceModel.indexOf(t.sourceFilteredModel[t.initialIndex])),e.$applyAsync(function(){t.sourceModel&&(i===t.source?t.sourceModel.splice(c,0,t.sourceModel.splice(t.initialIndex,1)[0]):(t.dropElmModel=t.copy&&!ae.dontCopyModel?angular.copy(t.sourceModel[t.initialIndex]):t.sourceModel[t.initialIndex],t.tempModel?t.targetModel=t.tempModel:t.targetModel=t.targetCtx.m,i.removeChild(n),t.copy||t.sourceModel.splice(t.initialIndex,1),t.targetModel.splice(c,0,t.dropElmModel)),S(n)&&n.parentNode.removeChild(n),r())})}else r()}function U(){if(pe.dragging){var n=S(t.item);n&&n.removeChild(t.item),t.sourceModel&&e.$applyAsync(function(){t.sourceModel.splice(t.initialIndex,1),Q()}),ae.scope&&ae.scope.$emit(t.copy?ae.eventNames.dragularcancel:ae.eventNames.dragularremove,t.item,n,t.sourceModel,t.initialIndex),t.sourceModel||Q()}}function z(e){if(pe.dragging){var n=arguments.length>0?e:de(ae.revertOnSpill),o=S(t.item),i=G(o);i||t.copy||!n||t.source.insertBefore(t.item,t.initialSibling),!t.sourceModel||t.copy||n?ae.scope&&(i||n)&&ae.scope.$emit(ae.eventNames.dragularcancel,t.item,t.source):J(t.item,o),(!t.sourceModel||t.copy||n||i)&&Q()}}function Q(){P(),oe(),t.item&&x(t.item,ae.classes.transit),pe.dragging=!1,de(ae.removeOnSpill)===!0&&ee(),ae.scope&&(t.lastDropTarget&&ae.scope.$emit(ae.eventNames.dragularout,t.item,t.lastDropTarget,t.source),ae.scope.$emit(ae.eventNames.dragulardragend,t.item)),t.source=t.item=t.sourceItem=t.initialSibling=t.currentSibling=t.sourceModel=null,t.initialIndex=t.currentIndex=t.lastDropTarget=t.tempModel=t.targetModel=null,t.dropElmModel=t.targetCtx=t.copy=t.moveX=t.moveY=null}function G(e,n){var o=n||(t.mirror?t.currentSibling:h(t.item));return e===t.source&&o===t.initialSibling}function _(e,n,o){function i(){var i=!1;if(j(r)){for(var l=ie(r,e),a=re(r,l,n,o),c=G(r,a),s=ae.nameSpace.length;s--;){if(-1!==t.containers[ae.nameSpace[s]].indexOf(r)){t.targetCtx=t.containersCtx[ae.nameSpace[s]][t.containers[ae.nameSpace[s]].indexOf(r)];break}t.targetCtx||(t.targetCtx=t.containersCtx.dragularCommon[t.containers.dragularCommon.indexOf(r)])}i=c||t.targetCtx.o.accepts(t.item,r,t.source,a,t.sourceModel,t.initialIndex)&&ae.canBeAccepted(t.item,r,t.source,a,t.sourceModel,t.initialIndex),t.target!==r&&(t.target=r)}return i}for(var r=e;r&&!i();)r=S(r);return r}function K(e){function n(e){ae.scope&&ae.scope.$emit(ae.eventNames["dragular"+e],t.item,t.lastDropTarget,t.source),de(ae.removeOnSpill)===!0&&("over"===e?Z():ee())}if(t.mirror){e.originalEvent&&(e=e.originalEvent),t.clientX=w("clientX",e),t.clientY=w("clientY",e);var o,i,r,l=t.clientX-t.offsetX,a=t.clientY-t.offsetY;ae.boundingBox&&(o=w("pageX",e),i=w("pageY",e),r=u(ae.boundingBox)),ae.lockY||(!ae.boundingBox||o>r.left+t.offsetX&&or.top+t.offsetY&&in;n++){if(i=e.children[n],r=i.getBoundingClientRect(),a&&r.left>t)return i;if(!a&&r.top>o)return i}return null}function r(){var e=n.getBoundingClientRect();return l(a?t>e.left+v(e)/2:o>e.top+p(e)/2)}function l(e){return e?h(n):n}var a="horizontal"===ae.direction;return n!==e?r():i()}function le(e,n,t){var o,i=e||{},r=i.className;return i.className+=" "+ae.classes.hide,o=k.elementFromPoint(n,t),i.className=r,o}var ae,ce=n||[],se=i||{},de=B,me={mirror:"gu-mirror",hide:"gu-hide",unselectable:"gu-unselectable",transit:"gu-transit"},ue={dragularenter:"dragularenter",dragularleave:"dragularleave",dragularrelease:"dragularrelease",dragularcloned:"dragularcloned",dragulardrag:"dragulardrag",dragularcancel:"dragularcancel",dragulardrop:"dragulardrop",dragularremove:"dragularremove",dragulardragend:"dragulardragend",dragularshadow:"dragularshadow",dragularover:"dragularover",dragularout:"dragularout"},ve={copyOptions:!1,classes:me,eventNames:ue,containers:!1,containersModel:!1,containersFilteredModel:!1,isContainer:l,isContainerModel:g,moves:a,accepts:a,canBeAccepted:a,copy:!1,copySortSource:!1,dontCopyModel:!1,invalid:l,revertOnSpill:!1,removeOnSpill:!1,lockX:!1,lockY:!1,boundingBox:!1,mirrorContainer:k.body,ignoreInputTextSelection:!0,compileItemOnDrop:!1},pe={containers:t.containers,containersCtx:t.containersCtx,sanitizeContainersModel:m,isContainer:j,start:X,end:H,cancel:z,remove:U,destroy:W,dragging:!1};return b(),I(),$(),R(),pe}function r(e,t,o,i){var r={mouseup:"touchend",mousedown:"touchstart",mousemove:"touchmove"},l={mouseup:"pointerup",mousedown:"pointerdown",mousemove:"pointermove"},a={mouseup:"MSPointerUp",mousedown:"MSPointerDown",mousemove:"MSPointerMove"},c=angular.element(e);n.navigator.pointerEnabled&&l[o]?c[t](l[o],i):n.navigator.msPointerEnabled&&a[o]?c[t](a[o],i):r[o]&&c[t](r[o],i),c[t](o,i)}function l(){return!1}function a(){return!0}function c(e,n){return Array.isArray(e)?e:e.length?Array.prototype.slice.call(e,n):[e]}function s(e){if(e.touches)return e.touches.length;if(e.originalEvent&&e.originalEvent.touches)return e.originalEvent.touches.length;if(void 0!==e.buttons)return e.buttons;if(void 0!==e.which)return e.which;var n=e.button;return void 0!==n?1&n?1:2&n?3:4&n?2:0:void 0}function d(e){e.originalEvent&&(e=e.originalEvent),t.grabbed&&e.preventDefault()}function m(e,n){return"undefined"!=typeof window[n]?window[n]:E.clientHeight?E[e]:k.body[e]}function u(e){var n=e.getBoundingClientRect(),t=m("scrollTop","pageYOffset"),o=m("scrollLeft","pageXOffset");return{left:n.left+o,right:n.right+o,top:n.top+t,bottom:n.bottom+t}}function v(e){return e.width||e.right-e.left}function p(e){return e.height||e.bottom-e.top}function g(){return{}}function h(e){function n(){var n=e;do n=n.nextSibling;while(n&&1!==n.nodeType);return n}return e.nextElementSibling||n()}function f(e){return"object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&null!==e&&1===e.nodeType&&"string"==typeof e.nodeName}function b(e){var n=t.classesCache[e];return n?n.lastIndex=0:t.classesCache[e]=n=new RegExp("(?:^|\\s)"+e+"(?:\\s|$)","g"),n}function y(e,n){var t=e.className;t.length?b(n).test(t)||(e.className+=" "+n):e.className=n}function x(e,n){e.className=e.className.replace(b(n)," ").trim()}function I(e){return e.targetTouches&&e.targetTouches.length?e.targetTouches[0]:e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e}function w(e,n){var t=I(n),o={pageX:"clientX",pageY:"clientY"};return e in o&&!(e in t)&&o[e]in t&&(e=o[e]),!t.type||t.type.indexOf("touch")<0?t[e]:-1===t.type.indexOf("end")?t.originalEvent.touches[0][e.replace("client","page")]:!1}function S(e){return e.parentNode===document?null:e.parentNode}function M(e){return"INPUT"===e.tagName||"TEXTAREA"===e.tagName||"SELECT"===e.tagName||$(e)}function $(e){return e?"false"===e.contentEditable?!1:"true"===e.contentEditable?!0:$(S(e)):!1}function q(e,n){return Array.prototype.indexOf.call(angular.element(n).children(),e)}function C(e,n,o){e&&(t.extra=o,e.dispatchEvent?e.dispatchEvent(n):e.fireEvent("on"+n.eventType,n))}function B(e,n,o){return angular.isFunction(e)?!!e.apply(o||this,n||t):!!e}var k=document,E=k.documentElement;return i.cleanEnviroment=function(){t.classesCache={},t.containersCtx={},t.containers={},t.mirror=void 0},i.shared=t,i};o.$inject=["$rootScope","$compile"],e.exports=o}).call(n,function(){return this}())},function(e,n){"use strict";var t=function(e,n){n.otherwise("/home");var t,o=function(e,n,o){n.link?o.cancel(t):t=o(function(){e.go("docs.detail",{link:"docsInstall"})},0)};o.$inject=["$state","$stateParams","$timeout"],e.state("home",{url:"/home",templateUrl:"partials/partial-home.html"}).state("docs",{url:"/docs",templateUrl:"partials/partial-docs.html",controller:o}).state("docs.detail",{url:"/:link",templateUrl:function(e){return e.link+"/"+e.link+".html"},controller:o}).state("contribute",{url:"/contribute",templateUrl:"partials/partial-contribute.html"})};t.$inject=["$stateProvider","$urlRouterProvider"],e.exports=t},function(e,n){"use strict";var t=function(e,n){n.cleanEnviroment(),n(".containerVertical")};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t){e.items1=[{content:"Move me, but you can only drop me in one of these containers."},{content:"If you try to drop me somewhere other than these containers, I'll just come back."},{content:"Item 3"},{content:"Item 4"}],e.items2=[{content:"Item 5"},{content:"Item 6"},{content:"Item 7"},{content:"Item 8"}];var o=n.children().eq(0).children();t.cleanEnviroment(),t([o[0],o[1]],{containersModel:[e.items1,e.items2]})};t.$inject=["$scope","$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){var t=e[0];n.cleanEnviroment(),n(e.children(),{boundingBox:t})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){var t=e.children().children()[0];n.cleanEnviroment(),n(t,{boundingBox:t,lockX:!0})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){var t=e.children().children()[0];n.cleanEnviroment(),n(t,{boundingBox:t,lockY:!0})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){n.cleanEnviroment(),n(e.children(),{copy:!0})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t){e.items1=[{content:"Move me, and make copy on drop."},{content:"If you try to drop me somewhere other than these containers, I'll just come back."},{content:"Item 3"},{content:"Item 4"}],e.items2=[{content:"Item 5"},{content:"Item 6"},{content:"Item 7"},{content:"Item 8"}];var o=n.children().eq(0).children();t.cleanEnviroment(),t([o[0],o[1]],{containersModel:[e.items1,e.items2],copy:!0})};t.$inject=["$scope","$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){n.cleanEnviroment(),n(e.children(),{classes:{mirror:"custom-green-mirror"}})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t){function o(e,n,t){return t===i||t===n?!0:void 0}e.items1=[{content:"Move me, but you can only drop me in one of these containers."},{content:"If you try to drop me somewhere other than these containers, I'll just come back."},{content:"Item 3"},{content:"Item 4"}],e.items2=[{content:"Item 5"},{content:"Item 6"},{content:"Item 7"},{content:"Item 8"}];var i=document.querySelector("#containerLeft"),r=document.querySelector("#containerRight");t.cleanEnviroment(),t([i],{containersModel:[e.items1],copy:!0,copySortSource:!0,accepts:o}),t([r],{containersModel:[e.items2],removeOnSpill:!0,accepts:o})};t.$inject=["$scope","$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e){e.dragularOptions={classes:{mirror:"custom-green-mirror"},nameSpace:"same"}};t.$inject=["$scope"],e.exports=t},function(e,n){"use strict";var t=function(e){e.items1=[{content:"Move me, and make copy on drop."},{content:"If you try to drop me somewhere other than these containers, I'll just come back."},{content:"Item 3"},{content:"Item 4"}],e.items2=[{content:"Item 5"},{content:"Item 6"},{content:"Item 7"},{content:"Item 8"}],e.dragularOptions={containersModel:e.items1,classes:{mirror:"custom-green-mirror"},nameSpace:"common"}};t.$inject=["$scope"],e.exports=t},function(e,n){"use strict";var t=function(e,n){function t(e){e.on("dragularenter",function(t){e[0]===t.target&&e.addClass(n.shared.extra?"gu-over-accept":"gu-over-decline")}),e.on("dragularleave dragularrelease",function(t){(e[0]===t.target&&n.shared.extra&&n.shared.extra.parentElement!==t.target||"dragularrelease"===t.type)&&(e.removeClass("gu-over-accept"),e.removeClass("gu-over-decline"))})}n.cleanEnviroment(),n([e.children()[0],e.children()[2]],{nameSpace:"apples"}),n([e.children()[1],e.children()[3]],{nameSpace:"oranges"}),angular.forEach(e.children(),function(e){t(angular.element(e))});var o=angular.element(document.getElementsByClassName("notContainer"));o.on("dragularenter",function(){o.addClass("gu-over")}),o.on("dragularleave dragularrelease",function(){o.removeClass("gu-over")})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t,o){function i(e){return function(){}}t.cleanEnviroment(),t(n.children(),{scope:e}),e.$on("dragulardrag",function(e,n){e.stopPropagation(),n.className=n.className.replace(" ex-moved","")}),e.$on("dragulardrop",function(e,n){e.stopPropagation(),o(function(){n.className+=" ex-moved"},0)}),e.$on("dragularcloned",i("cloned")),e.$on("dragulardrag",i("drag")),e.$on("dragularcancel",i("cancel")),e.$on("dragulardrop",i("drop")),e.$on("dragularremove",i("remove")),e.$on("dragulardragend",i("dragend")),e.$on("dragularshadow",i("shadow"))};t.$inject=["$scope","$element","dragularService","$timeout"],e.exports=t},function(e,n){"use strict";var t=function(e,n){n.cleanEnviroment(),n(e.children(),{moves:function(e,n,t){return"handle"===t.className}})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t){e.items1=[{content:"Move me, but you can only drop me in one of these containers."},{content:"If you try to drop me somewhere other than these containers, I'll just come back."},{content:"Item 3"},{content:"Item 4"}],e.cartModel=[];var o=document.querySelector("#containerLeft");t.cleanEnviroment(),t([o],{containersModel:[e.items1],copy:!0,isContainer:function(e){return"cart"===e.id},isContainerModel:function(){return e.cartModel}}),e.removeItem=function(){var n=e.cartModel.indexOf(this.item);e.cartModel.splice(n,1)}};t.$inject=["$scope","$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){n.cleanEnviroment(),n([e.children()[0],e.children()[2]],{nameSpace:"apples"}),n(e.children()[1],{nameSpace:"oranges"}),n(e.children()[3],{nameSpace:["oranges","apples"]})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t,o){e(function(){o.cleanEnviroment(),o(t,{nameSpace:"rows",moves:function(e,n,t){return t.classList.contains("row-handle")}}),o(t.children(),{nameSpace:"cells",moves:function(e,n,t){return!t.classList.contains("row-handle")}})},0),n.items=[{items:[{content:"Item a1"},{content:"Item a2"},{content:"Item a3"},{content:"Item a4"}]},{items:[{content:"Item b1"},{content:"Item b2"},{content:"Item b3"},{content:"Item b4"}]},{items:[{content:"Item c1"},{content:"Item c2"},{content:"Item c3"},{content:"Item c4"}]}]};t.$inject=["$timeout","$scope","$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t,o){e(function(){var e=t.children().eq(0).children(),i=e.children(),r=[];o.cleanEnviroment(),o(e,{moves:function(e,n,t){return t.classList.contains("row-handle")},containersModel:n.items,nameSpace:"rows"});for(var l=0;lInstall\n

download dragular.js and dragular.css from dist folder

\n

OR clone git

\n
\ngit clone http://github.com/luckylooke/dragular.git\n
\n

OR use npm

\n
\n[sudo] npm install dragular\n
\n

OR use bower

\n
\nbower install dragular\n
\n

AND include files into your project

\n
\n<link href='styles/dragular.css' rel='stylesheet' type='text/css' />\n<script src='scripts/dragular.js'></script>\n
\n

AND put dragularModule into dependency array

\n
\nvar app = angular.module('myApp', ['dragularModule', 'otherDependencies']);\n
\n

DONE :)

\n"), -e.put("exampleBasicWithModel/exampleBasicWithModel.html","
\n

Basic - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  controller('BasicModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: 'Move me, but you can only drop me in one of these containers.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.items2 = [{\n      content: 'Item 5'\n    }, {\n      content: 'Item 6'\n    }, {\n      content: 'Item 7'\n    }, {\n      content: 'Item 8'\n    }];\n    var containers = $element.children().children();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2]\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="Basic">\n    <div class='tableRow'>\n        <div class='containerVertical'>\n            <div ng-repeat="item in items1">{{item.content}}</div>\n        </div>\n        <div class='containerVertical'>\n            <div ng-repeat="item in items2">{{item.content}}</div>\n        </div>\n    </div>\n    <div class="tableRow">\n        <div class="container">\n            <div>Items1:\n                <br/>{{items1 | json}}</div>\n        </div>\n        <div class="container">\n            <div>Items2:\n                <br/>{{items2 | json}}</div>\n        </div>\n    </div>\n</div>\n        \n      
\n
\n"),e.put("exampleBasic/exampleBasic.html","
\n

Basic

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
Try to click me, dragular distinguish drag from click
\n
Item 5.
\n
\n
\n
\n        \n// JS\n  controller('Basic', ['$element', 'dragularService', function TodoCtrl($element, dragularService) {\n    dragularService('.containerVertical');\n  }])\n        \n        \n// CSS\n.clickedClass {\n  background-color: orange !important;\n}\n        \n        \n<!-- HTML -->\n  <div class='wrapper' ng-controller="Basic">\n    <div class='containerVertical'>\n        <div>Move me, but you can only drop me in one of these containers.</div>\n        <div>If you try to drop me somewhere other than these containers, I'll just come back.</div>\n        <div>Item 3.</div>\n        <div>Item 6.</div>\n    </div>\n    <div class='containerVertical'>\n        <div>You can drop me in the left container, otherwise I'll stay here.</div>\n        <div ng-click=\"clicked = !clicked\" ng-class=\"clicked && 'clickedClass'\">Try to click me, dragular distinguish drag from click</div>\n        <div>Item 5.</div>\n    </div>\n</div>\n        \n      
\n
\n"),e.put("exampleBoundingBox/exampleBoundingBox.html","
\n

BoundingBox

\n \n
\n
\n
This items cannot cross its example element, just try it your selves.
\n
Item 2.
\n
Item 3.
\n
Item 6.
\n
\n
\n
This items cannot cross its example element, just try it your selves.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n  dragularService([$element.children(), {\n    boundingBox: $element\n  });\n        \n      
\n
"),e.put("exampleBoundingBoxLockX/exampleBoundingBoxLockX.html","
\n

BoundingBox and lockX

\n \n
\n
\n
\n
Items are locked in X axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
\n
item 2
\n
item 3
\n
item 4
\n
\n
\n
\n
\n        \n  dragularService([$element.children()[0].children(), {\n    boundingBox: $element.children()[0],\n    lockX: true\n  });\n        \n      
\n
"),e.put("exampleBoundingBoxLockY/exampleBoundingBoxLockY.html","
\n

BoundingBox and LockY

\n \n
\n
\n
\n
Items are locked in Y axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
\n
item 2
\n
item 3
\n
item 4
\n
item 5
\n
item 6
\n
\n
\n
\n
\n        \n  dragularService([$element.children()[0].children(), {\n    boundingBox: $element.children()[0],\n    lockY: true\n  });\n        \n      
\n
"),e.put("exampleCopy/exampleCopy.html","
\n

Copy

\n \n
\n
\n
Move me, and make copy on drop.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
\n
\n
\n        \n// JS\n  controller('Copy', ['$element', 'dragularService', function TodoCtrl($element, dragularService) {\n    dragularService($element.children(), {\n      copy: true\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="Copy" ng-hide="globals.showModelExamples">\n    <div id='left2' class='containerVertical'>\n      <div>Move me, and make copy on drop.</div>\n      <div>If you try to drop me somewhere other than these containers, I'll just come back.</div>\n    </div>\n    <div id='right2' class='containerVertical'>\n      <div>You can drop me in the left container, otherwise I'll stay here.</div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleCopyWithModel/exampleCopyWithModel.html","
\n

Copy - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n
{{items1 | json}}
\n
\n
\n
Items2:\n
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  controller('CopyModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: 'Move me, and make copy on drop.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.items2 = [{\n      content: 'Item 5'\n    }, {\n      content: 'Item 6'\n    }, {\n      content: 'Item 7'\n    }, {\n      content: 'Item 8'\n    }];\n    var containers = $element.children().children();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2],\n      copy: true\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="CopyModel" ng-show="globals.showModelExamples">\n    <div class='tableRow'>\n      <div class='containerVertical'>\n        <div ng-repeat="item in items1">{{item.content}}</div>\n      </div>\n      <div class='containerVertical'>\n        <div ng-repeat="item in items2">{{item.content}}</div>\n      </div>\n    </div>\n    <div class="tableRow">\n      <div class="container">\n        <div>Items1:\n          <br/>{{items1 | json}}</div>\n      </div>\n      <div class="container">\n        <div>Items2:\n          <br/>{{items2 | json}}</div>\n      </div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleCustomClasses/exampleCustomClasses.html","
\n

Custom classes

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n  dragularService([document.getElementById(left), document.getElementById(right)], { classes: {\n    mirror: 'custom-green-mirror'\n  } });\n\n  // Default classes are:\n  option.classes = {\n    mirror: 'gu-mirror',\n    hide: 'gu-hide',\n    unselectable: 'gu-unselectable',\n    transit: 'gu-transit',\n    overActive: 'gu-over-active',\n    overAccepts: 'gu-over-accept',\n    overDeclines: 'gu-over-decline'\n  };\n        \n      
\n
\n"),e.put("exampleDifferentOptionsWithModel/exampleDifferentOptionsWithModel.html","
\n

Different options - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  .controller('DifferentOptionsModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: 'Move me, but you can only drop me in one of these containers.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.items2 = [{\n      content: 'Item 5'\n    }, {\n      content: 'Item 6'\n    }, {\n      content: 'Item 7'\n    }, {\n      content: 'Item 8'\n    }];\n\n    var containerLeft = document.querySelector('#containerLeft'),\n      containerRight = document.querySelector('#containerRight');\n\n    function accepts(el, target, source) {\n      if (source === containerLeft || source === target) {\n        return true;\n      }\n    }\n\n    dragularService([containerLeft], {\n      containersModel: [$scope.items1],\n      copy: true,\n      //move only from left to right  \n      accepts: accepts\n    });\n\n    dragularService([containerRight], {\n      containersModel: [$scope.items2],\n      removeOnSpill: true,\n      //move only from left to right  \n      accepts: accepts\n    });\n\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="DifferentOptionsModel">\n    <div class='tableRow'>\n      <div id="containerLeft" class='containerVertical'>\n        <div ng-repeat="item in items1">{{item.content}}</div>\n      </div>\n      <div id="containerRight" class='containerVertical'>\n        <div ng-repeat="item in items2">{{item.content}}</div>\n      </div>\n    </div>\n    <div class="tableRow">\n      <div class='containerVertical'>\n        <pre>Items1:\n          <br/>{{items1 | json}}</pre>\n      </div>\n      <div class='containerVertical'>\n        <pre>Items2:\n          <br/>{{items2 | json}}</pre>\n      </div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleDirective/exampleDirective.html","
\n

Directive

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n// JS\n  controller('Directive', ['$scope', 'dragularService', function TodoCtrl($scope) {\n    $scope.dragularOptions = {\n      classes: {\n        mirror: 'custom-green-mirror'\n      },\n      nameSpace: 'common' // just connecting left and right container\n    };\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="Directive">\n    <div class='containerVertical' dragular="dragularOptions">\n      <div>Move me, but you can only drop me in one of these containers.</div>\n      <div>If you try to drop me somewhere other than these containers, I'll just come back.</div>\n      <div>Item 3.</div>\n      <div>Item 6.</div>\n    </div>\n    <div class='containerVertical' dragular='{"classes":{"mirror":"custom-green-mirror"},"nameSpace":"same"}'>\n      <div>You can drop me in the left container, otherwise I'll stay here.</div>\n      <div>Item 4.</div>\n      <div>Item 5.</div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleDirectiveWithModel/exampleDirectiveWithModel.html","
\n

Directive - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n
{{items1 | json}}
\n
\n
\n
Items2:\n
{{items2 | json}}
\n
\n
\n
\n
\n       \n        \n// JS\n  controller('DirectiveModel', ['$scope', function TodoCtrl($scope) {\n    $scope.items1 = [{\n      content: 'Move me, and make copy on drop.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.items2 = [{\n      content: 'Item 5'\n    }, {\n      content: 'Item 6'\n    }, {\n      content: 'Item 7'\n    }, {\n      content: 'Item 8'\n    }];\n    $scope.dragularOptions = {\n      containersModel: $scope.items1,\n      classes: {\n        mirror: 'custom-green-mirror'\n      },\n      nameSpace: 'common' // just connecting left and right container\n    };\n  }])\n        \n        \n<!-- HTML -->\n <div class='wrapper' ng-controller="DirectiveModel">\n  <div class='containerVertical' dragular="dragularOptions">\n    <div ng-repeat="item in items1">{{item.content}}</div>\n  </div>\n  <div class='containerVertical' dragular='{"containersModel":"items2","classes":{"mirror":"custom-green-mirror"},"nameSpace":"common"}'>\n    <div ng-repeat="item in items2">{{item.content}}</div>\n  </div>\n</div>\n        \n      
\n
\n"),e.put("exampleDragOverEvents/exampleDragOverEvents.html","
\n

Drag-over events

\n

You can interact with dragging element by litening to dragOver events. Usually you want to containers show wheather they accepts element or not, but you can use it anywhere. DragOver events are: dragenter, dragleave and dragrelease. On dragOver events dragularService reveals several useful properties.

\n\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
dragularService.shared.itemitem beeing dragged (it is copy of item if copy is enabled via options)
dragularService.shared.sourcesource container item is dragged from
dragularService.shared.sourceModelsource container model representation if model was porvided
dragularService.shared.initialIndexoriginal index of item, can be used to get item model from sourceModel
dragularService.shared.extracontains accepting information (boolean) on dragenter, element drag is leaving to on dragleave and element behind the cursor on dragrelease
\n
\n\n

Try to drag over the not-container too.

\n
\n
\n
apples and oranges cannot be mixed
\n
apple 2
\n
apple 3
\n
apple 4
\n
\n
\n
orange 1
\n
orange 2
\n
orange 3
\n
orange 4
\n
\n
\n
apple 5
\n
apple 6
\n
apple 7
\n
apple 8
\n
\n
\n
orange 5
\n
orange 6
\n
orange 7
\n
orange 8
\n
\n
\n
Test active class on NOT container.
\n\n
\n    \n<!-- HTML -->\n  <div class='wrapper' ng-controller="DragOverEvents">\n    <div class='container width25'>\n      <div>apples and oranges cannot be mixed</div>\n      <div>apple 2</div>\n      ...\n    </div>\n    <div class='container width25'>\n      <div>orange 1</div>\n      <div>orange 2</div>\n      ...\n    </div>\n    <div class='container width25'>\n      <div>apple 5</div>\n      <div>apple 6</div>\n      ...\n    </div>\n    <div class='container width25'>\n      <div>orange 5</div>\n      <div>orange 6</div>\n      ...\n    </div>\n  </div>\n  <div class="notContainer"> Test active class on NOT container.</div>\n    \n  
\n\n
\n    \n  // CSS\n  \n.notContainer.gu-over {\n  background-color: yellow;\n}\n\n.containerVertical.gu-over-accept {\n  background-color: green;\n}\n\n.containerVertical.gu-over-decline {\n  background-color: red;\n}\n    \n  
\n\n
\n    \n  // JS\n  controller('DragOverEvents', ['$element', 'dragularService', function TodoCtrl($element, dragularService) {\n    dragularService.cleanEnviroment();\n    dragularService([$element.children()[0], $element.children()[2]], {\n      nameSpace: 'apples'\n    });\n    dragularService([$element.children()[1], $element.children()[3]], {\n      nameSpace: 'oranges'\n    });\n\n    // containers events handling\n    function registerEvents(el) {\n      el.on('dragularenter', function(e) {\n        if (el[0] === e.target) { // filter bubbled\n          el.addClass(dragularService.shared.extra ? 'gu-over-accept' : 'gu-over-decline');\n        }\n      });\n      el.on('dragularleave dragularrelease', function(e) {\n        if ((el[0] === e.target && // filter bubbled\n          dragularService.shared.extra && // extra on dragleave contains element the drag is leaving to\n          dragularService.shared.extra.parentElement !== e.target) // is that element child of this container?\n          || e.type === 'dragularrelease') {\n          el.removeClass('gu-over-accept');\n          el.removeClass('gu-over-decline');\n        }\n      });\n    }\n\n    angular.forEach($element.children(), function forEachChild(el) {\n      registerEvents(angular.element(el));\n    });\n\n    // notContainer events handling\n    var notContainer = angular.element(document.getElementsByClassName('notContainer'));\n    notContainer.on('dragularenter', function() {\n      notContainer.addClass('gu-over');\n    });\n    notContainer.on('dragularleave dragularrelease', function() {\n      notContainer.removeClass('gu-over');\n    });\n  }])\n    \n  
\n
\n"),e.put("exampleEvents/exampleEvents.html","
\n

Events

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n.controller('Events', ['$scope', '$element', 'dragularService', '$timeout', function TodoCtrl($scope, $element, dragularService, $timeout) {\n    dragularService($element.children(), {\n      scope: $scope\n    });\n    $scope.$on('dragulardrag', function(e, el) {\n      e.stopPropagation();\n      el.className = el.className.replace(' ex-moved', '');\n    });\n    $scope.$on('dragulardrop', function(e, el) {\n      e.stopPropagation();\n      $timeout(function() {\n        el.className += ' ex-moved';\n      }, 0);\n    });\n\n    $scope.$on('dragularcloned', myFn('cloned'));\n    $scope.$on('dragulardrag', myFn('drag'));\n    $scope.$on('dragularcancel', myFn('cancel'));\n    $scope.$on('dragulardrop', myFn('drop'));\n    $scope.$on('dragularremove', myFn('remove'));\n    $scope.$on('dragulardragend', myFn('dragend'));\n    $scope.$on('dragularshadow', myFn('shadow'));\n\n    function myFn(eventName) {\n      return function() {\n        console.log(eventName, arguments);\n      };\n    }\n\n  }]);\n        \n      
\n
\n"),e.put("exampleHandle/exampleHandle.html","
\n

Handle

\n \n
\n
\n
+Move me, but you can use the plus sign to drag me around.
\n
\n
\n
\n
\n
\n        \n  dragularService([document.getElementById(left), document.getElementById(right)], {\n    moves: function (el, container, handle) {\n      return handle.className === 'handle';\n    }\n  });\n        \n      
\n
\n"),e.put("exampleIsContainerWithModel/exampleIsContainerWithModel.html","
\n

isContainer - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}\n
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Cart:\n          
{{cartModel | json}}
\n
\n
\n
\n
\n        \n// JS\n  .controller('IsContainerModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: 'Move me, but you can only drop me in one of these containers.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.cartModel = [];\n\n    var containerLeft = document.querySelector('#containerLeft');\n\n    dragularService.cleanEnviroment();\n    dragularService([containerLeft], {\n      containersModel: [$scope.items1],\n      copy: true,\n      isContainer: function isContainer (el) {\n        return el.id === 'cart';\n      },\n      isContainerModel: function getModel (){\n        return $scope.cartModel;\n      }\n    });\n\n    $scope.removeItem = function removeItem() {\n      var index = $scope.cartModel.indexOf(this.item);\n      $scope.cartModel.splice(index, 1);\n    };\n\n  }])\n        \n        \n<!-- HTML -->\n <div class='wrapper' ng-controller="IsContainerModel">\n    <div class='tableRow'>\n      <div id="containerLeft" class='containerVertical'>\n        <div ng-repeat="item in items1">{{item.content}}</div>\n      </div>\n      <div id="cart" class='containerVertical'>\n        <div class='cursorDefault' ng-repeat="item in cartModel">{{item.content}}\n        <button class='cursorDefault' ng-click="removeItem()">x</button></div>\n      </div>\n    </div>\n    <div class="tableRow">\n      <div class='containerVertical'>\n        <pre>Items1:\n          <br/>{{items1 | json}}</pre>\n      </div>\n      <div class='containerVertical'>\n        <pre>Cart:\n          <br/>{{cartModel | json}}</pre>\n      </div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleNameSpaces/exampleNameSpaces.html","
\n

NameSpaces

\n \n
\n
\n
try to mix oranges and apples
\n
apple 2
\n
apple 3
\n
apple 4
\n
\n
\n
orange 1
\n
orange 2
\n
orange 3
\n
orange 4
\n
\n
\n
apple 5
\n
apple 6
\n
apple 7
\n
apple 8
\n
\n
\n
mixed 1
\n
mixed 2
\n
mixed 3
\n
mixed 4
\n
\n
\n
\n      \ndragularService([$element.children()[0], $element.children()[2]], {\n  nameSpace: 'apples'\n});\ndragularService($element.children()[1], {\n  nameSpace: 'oranges'\n});\ndragularService($element.children()[3], { // mixed\n  nameSpace: ['oranges', 'apples']\n});\n      \n    
\n
"), -e.put("exampleNestedNgRepeat/exampleNestedNgRepeat.html","
\n

Nested ngRepeat

\n \n
\n
\n
Row {{$index}}
\n
{{item.content}}
\n
\n
\n
\n        \n  // HTML\n\n  <div ng-controller="Example15">\n    <div ng-repeat="item in items" class='exampleRow'>\n      <div class="row-handle">Row {{$index}}</div>\n      <div ng-repeat="item in item.items" class="exampleCell">{{item.content}}</div>\n    </div>\n  </div>\n        \n      
\n
\n        \n  // CSS\n\n  .exampleRow {\n    display: flex;\n    flex-direction: row;\n  }\n\n  .exampleCell {\n    flex-grow: 1;\n  }\n\n  .exampleRow,\n  .exampleCell {\n    margin: 10px;\n    padding: 10px;\n    background-color: rgba(0, 0, 0, 0.2);\n    cursor: move;\n    cursor: grab;\n    cursor: -moz-grab;\n    cursor: -webkit-grab;\n  }\n        \n      
\n
\n        \n  // JS\n\n  .controller('NestedNgRepeat', ['$timeout', '$scope', '$element', 'dragularService', function NestedNgRepeatCtrl($timeout, $scope, $element, dragularService) {\n    $timeout(function() { // timeount due to ngRepeat to be ready\n      dragularService($element, {\n        nameSpace: 'rows',\n        moves: function rowOnly (el, container, handle) {\n          return handle.classList.contains('row-handle');\n        }\n      });\n      dragularService($element.children(), {\n        nameSpace: 'cells',\n        moves: function excludeHandle (el, container, handle) {\n          return !handle.classList.contains('row-handle');\n        }\n      });\n    }, 0);\n    $scope.items = [{\n      items: [{\n        content: 'Item a1'\n      }, {\n        content: 'Item a2'\n      }, {\n        content: 'Item a3'\n      }, {\n        content: 'Item a4'\n      }]\n    }, {\n      items: [{\n        content: 'Item b1'\n      }, {\n        content: 'Item b2'\n      }, {\n        content: 'Item b3'\n      }, {\n        content: 'Item b4'\n      }]\n    }, {\n      items: [{\n        content: 'Item c1'\n      }, {\n        content: 'Item c2'\n      }, {\n        content: 'Item c3'\n      }, {\n        content: 'Item c4'\n      }]\n    }];\n  }])\n        \n      
\n
\n"),e.put("exampleNestedNgRepeatWithModel/exampleNestedNgRepeatWithModel.html","
\n

Nested ngRepeat - with model

\n \n
\n
\n
\n
\n
Row {{::$index}}
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
\n
\n
\n            
Items:\n
{{items | json}}
\n
\n
\n
\n
\n
\n    \n<!-- HTML -->\n<div ng-controller="NestedNgRepeatWithModel">\n  <div class='containerVertical'>\n    <div ng-repeat="item in items" class='exampleRow'>\n      <div class="row-handle">Row {{::$index}}</div>\n      <div class="exampleRow exampleCell containerNested">\n        <div ng-repeat="item in item.items" class="exampleCell">{{item.content}}</div>\n      </div>\n    </div>\n  </div>\n</div>\n    \n  
\n
\n    \n  // CSS\n\n  .exampleRow {\n    display: flex;\n    flex-direction: row;\n  }\n\n  .exampleCell {\n    flex-grow: 1;\n  }\n\n  .exampleRow,\n  .exampleCell {\n    margin: 10px;\n    padding: 10px;\n    background-color: rgba(0, 0, 0, 0.2);\n    cursor: move;\n    cursor: grab;\n    cursor: -moz-grab;\n    cursor: -webkit-grab;\n  }\n    \n  
\n
\n    \n  // JS\n.controller('NestedNgRepeatWithModel', ['$timeout', '$scope', '$element', 'dragularService', function NestedNgRepeatWithModelCtrl($timeout, $scope, $element, dragularService) {\n    $timeout(function() { // timeount due to nested ngRepeat to be ready\n      var container = $element.children().eq(0).children(),\n        parentContainers = container.children(),\n        nestedContainers = [];\n\n      dragularService(container, {\n        moves: function(el, container, handle) {\n          return handle.classList.contains('row-handle');\n        },\n        containersModel: $scope.items,\n        nameSpace: 'rows'\n      });\n\n      // collect nested contianers\n      for (var i = 0; i < parentContainers.length; i++) {\n        nestedContainers.push(parentContainers.eq(i).children()[1]);\n      }\n\n      dragularService(nestedContainers, {\n        moves: function(el, container, handle) {\n          return !handle.classList.contains('row-handle');\n        },\n        containersModel: (function getNestedContainersModel(){\n          var parent = $scope.items,\n            containersModel = [];\n          for (var i = 0; i < parent.length; i++) {\n            containersModel.push(parent[i].items);\n          }\n          return containersModel;\n        })(),\n        nameSpace: 'cells'\n      });\n    }, 0);\n    $scope.items = [{\n      items: [{\n        content: 'Item a1'\n      }, {\n        content: 'Item a2'\n      }, {\n        content: 'Item a3'\n      }, {\n        content: 'Item a4'\n      }]\n    }, {\n      items: [{\n        content: 'Item b1'\n      }, {\n        content: 'Item b2'\n      }, {\n        content: 'Item b3'\n      }, {\n        content: 'Item b4'\n      }]\n    }, {\n      items: [{\n        content: 'Item c1'\n      }, {\n        content: 'Item c2'\n      }, {\n        content: 'Item c3'\n      }, {\n        content: 'Item c4'\n      }]\n    }];\n  }])\n    \n  
\n
\n"),e.put("exampleNgRepeat/exampleNgRepeat.html","
\n

ngRepeat

\n \n
\n
\n
\n {{item.content}}\n
\n
\n
\n
\n        \n  // HTML:\n  <div class='containerVertical'>\n    <div ng-repeat="item in items">\n      {{item.content}}\n    </div>\n  </div>\n\n  // JS:\n  dragularService($element.children());\n  $scope.items = [{\n    content: 'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.'\n  },{\n    content: 'Item 2'\n  },{\n    content: 'Item 3'\n  },{\n    content: 'Item 4'\n  }];\n        \n      
\n
\n"),e.put("exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel.html","
\n

Filtered ngRepeat - with model

\n \n
\n
\n
\n \n
\n
\n \n
\n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  .controller('NgRepeatFilteredWithModel', ['$scope', '$element', 'dragularService', '$filter', function TodoCtrl($scope, $element, dragularService, $filter) {\n    $scope.items1 = [{\n      content: 'Move me, but you can only drop me in one of these containers.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Apple 3'\n    }, {\n      content: 'Orange 4'\n    }, {\n      content: 'Orange 5'\n    }, {\n      content: 'Apple 6'\n    }, {\n      content: 'Apple 7'\n    }, {\n      content: 'Apple 8'\n    }];\n    $scope.items2 = [{\n      content: 'Apple 9'\n    }, {\n      content: 'Orange 10'\n    }, {\n      content: 'Orange 11'\n    }, {\n      content: 'Apple 12'\n    }, {\n      content: 'Orange 13'\n    }, {\n      content: 'Apple 14'\n    }];\n    $scope.filter1query = 'Orange';\n    $scope.filter2query = 'Orange';\n    $scope.filteredModel1 = [];\n    $scope.filteredModel2 = [];\n    $scope.getFilteredModel = function (filteredModel, items, filterQuery) {\n      filteredModel.length = 0;\n      /*\n      * Following one-liner is same like:\n      *   var filteredModelTemp = $filter('filter')(items, filterQuery);\n      *   angular.forEach(filteredModelTemp, function(item){\n      *     filteredModel.push(item);\n      *   });\n      * Or like:\n      *   var filteredModelTemp = $filter('filter')(items, filterQuery);\n      *   for(var i; i < filteredModelTemp.length; i++){\n      *     filteredModel.push(filteredModelTemp[i]);\n      *   }\n      *\n      * You cannot just assign filtered array to filteredModel like this:\n      *   filteredModel = $filter('filter')(items, filterQuery);\n      * Because you would replace the array object you provide to dragular with new one.\n      * So dragular will continue to use the one it was provided on init.\n      * Hopefully I make it clear. :)\n       */\n      [].push.apply(filteredModel, $filter('filter')(items, filterQuery));\n      return filteredModel;\n    };\n    var containers = $element.children().eq(1).children();\n    dragularService.cleanEnviroment();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2],\n      containersFilteredModel: [$scope.filteredModel1, $scope.filteredModel2]\n    });\n  }]);\n\n        \n        \n<!-- HTML -->\n  <div class='wrapper' ng-controller="NgRepeatFilteredWithModel">\n    <div class="tableRow">\n      <div class='containerVertical'>\n        <input ng-model="filter1query" style="margin:10px 10px">\n      </div>\n      <div class='containerVertical'>\n        <input ng-model="filter2query" style="margin:10px 10px">\n      </div>\n    </div>\n    <div class='tableRow'>\n      <div class='containerVertical'>\n        <div ng-repeat="item in getFilteredModel(filteredModel1, items1, filter1query)">{{item.content}}</div>\n      </div>\n      <div class='containerVertical'>\n        <div ng-repeat="item in getFilteredModel(filteredModel2, items2, filter2query)">{{item.content}}</div>\n      </div>\n    </div>\n    <div class="tableRow">\n      <div class='containerVertical'>\n        <pre>Items1:\n          <br/>{{items1 | json}}</pre>\n      </div>\n      <div class='containerVertical'>\n        <pre>Items2:\n          <br/>{{items2 | json}}</pre>\n      </div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleNgRepeatWithModel/exampleNgRepeatWithModel.html","
\n

ngRepeat - with model

\n \n
\n
\n
\n
\n {{item.content}}\n \n \n
\n
\n
\n
\n
\n
Items:\n
{{items | json}}
\n
\n
\n
\n
\n    \n  // HTML:\n   <div class='wrapper' ng-controller="NgRepeatWithModel">\n      <div class='containerVertical'>\n        <div ng-repeat="item in items">\n          {{item.content}}\n          <button class='cursorDefault' ng-click="addItem()">+</button>\n          <button class='cursorDefault' ng-click="removeItem()">x</button>\n        </div>\n    </div>\n  </div>\n    \n  
\n
\n    \n  // JS:\n  controller('NgRepeatWithModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items = [{\n      content: 'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.'\n    }, {\n      content: 'Item 2'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    dragularService($element.children().eq(0).children(), {containersModel: $scope.items});\n    $scope.addItem = function addItem() {\n      var index = $scope.items.indexOf(this.item) + 1;\n      $scope.items.splice(index, 0, {\n        content: this.item.content + '-copy'\n      });\n    };\n    $scope.removeItem = function removeItem() {\n      var index = $scope.items.indexOf(this.item);\n      $scope.items.splice(index, 1);\n    };\n  }])\n    \n  
\n
\n"),e.put("exampleRemoveOnSpill/exampleRemoveOnSpill.html","
\n

Remove on spill

\n \n
\n
\n
Move me, but you can only drop me in containers.
\n
If you try to drop me somewhere other than containers, I'll die a fiery death.
\n
Item 3.
\n
Item 6.
\n
Item 4.
\n
Item 5.
\n
\n \n
\n
\n        \n  dragularService([document.getElementById(single)], { removeOnSpill: true });\n        \n      
\n
"),e.put("exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel.html","
\n

Remove on spill - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  .controller('RemoveOnSpillWithModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: 'Move me, but you can only drop me in containers.'\n    }, {\n      content: 'If you try to drop me somewhere other than containers, I\\'ll die a fiery death.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.items2 = [{\n      content: 'You can drop me in the left container.'\n    }, {\n      content: 'Item 6'\n    }, {\n      content: 'Item 7'\n    }, {\n      content: 'Item 8'\n    }];\n    var containers = $element.children().eq(0).children();\n    dragularService.cleanEnviroment();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2],\n      removeOnSpill: true\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="Basic">\n    <div class='tableRow'>\n        <div class='containerVertical'>\n            <div ng-repeat="item in items1">{{item.content}}</div>\n        </div>\n        <div class='containerVertical'>\n            <div ng-repeat="item in items2">{{item.content}}</div>\n        </div>\n    </div>\n    <div class="tableRow">\n        <div class="container">\n            <div>Items1:\n                <br/>{{items1 | json}}</div>\n        </div>\n        <div class="container">\n            <div>Items2:\n                <br/>{{items2 | json}}</div>\n        </div>\n    </div>\n</div>\n        \n      
\n
\n"),e.put("exampleRevertOnSpill/exampleRevertOnSpill.html","
\n

Revert on spill

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n  dragularService([document.getElementById(left), document.getElementById(right)], { revertOnSpill: true });\n        \n      
\n
"),e.put("exampleScrollingDrag/exampleScrollingDrag.html",'
\n

Scrolling drag

\n \n
\n
\n
up
\n
\n
Item 1.
\n
Item 2.
\n
Item 3.
\n
Item 4.
\n
Item 5.
\n
Item 6.
\n
Item 7.
\n
Item 9.
\n
Item 10.
\n
Item 11.
\n
Item 12.
\n
Item 13.
\n
\n
down
\n
\n
\n
\n
\n
Item 1.
\n
Item 2.
\n
Item 3.
\n
Item 4.
\n
Item 5.
\n
Item 6.
\n
Item 7.
\n
Item 9.
\n
Item 10.
\n
Item 11.
\n
Item 12.
\n
Item 13.
\n
\n
\n
\n
\n
\n        \n// JS\ncontroller(\'ScrollingDrag\', [\'$interval\', \'$element\', \'dragularService\', function TodoCtrl($interval, $element, dragularService) {\n\n\n    var timer,\n      leftScrollContainer = document.getElementById(\'leftScroll\'),\n      rightScrollContainer = document.getElementById(\'rightScroll\'),\n      leftTopBar = document.getElementById(\'leftTopBar\'),\n      leftBottomBar = document.getElementById(\'leftBottomBar\'),\n      rightTopBar = document.getElementById(\'rightTopBar\'),\n      rightBottomBar = document.getElementById(\'rightBottomBar\');\n\n    dragularService.cleanEnviroment();\n    dragularService([leftScrollContainer, rightScrollContainer]);\n\n    registerEvents(leftTopBar, leftScrollContainer, -5);\n    registerEvents(leftBottomBar, leftScrollContainer, 5);\n    registerEvents(rightTopBar, rightScrollContainer, -5);\n    registerEvents(rightBottomBar, rightScrollContainer, 5);\n\n    function registerEvents(bar, container, inc, speed) {\n      if (!speed) {\n        speed = 20;\n      }\n      angular.element(bar).on(\'dragularenter\', function() {\n        container.scrollTop += inc;\n        timer = $interval(function moveScroll() {\n          container.scrollTop += inc;\n        }, speed);\n      });\n      angular.element(bar).on(\'dragularleave dragularrelease\', function() {\n        $interval.cancel(timer);\n      });\n    }\n  }])\n        \n      
\n
\n        \n<!-- HTML -->\n<div ng-controller="ScrollingDrag">\n    <div class="containerVertical scrollingDrag">\n      <div class="scrollBar" id="leftTopBar">up</div>\n      <div id="leftScroll" class="scrollingDragInner">\n        <div>Item 1</div>\n        <div>Item 2</div>\n            ...\n      </div>\n      <div class="scrollBar" id="leftBottomBar">down</div>\n    </div>\n    <div class="containerVertical scrollingDrag">\n      <div class="scrollBar" id="rightTopBar">up</div>\n      <div id="rightScroll" class="scrollingDragInner">\n        <div>Item 1</div>\n        <div>Item 2</div>\n            ...\n      </div>\n      <div class="scrollBar" id="rightBottomBar">down</div>\n    </div>\n  </div>\n        \n      
\n
\n        \n// CSS\n.scrollingDrag {\n  width: 45%;\n  display: inline-block;\n}\n\n.scrollingDragInner {\n  max-height: 200px;\n  overflow-y: auto;\n}\n\n#rightTopBar,\n#rightBottomBar {\n  background: transparent;\n  position: relative;\n  height: 20px;\n}\n\n#rightTopBar {\n  top: 10px;\n}\n\n#rightBottomBar {\n  bottom: 10px;\n}\n\ndiv.scrollBar {\n  background: yellow;\n  text-align: center;\n  padding: 1px;\n}\n\n        \n      
\n
\n'),e.put("partials/partial-contribute.html",'
\n
\n
\n \n
\n
\n
\n'),e.put("partials/partial-docs.html",'
\n
\n \n \n
\n

\n \n

\n \n
\n
\n \n
\n \n
\n'),e.put("partials/partial-home.html",'
\n
\n \n
\n
\n

DRAGULAR

\n

Angular drag&drop based on dragula.

\n

Live examples in docs

\n
\n
\n
\n

Browser support includes every sane browser and **IE7+**. _(Granted you polyfill the functional `Array` methods in ES5)_

\n

Inspiration

\n

I am working on huge angular project and I am using several drag&drop libraries in it, one for UI, one for lists, etc.. I want to use one full-featured drag&drop library for whole project. As I could not find any suitable, I decided to create one. I have choosen great library dragula by Nicolas Bevacqua as my starting point, make it more angular and started to put features in it! If you wish light-weight angular version of dragula, there is official angular version of dragula.

\n

Actual version 4.1.0 is based on dragula 3.6.3 and tested with angular 1.4.9.

\n

Differences of dragular (against dragula)

\n
    \n
  • replaced dragula crossvent with angulars event binding
  • \n
  • replaced dragula contra.emitter with $scope.$emit if scope provided in options (options.scope)
  • \n
  • provided as service or directive dragular where options can be passed via atribute dragular
  • \n
  • automatic direction if not provided in options, instead of default vertical
  • \n
  • accepting arraylike objects as containers array (jQuery, jQlite collections etc..)
  • \n
  • accepting custom classes via option.classes
  • \n
  • namespaced containers groups available via option.nameSpace (containers in same nameSpace cooperate)
  • \n
  • boundingBox (dragging element can me moved only in specific area)
  • \n
  • lockX/Y (dragging element can me moved only in specific direction)
  • \n
  • DOM can be synced with scope model
  • \n
  • support css selectors to define containers
  • \n
  • added syntax highlighter to example codes
  • \n
  • etc..
  • \n
\n

Todo

\n
    \n
  • improve docs
  • \n
\n

Features

\n
    \n
  • provided as service and also as directive
  • \n
  • Super easy to set up
  • \n
  • No bloated dependencies
  • \n
  • Figures out sort order on its own
  • \n
  • A shadow where the item would be dropped offers visual feedback
  • \n
  • Touch events!
  • \n
\n

For installation, usage and examples go to docs

\n
\n
\n \n
\n \n
\n \n
\n'),e.put("partials/autogenerated/contribute.html",'

How to contribute

\n

It's important to us that you feel you can contribute towards the evolution of Dragular. This can take many forms: from helping to fix bugs or improve the docs, to adding in new features to the source. This guide should help you in making that process as smooth as possible.

\n

Before contributing, please read the code of conduct.

\n

Reporting issues

\n

GitHub Issues is the place to report bugs you may have found in either the core library or any of the examples that are part of the repository. When submitting a bug please do the following:

\n

1. Search for existing issues. Your bug may have already been fixed or addressed in a development branch version of Dragular, so be sure to search the issues first before putting in a duplicate issue.

\n

2. Not sure if it's a bug?. Then please ask via issues and tag it [question].

\n

3. Create an isolated and reproducible test case. If you are reporting a bug, make sure you also have a minimal, runnable, code example that reproduces the problem you have.

\n

4. Include a live example. After narrowing your code down to only the problem areas, make use of jsFiddle, jsBin, or a link to your live site so that we can view a live example of the problem. (you can start by forking this fiddle)

\n

5. Share as much information as possible. Include browser version affected, your OS, version of the library, steps to reproduce, etc. "X isn't working!!!1!" will probably just be closed.

\n

Dev vs. Master

\n

The dev branch of Dragular is our 'current working' version. It is always ahead of the master branch in terms of features and fixes. However it's also bleeding-edge and experimental and we cannot and do not guarantee it will compile or work for you. Very often we have to break things for a few days while we rebuild and patch. So by all means please export the dev branch and contribute towards it, indeed that is where all Pull Requests should be sent, but do so understanding the API may change beneath you.

\n

Making Changes

\n

To take advantage of our npm build script and jshint config it will be easiest for you if you have node.js installed locally.

\n

You can download node.js from nodejs.org.

\n

After that you can clone the repository and run npm i inside the cloned folder. This will install dependencies necessary for building the project. For development workflow automation dragular uses gulp >= 3.9.0. Before starting development, make sure that gulp is installed on your machine globally: npm i -g gulp.

\n

Developing

\n

There are several gulp tasks that are used for generating different builds:

\n
    \n
  • gulp dev - Serves files with BrowserSync server, watches & automatically refreshes connected browsers on changes, generates non-minified but concatenated styles & scripts from the dragular source.
  • \n
  • gulp dev:docs - Does exactly the same as gulp dev, except it works with the documentation source.
  • \n
  • gulp build - Concatenates and minifies dragular source files.
  • \n
  • gulp build:docs - Concatenates and minifies documentation source files.
  • \n
\n

Linting

\n
    \n
  • gulp lint & gulp lint:docs - Lint JavaScript files.
  • \n
\n

Making a pull request

\n

Once that is ready, make your changes and submit a Pull Request:

\n
    \n
  • Send Pull Requests to the dev branch. All Pull Requests must be sent to the dev branch, master is the latest release and PRs to that branch will be closed.

    \n
  • \n
  • Ensure changes are jshint validated. Our JSHint configuration file is provided in the repository and you should check against it before submitting.

    \n
  • \n
  • Only commit relevant changes. Don't include changes that are not directly relevant to the fix you are making. The more focused a PR is, the faster it will get attention and be merged. Extra files changing only whitespace or trash files will likely get your PR closed.

    \n
  • \n
\n

Dependencies for building from source and running tests:

\n

Coding style preferences are not contributions

\n

If your PR is doing little more than changing the Dragular source code into a format / coding style that you prefer then we will automatically close it. All PRs must adhere to the coding style already set-out across the lines of code in Dragular. Your personal preferences for how things should "look" or be structured do not apply here, sorry. PRs should fix bugs, fix documentation or add features. No changes for the sake of change.

\n

I don't really like git / node.js, but I can fix this bug

\n

That is fine too. While Pull Requests are the best thing in the world for us, they are not the only way to help. You're welcome to post fixes to our forum or even just email them to us. All we ask is that you still adhere to the guidelines presented here re: JSHint, etc.

\n'); -}])}]); +!function(e,n){if("object"==typeof exports&&"object"==typeof module)module.exports=n();else if("function"==typeof define&&define.amd)define([],n);else{var t=n();for(var o in t)("object"==typeof exports?exports:e)[o]=t[o]}}(this,function(){return function(e){function n(o){if(t[o])return t[o].exports;var i=t[o]={exports:{},id:o,loaded:!1};return e[o].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}var t={};return n.m=e,n.c=t,n.p="",n(0)}([function(e,n,t){"use strict";var o=t(1),i=t(4),r=t(5),l=t(6),a=t(7),c=t(8),s=t(9),d=t(10),m=t(11),u=t(12),v=t(13),p=t(14),g=t(15),h=t(16),f=t(17),b=t(18),y=t(19),x=t(20),I=t(21),w=t(22),S=t(23),M=t(24),$=t(25),q=t(26),C=t(27),B=t(28),k=t(29);t(30),angular.module("examplesApp",[o,"templates","ui.router"]).config(i).controller("Basic",r).controller("BasicModel",l).controller("BoundingBox",a).controller("BoundingBoxLockX",c).controller("BoundingBoxLockY",s).controller("Copy",d).controller("CopyModel",m).controller("CustomClasses",u).controller("DifferentOptionsModel",v).controller("Directive",p).controller("DirectiveModel",g).controller("DragOverEvents",h).controller("Events",f).controller("Handle",b).controller("IsContainerModel",y).controller("NameSpaces",x).controller("NestedNgRepeat",I).controller("NestedNgRepeatWithModel",w).controller("NgRepeat",S).controller("NgRepeatFilteredWithModel",M).controller("NgRepeatWithModel",$).controller("RemoveOnSpill",q).controller("RemoveOnSpillWithModel",C).controller("RevertOnSpill",B).controller("ScrollingDrag",k).controller("ExAppCtrl",["$scope",function(e){e.examplesList=[{template:"docsInstall/docsInstall.html",link:"docsInstall",title:"Installation"},{template:"exampleBasic/exampleBasic.html",link:"exampleBasic",title:"Basic"},{template:"exampleBasicWithModel/exampleBasicWithModel.html",link:"exampleBasicWithModel",title:"Basic - with model"},{template:"exampleDifferentOptionsWithModel/exampleDifferentOptionsWithModel.html",link:"exampleDifferentOptionsWithModel",title:"Different options - with model"},{template:"exampleDirective/exampleDirective.html",link:"exampleDirective",title:"Directive"},{template:"exampleDirectiveWithModel/exampleDirectiveWithModel.html",link:"exampleDirectiveWithModel",title:"Directive - with model"},{template:"exampleEvents/exampleEvents.html",link:"exampleEvents",title:"Events"},{template:"exampleRemoveOnSpill/exampleRemoveOnSpill.html",link:"exampleRemoveOnSpill",title:"Remove on spill"},{template:"exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel.html",link:"exampleRemoveOnSpillWithModel",title:"Remove on spill - with model"},{template:"exampleRevertOnSpill/exampleRevertOnSpill.html",link:"exampleRevertOnSpill",title:"Revert on spill"},{template:"exampleCopy/exampleCopy.html",link:"exampleCopy",title:"Copy"},{template:"exampleCopyWithModel/exampleCopyWithModel.html",link:"exampleCopyWithModel",title:"Copy - with model"},{template:"exampleHandle/exampleHandle.html",link:"exampleHandle",title:"Handle"},{template:"exampleIsContainerWithModel/exampleIsContainerWithModel.html",link:"exampleIsContainerWithModel",title:"isContainer - with model"},{template:"exampleCustomClasses/exampleCustomClasses.html",link:"exampleCustomClasses",title:"Custom classes"},{template:"exampleNameSpaces/exampleNameSpaces.html",link:"exampleNameSpaces",title:"NameSpaces"},{template:"exampleDragOverEvents/exampleDragOverEvents.html",link:"exampleDragOverEvents",title:"Drag-over events"},{template:"exampleBoundingBox/exampleBoundingBox.html",link:"exampleBoundingBox",title:"BoundingBox"},{template:"exampleBoundingBoxLockX/exampleBoundingBoxLockX.html",link:"exampleBoundingBoxLockX",title:"BoundingBox + LockX"},{template:"exampleBoundingBoxLockY/exampleBoundingBoxLockY.html",link:"exampleBoundingBoxLockY",title:"BoundingBox + LockY"},{template:"exampleNgRepeat/exampleNgRepeat.html",link:"exampleNgRepeat",title:"ngRepeat"},{template:"exampleNgRepeatWithModel/exampleNgRepeatWithModel.html",link:"exampleNgRepeatWithModel",title:"ngRepeat - with model"},{template:"exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel.html",link:"exampleNgRepeatFilteredWithModel",title:"Filtered ngRepeat - with model"},{template:"exampleNestedNgRepeat/exampleNestedNgRepeat.html",link:"exampleNestedNgRepeat",title:"Nested ngRepead"},{template:"exampleNestedNgRepeatWithModel/exampleNestedNgRepeatWithModel.html",link:"exampleNestedNgRepeatWithModel",title:"Nested ngRepead - with model"},{template:"exampleScrollingDrag/exampleScrollingDrag.html",link:"exampleScrollingDrag",title:"Scrolling drag"}],e.highlightCode=function(){if(document.getElementsByTagName("code").length)for(var e=document.getElementsByTagName("code"),n=e.length-1;n>=0;n--)hljs.highlightBlock(e[n])};var n;e.toggleSidebar=function(){n||(n=angular.element(document.getElementById("rowOffcanvas"))),n.toggleClass("active")}}])},function(e,n,t){"use strict";var o=t(2),i=t(3);e.exports="dragularModule",angular.module("dragularModule",[]).factory("dragularService",i).directive("dragular",o)},function(e,n){"use strict";var t=function(e){return{restrict:"A",link:function(n,t,o){function i(e){try{return JSON.parse(e)}catch(n){return}}var r,l=n.$eval(o.dragular)||i(o.dragular)||{};l&&l.containersModel&&"string"==typeof l.containersModel&&(l.containersModel=n.$eval(l.containersModel)),l&&l.dynamicModelAttribute?n.$watch(function(){return n.$eval(o.dragularModel)},function(e){e&&(r.containersModel=r.sanitizeContainersModel(n.$eval(e)))}):o.dragularModel&&(l.containersModel=n.$eval(o.dragularModel)),o.dragularNameSpace&&(l.nameSpace=o.dragularNameSpace.split(" ")),o.dragularOnInit&&(l.onInit=n.$eval(o.dragularOnInit)),r=e(t[0],l)}}};t.$inject=["dragularService"],e.exports=t},function(e,n){(function(n){"use strict";var t={classesCache:{},containersCtx:{},containers:{},mirror:null,source:null,item:null,copy:null,sourceItem:null,sourceModel:null,sourceFilteredModel:null,target:null,targetCtx:null,targetModel:null,lastDropTarget:null,offsetX:null,offsetY:null,moveX:null,moveY:null,offsetXr:null,offsetYb:null,clientX:null,clientY:null,mirrorWidth:null,mirrorHeight:null,initialSibling:null,currentSibling:null,initialIndex:null,currentIndex:null,tempModel:null,dragOverEvents:{},lastElementBehindCursor:null,grabbed:null},o=function(e,o){function i(n,i){function m(e){return"function"==typeof e?e:Array.isArray(e)?Array.isArray(e[0])?e:[e]:[]}function b(){1!==arguments.length||Array.isArray(n)||angular.isElement(n)||n[0]||"string"==typeof n?"string"==typeof n&&(ce=document.querySelectorAll(n)):(se=n||{},ce=[]),ae=se.copyOptions?angular.copy(se):se}function I(){var e=angular.extend({},ve,ae);angular.extend(ae,e),ae.classes&&(e=angular.extend({},me,ae.classes),angular.extend(ae.classes,e)),ae.eventNames&&(e=angular.extend({},ue,ae.eventNames),angular.extend(ae.eventNames,e))}function $(){f(ae.boundingBox)||(ae.boundingBox=!1),ae.containers&&(ce=ae.containers),ce=c(ce),ae.containersModel=m(ae.containersModel),Array.isArray(ae.containersFilteredModel)?ae.containersFilteredModel=Array.isArray(ae.containersFilteredModel[0])?ae.containersFilteredModel:[ae.containersFilteredModel]:ae.containersFilteredModel=[],ae.nameSpace||(ae.nameSpace=["dragularCommon"]),Array.isArray(ae.nameSpace)||(ae.nameSpace=[ae.nameSpace]),ae.nameSpace.forEach(function(e){t.containers[e]||(t.containers[e]=[],t.containersCtx[e]=[]);for(var n=ce.length,o=t.containers[e].length,i=0;n>i;i++)t.containers[e][i+o]=ce[i],t.containersCtx[e][i+o]={o:ae,m:T()[i],fm:ae.containersFilteredModel[i]}})}function R(e){var n=e?"off":"on";r(E,n,"mouseup",O),ce.forEach(function(e){r(e,"on","mousedown",N)}),e||angular.forEach(["dragularenter","dragularleave","dragularrelease"],function(e){var n=ae.eventNames[e];t.dragOverEvents[n]||(k.createEvent?(t.dragOverEvents[n]=k.createEvent("HTMLEvents"),t.dragOverEvents[n].initEvent(n,!0,!0)):(t.dragOverEvents[n]=k.createEventObject(),t.dragOverEvents[n].eventType=n))})}function N(e){if(1===s(e)&&!e.metaKey&&!e.ctrlKey){t.moveX=e.clientX,t.moveY=e.clientY;var n=A(e.target);n&&n.item&&(t.grabbed=n,V(),"mousedown"===e.type&&(M(n.item)?n.item.focus():e.preventDefault()))}}function O(e){if(P(),pe.dragging){e.originalEvent&&(e=e.originalEvent),t.clientX=w("clientX",e),t.clientY=w("clientY",e);var n=le(t.mirror,t.clientX,t.clientY),o=_(n,t.clientX,t.clientY);o&&(t.copy&&de(ae.copySortSource)||!t.copy||o!==t.source)?J(t.item,o):de(ae.removeOnSpill)?U():z(),t.target=null,t.lastElementBehindCursor&&C(t.lastElementBehindCursor,t.dragOverEvents.dragularrelease,n),ae.scope&&ae.scope.$emit(ae.eventNames.dragularrelease,t.item,t.source)}}function j(e){if(!e)return!1;for(var n=ae.nameSpace.length;n--;)if(-1!==t.containers[ae.nameSpace[n]].indexOf(e))return!0;return ae.isContainer(e)?(t.tempModel=ae.isContainerModel(e),!0):(t.tempModel=null,!1)}function T(){return"function"==typeof ae.containersModel?m(ae.containersModel(pe,t)):ae.containersModel}function D(n){e.$applyAsync(function(){var e=Array.isArray(n)?n:c(n);e.forEach(function(e){angular.forEach(ae.nameSpace,function(n){var o;o=t.containers[n].indexOf(e),t.containers[n].splice(o,1),t.containersCtx[n].splice(o,1)})})})}function V(e){var n=e?"off":"on";r(E,n,"mousemove",L)}function Y(e){var n=e?"off":"on";r(E,n,"selectstart",d),r(E,n,"click",d),r(E,n,"touchmove",d)}function W(){R(!0),D(ce),O({})}function L(e){if(t.grabbed&&!pe.dragging){if(e.originalEvent&&(e=e.originalEvent),0===s(e))return void O({});if(!e.clientX||e.clientX!==t.moveX||!e.clientY||e.clientY!==t.moveY){if(de(ae.ignoreInputTextSelection)){var n=w("clientX",e),o=w("clientY",e),i=k.elementFromPoint(n,o);if(M(i))return}var r=t.grabbed;if(V("remove"),Y(),H(),F(r),!ae.direction&&S(t.sourceItem)){var l=t.sourceItem.parentNode,a=l.offsetHeight,c=l.offsetWidth,d=t.sourceItem.clientHeight,m=t.sourceItem.clientWidth;ae.direction=c/m>a/d?"horizontal":"vertical"}var v=u(t.sourceItem);t.offsetX=w("pageX",e)-v.left,t.offsetY=w("pageY",e)-v.top,t.clientX=w("clientX",e),t.clientY=w("clientY",e),ae.boundingBox&&(t.offsetXr=w("pageX",e)-v.right,t.offsetYb=w("pageY",e)-v.bottom),e.preventDefault(),y(t.item,ae.classes.transit),te(),t.mirror.style.left=t.clientX-t.offsetX+"px",t.mirror.style.top=t.clientY-t.offsetY+"px",K(e)}}}function A(e){if(!pe.dragging||!t.mirror){for(var n=e;S(e)&&!j(S(e));){if(ae.invalid(e,n))return;if(e=S(e),!e)return}var o=S(e);if(o&&!ae.invalid(e,n)&&ae.moves(e,o,n,h(e)))return{item:e,source:o}}}function X(e){var n=A(e);n&&F(n)}function F(e){t.sourceItem=t.item=e.item,t.source=e.source,t.initialSibling=t.currentSibling=h(e.item),de(ae.copy,[e.item,e.source])?(t.item=e.item.cloneNode(!0),t.copy=!0,ae.scope&&ae.scope.$emit(ae.eventNames.dragularcloned,t.item,e.item)):t.copy=!1;var n=ce.indexOf(e.source);return t.sourceModel=T()[n],t.sourceFilteredModel=ae.containersFilteredModel[n],t.initialIndex=q(e.item,e.source),pe.dragging=!0,ae.scope&&ae.scope.$emit(ae.eventNames.dragulardrag,t.sourceItem,t.source),!0}function H(){pe.dragging&&t.item&&J(t.item,S(t.item))}function P(){t.grabbed=!1,V("remove"),Y("remove")}function J(n,i){function r(){if(ae.compileItemOnDrop){var e=angular.element(i).scope();e.$applyAsync(function(){var r=o(t.copy?l.cloneNode(!0):l)(e);n.parentNode===i&&i.removeChild(n),i.insertBefore(r[0],a)})}ae.scope&&(G(i)?ae.scope.$emit(ae.eventNames.dragularcancel,n,t.source,t.sourceModel,t.initialIndex):ae.scope.$emit(ae.eventNames.dragulardrop,n,i,t.source,t.sourceModel,t.initialIndex,t.targetModel,c)),Q()}var l=t.sourceItem,a=t.currentSibling;if(t.copy&&de(ae.copySortSource)&&i===t.source&&S(n)&&n.parentNode.removeChild(t.sourceItem),t.sourceModel&&!G(i)){var c=q(n,i);t.targetCtx.fm&&(c=t.targetCtx.m.indexOf(t.targetCtx.fm[c])),t.sourceFilteredModel&&(t.initialIndex=t.sourceModel.indexOf(t.sourceFilteredModel[t.initialIndex])),e.$applyAsync(function(){t.sourceModel&&(i===t.source?t.sourceModel.splice(c,0,t.sourceModel.splice(t.initialIndex,1)[0]):(t.dropElmModel=t.copy&&!ae.dontCopyModel?angular.copy(t.sourceModel[t.initialIndex]):t.sourceModel[t.initialIndex],t.tempModel?t.targetModel=t.tempModel:t.targetModel=t.targetCtx.m,i.removeChild(n),t.copy||t.sourceModel.splice(t.initialIndex,1),t.targetModel.splice(c,0,t.dropElmModel)),S(n)&&n.parentNode.removeChild(n),r())})}else r()}function U(){if(pe.dragging){var n=S(t.item);n&&n.removeChild(t.item),t.sourceModel&&e.$applyAsync(function(){t.sourceModel.splice(t.initialIndex,1),Q()}),ae.scope&&ae.scope.$emit(t.copy?ae.eventNames.dragularcancel:ae.eventNames.dragularremove,t.item,n,t.sourceModel,t.initialIndex),t.sourceModel||Q()}}function z(e){if(pe.dragging){var n=arguments.length>0?e:de(ae.revertOnSpill),o=S(t.item),i=G(o);i||t.copy||!n||t.source.insertBefore(t.item,t.initialSibling),!t.sourceModel||t.copy||n?ae.scope&&(i||n)&&ae.scope.$emit(ae.eventNames.dragularcancel,t.item,t.source):J(t.item,o),(!t.sourceModel||t.copy||n||i)&&Q()}}function Q(){P(),oe(),t.item&&x(t.item,ae.classes.transit),pe.dragging=!1,de(ae.removeOnSpill)===!0&&ee(),ae.scope&&(t.lastDropTarget&&ae.scope.$emit(ae.eventNames.dragularout,t.item,t.lastDropTarget,t.source),ae.scope.$emit(ae.eventNames.dragulardragend,t.item)),t.source=t.item=t.sourceItem=t.initialSibling=t.currentSibling=t.sourceModel=null,t.initialIndex=t.currentIndex=t.lastDropTarget=t.tempModel=t.targetModel=null,t.dropElmModel=t.targetCtx=t.copy=t.moveX=t.moveY=null}function G(e,n){var o=n||(t.mirror?t.currentSibling:h(t.item));return e===t.source&&o===t.initialSibling}function _(e,n,o){function i(){var i=!1;if(j(r)){for(var l=ie(r,e),a=re(r,l,n,o),c=G(r,a),s=ae.nameSpace.length;s--;){if(-1!==t.containers[ae.nameSpace[s]].indexOf(r)){t.targetCtx=t.containersCtx[ae.nameSpace[s]][t.containers[ae.nameSpace[s]].indexOf(r)];break}t.targetCtx||(t.targetCtx=t.containersCtx.dragularCommon[t.containers.dragularCommon.indexOf(r)])}i=c||t.targetCtx.o.accepts(t.item,r,t.source,a,t.sourceModel,t.initialIndex)&&ae.canBeAccepted(t.item,r,t.source,a,t.sourceModel,t.initialIndex),t.target!==r&&(t.target=r)}return i}for(var r=e;r&&!i();)r=S(r);return r}function K(e){function n(e){ae.scope&&ae.scope.$emit(ae.eventNames["dragular"+e],t.item,t.lastDropTarget,t.source),de(ae.removeOnSpill)===!0&&("over"===e?Z():ee())}if(t.mirror){e.originalEvent&&(e=e.originalEvent),t.clientX=w("clientX",e),t.clientY=w("clientY",e);var o,i,r,l=t.clientX-t.offsetX,a=t.clientY-t.offsetY;ae.boundingBox&&(o=w("pageX",e),i=w("pageY",e),r=u(ae.boundingBox)),ae.lockY||(!ae.boundingBox||o>r.left+t.offsetX&&or.top+t.offsetY&&in;n++){if(i=e.children[n],r=i.getBoundingClientRect(),a&&r.left>t)return i;if(!a&&r.top>o)return i}return null}function r(){var e=n.getBoundingClientRect();return l(a?t>e.left+v(e)/2:o>e.top+p(e)/2)}function l(e){return e?h(n):n}var a="horizontal"===ae.direction;return n!==e?r():i()}function le(e,n,t){var o,i=e||{},r=i.className;return i.className+=" "+ae.classes.hide,o=k.elementFromPoint(n,t),i.className=r,o}var ae,ce=n||[],se=i||{},de=B,me={mirror:"gu-mirror",hide:"gu-hide",unselectable:"gu-unselectable",transit:"gu-transit"},ue={dragularenter:"dragularenter",dragularleave:"dragularleave",dragularrelease:"dragularrelease",dragularcloned:"dragularcloned",dragulardrag:"dragulardrag",dragularcancel:"dragularcancel",dragulardrop:"dragulardrop",dragularremove:"dragularremove",dragulardragend:"dragulardragend",dragularshadow:"dragularshadow",dragularover:"dragularover",dragularout:"dragularout"},ve={copyOptions:!1,classes:me,eventNames:ue,containers:!1,containersModel:!1,containersFilteredModel:!1,isContainer:l,isContainerModel:g,moves:a,accepts:a,canBeAccepted:a,copy:!1,copySortSource:!1,dontCopyModel:!1,invalid:l,revertOnSpill:!1,removeOnSpill:!1,lockX:!1,lockY:!1,boundingBox:!1,mirrorContainer:k.body,ignoreInputTextSelection:!0,compileItemOnDrop:!1,onInit:!1},pe={containers:t.containers,containersCtx:t.containersCtx,sanitizeContainersModel:m,isContainer:j,start:X,end:H,cancel:z,remove:U,destroy:W,dragging:!1};return b(),I(),$(),R(),ae.onInit&&ae.onInit(pe),pe}function r(e,t,o,i){var r={mouseup:"touchend",mousedown:"touchstart",mousemove:"touchmove"},l={mouseup:"pointerup",mousedown:"pointerdown",mousemove:"pointermove"},a={mouseup:"MSPointerUp",mousedown:"MSPointerDown",mousemove:"MSPointerMove"},c=angular.element(e);n.navigator.pointerEnabled&&l[o]?c[t](l[o],i):n.navigator.msPointerEnabled&&a[o]?c[t](a[o],i):r[o]&&c[t](r[o],i),c[t](o,i)}function l(){return!1}function a(){return!0}function c(e,n){return Array.isArray(e)?e:e.length?Array.prototype.slice.call(e,n):[e]}function s(e){if(e.touches)return e.touches.length;if(e.originalEvent&&e.originalEvent.touches)return e.originalEvent.touches.length;if(void 0!==e.buttons)return e.buttons;if(void 0!==e.which)return e.which;var n=e.button;return void 0!==n?1&n?1:2&n?3:4&n?2:0:void 0}function d(e){e.originalEvent&&(e=e.originalEvent),t.grabbed&&e.preventDefault()}function m(e,n){return"undefined"!=typeof window[n]?window[n]:E.clientHeight?E[e]:k.body[e]}function u(e){var n=e.getBoundingClientRect(),t=m("scrollTop","pageYOffset"),o=m("scrollLeft","pageXOffset");return{left:n.left+o,right:n.right+o,top:n.top+t,bottom:n.bottom+t}}function v(e){return e.width||e.right-e.left}function p(e){return e.height||e.bottom-e.top}function g(){return{}}function h(e){function n(){var n=e;do n=n.nextSibling;while(n&&1!==n.nodeType);return n}return e.nextElementSibling||n()}function f(e){return"object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&null!==e&&1===e.nodeType&&"string"==typeof e.nodeName}function b(e){var n=t.classesCache[e];return n?n.lastIndex=0:t.classesCache[e]=n=new RegExp("(?:^|\\s)"+e+"(?:\\s|$)","g"),n}function y(e,n){var t=e.className;t.length?b(n).test(t)||(e.className+=" "+n):e.className=n}function x(e,n){e.className=e.className.replace(b(n)," ").trim()}function I(e){return e.targetTouches&&e.targetTouches.length?e.targetTouches[0]:e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e}function w(e,n){var t=I(n),o={pageX:"clientX",pageY:"clientY"};return e in o&&!(e in t)&&o[e]in t&&(e=o[e]),!t.type||t.type.indexOf("touch")<0?t[e]:-1===t.type.indexOf("end")?t.originalEvent.touches[0][e.replace("client","page")]:!1}function S(e){return e.parentNode===document?null:e.parentNode}function M(e){return"INPUT"===e.tagName||"TEXTAREA"===e.tagName||"SELECT"===e.tagName||$(e)}function $(e){return e?"false"===e.contentEditable?!1:"true"===e.contentEditable?!0:$(S(e)):!1}function q(e,n){return Array.prototype.indexOf.call(angular.element(n).children(),e)}function C(e,n,o){e&&(t.extra=o,e.dispatchEvent?e.dispatchEvent(n):e.fireEvent("on"+n.eventType,n))}function B(e,n,o){return angular.isFunction(e)?!!e.apply(o||this,n||t):!!e}var k=document,E=k.documentElement;return i.cleanEnviroment=function(){t.classesCache={},t.containersCtx={},t.containers={},t.mirror=void 0},i.shared=t,i};o.$inject=["$rootScope","$compile"],e.exports=o}).call(n,function(){return this}())},function(e,n){"use strict";var t=function(e,n){n.otherwise("/home");var t,o=function(e,n,o){n.link?o.cancel(t):t=o(function(){e.go("docs.detail",{link:"docsInstall"})},0)};o.$inject=["$state","$stateParams","$timeout"],e.state("home",{url:"/home",templateUrl:"partials/partial-home.html"}).state("docs",{url:"/docs",templateUrl:"partials/partial-docs.html",controller:o}).state("docs.detail",{url:"/:link",templateUrl:function(e){return e.link+"/"+e.link+".html"},controller:o}).state("contribute",{url:"/contribute",templateUrl:"partials/partial-contribute.html"})};t.$inject=["$stateProvider","$urlRouterProvider"],e.exports=t},function(e,n){"use strict";var t=function(e,n){n.cleanEnviroment(),n(".containerVertical")};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t){e.items1=[{content:"Move me, but you can only drop me in one of these containers."},{content:"If you try to drop me somewhere other than these containers, I'll just come back."},{content:"Item 3"},{content:"Item 4"}],e.items2=[{content:"Item 5"},{content:"Item 6"},{content:"Item 7"},{content:"Item 8"}];var o=n.children().eq(0).children();t.cleanEnviroment(),t([o[0],o[1]],{containersModel:[e.items1,e.items2]})};t.$inject=["$scope","$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){var t=e[0];n.cleanEnviroment(),n(e.children(),{boundingBox:t})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){var t=e.children().children()[0];n.cleanEnviroment(),n(t,{boundingBox:t,lockX:!0})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){var t=e.children().children()[0];n.cleanEnviroment(),n(t,{boundingBox:t,lockY:!0})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){n.cleanEnviroment(),n(e.children(),{copy:!0})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t){e.items1=[{content:"Move me, and make copy on drop."},{content:"If you try to drop me somewhere other than these containers, I'll just come back."},{content:"Item 3"},{content:"Item 4"}],e.items2=[{content:"Item 5"},{content:"Item 6"},{content:"Item 7"},{content:"Item 8"}];var o=n.children().eq(0).children();t.cleanEnviroment(),t([o[0],o[1]],{containersModel:[e.items1,e.items2],copy:!0})};t.$inject=["$scope","$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){n.cleanEnviroment(),n(e.children(),{classes:{mirror:"custom-green-mirror"}})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t){function o(e,n,t){return t===i||t===n?!0:void 0}e.items1=[{content:"Move me, but you can only drop me in one of these containers."},{content:"If you try to drop me somewhere other than these containers, I'll just come back."},{content:"Item 3"},{content:"Item 4"}],e.items2=[{content:"Item 5"},{content:"Item 6"},{content:"Item 7"},{content:"Item 8"}];var i=document.querySelector("#containerLeft"),r=document.querySelector("#containerRight");t.cleanEnviroment(),t([i],{containersModel:[e.items1],copy:!0,copySortSource:!0,accepts:o}),t([r],{containersModel:[e.items2],removeOnSpill:!0,accepts:o})};t.$inject=["$scope","$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e){e.dragularOptions={classes:{mirror:"custom-green-mirror"},nameSpace:"same"}};t.$inject=["$scope"],e.exports=t},function(e,n){"use strict";var t=function(e){e.items1=[{content:"Move me, and make copy on drop."},{content:"If you try to drop me somewhere other than these containers, I'll just come back."},{content:"Item 3"},{content:"Item 4"}],e.items2=[{content:"Item 5"},{content:"Item 6"},{content:"Item 7"},{content:"Item 8"}],e.dragularOptions={containersModel:e.items1,classes:{mirror:"custom-green-mirror"},nameSpace:"common"}};t.$inject=["$scope"],e.exports=t},function(e,n){"use strict";var t=function(e,n){function t(e){e.on("dragularenter",function(t){e[0]===t.target&&e.addClass(n.shared.extra?"gu-over-accept":"gu-over-decline")}),e.on("dragularleave dragularrelease",function(t){(e[0]===t.target&&n.shared.extra&&n.shared.extra.parentElement!==t.target||"dragularrelease"===t.type)&&(e.removeClass("gu-over-accept"),e.removeClass("gu-over-decline"))})}n.cleanEnviroment(),n([e.children()[0],e.children()[2]],{nameSpace:"apples"}),n([e.children()[1],e.children()[3]],{nameSpace:"oranges"}),angular.forEach(e.children(),function(e){t(angular.element(e))});var o=angular.element(document.getElementsByClassName("notContainer"));o.on("dragularenter",function(){o.addClass("gu-over")}),o.on("dragularleave dragularrelease",function(){o.removeClass("gu-over")})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t,o){function i(e){return function(){}}t.cleanEnviroment(),t(n.children(),{scope:e}),e.$on("dragulardrag",function(e,n){e.stopPropagation(),n.className=n.className.replace(" ex-moved","")}),e.$on("dragulardrop",function(e,n){e.stopPropagation(),o(function(){n.className+=" ex-moved"},0)}),e.$on("dragularcloned",i("cloned")),e.$on("dragulardrag",i("drag")),e.$on("dragularcancel",i("cancel")),e.$on("dragulardrop",i("drop")),e.$on("dragularremove",i("remove")),e.$on("dragulardragend",i("dragend")),e.$on("dragularshadow",i("shadow"))};t.$inject=["$scope","$element","dragularService","$timeout"],e.exports=t},function(e,n){"use strict";var t=function(e,n){n.cleanEnviroment(),n(e.children(),{moves:function(e,n,t){return"handle"===t.className}})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t){e.items1=[{content:"Move me, but you can only drop me in one of these containers."},{content:"If you try to drop me somewhere other than these containers, I'll just come back."},{content:"Item 3"},{content:"Item 4"}],e.cartModel=[];var o=document.querySelector("#containerLeft");t.cleanEnviroment(),t([o],{containersModel:[e.items1],copy:!0,isContainer:function(e){return"cart"===e.id},isContainerModel:function(){return e.cartModel}}),e.removeItem=function(){var n=e.cartModel.indexOf(this.item);e.cartModel.splice(n,1)}};t.$inject=["$scope","$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n){n.cleanEnviroment(),n([e.children()[0],e.children()[2]],{nameSpace:"apples"}),n(e.children()[1],{nameSpace:"oranges"}),n(e.children()[3],{nameSpace:["oranges","apples"]})};t.$inject=["$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t,o){e(function(){o.cleanEnviroment(),o(t,{nameSpace:"rows",moves:function(e,n,t){return t.classList.contains("row-handle")}}),o(t.children(),{nameSpace:"cells",moves:function(e,n,t){return!t.classList.contains("row-handle")}})},0),n.items=[{items:[{content:"Item a1"},{content:"Item a2"},{content:"Item a3"},{content:"Item a4"}]},{items:[{content:"Item b1"},{content:"Item b2"},{content:"Item b3"},{content:"Item b4"}]},{items:[{content:"Item c1"},{content:"Item c2"},{content:"Item c3"},{content:"Item c4"}]}]};t.$inject=["$timeout","$scope","$element","dragularService"],e.exports=t},function(e,n){"use strict";var t=function(e,n,t,o){e(function(){var e=t.children().eq(0).children(),i=e.children(),r=[];o.cleanEnviroment(),o(e,{moves:function(e,n,t){return t.classList.contains("row-handle")},containersModel:n.items,nameSpace:"rows"});for(var l=0;lInstall\n

download dragular.js and dragular.css from dist folder

\n

OR clone git

\n
\ngit clone http://github.com/luckylooke/dragular.git\n
\n

OR use npm

\n
\n[sudo] npm install dragular\n
\n

OR use bower

\n
\nbower install dragular\n
\n

AND include files into your project

\n
\n<link href='styles/dragular.css' rel='stylesheet' type='text/css' />\n<script src='scripts/dragular.js'></script>\n
\n

AND put dragularModule into dependency array

\n
\nvar app = angular.module('myApp', ['dragularModule', 'otherDependencies']);\n
\n

DONE :)

\n"),e.put("exampleBasic/exampleBasic.html","
\n

Basic

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
Try to click me, dragular distinguish drag from click
\n
Item 5.
\n
\n
\n
\n        \n// JS\n  controller('Basic', ['$element', 'dragularService', function TodoCtrl($element, dragularService) {\n    dragularService('.containerVertical');\n  }])\n        \n        \n// CSS\n.clickedClass {\n  background-color: orange !important;\n}\n        \n        \n<!-- HTML -->\n  <div class='wrapper' ng-controller="Basic">\n    <div class='containerVertical'>\n        <div>Move me, but you can only drop me in one of these containers.</div>\n        <div>If you try to drop me somewhere other than these containers, I'll just come back.</div>\n        <div>Item 3.</div>\n        <div>Item 6.</div>\n    </div>\n    <div class='containerVertical'>\n        <div>You can drop me in the left container, otherwise I'll stay here.</div>\n        <div ng-click=\"clicked = !clicked\" ng-class=\"clicked && 'clickedClass'\">Try to click me, dragular distinguish drag from click</div>\n        <div>Item 5.</div>\n    </div>\n</div>\n        \n      
\n
\n"),e.put("exampleBasicWithModel/exampleBasicWithModel.html","
\n

Basic - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  controller('BasicModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: 'Move me, but you can only drop me in one of these containers.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.items2 = [{\n      content: 'Item 5'\n    }, {\n      content: 'Item 6'\n    }, {\n      content: 'Item 7'\n    }, {\n      content: 'Item 8'\n    }];\n    var containers = $element.children().children();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2]\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="Basic">\n    <div class='tableRow'>\n        <div class='containerVertical'>\n            <div ng-repeat="item in items1">{{item.content}}</div>\n        </div>\n        <div class='containerVertical'>\n            <div ng-repeat="item in items2">{{item.content}}</div>\n        </div>\n    </div>\n    <div class="tableRow">\n        <div class="container">\n            <div>Items1:\n                <br/>{{items1 | json}}</div>\n        </div>\n        <div class="container">\n            <div>Items2:\n                <br/>{{items2 | json}}</div>\n        </div>\n    </div>\n</div>\n        \n      
\n
\n"),e.put("exampleBoundingBox/exampleBoundingBox.html","
\n

BoundingBox

\n \n
\n
\n
This items cannot cross its example element, just try it your selves.
\n
Item 2.
\n
Item 3.
\n
Item 6.
\n
\n
\n
This items cannot cross its example element, just try it your selves.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n  dragularService([$element.children(), {\n    boundingBox: $element\n  });\n        \n      
\n
"),e.put("exampleBoundingBoxLockX/exampleBoundingBoxLockX.html","
\n

BoundingBox and lockX

\n \n
\n
\n
\n
Items are locked in X axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
\n
item 2
\n
item 3
\n
item 4
\n
\n
\n
\n
\n        \n  dragularService([$element.children()[0].children(), {\n    boundingBox: $element.children()[0],\n    lockX: true\n  });\n        \n      
\n
"),e.put("exampleBoundingBoxLockY/exampleBoundingBoxLockY.html","
\n

BoundingBox and LockY

\n \n
\n
\n
\n
Items are locked in Y axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
\n
item 2
\n
item 3
\n
item 4
\n
item 5
\n
item 6
\n
\n
\n
\n
\n        \n  dragularService([$element.children()[0].children(), {\n    boundingBox: $element.children()[0],\n    lockY: true\n  });\n        \n      
\n
"),e.put("exampleCopy/exampleCopy.html","
\n

Copy

\n \n
\n
\n
Move me, and make copy on drop.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
\n
\n
\n        \n// JS\n  controller('Copy', ['$element', 'dragularService', function TodoCtrl($element, dragularService) {\n    dragularService($element.children(), {\n      copy: true\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="Copy" ng-hide="globals.showModelExamples">\n    <div id='left2' class='containerVertical'>\n      <div>Move me, and make copy on drop.</div>\n      <div>If you try to drop me somewhere other than these containers, I'll just come back.</div>\n    </div>\n    <div id='right2' class='containerVertical'>\n      <div>You can drop me in the left container, otherwise I'll stay here.</div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleCopyWithModel/exampleCopyWithModel.html","
\n

Copy - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n
{{items1 | json}}
\n
\n
\n
Items2:\n
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  controller('CopyModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: 'Move me, and make copy on drop.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.items2 = [{\n      content: 'Item 5'\n    }, {\n      content: 'Item 6'\n    }, {\n      content: 'Item 7'\n    }, {\n      content: 'Item 8'\n    }];\n    var containers = $element.children().children();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2],\n      copy: true\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="CopyModel" ng-show="globals.showModelExamples">\n    <div class='tableRow'>\n      <div class='containerVertical'>\n        <div ng-repeat="item in items1">{{item.content}}</div>\n      </div>\n      <div class='containerVertical'>\n        <div ng-repeat="item in items2">{{item.content}}</div>\n      </div>\n    </div>\n    <div class="tableRow">\n      <div class="container">\n        <div>Items1:\n          <br/>{{items1 | json}}</div>\n      </div>\n      <div class="container">\n        <div>Items2:\n          <br/>{{items2 | json}}</div>\n      </div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleCustomClasses/exampleCustomClasses.html","
\n

Custom classes

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n  dragularService([document.getElementById(left), document.getElementById(right)], { classes: {\n    mirror: 'custom-green-mirror'\n  } });\n\n  // Default classes are:\n  option.classes = {\n    mirror: 'gu-mirror',\n    hide: 'gu-hide',\n    unselectable: 'gu-unselectable',\n    transit: 'gu-transit',\n    overActive: 'gu-over-active',\n    overAccepts: 'gu-over-accept',\n    overDeclines: 'gu-over-decline'\n  };\n        \n      
\n
\n"),e.put("exampleDifferentOptionsWithModel/exampleDifferentOptionsWithModel.html","
\n

Different options - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  .controller('DifferentOptionsModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: 'Move me, but you can only drop me in one of these containers.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.items2 = [{\n      content: 'Item 5'\n    }, {\n      content: 'Item 6'\n    }, {\n      content: 'Item 7'\n    }, {\n      content: 'Item 8'\n    }];\n\n    var containerLeft = document.querySelector('#containerLeft'),\n      containerRight = document.querySelector('#containerRight');\n\n    function accepts(el, target, source) {\n      if (source === containerLeft || source === target) {\n        return true;\n      }\n    }\n\n    dragularService([containerLeft], {\n      containersModel: [$scope.items1],\n      copy: true,\n      //move only from left to right  \n      accepts: accepts\n    });\n\n    dragularService([containerRight], {\n      containersModel: [$scope.items2],\n      removeOnSpill: true,\n      //move only from left to right  \n      accepts: accepts\n    });\n\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="DifferentOptionsModel">\n    <div class='tableRow'>\n      <div id="containerLeft" class='containerVertical'>\n        <div ng-repeat="item in items1">{{item.content}}</div>\n      </div>\n      <div id="containerRight" class='containerVertical'>\n        <div ng-repeat="item in items2">{{item.content}}</div>\n      </div>\n    </div>\n    <div class="tableRow">\n      <div class='containerVertical'>\n        <pre>Items1:\n          <br/>{{items1 | json}}</pre>\n      </div>\n      <div class='containerVertical'>\n        <pre>Items2:\n          <br/>{{items2 | json}}</pre>\n      </div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleDirective/exampleDirective.html","
\n

Directive

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n// JS\n  controller('Directive', ['$scope', 'dragularService', function TodoCtrl($scope) {\n    $scope.dragularOptions = {\n      classes: {\n        mirror: 'custom-green-mirror'\n      },\n      nameSpace: 'common' // just connecting left and right container\n    };\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="Directive">\n    <div class='containerVertical' dragular="dragularOptions">\n      <div>Move me, but you can only drop me in one of these containers.</div>\n      <div>If you try to drop me somewhere other than these containers, I'll just come back.</div>\n      <div>Item 3.</div>\n      <div>Item 6.</div>\n    </div>\n    <div class='containerVertical' dragular='{"classes":{"mirror":"custom-green-mirror"},"nameSpace":"same"}'>\n      <div>You can drop me in the left container, otherwise I'll stay here.</div>\n      <div>Item 4.</div>\n      <div>Item 5.</div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleDirectiveWithModel/exampleDirectiveWithModel.html","
\n

Directive - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n
{{items1 | json}}
\n
\n
\n
Items2:\n
{{items2 | json}}
\n
\n
\n
\n
\n       \n        \n// JS\n  controller('DirectiveModel', ['$scope', function TodoCtrl($scope) {\n    $scope.items1 = [{\n      content: 'Move me, and make copy on drop.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.items2 = [{\n      content: 'Item 5'\n    }, {\n      content: 'Item 6'\n    }, {\n      content: 'Item 7'\n    }, {\n      content: 'Item 8'\n    }];\n    $scope.dragularOptions = {\n      containersModel: $scope.items1,\n      classes: {\n        mirror: 'custom-green-mirror'\n      },\n      nameSpace: 'common' // just connecting left and right container\n    };\n  }])\n        \n        \n<!-- HTML -->\n <div class='wrapper' ng-controller="DirectiveModel">\n  <div class='containerVertical' dragular="dragularOptions">\n    <div ng-repeat="item in items1">{{item.content}}</div>\n  </div>\n  <div class='containerVertical' dragular='{"containersModel":"items2","classes":{"mirror":"custom-green-mirror"},"nameSpace":"common"}'>\n    <div ng-repeat="item in items2">{{item.content}}</div>\n  </div>\n</div>\n        \n      
\n
\n"),e.put("exampleDragOverEvents/exampleDragOverEvents.html","
\n

Drag-over events

\n

You can interact with dragging element by litening to dragOver events. Usually you want to containers show wheather they accepts element or not, but you can use it anywhere. DragOver events are: dragenter, dragleave and dragrelease. On dragOver events dragularService reveals several useful properties.

\n\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
dragularService.shared.itemitem beeing dragged (it is copy of item if copy is enabled via options)
dragularService.shared.sourcesource container item is dragged from
dragularService.shared.sourceModelsource container model representation if model was porvided
dragularService.shared.initialIndexoriginal index of item, can be used to get item model from sourceModel
dragularService.shared.extracontains accepting information (boolean) on dragenter, element drag is leaving to on dragleave and element behind the cursor on dragrelease
\n
\n\n

Try to drag over the not-container too.

\n
\n
\n
apples and oranges cannot be mixed
\n
apple 2
\n
apple 3
\n
apple 4
\n
\n
\n
orange 1
\n
orange 2
\n
orange 3
\n
orange 4
\n
\n
\n
apple 5
\n
apple 6
\n
apple 7
\n
apple 8
\n
\n
\n
orange 5
\n
orange 6
\n
orange 7
\n
orange 8
\n
\n
\n
Test active class on NOT container.
\n\n
\n    \n<!-- HTML -->\n  <div class='wrapper' ng-controller="DragOverEvents">\n    <div class='container width25'>\n      <div>apples and oranges cannot be mixed</div>\n      <div>apple 2</div>\n      ...\n    </div>\n    <div class='container width25'>\n      <div>orange 1</div>\n      <div>orange 2</div>\n      ...\n    </div>\n    <div class='container width25'>\n      <div>apple 5</div>\n      <div>apple 6</div>\n      ...\n    </div>\n    <div class='container width25'>\n      <div>orange 5</div>\n      <div>orange 6</div>\n      ...\n    </div>\n  </div>\n  <div class="notContainer"> Test active class on NOT container.</div>\n    \n  
\n\n
\n    \n  // CSS\n  \n.notContainer.gu-over {\n  background-color: yellow;\n}\n\n.containerVertical.gu-over-accept {\n  background-color: green;\n}\n\n.containerVertical.gu-over-decline {\n  background-color: red;\n}\n    \n  
\n\n
\n    \n  // JS\n  controller('DragOverEvents', ['$element', 'dragularService', function TodoCtrl($element, dragularService) {\n    dragularService.cleanEnviroment();\n    dragularService([$element.children()[0], $element.children()[2]], {\n      nameSpace: 'apples'\n    });\n    dragularService([$element.children()[1], $element.children()[3]], {\n      nameSpace: 'oranges'\n    });\n\n    // containers events handling\n    function registerEvents(el) {\n      el.on('dragularenter', function(e) {\n        if (el[0] === e.target) { // filter bubbled\n          el.addClass(dragularService.shared.extra ? 'gu-over-accept' : 'gu-over-decline');\n        }\n      });\n      el.on('dragularleave dragularrelease', function(e) {\n        if ((el[0] === e.target && // filter bubbled\n          dragularService.shared.extra && // extra on dragleave contains element the drag is leaving to\n          dragularService.shared.extra.parentElement !== e.target) // is that element child of this container?\n          || e.type === 'dragularrelease') {\n          el.removeClass('gu-over-accept');\n          el.removeClass('gu-over-decline');\n        }\n      });\n    }\n\n    angular.forEach($element.children(), function forEachChild(el) {\n      registerEvents(angular.element(el));\n    });\n\n    // notContainer events handling\n    var notContainer = angular.element(document.getElementsByClassName('notContainer'));\n    notContainer.on('dragularenter', function() {\n      notContainer.addClass('gu-over');\n    });\n    notContainer.on('dragularleave dragularrelease', function() {\n      notContainer.removeClass('gu-over');\n    });\n  }])\n    \n  
\n
\n"),e.put("exampleEvents/exampleEvents.html","
\n

Events

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n.controller('Events', ['$scope', '$element', 'dragularService', '$timeout', function TodoCtrl($scope, $element, dragularService, $timeout) {\n    dragularService($element.children(), {\n      scope: $scope\n    });\n    $scope.$on('dragulardrag', function(e, el) {\n      e.stopPropagation();\n      el.className = el.className.replace(' ex-moved', '');\n    });\n    $scope.$on('dragulardrop', function(e, el) {\n      e.stopPropagation();\n      $timeout(function() {\n        el.className += ' ex-moved';\n      }, 0);\n    });\n\n    $scope.$on('dragularcloned', myFn('cloned'));\n    $scope.$on('dragulardrag', myFn('drag'));\n    $scope.$on('dragularcancel', myFn('cancel'));\n    $scope.$on('dragulardrop', myFn('drop'));\n    $scope.$on('dragularremove', myFn('remove'));\n    $scope.$on('dragulardragend', myFn('dragend'));\n    $scope.$on('dragularshadow', myFn('shadow'));\n\n    function myFn(eventName) {\n      return function() {\n        console.log(eventName, arguments);\n      };\n    }\n\n  }]);\n        \n      
\n
\n"),e.put("exampleHandle/exampleHandle.html","
\n

Handle

\n \n
\n
\n
+Move me, but you can use the plus sign to drag me around.
\n
\n
\n
\n
\n
\n        \n  dragularService([document.getElementById(left), document.getElementById(right)], {\n    moves: function (el, container, handle) {\n      return handle.className === 'handle';\n    }\n  });\n        \n      
\n
\n"),e.put("exampleIsContainerWithModel/exampleIsContainerWithModel.html","
\n

isContainer - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}\n
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Cart:\n          
{{cartModel | json}}
\n
\n
\n
\n
\n        \n// JS\n  .controller('IsContainerModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: 'Move me, but you can only drop me in one of these containers.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.cartModel = [];\n\n    var containerLeft = document.querySelector('#containerLeft');\n\n    dragularService.cleanEnviroment();\n    dragularService([containerLeft], {\n      containersModel: [$scope.items1],\n      copy: true,\n      isContainer: function isContainer (el) {\n        return el.id === 'cart';\n      },\n      isContainerModel: function getModel (){\n        return $scope.cartModel;\n      }\n    });\n\n    $scope.removeItem = function removeItem() {\n      var index = $scope.cartModel.indexOf(this.item);\n      $scope.cartModel.splice(index, 1);\n    };\n\n  }])\n        \n        \n<!-- HTML -->\n <div class='wrapper' ng-controller="IsContainerModel">\n    <div class='tableRow'>\n      <div id="containerLeft" class='containerVertical'>\n        <div ng-repeat="item in items1">{{item.content}}</div>\n      </div>\n      <div id="cart" class='containerVertical'>\n        <div class='cursorDefault' ng-repeat="item in cartModel">{{item.content}}\n        <button class='cursorDefault' ng-click="removeItem()">x</button></div>\n      </div>\n    </div>\n    <div class="tableRow">\n      <div class='containerVertical'>\n        <pre>Items1:\n          <br/>{{items1 | json}}</pre>\n      </div>\n      <div class='containerVertical'>\n        <pre>Cart:\n          <br/>{{cartModel | json}}</pre>\n      </div>\n    </div>\n  </div>\n        \n      
\n
\n"), +e.put("exampleNameSpaces/exampleNameSpaces.html","
\n

NameSpaces

\n \n
\n
\n
try to mix oranges and apples
\n
apple 2
\n
apple 3
\n
apple 4
\n
\n
\n
orange 1
\n
orange 2
\n
orange 3
\n
orange 4
\n
\n
\n
apple 5
\n
apple 6
\n
apple 7
\n
apple 8
\n
\n
\n
mixed 1
\n
mixed 2
\n
mixed 3
\n
mixed 4
\n
\n
\n
\n      \ndragularService([$element.children()[0], $element.children()[2]], {\n  nameSpace: 'apples'\n});\ndragularService($element.children()[1], {\n  nameSpace: 'oranges'\n});\ndragularService($element.children()[3], { // mixed\n  nameSpace: ['oranges', 'apples']\n});\n      \n    
\n
"),e.put("exampleNestedNgRepeat/exampleNestedNgRepeat.html","
\n

Nested ngRepeat

\n \n
\n
\n
Row {{$index}}
\n
{{item.content}}
\n
\n
\n
\n        \n  // HTML\n\n  <div ng-controller="Example15">\n    <div ng-repeat="item in items" class='exampleRow'>\n      <div class="row-handle">Row {{$index}}</div>\n      <div ng-repeat="item in item.items" class="exampleCell">{{item.content}}</div>\n    </div>\n  </div>\n        \n      
\n
\n        \n  // CSS\n\n  .exampleRow {\n    display: flex;\n    flex-direction: row;\n  }\n\n  .exampleCell {\n    flex-grow: 1;\n  }\n\n  .exampleRow,\n  .exampleCell {\n    margin: 10px;\n    padding: 10px;\n    background-color: rgba(0, 0, 0, 0.2);\n    cursor: move;\n    cursor: grab;\n    cursor: -moz-grab;\n    cursor: -webkit-grab;\n  }\n        \n      
\n
\n        \n  // JS\n\n  .controller('NestedNgRepeat', ['$timeout', '$scope', '$element', 'dragularService', function NestedNgRepeatCtrl($timeout, $scope, $element, dragularService) {\n    $timeout(function() { // timeount due to ngRepeat to be ready\n      dragularService($element, {\n        nameSpace: 'rows',\n        moves: function rowOnly (el, container, handle) {\n          return handle.classList.contains('row-handle');\n        }\n      });\n      dragularService($element.children(), {\n        nameSpace: 'cells',\n        moves: function excludeHandle (el, container, handle) {\n          return !handle.classList.contains('row-handle');\n        }\n      });\n    }, 0);\n    $scope.items = [{\n      items: [{\n        content: 'Item a1'\n      }, {\n        content: 'Item a2'\n      }, {\n        content: 'Item a3'\n      }, {\n        content: 'Item a4'\n      }]\n    }, {\n      items: [{\n        content: 'Item b1'\n      }, {\n        content: 'Item b2'\n      }, {\n        content: 'Item b3'\n      }, {\n        content: 'Item b4'\n      }]\n    }, {\n      items: [{\n        content: 'Item c1'\n      }, {\n        content: 'Item c2'\n      }, {\n        content: 'Item c3'\n      }, {\n        content: 'Item c4'\n      }]\n    }];\n  }])\n        \n      
\n
\n"),e.put("exampleNestedNgRepeatWithModel/exampleNestedNgRepeatWithModel.html","
\n

Nested ngRepeat - with model

\n \n
\n
\n
\n
\n
Row {{::$index}}
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
\n
\n
\n            
Items:\n
{{items | json}}
\n
\n
\n
\n
\n
\n    \n<!-- HTML -->\n<div ng-controller="NestedNgRepeatWithModel">\n  <div class='containerVertical'>\n    <div ng-repeat="item in items" class='exampleRow'>\n      <div class="row-handle">Row {{::$index}}</div>\n      <div class="exampleRow exampleCell containerNested">\n        <div ng-repeat="item in item.items" class="exampleCell">{{item.content}}</div>\n      </div>\n    </div>\n  </div>\n</div>\n    \n  
\n
\n    \n  // CSS\n\n  .exampleRow {\n    display: flex;\n    flex-direction: row;\n  }\n\n  .exampleCell {\n    flex-grow: 1;\n  }\n\n  .exampleRow,\n  .exampleCell {\n    margin: 10px;\n    padding: 10px;\n    background-color: rgba(0, 0, 0, 0.2);\n    cursor: move;\n    cursor: grab;\n    cursor: -moz-grab;\n    cursor: -webkit-grab;\n  }\n    \n  
\n
\n    \n  // JS\n.controller('NestedNgRepeatWithModel', ['$timeout', '$scope', '$element', 'dragularService', function NestedNgRepeatWithModelCtrl($timeout, $scope, $element, dragularService) {\n    $timeout(function() { // timeount due to nested ngRepeat to be ready\n      var container = $element.children().eq(0).children(),\n        parentContainers = container.children(),\n        nestedContainers = [];\n\n      dragularService(container, {\n        moves: function(el, container, handle) {\n          return handle.classList.contains('row-handle');\n        },\n        containersModel: $scope.items,\n        nameSpace: 'rows'\n      });\n\n      // collect nested contianers\n      for (var i = 0; i < parentContainers.length; i++) {\n        nestedContainers.push(parentContainers.eq(i).children()[1]);\n      }\n\n      dragularService(nestedContainers, {\n        moves: function(el, container, handle) {\n          return !handle.classList.contains('row-handle');\n        },\n        containersModel: (function getNestedContainersModel(){\n          var parent = $scope.items,\n            containersModel = [];\n          for (var i = 0; i < parent.length; i++) {\n            containersModel.push(parent[i].items);\n          }\n          return containersModel;\n        })(),\n        nameSpace: 'cells'\n      });\n    }, 0);\n    $scope.items = [{\n      items: [{\n        content: 'Item a1'\n      }, {\n        content: 'Item a2'\n      }, {\n        content: 'Item a3'\n      }, {\n        content: 'Item a4'\n      }]\n    }, {\n      items: [{\n        content: 'Item b1'\n      }, {\n        content: 'Item b2'\n      }, {\n        content: 'Item b3'\n      }, {\n        content: 'Item b4'\n      }]\n    }, {\n      items: [{\n        content: 'Item c1'\n      }, {\n        content: 'Item c2'\n      }, {\n        content: 'Item c3'\n      }, {\n        content: 'Item c4'\n      }]\n    }];\n  }])\n    \n  
\n
\n"),e.put("exampleNgRepeat/exampleNgRepeat.html","
\n

ngRepeat

\n \n
\n
\n
\n {{item.content}}\n
\n
\n
\n
\n        \n  // HTML:\n  <div class='containerVertical'>\n    <div ng-repeat="item in items">\n      {{item.content}}\n    </div>\n  </div>\n\n  // JS:\n  dragularService($element.children());\n  $scope.items = [{\n    content: 'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.'\n  },{\n    content: 'Item 2'\n  },{\n    content: 'Item 3'\n  },{\n    content: 'Item 4'\n  }];\n        \n      
\n
\n"),e.put("exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel.html","
\n

Filtered ngRepeat - with model

\n \n
\n
\n
\n \n
\n
\n \n
\n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  .controller('NgRepeatFilteredWithModel', ['$scope', '$element', 'dragularService', '$filter', function TodoCtrl($scope, $element, dragularService, $filter) {\n    $scope.items1 = [{\n      content: 'Move me, but you can only drop me in one of these containers.'\n    }, {\n      content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n    }, {\n      content: 'Apple 3'\n    }, {\n      content: 'Orange 4'\n    }, {\n      content: 'Orange 5'\n    }, {\n      content: 'Apple 6'\n    }, {\n      content: 'Apple 7'\n    }, {\n      content: 'Apple 8'\n    }];\n    $scope.items2 = [{\n      content: 'Apple 9'\n    }, {\n      content: 'Orange 10'\n    }, {\n      content: 'Orange 11'\n    }, {\n      content: 'Apple 12'\n    }, {\n      content: 'Orange 13'\n    }, {\n      content: 'Apple 14'\n    }];\n    $scope.filter1query = 'Orange';\n    $scope.filter2query = 'Orange';\n    $scope.filteredModel1 = [];\n    $scope.filteredModel2 = [];\n    $scope.getFilteredModel = function (filteredModel, items, filterQuery) {\n      filteredModel.length = 0;\n      /*\n      * Following one-liner is same like:\n      *   var filteredModelTemp = $filter('filter')(items, filterQuery);\n      *   angular.forEach(filteredModelTemp, function(item){\n      *     filteredModel.push(item);\n      *   });\n      * Or like:\n      *   var filteredModelTemp = $filter('filter')(items, filterQuery);\n      *   for(var i; i < filteredModelTemp.length; i++){\n      *     filteredModel.push(filteredModelTemp[i]);\n      *   }\n      *\n      * You cannot just assign filtered array to filteredModel like this:\n      *   filteredModel = $filter('filter')(items, filterQuery);\n      * Because you would replace the array object you provide to dragular with new one.\n      * So dragular will continue to use the one it was provided on init.\n      * Hopefully I make it clear. :)\n       */\n      [].push.apply(filteredModel, $filter('filter')(items, filterQuery));\n      return filteredModel;\n    };\n    var containers = $element.children().eq(1).children();\n    dragularService.cleanEnviroment();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2],\n      containersFilteredModel: [$scope.filteredModel1, $scope.filteredModel2]\n    });\n  }]);\n\n        \n        \n<!-- HTML -->\n  <div class='wrapper' ng-controller="NgRepeatFilteredWithModel">\n    <div class="tableRow">\n      <div class='containerVertical'>\n        <input ng-model="filter1query" style="margin:10px 10px">\n      </div>\n      <div class='containerVertical'>\n        <input ng-model="filter2query" style="margin:10px 10px">\n      </div>\n    </div>\n    <div class='tableRow'>\n      <div class='containerVertical'>\n        <div ng-repeat="item in getFilteredModel(filteredModel1, items1, filter1query)">{{item.content}}</div>\n      </div>\n      <div class='containerVertical'>\n        <div ng-repeat="item in getFilteredModel(filteredModel2, items2, filter2query)">{{item.content}}</div>\n      </div>\n    </div>\n    <div class="tableRow">\n      <div class='containerVertical'>\n        <pre>Items1:\n          <br/>{{items1 | json}}</pre>\n      </div>\n      <div class='containerVertical'>\n        <pre>Items2:\n          <br/>{{items2 | json}}</pre>\n      </div>\n    </div>\n  </div>\n        \n      
\n
\n"),e.put("exampleNgRepeatWithModel/exampleNgRepeatWithModel.html","
\n

ngRepeat - with model

\n \n
\n
\n
\n
\n {{item.content}}\n \n \n
\n
\n
\n
\n
\n
Items:\n
{{items | json}}
\n
\n
\n
\n
\n    \n  // HTML:\n   <div class='wrapper' ng-controller="NgRepeatWithModel">\n      <div class='containerVertical'>\n        <div ng-repeat="item in items">\n          {{item.content}}\n          <button class='cursorDefault' ng-click="addItem()">+</button>\n          <button class='cursorDefault' ng-click="removeItem()">x</button>\n        </div>\n    </div>\n  </div>\n    \n  
\n
\n    \n  // JS:\n  controller('NgRepeatWithModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items = [{\n      content: 'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.'\n    }, {\n      content: 'Item 2'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    dragularService($element.children().eq(0).children(), {containersModel: $scope.items});\n    $scope.addItem = function addItem() {\n      var index = $scope.items.indexOf(this.item) + 1;\n      $scope.items.splice(index, 0, {\n        content: this.item.content + '-copy'\n      });\n    };\n    $scope.removeItem = function removeItem() {\n      var index = $scope.items.indexOf(this.item);\n      $scope.items.splice(index, 1);\n    };\n  }])\n    \n  
\n
\n"),e.put("exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel.html","
\n

Remove on spill - with model

\n \n
\n
\n
\n
{{item.content}}
\n
\n
\n
{{item.content}}
\n
\n
\n
\n
\n
Items1:\n          
{{items1 | json}}
\n
\n
\n
Items2:\n          
{{items2 | json}}
\n
\n
\n
\n
\n        \n// JS\n  .controller('RemoveOnSpillWithModel', ['$scope', '$element', 'dragularService', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: 'Move me, but you can only drop me in containers.'\n    }, {\n      content: 'If you try to drop me somewhere other than containers, I\\'ll die a fiery death.'\n    }, {\n      content: 'Item 3'\n    }, {\n      content: 'Item 4'\n    }];\n    $scope.items2 = [{\n      content: 'You can drop me in the left container.'\n    }, {\n      content: 'Item 6'\n    }, {\n      content: 'Item 7'\n    }, {\n      content: 'Item 8'\n    }];\n    var containers = $element.children().eq(0).children();\n    dragularService.cleanEnviroment();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2],\n      removeOnSpill: true\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class='wrapper' ng-controller="Basic">\n    <div class='tableRow'>\n        <div class='containerVertical'>\n            <div ng-repeat="item in items1">{{item.content}}</div>\n        </div>\n        <div class='containerVertical'>\n            <div ng-repeat="item in items2">{{item.content}}</div>\n        </div>\n    </div>\n    <div class="tableRow">\n        <div class="container">\n            <div>Items1:\n                <br/>{{items1 | json}}</div>\n        </div>\n        <div class="container">\n            <div>Items2:\n                <br/>{{items2 | json}}</div>\n        </div>\n    </div>\n</div>\n        \n      
\n
\n"),e.put("exampleRemoveOnSpill/exampleRemoveOnSpill.html","
\n

Remove on spill

\n \n
\n
\n
Move me, but you can only drop me in containers.
\n
If you try to drop me somewhere other than containers, I'll die a fiery death.
\n
Item 3.
\n
Item 6.
\n
Item 4.
\n
Item 5.
\n
\n \n
\n
\n        \n  dragularService([document.getElementById(single)], { removeOnSpill: true });\n        \n      
\n
"),e.put("exampleRevertOnSpill/exampleRevertOnSpill.html","
\n

Revert on spill

\n \n
\n
\n
Move me, but you can only drop me in one of these containers.
\n
If you try to drop me somewhere other than these containers, I'll just come back.
\n
Item 3.
\n
Item 6.
\n
\n
\n
You can drop me in the left container, otherwise I'll stay here.
\n
Item 4.
\n
Item 5.
\n
\n
\n
\n        \n  dragularService([document.getElementById(left), document.getElementById(right)], { revertOnSpill: true });\n        \n      
\n
"),e.put("exampleScrollingDrag/exampleScrollingDrag.html",'
\n

Scrolling drag

\n \n
\n
\n
up
\n
\n
Item 1.
\n
Item 2.
\n
Item 3.
\n
Item 4.
\n
Item 5.
\n
Item 6.
\n
Item 7.
\n
Item 9.
\n
Item 10.
\n
Item 11.
\n
Item 12.
\n
Item 13.
\n
\n
down
\n
\n
\n
\n
\n
Item 1.
\n
Item 2.
\n
Item 3.
\n
Item 4.
\n
Item 5.
\n
Item 6.
\n
Item 7.
\n
Item 9.
\n
Item 10.
\n
Item 11.
\n
Item 12.
\n
Item 13.
\n
\n
\n
\n
\n
\n        \n// JS\ncontroller(\'ScrollingDrag\', [\'$interval\', \'$element\', \'dragularService\', function TodoCtrl($interval, $element, dragularService) {\n\n\n    var timer,\n      leftScrollContainer = document.getElementById(\'leftScroll\'),\n      rightScrollContainer = document.getElementById(\'rightScroll\'),\n      leftTopBar = document.getElementById(\'leftTopBar\'),\n      leftBottomBar = document.getElementById(\'leftBottomBar\'),\n      rightTopBar = document.getElementById(\'rightTopBar\'),\n      rightBottomBar = document.getElementById(\'rightBottomBar\');\n\n    dragularService.cleanEnviroment();\n    dragularService([leftScrollContainer, rightScrollContainer]);\n\n    registerEvents(leftTopBar, leftScrollContainer, -5);\n    registerEvents(leftBottomBar, leftScrollContainer, 5);\n    registerEvents(rightTopBar, rightScrollContainer, -5);\n    registerEvents(rightBottomBar, rightScrollContainer, 5);\n\n    function registerEvents(bar, container, inc, speed) {\n      if (!speed) {\n        speed = 20;\n      }\n      angular.element(bar).on(\'dragularenter\', function() {\n        container.scrollTop += inc;\n        timer = $interval(function moveScroll() {\n          container.scrollTop += inc;\n        }, speed);\n      });\n      angular.element(bar).on(\'dragularleave dragularrelease\', function() {\n        $interval.cancel(timer);\n      });\n    }\n  }])\n        \n      
\n
\n        \n<!-- HTML -->\n<div ng-controller="ScrollingDrag">\n    <div class="containerVertical scrollingDrag">\n      <div class="scrollBar" id="leftTopBar">up</div>\n      <div id="leftScroll" class="scrollingDragInner">\n        <div>Item 1</div>\n        <div>Item 2</div>\n            ...\n      </div>\n      <div class="scrollBar" id="leftBottomBar">down</div>\n    </div>\n    <div class="containerVertical scrollingDrag">\n      <div class="scrollBar" id="rightTopBar">up</div>\n      <div id="rightScroll" class="scrollingDragInner">\n        <div>Item 1</div>\n        <div>Item 2</div>\n            ...\n      </div>\n      <div class="scrollBar" id="rightBottomBar">down</div>\n    </div>\n  </div>\n        \n      
\n
\n        \n// CSS\n.scrollingDrag {\n  width: 45%;\n  display: inline-block;\n}\n\n.scrollingDragInner {\n  max-height: 200px;\n  overflow-y: auto;\n}\n\n#rightTopBar,\n#rightBottomBar {\n  background: transparent;\n  position: relative;\n  height: 20px;\n}\n\n#rightTopBar {\n  top: 10px;\n}\n\n#rightBottomBar {\n  bottom: 10px;\n}\n\ndiv.scrollBar {\n  background: yellow;\n  text-align: center;\n  padding: 1px;\n}\n\n        \n      
\n
\n'),e.put("partials/partial-contribute.html",'
\n
\n
\n \n
\n
\n
\n'),e.put("partials/partial-docs.html",'
\n
\n \n \n
\n

\n \n

\n \n
\n
\n \n
\n \n
\n'),e.put("partials/partial-home.html",'
\n
\n \n
\n
\n

DRAGULAR

\n

Angular drag&drop based on dragula.

\n

Live examples in docs

\n
\n
\n
\n

Browser support includes every sane browser and **IE7+**. _(Granted you polyfill the functional `Array` methods in ES5)_

\n

Inspiration

\n

I am working on huge angular project and I am using several drag&drop libraries in it, one for UI, one for lists, etc.. I want to use one full-featured drag&drop library for whole project. As I could not find any suitable, I decided to create one. I have choosen great library dragula by Nicolas Bevacqua as my starting point, make it more angular and started to put features in it! If you wish light-weight angular version of dragula, there is official angular version of dragula.

\n

Actual version 4.2.0 is based on dragula 3.6.3 and tested with angular 1.5.5.

\n

Differences of dragular (against dragula)

\n
    \n
  • replaced dragula crossvent with angulars event binding
  • \n
  • replaced dragula contra.emitter with $scope.$emit if scope provided in options (options.scope)
  • \n
  • provided as service or directive dragular where options can be passed via atribute dragular
  • \n
  • automatic direction if not provided in options, instead of default vertical
  • \n
  • accepting arraylike objects as containers array (jQuery, jQlite collections etc..)
  • \n
  • accepting custom classes via option.classes
  • \n
  • namespaced containers groups available via option.nameSpace (containers in same nameSpace cooperate)
  • \n
  • boundingBox (dragging element can me moved only in specific area)
  • \n
  • lockX/Y (dragging element can me moved only in specific direction)
  • \n
  • DOM can be synced with scope model
  • \n
  • support css selectors to define containers
  • \n
  • added syntax highlighter to example codes
  • \n
  • etc..
  • \n
\n

Todo

\n
    \n
  • improve docs
  • \n
\n

Features

\n
    \n
  • provided as service and also as directive
  • \n
  • Super easy to set up
  • \n
  • No bloated dependencies
  • \n
  • Figures out sort order on its own
  • \n
  • A shadow where the item would be dropped offers visual feedback
  • \n
  • Touch events!
  • \n
\n

For installation, usage and examples go to docs

\n
\n
\n \n
\n \n
\n \n
\n'),e.put("partials/autogenerated/contribute.html",'

How to contribute

\n

It's important to us that you feel you can contribute towards the evolution of Dragular. This can take many forms: from helping to fix bugs or improve the docs, to adding in new features to the source. This guide should help you in making that process as smooth as possible.

\n

Before contributing, please read the code of conduct.

\n

Reporting issues

\n

GitHub Issues is the place to report bugs you may have found in either the core library or any of the examples that are part of the repository. When submitting a bug please do the following:

\n

1. Search for existing issues. Your bug may have already been fixed or addressed in a development branch version of Dragular, so be sure to search the issues first before putting in a duplicate issue.

\n

2. Not sure if it's a bug?. Then please ask via issues and tag it [question].

\n

3. Create an isolated and reproducible test case. If you are reporting a bug, make sure you also have a minimal, runnable, code example that reproduces the problem you have.

\n

4. Include a live example. After narrowing your code down to only the problem areas, make use of jsFiddle, jsBin, or a link to your live site so that we can view a live example of the problem. (you can start by forking this fiddle)

\n

5. Share as much information as possible. Include browser version affected, your OS, version of the library, steps to reproduce, etc. "X isn't working!!!1!" will probably just be closed.

\n

Dev vs. Master

\n

The dev branch of Dragular is our 'current working' version. It is always ahead of the master branch in terms of features and fixes. However it's also bleeding-edge and experimental and we cannot and do not guarantee it will compile or work for you. Very often we have to break things for a few days while we rebuild and patch. So by all means please export the dev branch and contribute towards it, indeed that is where all Pull Requests should be sent, but do so understanding the API may change beneath you.

\n

Making Changes

\n

To take advantage of our npm build script and jshint config it will be easiest for you if you have node.js installed locally.

\n

You can download node.js from nodejs.org.

\n

After that you can clone the repository and run npm i inside the cloned folder. This will install dependencies necessary for building the project. For development workflow automation dragular uses gulp >= 3.9.0. Before starting development, make sure that gulp is installed on your machine globally: npm i -g gulp.

\n

Developing

\n

There are several gulp tasks that are used for generating different builds:

\n
    \n
  • gulp dev - Serves files with BrowserSync server, watches & automatically refreshes connected browsers on changes, generates non-minified but concatenated styles & scripts from the dragular source.
  • \n
  • gulp dev:docs - Does exactly the same as gulp dev, except it works with the documentation source.
  • \n
  • gulp build - Concatenates and minifies dragular source files.
  • \n
  • gulp build:docs - Concatenates and minifies documentation source files.
  • \n
\n

Linting

\n
    \n
  • gulp lint & gulp lint:docs - Lint JavaScript files.
  • \n
\n

Making a pull request

\n

Once that is ready, make your changes and submit a Pull Request:

\n
    \n
  • Send Pull Requests to the dev branch. All Pull Requests must be sent to the dev branch, master is the latest release and PRs to that branch will be closed.

    \n
  • \n
  • Ensure changes are jshint validated. Our JSHint configuration file is provided in the repository and you should check against it before submitting.

    \n
  • \n
  • Only commit relevant changes. Don't include changes that are not directly relevant to the fix you are making. The more focused a PR is, the faster it will get attention and be merged. Extra files changing only whitespace or trash files will likely get your PR closed.

    \n
  • \n
\n

Dependencies for building from source and running tests:

\n

Coding style preferences are not contributions

\n

If your PR is doing little more than changing the Dragular source code into a format / coding style that you prefer then we will automatically close it. All PRs must adhere to the coding style already set-out across the lines of code in Dragular. Your personal preferences for how things should "look" or be structured do not apply here, sorry. PRs should fix bugs, fix documentation or add features. No changes for the sake of change.

\n

I don't really like git / node.js, but I can fix this bug

\n

That is fine too. While Pull Requests are the best thing in the world for us, they are not the only way to help. You're welcome to post fixes to our forum or even just email them to us. All we ask is that you still adhere to the guidelines presented here re: JSHint, etc.

\n'); +}])}])}); //# sourceMappingURL=examples.min.js.map diff --git a/docs/dist/examples.min.js.map b/docs/dist/examples.min.js.map index 74790442..e093e41e 100644 --- a/docs/dist/examples.min.js.map +++ b/docs/dist/examples.min.js.map @@ -1 +1 @@ -{"version":3,"sources":["examples.js"],"names":["modules","__webpack_require__","moduleId","installedModules","exports","module","id","loaded","call","m","c","p","dragular","examplesRouter","BasicCtrl","BasicModelCtrl","BoundingBoxCtrl","BoundingBoxLockXCtrl","BoundingBoxLockYCtrl","CopyCtrl","CopyModelCtrl","CustomClassesCtrl","DifferentOptionsModelCtrl","DirectiveCtrl","DirectiveModelCtrl","DragOverEventsCtrl","EventsCtrl","HandleCtrl","IsContainerModelCtrl","NameSpacesCtrl","NestedNgRepeatCtrl","NestedNgRepeatWithModelCtrl","NgRepeatCtrl","NgRepeatFilteredWithModelCtrl","NgRepeatWithModelCtrl","RemoveOnSpillCtrl","RemoveOnSpillWithModelCtrl","RevertOnSpillCtrl","ScrollingDragCtrl","angular","config","controller","$scope","examplesList","template","link","title","highlightCode","document","getElementsByTagName","length","codeBlocks","i","hljs","highlightBlock","rowOffcanvas","toggleSidebar","element","getElementById","toggleClass","dragularDirective","dragularService","factory","directive","restrict","iElm","iAttrs","tryJson","json","JSON","parse","e","drake","options","$eval","containersModel","dynamicModelAttribute","$watch","dragularModel","newVal","sanitizeContainersModel","dragularNameSpace","nameSpace","split","$inject","global","shared","classesCache","containersCtx","containers","mirror","source","item","copy","sourceItem","sourceModel","sourceFilteredModel","target","targetCtx","targetModel","lastDropTarget","offsetX","offsetY","moveX","moveY","offsetXr","offsetYb","clientX","clientY","mirrorWidth","mirrorHeight","initialSibling","currentSibling","initialIndex","currentIndex","tempModel","dragOverEvents","lastElementBehindCursor","grabbed","$rootScope","$compile","service","arg0","arg1","Array","isArray","processServiceArguments","arguments","isElement","initialContainers","querySelectorAll","o","copyOptions","extendOptions","tmp","extend","defaultOptions","classes","defaultClasses","eventNames","defaultEventNames","processOptionsObject","boundingBox","makeArray","containersFilteredModel","forEach","len","shLen","getContainersModel","fm","registerEvents","remove","op","regEvent","docElm","release","container","grab","name","eventName","doc","createEvent","initEvent","createEventObject","eventType","whichMouseButton","metaKey","ctrlKey","context","canStart","eventualMovements","type","isInput","focus","preventDefault","ungrab","dragging","originalEvent","getCoord","elementBehindCursor","getElementBehindPoint","dropTarget","findDropTarget","g","copySortSource","drop","removeOnSpill","cancel","fireEvent","dragularrelease","scope","$emit","isContainer","el","indexOf","isContainerModel","removeContainers","all","$applyAsync","changes","index","splice","startBecauseMouseMoved","movements","preventGrabbed","destroy","ignoreInputTextSelection","elementFromPoint","end","start","direction","getParent","parent","parentNode","parentHeight","offsetHeight","parentWidth","offsetWidth","childHeight","clientHeight","childWidth","clientWidth","offset","getOffset","left","top","right","bottom","addClass","transit","renderMirrorImage","style","drag","handle","invalid","moves","nextEl","manualStart","cloneNode","dragularcloned","containerIndex","domIndexOf","dragulardrag","afterDrop","compileItemOnDrop","content","removeChild","insertBefore","isInitialPlacement","dragularcancel","dragulardrop","dropIndex","cleanup","dropElmModel","dontCopyModel","dragularremove","revert","reverts","revertOnSpill","initial","removeMirrorImage","rmClass","spillOut","dragularout","dragulardragend","s","sibling","accepted","accepts","immediate","getImmediateChild","reference","getReference","dragularCommon","canBeAccepted","moved","spillOver","pageX","pageY","offsetBox","x","y","lockY","lockX","changed","dragularenter","dragularleave","dragularshadow","hide","scrollContainer","before","scrollTop","deltaY","stopPropagation","rect","getBoundingClientRect","width","height","getRectWidth","getRectHeight","mirrorContainer","appendChild","body","unselectable","outside","children","horizontal","inside","resolve","after","point","state","className","getBool","dragularover","never","getEmptyObject","always","fn","touch","mouseup","mousedown","mousemove","pointers","microsoft","$el","navigator","pointerEnabled","msPointerEnabled","startIndex","prototype","slice","touches","undefined","buttons","which","button","getScroll","scrollProp","offsetProp","window","scrollLeft","manually","nextSibling","nodeType","nextElementSibling","obj","HTMLElement","nodeName","lookupClass","cached","lastIndex","RegExp","current","test","replace","trim","getEventHost","targetTouches","changedTouches","coord","host","missMap","tagName","isEditable","contentEditable","child","extra","dispatchEvent","prop","args","isFunction","apply","this","documentElement","cleanEnviroment","$stateProvider","$urlRouterProvider","otherwise","timer","ctrl","$state","$stateParams","$timeout","go","url","templateUrl","$element","items1","items2","eq","containerLeft","querySelector","containerRight","dragularOptions","on","parentElement","removeClass","notContainer","getElementsByClassName","myFn","$on","cartModel","removeItem","classList","contains","items","parentContainers","nestedContainers","push","addItem","$interval","bar","inc","speed","leftScrollContainer","rightScrollContainer","leftTopBar","leftBottomBar","rightTopBar","rightBottomBar","run","$templateCache","put"],"mappings":"CAAS,SAAUA,GAKT,QAASC,GAAoBC,GAG5B,GAAGC,EAAiBD,GACnB,MAAOC,GAAiBD,GAAUE,OAGnC,IAAIC,GAASF,EAAiBD,IAC7BE,WACAE,GAAIJ,EACJK,QAAQ,EAUT,OANAP,GAAQE,GAAUM,KAAKH,EAAOD,QAASC,EAAQA,EAAOD,QAASH,GAG/DI,EAAOE,QAAS,EAGTF,EAAOD,QAvBf,GAAID,KAqCJ,OATAF,GAAoBQ,EAAIT,EAGxBC,EAAoBS,EAAIP,EAGxBF,EAAoBU,EAAI,GAGjBV,EAAoB,KAK/B,SAASI,EAAQ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8Q,EAAgBJ,EAAsB,GAkBvD1X,GAAkB8C,SAAW,YAAa,WAAY,mBAEtD/E,EAAOD,QAAUkC,GAKZ,SAASjC,EAAQD,GAEtB,YAAcC,GAAOD,QAAUmC,QAAQlC,OAAO,gBAAiBga,KAAK,iBAAkB,SAASC,GAAiBA,EAAeC,IAAI,+BAA+B;AAClKD,EAAeC,IAAI,mDAAmD,49EACtED,EAAeC,IAAI,iCAAiC,+7DACpDD,EAAeC,IAAI,6CAA6C,m9BAChED,EAAeC,IAAI,uDAAuD,sgCAC1ED,EAAeC,IAAI,uDAAuD,0hCAC1ED,EAAeC,IAAI,+BAA+B,42CAClDD,EAAeC,IAAI,iDAAiD,m4EACpED,EAAeC,IAAI,iDAAiD,+vCACpED,EAAeC,IAAI,yEAAyE,iuGAC5FD,EAAeC,IAAI,yCAAyC,s8DAC5DD,EAAeC,IAAI,2DAA2D,0yEAC9ED,EAAeC,IAAI,mDAAmD,o3JACtED,EAAeC,IAAI,mCAAmC,owDACtDD,EAAeC,IAAI,mCAAmC,sqBACtDD,EAAeC,IAAI,+DAA+D,mtGAClFD,EAAeC,IAAI,2CAA2C;AAC9DD,EAAeC,IAAI,mDAAmD,wxFACtED,EAAeC,IAAI,qEAAqE,u6HACxFD,EAAeC,IAAI,uCAAuC,0+BAC1DD,EAAeC,IAAI,yEAAyE,sgKAC5FD,EAAeC,IAAI,yDAAyD,+lEAC5ED,EAAeC,IAAI,iDAAiD,ulCACpED,EAAeC,IAAI,mEAAmE,gkFACtFD,EAAeC,IAAI,iDAAiD,6sCACpED,EAAeC,IAAI,iDAAiD,04IACpED,EAAeC,IAAI,mCAAmC,kMACtDD,EAAeC,IAAI,6BAA6B,2wBAChDD,EAAeC,IAAI,6BAA6B,yuGAChDD,EAAeC,IAAI,yCAAyC","file":"examples.min.js","sourcesContent":["/******/ (function(modules) { // webpackBootstrap\n/******/ \t// The module cache\n/******/ \tvar installedModules = {};\n\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId])\n/******/ \t\t\treturn installedModules[moduleId].exports;\n\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\texports: {},\n/******/ \t\t\tid: moduleId,\n/******/ \t\t\tloaded: false\n/******/ \t\t};\n\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.loaded = true;\n\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n\n\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(0);\n/******/ })\n/************************************************************************/\n/******/ ([\n/* 0 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t/* global angular, hljs */\n\t'use strict';\n\n\t// var angular = require('angular');\n\n\tvar dragular = __webpack_require__(1);\n\tvar examplesRouter = __webpack_require__(4);\n\tvar BasicCtrl = __webpack_require__(5);\n\tvar BasicModelCtrl = __webpack_require__(6);\n\tvar BoundingBoxCtrl = __webpack_require__(7);\n\tvar BoundingBoxLockXCtrl = __webpack_require__(8);\n\tvar BoundingBoxLockYCtrl = __webpack_require__(9);\n\tvar CopyCtrl = __webpack_require__(10);\n\tvar CopyModelCtrl = __webpack_require__(11);\n\tvar CustomClassesCtrl = __webpack_require__(12);\n\tvar DifferentOptionsModelCtrl = __webpack_require__(13);\n\tvar DirectiveCtrl = __webpack_require__(14);\n\tvar DirectiveModelCtrl = __webpack_require__(15);\n\tvar DragOverEventsCtrl = __webpack_require__(16);\n\tvar EventsCtrl = __webpack_require__(17);\n\tvar HandleCtrl = __webpack_require__(18);\n\tvar IsContainerModelCtrl = __webpack_require__(19);\n\tvar NameSpacesCtrl = __webpack_require__(20);\n\tvar NestedNgRepeatCtrl = __webpack_require__(21);\n\tvar NestedNgRepeatWithModelCtrl = __webpack_require__(22);\n\tvar NgRepeatCtrl = __webpack_require__(23);\n\tvar NgRepeatFilteredWithModelCtrl = __webpack_require__(23);\n\tvar NgRepeatWithModelCtrl = __webpack_require__(24);\n\tvar RemoveOnSpillCtrl = __webpack_require__(25);\n\tvar RemoveOnSpillWithModelCtrl = __webpack_require__(26);\n\tvar RevertOnSpillCtrl = __webpack_require__(27);\n\tvar ScrollingDragCtrl = __webpack_require__(28);\n\t__webpack_require__(29);\n\n\t/**\n\t * Module Example App\n\t *\n\t * DEMO app for dragular https://github.com/luckylooke/dragular\n\t */\n\n\tangular\n\t .module('examplesApp', [dragular, 'templates', 'ui.router'])\n\t .config(examplesRouter)\n\t .controller('Basic', BasicCtrl)\n\t .controller('BasicModel', BasicModelCtrl)\n\t .controller('BoundingBox', BoundingBoxCtrl)\n\t .controller('BoundingBoxLockX', BoundingBoxLockXCtrl)\n\t .controller('BoundingBoxLockY', BoundingBoxLockYCtrl)\n\t .controller('Copy', CopyCtrl)\n\t .controller('CopyModel', CopyModelCtrl)\n\t .controller('CustomClasses', CustomClassesCtrl)\n\t .controller('DifferentOptionsModel', DifferentOptionsModelCtrl)\n\t .controller('Directive', DirectiveCtrl)\n\t .controller('DirectiveModel', DirectiveModelCtrl)\n\t .controller('DragOverEvents', DragOverEventsCtrl)\n\t .controller('Events', EventsCtrl)\n\t .controller('Handle', HandleCtrl)\n\t .controller('IsContainerModel', IsContainerModelCtrl)\n\t .controller('NameSpaces', NameSpacesCtrl)\n\t .controller('NestedNgRepeat', NestedNgRepeatCtrl)\n\t .controller('NestedNgRepeatWithModel', NestedNgRepeatWithModelCtrl)\n\t .controller('NgRepeat', NgRepeatCtrl)\n\t .controller('NgRepeatFilteredWithModel', NgRepeatFilteredWithModelCtrl)\n\t .controller('NgRepeatWithModel', NgRepeatWithModelCtrl)\n\t .controller('RemoveOnSpill', RemoveOnSpillCtrl)\n\t .controller('RemoveOnSpillWithModel', RemoveOnSpillWithModelCtrl)\n\t .controller('RevertOnSpill', RevertOnSpillCtrl)\n\t .controller('ScrollingDrag', ScrollingDragCtrl)\n\t .controller('ExAppCtrl', ['$scope', function($scope) {\n\t $scope.examplesList = [{\n\t template: 'docsInstall/docsInstall.html',\n\t link: 'docsInstall',\n\t title: 'Installation'\n\t },{\n\t template: 'exampleBasic/exampleBasic.html',\n\t link: 'exampleBasic',\n\t title: 'Basic'\n\t },{\n\t template: 'exampleBasicWithModel/exampleBasicWithModel.html',\n\t link: 'exampleBasicWithModel',\n\t title: 'Basic - with model'\n\t },{\n\t template: 'exampleDifferentOptionsWithModel/exampleDifferentOptionsWithModel.html',\n\t link: 'exampleDifferentOptionsWithModel',\n\t title: 'Different options - with model'\n\t }, {\n\t template: 'exampleDirective/exampleDirective.html',\n\t link: 'exampleDirective',\n\t title: 'Directive'\n\t }, {\n\t template: 'exampleDirectiveWithModel/exampleDirectiveWithModel.html',\n\t link: 'exampleDirectiveWithModel',\n\t title: 'Directive - with model'\n\t }, {\n\t template: 'exampleEvents/exampleEvents.html',\n\t link: 'exampleEvents',\n\t title: 'Events'\n\t }, {\n\t template: 'exampleRemoveOnSpill/exampleRemoveOnSpill.html',\n\t link: 'exampleRemoveOnSpill',\n\t title: 'Remove on spill'\n\t }, {\n\t template: 'exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel.html',\n\t link: 'exampleRemoveOnSpillWithModel',\n\t title: 'Remove on spill - with model'\n\t }, {\n\t template: 'exampleRevertOnSpill/exampleRevertOnSpill.html',\n\t link: 'exampleRevertOnSpill',\n\t title: 'Revert on spill'\n\t }, {\n\t template: 'exampleCopy/exampleCopy.html',\n\t link: 'exampleCopy',\n\t title: 'Copy'\n\t }, {\n\t template: 'exampleCopyWithModel/exampleCopyWithModel.html',\n\t link: 'exampleCopyWithModel',\n\t title: 'Copy - with model'\n\t }, {\n\t template: 'exampleHandle/exampleHandle.html',\n\t link: 'exampleHandle',\n\t title: 'Handle'\n\t }, {\n\t template: 'exampleIsContainerWithModel/exampleIsContainerWithModel.html',\n\t link: 'exampleIsContainerWithModel',\n\t title: 'isContainer - with model'\n\t }, {\n\t template: 'exampleCustomClasses/exampleCustomClasses.html',\n\t link: 'exampleCustomClasses',\n\t title: 'Custom classes'\n\t }, {\n\t template: 'exampleNameSpaces/exampleNameSpaces.html',\n\t link: 'exampleNameSpaces',\n\t title: 'NameSpaces'\n\t }, {\n\t template: 'exampleDragOverEvents/exampleDragOverEvents.html',\n\t link: 'exampleDragOverEvents',\n\t title: 'Drag-over events'\n\t }, {\n\t template: 'exampleBoundingBox/exampleBoundingBox.html',\n\t link: 'exampleBoundingBox',\n\t title: 'BoundingBox'\n\t }, {\n\t template: 'exampleBoundingBoxLockX/exampleBoundingBoxLockX.html',\n\t link: 'exampleBoundingBoxLockX',\n\t title: 'BoundingBox + LockX'\n\t }, {\n\t template: 'exampleBoundingBoxLockY/exampleBoundingBoxLockY.html',\n\t link: 'exampleBoundingBoxLockY',\n\t title: 'BoundingBox + LockY'\n\t }, {\n\t template: 'exampleNgRepeat/exampleNgRepeat.html',\n\t link: 'exampleNgRepeat',\n\t title: 'ngRepeat'\n\t }, {\n\t template: 'exampleNgRepeatWithModel/exampleNgRepeatWithModel.html',\n\t link: 'exampleNgRepeatWithModel',\n\t title: 'ngRepeat - with model'\n\t }, {\n\t template: 'exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel.html',\n\t link: 'exampleNgRepeatFilteredWithModel',\n\t title: 'Filtered ngRepeat - with model'\n\t }, {\n\t template: 'exampleNestedNgRepeat/exampleNestedNgRepeat.html',\n\t link: 'exampleNestedNgRepeat',\n\t title: 'Nested ngRepead'\n\t }, {\n\t template: 'exampleNestedNgRepeatWithModel/exampleNestedNgRepeatWithModel.html',\n\t link: 'exampleNestedNgRepeatWithModel',\n\t title: 'Nested ngRepead - with model'\n\t }, {\n\t template: 'exampleScrollingDrag/exampleScrollingDrag.html',\n\t link: 'exampleScrollingDrag',\n\t title: 'Scrolling drag'\n\t }];\n\n\t $scope.highlightCode = function () {\n\t if(document.getElementsByTagName('code').length){\n\t var codeBlocks = document.getElementsByTagName('code');\n\t for (var i = codeBlocks.length - 1; i >= 0; i--) {\n\t hljs.highlightBlock(codeBlocks[i]);\n\t }\n\t }\n\t };\n\n\t var rowOffcanvas;\n\t $scope.toggleSidebar = function toggleSidebar () {\n\t if(!rowOffcanvas){\n\t rowOffcanvas = angular.element(document.getElementById('rowOffcanvas'));\n\t }\n\t rowOffcanvas.toggleClass('active');\n\t };\n\n\t }]);\n\n\n/***/ },\n/* 1 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t/* global angular */\n\t'use strict';\n\tvar dragularDirective = __webpack_require__(2);\n\tvar dragularService = __webpack_require__(3);\n\n\t/**\n\t * Dragular 4.1.0 by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\tmodule.exports = 'dragularModule';\n\n\tangular\n\t .module('dragularModule', [])\n\t .factory('dragularService', dragularService)\n\t .directive('dragular', dragularDirective);\n\n\n/***/ },\n/* 2 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\t/**\n\t * dragular Directive by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\n\tvar dragular = function (dragularService) {\n\t return {\n\t restrict: 'A',\n\t link: function($scope, iElm, iAttrs) {\n\n\t var drake,\n\t options = $scope.$eval(iAttrs.dragular) || tryJson(iAttrs.dragular) || {};\n\n\t function tryJson(json) {\n\t try { // I dont like try catch solutions but I havent find sattisfying way of chcecking json validity.\n\t return JSON.parse(json);\n\t } catch (e) {\n\t return undefined;\n\t }\n\t }\n\n\t if(options && options.containersModel && typeof options.containersModel === 'string'){\n\t options.containersModel = $scope.$eval(options.containersModel);\n\t }\n\n\t if(options && options.dynamicModelAttribute){\n\t // watch for model changes\n\t $scope.$watch(function () {\n\t return $scope.$eval(iAttrs.dragularModel);\n\t }, function (newVal) {\n\t if(newVal){\n\t drake.containersModel = drake.sanitizeContainersModel($scope.$eval(newVal));\n\t }\n\t });\n\t }else if(iAttrs.dragularModel){\n\t // bind once and keep reference\n\t options.containersModel = $scope.$eval(iAttrs.dragularModel);\n\t }\n\n\t if(iAttrs.dragularNameSpace){\n\t options.nameSpace = iAttrs.dragularNameSpace.split(' ');\n\t }\n\n\t drake = dragularService(iElm[0], options);\n\t }\n\t };\n\t};\n\n\tdragular.$inject = ['dragularService'];\n\n\tmodule.exports = dragular;\n\n\n/***/ },\n/* 3 */\n/***/ function(module, exports) {\n\n\t/* WEBPACK VAR INJECTION */(function(global) {/* global angular */\n\t'use strict';\n\n\t/**\n\t * dragular Service by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\n\tvar shared = { // sahred object between all service instances\n\t classesCache: {}, // classes lookup cache\n\t containersCtx: {}, // containers model\n\t containers: {}, // containers\n\t mirror: null, // mirror image\n\t source: null, // source container\n\t item: null, // item being dragged\n\t copy: null, // copy flag\n\t sourceItem: null, // item originaly dragged if copy is enabled\n\t sourceModel: null, // source container model\n\t sourceFilteredModel: null, // source container filtered model if relevant\n\t target: null, // droppable container under drag item\n\t targetCtx: null, // target container context\n\t targetModel: null, // target container model\n\t lastDropTarget: null, // last container item was over\n\t offsetX: null, // reference x\n\t offsetY: null, // reference y\n\t moveX: null, // reference move x\n\t moveY: null, // reference move y\n\t offsetXr: null, // reference x right for boundingBox feature\n\t offsetYb: null, // reference y bottom for boundingBox feature\n\t clientX: null, // cache client x, init at grab, update at drag\n\t clientY: null, // cache client y, init at grab, update at drag\n\t mirrorWidth: null, // mirror width for boundingBox feature\n\t mirrorHeight: null, // mirror height for boundingBox feature\n\t initialSibling: null, // reference sibling when grabbed\n\t currentSibling: null, // reference sibling now\n\t initialIndex: null, // reference model index when grabbed\n\t currentIndex: null, // reference model index now\n\t tempModel: null, // if o.isContainer is used, model can be provided as well, it is temporary saved here during drags\n\t dragOverEvents: {}, // drag over events fired on element behind cursor\n\t lastElementBehindCursor: null, // last element behind cursor\n\t grabbed: null // holds mousedown context until first mousemove\n\t};\n\n\tvar dragularService = function ($rootScope, $compile) {\n\t // abbreviations\n\t var doc = document,\n\t docElm = doc.documentElement;\n\n\t // clean common/shared objects\n\t service.cleanEnviroment = function cleanEnviroment() {\n\t shared.classesCache = {};\n\t shared.containersCtx = {};\n\t shared.containers = {};\n\t shared.mirror = undefined;\n\t };\n\n\t service.shared = shared;\n\n\t return service;\n\n\t // service definition\n\t function service(arg0, arg1) {\n\t var initialContainers = arg0 || [],\n\t options = arg1 || {},\n\t o, // shorthand for options\n\t g = getBool, // shorthand for getBool\n\t // defaults\n\t defaultClasses = {\n\t mirror: 'gu-mirror',\n\t hide: 'gu-hide',\n\t unselectable: 'gu-unselectable',\n\t transit: 'gu-transit'\n\t },\n\t defaultEventNames = {\n\t // drag-over DOM events\n\t dragularenter: 'dragularenter',\n\t dragularleave: 'dragularleave',\n\t dragularrelease: 'dragularrelease',\n\t // $scope events\n\t dragularcloned: 'dragularcloned',\n\t dragulardrag: 'dragulardrag',\n\t dragularcancel: 'dragularcancel',\n\t dragulardrop: 'dragulardrop',\n\t dragularremove: 'dragularremove',\n\t dragulardragend: 'dragulardragend',\n\t dragularshadow: 'dragularshadow',\n\t dragularover: 'dragularover',\n\t dragularout: 'dragularout'\n\t },\n\t defaultOptions = { // options with defaults\n\t copyOptions: false, // copy options object when provided\n\t classes: defaultClasses, // classes used by dragular\n\t eventNames: defaultEventNames, // event names used by dragular\n\t containers: false, // initial containers provided via options object (are provided via parameter by default)\n\t containersModel: false, // if provided, model will be synced with DOM\n\t containersFilteredModel: false, // if provided, dragular will handle filtered model cases\n\t isContainer: never, // potential target can be forced to be container by custom logic\n\t isContainerModel: getEmptyObject, // if isContainer function is provided, you can provide also respective model\n\t moves: always, // can drag start?\n\t accepts: always, // can target accept dragged item? (target context used)\n\t canBeAccepted: always, // can be dragged item accepted by target? (source context used)\n\t copy: false, // dragged item will be copy of source? flag or function\n\t copySortSource: false, // enable sorting in source when copying item\n\t dontCopyModel: false, // dont make copy of model when coping item (#61)\n\t invalid: never, // target (in)validity function\n\t revertOnSpill: false, // item returns to original place\n\t removeOnSpill: false, // item will be removed if not placed into valid target\n\t lockX: false, // lock movement into x-axis\n\t lockY: false, // lock movement into y-axis\n\t boundingBox: false, // lock movement inside this element boundaries\n\t mirrorContainer: doc.body, // element for appending mirror\n\t ignoreInputTextSelection: true, // text selection in inputs wont be considered as drag\n\t compileItemOnDrop: false\n\t },\n\t drake = {\n\t containers: shared.containers,\n\t containersCtx: shared.containersCtx,\n\t sanitizeContainersModel: sanitizeContainersModel,\n\t isContainer: isContainer,\n\t start: manualStart,\n\t end: end,\n\t cancel: cancel,\n\t remove: remove,\n\t destroy: destroy,\n\t dragging: false\n\t };\n\n\t processServiceArguments(); // both arguments (containers and options) are optional, this function handle this\n\t extendOptions();\n\t processOptionsObject();\n\t registerEvents();\n\n\t return drake;\n\n\t // Function definitions: ==============================================================================================================\n\t // Initial functions: -----------------------------------------------------------------------------------------------------------------\n\n\t function sanitizeContainersModel(containersModel) {\n\t if (typeof(containersModel) === 'function') {\n\t return containersModel;\n\t }\n\t if (Array.isArray(containersModel)) {\n\t // |-------- is 2D array? -----------|\n\t return Array.isArray(containersModel[0]) ? containersModel : [containersModel];\n\t } else {\n\t return [];\n\t }\n\t }\n\n\t function processServiceArguments(){\n\t if (arguments.length === 1 && // if there is only one argument we need to distinguish if it is options object or container(s) reference\n\t !Array.isArray(arg0) && // array of containers elements\n\t !angular.isElement(arg0) && // one container element\n\t !arg0[0] && // array-like object with containers elements\n\t typeof arg0 !== 'string') { // selector\n\t // then arg0 is options object\n\t options = arg0 || {};\n\t initialContainers = []; // containers are not provided on init\n\t } else if (typeof arg0 === 'string') {\n\t initialContainers = document.querySelectorAll(arg0);\n\t }\n\t o = options.copyOptions ? angular.copy(options) : options;\n\t }\n\n\t function extendOptions(){\n\t var tmp = angular.extend({}, defaultOptions, o); // tmp for keeping defaults untouched\n\t angular.extend(o, tmp); // merge defaults back into options\n\t if(o.classes){\n\t tmp = angular.extend({}, defaultClasses, o.classes);\n\t angular.extend(o.classes, tmp);\n\t }\n\t if(o.eventNames){\n\t tmp = angular.extend({}, defaultEventNames, o.eventNames);\n\t angular.extend(o.eventNames, tmp);\n\t }\n\t }\n\n\t function processOptionsObject(){\n\t // bounding box must be pure DOM element, not jQuery wrapper or something else..\n\t if (!isElement(o.boundingBox)) {\n\t o.boundingBox = false;\n\t }\n\n\t // initial containers provided via options are higher priority then by parameter\n\t if(o.containers){\n\t initialContainers = o.containers;\n\t }\n\t // sanitize initialContainers\n\t initialContainers = makeArray(initialContainers);\n\n\t // sanitize o.containersModel\n\t o.containersModel = sanitizeContainersModel(o.containersModel);\n\n\t // sanitize o.containersFilteredModel\n\t if (Array.isArray(o.containersFilteredModel)) {\n\t // |-------- is 2D array? -----------|\n\t o.containersFilteredModel = Array.isArray(o.containersFilteredModel[0]) ? o.containersFilteredModel : [o.containersFilteredModel];\n\t } else {\n\t o.containersFilteredModel = [];\n\t }\n\n\t // feed containers groups and optionaly do same for models\n\t if (!o.nameSpace) {\n\t o.nameSpace = ['dragularCommon'];\n\t }\n\t if (!Array.isArray(o.nameSpace)) {\n\t o.nameSpace = [o.nameSpace];\n\t }\n\t o.nameSpace.forEach(function eachNameSpace(nameSpace) {\n\t if (!shared.containers[nameSpace]) {\n\t shared.containers[nameSpace] = [];\n\t shared.containersCtx[nameSpace] = [];\n\t }\n\t var len = initialContainers.length,\n\t shLen = shared.containers[nameSpace].length;\n\t for (var i = 0; i < len; i++) {\n\t shared.containers[nameSpace][i + shLen] = initialContainers[i];\n\t shared.containersCtx[nameSpace][i + shLen] = {\n\t o: o,\n\t m: getContainersModel()[i], // can be undefined\n\t fm: o.containersFilteredModel[i] // can be undefined\n\t };\n\t }\n\t });\n\t }\n\n\t function registerEvents(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'mouseup', release);\n\n\t initialContainers.forEach(function addMouseDown(container) {\n\t regEvent(container, 'on', 'mousedown', grab);\n\t });\n\n\t if(!remove){ // create dragular DOM events\n\t angular.forEach(['dragularenter', 'dragularleave', 'dragularrelease'], function prepareDragOverEvents(name) {\n\t var eventName = o.eventNames[name];\n\t if(!shared.dragOverEvents[eventName]){\n\t if (doc.createEvent) {\n\t shared.dragOverEvents[eventName] = doc.createEvent('HTMLEvents');\n\t shared.dragOverEvents[eventName].initEvent(eventName, true, true);\n\t } else {\n\t shared.dragOverEvents[eventName] = doc.createEventObject();\n\t shared.dragOverEvents[eventName].eventType = eventName;\n\t }\n\t }\n\t });\n\t }\n\t }\n\n\t // Event handlers functions (end of initial functions): -----------------------------------------------------------------------------------------------------------------\n\n\t function grab(e) {\n\t // filter some odd situations\n\t if (whichMouseButton(e) !== 1 || e.metaKey || e.ctrlKey) {\n\t return; // we only care about honest-to-god left clicks and touch events\n\t }\n\n\t // set itial values\n\t shared.moveX = e.clientX;\n\t shared.moveY = e.clientY;\n\n\t var context = canStart(e.target);\n\t if (!context || !context.item) {\n\t return;\n\t }\n\n\t shared.grabbed = context;\n\t eventualMovements();\n\t if (e.type === 'mousedown') {\n\t if (isInput(context.item)) { // see also: https://github.com/bevacqua/dragula/issues/208\n\t context.item.focus(); // fixes https://github.com/bevacqua/dragula/issues/176\n\t } else {\n\t e.preventDefault(); // fixes https://github.com/bevacqua/dragula/issues/155\n\t }\n\t }\n\t }\n\n\t function release(e) {\n\t ungrab();\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t var elementBehindCursor = getElementBehindPoint(shared.mirror, shared.clientX, shared.clientY),\n\t dropTarget = findDropTarget(elementBehindCursor, shared.clientX, shared.clientY);\n\n\t if (dropTarget && ((shared.copy && g(o.copySortSource)) || (!shared.copy || dropTarget !== shared.source))) {\n\t // found valid target and (is not copy case or target is not initial container)\n\t drop(shared.item, dropTarget);\n\t } else if (g(o.removeOnSpill)) {\n\t remove();\n\t } else {\n\t cancel();\n\t }\n\n\t // after release there is no container hovered\n\t shared.target = null;\n\n\t if (shared.lastElementBehindCursor) {\n\t fireEvent(shared.lastElementBehindCursor, shared.dragOverEvents.dragularrelease, elementBehindCursor);\n\t }\n\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularrelease, shared.item, shared.source);\n\t }\n\t }\n\n\t // Main logic functions (end of event handler functions): -----------------------------------------------------------------------------------------------------------------\n\n\t function isContainer(el) {\n\t if(!el){\n\t return false;\n\t }\n\t var i = o.nameSpace.length;\n\t while (i--) {\n\t if (shared.containers[o.nameSpace[i]].indexOf(el) !== -1) {\n\t return true;\n\t }\n\t }\n\t if (o.isContainer(el)) {\n\t shared.tempModel = o.isContainerModel(el);\n\t return true;\n\t } else {\n\t shared.tempModel = null;\n\t }\n\t return false;\n\t }\n\n\t function getContainersModel() {\n\t return (typeof(o.containersModel) === 'function') ? sanitizeContainersModel(o.containersModel(drake, shared)) : o.containersModel;\n\t }\n\n\t function removeContainers(all) {\n\t $rootScope.$applyAsync(function applyDestroyed() {\n\t var changes = Array.isArray(all) ? all : makeArray(all);\n\t changes.forEach(function forEachContainer(container) {\n\t angular.forEach(o.nameSpace, function forEachNs(nameSpace) {\n\t var index;\n\t index = shared.containers[nameSpace].indexOf(container);\n\t shared.containers[nameSpace].splice(index, 1);\n\t shared.containersCtx[nameSpace].splice(index, 1);\n\t });\n\t });\n\t });\n\t }\n\n\t function eventualMovements(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'mousemove', startBecauseMouseMoved);\n\t }\n\n\t function movements(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'selectstart', preventGrabbed); // IE8\n\t regEvent(docElm, op, 'click', preventGrabbed);\n\t regEvent(docElm, op, 'touchmove', preventGrabbed); // fixes touch devices scrolling while drag\n\t }\n\n\t function destroy() {\n\t registerEvents(true);\n\t removeContainers(initialContainers);\n\t release({});\n\t }\n\n\t function startBecauseMouseMoved(e) {\n\t if (!shared.grabbed || drake.dragging) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t if (whichMouseButton(e) === 0) {\n\t release({});\n\t return; // when text is selected on an input and then dragged, mouseup doesn't fire. this is our only hope\n\t }\n\t // truthy check fixes dragula-#239, equality fixes dragula-#207\n\t if (e.clientX && e.clientX === shared.moveX && e.clientY && e.clientY === shared.moveY) {\n\t return;\n\t }\n\t if (g(o.ignoreInputTextSelection)) {\n\t var clientX = getCoord('clientX', e),\n\t clientY = getCoord('clientY', e),\n\t elementBehindCursor = doc.elementFromPoint(clientX, clientY);\n\t if (isInput(elementBehindCursor)) {\n\t return;\n\t }\n\t }\n\n\t var grabbed = shared.grabbed; // calling end() unsets shared.grabbed\n\t eventualMovements('remove'); // remove mousemove listener\n\t movements();\n\t end();\n\t start(grabbed);\n\n\t // automaticly detect direction of elements if not set in options\n\t if (!o.direction && getParent(shared.sourceItem)) {\n\t var parent = shared.sourceItem.parentNode,\n\t parentHeight = parent.offsetHeight,\n\t parentWidth = parent.offsetWidth,\n\t childHeight = shared.sourceItem.clientHeight,\n\t childWidth = shared.sourceItem.clientWidth;\n\t o.direction = parentHeight / childHeight < parentWidth / childWidth ? 'horizontal' : 'vertical';\n\t }\n\n\t // get initial coordinates, used to render shared.mirror for first time\n\t var offset = getOffset(shared.sourceItem);\n\t shared.offsetX = getCoord('pageX', e) - offset.left;\n\t shared.offsetY = getCoord('pageY', e) - offset.top;\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t // limiting area of shared.mirror movement, get initial coordinates\n\t if (o.boundingBox) {\n\t shared.offsetXr = getCoord('pageX', e) - offset.right;\n\t shared.offsetYb = getCoord('pageY', e) - offset.bottom;\n\t }\n\n\t e.preventDefault();\n\n\t addClass(shared.item, o.classes.transit);\n\t renderMirrorImage();\n\t // initial position\n\t shared.mirror.style.left = shared.clientX - shared.offsetX + 'px';\n\t shared.mirror.style.top = shared.clientY - shared.offsetY + 'px';\n\n\t drag(e);\n\t }\n\n\t function canStart(item) {\n\t if (drake.dragging && shared.mirror) {\n\t console.log('usecase?');\n\t return; // already dragging\n\t }\n\n\t var handle = item;\n\t while (getParent(item) && !isContainer(getParent(item))) {\n\t // break loop if user tries to drag item which is considered invalid handle\n\t if (o.invalid(item, handle)) {\n\t return;\n\t }\n\t item = getParent(item); // drag target should be immediate child of container\n\t if (!item) {\n\t return;\n\t }\n\t }\n\n\t var source = getParent(item);\n\t if (!source ||\n\t o.invalid(item, handle) ||\n\t !o.moves(item, source, handle, nextEl(item))) {\n\t return;\n\t }\n\n\t return {\n\t item: item,\n\t source: source\n\t };\n\t }\n\n\t function manualStart(item) {\n\t var context = canStart(item);\n\t if (context) {\n\t start(context);\n\t }\n\t }\n\n\t function start(context) {\n\t shared.sourceItem = shared.item = context.item;\n\t shared.source = context.source;\n\t shared.initialSibling = shared.currentSibling = nextEl(context.item);\n\n\t if (g(o.copy, [context.item, context.source])) {\n\t shared.item = context.item.cloneNode(true);\n\t shared.copy = true;\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularcloned, shared.item, context.item);\n\t }\n\t } else {\n\t shared.copy = false;\n\t }\n\n\t // prepare models operations\n\t var containerIndex = initialContainers.indexOf(context.source);\n\t shared.sourceModel = getContainersModel()[containerIndex];\n\n\t shared.sourceFilteredModel = o.containersFilteredModel[containerIndex];\n\t shared.initialIndex = domIndexOf(context.item, context.source);\n\n\t drake.dragging = true;\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragulardrag, shared.sourceItem, shared.source);\n\t }\n\n\t return true;\n\t }\n\n\t function end() {\n\t if (!drake.dragging || !shared.item) {\n\t return;\n\t }\n\t drop(shared.item, getParent(shared.item));\n\t }\n\n\t function ungrab() {\n\t shared.grabbed = false;\n\t eventualMovements('remove');\n\t movements('remove');\n\t }\n\n\t function drop(item, target) {\n\t var sourceItem = shared.sourceItem,\n\t currentSibling = shared.currentSibling;\n\t \n\t if (shared.copy && g(o.copySortSource) && target === shared.source && getParent(item)) {\n\t item.parentNode.removeChild(shared.sourceItem);\n\t }\n\n\t if (shared.sourceModel && !isInitialPlacement(target)) {\n\n\t var dropIndex = domIndexOf(item, target);\n\t if(shared.targetCtx.fm){ // target has filtered model\n\t // convert index from index-in-filteredModel to index-in-model\n\t dropIndex = shared.targetCtx.m.indexOf(shared.targetCtx.fm[dropIndex]);\n\t }\n\t if(shared.sourceFilteredModel){ // target has filtered model\n\t // convert index from index-in-filteredModel to index-in-model\n\t shared.initialIndex = shared.sourceModel.indexOf(shared.sourceFilteredModel[shared.initialIndex]);\n\t }\n\t $rootScope.$applyAsync(function applyDrop() {\n\t if(!shared.sourceModel){\n\t return;\n\t }\n\t if (target === shared.source) {\n\t shared.sourceModel.splice(dropIndex, 0, shared.sourceModel.splice(shared.initialIndex, 1)[0]);\n\t } else {\n\t shared.dropElmModel = shared.copy && !o.dontCopyModel ? angular.copy(shared.sourceModel[shared.initialIndex]) : shared.sourceModel[shared.initialIndex];\n\n\t if (!shared.tempModel) {\n\t shared.targetModel = shared.targetCtx.m;\n\t } else {\n\t shared.targetModel = shared.tempModel;\n\t }\n\t \n\t target.removeChild(item); // element must be removed for ngRepeat to apply correctly\n\n\t if (!shared.copy) {\n\t shared.sourceModel.splice(shared.initialIndex, 1);\n\t }\n\t shared.targetModel.splice(dropIndex, 0, shared.dropElmModel);\n\t }\n\n\t if (getParent(item)) {\n\t item.parentNode.removeChild(item);\n\t }\n\n\t afterDrop();\n\t });\n\t } else {\n\t afterDrop();\n\t }\n\n\t function afterDrop() {\n\t if(o.compileItemOnDrop){\n\t var scope = angular.element(target).scope();\n\t scope.$applyAsync(function(){\n\t var content = $compile(shared.copy ? sourceItem.cloneNode(true) : sourceItem)(scope); \n\t if(item.parentNode === target){\n\t target.removeChild(item);\n\t }\n\t target.insertBefore(content[0], currentSibling);\n\t });\n\t }\n\t \n\t if (o.scope) {\n\t if (isInitialPlacement(target)) {\n\t o.scope.$emit(o.eventNames.dragularcancel, item, shared.source, shared.sourceModel, shared.initialIndex);\n\t } else {\n\t o.scope.$emit(o.eventNames.dragulardrop, item, target, shared.source, shared.sourceModel, shared.initialIndex, shared.targetModel, dropIndex);\n\t }\n\t }\n\t \n\t cleanup();\n\t }\n\t }\n\n\t function remove() {\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t var parent = getParent(shared.item);\n\n\t if (parent) {\n\t parent.removeChild(shared.item);\n\t }\n\n\t if (shared.sourceModel) {\n\t $rootScope.$applyAsync(function removeModel() {\n\t shared.sourceModel.splice(shared.initialIndex, 1);\n\t cleanup();\n\t });\n\t }\n\n\t if (o.scope) {\n\t o.scope.$emit(shared.copy ? o.eventNames.dragularcancel : o.eventNames.dragularremove, shared.item, parent, shared.sourceModel, shared.initialIndex);\n\t }\n\t if (!shared.sourceModel) {\n\t cleanup();\n\t }\n\t }\n\n\t function cancel(revert) {\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t var reverts = arguments.length > 0 ? revert : g(o.revertOnSpill),\n\t parent = getParent(shared.item);\n\n\t var initial = isInitialPlacement(parent);\n\t if (!initial && !shared.copy && reverts) {\n\t shared.source.insertBefore(shared.item, shared.initialSibling);\n\t }\n\t if (shared.sourceModel && !shared.copy && !reverts) {\n\t drop(shared.item, parent);\n\t } else if (o.scope) {\n\t if (initial || reverts) {\n\t o.scope.$emit(o.eventNames.dragularcancel, shared.item, shared.source);\n\t }\n\t }\n\n\t if (!shared.sourceModel || shared.copy || reverts || initial) {\n\t cleanup();\n\t }\n\t }\n\n\t function cleanup() {\n\t ungrab();\n\t removeMirrorImage();\n\n\t if (shared.item) {\n\t rmClass(shared.item, o.classes.transit);\n\t }\n\n\t drake.dragging = false;\n\n\t if (g(o.removeOnSpill) === true) {\n\t spillOut();\n\t }\n\n\t if (o.scope) {\n\t if(shared.lastDropTarget){\n\t o.scope.$emit(o.eventNames.dragularout, shared.item, shared.lastDropTarget, shared.source);\n\t }\n\t o.scope.$emit(o.eventNames.dragulardragend, shared.item);\n\t }\n\n\t shared.source = shared.item = shared.sourceItem = shared.initialSibling = shared.currentSibling = shared.sourceModel = null;\n\t shared.initialIndex = shared.currentIndex = shared.lastDropTarget = shared.tempModel = shared.targetModel = null;\n\t shared.dropElmModel = shared.targetCtx = shared.copy = shared.moveX = shared.moveY = null;\n\t }\n\n\t // is item currently placed in original container and original position?\n\t function isInitialPlacement(target, s) { // watch performance - running each move several times!\n\t var sibling = s || (shared.mirror ? shared.currentSibling : nextEl(shared.item));\n\t return target === shared.source && sibling === shared.initialSibling;\n\t }\n\n\t // find valid drop container\n\t function findDropTarget(elementBehindCursor, clientX, clientY) { // watch performance - running each move!\n\t var target = elementBehindCursor;\n\n\t while (target && !accepted()) {\n\t target = getParent(target);\n\t }\n\t return target;\n\n\t function accepted() {\n\t var accepts = false;\n\n\t if (isContainer(target)) { // is droppable?\n\n\t var immediate = getImmediateChild(target, elementBehindCursor),\n\t reference = getReference(target, immediate, clientX, clientY),\n\t initial = isInitialPlacement(target, reference),\n\t i = o.nameSpace.length;\n\n\t while (i--) {\n\t if (shared.containers[o.nameSpace[i]].indexOf(target) !== -1) {\n\t shared.targetCtx = shared.containersCtx[o.nameSpace[i]][shared.containers[o.nameSpace[i]].indexOf(target)];\n\t break;\n\t }\n\t if (!shared.targetCtx) {\n\t shared.targetCtx = shared.containersCtx.dragularCommon[shared.containers.dragularCommon.indexOf(target)];\n\t }\n\t }\n\n\t accepts = initial ||\n\t (shared.targetCtx.o.accepts(shared.item, target, shared.source, reference, shared.sourceModel, shared.initialIndex) &&\n\t o.canBeAccepted(shared.item, target, shared.source, reference, shared.sourceModel, shared.initialIndex));\n\n\t if (shared.target !== target) { // used for scroll issue\n\t shared.target = target;\n\t }\n\t }\n\t return accepts;\n\t }\n\t }\n\n\t function drag(e) { // watch performance - running each move!\n\t if (!shared.mirror) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\n\t // update coordinates\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t // count mirror coordiates\n\t var x = shared.clientX - shared.offsetX,\n\t y = shared.clientY - shared.offsetY,\n\t pageX,\n\t pageY,\n\t offsetBox;\n\n\t // fill extra properties if boundingBox is used\n\t if (o.boundingBox) {\n\t pageX = getCoord('pageX', e);\n\t pageY = getCoord('pageY', e);\n\t offsetBox = getOffset(o.boundingBox);\n\t }\n\n\t if (!o.lockY) {\n\t if (!o.boundingBox || (pageX > offsetBox.left + shared.offsetX && pageX < offsetBox.right + shared.offsetXr)) {\n\t shared.mirror.style.left = x + 'px';\n\t } else if (o.boundingBox) { // check again in case user scrolled the view\n\t if (pageX < offsetBox.left + shared.offsetX) {\n\t shared.mirror.style.left = shared.clientX - (pageX - offsetBox.left) + 'px';\n\t } else {\n\t shared.mirror.style.left = shared.clientX - shared.mirrorWidth - (pageX - offsetBox.right) + 'px';\n\t }\n\t }\n\t }\n\t if (!o.lockX) {\n\t if (!o.boundingBox || (pageY > offsetBox.top + shared.offsetY && pageY < offsetBox.bottom + shared.offsetYb)) {\n\t shared.mirror.style.top = y + 'px';\n\t } else if (o.boundingBox) { // check again in case user scrolled the view\n\t if (pageY < offsetBox.top + shared.offsetY) {\n\t shared.mirror.style.top = shared.clientY - (pageY - offsetBox.top) + 'px';\n\t } else {\n\t shared.mirror.style.top = shared.clientY - shared.mirrorHeight - (pageY - offsetBox.bottom) + 'px';\n\t }\n\t }\n\t }\n\n\t var elementBehindCursor = getElementBehindPoint(shared.mirror, shared.clientX, shared.clientY),\n\t dropTarget = findDropTarget(elementBehindCursor, shared.clientX, shared.clientY),\n\t changed = dropTarget !== shared.lastDropTarget;\n\n\t if (elementBehindCursor !== shared.lastElementBehindCursor) {\n\t fireEvent(elementBehindCursor, shared.dragOverEvents.dragularenter, !!dropTarget);\n\t if (shared.lastElementBehindCursor) {\n\t fireEvent(shared.lastElementBehindCursor, shared.dragOverEvents.dragularleave, elementBehindCursor);\n\t }\n\t shared.lastElementBehindCursor = elementBehindCursor;\n\t }\n\n\t if (changed) {\n\t if (shared.lastDropTarget) {\n\t moved('out');\n\t }\n\t shared.lastDropTarget = dropTarget;\n\t moved('over');\n\t }\n\n\t // do not copy in same container\n\t if (dropTarget === shared.source && shared.copy && !g(o.copySortSource)) {\n\t if (getParent(shared.item)) {\n\t shared.item.parentNode.removeChild(shared.item);\n\t }\n\t return;\n\t }\n\n\t var reference,\n\t immediate = getImmediateChild(dropTarget, elementBehindCursor);\n\n\t if (immediate !== null) {\n\t reference = getReference(dropTarget, immediate, shared.clientX, shared.clientY);\n\t } else if (g(o.revertOnSpill) === true && !shared.copy) {\n\t // the case that mirror is not over valid target and reverting is on and copy is off\n\t reference = shared.initialSibling;\n\t dropTarget = shared.source;\n\t } else {\n\t // the case that mirror is not over valid target and removing is on or copy is on\n\t if (shared.copy && getParent(shared.item)) {\n\t // remove item or copy of item\n\t shared.item.parentNode.removeChild(shared.item);\n\t }\n\t return;\n\t }\n\n\t if (reference === null ||\n\t reference !== shared.item &&\n\t reference !== nextEl(shared.item) &&\n\t reference !== shared.currentSibling) {\n\t // moving item/copy to new container from previous one\n\t shared.currentSibling = reference;\n\n\t dropTarget.insertBefore(shared.item, reference); // if reference is null item is inserted at the end\n\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularshadow, shared.item, dropTarget);\n\t }\n\t }\n\n\t function moved(type) {\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames['dragular' + type], shared.item, shared.lastDropTarget, shared.source);\n\t }\n\t if (g(o.removeOnSpill) === true) {\n\t type === 'over' ? spillOver() : spillOut();\n\t }\n\t }\n\t }\n\n\t function spillOver() {\n\t rmClass(shared.item, o.classes.hide);\n\t }\n\n\t function spillOut() {\n\t if (drake.dragging) {\n\t addClass(shared.item, o.classes.hide);\n\t }\n\t }\n\n\t function scrollContainer(e) {\n\t if (shared.target) {\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t var before = shared.target.scrollTop;\n\t shared.target.scrollTop += e.deltaY;\n\t // block scroll of the document when container can be scrolled\n\t if (before !== shared.target.scrollTop) {\n\t e.stopPropagation();\n\t e.preventDefault();\n\t }\n\t }\n\t }\n\n\t function renderMirrorImage() {\n\t if (shared.mirror) {\n\t return;\n\t }\n\t var rect = shared.sourceItem.getBoundingClientRect();\n\t shared.mirror = shared.sourceItem.cloneNode(true);\n\t shared.mirrorWidth = rect.width;\n\t shared.mirrorHeight = rect.height;\n\t shared.mirror.style.width = getRectWidth(rect) + 'px';\n\t shared.mirror.style.height = getRectHeight(rect) + 'px';\n\t rmClass(shared.mirror, o.classes.transit);\n\t addClass(shared.mirror, o.classes.mirror);\n\t o.mirrorContainer.appendChild(shared.mirror);\n\t regEvent(docElm, 'on', 'mousemove', drag);\n\t addClass(doc.body, o.classes.unselectable);\n\t regEvent(shared.mirror, 'on', 'wheel', scrollContainer);\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularcloned, shared.mirror, shared.sourceItem);\n\t }\n\t }\n\n\t function removeMirrorImage() {\n\t if (shared.mirror) {\n\t rmClass(doc.body, o.classes.unselectable);\n\t regEvent(docElm, 'off', 'mousemove', drag);\n\t regEvent(shared.mirror, 'off', 'wheel', scrollContainer);\n\t if(getParent(shared.mirror)){\n\t shared.mirror.parentNode.removeChild(shared.mirror);\n\t }\n\t shared.mirror = null;\n\t }\n\t }\n\n\t function getImmediateChild(dropTarget, target) { // watch performance - running each move several times!\n\t var immediate = target;\n\t while (immediate !== dropTarget && getParent(immediate) !== dropTarget) {\n\t immediate = getParent(immediate);\n\t }\n\t if (immediate === docElm) {\n\t return null;\n\t }\n\t return immediate;\n\t }\n\n\t function getReference(dropTarget, target, x, y) { // watch performance - running each move several times!\n\t var horizontal = o.direction === 'horizontal';\n\t return target !== dropTarget ? inside() : outside();\n\n\t function outside() { // slower, but able to figure out any position\n\t var len = dropTarget.children.length,\n\t i, el, rect;\n\t for (i = 0; i < len; i++) {\n\t el = dropTarget.children[i];\n\t rect = el.getBoundingClientRect();\n\t if (horizontal && rect.left > x) {\n\t return el;\n\t }\n\t if (!horizontal && rect.top > y) {\n\t return el;\n\t }\n\t }\n\t return null;\n\t }\n\n\t function inside() { // faster, but only available if dropped inside a child element\n\t var rect = target.getBoundingClientRect();\n\t if (horizontal) {\n\t return resolve(x > rect.left + getRectWidth(rect) / 2);\n\t }\n\t return resolve(y > rect.top + getRectHeight(rect) / 2);\n\t }\n\n\t function resolve(after) {\n\t return after ? nextEl(target) : target;\n\t }\n\t }\n\n\t function getElementBehindPoint(point, x, y) { // watch performance - running each move!\n\t var p = point || {},\n\t state = p.className,\n\t el;\n\t p.className += ' ' + o.classes.hide;\n\t el = doc.elementFromPoint(x, y);\n\t p.className = state;\n\t return el;\n\t }\n\t } // end of service\n\n\t /****************************************************************************************************************************/\n\t /****************************************************************************************************************************/\n\t /****************************************************************************************************************************/\n\n\t // HELPERS FUNCTIONS:\n\n\t function regEvent(el, op, type, fn) {\n\t var touch = {\n\t mouseup: 'touchend',\n\t mousedown: 'touchstart',\n\t mousemove: 'touchmove'\n\t },\n\t pointers = {\n\t mouseup: 'pointerup',\n\t mousedown: 'pointerdown',\n\t mousemove: 'pointermove'\n\t },\n\t microsoft = {\n\t mouseup: 'MSPointerUp',\n\t mousedown: 'MSPointerDown',\n\t mousemove: 'MSPointerMove'\n\t },\n\t $el = angular.element(el);\n\n\t if (global.navigator.pointerEnabled && pointers[type]) {\n\t $el[op](pointers[type], fn);\n\t } else if (global.navigator.msPointerEnabled && microsoft[type]) {\n\t $el[op](microsoft[type], fn);\n\t } else if (touch[type]) {\n\t $el[op](touch[type], fn);\n\t }\n\t $el[op](type, fn);\n\t }\n\n\t function never() {\n\t return false;\n\t }\n\n\t function always() {\n\t return true;\n\t }\n\n\t // make array from array-like objects or from single element (based on bevacqua/atoa)\n\t function makeArray(all, startIndex) {\n\t if (Array.isArray(all)) {\n\t return all;\n\t }\n\t if (all.length) { // is array-like\n\t return Array.prototype.slice.call(all, startIndex); // convert to vanilla js array\n\t } else { // is one element\n\t return [all];\n\t }\n\t }\n\n\t function whichMouseButton (e) {\n\t if (e.touches) { return e.touches.length; }\n\t if (e.originalEvent && e.originalEvent.touches) { return e.originalEvent.touches.length; }\n\t if (e.buttons !== undefined) { return e.buttons; }\n\t if (e.which !== undefined) { return e.which; }\n\t var button = e.button;\n\t if (button !== undefined) { // see https://github.com/jquery/jquery/blob/99e8ff1baa7ae341e94bb89c3e84570c7c3ad9ea/src/event.js#L573-L575\n\t return button & 1 ? 1 : button & 2 ? 3 : (button & 4 ? 2 : 0);\n\t }\n\t }\n\n\t function preventGrabbed(e) {\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t if (shared.grabbed) {\n\t e.preventDefault();\n\t }\n\t }\n\n\t function getScroll(scrollProp, offsetProp) {\n\t if (typeof window[offsetProp] !== 'undefined') {\n\t return window[offsetProp];\n\t }\n\t if (docElm.clientHeight) {\n\t return docElm[scrollProp];\n\t }\n\t return doc.body[scrollProp];\n\t }\n\n\t function getOffset(el) { // watch performance - running each move!\n\t var rect = el.getBoundingClientRect(),\n\t scrollTop = getScroll('scrollTop', 'pageYOffset'),\n\t scrollLeft = getScroll('scrollLeft', 'pageXOffset');\n\t return {\n\t left: rect.left + scrollLeft,\n\t right: rect.right + scrollLeft,\n\t top: rect.top + scrollTop,\n\t bottom: rect.bottom + scrollTop\n\t };\n\t }\n\n\t function getRectWidth(rect) {\n\t return rect.width || (rect.right - rect.left);\n\t }\n\n\t function getRectHeight(rect) {\n\t return rect.height || (rect.bottom - rect.top);\n\t }\n\n\t function getEmptyObject() {\n\t return {};\n\t }\n\n\t function nextEl(el) {\n\t return el.nextElementSibling || manually();\n\n\t function manually() {\n\t var sibling = el;\n\t do {\n\t sibling = sibling.nextSibling;\n\t } while (sibling && sibling.nodeType !== 1);\n\t return sibling;\n\t }\n\t }\n\n\t //Cannot use angular.isElement because we need to check plain dom element, no jQlite wrapped\n\t function isElement(obj) {\n\t return (\n\t typeof HTMLElement === 'object' ? obj instanceof HTMLElement : //DOM2\n\t obj && typeof obj === 'object' && obj !== null && obj.nodeType === 1 && typeof obj.nodeName === 'string'\n\t );\n\t }\n\n\t function lookupClass(className) {\n\t var cached = shared.classesCache[className];\n\t if (cached) {\n\t cached.lastIndex = 0;\n\t } else {\n\t shared.classesCache[className] = cached = new RegExp('(?:^|\\\\s)' + className + '(?:\\\\s|$)', 'g');\n\t }\n\t return cached;\n\t }\n\n\t function addClass(el, className) {\n\t var current = el.className;\n\t if (!current.length) {\n\t el.className = className;\n\t } else if (!lookupClass(className).test(current)) {\n\t el.className += ' ' + className;\n\t }\n\t }\n\n\t function rmClass(el, className) {\n\t el.className = el.className.replace(lookupClass(className), ' ').trim();\n\t }\n\n\t function getEventHost(e) {\n\t // on touchend event, we have to use `e.changedTouches`\n\t // see http://stackoverflow.com/questions/7192563/touchend-event-properties\n\t // see https://github.com/bevacqua/dragula/issues/34\n\t if (e.targetTouches && e.targetTouches.length) {\n\t return e.targetTouches[0];\n\t }\n\t if (e.changedTouches && e.changedTouches.length) {\n\t return e.changedTouches[0];\n\t }\n\t return e;\n\t }\n\n\t function getCoord(coord, e) { // watch performance - running each move several times!\n\t var host = getEventHost(e);\n\t var missMap = {\n\t pageX: 'clientX', // IE8\n\t pageY: 'clientY' // IE8\n\t };\n\t if (coord in missMap && !(coord in host) && missMap[coord] in host) {\n\t coord = missMap[coord];\n\t }\n\n\t // Adding support for touch events, as they are not functional in the original\n\t if (!host.type || host.type.indexOf('touch') < 0) {\n\t return host[coord];\n\t } else {\n\t if (host.type.indexOf('end') === -1) {\n\t // No clientX or clientY in a touch event\n\t return host.originalEvent.touches[0][coord.replace('client', 'page')];\n\t }\n\t // Nothing should happen for touchend\n\t return false;\n\t }\n\t }\n\n\t function getParent (el) { // watch performance - running each move!\n\t return el.parentNode === document ? null : el.parentNode;\n\t }\n\n\t function isInput (el) {\n\t return el.tagName === 'INPUT' || el.tagName === 'TEXTAREA' || el.tagName === 'SELECT' || isEditable(el);\n\t }\n\n\t function isEditable (el) {\n\t if (!el) { return false; } // no parents were editable\n\t if (el.contentEditable === 'false') { return false; } // stop the lookup\n\t if (el.contentEditable === 'true') { return true; } // found a contentEditable element in the chain\n\t return isEditable(getParent(el)); // contentEditable is set to 'inherit'\n\t }\n\n\t function domIndexOf(child, parent) {\n\t return Array.prototype.indexOf.call(angular.element(parent).children(), child);\n\t }\n\n\t function fireEvent(target, e, extra) { // watch performance - running each move!\n\t if (!target) {\n\t return;\n\t }\n\t shared.extra = extra;\n\t if (target.dispatchEvent) {\n\t target.dispatchEvent(e);\n\t } else {\n\t target.fireEvent('on' + e.eventType, e);\n\t }\n\t }\n\n\t function getBool(prop, args, context){\n\t if(angular.isFunction(prop)){\n\t return !!prop.apply(context || this, args || shared);\n\t }else{\n\t return !!prop;\n\t }\n\t }\n\n\t};\n\n\tdragularService.$inject = ['$rootScope', '$compile'];\n\n\tmodule.exports = dragularService;\n\n\t/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))\n\n/***/ },\n/* 4 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar examplesRouter = function ($stateProvider, $urlRouterProvider) {\n\t $urlRouterProvider.otherwise('/home');\n\n\t var timer,\n\t ctrl = function routerCtrl($state, $stateParams, $timeout) {\n\t // go to install notes by default\n\t if (!$stateParams.link) {\n\t timer = $timeout(function timer() {\n\t $state.go('docs.detail', {\n\t link: 'docsInstall'\n\t });\n\t },0);\n\t }else{\n\t $timeout.cancel(timer);\n\t }\n\t };\n\n\t ctrl.$inject = ['$state', '$stateParams', '$timeout'];\n\n\t $stateProvider\n\t .state('home', {\n\t url: '/home',\n\t templateUrl: 'partials/partial-home.html'\n\t })\n\t .state('docs', {\n\t url: '/docs',\n\t templateUrl: 'partials/partial-docs.html',\n\t controller: ctrl\n\t })\n\t .state('docs.detail', {\n\t url: '/:link',\n\t templateUrl: function($stateParams) {\n\t return $stateParams.link + '/' + $stateParams.link + '.html';\n\t },\n\t controller: ctrl\n\t })\n\t .state('contribute', {\n\t url: '/contribute',\n\t templateUrl: 'partials/partial-contribute.html'\n\t });\n\t};\n\n\texamplesRouter.$inject = ['$stateProvider', '$urlRouterProvider'];\n\n\tmodule.exports = examplesRouter;\n\n\n/***/ },\n/* 5 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar BasicCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService('.containerVertical');\n\t};\n\n\tBasicCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = BasicCtrl;\n\n\n/***/ },\n/* 6 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\tvar BasicModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items1 = [{\n\t content: 'Move me, but you can only drop me in one of these containers.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.items2 = [{\n\t content: 'Item 5'\n\t }, {\n\t content: 'Item 6'\n\t }, {\n\t content: 'Item 7'\n\t }, {\n\t content: 'Item 8'\n\t }];\n\t var containers = $element.children().eq(0).children();\n\t dragularService.cleanEnviroment();\n\t dragularService([containers[0],containers[1]],{\n\t containersModel: [$scope.items1, $scope.items2]\n\t });\n\t};\n\n\tBasicModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = BasicModelCtrl;\n\n\n/***/ },\n/* 7 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar BoundingBoxCtrl = function ($element, dragularService) {\n\t var boundingBox = $element[0];\n\t dragularService.cleanEnviroment();\n\n\t dragularService($element.children(), {\n\t boundingBox: boundingBox\n\t });\n\t};\n\n\tBoundingBoxCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = BoundingBoxCtrl;\n\n\n/***/ },\n/* 8 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar BoundingBoxLockXCtrl = function ($element, dragularService) {\n\t var boundingBox = $element.children().children()[0];\n\t dragularService.cleanEnviroment();\n\t dragularService(boundingBox, {\n\t boundingBox: boundingBox,\n\t lockX: true\n\t });\n\t};\n\n\tBoundingBoxLockXCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = BoundingBoxLockXCtrl;\n\n\n/***/ },\n/* 9 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar BoundingBoxLockYCtrl = function ($element, dragularService) {\n\t var boundingBox = $element.children().children()[0];\n\t dragularService.cleanEnviroment();\n\t dragularService(boundingBox, {\n\t boundingBox: boundingBox,\n\t lockY: true\n\t });\n\t};\n\n\tBoundingBoxLockYCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = BoundingBoxLockYCtrl;\n\n\n/***/ },\n/* 10 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar CopyCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children(), {\n\t copy: true\n\t });\n\t};\n\n\tCopyCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = CopyCtrl;\n\n\n/***/ },\n/* 11 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar CopyModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items1 = [{\n\t content: 'Move me, and make copy on drop.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.items2 = [{\n\t content: 'Item 5'\n\t }, {\n\t content: 'Item 6'\n\t }, {\n\t content: 'Item 7'\n\t }, {\n\t content: 'Item 8'\n\t }];\n\t var containers = $element.children().eq(0).children();\n\t dragularService.cleanEnviroment();\n\t dragularService([containers[0],containers[1]],{\n\t containersModel: [$scope.items1, $scope.items2],\n\t copy: true\n\t });\n\t};\n\n\tCopyModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = CopyModelCtrl;\n\n\n/***/ },\n/* 12 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar CustomClassesCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children(), {\n\t classes: {\n\t mirror: 'custom-green-mirror'\n\t }\n\t });\n\t};\n\n\tCustomClassesCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = CustomClassesCtrl;\n\n\n/***/ },\n/* 13 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar DifferentOptionsModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items1 = [{\n\t content: 'Move me, but you can only drop me in one of these containers.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.items2 = [{\n\t content: 'Item 5'\n\t }, {\n\t content: 'Item 6'\n\t }, {\n\t content: 'Item 7'\n\t }, {\n\t content: 'Item 8'\n\t }];\n\n\t var containerLeft = document.querySelector('#containerLeft'),\n\t containerRight = document.querySelector('#containerRight');\n\n\t function accepts(el, target, source) {\n\t // left->right || in same container\n\t if (source === containerLeft || source === target) {\n\t return true;\n\t }\n\t }\n\n\t dragularService.cleanEnviroment();\n\t dragularService([containerLeft], {\n\t containersModel: [$scope.items1],\n\t copy: true,\n\t copySortSource: true,\n\t //move only from left to right\n\t accepts: accepts\n\t });\n\n\t dragularService([containerRight], {\n\t containersModel: [$scope.items2],\n\t removeOnSpill: true,\n\t //move only from left to right\n\t accepts: accepts\n\t });\n\n\t};\n\n\tDifferentOptionsModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = DifferentOptionsModelCtrl;\n\n\n/***/ },\n/* 14 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar DirectiveCtrl = function ($scope) {\n\t $scope.dragularOptions = {\n\t classes: {\n\t mirror: 'custom-green-mirror'\n\t },\n\t nameSpace: 'same' // just connecting left and right container\n\t };\n\t};\n\n\tDirectiveCtrl.$inject = ['$scope'];\n\n\tmodule.exports = DirectiveCtrl;\n\n\n/***/ },\n/* 15 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar DirectiveModelCtrl = function ($scope) {\n\t $scope.items1 = [{\n\t content: 'Move me, and make copy on drop.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.items2 = [{\n\t content: 'Item 5'\n\t }, {\n\t content: 'Item 6'\n\t }, {\n\t content: 'Item 7'\n\t }, {\n\t content: 'Item 8'\n\t }];\n\t $scope.dragularOptions = {\n\t containersModel: $scope.items1,\n\t classes: {\n\t mirror: 'custom-green-mirror'\n\t },\n\t nameSpace: 'common' // just connecting left and right container\n\t };\n\t};\n\n\tDirectiveModelCtrl.$inject = ['$scope'];\n\n\tmodule.exports = DirectiveModelCtrl;\n\n\n/***/ },\n/* 16 */\n/***/ function(module, exports) {\n\n\t/* global angular */\n\t'use strict';\n\n\tvar DragOverEventsCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService([$element.children()[0], $element.children()[2]], {\n\t nameSpace: 'apples'\n\t });\n\t dragularService([$element.children()[1], $element.children()[3]], {\n\t nameSpace: 'oranges'\n\t });\n\n\t // containers events handling\n\t function registerEvents(el) {\n\t el.on('dragularenter', function(e) {\n\t if (el[0] === e.target) { // filter bubbled\n\t el.addClass(dragularService.shared.extra ? 'gu-over-accept' : 'gu-over-decline');\n\t }\n\t });\n\t el.on('dragularleave dragularrelease', function(e) {\n\t if ((el[0] === e.target && // filter bubbled\n\t dragularService.shared.extra && // extra on dragleave contains element the drag is leaving to\n\t dragularService.shared.extra.parentElement !== e.target) || // is that element child of this container?\n\t e.type === 'dragularrelease') {\n\t el.removeClass('gu-over-accept');\n\t el.removeClass('gu-over-decline');\n\t }\n\t });\n\t }\n\n\t angular.forEach($element.children(), function forEachChild(el) {\n\t registerEvents(angular.element(el));\n\t });\n\n\t // notContainer events handling\n\t var notContainer = angular.element(document.getElementsByClassName('notContainer'));\n\t notContainer.on('dragularenter', function() {\n\t notContainer.addClass('gu-over');\n\t });\n\t notContainer.on('dragularleave dragularrelease', function() {\n\t notContainer.removeClass('gu-over');\n\t });\n\t};\n\n\tDragOverEventsCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = DragOverEventsCtrl;\n\n\n/***/ },\n/* 17 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar EventsCtrl = function ($scope, $element, dragularService, $timeout) {\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children(), {\n\t scope: $scope\n\t });\n\t $scope.$on('dragulardrag', function(e, el) {\n\t e.stopPropagation();\n\t el.className = el.className.replace(' ex-moved', '');\n\t });\n\t $scope.$on('dragulardrop', function(e, el) {\n\t e.stopPropagation();\n\t $timeout(function() {\n\t el.className += ' ex-moved';\n\t }, 0);\n\t });\n\n\t $scope.$on('dragularcloned', myFn('cloned'));\n\t $scope.$on('dragulardrag', myFn('drag'));\n\t $scope.$on('dragularcancel', myFn('cancel'));\n\t $scope.$on('dragulardrop', myFn('drop'));\n\t $scope.$on('dragularremove', myFn('remove'));\n\t $scope.$on('dragulardragend', myFn('dragend'));\n\t $scope.$on('dragularshadow', myFn('shadow'));\n\n\t function myFn(eventName) {\n\t return function() {\n\t console.log(eventName, arguments);\n\t };\n\t }\n\t};\n\n\tEventsCtrl.$inject = ['$scope', '$element', 'dragularService', '$timeout'];\n\n\tmodule.exports = EventsCtrl;\n\n\n/***/ },\n/* 18 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar HandleCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t\tdragularService($element.children(), {\n\t moves: function(el, container, handle) {\n\t return handle.className === 'handle';\n\t }\n\t });\n\t};\n\n\tHandleCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = HandleCtrl;\n\n\n/***/ },\n/* 19 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar IsContainerModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items1 = [{\n\t content: 'Move me, but you can only drop me in one of these containers.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.cartModel = [];\n\n\t var containerLeft = document.querySelector('#containerLeft');\n\n\t dragularService.cleanEnviroment();\n\t dragularService([containerLeft], {\n\t containersModel: [$scope.items1],\n\t copy: true,\n\t isContainer: function isContainer (el) {\n\t return el.id === 'cart';\n\t },\n\t isContainerModel: function getModel (){\n\t return $scope.cartModel;\n\t }\n\t });\n\n\t $scope.removeItem = function removeItem() {\n\t var index = $scope.cartModel.indexOf(this.item);\n\t $scope.cartModel.splice(index, 1);\n\t };\n\t};\n\n\tIsContainerModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = IsContainerModelCtrl;\n\n\n/***/ },\n/* 20 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NameSpacesCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService([$element.children()[0], $element.children()[2]], {\n\t nameSpace: 'apples'\n\t });\n\t dragularService($element.children()[1], {\n\t nameSpace: 'oranges'\n\t });\n\t dragularService($element.children()[3], { // mixed\n\t nameSpace: ['oranges', 'apples']\n\t });\n\t};\n\n\tNameSpacesCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = NameSpacesCtrl;\n\n\n/***/ },\n/* 21 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NestedNgRepeatCtrl = function ($timeout, $scope, $element, dragularService) {\n\t $timeout(function() { // timeount due to ngRepeat to be ready\n\t dragularService.cleanEnviroment();\n\t dragularService($element, {\n\t nameSpace: 'rows',\n\t moves: function rowOnly (el, container, handle) {\n\t return handle.classList.contains('row-handle');\n\t }\n\t });\n\n\t dragularService($element.children(), {\n\t nameSpace: 'cells',\n\t moves: function excludeHandle (el, container, handle) {\n\t return !handle.classList.contains('row-handle');\n\t }\n\t });\n\t }, 0);\n\t $scope.items = [{\n\t items: [{\n\t content: 'Item a1'\n\t }, {\n\t content: 'Item a2'\n\t }, {\n\t content: 'Item a3'\n\t }, {\n\t content: 'Item a4'\n\t }]\n\t }, {\n\t items: [{\n\t content: 'Item b1'\n\t }, {\n\t content: 'Item b2'\n\t }, {\n\t content: 'Item b3'\n\t }, {\n\t content: 'Item b4'\n\t }]\n\t }, {\n\t items: [{\n\t content: 'Item c1'\n\t }, {\n\t content: 'Item c2'\n\t }, {\n\t content: 'Item c3'\n\t }, {\n\t content: 'Item c4'\n\t }]\n\t }];\n\t};\n\n\tNestedNgRepeatCtrl.$inject = ['$timeout', '$scope', '$element', 'dragularService'];\n\n\tmodule.exports = NestedNgRepeatCtrl;\n\n\n/***/ },\n/* 22 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NestedNgRepeatWithModelCtrl = function ($timeout, $scope, $element, dragularService) {\n\t $timeout(function() { // timeount due to nested ngRepeat to be ready\n\t var container = $element.children().eq(0).children(),\n\t parentContainers = container.children(),\n\t nestedContainers = [];\n\n\t dragularService.cleanEnviroment();\n\t dragularService(container, {\n\t moves: function(el, container, handle) {\n\t return handle.classList.contains('row-handle');\n\t },\n\t containersModel: $scope.items,\n\t nameSpace: 'rows'\n\t });\n\n\t // collect nested contianers\n\t for (var i = 0; i < parentContainers.length; i++) {\n\t nestedContainers.push(parentContainers.eq(i).children()[1]);\n\t }\n\n\t dragularService(nestedContainers, {\n\t moves: function(el, container, handle) {\n\t return !handle.classList.contains('row-handle');\n\t },\n\t containersModel: (function getNestedContainersModel(){\n\t var parent = $scope.items,\n\t containersModel = [];\n\t for (var i = 0; i < parent.length; i++) {\n\t containersModel.push(parent[i].items);\n\t }\n\t return containersModel;\n\t })(),\n\t nameSpace: 'cells'\n\t });\n\t }, 0);\n\t $scope.items = [{\n\t items: [{\n\t content: 'Item a1'\n\t }, {\n\t content: 'Item a2'\n\t }, {\n\t content: 'Item a3'\n\t }, {\n\t content: 'Item a4'\n\t }]\n\t }, {\n\t items: [{\n\t content: 'Item b1'\n\t }, {\n\t content: 'Item b2'\n\t }, {\n\t content: 'Item b3'\n\t }, {\n\t content: 'Item b4'\n\t }]\n\t }, {\n\t items: [{\n\t content: 'Item c1'\n\t }, {\n\t content: 'Item c2'\n\t }, {\n\t content: 'Item c3'\n\t }, {\n\t content: 'Item c4'\n\t }]\n\t }];\n\t};\n\n\tNestedNgRepeatWithModelCtrl.$inject = ['$timeout', '$scope', '$element', 'dragularService'];\n\n\tmodule.exports = NestedNgRepeatWithModelCtrl;\n\n\n/***/ },\n/* 23 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NgRepeatCtrl = function ($scope, $element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children());\n\t $scope.items = [{\n\t content: 'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.'\n\t }, {\n\t content: 'Item 2'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.addItem = function addItem() {\n\t var index = $scope.items.indexOf(this.item) + 1;\n\t $scope.items.splice(index, 0, {\n\t content: this.item.content + '-copy'\n\t });\n\t };\n\t $scope.removeItem = function removeItem() {\n\t var index = $scope.items.indexOf(this.item);\n\t $scope.items.splice(index, 1);\n\t };\n\t};\n\n\tNgRepeatCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = NgRepeatCtrl;\n\n\n/***/ },\n/* 24 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NgRepeatWithModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items = [{\n\t content: 'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.'\n\t }, {\n\t content: 'Item 2'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children().eq(0).children(), {containersModel: $scope.items});\n\t $scope.addItem = function addItem() {\n\t var index = $scope.items.indexOf(this.item) + 1;\n\t $scope.items.splice(index, 0, {\n\t content: this.item.content + '-copy'\n\t });\n\t };\n\t $scope.removeItem = function removeItem() {\n\t var index = $scope.items.indexOf(this.item);\n\t $scope.items.splice(index, 1);\n\t };\n\t};\n\n\tNgRepeatWithModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = NgRepeatWithModelCtrl;\n\n\n/***/ },\n/* 25 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar RemoveOnSpillCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t\tdragularService($element.children(), {\n\t removeOnSpill: true\n\t });\n\t};\n\n\tRemoveOnSpillCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = RemoveOnSpillCtrl;\n\n\n/***/ },\n/* 26 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar RemoveOnSpillWithModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items1 = [{\n\t content: 'Move me, but you can only drop me in containers.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than containers, I\\'ll die a fiery death.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.items2 = [{\n\t content: 'You can drop me in the left container.'\n\t }, {\n\t content: 'Item 6'\n\t }, {\n\t content: 'Item 7'\n\t }, {\n\t content: 'Item 8'\n\t }];\n\t var containers = $element.children().eq(0).children();\n\t dragularService.cleanEnviroment();\n\t dragularService([containers[0], containers[1]], {\n\t containersModel: [$scope.items1, $scope.items2],\n\t removeOnSpill: true\n\t });\n\t};\n\n\tRemoveOnSpillWithModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = RemoveOnSpillWithModelCtrl;\n\n\n/***/ },\n/* 27 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar RevertOnSpillCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children(), {\n\t revertOnSpill: true\n\t });\n\t};\n\n\tRevertOnSpillCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = RevertOnSpillCtrl;\n\n\n/***/ },\n/* 28 */\n/***/ function(module, exports) {\n\n\t/* global angular */\n\t'use strict';\n\n\tvar ScrollingDragCtrl = function ($interval, $element, dragularService) {\n\t var timer,\n\t leftScrollContainer = document.getElementById('leftScroll'),\n\t rightScrollContainer = document.getElementById('rightScroll'),\n\t leftTopBar = document.getElementById('leftTopBar'),\n\t leftBottomBar = document.getElementById('leftBottomBar'),\n\t rightTopBar = document.getElementById('rightTopBar'),\n\t rightBottomBar = document.getElementById('rightBottomBar');\n\n\t dragularService.cleanEnviroment();\n\t dragularService([leftScrollContainer, rightScrollContainer]);\n\n\t registerEvents(leftTopBar, leftScrollContainer, -5);\n\t registerEvents(leftBottomBar, leftScrollContainer, 5);\n\t registerEvents(rightTopBar, rightScrollContainer, -5);\n\t registerEvents(rightBottomBar, rightScrollContainer, 5);\n\n\t function registerEvents(bar, container, inc, speed) {\n\t if (!speed) {\n\t speed = 20;\n\t }\n\t angular.element(bar).on('dragularenter', function() {\n\t container.scrollTop += inc;\n\t timer = $interval(function moveScroll() {\n\t container.scrollTop += inc;\n\t }, speed);\n\t });\n\t angular.element(bar).on('dragularleave dragularrelease', function() {\n\t $interval.cancel(timer);\n\t });\n\t }\n\t};\n\n\tScrollingDragCtrl.$inject = ['$interval', '$element', 'dragularService'];\n\n\tmodule.exports = ScrollingDragCtrl;\n\n\n/***/ },\n/* 29 */\n/***/ function(module, exports) {\n\n\t'use strict'; module.exports = angular.module(\"templates\", []).run([\"$templateCache\", function($templateCache) {$templateCache.put(\"docsInstall/docsInstall.html\",\"

Install

\\n

download dragular.js and dragular.css from dist folder

\\n

OR clone git

\\n
\\ngit clone http://github.com/luckylooke/dragular.git\\n
\\n

OR use npm

\\n
\\n[sudo] npm install dragular\\n
\\n

OR use bower

\\n
\\nbower install dragular\\n
\\n

AND include files into your project

\\n
\\n<link href=\\'styles/dragular.css\\' rel=\\'stylesheet\\' type=\\'text/css\\' />\\n<script src=\\'scripts/dragular.js\\'></script>\\n
\\n

AND put dragularModule into dependency array

\\n
\\nvar app = angular.module(\\'myApp\\', [\\'dragularModule\\', \\'otherDependencies\\']);\\n
\\n

DONE :)

\\n\");\n\t$templateCache.put(\"exampleBasicWithModel/exampleBasicWithModel.html\",\"
\\n

Basic - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n          
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n          
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  controller(\\'BasicModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items1 = [{\\n      content: \\'Move me, but you can only drop me in one of these containers.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'Item 5\\'\\n    }, {\\n      content: \\'Item 6\\'\\n    }, {\\n      content: \\'Item 7\\'\\n    }, {\\n      content: \\'Item 8\\'\\n    }];\\n    var containers = $element.children().children();\\n    dragularService([containers[0],containers[1]],{\\n      containersModel: [$scope.items1, $scope.items2]\\n    });\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="Basic">\\n    <div class=\\'tableRow\\'>\\n        <div class=\\'containerVertical\\'>\\n            <div ng-repeat="item in items1">{{item.content}}</div>\\n        </div>\\n        <div class=\\'containerVertical\\'>\\n            <div ng-repeat="item in items2">{{item.content}}</div>\\n        </div>\\n    </div>\\n    <div class="tableRow">\\n        <div class="container">\\n            <div>Items1:\\n                <br/>{{items1 | json}}</div>\\n        </div>\\n        <div class="container">\\n            <div>Items2:\\n                <br/>{{items2 | json}}</div>\\n        </div>\\n    </div>\\n</div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleBasic/exampleBasic.html\",\"
\\n

Basic

\\n \\n
\\n
\\n
Move me, but you can only drop me in one of these containers.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
Try to click me, dragular distinguish drag from click
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n// JS\\n  controller(\\'Basic\\', [\\'$element\\', \\'dragularService\\', function TodoCtrl($element, dragularService) {\\n    dragularService(\\'.containerVertical\\');\\n  }])\\n        \\n        \\n// CSS\\n.clickedClass {\\n  background-color: orange !important;\\n}\\n        \\n        \\n<!-- HTML -->\\n  <div class=\\'wrapper\\' ng-controller="Basic">\\n    <div class=\\'containerVertical\\'>\\n        <div>Move me, but you can only drop me in one of these containers.</div>\\n        <div>If you try to drop me somewhere other than these containers, I\\'ll just come back.</div>\\n        <div>Item 3.</div>\\n        <div>Item 6.</div>\\n    </div>\\n    <div class=\\'containerVertical\\'>\\n        <div>You can drop me in the left container, otherwise I\\'ll stay here.</div>\\n        <div ng-click=\\\"clicked = !clicked\\\" ng-class=\\\"clicked && \\'clickedClass\\'\\\">Try to click me, dragular distinguish drag from click</div>\\n        <div>Item 5.</div>\\n    </div>\\n</div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleBoundingBox/exampleBoundingBox.html\",\"
\\n

BoundingBox

\\n \\n
\\n
\\n
This items cannot cross its example element, just try it your selves.
\\n
Item 2.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
This items cannot cross its example element, just try it your selves.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n  dragularService([$element.children(), {\\n    boundingBox: $element\\n  });\\n        \\n      
\\n
\");\n\t$templateCache.put(\"exampleBoundingBoxLockX/exampleBoundingBoxLockX.html\",\"
\\n

BoundingBox and lockX

\\n \\n
\\n
\\n
\\n
Items are locked in X axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
\\n
item 2
\\n
item 3
\\n
item 4
\\n
\\n
\\n
\\n
\\n        \\n  dragularService([$element.children()[0].children(), {\\n    boundingBox: $element.children()[0],\\n    lockX: true\\n  });\\n        \\n      
\\n
\");\n\t$templateCache.put(\"exampleBoundingBoxLockY/exampleBoundingBoxLockY.html\",\"
\\n

BoundingBox and LockY

\\n \\n
\\n
\\n
\\n
Items are locked in Y axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
\\n
item 2
\\n
item 3
\\n
item 4
\\n
item 5
\\n
item 6
\\n
\\n
\\n
\\n
\\n        \\n  dragularService([$element.children()[0].children(), {\\n    boundingBox: $element.children()[0],\\n    lockY: true\\n  });\\n        \\n      
\\n
\");\n\t$templateCache.put(\"exampleCopy/exampleCopy.html\",\"
\\n

Copy

\\n \\n
\\n
\\n
Move me, and make copy on drop.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
\\n
\\n
\\n        \\n// JS\\n  controller(\\'Copy\\', [\\'$element\\', \\'dragularService\\', function TodoCtrl($element, dragularService) {\\n    dragularService($element.children(), {\\n      copy: true\\n    });\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="Copy" ng-hide="globals.showModelExamples">\\n    <div id=\\'left2\\' class=\\'containerVertical\\'>\\n      <div>Move me, and make copy on drop.</div>\\n      <div>If you try to drop me somewhere other than these containers, I\\'ll just come back.</div>\\n    </div>\\n    <div id=\\'right2\\' class=\\'containerVertical\\'>\\n      <div>You can drop me in the left container, otherwise I\\'ll stay here.</div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleCopyWithModel/exampleCopyWithModel.html\",\"
\\n

Copy - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  controller(\\'CopyModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items1 = [{\\n      content: \\'Move me, and make copy on drop.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'Item 5\\'\\n    }, {\\n      content: \\'Item 6\\'\\n    }, {\\n      content: \\'Item 7\\'\\n    }, {\\n      content: \\'Item 8\\'\\n    }];\\n    var containers = $element.children().children();\\n    dragularService([containers[0],containers[1]],{\\n      containersModel: [$scope.items1, $scope.items2],\\n      copy: true\\n    });\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="CopyModel" ng-show="globals.showModelExamples">\\n    <div class=\\'tableRow\\'>\\n      <div class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items1">{{item.content}}</div>\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items2">{{item.content}}</div>\\n      </div>\\n    </div>\\n    <div class="tableRow">\\n      <div class="container">\\n        <div>Items1:\\n          <br/>{{items1 | json}}</div>\\n      </div>\\n      <div class="container">\\n        <div>Items2:\\n          <br/>{{items2 | json}}</div>\\n      </div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleCustomClasses/exampleCustomClasses.html\",\"
\\n

Custom classes

\\n \\n
\\n
\\n
Move me, but you can only drop me in one of these containers.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n  dragularService([document.getElementById(left), document.getElementById(right)], { classes: {\\n    mirror: \\'custom-green-mirror\\'\\n  } });\\n\\n  // Default classes are:\\n  option.classes = {\\n    mirror: \\'gu-mirror\\',\\n    hide: \\'gu-hide\\',\\n    unselectable: \\'gu-unselectable\\',\\n    transit: \\'gu-transit\\',\\n    overActive: \\'gu-over-active\\',\\n    overAccepts: \\'gu-over-accept\\',\\n    overDeclines: \\'gu-over-decline\\'\\n  };\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleDifferentOptionsWithModel/exampleDifferentOptionsWithModel.html\",\"
\\n

Different options - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n          
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n          
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  .controller(\\'DifferentOptionsModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items1 = [{\\n      content: \\'Move me, but you can only drop me in one of these containers.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'Item 5\\'\\n    }, {\\n      content: \\'Item 6\\'\\n    }, {\\n      content: \\'Item 7\\'\\n    }, {\\n      content: \\'Item 8\\'\\n    }];\\n\\n    var containerLeft = document.querySelector(\\'#containerLeft\\'),\\n      containerRight = document.querySelector(\\'#containerRight\\');\\n\\n    function accepts(el, target, source) {\\n      if (source === containerLeft || source === target) {\\n        return true;\\n      }\\n    }\\n\\n    dragularService([containerLeft], {\\n      containersModel: [$scope.items1],\\n      copy: true,\\n      //move only from left to right  \\n      accepts: accepts\\n    });\\n\\n    dragularService([containerRight], {\\n      containersModel: [$scope.items2],\\n      removeOnSpill: true,\\n      //move only from left to right  \\n      accepts: accepts\\n    });\\n\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="DifferentOptionsModel">\\n    <div class=\\'tableRow\\'>\\n      <div id="containerLeft" class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items1">{{item.content}}</div>\\n      </div>\\n      <div id="containerRight" class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items2">{{item.content}}</div>\\n      </div>\\n    </div>\\n    <div class="tableRow">\\n      <div class=\\'containerVertical\\'>\\n        <pre>Items1:\\n          <br/>{{items1 | json}}</pre>\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <pre>Items2:\\n          <br/>{{items2 | json}}</pre>\\n      </div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleDirective/exampleDirective.html\",\"
\\n

Directive

\\n \\n
\\n
\\n
Move me, but you can only drop me in one of these containers.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n// JS\\n  controller(\\'Directive\\', [\\'$scope\\', \\'dragularService\\', function TodoCtrl($scope) {\\n    $scope.dragularOptions = {\\n      classes: {\\n        mirror: \\'custom-green-mirror\\'\\n      },\\n      nameSpace: \\'common\\' // just connecting left and right container\\n    };\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="Directive">\\n    <div class=\\'containerVertical\\' dragular="dragularOptions">\\n      <div>Move me, but you can only drop me in one of these containers.</div>\\n      <div>If you try to drop me somewhere other than these containers, I\\'ll just come back.</div>\\n      <div>Item 3.</div>\\n      <div>Item 6.</div>\\n    </div>\\n    <div class=\\'containerVertical\\' dragular=\\'{"classes":{"mirror":"custom-green-mirror"},"nameSpace":"same"}\\'>\\n      <div>You can drop me in the left container, otherwise I\\'ll stay here.</div>\\n      <div>Item 4.</div>\\n      <div>Item 5.</div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleDirectiveWithModel/exampleDirectiveWithModel.html\",\"
\\n

Directive - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n       \\n        \\n// JS\\n  controller(\\'DirectiveModel\\', [\\'$scope\\', function TodoCtrl($scope) {\\n    $scope.items1 = [{\\n      content: \\'Move me, and make copy on drop.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'Item 5\\'\\n    }, {\\n      content: \\'Item 6\\'\\n    }, {\\n      content: \\'Item 7\\'\\n    }, {\\n      content: \\'Item 8\\'\\n    }];\\n    $scope.dragularOptions = {\\n      containersModel: $scope.items1,\\n      classes: {\\n        mirror: \\'custom-green-mirror\\'\\n      },\\n      nameSpace: \\'common\\' // just connecting left and right container\\n    };\\n  }])\\n        \\n        \\n<!-- HTML -->\\n <div class=\\'wrapper\\' ng-controller="DirectiveModel">\\n  <div class=\\'containerVertical\\' dragular="dragularOptions">\\n    <div ng-repeat="item in items1">{{item.content}}</div>\\n  </div>\\n  <div class=\\'containerVertical\\' dragular=\\'{"containersModel":"items2","classes":{"mirror":"custom-green-mirror"},"nameSpace":"common"}\\'>\\n    <div ng-repeat="item in items2">{{item.content}}</div>\\n  </div>\\n</div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleDragOverEvents/exampleDragOverEvents.html\",\"
\\n

Drag-over events

\\n

You can interact with dragging element by litening to dragOver events. Usually you want to containers show wheather they accepts element or not, but you can use it anywhere. DragOver events are: dragenter, dragleave and dragrelease. On dragOver events dragularService reveals several useful properties.

\\n\\n
\\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n
dragularService.shared.itemitem beeing dragged (it is copy of item if copy is enabled via options)
dragularService.shared.sourcesource container item is dragged from
dragularService.shared.sourceModelsource container model representation if model was porvided
dragularService.shared.initialIndexoriginal index of item, can be used to get item model from sourceModel
dragularService.shared.extracontains accepting information (boolean) on dragenter, element drag is leaving to on dragleave and element behind the cursor on dragrelease
\\n
\\n\\n

Try to drag over the not-container too.

\\n
\\n
\\n
apples and oranges cannot be mixed
\\n
apple 2
\\n
apple 3
\\n
apple 4
\\n
\\n
\\n
orange 1
\\n
orange 2
\\n
orange 3
\\n
orange 4
\\n
\\n
\\n
apple 5
\\n
apple 6
\\n
apple 7
\\n
apple 8
\\n
\\n
\\n
orange 5
\\n
orange 6
\\n
orange 7
\\n
orange 8
\\n
\\n
\\n
Test active class on NOT container.
\\n\\n
\\n    \\n<!-- HTML -->\\n  <div class=\\'wrapper\\' ng-controller="DragOverEvents">\\n    <div class=\\'container width25\\'>\\n      <div>apples and oranges cannot be mixed</div>\\n      <div>apple 2</div>\\n      ...\\n    </div>\\n    <div class=\\'container width25\\'>\\n      <div>orange 1</div>\\n      <div>orange 2</div>\\n      ...\\n    </div>\\n    <div class=\\'container width25\\'>\\n      <div>apple 5</div>\\n      <div>apple 6</div>\\n      ...\\n    </div>\\n    <div class=\\'container width25\\'>\\n      <div>orange 5</div>\\n      <div>orange 6</div>\\n      ...\\n    </div>\\n  </div>\\n  <div class="notContainer"> Test active class on NOT container.</div>\\n    \\n  
\\n\\n
\\n    \\n  // CSS\\n  \\n.notContainer.gu-over {\\n  background-color: yellow;\\n}\\n\\n.containerVertical.gu-over-accept {\\n  background-color: green;\\n}\\n\\n.containerVertical.gu-over-decline {\\n  background-color: red;\\n}\\n    \\n  
\\n\\n
\\n    \\n  // JS\\n  controller(\\'DragOverEvents\\', [\\'$element\\', \\'dragularService\\', function TodoCtrl($element, dragularService) {\\n    dragularService.cleanEnviroment();\\n    dragularService([$element.children()[0], $element.children()[2]], {\\n      nameSpace: \\'apples\\'\\n    });\\n    dragularService([$element.children()[1], $element.children()[3]], {\\n      nameSpace: \\'oranges\\'\\n    });\\n\\n    // containers events handling\\n    function registerEvents(el) {\\n      el.on(\\'dragularenter\\', function(e) {\\n        if (el[0] === e.target) { // filter bubbled\\n          el.addClass(dragularService.shared.extra ? \\'gu-over-accept\\' : \\'gu-over-decline\\');\\n        }\\n      });\\n      el.on(\\'dragularleave dragularrelease\\', function(e) {\\n        if ((el[0] === e.target && // filter bubbled\\n          dragularService.shared.extra && // extra on dragleave contains element the drag is leaving to\\n          dragularService.shared.extra.parentElement !== e.target) // is that element child of this container?\\n          || e.type === \\'dragularrelease\\') {\\n          el.removeClass(\\'gu-over-accept\\');\\n          el.removeClass(\\'gu-over-decline\\');\\n        }\\n      });\\n    }\\n\\n    angular.forEach($element.children(), function forEachChild(el) {\\n      registerEvents(angular.element(el));\\n    });\\n\\n    // notContainer events handling\\n    var notContainer = angular.element(document.getElementsByClassName(\\'notContainer\\'));\\n    notContainer.on(\\'dragularenter\\', function() {\\n      notContainer.addClass(\\'gu-over\\');\\n    });\\n    notContainer.on(\\'dragularleave dragularrelease\\', function() {\\n      notContainer.removeClass(\\'gu-over\\');\\n    });\\n  }])\\n    \\n  
\\n
\\n\");\n\t$templateCache.put(\"exampleEvents/exampleEvents.html\",\"
\\n

Events

\\n \\n
\\n
\\n
Move me, but you can only drop me in one of these containers.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n.controller(\\'Events\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', \\'$timeout\\', function TodoCtrl($scope, $element, dragularService, $timeout) {\\n    dragularService($element.children(), {\\n      scope: $scope\\n    });\\n    $scope.$on(\\'dragulardrag\\', function(e, el) {\\n      e.stopPropagation();\\n      el.className = el.className.replace(\\' ex-moved\\', \\'\\');\\n    });\\n    $scope.$on(\\'dragulardrop\\', function(e, el) {\\n      e.stopPropagation();\\n      $timeout(function() {\\n        el.className += \\' ex-moved\\';\\n      }, 0);\\n    });\\n\\n    $scope.$on(\\'dragularcloned\\', myFn(\\'cloned\\'));\\n    $scope.$on(\\'dragulardrag\\', myFn(\\'drag\\'));\\n    $scope.$on(\\'dragularcancel\\', myFn(\\'cancel\\'));\\n    $scope.$on(\\'dragulardrop\\', myFn(\\'drop\\'));\\n    $scope.$on(\\'dragularremove\\', myFn(\\'remove\\'));\\n    $scope.$on(\\'dragulardragend\\', myFn(\\'dragend\\'));\\n    $scope.$on(\\'dragularshadow\\', myFn(\\'shadow\\'));\\n\\n    function myFn(eventName) {\\n      return function() {\\n        console.log(eventName, arguments);\\n      };\\n    }\\n\\n  }]);\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleHandle/exampleHandle.html\",\"
\\n

Handle

\\n \\n
\\n
\\n
+Move me, but you can use the plus sign to drag me around.
\\n
\\n
\\n
\\n
\\n
\\n        \\n  dragularService([document.getElementById(left), document.getElementById(right)], {\\n    moves: function (el, container, handle) {\\n      return handle.className === \\'handle\\';\\n    }\\n  });\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleIsContainerWithModel/exampleIsContainerWithModel.html\",\"
\\n

isContainer - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}\\n
\\n
\\n
\\n
\\n
\\n
Items1:\\n          
{{items1 | json}}
\\n
\\n
\\n
Cart:\\n          
{{cartModel | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  .controller(\\'IsContainerModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items1 = [{\\n      content: \\'Move me, but you can only drop me in one of these containers.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.cartModel = [];\\n\\n    var containerLeft = document.querySelector(\\'#containerLeft\\');\\n\\n    dragularService.cleanEnviroment();\\n    dragularService([containerLeft], {\\n      containersModel: [$scope.items1],\\n      copy: true,\\n      isContainer: function isContainer (el) {\\n        return el.id === \\'cart\\';\\n      },\\n      isContainerModel: function getModel (){\\n        return $scope.cartModel;\\n      }\\n    });\\n\\n    $scope.removeItem = function removeItem() {\\n      var index = $scope.cartModel.indexOf(this.item);\\n      $scope.cartModel.splice(index, 1);\\n    };\\n\\n  }])\\n        \\n        \\n<!-- HTML -->\\n <div class=\\'wrapper\\' ng-controller="IsContainerModel">\\n    <div class=\\'tableRow\\'>\\n      <div id="containerLeft" class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items1">{{item.content}}</div>\\n      </div>\\n      <div id="cart" class=\\'containerVertical\\'>\\n        <div class=\\'cursorDefault\\' ng-repeat="item in cartModel">{{item.content}}\\n        <button class=\\'cursorDefault\\' ng-click="removeItem()">x</button></div>\\n      </div>\\n    </div>\\n    <div class="tableRow">\\n      <div class=\\'containerVertical\\'>\\n        <pre>Items1:\\n          <br/>{{items1 | json}}</pre>\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <pre>Cart:\\n          <br/>{{cartModel | json}}</pre>\\n      </div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleNameSpaces/exampleNameSpaces.html\",\"
\\n

NameSpaces

\\n \\n
\\n
\\n
try to mix oranges and apples
\\n
apple 2
\\n
apple 3
\\n
apple 4
\\n
\\n
\\n
orange 1
\\n
orange 2
\\n
orange 3
\\n
orange 4
\\n
\\n
\\n
apple 5
\\n
apple 6
\\n
apple 7
\\n
apple 8
\\n
\\n
\\n
mixed 1
\\n
mixed 2
\\n
mixed 3
\\n
mixed 4
\\n
\\n
\\n
\\n      \\ndragularService([$element.children()[0], $element.children()[2]], {\\n  nameSpace: \\'apples\\'\\n});\\ndragularService($element.children()[1], {\\n  nameSpace: \\'oranges\\'\\n});\\ndragularService($element.children()[3], { // mixed\\n  nameSpace: [\\'oranges\\', \\'apples\\']\\n});\\n      \\n    
\\n
\");\n\t$templateCache.put(\"exampleNestedNgRepeat/exampleNestedNgRepeat.html\",\"
\\n

Nested ngRepeat

\\n \\n
\\n
\\n
Row {{$index}}
\\n
{{item.content}}
\\n
\\n
\\n
\\n        \\n  // HTML\\n\\n  <div ng-controller="Example15">\\n    <div ng-repeat="item in items" class=\\'exampleRow\\'>\\n      <div class="row-handle">Row {{$index}}</div>\\n      <div ng-repeat="item in item.items" class="exampleCell">{{item.content}}</div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n        \\n  // CSS\\n\\n  .exampleRow {\\n    display: flex;\\n    flex-direction: row;\\n  }\\n\\n  .exampleCell {\\n    flex-grow: 1;\\n  }\\n\\n  .exampleRow,\\n  .exampleCell {\\n    margin: 10px;\\n    padding: 10px;\\n    background-color: rgba(0, 0, 0, 0.2);\\n    cursor: move;\\n    cursor: grab;\\n    cursor: -moz-grab;\\n    cursor: -webkit-grab;\\n  }\\n        \\n      
\\n
\\n        \\n  // JS\\n\\n  .controller(\\'NestedNgRepeat\\', [\\'$timeout\\', \\'$scope\\', \\'$element\\', \\'dragularService\\', function NestedNgRepeatCtrl($timeout, $scope, $element, dragularService) {\\n    $timeout(function() { // timeount due to ngRepeat to be ready\\n      dragularService($element, {\\n        nameSpace: \\'rows\\',\\n        moves: function rowOnly (el, container, handle) {\\n          return handle.classList.contains(\\'row-handle\\');\\n        }\\n      });\\n      dragularService($element.children(), {\\n        nameSpace: \\'cells\\',\\n        moves: function excludeHandle (el, container, handle) {\\n          return !handle.classList.contains(\\'row-handle\\');\\n        }\\n      });\\n    }, 0);\\n    $scope.items = [{\\n      items: [{\\n        content: \\'Item a1\\'\\n      }, {\\n        content: \\'Item a2\\'\\n      }, {\\n        content: \\'Item a3\\'\\n      }, {\\n        content: \\'Item a4\\'\\n      }]\\n    }, {\\n      items: [{\\n        content: \\'Item b1\\'\\n      }, {\\n        content: \\'Item b2\\'\\n      }, {\\n        content: \\'Item b3\\'\\n      }, {\\n        content: \\'Item b4\\'\\n      }]\\n    }, {\\n      items: [{\\n        content: \\'Item c1\\'\\n      }, {\\n        content: \\'Item c2\\'\\n      }, {\\n        content: \\'Item c3\\'\\n      }, {\\n        content: \\'Item c4\\'\\n      }]\\n    }];\\n  }])\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleNestedNgRepeatWithModel/exampleNestedNgRepeatWithModel.html\",\"
\\n

Nested ngRepeat - with model

\\n \\n
\\n
\\n
\\n
\\n
Row {{::$index}}
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n            
Items:\\n
{{items | json}}
\\n
\\n
\\n
\\n
\\n
\\n    \\n<!-- HTML -->\\n<div ng-controller="NestedNgRepeatWithModel">\\n  <div class=\\'containerVertical\\'>\\n    <div ng-repeat="item in items" class=\\'exampleRow\\'>\\n      <div class="row-handle">Row {{::$index}}</div>\\n      <div class="exampleRow exampleCell containerNested">\\n        <div ng-repeat="item in item.items" class="exampleCell">{{item.content}}</div>\\n      </div>\\n    </div>\\n  </div>\\n</div>\\n    \\n  
\\n
\\n    \\n  // CSS\\n\\n  .exampleRow {\\n    display: flex;\\n    flex-direction: row;\\n  }\\n\\n  .exampleCell {\\n    flex-grow: 1;\\n  }\\n\\n  .exampleRow,\\n  .exampleCell {\\n    margin: 10px;\\n    padding: 10px;\\n    background-color: rgba(0, 0, 0, 0.2);\\n    cursor: move;\\n    cursor: grab;\\n    cursor: -moz-grab;\\n    cursor: -webkit-grab;\\n  }\\n    \\n  
\\n
\\n    \\n  // JS\\n.controller(\\'NestedNgRepeatWithModel\\', [\\'$timeout\\', \\'$scope\\', \\'$element\\', \\'dragularService\\', function NestedNgRepeatWithModelCtrl($timeout, $scope, $element, dragularService) {\\n    $timeout(function() { // timeount due to nested ngRepeat to be ready\\n      var container = $element.children().eq(0).children(),\\n        parentContainers = container.children(),\\n        nestedContainers = [];\\n\\n      dragularService(container, {\\n        moves: function(el, container, handle) {\\n          return handle.classList.contains(\\'row-handle\\');\\n        },\\n        containersModel: $scope.items,\\n        nameSpace: \\'rows\\'\\n      });\\n\\n      // collect nested contianers\\n      for (var i = 0; i < parentContainers.length; i++) {\\n        nestedContainers.push(parentContainers.eq(i).children()[1]);\\n      }\\n\\n      dragularService(nestedContainers, {\\n        moves: function(el, container, handle) {\\n          return !handle.classList.contains(\\'row-handle\\');\\n        },\\n        containersModel: (function getNestedContainersModel(){\\n          var parent = $scope.items,\\n            containersModel = [];\\n          for (var i = 0; i < parent.length; i++) {\\n            containersModel.push(parent[i].items);\\n          }\\n          return containersModel;\\n        })(),\\n        nameSpace: \\'cells\\'\\n      });\\n    }, 0);\\n    $scope.items = [{\\n      items: [{\\n        content: \\'Item a1\\'\\n      }, {\\n        content: \\'Item a2\\'\\n      }, {\\n        content: \\'Item a3\\'\\n      }, {\\n        content: \\'Item a4\\'\\n      }]\\n    }, {\\n      items: [{\\n        content: \\'Item b1\\'\\n      }, {\\n        content: \\'Item b2\\'\\n      }, {\\n        content: \\'Item b3\\'\\n      }, {\\n        content: \\'Item b4\\'\\n      }]\\n    }, {\\n      items: [{\\n        content: \\'Item c1\\'\\n      }, {\\n        content: \\'Item c2\\'\\n      }, {\\n        content: \\'Item c3\\'\\n      }, {\\n        content: \\'Item c4\\'\\n      }]\\n    }];\\n  }])\\n    \\n  
\\n
\\n\");\n\t$templateCache.put(\"exampleNgRepeat/exampleNgRepeat.html\",\"
\\n

ngRepeat

\\n \\n
\\n
\\n
\\n {{item.content}}\\n
\\n
\\n
\\n
\\n        \\n  // HTML:\\n  <div class=\\'containerVertical\\'>\\n    <div ng-repeat="item in items">\\n      {{item.content}}\\n    </div>\\n  </div>\\n\\n  // JS:\\n  dragularService($element.children());\\n  $scope.items = [{\\n    content: \\'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.\\'\\n  },{\\n    content: \\'Item 2\\'\\n  },{\\n    content: \\'Item 3\\'\\n  },{\\n    content: \\'Item 4\\'\\n  }];\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel.html\",\"
\\n

Filtered ngRepeat - with model

\\n \\n
\\n
\\n
\\n \\n
\\n
\\n \\n
\\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n          
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n          
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  .controller(\\'NgRepeatFilteredWithModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', \\'$filter\\', function TodoCtrl($scope, $element, dragularService, $filter) {\\n    $scope.items1 = [{\\n      content: \\'Move me, but you can only drop me in one of these containers.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Apple 3\\'\\n    }, {\\n      content: \\'Orange 4\\'\\n    }, {\\n      content: \\'Orange 5\\'\\n    }, {\\n      content: \\'Apple 6\\'\\n    }, {\\n      content: \\'Apple 7\\'\\n    }, {\\n      content: \\'Apple 8\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'Apple 9\\'\\n    }, {\\n      content: \\'Orange 10\\'\\n    }, {\\n      content: \\'Orange 11\\'\\n    }, {\\n      content: \\'Apple 12\\'\\n    }, {\\n      content: \\'Orange 13\\'\\n    }, {\\n      content: \\'Apple 14\\'\\n    }];\\n    $scope.filter1query = \\'Orange\\';\\n    $scope.filter2query = \\'Orange\\';\\n    $scope.filteredModel1 = [];\\n    $scope.filteredModel2 = [];\\n    $scope.getFilteredModel = function (filteredModel, items, filterQuery) {\\n      filteredModel.length = 0;\\n      /*\\n      * Following one-liner is same like:\\n      *   var filteredModelTemp = $filter(\\'filter\\')(items, filterQuery);\\n      *   angular.forEach(filteredModelTemp, function(item){\\n      *     filteredModel.push(item);\\n      *   });\\n      * Or like:\\n      *   var filteredModelTemp = $filter(\\'filter\\')(items, filterQuery);\\n      *   for(var i; i < filteredModelTemp.length; i++){\\n      *     filteredModel.push(filteredModelTemp[i]);\\n      *   }\\n      *\\n      * You cannot just assign filtered array to filteredModel like this:\\n      *   filteredModel = $filter(\\'filter\\')(items, filterQuery);\\n      * Because you would replace the array object you provide to dragular with new one.\\n      * So dragular will continue to use the one it was provided on init.\\n      * Hopefully I make it clear. :)\\n       */\\n      [].push.apply(filteredModel, $filter(\\'filter\\')(items, filterQuery));\\n      return filteredModel;\\n    };\\n    var containers = $element.children().eq(1).children();\\n    dragularService.cleanEnviroment();\\n    dragularService([containers[0],containers[1]],{\\n      containersModel: [$scope.items1, $scope.items2],\\n      containersFilteredModel: [$scope.filteredModel1, $scope.filteredModel2]\\n    });\\n  }]);\\n\\n        \\n        \\n<!-- HTML -->\\n  <div class=\\'wrapper\\' ng-controller="NgRepeatFilteredWithModel">\\n    <div class="tableRow">\\n      <div class=\\'containerVertical\\'>\\n        <input ng-model="filter1query" style="margin:10px 10px">\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <input ng-model="filter2query" style="margin:10px 10px">\\n      </div>\\n    </div>\\n    <div class=\\'tableRow\\'>\\n      <div class=\\'containerVertical\\'>\\n        <div ng-repeat="item in getFilteredModel(filteredModel1, items1, filter1query)">{{item.content}}</div>\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <div ng-repeat="item in getFilteredModel(filteredModel2, items2, filter2query)">{{item.content}}</div>\\n      </div>\\n    </div>\\n    <div class="tableRow">\\n      <div class=\\'containerVertical\\'>\\n        <pre>Items1:\\n          <br/>{{items1 | json}}</pre>\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <pre>Items2:\\n          <br/>{{items2 | json}}</pre>\\n      </div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleNgRepeatWithModel/exampleNgRepeatWithModel.html\",\"
\\n

ngRepeat - with model

\\n \\n
\\n
\\n
\\n
\\n {{item.content}}\\n \\n \\n
\\n
\\n
\\n
\\n
\\n
Items:\\n
{{items | json}}
\\n
\\n
\\n
\\n
\\n    \\n  // HTML:\\n   <div class=\\'wrapper\\' ng-controller="NgRepeatWithModel">\\n      <div class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items">\\n          {{item.content}}\\n          <button class=\\'cursorDefault\\' ng-click="addItem()">+</button>\\n          <button class=\\'cursorDefault\\' ng-click="removeItem()">x</button>\\n        </div>\\n    </div>\\n  </div>\\n    \\n  
\\n
\\n    \\n  // JS:\\n  controller(\\'NgRepeatWithModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items = [{\\n      content: \\'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.\\'\\n    }, {\\n      content: \\'Item 2\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    dragularService($element.children().eq(0).children(), {containersModel: $scope.items});\\n    $scope.addItem = function addItem() {\\n      var index = $scope.items.indexOf(this.item) + 1;\\n      $scope.items.splice(index, 0, {\\n        content: this.item.content + \\'-copy\\'\\n      });\\n    };\\n    $scope.removeItem = function removeItem() {\\n      var index = $scope.items.indexOf(this.item);\\n      $scope.items.splice(index, 1);\\n    };\\n  }])\\n    \\n  
\\n
\\n\");\n\t$templateCache.put(\"exampleRemoveOnSpill/exampleRemoveOnSpill.html\",\"
\\n

Remove on spill

\\n \\n
\\n
\\n
Move me, but you can only drop me in containers.
\\n
If you try to drop me somewhere other than containers, I\\'ll die a fiery death.
\\n
Item 3.
\\n
Item 6.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
You can drop me in the left container.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n  dragularService([document.getElementById(single)], { removeOnSpill: true });\\n        \\n      
\\n
\");\n\t$templateCache.put(\"exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel.html\",\"
\\n

Remove on spill - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n          
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n          
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  .controller(\\'RemoveOnSpillWithModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items1 = [{\\n      content: \\'Move me, but you can only drop me in containers.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than containers, I\\\\\\'ll die a fiery death.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'You can drop me in the left container.\\'\\n    }, {\\n      content: \\'Item 6\\'\\n    }, {\\n      content: \\'Item 7\\'\\n    }, {\\n      content: \\'Item 8\\'\\n    }];\\n    var containers = $element.children().eq(0).children();\\n    dragularService.cleanEnviroment();\\n    dragularService([containers[0],containers[1]],{\\n      containersModel: [$scope.items1, $scope.items2],\\n      removeOnSpill: true\\n    });\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="Basic">\\n    <div class=\\'tableRow\\'>\\n        <div class=\\'containerVertical\\'>\\n            <div ng-repeat="item in items1">{{item.content}}</div>\\n        </div>\\n        <div class=\\'containerVertical\\'>\\n            <div ng-repeat="item in items2">{{item.content}}</div>\\n        </div>\\n    </div>\\n    <div class="tableRow">\\n        <div class="container">\\n            <div>Items1:\\n                <br/>{{items1 | json}}</div>\\n        </div>\\n        <div class="container">\\n            <div>Items2:\\n                <br/>{{items2 | json}}</div>\\n        </div>\\n    </div>\\n</div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleRevertOnSpill/exampleRevertOnSpill.html\",\"
\\n

Revert on spill

\\n \\n
\\n
\\n
Move me, but you can only drop me in one of these containers.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n  dragularService([document.getElementById(left), document.getElementById(right)], { revertOnSpill: true });\\n        \\n      
\\n
\");\n\t$templateCache.put(\"exampleScrollingDrag/exampleScrollingDrag.html\",\"
\\n

Scrolling drag

\\n \\n
\\n
\\n
up
\\n
\\n
Item 1.
\\n
Item 2.
\\n
Item 3.
\\n
Item 4.
\\n
Item 5.
\\n
Item 6.
\\n
Item 7.
\\n
Item 9.
\\n
Item 10.
\\n
Item 11.
\\n
Item 12.
\\n
Item 13.
\\n
\\n
down
\\n
\\n
\\n
\\n
\\n
Item 1.
\\n
Item 2.
\\n
Item 3.
\\n
Item 4.
\\n
Item 5.
\\n
Item 6.
\\n
Item 7.
\\n
Item 9.
\\n
Item 10.
\\n
Item 11.
\\n
Item 12.
\\n
Item 13.
\\n
\\n
\\n
\\n
\\n
\\n        \\n// JS\\ncontroller(\\'ScrollingDrag\\', [\\'$interval\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($interval, $element, dragularService) {\\n\\n\\n    var timer,\\n      leftScrollContainer = document.getElementById(\\'leftScroll\\'),\\n      rightScrollContainer = document.getElementById(\\'rightScroll\\'),\\n      leftTopBar = document.getElementById(\\'leftTopBar\\'),\\n      leftBottomBar = document.getElementById(\\'leftBottomBar\\'),\\n      rightTopBar = document.getElementById(\\'rightTopBar\\'),\\n      rightBottomBar = document.getElementById(\\'rightBottomBar\\');\\n\\n    dragularService.cleanEnviroment();\\n    dragularService([leftScrollContainer, rightScrollContainer]);\\n\\n    registerEvents(leftTopBar, leftScrollContainer, -5);\\n    registerEvents(leftBottomBar, leftScrollContainer, 5);\\n    registerEvents(rightTopBar, rightScrollContainer, -5);\\n    registerEvents(rightBottomBar, rightScrollContainer, 5);\\n\\n    function registerEvents(bar, container, inc, speed) {\\n      if (!speed) {\\n        speed = 20;\\n      }\\n      angular.element(bar).on(\\'dragularenter\\', function() {\\n        container.scrollTop += inc;\\n        timer = $interval(function moveScroll() {\\n          container.scrollTop += inc;\\n        }, speed);\\n      });\\n      angular.element(bar).on(\\'dragularleave dragularrelease\\', function() {\\n        $interval.cancel(timer);\\n      });\\n    }\\n  }])\\n        \\n      
\\n
\\n        \\n<!-- HTML -->\\n<div ng-controller="ScrollingDrag">\\n    <div class="containerVertical scrollingDrag">\\n      <div class="scrollBar" id="leftTopBar">up</div>\\n      <div id="leftScroll" class="scrollingDragInner">\\n        <div>Item 1</div>\\n        <div>Item 2</div>\\n            ...\\n      </div>\\n      <div class="scrollBar" id="leftBottomBar">down</div>\\n    </div>\\n    <div class="containerVertical scrollingDrag">\\n      <div class="scrollBar" id="rightTopBar">up</div>\\n      <div id="rightScroll" class="scrollingDragInner">\\n        <div>Item 1</div>\\n        <div>Item 2</div>\\n            ...\\n      </div>\\n      <div class="scrollBar" id="rightBottomBar">down</div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n        \\n// CSS\\n.scrollingDrag {\\n  width: 45%;\\n  display: inline-block;\\n}\\n\\n.scrollingDragInner {\\n  max-height: 200px;\\n  overflow-y: auto;\\n}\\n\\n#rightTopBar,\\n#rightBottomBar {\\n  background: transparent;\\n  position: relative;\\n  height: 20px;\\n}\\n\\n#rightTopBar {\\n  top: 10px;\\n}\\n\\n#rightBottomBar {\\n  bottom: 10px;\\n}\\n\\ndiv.scrollBar {\\n  background: yellow;\\n  text-align: center;\\n  padding: 1px;\\n}\\n\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"partials/partial-contribute.html\",\"
\\n
\\n
\\n \\n
\\n
\\n
\\n\");\n\t$templateCache.put(\"partials/partial-docs.html\",\"
\\n
\\n
\\n \\n
\\n \\n
\\n

\\n \\n

\\n \\n
\\n
\\n \\n
\\n \\n
\\n\");\n\t$templateCache.put(\"partials/partial-home.html\",\"
\\n
\\n \\n
\\n
\\n

DRAGULAR

\\n

Angular drag&drop based on dragula.

\\n

Live examples in docs

\\n
\\n
\\n
\\n

Browser support includes every sane browser and **IE7+**. _(Granted you polyfill the functional `Array` methods in ES5)_

\\n

Inspiration

\\n

I am working on huge angular project and I am using several drag&drop libraries in it, one for UI, one for lists, etc.. I want to use one full-featured drag&drop library for whole project. As I could not find any suitable, I decided to create one. I have choosen great library dragula by Nicolas Bevacqua as my starting point, make it more angular and started to put features in it! If you wish light-weight angular version of dragula, there is official angular version of dragula.

\\n

Actual version 4.1.0 is based on dragula 3.6.3 and tested with angular 1.4.9.

\\n

Differences of dragular (against dragula)

\\n
    \\n
  • replaced dragula crossvent with angulars event binding
  • \\n
  • replaced dragula contra.emitter with $scope.$emit if scope provided in options (options.scope)
  • \\n
  • provided as service or directive dragular where options can be passed via atribute dragular
  • \\n
  • automatic direction if not provided in options, instead of default vertical
  • \\n
  • accepting arraylike objects as containers array (jQuery, jQlite collections etc..)
  • \\n
  • accepting custom classes via option.classes
  • \\n
  • namespaced containers groups available via option.nameSpace (containers in same nameSpace cooperate)
  • \\n
  • boundingBox (dragging element can me moved only in specific area)
  • \\n
  • lockX/Y (dragging element can me moved only in specific direction)
  • \\n
  • DOM can be synced with scope model
  • \\n
  • support css selectors to define containers
  • \\n
  • added syntax highlighter to example codes
  • \\n
  • etc..
  • \\n
\\n

Todo

\\n
    \\n
  • improve docs
  • \\n
\\n

Features

\\n
    \\n
  • provided as service and also as directive
  • \\n
  • Super easy to set up
  • \\n
  • No bloated dependencies
  • \\n
  • Figures out sort order on its own
  • \\n
  • A shadow where the item would be dropped offers visual feedback
  • \\n
  • Touch events!
  • \\n
\\n

For installation, usage and examples go to docs

\\n
\\n
\\n \\n
\\n \\n
\\n \\n
\\n\");\n\t$templateCache.put(\"partials/autogenerated/contribute.html\",\"

How to contribute

\\n

It's important to us that you feel you can contribute towards the evolution of Dragular. This can take many forms: from helping to fix bugs or improve the docs, to adding in new features to the source. This guide should help you in making that process as smooth as possible.

\\n

Before contributing, please read the code of conduct.

\\n

Reporting issues

\\n

GitHub Issues is the place to report bugs you may have found in either the core library or any of the examples that are part of the repository. When submitting a bug please do the following:

\\n

1. Search for existing issues. Your bug may have already been fixed or addressed in a development branch version of Dragular, so be sure to search the issues first before putting in a duplicate issue.

\\n

2. Not sure if it's a bug?. Then please ask via issues and tag it [question].

\\n

3. Create an isolated and reproducible test case. If you are reporting a bug, make sure you also have a minimal, runnable, code example that reproduces the problem you have.

\\n

4. Include a live example. After narrowing your code down to only the problem areas, make use of jsFiddle, jsBin, or a link to your live site so that we can view a live example of the problem. (you can start by forking this fiddle)

\\n

5. Share as much information as possible. Include browser version affected, your OS, version of the library, steps to reproduce, etc. "X isn't working!!!1!" will probably just be closed.

\\n

Dev vs. Master

\\n

The dev branch of Dragular is our 'current working' version. It is always ahead of the master branch in terms of features and fixes. However it's also bleeding-edge and experimental and we cannot and do not guarantee it will compile or work for you. Very often we have to break things for a few days while we rebuild and patch. So by all means please export the dev branch and contribute towards it, indeed that is where all Pull Requests should be sent, but do so understanding the API may change beneath you.

\\n

Making Changes

\\n

To take advantage of our npm build script and jshint config it will be easiest for you if you have node.js installed locally.

\\n

You can download node.js from nodejs.org.

\\n

After that you can clone the repository and run npm i inside the cloned folder. This will install dependencies necessary for building the project. For development workflow automation dragular uses gulp >= 3.9.0. Before starting development, make sure that gulp is installed on your machine globally: npm i -g gulp.

\\n

Developing

\\n

There are several gulp tasks that are used for generating different builds:

\\n
    \\n
  • gulp dev - Serves files with BrowserSync server, watches & automatically refreshes connected browsers on changes, generates non-minified but concatenated styles & scripts from the dragular source.
  • \\n
  • gulp dev:docs - Does exactly the same as gulp dev, except it works with the documentation source.
  • \\n
  • gulp build - Concatenates and minifies dragular source files.
  • \\n
  • gulp build:docs - Concatenates and minifies documentation source files.
  • \\n
\\n

Linting

\\n
    \\n
  • gulp lint & gulp lint:docs - Lint JavaScript files.
  • \\n
\\n

Making a pull request

\\n

Once that is ready, make your changes and submit a Pull Request:

\\n
    \\n
  • Send Pull Requests to the dev branch. All Pull Requests must be sent to the dev branch, master is the latest release and PRs to that branch will be closed.

    \\n
  • \\n
  • Ensure changes are jshint validated. Our JSHint configuration file is provided in the repository and you should check against it before submitting.

    \\n
  • \\n
  • Only commit relevant changes. Don't include changes that are not directly relevant to the fix you are making. The more focused a PR is, the faster it will get attention and be merged. Extra files changing only whitespace or trash files will likely get your PR closed.

    \\n
  • \\n
\\n

Dependencies for building from source and running tests:

\\n

Coding style preferences are not contributions

\\n

If your PR is doing little more than changing the Dragular source code into a format / coding style that you prefer then we will automatically close it. All PRs must adhere to the coding style already set-out across the lines of code in Dragular. Your personal preferences for how things should "look" or be structured do not apply here, sorry. PRs should fix bugs, fix documentation or add features. No changes for the sake of change.

\\n

I don't really like git / node.js, but I can fix this bug

\\n

That is fine too. While Pull Requests are the best thing in the world for us, they are not the only way to help. You're welcome to post fixes to our forum or even just email them to us. All we ask is that you still adhere to the guidelines presented here re: JSHint, etc.

\\n\");}]);\n\n/***/ }\n/******/ ]);"],"sourceRoot":"/source/"} \ No newline at end of file +{"version":3,"sources":["examples.js"],"names":["root","factory","exports","module","define","amd","a","i","this","modules","__webpack_require__","moduleId","installedModules","id","loaded","call","m","c","p","dragular","examplesRouter","BasicCtrl","BasicModelCtrl","BoundingBoxCtrl","BoundingBoxLockXCtrl","BoundingBoxLockYCtrl","CopyCtrl","CopyModelCtrl","CustomClassesCtrl","DifferentOptionsModelCtrl","DirectiveCtrl","DirectiveModelCtrl","DragOverEventsCtrl","EventsCtrl","HandleCtrl","IsContainerModelCtrl","NameSpacesCtrl","NestedNgRepeatCtrl","NestedNgRepeatWithModelCtrl","NgRepeatCtrl","NgRepeatFilteredWithModelCtrl","NgRepeatWithModelCtrl","RemoveOnSpillCtrl","RemoveOnSpillWithModelCtrl","RevertOnSpillCtrl","ScrollingDragCtrl","angular","config","controller","$scope","examplesList","template","link","title","highlightCode","document","getElementsByTagName","length","codeBlocks","hljs","highlightBlock","rowOffcanvas","toggleSidebar","element","getElementById","toggleClass","dragularDirective","dragularService","directive","restrict","iElm","iAttrs","tryJson","json","JSON","parse","e","drake","options","$eval","containersModel","dynamicModelAttribute","$watch","dragularModel","newVal","sanitizeContainersModel","dragularNameSpace","nameSpace","split","dragularOnInit","onInit","$inject","global","shared","classesCache","containersCtx","containers","mirror","source","item","copy","sourceItem","sourceModel","sourceFilteredModel","target","targetCtx","targetModel","lastDropTarget","offsetX","offsetY","moveX","moveY","offsetXr","offsetYb","clientX","clientY","mirrorWidth","mirrorHeight","initialSibling","currentSibling","initialIndex","currentIndex","tempModel","dragOverEvents","lastElementBehindCursor","grabbed","$rootScope","$compile","service","arg0","arg1","Array","isArray","processServiceArguments","arguments","isElement","initialContainers","querySelectorAll","o","copyOptions","extendOptions","tmp","extend","defaultOptions","classes","defaultClasses","eventNames","defaultEventNames","processOptionsObject","boundingBox","makeArray","containersFilteredModel","forEach","len","shLen","getContainersModel","fm","registerEvents","remove","op","regEvent","docElm","release","container","grab","name","eventName","doc","createEvent","initEvent","createEventObject","eventType","whichMouseButton","metaKey","ctrlKey","context","canStart","eventualMovements","type","isInput","focus","preventDefault","ungrab","dragging","originalEvent","getCoord","elementBehindCursor","getElementBehindPoint","dropTarget","findDropTarget","g","copySortSource","drop","removeOnSpill","cancel","fireEvent","dragularrelease","scope","$emit","isContainer","el","indexOf","isContainerModel","removeContainers","all","$applyAsync","changes","index","splice","startBecauseMouseMoved","movements","preventGrabbed","destroy","ignoreInputTextSelection","elementFromPoint","end","start","direction","getParent","parent","parentNode","parentHeight","offsetHeight","parentWidth","offsetWidth","childHeight","clientHeight","childWidth","clientWidth","offset","getOffset","left","top","right","bottom","addClass","transit","renderMirrorImage","style","drag","handle","invalid","moves","nextEl","manualStart","cloneNode","dragularcloned","containerIndex","domIndexOf","dragulardrag","afterDrop","compileItemOnDrop","content","removeChild","insertBefore","isInitialPlacement","dragularcancel","dragulardrop","dropIndex","cleanup","dropElmModel","dontCopyModel","dragularremove","revert","reverts","revertOnSpill","initial","removeMirrorImage","rmClass","spillOut","dragularout","dragulardragend","s","sibling","accepted","accepts","immediate","getImmediateChild","reference","getReference","dragularCommon","canBeAccepted","moved","spillOver","pageX","pageY","offsetBox","x","y","lockY","lockX","changed","dragularenter","dragularleave","dragularshadow","hide","scrollContainer","before","scrollTop","deltaY","stopPropagation","rect","getBoundingClientRect","width","height","getRectWidth","getRectHeight","mirrorContainer","appendChild","body","unselectable","outside","children","horizontal","inside","resolve","after","point","state","className","getBool","dragularover","never","getEmptyObject","always","fn","touch","mouseup","mousedown","mousemove","pointers","microsoft","$el","navigator","pointerEnabled","msPointerEnabled","startIndex","prototype","slice","touches","undefined","buttons","which","button","getScroll","scrollProp","offsetProp","window","scrollLeft","manually","nextSibling","nodeType","nextElementSibling","obj","HTMLElement","nodeName","lookupClass","cached","lastIndex","RegExp","current","test","replace","trim","getEventHost","targetTouches","changedTouches","coord","host","missMap","tagName","isEditable","contentEditable","child","extra","dispatchEvent","prop","args","isFunction","apply","documentElement","cleanEnviroment","$stateProvider","$urlRouterProvider","otherwise","timer","ctrl","$state","$stateParams","$timeout","go","url","templateUrl","$element","items1","items2","eq","containerLeft","querySelector","containerRight","dragularOptions","on","parentElement","removeClass","notContainer","getElementsByClassName","myFn","$on","cartModel","removeItem","classList","contains","items","parentContainers","nestedContainers","push","addItem","$filter","filter1query","filter2query","filteredModel1","filteredModel2","getFilteredModel","filteredModel","filterQuery","$interval","bar","inc","speed","leftScrollContainer","rightScrollContainer","leftTopBar","leftBottomBar","rightTopBar","rightBottomBar","run","$templateCache","put"],"mappings":"CAAA,SAA2CA,EAAMC,GAChD,GAAsB,gBAAZC,UAA0C,gBAAXC,QACxCA,OAAOD,QAAUD,QACb,IAAqB,kBAAXG,SAAyBA,OAAOC,IAC9CD,UAAWH,OACP,CACJ,GAAIK,GAAIL,GACR,KAAI,GAAIM,KAAKD,IAAuB,gBAAZJ,SAAuBA,QAAUF,GAAMO,GAAKD,EAAEC,KAErEC,KAAM,WACT,MAAgB,UAAUC,GAKhB,QAASC,GAAoBC,GAG5B,GAAGC,EAAiBD,GACnB,MAAOC,GAAiBD,GAAUT,OAGnC,IAAIC,GAASS,EAAiBD,IAC7BT,WACAW,GAAIF,EACJG,QAAQ,EAUT,OANAL,GAAQE,GAAUI,KAAKZ,EAAOD,QAASC,EAAQA,EAAOD,QAASQ,GAG/DP,EAAOW,QAAS,EAGTX,EAAOD,QAvBf,GAAIU,KAqCJ,OATAF,GAAoBM,EAAIP,EAGxBC,EAAoBO,EAAIL,EAGxBF,EAAoBQ,EAAI,GAGjBR,EAAoB,KAK/B,SAASP,EAAQD,EAASQ,GAG/B,YAIA,IAAIS,GAAWT,EAAoB,GAC/BU,EAAiBV,EAAoB,GACrCW,EAAYX,EAAoB,GAChCY,EAAiBZ,EAAoB,GACrCa,EAAkBb,EAAoB,GACtCc,EAAuBd,EAAoB,GAC3Ce,EAAuBf,EAAoB,GAC3CgB,EAAWhB,EAAoB,IAC/BiB,EAAgBjB,EAAoB,IACpCkB,EAAoBlB,EAAoB,IACxCmB,EAA4BnB,EAAoB,IAChDoB,EAAgBpB,EAAoB,IACpCqB,EAAqBrB,EAAoB,IACzCsB,EAAqBtB,EAAoB,IACzCuB,EAAavB,EAAoB,IACjCwB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D;AAClFD,EAAeC,IAAI,2CAA2C,yjEAC9DD,EAAeC,IAAI,mDAAmD,wxFACtED,EAAeC,IAAI,qEAAqE,u6HACxFD,EAAeC,IAAI,uCAAuC,0+BAC1DD,EAAeC,IAAI,yEAAyE,sgKAC5FD,EAAeC,IAAI,yDAAyD,+lEAC5ED,EAAeC,IAAI,mEAAmE,gkFACtFD,EAAeC,IAAI,iDAAiD,ulCACpED,EAAeC,IAAI,iDAAiD,6sCACpED,EAAeC,IAAI,iDAAiD,04IACpED,EAAeC,IAAI,mCAAmC,kMACtDD,EAAeC,IAAI,6BAA6B,2wBAChDD,EAAeC,IAAI,6BAA6B,yuGAChDD,EAAeC,IAAI,yCAAyC","file":"examples.min.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse {\n\t\tvar a = factory();\n\t\tfor(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];\n\t}\n})(this, function() {\nreturn /******/ (function(modules) { // webpackBootstrap\n/******/ \t// The module cache\n/******/ \tvar installedModules = {};\n\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId])\n/******/ \t\t\treturn installedModules[moduleId].exports;\n\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\texports: {},\n/******/ \t\t\tid: moduleId,\n/******/ \t\t\tloaded: false\n/******/ \t\t};\n\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.loaded = true;\n\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n\n\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(0);\n/******/ })\n/************************************************************************/\n/******/ ([\n/* 0 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t/* global angular, hljs */\n\t'use strict';\n\n\t// var angular = require('angular');\n\n\tvar dragular = __webpack_require__(1);\n\tvar examplesRouter = __webpack_require__(4);\n\tvar BasicCtrl = __webpack_require__(5);\n\tvar BasicModelCtrl = __webpack_require__(6);\n\tvar BoundingBoxCtrl = __webpack_require__(7);\n\tvar BoundingBoxLockXCtrl = __webpack_require__(8);\n\tvar BoundingBoxLockYCtrl = __webpack_require__(9);\n\tvar CopyCtrl = __webpack_require__(10);\n\tvar CopyModelCtrl = __webpack_require__(11);\n\tvar CustomClassesCtrl = __webpack_require__(12);\n\tvar DifferentOptionsModelCtrl = __webpack_require__(13);\n\tvar DirectiveCtrl = __webpack_require__(14);\n\tvar DirectiveModelCtrl = __webpack_require__(15);\n\tvar DragOverEventsCtrl = __webpack_require__(16);\n\tvar EventsCtrl = __webpack_require__(17);\n\tvar HandleCtrl = __webpack_require__(18);\n\tvar IsContainerModelCtrl = __webpack_require__(19);\n\tvar NameSpacesCtrl = __webpack_require__(20);\n\tvar NestedNgRepeatCtrl = __webpack_require__(21);\n\tvar NestedNgRepeatWithModelCtrl = __webpack_require__(22);\n\tvar NgRepeatCtrl = __webpack_require__(23);\n\tvar NgRepeatFilteredWithModelCtrl = __webpack_require__(24);\n\tvar NgRepeatWithModelCtrl = __webpack_require__(25);\n\tvar RemoveOnSpillCtrl = __webpack_require__(26);\n\tvar RemoveOnSpillWithModelCtrl = __webpack_require__(27);\n\tvar RevertOnSpillCtrl = __webpack_require__(28);\n\tvar ScrollingDragCtrl = __webpack_require__(29);\n\t__webpack_require__(30);\n\n\t/**\n\t * Module Example App\n\t *\n\t * DEMO app for dragular https://github.com/luckylooke/dragular\n\t */\n\n\tangular\n\t .module('examplesApp', [dragular, 'templates', 'ui.router'])\n\t .config(examplesRouter)\n\t .controller('Basic', BasicCtrl)\n\t .controller('BasicModel', BasicModelCtrl)\n\t .controller('BoundingBox', BoundingBoxCtrl)\n\t .controller('BoundingBoxLockX', BoundingBoxLockXCtrl)\n\t .controller('BoundingBoxLockY', BoundingBoxLockYCtrl)\n\t .controller('Copy', CopyCtrl)\n\t .controller('CopyModel', CopyModelCtrl)\n\t .controller('CustomClasses', CustomClassesCtrl)\n\t .controller('DifferentOptionsModel', DifferentOptionsModelCtrl)\n\t .controller('Directive', DirectiveCtrl)\n\t .controller('DirectiveModel', DirectiveModelCtrl)\n\t .controller('DragOverEvents', DragOverEventsCtrl)\n\t .controller('Events', EventsCtrl)\n\t .controller('Handle', HandleCtrl)\n\t .controller('IsContainerModel', IsContainerModelCtrl)\n\t .controller('NameSpaces', NameSpacesCtrl)\n\t .controller('NestedNgRepeat', NestedNgRepeatCtrl)\n\t .controller('NestedNgRepeatWithModel', NestedNgRepeatWithModelCtrl)\n\t .controller('NgRepeat', NgRepeatCtrl)\n\t .controller('NgRepeatFilteredWithModel', NgRepeatFilteredWithModelCtrl)\n\t .controller('NgRepeatWithModel', NgRepeatWithModelCtrl)\n\t .controller('RemoveOnSpill', RemoveOnSpillCtrl)\n\t .controller('RemoveOnSpillWithModel', RemoveOnSpillWithModelCtrl)\n\t .controller('RevertOnSpill', RevertOnSpillCtrl)\n\t .controller('ScrollingDrag', ScrollingDragCtrl)\n\t .controller('ExAppCtrl', ['$scope', function($scope) {\n\t $scope.examplesList = [{\n\t template: 'docsInstall/docsInstall.html',\n\t link: 'docsInstall',\n\t title: 'Installation'\n\t },{\n\t template: 'exampleBasic/exampleBasic.html',\n\t link: 'exampleBasic',\n\t title: 'Basic'\n\t },{\n\t template: 'exampleBasicWithModel/exampleBasicWithModel.html',\n\t link: 'exampleBasicWithModel',\n\t title: 'Basic - with model'\n\t },{\n\t template: 'exampleDifferentOptionsWithModel/exampleDifferentOptionsWithModel.html',\n\t link: 'exampleDifferentOptionsWithModel',\n\t title: 'Different options - with model'\n\t }, {\n\t template: 'exampleDirective/exampleDirective.html',\n\t link: 'exampleDirective',\n\t title: 'Directive'\n\t }, {\n\t template: 'exampleDirectiveWithModel/exampleDirectiveWithModel.html',\n\t link: 'exampleDirectiveWithModel',\n\t title: 'Directive - with model'\n\t }, {\n\t template: 'exampleEvents/exampleEvents.html',\n\t link: 'exampleEvents',\n\t title: 'Events'\n\t }, {\n\t template: 'exampleRemoveOnSpill/exampleRemoveOnSpill.html',\n\t link: 'exampleRemoveOnSpill',\n\t title: 'Remove on spill'\n\t }, {\n\t template: 'exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel.html',\n\t link: 'exampleRemoveOnSpillWithModel',\n\t title: 'Remove on spill - with model'\n\t }, {\n\t template: 'exampleRevertOnSpill/exampleRevertOnSpill.html',\n\t link: 'exampleRevertOnSpill',\n\t title: 'Revert on spill'\n\t }, {\n\t template: 'exampleCopy/exampleCopy.html',\n\t link: 'exampleCopy',\n\t title: 'Copy'\n\t }, {\n\t template: 'exampleCopyWithModel/exampleCopyWithModel.html',\n\t link: 'exampleCopyWithModel',\n\t title: 'Copy - with model'\n\t }, {\n\t template: 'exampleHandle/exampleHandle.html',\n\t link: 'exampleHandle',\n\t title: 'Handle'\n\t }, {\n\t template: 'exampleIsContainerWithModel/exampleIsContainerWithModel.html',\n\t link: 'exampleIsContainerWithModel',\n\t title: 'isContainer - with model'\n\t }, {\n\t template: 'exampleCustomClasses/exampleCustomClasses.html',\n\t link: 'exampleCustomClasses',\n\t title: 'Custom classes'\n\t }, {\n\t template: 'exampleNameSpaces/exampleNameSpaces.html',\n\t link: 'exampleNameSpaces',\n\t title: 'NameSpaces'\n\t }, {\n\t template: 'exampleDragOverEvents/exampleDragOverEvents.html',\n\t link: 'exampleDragOverEvents',\n\t title: 'Drag-over events'\n\t }, {\n\t template: 'exampleBoundingBox/exampleBoundingBox.html',\n\t link: 'exampleBoundingBox',\n\t title: 'BoundingBox'\n\t }, {\n\t template: 'exampleBoundingBoxLockX/exampleBoundingBoxLockX.html',\n\t link: 'exampleBoundingBoxLockX',\n\t title: 'BoundingBox + LockX'\n\t }, {\n\t template: 'exampleBoundingBoxLockY/exampleBoundingBoxLockY.html',\n\t link: 'exampleBoundingBoxLockY',\n\t title: 'BoundingBox + LockY'\n\t }, {\n\t template: 'exampleNgRepeat/exampleNgRepeat.html',\n\t link: 'exampleNgRepeat',\n\t title: 'ngRepeat'\n\t }, {\n\t template: 'exampleNgRepeatWithModel/exampleNgRepeatWithModel.html',\n\t link: 'exampleNgRepeatWithModel',\n\t title: 'ngRepeat - with model'\n\t }, {\n\t template: 'exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel.html',\n\t link: 'exampleNgRepeatFilteredWithModel',\n\t title: 'Filtered ngRepeat - with model'\n\t }, {\n\t template: 'exampleNestedNgRepeat/exampleNestedNgRepeat.html',\n\t link: 'exampleNestedNgRepeat',\n\t title: 'Nested ngRepead'\n\t }, {\n\t template: 'exampleNestedNgRepeatWithModel/exampleNestedNgRepeatWithModel.html',\n\t link: 'exampleNestedNgRepeatWithModel',\n\t title: 'Nested ngRepead - with model'\n\t }, {\n\t template: 'exampleScrollingDrag/exampleScrollingDrag.html',\n\t link: 'exampleScrollingDrag',\n\t title: 'Scrolling drag'\n\t }];\n\n\t $scope.highlightCode = function () {\n\t if(document.getElementsByTagName('code').length){\n\t var codeBlocks = document.getElementsByTagName('code');\n\t for (var i = codeBlocks.length - 1; i >= 0; i--) {\n\t hljs.highlightBlock(codeBlocks[i]);\n\t }\n\t }\n\t };\n\n\t var rowOffcanvas;\n\t $scope.toggleSidebar = function toggleSidebar () {\n\t if(!rowOffcanvas){\n\t rowOffcanvas = angular.element(document.getElementById('rowOffcanvas'));\n\t }\n\t rowOffcanvas.toggleClass('active');\n\t };\n\n\t }]);\n\n\n/***/ },\n/* 1 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t/* global angular */\n\t'use strict';\n\tvar dragularDirective = __webpack_require__(2);\n\tvar dragularService = __webpack_require__(3);\n\n\t/**\n\t * Dragular 4.2.0 by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\tmodule.exports = 'dragularModule';\n\n\tangular\n\t .module('dragularModule', [])\n\t .factory('dragularService', dragularService)\n\t .directive('dragular', dragularDirective);\n\n\n/***/ },\n/* 2 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\t/**\n\t * dragular Directive by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\n\tvar dragular = function (dragularService) {\n\t return {\n\t restrict: 'A',\n\t link: function($scope, iElm, iAttrs) {\n\n\t var drake,\n\t options = $scope.$eval(iAttrs.dragular) || tryJson(iAttrs.dragular) || {};\n\n\t function tryJson(json) {\n\t try { // I dont like try catch solutions but I havent find sattisfying way of chcecking json validity.\n\t return JSON.parse(json);\n\t } catch (e) {\n\t return undefined;\n\t }\n\t }\n\n\t if(options && options.containersModel && typeof options.containersModel === 'string'){\n\t options.containersModel = $scope.$eval(options.containersModel);\n\t }\n\n\t if(options && options.dynamicModelAttribute){\n\t // watch for model changes\n\t $scope.$watch(function () {\n\t return $scope.$eval(iAttrs.dragularModel);\n\t }, function (newVal) {\n\t if(newVal){\n\t drake.containersModel = drake.sanitizeContainersModel($scope.$eval(newVal));\n\t }\n\t });\n\t }else if(iAttrs.dragularModel){\n\t // bind once and keep reference\n\t options.containersModel = $scope.$eval(iAttrs.dragularModel);\n\t }\n\n\t if(iAttrs.dragularNameSpace){\n\t options.nameSpace = iAttrs.dragularNameSpace.split(' ');\n\t }\n\n\t if(iAttrs.dragularOnInit){\n\t options.onInit = $scope.$eval(iAttrs.dragularOnInit);\n\t }\n\n\t drake = dragularService(iElm[0], options);\n\t }\n\t };\n\t};\n\n\tdragular.$inject = ['dragularService'];\n\n\tmodule.exports = dragular;\n\n\n/***/ },\n/* 3 */\n/***/ function(module, exports) {\n\n\t/* WEBPACK VAR INJECTION */(function(global) {/* global angular */\n\t'use strict';\n\n\t/**\n\t * dragular Service by Luckylooke https://github.com/luckylooke/dragular\n\t * Angular version of dragula https://github.com/bevacqua/dragula\n\t */\n\n\tvar shared = { // sahred object between all service instances\n\t classesCache: {}, // classes lookup cache\n\t containersCtx: {}, // containers model\n\t containers: {}, // containers\n\t mirror: null, // mirror image\n\t source: null, // source container\n\t item: null, // item being dragged\n\t copy: null, // copy flag\n\t sourceItem: null, // item originaly dragged if copy is enabled\n\t sourceModel: null, // source container model\n\t sourceFilteredModel: null, // source container filtered model if relevant\n\t target: null, // droppable container under drag item\n\t targetCtx: null, // target container context\n\t targetModel: null, // target container model\n\t lastDropTarget: null, // last container item was over\n\t offsetX: null, // reference x\n\t offsetY: null, // reference y\n\t moveX: null, // reference move x\n\t moveY: null, // reference move y\n\t offsetXr: null, // reference x right for boundingBox feature\n\t offsetYb: null, // reference y bottom for boundingBox feature\n\t clientX: null, // cache client x, init at grab, update at drag\n\t clientY: null, // cache client y, init at grab, update at drag\n\t mirrorWidth: null, // mirror width for boundingBox feature\n\t mirrorHeight: null, // mirror height for boundingBox feature\n\t initialSibling: null, // reference sibling when grabbed\n\t currentSibling: null, // reference sibling now\n\t initialIndex: null, // reference model index when grabbed\n\t currentIndex: null, // reference model index now\n\t tempModel: null, // if o.isContainer is used, model can be provided as well, it is temporary saved here during drags\n\t dragOverEvents: {}, // drag over events fired on element behind cursor\n\t lastElementBehindCursor: null, // last element behind cursor\n\t grabbed: null // holds mousedown context until first mousemove\n\t};\n\n\tvar dragularService = function ($rootScope, $compile) {\n\t // abbreviations\n\t var doc = document,\n\t docElm = doc.documentElement;\n\n\t // clean common/shared objects\n\t service.cleanEnviroment = function cleanEnviroment() {\n\t shared.classesCache = {};\n\t shared.containersCtx = {};\n\t shared.containers = {};\n\t shared.mirror = undefined;\n\t };\n\n\t service.shared = shared;\n\n\t return service;\n\n\t // service definition\n\t function service(arg0, arg1) {\n\t var initialContainers = arg0 || [],\n\t options = arg1 || {},\n\t o, // shorthand for options\n\t g = getBool, // shorthand for getBool\n\t // defaults\n\t defaultClasses = {\n\t mirror: 'gu-mirror',\n\t hide: 'gu-hide',\n\t unselectable: 'gu-unselectable',\n\t transit: 'gu-transit'\n\t },\n\t defaultEventNames = {\n\t // drag-over DOM events\n\t dragularenter: 'dragularenter',\n\t dragularleave: 'dragularleave',\n\t dragularrelease: 'dragularrelease',\n\t // $scope events\n\t dragularcloned: 'dragularcloned',\n\t dragulardrag: 'dragulardrag',\n\t dragularcancel: 'dragularcancel',\n\t dragulardrop: 'dragulardrop',\n\t dragularremove: 'dragularremove',\n\t dragulardragend: 'dragulardragend',\n\t dragularshadow: 'dragularshadow',\n\t dragularover: 'dragularover',\n\t dragularout: 'dragularout'\n\t },\n\t defaultOptions = { // options with defaults\n\t copyOptions: false, // copy options object when provided\n\t classes: defaultClasses, // classes used by dragular\n\t eventNames: defaultEventNames, // event names used by dragular\n\t containers: false, // initial containers provided via options object (are provided via parameter by default)\n\t containersModel: false, // if provided, model will be synced with DOM\n\t containersFilteredModel: false, // if provided, dragular will handle filtered model cases\n\t isContainer: never, // potential target can be forced to be container by custom logic\n\t isContainerModel: getEmptyObject, // if isContainer function is provided, you can provide also respective model\n\t moves: always, // can drag start?\n\t accepts: always, // can target accept dragged item? (target context used)\n\t canBeAccepted: always, // can be dragged item accepted by target? (source context used)\n\t copy: false, // dragged item will be copy of source? flag or function\n\t copySortSource: false, // enable sorting in source when copying item\n\t dontCopyModel: false, // dont make copy of model when coping item (#61)\n\t invalid: never, // target (in)validity function\n\t revertOnSpill: false, // item returns to original place\n\t removeOnSpill: false, // item will be removed if not placed into valid target\n\t lockX: false, // lock movement into x-axis\n\t lockY: false, // lock movement into y-axis\n\t boundingBox: false, // lock movement inside this element boundaries\n\t mirrorContainer: doc.body, // element for appending mirror\n\t ignoreInputTextSelection: true, // text selection in inputs wont be considered as drag\n\t compileItemOnDrop: false,\n\t onInit: false // function callback called after dragular initialisation and providing drake as first argument\n\t },\n\t drake = {\n\t containers: shared.containers,\n\t containersCtx: shared.containersCtx,\n\t sanitizeContainersModel: sanitizeContainersModel,\n\t isContainer: isContainer,\n\t start: manualStart,\n\t end: end,\n\t cancel: cancel,\n\t remove: remove,\n\t destroy: destroy,\n\t dragging: false\n\t };\n\n\t processServiceArguments(); // both arguments (containers and options) are optional, this function handle this\n\t extendOptions();\n\t processOptionsObject();\n\t registerEvents();\n\t \n\t if(o.onInit){\n\t o.onInit(drake); \n\t }\n\n\t return drake;\n\n\t // Function definitions: ==============================================================================================================\n\t // Initial functions: -----------------------------------------------------------------------------------------------------------------\n\n\t function sanitizeContainersModel(containersModel) {\n\t if (typeof(containersModel) === 'function') {\n\t return containersModel;\n\t }\n\t if (Array.isArray(containersModel)) {\n\t // |-------- is 2D array? -----------|\n\t return Array.isArray(containersModel[0]) ? containersModel : [containersModel];\n\t } else {\n\t return [];\n\t }\n\t }\n\n\t function processServiceArguments(){\n\t if (arguments.length === 1 && // if there is only one argument we need to distinguish if it is options object or container(s) reference\n\t !Array.isArray(arg0) && // array of containers elements\n\t !angular.isElement(arg0) && // one container element\n\t !arg0[0] && // array-like object with containers elements\n\t typeof arg0 !== 'string') { // selector\n\t // then arg0 is options object\n\t options = arg0 || {};\n\t initialContainers = []; // containers are not provided on init\n\t } else if (typeof arg0 === 'string') {\n\t initialContainers = document.querySelectorAll(arg0);\n\t }\n\t o = options.copyOptions ? angular.copy(options) : options;\n\t }\n\n\t function extendOptions(){\n\t var tmp = angular.extend({}, defaultOptions, o); // tmp for keeping defaults untouched\n\t angular.extend(o, tmp); // merge defaults back into options\n\t if(o.classes){\n\t tmp = angular.extend({}, defaultClasses, o.classes);\n\t angular.extend(o.classes, tmp);\n\t }\n\t if(o.eventNames){\n\t tmp = angular.extend({}, defaultEventNames, o.eventNames);\n\t angular.extend(o.eventNames, tmp);\n\t }\n\t }\n\n\t function processOptionsObject(){\n\t // bounding box must be pure DOM element, not jQuery wrapper or something else..\n\t if (!isElement(o.boundingBox)) {\n\t o.boundingBox = false;\n\t }\n\n\t // initial containers provided via options are higher priority then by parameter\n\t if(o.containers){\n\t initialContainers = o.containers;\n\t }\n\t // sanitize initialContainers\n\t initialContainers = makeArray(initialContainers);\n\n\t // sanitize o.containersModel\n\t o.containersModel = sanitizeContainersModel(o.containersModel);\n\n\t // sanitize o.containersFilteredModel\n\t if (Array.isArray(o.containersFilteredModel)) {\n\t // |-------- is 2D array? -----------|\n\t o.containersFilteredModel = Array.isArray(o.containersFilteredModel[0]) ? o.containersFilteredModel : [o.containersFilteredModel];\n\t } else {\n\t o.containersFilteredModel = [];\n\t }\n\n\t // feed containers groups and optionaly do same for models\n\t if (!o.nameSpace) {\n\t o.nameSpace = ['dragularCommon'];\n\t }\n\t if (!Array.isArray(o.nameSpace)) {\n\t o.nameSpace = [o.nameSpace];\n\t }\n\t o.nameSpace.forEach(function eachNameSpace(nameSpace) {\n\t if (!shared.containers[nameSpace]) {\n\t shared.containers[nameSpace] = [];\n\t shared.containersCtx[nameSpace] = [];\n\t }\n\t var len = initialContainers.length,\n\t shLen = shared.containers[nameSpace].length;\n\t for (var i = 0; i < len; i++) {\n\t shared.containers[nameSpace][i + shLen] = initialContainers[i];\n\t shared.containersCtx[nameSpace][i + shLen] = {\n\t o: o,\n\t m: getContainersModel()[i], // can be undefined\n\t fm: o.containersFilteredModel[i] // can be undefined\n\t };\n\t }\n\t });\n\t }\n\n\t function registerEvents(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'mouseup', release);\n\n\t initialContainers.forEach(function addMouseDown(container) {\n\t regEvent(container, 'on', 'mousedown', grab);\n\t });\n\n\t if(!remove){ // create dragular DOM events\n\t angular.forEach(['dragularenter', 'dragularleave', 'dragularrelease'], function prepareDragOverEvents(name) {\n\t var eventName = o.eventNames[name];\n\t if(!shared.dragOverEvents[eventName]){\n\t if (doc.createEvent) {\n\t shared.dragOverEvents[eventName] = doc.createEvent('HTMLEvents');\n\t shared.dragOverEvents[eventName].initEvent(eventName, true, true);\n\t } else {\n\t shared.dragOverEvents[eventName] = doc.createEventObject();\n\t shared.dragOverEvents[eventName].eventType = eventName;\n\t }\n\t }\n\t });\n\t }\n\t }\n\n\t // Event handlers functions (end of initial functions): -----------------------------------------------------------------------------------------------------------------\n\n\t function grab(e) {\n\t // filter some odd situations\n\t if (whichMouseButton(e) !== 1 || e.metaKey || e.ctrlKey) {\n\t return; // we only care about honest-to-god left clicks and touch events\n\t }\n\n\t // set itial values\n\t shared.moveX = e.clientX;\n\t shared.moveY = e.clientY;\n\n\t var context = canStart(e.target);\n\t if (!context || !context.item) {\n\t return;\n\t }\n\n\t shared.grabbed = context;\n\t eventualMovements();\n\t if (e.type === 'mousedown') {\n\t if (isInput(context.item)) { // see also: https://github.com/bevacqua/dragula/issues/208\n\t context.item.focus(); // fixes https://github.com/bevacqua/dragula/issues/176\n\t } else {\n\t e.preventDefault(); // fixes https://github.com/bevacqua/dragula/issues/155\n\t }\n\t }\n\t }\n\n\t function release(e) {\n\t ungrab();\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t var elementBehindCursor = getElementBehindPoint(shared.mirror, shared.clientX, shared.clientY),\n\t dropTarget = findDropTarget(elementBehindCursor, shared.clientX, shared.clientY);\n\n\t if (dropTarget && ((shared.copy && g(o.copySortSource)) || (!shared.copy || dropTarget !== shared.source))) {\n\t // found valid target and (is not copy case or target is not initial container)\n\t drop(shared.item, dropTarget);\n\t } else if (g(o.removeOnSpill)) {\n\t remove();\n\t } else {\n\t cancel();\n\t }\n\n\t // after release there is no container hovered\n\t shared.target = null;\n\n\t if (shared.lastElementBehindCursor) {\n\t fireEvent(shared.lastElementBehindCursor, shared.dragOverEvents.dragularrelease, elementBehindCursor);\n\t }\n\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularrelease, shared.item, shared.source);\n\t }\n\t }\n\n\t // Main logic functions (end of event handler functions): -----------------------------------------------------------------------------------------------------------------\n\n\t function isContainer(el) {\n\t if(!el){\n\t return false;\n\t }\n\t var i = o.nameSpace.length;\n\t while (i--) {\n\t if (shared.containers[o.nameSpace[i]].indexOf(el) !== -1) {\n\t return true;\n\t }\n\t }\n\t if (o.isContainer(el)) {\n\t shared.tempModel = o.isContainerModel(el);\n\t return true;\n\t } else {\n\t shared.tempModel = null;\n\t }\n\t return false;\n\t }\n\n\t function getContainersModel() {\n\t return (typeof(o.containersModel) === 'function') ? sanitizeContainersModel(o.containersModel(drake, shared)) : o.containersModel;\n\t }\n\n\t function removeContainers(all) {\n\t $rootScope.$applyAsync(function applyDestroyed() {\n\t var changes = Array.isArray(all) ? all : makeArray(all);\n\t changes.forEach(function forEachContainer(container) {\n\t angular.forEach(o.nameSpace, function forEachNs(nameSpace) {\n\t var index;\n\t index = shared.containers[nameSpace].indexOf(container);\n\t shared.containers[nameSpace].splice(index, 1);\n\t shared.containersCtx[nameSpace].splice(index, 1);\n\t });\n\t });\n\t });\n\t }\n\n\t function eventualMovements(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'mousemove', startBecauseMouseMoved);\n\t }\n\n\t function movements(remove) {\n\t var op = remove ? 'off' : 'on';\n\t regEvent(docElm, op, 'selectstart', preventGrabbed); // IE8\n\t regEvent(docElm, op, 'click', preventGrabbed);\n\t regEvent(docElm, op, 'touchmove', preventGrabbed); // fixes touch devices scrolling while drag\n\t }\n\n\t function destroy() {\n\t registerEvents(true);\n\t removeContainers(initialContainers);\n\t release({});\n\t }\n\n\t function startBecauseMouseMoved(e) {\n\t if (!shared.grabbed || drake.dragging) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t if (whichMouseButton(e) === 0) {\n\t release({});\n\t return; // when text is selected on an input and then dragged, mouseup doesn't fire. this is our only hope\n\t }\n\t // truthy check fixes dragula-#239, equality fixes dragula-#207\n\t if (e.clientX && e.clientX === shared.moveX && e.clientY && e.clientY === shared.moveY) {\n\t return;\n\t }\n\t if (g(o.ignoreInputTextSelection)) {\n\t var clientX = getCoord('clientX', e),\n\t clientY = getCoord('clientY', e),\n\t elementBehindCursor = doc.elementFromPoint(clientX, clientY);\n\t if (isInput(elementBehindCursor)) {\n\t return;\n\t }\n\t }\n\n\t var grabbed = shared.grabbed; // calling end() unsets shared.grabbed\n\t eventualMovements('remove'); // remove mousemove listener\n\t movements();\n\t end();\n\t start(grabbed);\n\n\t // automaticly detect direction of elements if not set in options\n\t if (!o.direction && getParent(shared.sourceItem)) {\n\t var parent = shared.sourceItem.parentNode,\n\t parentHeight = parent.offsetHeight,\n\t parentWidth = parent.offsetWidth,\n\t childHeight = shared.sourceItem.clientHeight,\n\t childWidth = shared.sourceItem.clientWidth;\n\t o.direction = parentHeight / childHeight < parentWidth / childWidth ? 'horizontal' : 'vertical';\n\t }\n\n\t // get initial coordinates, used to render shared.mirror for first time\n\t var offset = getOffset(shared.sourceItem);\n\t shared.offsetX = getCoord('pageX', e) - offset.left;\n\t shared.offsetY = getCoord('pageY', e) - offset.top;\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t // limiting area of shared.mirror movement, get initial coordinates\n\t if (o.boundingBox) {\n\t shared.offsetXr = getCoord('pageX', e) - offset.right;\n\t shared.offsetYb = getCoord('pageY', e) - offset.bottom;\n\t }\n\n\t e.preventDefault();\n\n\t addClass(shared.item, o.classes.transit);\n\t renderMirrorImage();\n\t // initial position\n\t shared.mirror.style.left = shared.clientX - shared.offsetX + 'px';\n\t shared.mirror.style.top = shared.clientY - shared.offsetY + 'px';\n\n\t drag(e);\n\t }\n\n\t function canStart(item) {\n\t if (drake.dragging && shared.mirror) {\n\t console.log('usecase?');\n\t return; // already dragging\n\t }\n\n\t var handle = item;\n\t while (getParent(item) && !isContainer(getParent(item))) {\n\t // break loop if user tries to drag item which is considered invalid handle\n\t if (o.invalid(item, handle)) {\n\t return;\n\t }\n\t item = getParent(item); // drag target should be immediate child of container\n\t if (!item) {\n\t return;\n\t }\n\t }\n\n\t var source = getParent(item);\n\t if (!source ||\n\t o.invalid(item, handle) ||\n\t !o.moves(item, source, handle, nextEl(item))) {\n\t return;\n\t }\n\n\t return {\n\t item: item,\n\t source: source\n\t };\n\t }\n\n\t function manualStart(item) {\n\t var context = canStart(item);\n\t if (context) {\n\t start(context);\n\t }\n\t }\n\n\t function start(context) {\n\t shared.sourceItem = shared.item = context.item;\n\t shared.source = context.source;\n\t shared.initialSibling = shared.currentSibling = nextEl(context.item);\n\n\t if (g(o.copy, [context.item, context.source])) {\n\t shared.item = context.item.cloneNode(true);\n\t shared.copy = true;\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularcloned, shared.item, context.item);\n\t }\n\t } else {\n\t shared.copy = false;\n\t }\n\n\t // prepare models operations\n\t var containerIndex = initialContainers.indexOf(context.source);\n\t shared.sourceModel = getContainersModel()[containerIndex];\n\n\t shared.sourceFilteredModel = o.containersFilteredModel[containerIndex];\n\t shared.initialIndex = domIndexOf(context.item, context.source);\n\n\t drake.dragging = true;\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragulardrag, shared.sourceItem, shared.source);\n\t }\n\n\t return true;\n\t }\n\n\t function end() {\n\t if (!drake.dragging || !shared.item) {\n\t return;\n\t }\n\t drop(shared.item, getParent(shared.item));\n\t }\n\n\t function ungrab() {\n\t shared.grabbed = false;\n\t eventualMovements('remove');\n\t movements('remove');\n\t }\n\n\t function drop(item, target) {\n\t var sourceItem = shared.sourceItem,\n\t currentSibling = shared.currentSibling;\n\t \n\t if (shared.copy && g(o.copySortSource) && target === shared.source && getParent(item)) {\n\t item.parentNode.removeChild(shared.sourceItem);\n\t }\n\n\t if (shared.sourceModel && !isInitialPlacement(target)) {\n\n\t var dropIndex = domIndexOf(item, target);\n\t if(shared.targetCtx.fm){ // target has filtered model\n\t // convert index from index-in-filteredModel to index-in-model\n\t dropIndex = shared.targetCtx.m.indexOf(shared.targetCtx.fm[dropIndex]);\n\t }\n\t if(shared.sourceFilteredModel){ // target has filtered model\n\t // convert index from index-in-filteredModel to index-in-model\n\t shared.initialIndex = shared.sourceModel.indexOf(shared.sourceFilteredModel[shared.initialIndex]);\n\t }\n\t $rootScope.$applyAsync(function applyDrop() {\n\t if(!shared.sourceModel){\n\t return;\n\t }\n\t if (target === shared.source) {\n\t shared.sourceModel.splice(dropIndex, 0, shared.sourceModel.splice(shared.initialIndex, 1)[0]);\n\t } else {\n\t shared.dropElmModel = shared.copy && !o.dontCopyModel ? angular.copy(shared.sourceModel[shared.initialIndex]) : shared.sourceModel[shared.initialIndex];\n\n\t if (!shared.tempModel) {\n\t shared.targetModel = shared.targetCtx.m;\n\t } else {\n\t shared.targetModel = shared.tempModel;\n\t }\n\t \n\t target.removeChild(item); // element must be removed for ngRepeat to apply correctly\n\n\t if (!shared.copy) {\n\t shared.sourceModel.splice(shared.initialIndex, 1);\n\t }\n\t shared.targetModel.splice(dropIndex, 0, shared.dropElmModel);\n\t }\n\n\t if (getParent(item)) {\n\t item.parentNode.removeChild(item);\n\t }\n\n\t afterDrop();\n\t });\n\t } else {\n\t afterDrop();\n\t }\n\n\t function afterDrop() {\n\t if(o.compileItemOnDrop){\n\t var scope = angular.element(target).scope();\n\t scope.$applyAsync(function(){\n\t var content = $compile(shared.copy ? sourceItem.cloneNode(true) : sourceItem)(scope); \n\t if(item.parentNode === target){\n\t target.removeChild(item);\n\t }\n\t target.insertBefore(content[0], currentSibling);\n\t });\n\t }\n\t \n\t if (o.scope) {\n\t if (isInitialPlacement(target)) {\n\t o.scope.$emit(o.eventNames.dragularcancel, item, shared.source, shared.sourceModel, shared.initialIndex);\n\t } else {\n\t o.scope.$emit(o.eventNames.dragulardrop, item, target, shared.source, shared.sourceModel, shared.initialIndex, shared.targetModel, dropIndex);\n\t }\n\t }\n\t \n\t cleanup();\n\t }\n\t }\n\n\t function remove() {\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t var parent = getParent(shared.item);\n\n\t if (parent) {\n\t parent.removeChild(shared.item);\n\t }\n\n\t if (shared.sourceModel) {\n\t $rootScope.$applyAsync(function removeModel() {\n\t shared.sourceModel.splice(shared.initialIndex, 1);\n\t cleanup();\n\t });\n\t }\n\n\t if (o.scope) {\n\t o.scope.$emit(shared.copy ? o.eventNames.dragularcancel : o.eventNames.dragularremove, shared.item, parent, shared.sourceModel, shared.initialIndex);\n\t }\n\t if (!shared.sourceModel) {\n\t cleanup();\n\t }\n\t }\n\n\t function cancel(revert) {\n\t if (!drake.dragging) {\n\t return;\n\t }\n\t var reverts = arguments.length > 0 ? revert : g(o.revertOnSpill),\n\t parent = getParent(shared.item);\n\n\t var initial = isInitialPlacement(parent);\n\t if (!initial && !shared.copy && reverts) {\n\t shared.source.insertBefore(shared.item, shared.initialSibling);\n\t }\n\t if (shared.sourceModel && !shared.copy && !reverts) {\n\t drop(shared.item, parent);\n\t } else if (o.scope) {\n\t if (initial || reverts) {\n\t o.scope.$emit(o.eventNames.dragularcancel, shared.item, shared.source);\n\t }\n\t }\n\n\t if (!shared.sourceModel || shared.copy || reverts || initial) {\n\t cleanup();\n\t }\n\t }\n\n\t function cleanup() {\n\t ungrab();\n\t removeMirrorImage();\n\n\t if (shared.item) {\n\t rmClass(shared.item, o.classes.transit);\n\t }\n\n\t drake.dragging = false;\n\n\t if (g(o.removeOnSpill) === true) {\n\t spillOut();\n\t }\n\n\t if (o.scope) {\n\t if(shared.lastDropTarget){\n\t o.scope.$emit(o.eventNames.dragularout, shared.item, shared.lastDropTarget, shared.source);\n\t }\n\t o.scope.$emit(o.eventNames.dragulardragend, shared.item);\n\t }\n\n\t shared.source = shared.item = shared.sourceItem = shared.initialSibling = shared.currentSibling = shared.sourceModel = null;\n\t shared.initialIndex = shared.currentIndex = shared.lastDropTarget = shared.tempModel = shared.targetModel = null;\n\t shared.dropElmModel = shared.targetCtx = shared.copy = shared.moveX = shared.moveY = null;\n\t }\n\n\t // is item currently placed in original container and original position?\n\t function isInitialPlacement(target, s) { // watch performance - running each move several times!\n\t var sibling = s || (shared.mirror ? shared.currentSibling : nextEl(shared.item));\n\t return target === shared.source && sibling === shared.initialSibling;\n\t }\n\n\t // find valid drop container\n\t function findDropTarget(elementBehindCursor, clientX, clientY) { // watch performance - running each move!\n\t var target = elementBehindCursor;\n\n\t while (target && !accepted()) {\n\t target = getParent(target);\n\t }\n\t return target;\n\n\t function accepted() {\n\t var accepts = false;\n\n\t if (isContainer(target)) { // is droppable?\n\n\t var immediate = getImmediateChild(target, elementBehindCursor),\n\t reference = getReference(target, immediate, clientX, clientY),\n\t initial = isInitialPlacement(target, reference),\n\t i = o.nameSpace.length;\n\n\t while (i--) {\n\t if (shared.containers[o.nameSpace[i]].indexOf(target) !== -1) {\n\t shared.targetCtx = shared.containersCtx[o.nameSpace[i]][shared.containers[o.nameSpace[i]].indexOf(target)];\n\t break;\n\t }\n\t if (!shared.targetCtx) {\n\t shared.targetCtx = shared.containersCtx.dragularCommon[shared.containers.dragularCommon.indexOf(target)];\n\t }\n\t }\n\n\t accepts = initial ||\n\t (shared.targetCtx.o.accepts(shared.item, target, shared.source, reference, shared.sourceModel, shared.initialIndex) &&\n\t o.canBeAccepted(shared.item, target, shared.source, reference, shared.sourceModel, shared.initialIndex));\n\n\t if (shared.target !== target) { // used for scroll issue\n\t shared.target = target;\n\t }\n\t }\n\t return accepts;\n\t }\n\t }\n\n\t function drag(e) { // watch performance - running each move!\n\t if (!shared.mirror) {\n\t return;\n\t }\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\n\t // update coordinates\n\t shared.clientX = getCoord('clientX', e);\n\t shared.clientY = getCoord('clientY', e);\n\n\t // count mirror coordiates\n\t var x = shared.clientX - shared.offsetX,\n\t y = shared.clientY - shared.offsetY,\n\t pageX,\n\t pageY,\n\t offsetBox;\n\n\t // fill extra properties if boundingBox is used\n\t if (o.boundingBox) {\n\t pageX = getCoord('pageX', e);\n\t pageY = getCoord('pageY', e);\n\t offsetBox = getOffset(o.boundingBox);\n\t }\n\n\t if (!o.lockY) {\n\t if (!o.boundingBox || (pageX > offsetBox.left + shared.offsetX && pageX < offsetBox.right + shared.offsetXr)) {\n\t shared.mirror.style.left = x + 'px';\n\t } else if (o.boundingBox) { // check again in case user scrolled the view\n\t if (pageX < offsetBox.left + shared.offsetX) {\n\t shared.mirror.style.left = shared.clientX - (pageX - offsetBox.left) + 'px';\n\t } else {\n\t shared.mirror.style.left = shared.clientX - shared.mirrorWidth - (pageX - offsetBox.right) + 'px';\n\t }\n\t }\n\t }\n\t if (!o.lockX) {\n\t if (!o.boundingBox || (pageY > offsetBox.top + shared.offsetY && pageY < offsetBox.bottom + shared.offsetYb)) {\n\t shared.mirror.style.top = y + 'px';\n\t } else if (o.boundingBox) { // check again in case user scrolled the view\n\t if (pageY < offsetBox.top + shared.offsetY) {\n\t shared.mirror.style.top = shared.clientY - (pageY - offsetBox.top) + 'px';\n\t } else {\n\t shared.mirror.style.top = shared.clientY - shared.mirrorHeight - (pageY - offsetBox.bottom) + 'px';\n\t }\n\t }\n\t }\n\n\t var elementBehindCursor = getElementBehindPoint(shared.mirror, shared.clientX, shared.clientY),\n\t dropTarget = findDropTarget(elementBehindCursor, shared.clientX, shared.clientY),\n\t changed = dropTarget !== shared.lastDropTarget;\n\n\t if (elementBehindCursor !== shared.lastElementBehindCursor) {\n\t fireEvent(elementBehindCursor, shared.dragOverEvents.dragularenter, !!dropTarget);\n\t if (shared.lastElementBehindCursor) {\n\t fireEvent(shared.lastElementBehindCursor, shared.dragOverEvents.dragularleave, elementBehindCursor);\n\t }\n\t shared.lastElementBehindCursor = elementBehindCursor;\n\t }\n\n\t if (changed) {\n\t if (shared.lastDropTarget) {\n\t moved('out');\n\t }\n\t shared.lastDropTarget = dropTarget;\n\t moved('over');\n\t }\n\n\t // do not copy in same container\n\t if (dropTarget === shared.source && shared.copy && !g(o.copySortSource)) {\n\t if (getParent(shared.item)) {\n\t shared.item.parentNode.removeChild(shared.item);\n\t }\n\t return;\n\t }\n\n\t var reference,\n\t immediate = getImmediateChild(dropTarget, elementBehindCursor);\n\n\t if (immediate !== null) {\n\t reference = getReference(dropTarget, immediate, shared.clientX, shared.clientY);\n\t } else if (g(o.revertOnSpill) === true && !shared.copy) {\n\t // the case that mirror is not over valid target and reverting is on and copy is off\n\t reference = shared.initialSibling;\n\t dropTarget = shared.source;\n\t } else {\n\t // the case that mirror is not over valid target and removing is on or copy is on\n\t if (shared.copy && getParent(shared.item)) {\n\t // remove item or copy of item\n\t shared.item.parentNode.removeChild(shared.item);\n\t }\n\t return;\n\t }\n\n\t if (reference === null ||\n\t reference !== shared.item &&\n\t reference !== nextEl(shared.item) &&\n\t reference !== shared.currentSibling) {\n\t // moving item/copy to new container from previous one\n\t shared.currentSibling = reference;\n\n\t dropTarget.insertBefore(shared.item, reference); // if reference is null item is inserted at the end\n\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularshadow, shared.item, dropTarget);\n\t }\n\t }\n\n\t function moved(type) {\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames['dragular' + type], shared.item, shared.lastDropTarget, shared.source);\n\t }\n\t if (g(o.removeOnSpill) === true) {\n\t type === 'over' ? spillOver() : spillOut();\n\t }\n\t }\n\t }\n\n\t function spillOver() {\n\t rmClass(shared.item, o.classes.hide);\n\t }\n\n\t function spillOut() {\n\t if (drake.dragging) {\n\t addClass(shared.item, o.classes.hide);\n\t }\n\t }\n\n\t function scrollContainer(e) {\n\t if (shared.target) {\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t var before = shared.target.scrollTop;\n\t shared.target.scrollTop += e.deltaY;\n\t // block scroll of the document when container can be scrolled\n\t if (before !== shared.target.scrollTop) {\n\t e.stopPropagation();\n\t e.preventDefault();\n\t }\n\t }\n\t }\n\n\t function renderMirrorImage() {\n\t if (shared.mirror) {\n\t return;\n\t }\n\t var rect = shared.sourceItem.getBoundingClientRect();\n\t shared.mirror = shared.sourceItem.cloneNode(true);\n\t shared.mirrorWidth = rect.width;\n\t shared.mirrorHeight = rect.height;\n\t shared.mirror.style.width = getRectWidth(rect) + 'px';\n\t shared.mirror.style.height = getRectHeight(rect) + 'px';\n\t rmClass(shared.mirror, o.classes.transit);\n\t addClass(shared.mirror, o.classes.mirror);\n\t o.mirrorContainer.appendChild(shared.mirror);\n\t regEvent(docElm, 'on', 'mousemove', drag);\n\t addClass(doc.body, o.classes.unselectable);\n\t regEvent(shared.mirror, 'on', 'wheel', scrollContainer);\n\t if (o.scope) {\n\t o.scope.$emit(o.eventNames.dragularcloned, shared.mirror, shared.sourceItem);\n\t }\n\t }\n\n\t function removeMirrorImage() {\n\t if (shared.mirror) {\n\t rmClass(doc.body, o.classes.unselectable);\n\t regEvent(docElm, 'off', 'mousemove', drag);\n\t regEvent(shared.mirror, 'off', 'wheel', scrollContainer);\n\t if(getParent(shared.mirror)){\n\t shared.mirror.parentNode.removeChild(shared.mirror);\n\t }\n\t shared.mirror = null;\n\t }\n\t }\n\n\t function getImmediateChild(dropTarget, target) { // watch performance - running each move several times!\n\t var immediate = target;\n\t while (immediate !== dropTarget && getParent(immediate) !== dropTarget) {\n\t immediate = getParent(immediate);\n\t }\n\t if (immediate === docElm) {\n\t return null;\n\t }\n\t return immediate;\n\t }\n\n\t function getReference(dropTarget, target, x, y) { // watch performance - running each move several times!\n\t var horizontal = o.direction === 'horizontal';\n\t return target !== dropTarget ? inside() : outside();\n\n\t function outside() { // slower, but able to figure out any position\n\t var len = dropTarget.children.length,\n\t i, el, rect;\n\t for (i = 0; i < len; i++) {\n\t el = dropTarget.children[i];\n\t rect = el.getBoundingClientRect();\n\t if (horizontal && rect.left > x) {\n\t return el;\n\t }\n\t if (!horizontal && rect.top > y) {\n\t return el;\n\t }\n\t }\n\t return null;\n\t }\n\n\t function inside() { // faster, but only available if dropped inside a child element\n\t var rect = target.getBoundingClientRect();\n\t if (horizontal) {\n\t return resolve(x > rect.left + getRectWidth(rect) / 2);\n\t }\n\t return resolve(y > rect.top + getRectHeight(rect) / 2);\n\t }\n\n\t function resolve(after) {\n\t return after ? nextEl(target) : target;\n\t }\n\t }\n\n\t function getElementBehindPoint(point, x, y) { // watch performance - running each move!\n\t var p = point || {},\n\t state = p.className,\n\t el;\n\t p.className += ' ' + o.classes.hide;\n\t el = doc.elementFromPoint(x, y);\n\t p.className = state;\n\t return el;\n\t }\n\t } // end of service\n\n\t /****************************************************************************************************************************/\n\t /****************************************************************************************************************************/\n\t /****************************************************************************************************************************/\n\n\t // HELPERS FUNCTIONS:\n\n\t function regEvent(el, op, type, fn) {\n\t var touch = {\n\t mouseup: 'touchend',\n\t mousedown: 'touchstart',\n\t mousemove: 'touchmove'\n\t },\n\t pointers = {\n\t mouseup: 'pointerup',\n\t mousedown: 'pointerdown',\n\t mousemove: 'pointermove'\n\t },\n\t microsoft = {\n\t mouseup: 'MSPointerUp',\n\t mousedown: 'MSPointerDown',\n\t mousemove: 'MSPointerMove'\n\t },\n\t $el = angular.element(el);\n\n\t if (global.navigator.pointerEnabled && pointers[type]) {\n\t $el[op](pointers[type], fn);\n\t } else if (global.navigator.msPointerEnabled && microsoft[type]) {\n\t $el[op](microsoft[type], fn);\n\t } else if (touch[type]) {\n\t $el[op](touch[type], fn);\n\t }\n\t $el[op](type, fn);\n\t }\n\n\t function never() {\n\t return false;\n\t }\n\n\t function always() {\n\t return true;\n\t }\n\n\t // make array from array-like objects or from single element (based on bevacqua/atoa)\n\t function makeArray(all, startIndex) {\n\t if (Array.isArray(all)) {\n\t return all;\n\t }\n\t if (all.length) { // is array-like\n\t return Array.prototype.slice.call(all, startIndex); // convert to vanilla js array\n\t } else { // is one element\n\t return [all];\n\t }\n\t }\n\n\t function whichMouseButton (e) {\n\t if (e.touches) { return e.touches.length; }\n\t if (e.originalEvent && e.originalEvent.touches) { return e.originalEvent.touches.length; }\n\t if (e.buttons !== undefined) { return e.buttons; }\n\t if (e.which !== undefined) { return e.which; }\n\t var button = e.button;\n\t if (button !== undefined) { // see https://github.com/jquery/jquery/blob/99e8ff1baa7ae341e94bb89c3e84570c7c3ad9ea/src/event.js#L573-L575\n\t return button & 1 ? 1 : button & 2 ? 3 : (button & 4 ? 2 : 0);\n\t }\n\t }\n\n\t function preventGrabbed(e) {\n\t if (e.originalEvent){\n\t e = e.originalEvent; // jQuery enviroment\n\t }\n\t if (shared.grabbed) {\n\t e.preventDefault();\n\t }\n\t }\n\n\t function getScroll(scrollProp, offsetProp) {\n\t if (typeof window[offsetProp] !== 'undefined') {\n\t return window[offsetProp];\n\t }\n\t if (docElm.clientHeight) {\n\t return docElm[scrollProp];\n\t }\n\t return doc.body[scrollProp];\n\t }\n\n\t function getOffset(el) { // watch performance - running each move!\n\t var rect = el.getBoundingClientRect(),\n\t scrollTop = getScroll('scrollTop', 'pageYOffset'),\n\t scrollLeft = getScroll('scrollLeft', 'pageXOffset');\n\t return {\n\t left: rect.left + scrollLeft,\n\t right: rect.right + scrollLeft,\n\t top: rect.top + scrollTop,\n\t bottom: rect.bottom + scrollTop\n\t };\n\t }\n\n\t function getRectWidth(rect) {\n\t return rect.width || (rect.right - rect.left);\n\t }\n\n\t function getRectHeight(rect) {\n\t return rect.height || (rect.bottom - rect.top);\n\t }\n\n\t function getEmptyObject() {\n\t return {};\n\t }\n\n\t function nextEl(el) {\n\t return el.nextElementSibling || manually();\n\n\t function manually() {\n\t var sibling = el;\n\t do {\n\t sibling = sibling.nextSibling;\n\t } while (sibling && sibling.nodeType !== 1);\n\t return sibling;\n\t }\n\t }\n\n\t //Cannot use angular.isElement because we need to check plain dom element, no jQlite wrapped\n\t function isElement(obj) {\n\t return (\n\t typeof HTMLElement === 'object' ? obj instanceof HTMLElement : //DOM2\n\t obj && typeof obj === 'object' && obj !== null && obj.nodeType === 1 && typeof obj.nodeName === 'string'\n\t );\n\t }\n\n\t function lookupClass(className) {\n\t var cached = shared.classesCache[className];\n\t if (cached) {\n\t cached.lastIndex = 0;\n\t } else {\n\t shared.classesCache[className] = cached = new RegExp('(?:^|\\\\s)' + className + '(?:\\\\s|$)', 'g');\n\t }\n\t return cached;\n\t }\n\n\t function addClass(el, className) {\n\t var current = el.className;\n\t if (!current.length) {\n\t el.className = className;\n\t } else if (!lookupClass(className).test(current)) {\n\t el.className += ' ' + className;\n\t }\n\t }\n\n\t function rmClass(el, className) {\n\t el.className = el.className.replace(lookupClass(className), ' ').trim();\n\t }\n\n\t function getEventHost(e) {\n\t // on touchend event, we have to use `e.changedTouches`\n\t // see http://stackoverflow.com/questions/7192563/touchend-event-properties\n\t // see https://github.com/bevacqua/dragula/issues/34\n\t if (e.targetTouches && e.targetTouches.length) {\n\t return e.targetTouches[0];\n\t }\n\t if (e.changedTouches && e.changedTouches.length) {\n\t return e.changedTouches[0];\n\t }\n\t return e;\n\t }\n\n\t function getCoord(coord, e) { // watch performance - running each move several times!\n\t var host = getEventHost(e);\n\t var missMap = {\n\t pageX: 'clientX', // IE8\n\t pageY: 'clientY' // IE8\n\t };\n\t if (coord in missMap && !(coord in host) && missMap[coord] in host) {\n\t coord = missMap[coord];\n\t }\n\n\t // Adding support for touch events, as they are not functional in the original\n\t if (!host.type || host.type.indexOf('touch') < 0) {\n\t return host[coord];\n\t } else {\n\t if (host.type.indexOf('end') === -1) {\n\t // No clientX or clientY in a touch event\n\t return host.originalEvent.touches[0][coord.replace('client', 'page')];\n\t }\n\t // Nothing should happen for touchend\n\t return false;\n\t }\n\t }\n\n\t function getParent (el) { // watch performance - running each move!\n\t return el.parentNode === document ? null : el.parentNode;\n\t }\n\n\t function isInput (el) {\n\t return el.tagName === 'INPUT' || el.tagName === 'TEXTAREA' || el.tagName === 'SELECT' || isEditable(el);\n\t }\n\n\t function isEditable (el) {\n\t if (!el) { return false; } // no parents were editable\n\t if (el.contentEditable === 'false') { return false; } // stop the lookup\n\t if (el.contentEditable === 'true') { return true; } // found a contentEditable element in the chain\n\t return isEditable(getParent(el)); // contentEditable is set to 'inherit'\n\t }\n\n\t function domIndexOf(child, parent) {\n\t return Array.prototype.indexOf.call(angular.element(parent).children(), child);\n\t }\n\n\t function fireEvent(target, e, extra) { // watch performance - running each move!\n\t if (!target) {\n\t return;\n\t }\n\t shared.extra = extra;\n\t if (target.dispatchEvent) {\n\t target.dispatchEvent(e);\n\t } else {\n\t target.fireEvent('on' + e.eventType, e);\n\t }\n\t }\n\n\t function getBool(prop, args, context){\n\t if(angular.isFunction(prop)){\n\t return !!prop.apply(context || this, args || shared);\n\t }else{\n\t return !!prop;\n\t }\n\t }\n\n\t};\n\n\tdragularService.$inject = ['$rootScope', '$compile'];\n\n\tmodule.exports = dragularService;\n\n\t/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))\n\n/***/ },\n/* 4 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar examplesRouter = function ($stateProvider, $urlRouterProvider) {\n\t $urlRouterProvider.otherwise('/home');\n\n\t var timer,\n\t ctrl = function routerCtrl($state, $stateParams, $timeout) {\n\t // go to install notes by default\n\t if (!$stateParams.link) {\n\t timer = $timeout(function timer() {\n\t $state.go('docs.detail', {\n\t link: 'docsInstall'\n\t });\n\t },0);\n\t }else{\n\t $timeout.cancel(timer);\n\t }\n\t };\n\n\t ctrl.$inject = ['$state', '$stateParams', '$timeout'];\n\n\t $stateProvider\n\t .state('home', {\n\t url: '/home',\n\t templateUrl: 'partials/partial-home.html'\n\t })\n\t .state('docs', {\n\t url: '/docs',\n\t templateUrl: 'partials/partial-docs.html',\n\t controller: ctrl\n\t })\n\t .state('docs.detail', {\n\t url: '/:link',\n\t templateUrl: function($stateParams) {\n\t return $stateParams.link + '/' + $stateParams.link + '.html';\n\t },\n\t controller: ctrl\n\t })\n\t .state('contribute', {\n\t url: '/contribute',\n\t templateUrl: 'partials/partial-contribute.html'\n\t });\n\t};\n\n\texamplesRouter.$inject = ['$stateProvider', '$urlRouterProvider'];\n\n\tmodule.exports = examplesRouter;\n\n\n/***/ },\n/* 5 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar BasicCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService('.containerVertical');\n\t};\n\n\tBasicCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = BasicCtrl;\n\n\n/***/ },\n/* 6 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\tvar BasicModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items1 = [{\n\t content: 'Move me, but you can only drop me in one of these containers.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.items2 = [{\n\t content: 'Item 5'\n\t }, {\n\t content: 'Item 6'\n\t }, {\n\t content: 'Item 7'\n\t }, {\n\t content: 'Item 8'\n\t }];\n\t var containers = $element.children().eq(0).children();\n\t dragularService.cleanEnviroment();\n\t dragularService([containers[0],containers[1]],{\n\t containersModel: [$scope.items1, $scope.items2]\n\t });\n\t};\n\n\tBasicModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = BasicModelCtrl;\n\n\n/***/ },\n/* 7 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar BoundingBoxCtrl = function ($element, dragularService) {\n\t var boundingBox = $element[0];\n\t dragularService.cleanEnviroment();\n\n\t dragularService($element.children(), {\n\t boundingBox: boundingBox\n\t });\n\t};\n\n\tBoundingBoxCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = BoundingBoxCtrl;\n\n\n/***/ },\n/* 8 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar BoundingBoxLockXCtrl = function ($element, dragularService) {\n\t var boundingBox = $element.children().children()[0];\n\t dragularService.cleanEnviroment();\n\t dragularService(boundingBox, {\n\t boundingBox: boundingBox,\n\t lockX: true\n\t });\n\t};\n\n\tBoundingBoxLockXCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = BoundingBoxLockXCtrl;\n\n\n/***/ },\n/* 9 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar BoundingBoxLockYCtrl = function ($element, dragularService) {\n\t var boundingBox = $element.children().children()[0];\n\t dragularService.cleanEnviroment();\n\t dragularService(boundingBox, {\n\t boundingBox: boundingBox,\n\t lockY: true\n\t });\n\t};\n\n\tBoundingBoxLockYCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = BoundingBoxLockYCtrl;\n\n\n/***/ },\n/* 10 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar CopyCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children(), {\n\t copy: true\n\t });\n\t};\n\n\tCopyCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = CopyCtrl;\n\n\n/***/ },\n/* 11 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar CopyModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items1 = [{\n\t content: 'Move me, and make copy on drop.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.items2 = [{\n\t content: 'Item 5'\n\t }, {\n\t content: 'Item 6'\n\t }, {\n\t content: 'Item 7'\n\t }, {\n\t content: 'Item 8'\n\t }];\n\t var containers = $element.children().eq(0).children();\n\t dragularService.cleanEnviroment();\n\t dragularService([containers[0],containers[1]],{\n\t containersModel: [$scope.items1, $scope.items2],\n\t copy: true\n\t });\n\t};\n\n\tCopyModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = CopyModelCtrl;\n\n\n/***/ },\n/* 12 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar CustomClassesCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children(), {\n\t classes: {\n\t mirror: 'custom-green-mirror'\n\t }\n\t });\n\t};\n\n\tCustomClassesCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = CustomClassesCtrl;\n\n\n/***/ },\n/* 13 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar DifferentOptionsModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items1 = [{\n\t content: 'Move me, but you can only drop me in one of these containers.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.items2 = [{\n\t content: 'Item 5'\n\t }, {\n\t content: 'Item 6'\n\t }, {\n\t content: 'Item 7'\n\t }, {\n\t content: 'Item 8'\n\t }];\n\n\t var containerLeft = document.querySelector('#containerLeft'),\n\t containerRight = document.querySelector('#containerRight');\n\n\t function accepts(el, target, source) {\n\t // left->right || in same container\n\t if (source === containerLeft || source === target) {\n\t return true;\n\t }\n\t }\n\n\t dragularService.cleanEnviroment();\n\t dragularService([containerLeft], {\n\t containersModel: [$scope.items1],\n\t copy: true,\n\t copySortSource: true,\n\t //move only from left to right\n\t accepts: accepts\n\t });\n\n\t dragularService([containerRight], {\n\t containersModel: [$scope.items2],\n\t removeOnSpill: true,\n\t //move only from left to right\n\t accepts: accepts\n\t });\n\n\t};\n\n\tDifferentOptionsModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = DifferentOptionsModelCtrl;\n\n\n/***/ },\n/* 14 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar DirectiveCtrl = function ($scope) {\n\t $scope.dragularOptions = {\n\t classes: {\n\t mirror: 'custom-green-mirror'\n\t },\n\t nameSpace: 'same' // just connecting left and right container\n\t };\n\t};\n\n\tDirectiveCtrl.$inject = ['$scope'];\n\n\tmodule.exports = DirectiveCtrl;\n\n\n/***/ },\n/* 15 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar DirectiveModelCtrl = function ($scope) {\n\t $scope.items1 = [{\n\t content: 'Move me, and make copy on drop.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.items2 = [{\n\t content: 'Item 5'\n\t }, {\n\t content: 'Item 6'\n\t }, {\n\t content: 'Item 7'\n\t }, {\n\t content: 'Item 8'\n\t }];\n\t $scope.dragularOptions = {\n\t containersModel: $scope.items1,\n\t classes: {\n\t mirror: 'custom-green-mirror'\n\t },\n\t nameSpace: 'common' // just connecting left and right container\n\t };\n\t};\n\n\tDirectiveModelCtrl.$inject = ['$scope'];\n\n\tmodule.exports = DirectiveModelCtrl;\n\n\n/***/ },\n/* 16 */\n/***/ function(module, exports) {\n\n\t/* global angular */\n\t'use strict';\n\n\tvar DragOverEventsCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService([$element.children()[0], $element.children()[2]], {\n\t nameSpace: 'apples'\n\t });\n\t dragularService([$element.children()[1], $element.children()[3]], {\n\t nameSpace: 'oranges'\n\t });\n\n\t // containers events handling\n\t function registerEvents(el) {\n\t el.on('dragularenter', function(e) {\n\t if (el[0] === e.target) { // filter bubbled\n\t el.addClass(dragularService.shared.extra ? 'gu-over-accept' : 'gu-over-decline');\n\t }\n\t });\n\t el.on('dragularleave dragularrelease', function(e) {\n\t if ((el[0] === e.target && // filter bubbled\n\t dragularService.shared.extra && // extra on dragleave contains element the drag is leaving to\n\t dragularService.shared.extra.parentElement !== e.target) || // is that element child of this container?\n\t e.type === 'dragularrelease') {\n\t el.removeClass('gu-over-accept');\n\t el.removeClass('gu-over-decline');\n\t }\n\t });\n\t }\n\n\t angular.forEach($element.children(), function forEachChild(el) {\n\t registerEvents(angular.element(el));\n\t });\n\n\t // notContainer events handling\n\t var notContainer = angular.element(document.getElementsByClassName('notContainer'));\n\t notContainer.on('dragularenter', function() {\n\t notContainer.addClass('gu-over');\n\t });\n\t notContainer.on('dragularleave dragularrelease', function() {\n\t notContainer.removeClass('gu-over');\n\t });\n\t};\n\n\tDragOverEventsCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = DragOverEventsCtrl;\n\n\n/***/ },\n/* 17 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar EventsCtrl = function ($scope, $element, dragularService, $timeout) {\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children(), {\n\t scope: $scope\n\t });\n\t $scope.$on('dragulardrag', function(e, el) {\n\t e.stopPropagation();\n\t el.className = el.className.replace(' ex-moved', '');\n\t });\n\t $scope.$on('dragulardrop', function(e, el) {\n\t e.stopPropagation();\n\t $timeout(function() {\n\t el.className += ' ex-moved';\n\t }, 0);\n\t });\n\n\t $scope.$on('dragularcloned', myFn('cloned'));\n\t $scope.$on('dragulardrag', myFn('drag'));\n\t $scope.$on('dragularcancel', myFn('cancel'));\n\t $scope.$on('dragulardrop', myFn('drop'));\n\t $scope.$on('dragularremove', myFn('remove'));\n\t $scope.$on('dragulardragend', myFn('dragend'));\n\t $scope.$on('dragularshadow', myFn('shadow'));\n\n\t function myFn(eventName) {\n\t return function() {\n\t console.log(eventName, arguments);\n\t };\n\t }\n\t};\n\n\tEventsCtrl.$inject = ['$scope', '$element', 'dragularService', '$timeout'];\n\n\tmodule.exports = EventsCtrl;\n\n\n/***/ },\n/* 18 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar HandleCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t\tdragularService($element.children(), {\n\t moves: function(el, container, handle) {\n\t return handle.className === 'handle';\n\t }\n\t });\n\t};\n\n\tHandleCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = HandleCtrl;\n\n\n/***/ },\n/* 19 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar IsContainerModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items1 = [{\n\t content: 'Move me, but you can only drop me in one of these containers.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.cartModel = [];\n\n\t var containerLeft = document.querySelector('#containerLeft');\n\n\t dragularService.cleanEnviroment();\n\t dragularService([containerLeft], {\n\t containersModel: [$scope.items1],\n\t copy: true,\n\t isContainer: function isContainer (el) {\n\t return el.id === 'cart';\n\t },\n\t isContainerModel: function getModel (){\n\t return $scope.cartModel;\n\t }\n\t });\n\n\t $scope.removeItem = function removeItem() {\n\t var index = $scope.cartModel.indexOf(this.item);\n\t $scope.cartModel.splice(index, 1);\n\t };\n\t};\n\n\tIsContainerModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = IsContainerModelCtrl;\n\n\n/***/ },\n/* 20 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NameSpacesCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService([$element.children()[0], $element.children()[2]], {\n\t nameSpace: 'apples'\n\t });\n\t dragularService($element.children()[1], {\n\t nameSpace: 'oranges'\n\t });\n\t dragularService($element.children()[3], { // mixed\n\t nameSpace: ['oranges', 'apples']\n\t });\n\t};\n\n\tNameSpacesCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = NameSpacesCtrl;\n\n\n/***/ },\n/* 21 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NestedNgRepeatCtrl = function ($timeout, $scope, $element, dragularService) {\n\t $timeout(function() { // timeount due to ngRepeat to be ready\n\t dragularService.cleanEnviroment();\n\t dragularService($element, {\n\t nameSpace: 'rows',\n\t moves: function rowOnly (el, container, handle) {\n\t return handle.classList.contains('row-handle');\n\t }\n\t });\n\n\t dragularService($element.children(), {\n\t nameSpace: 'cells',\n\t moves: function excludeHandle (el, container, handle) {\n\t return !handle.classList.contains('row-handle');\n\t }\n\t });\n\t }, 0);\n\t $scope.items = [{\n\t items: [{\n\t content: 'Item a1'\n\t }, {\n\t content: 'Item a2'\n\t }, {\n\t content: 'Item a3'\n\t }, {\n\t content: 'Item a4'\n\t }]\n\t }, {\n\t items: [{\n\t content: 'Item b1'\n\t }, {\n\t content: 'Item b2'\n\t }, {\n\t content: 'Item b3'\n\t }, {\n\t content: 'Item b4'\n\t }]\n\t }, {\n\t items: [{\n\t content: 'Item c1'\n\t }, {\n\t content: 'Item c2'\n\t }, {\n\t content: 'Item c3'\n\t }, {\n\t content: 'Item c4'\n\t }]\n\t }];\n\t};\n\n\tNestedNgRepeatCtrl.$inject = ['$timeout', '$scope', '$element', 'dragularService'];\n\n\tmodule.exports = NestedNgRepeatCtrl;\n\n\n/***/ },\n/* 22 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NestedNgRepeatWithModelCtrl = function ($timeout, $scope, $element, dragularService) {\n\t $timeout(function() { // timeount due to nested ngRepeat to be ready\n\t var container = $element.children().eq(0).children(),\n\t parentContainers = container.children(),\n\t nestedContainers = [];\n\n\t dragularService.cleanEnviroment();\n\t dragularService(container, {\n\t moves: function(el, container, handle) {\n\t return handle.classList.contains('row-handle');\n\t },\n\t containersModel: $scope.items,\n\t nameSpace: 'rows'\n\t });\n\n\t // collect nested contianers\n\t for (var i = 0; i < parentContainers.length; i++) {\n\t nestedContainers.push(parentContainers.eq(i).children()[1]);\n\t }\n\n\t dragularService(nestedContainers, {\n\t moves: function(el, container, handle) {\n\t return !handle.classList.contains('row-handle');\n\t },\n\t containersModel: (function getNestedContainersModel(){\n\t var parent = $scope.items,\n\t containersModel = [];\n\t for (var i = 0; i < parent.length; i++) {\n\t containersModel.push(parent[i].items);\n\t }\n\t return containersModel;\n\t })(),\n\t nameSpace: 'cells'\n\t });\n\t }, 0);\n\t $scope.items = [{\n\t items: [{\n\t content: 'Item a1'\n\t }, {\n\t content: 'Item a2'\n\t }, {\n\t content: 'Item a3'\n\t }, {\n\t content: 'Item a4'\n\t }]\n\t }, {\n\t items: [{\n\t content: 'Item b1'\n\t }, {\n\t content: 'Item b2'\n\t }, {\n\t content: 'Item b3'\n\t }, {\n\t content: 'Item b4'\n\t }]\n\t }, {\n\t items: [{\n\t content: 'Item c1'\n\t }, {\n\t content: 'Item c2'\n\t }, {\n\t content: 'Item c3'\n\t }, {\n\t content: 'Item c4'\n\t }]\n\t }];\n\t};\n\n\tNestedNgRepeatWithModelCtrl.$inject = ['$timeout', '$scope', '$element', 'dragularService'];\n\n\tmodule.exports = NestedNgRepeatWithModelCtrl;\n\n\n/***/ },\n/* 23 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NgRepeatCtrl = function ($scope, $element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children());\n\t $scope.items = [{\n\t content: 'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.'\n\t }, {\n\t content: 'Item 2'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.addItem = function addItem() {\n\t var index = $scope.items.indexOf(this.item) + 1;\n\t $scope.items.splice(index, 0, {\n\t content: this.item.content + '-copy'\n\t });\n\t };\n\t $scope.removeItem = function removeItem() {\n\t var index = $scope.items.indexOf(this.item);\n\t $scope.items.splice(index, 1);\n\t };\n\t};\n\n\tNgRepeatCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = NgRepeatCtrl;\n\n\n/***/ },\n/* 24 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NgRepeatFilteredWithModelCtrl = function ($scope, $element, dragularService, $filter) {\n\t $scope.items1 = [{\n\t content: 'Move me, but you can only drop me in one of these containers.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than these containers, I\\'ll just come back.'\n\t }, {\n\t content: 'Apple 3'\n\t }, {\n\t content: 'Orange 4'\n\t }, {\n\t content: 'Orange 5'\n\t }, {\n\t content: 'Apple 6'\n\t }, {\n\t content: 'Apple 7'\n\t }, {\n\t content: 'Apple 8'\n\t }];\n\t $scope.items2 = [{\n\t content: 'Apple 9'\n\t }, {\n\t content: 'Orange 10'\n\t }, {\n\t content: 'Orange 11'\n\t }, {\n\t content: 'Apple 12'\n\t }, {\n\t content: 'Orange 13'\n\t }, {\n\t content: 'Apple 14'\n\t }];\n\t $scope.filter1query = 'Orange';\n\t $scope.filter2query = 'Orange';\n\t $scope.filteredModel1 = [];\n\t $scope.filteredModel2 = [];\n\t $scope.getFilteredModel = function (filteredModel, items, filterQuery) {\n\t filteredModel.length = 0;\n\t /*\n\t * Following one-liner is same like:\n\t * var filteredModelTemp = $filter('filter')(items, filterQuery);\n\t * angular.forEach(filteredModelTemp, function(item){\n\t * filteredModel.push(item);\n\t * });\n\t * Or like:\n\t * var filteredModelTemp = $filter('filter')(items, filterQuery);\n\t * for(var i; i < filteredModelTemp.length; i++){\n\t * filteredModel.push(filteredModelTemp[i]);\n\t * }\n\t *\n\t * You cannot just assign filtered array to filteredModel like this:\n\t * filteredModel = $filter('filter')(items, filterQuery);\n\t * Because you would replace the array object you provide to dragular with new one.\n\t * So dragular will continue to use the one it was provided on init.\n\t * Hopefully I make it clear. :)\n\t */\n\t [].push.apply(filteredModel, $filter('filter')(items, filterQuery));\n\t return filteredModel;\n\t };\n\t var containers = $element.children().eq(1).children();\n\t dragularService.cleanEnviroment();\n\t dragularService([containers[0],containers[1]],{\n\t containersModel: [$scope.items1, $scope.items2],\n\t containersFilteredModel: [$scope.filteredModel1, $scope.filteredModel2]\n\t });\n\t};\n\n\tNgRepeatFilteredWithModelCtrl.$inject = ['$scope', '$element', 'dragularService', '$filter'];\n\n\tmodule.exports = NgRepeatFilteredWithModelCtrl;\n\n\n/***/ },\n/* 25 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar NgRepeatWithModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items = [{\n\t content: 'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.'\n\t }, {\n\t content: 'Item 2'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children().eq(0).children(), {containersModel: $scope.items});\n\t $scope.addItem = function addItem() {\n\t var index = $scope.items.indexOf(this.item) + 1;\n\t $scope.items.splice(index, 0, {\n\t content: this.item.content + '-copy'\n\t });\n\t };\n\t $scope.removeItem = function removeItem() {\n\t var index = $scope.items.indexOf(this.item);\n\t $scope.items.splice(index, 1);\n\t };\n\t};\n\n\tNgRepeatWithModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = NgRepeatWithModelCtrl;\n\n\n/***/ },\n/* 26 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar RemoveOnSpillCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t\tdragularService($element.children(), {\n\t removeOnSpill: true\n\t });\n\t};\n\n\tRemoveOnSpillCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = RemoveOnSpillCtrl;\n\n\n/***/ },\n/* 27 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar RemoveOnSpillWithModelCtrl = function ($scope, $element, dragularService) {\n\t $scope.items1 = [{\n\t content: 'Move me, but you can only drop me in containers.'\n\t }, {\n\t content: 'If you try to drop me somewhere other than containers, I\\'ll die a fiery death.'\n\t }, {\n\t content: 'Item 3'\n\t }, {\n\t content: 'Item 4'\n\t }];\n\t $scope.items2 = [{\n\t content: 'You can drop me in the left container.'\n\t }, {\n\t content: 'Item 6'\n\t }, {\n\t content: 'Item 7'\n\t }, {\n\t content: 'Item 8'\n\t }];\n\t var containers = $element.children().eq(0).children();\n\t dragularService.cleanEnviroment();\n\t dragularService([containers[0], containers[1]], {\n\t containersModel: [$scope.items1, $scope.items2],\n\t removeOnSpill: true\n\t });\n\t};\n\n\tRemoveOnSpillWithModelCtrl.$inject = ['$scope', '$element', 'dragularService'];\n\n\tmodule.exports = RemoveOnSpillWithModelCtrl;\n\n\n/***/ },\n/* 28 */\n/***/ function(module, exports) {\n\n\t'use strict';\n\n\tvar RevertOnSpillCtrl = function ($element, dragularService) {\n\t dragularService.cleanEnviroment();\n\t dragularService($element.children(), {\n\t revertOnSpill: true\n\t });\n\t};\n\n\tRevertOnSpillCtrl.$inject = ['$element', 'dragularService'];\n\n\tmodule.exports = RevertOnSpillCtrl;\n\n\n/***/ },\n/* 29 */\n/***/ function(module, exports) {\n\n\t/* global angular */\n\t'use strict';\n\n\tvar ScrollingDragCtrl = function ($interval, $element, dragularService) {\n\t var timer,\n\t leftScrollContainer = document.getElementById('leftScroll'),\n\t rightScrollContainer = document.getElementById('rightScroll'),\n\t leftTopBar = document.getElementById('leftTopBar'),\n\t leftBottomBar = document.getElementById('leftBottomBar'),\n\t rightTopBar = document.getElementById('rightTopBar'),\n\t rightBottomBar = document.getElementById('rightBottomBar');\n\n\t dragularService.cleanEnviroment();\n\t dragularService([leftScrollContainer, rightScrollContainer]);\n\n\t registerEvents(leftTopBar, leftScrollContainer, -5);\n\t registerEvents(leftBottomBar, leftScrollContainer, 5);\n\t registerEvents(rightTopBar, rightScrollContainer, -5);\n\t registerEvents(rightBottomBar, rightScrollContainer, 5);\n\n\t function registerEvents(bar, container, inc, speed) {\n\t if (!speed) {\n\t speed = 20;\n\t }\n\t angular.element(bar).on('dragularenter', function() {\n\t container.scrollTop += inc;\n\t timer = $interval(function moveScroll() {\n\t container.scrollTop += inc;\n\t }, speed);\n\t });\n\t angular.element(bar).on('dragularleave dragularrelease', function() {\n\t $interval.cancel(timer);\n\t });\n\t }\n\t};\n\n\tScrollingDragCtrl.$inject = ['$interval', '$element', 'dragularService'];\n\n\tmodule.exports = ScrollingDragCtrl;\n\n\n/***/ },\n/* 30 */\n/***/ function(module, exports) {\n\n\t'use strict'; module.exports = angular.module(\"templates\", []).run([\"$templateCache\", function($templateCache) {$templateCache.put(\"docsInstall/docsInstall.html\",\"

Install

\\n

download dragular.js and dragular.css from dist folder

\\n

OR clone git

\\n
\\ngit clone http://github.com/luckylooke/dragular.git\\n
\\n

OR use npm

\\n
\\n[sudo] npm install dragular\\n
\\n

OR use bower

\\n
\\nbower install dragular\\n
\\n

AND include files into your project

\\n
\\n<link href=\\'styles/dragular.css\\' rel=\\'stylesheet\\' type=\\'text/css\\' />\\n<script src=\\'scripts/dragular.js\\'></script>\\n
\\n

AND put dragularModule into dependency array

\\n
\\nvar app = angular.module(\\'myApp\\', [\\'dragularModule\\', \\'otherDependencies\\']);\\n
\\n

DONE :)

\\n\");\n\t$templateCache.put(\"exampleBasic/exampleBasic.html\",\"
\\n

Basic

\\n \\n
\\n
\\n
Move me, but you can only drop me in one of these containers.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
Try to click me, dragular distinguish drag from click
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n// JS\\n  controller(\\'Basic\\', [\\'$element\\', \\'dragularService\\', function TodoCtrl($element, dragularService) {\\n    dragularService(\\'.containerVertical\\');\\n  }])\\n        \\n        \\n// CSS\\n.clickedClass {\\n  background-color: orange !important;\\n}\\n        \\n        \\n<!-- HTML -->\\n  <div class=\\'wrapper\\' ng-controller="Basic">\\n    <div class=\\'containerVertical\\'>\\n        <div>Move me, but you can only drop me in one of these containers.</div>\\n        <div>If you try to drop me somewhere other than these containers, I\\'ll just come back.</div>\\n        <div>Item 3.</div>\\n        <div>Item 6.</div>\\n    </div>\\n    <div class=\\'containerVertical\\'>\\n        <div>You can drop me in the left container, otherwise I\\'ll stay here.</div>\\n        <div ng-click=\\\"clicked = !clicked\\\" ng-class=\\\"clicked && \\'clickedClass\\'\\\">Try to click me, dragular distinguish drag from click</div>\\n        <div>Item 5.</div>\\n    </div>\\n</div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleBasicWithModel/exampleBasicWithModel.html\",\"
\\n

Basic - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n          
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n          
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  controller(\\'BasicModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items1 = [{\\n      content: \\'Move me, but you can only drop me in one of these containers.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'Item 5\\'\\n    }, {\\n      content: \\'Item 6\\'\\n    }, {\\n      content: \\'Item 7\\'\\n    }, {\\n      content: \\'Item 8\\'\\n    }];\\n    var containers = $element.children().children();\\n    dragularService([containers[0],containers[1]],{\\n      containersModel: [$scope.items1, $scope.items2]\\n    });\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="Basic">\\n    <div class=\\'tableRow\\'>\\n        <div class=\\'containerVertical\\'>\\n            <div ng-repeat="item in items1">{{item.content}}</div>\\n        </div>\\n        <div class=\\'containerVertical\\'>\\n            <div ng-repeat="item in items2">{{item.content}}</div>\\n        </div>\\n    </div>\\n    <div class="tableRow">\\n        <div class="container">\\n            <div>Items1:\\n                <br/>{{items1 | json}}</div>\\n        </div>\\n        <div class="container">\\n            <div>Items2:\\n                <br/>{{items2 | json}}</div>\\n        </div>\\n    </div>\\n</div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleBoundingBox/exampleBoundingBox.html\",\"
\\n

BoundingBox

\\n \\n
\\n
\\n
This items cannot cross its example element, just try it your selves.
\\n
Item 2.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
This items cannot cross its example element, just try it your selves.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n  dragularService([$element.children(), {\\n    boundingBox: $element\\n  });\\n        \\n      
\\n
\");\n\t$templateCache.put(\"exampleBoundingBoxLockX/exampleBoundingBoxLockX.html\",\"
\\n

BoundingBox and lockX

\\n \\n
\\n
\\n
\\n
Items are locked in X axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
\\n
item 2
\\n
item 3
\\n
item 4
\\n
\\n
\\n
\\n
\\n        \\n  dragularService([$element.children()[0].children(), {\\n    boundingBox: $element.children()[0],\\n    lockX: true\\n  });\\n        \\n      
\\n
\");\n\t$templateCache.put(\"exampleBoundingBoxLockY/exampleBoundingBoxLockY.html\",\"
\\n

BoundingBox and LockY

\\n \\n
\\n
\\n
\\n
Items are locked in Y axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
\\n
item 2
\\n
item 3
\\n
item 4
\\n
item 5
\\n
item 6
\\n
\\n
\\n
\\n
\\n        \\n  dragularService([$element.children()[0].children(), {\\n    boundingBox: $element.children()[0],\\n    lockY: true\\n  });\\n        \\n      
\\n
\");\n\t$templateCache.put(\"exampleCopy/exampleCopy.html\",\"
\\n

Copy

\\n \\n
\\n
\\n
Move me, and make copy on drop.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
\\n
\\n
\\n        \\n// JS\\n  controller(\\'Copy\\', [\\'$element\\', \\'dragularService\\', function TodoCtrl($element, dragularService) {\\n    dragularService($element.children(), {\\n      copy: true\\n    });\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="Copy" ng-hide="globals.showModelExamples">\\n    <div id=\\'left2\\' class=\\'containerVertical\\'>\\n      <div>Move me, and make copy on drop.</div>\\n      <div>If you try to drop me somewhere other than these containers, I\\'ll just come back.</div>\\n    </div>\\n    <div id=\\'right2\\' class=\\'containerVertical\\'>\\n      <div>You can drop me in the left container, otherwise I\\'ll stay here.</div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleCopyWithModel/exampleCopyWithModel.html\",\"
\\n

Copy - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  controller(\\'CopyModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items1 = [{\\n      content: \\'Move me, and make copy on drop.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'Item 5\\'\\n    }, {\\n      content: \\'Item 6\\'\\n    }, {\\n      content: \\'Item 7\\'\\n    }, {\\n      content: \\'Item 8\\'\\n    }];\\n    var containers = $element.children().children();\\n    dragularService([containers[0],containers[1]],{\\n      containersModel: [$scope.items1, $scope.items2],\\n      copy: true\\n    });\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="CopyModel" ng-show="globals.showModelExamples">\\n    <div class=\\'tableRow\\'>\\n      <div class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items1">{{item.content}}</div>\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items2">{{item.content}}</div>\\n      </div>\\n    </div>\\n    <div class="tableRow">\\n      <div class="container">\\n        <div>Items1:\\n          <br/>{{items1 | json}}</div>\\n      </div>\\n      <div class="container">\\n        <div>Items2:\\n          <br/>{{items2 | json}}</div>\\n      </div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleCustomClasses/exampleCustomClasses.html\",\"
\\n

Custom classes

\\n \\n
\\n
\\n
Move me, but you can only drop me in one of these containers.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n  dragularService([document.getElementById(left), document.getElementById(right)], { classes: {\\n    mirror: \\'custom-green-mirror\\'\\n  } });\\n\\n  // Default classes are:\\n  option.classes = {\\n    mirror: \\'gu-mirror\\',\\n    hide: \\'gu-hide\\',\\n    unselectable: \\'gu-unselectable\\',\\n    transit: \\'gu-transit\\',\\n    overActive: \\'gu-over-active\\',\\n    overAccepts: \\'gu-over-accept\\',\\n    overDeclines: \\'gu-over-decline\\'\\n  };\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleDifferentOptionsWithModel/exampleDifferentOptionsWithModel.html\",\"
\\n

Different options - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n          
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n          
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  .controller(\\'DifferentOptionsModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items1 = [{\\n      content: \\'Move me, but you can only drop me in one of these containers.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'Item 5\\'\\n    }, {\\n      content: \\'Item 6\\'\\n    }, {\\n      content: \\'Item 7\\'\\n    }, {\\n      content: \\'Item 8\\'\\n    }];\\n\\n    var containerLeft = document.querySelector(\\'#containerLeft\\'),\\n      containerRight = document.querySelector(\\'#containerRight\\');\\n\\n    function accepts(el, target, source) {\\n      if (source === containerLeft || source === target) {\\n        return true;\\n      }\\n    }\\n\\n    dragularService([containerLeft], {\\n      containersModel: [$scope.items1],\\n      copy: true,\\n      //move only from left to right  \\n      accepts: accepts\\n    });\\n\\n    dragularService([containerRight], {\\n      containersModel: [$scope.items2],\\n      removeOnSpill: true,\\n      //move only from left to right  \\n      accepts: accepts\\n    });\\n\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="DifferentOptionsModel">\\n    <div class=\\'tableRow\\'>\\n      <div id="containerLeft" class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items1">{{item.content}}</div>\\n      </div>\\n      <div id="containerRight" class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items2">{{item.content}}</div>\\n      </div>\\n    </div>\\n    <div class="tableRow">\\n      <div class=\\'containerVertical\\'>\\n        <pre>Items1:\\n          <br/>{{items1 | json}}</pre>\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <pre>Items2:\\n          <br/>{{items2 | json}}</pre>\\n      </div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleDirective/exampleDirective.html\",\"
\\n

Directive

\\n \\n
\\n
\\n
Move me, but you can only drop me in one of these containers.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n// JS\\n  controller(\\'Directive\\', [\\'$scope\\', \\'dragularService\\', function TodoCtrl($scope) {\\n    $scope.dragularOptions = {\\n      classes: {\\n        mirror: \\'custom-green-mirror\\'\\n      },\\n      nameSpace: \\'common\\' // just connecting left and right container\\n    };\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="Directive">\\n    <div class=\\'containerVertical\\' dragular="dragularOptions">\\n      <div>Move me, but you can only drop me in one of these containers.</div>\\n      <div>If you try to drop me somewhere other than these containers, I\\'ll just come back.</div>\\n      <div>Item 3.</div>\\n      <div>Item 6.</div>\\n    </div>\\n    <div class=\\'containerVertical\\' dragular=\\'{"classes":{"mirror":"custom-green-mirror"},"nameSpace":"same"}\\'>\\n      <div>You can drop me in the left container, otherwise I\\'ll stay here.</div>\\n      <div>Item 4.</div>\\n      <div>Item 5.</div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleDirectiveWithModel/exampleDirectiveWithModel.html\",\"
\\n

Directive - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n       \\n        \\n// JS\\n  controller(\\'DirectiveModel\\', [\\'$scope\\', function TodoCtrl($scope) {\\n    $scope.items1 = [{\\n      content: \\'Move me, and make copy on drop.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'Item 5\\'\\n    }, {\\n      content: \\'Item 6\\'\\n    }, {\\n      content: \\'Item 7\\'\\n    }, {\\n      content: \\'Item 8\\'\\n    }];\\n    $scope.dragularOptions = {\\n      containersModel: $scope.items1,\\n      classes: {\\n        mirror: \\'custom-green-mirror\\'\\n      },\\n      nameSpace: \\'common\\' // just connecting left and right container\\n    };\\n  }])\\n        \\n        \\n<!-- HTML -->\\n <div class=\\'wrapper\\' ng-controller="DirectiveModel">\\n  <div class=\\'containerVertical\\' dragular="dragularOptions">\\n    <div ng-repeat="item in items1">{{item.content}}</div>\\n  </div>\\n  <div class=\\'containerVertical\\' dragular=\\'{"containersModel":"items2","classes":{"mirror":"custom-green-mirror"},"nameSpace":"common"}\\'>\\n    <div ng-repeat="item in items2">{{item.content}}</div>\\n  </div>\\n</div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleDragOverEvents/exampleDragOverEvents.html\",\"
\\n

Drag-over events

\\n

You can interact with dragging element by litening to dragOver events. Usually you want to containers show wheather they accepts element or not, but you can use it anywhere. DragOver events are: dragenter, dragleave and dragrelease. On dragOver events dragularService reveals several useful properties.

\\n\\n
\\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n
dragularService.shared.itemitem beeing dragged (it is copy of item if copy is enabled via options)
dragularService.shared.sourcesource container item is dragged from
dragularService.shared.sourceModelsource container model representation if model was porvided
dragularService.shared.initialIndexoriginal index of item, can be used to get item model from sourceModel
dragularService.shared.extracontains accepting information (boolean) on dragenter, element drag is leaving to on dragleave and element behind the cursor on dragrelease
\\n
\\n\\n

Try to drag over the not-container too.

\\n
\\n
\\n
apples and oranges cannot be mixed
\\n
apple 2
\\n
apple 3
\\n
apple 4
\\n
\\n
\\n
orange 1
\\n
orange 2
\\n
orange 3
\\n
orange 4
\\n
\\n
\\n
apple 5
\\n
apple 6
\\n
apple 7
\\n
apple 8
\\n
\\n
\\n
orange 5
\\n
orange 6
\\n
orange 7
\\n
orange 8
\\n
\\n
\\n
Test active class on NOT container.
\\n\\n
\\n    \\n<!-- HTML -->\\n  <div class=\\'wrapper\\' ng-controller="DragOverEvents">\\n    <div class=\\'container width25\\'>\\n      <div>apples and oranges cannot be mixed</div>\\n      <div>apple 2</div>\\n      ...\\n    </div>\\n    <div class=\\'container width25\\'>\\n      <div>orange 1</div>\\n      <div>orange 2</div>\\n      ...\\n    </div>\\n    <div class=\\'container width25\\'>\\n      <div>apple 5</div>\\n      <div>apple 6</div>\\n      ...\\n    </div>\\n    <div class=\\'container width25\\'>\\n      <div>orange 5</div>\\n      <div>orange 6</div>\\n      ...\\n    </div>\\n  </div>\\n  <div class="notContainer"> Test active class on NOT container.</div>\\n    \\n  
\\n\\n
\\n    \\n  // CSS\\n  \\n.notContainer.gu-over {\\n  background-color: yellow;\\n}\\n\\n.containerVertical.gu-over-accept {\\n  background-color: green;\\n}\\n\\n.containerVertical.gu-over-decline {\\n  background-color: red;\\n}\\n    \\n  
\\n\\n
\\n    \\n  // JS\\n  controller(\\'DragOverEvents\\', [\\'$element\\', \\'dragularService\\', function TodoCtrl($element, dragularService) {\\n    dragularService.cleanEnviroment();\\n    dragularService([$element.children()[0], $element.children()[2]], {\\n      nameSpace: \\'apples\\'\\n    });\\n    dragularService([$element.children()[1], $element.children()[3]], {\\n      nameSpace: \\'oranges\\'\\n    });\\n\\n    // containers events handling\\n    function registerEvents(el) {\\n      el.on(\\'dragularenter\\', function(e) {\\n        if (el[0] === e.target) { // filter bubbled\\n          el.addClass(dragularService.shared.extra ? \\'gu-over-accept\\' : \\'gu-over-decline\\');\\n        }\\n      });\\n      el.on(\\'dragularleave dragularrelease\\', function(e) {\\n        if ((el[0] === e.target && // filter bubbled\\n          dragularService.shared.extra && // extra on dragleave contains element the drag is leaving to\\n          dragularService.shared.extra.parentElement !== e.target) // is that element child of this container?\\n          || e.type === \\'dragularrelease\\') {\\n          el.removeClass(\\'gu-over-accept\\');\\n          el.removeClass(\\'gu-over-decline\\');\\n        }\\n      });\\n    }\\n\\n    angular.forEach($element.children(), function forEachChild(el) {\\n      registerEvents(angular.element(el));\\n    });\\n\\n    // notContainer events handling\\n    var notContainer = angular.element(document.getElementsByClassName(\\'notContainer\\'));\\n    notContainer.on(\\'dragularenter\\', function() {\\n      notContainer.addClass(\\'gu-over\\');\\n    });\\n    notContainer.on(\\'dragularleave dragularrelease\\', function() {\\n      notContainer.removeClass(\\'gu-over\\');\\n    });\\n  }])\\n    \\n  
\\n
\\n\");\n\t$templateCache.put(\"exampleEvents/exampleEvents.html\",\"
\\n

Events

\\n \\n
\\n
\\n
Move me, but you can only drop me in one of these containers.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n.controller(\\'Events\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', \\'$timeout\\', function TodoCtrl($scope, $element, dragularService, $timeout) {\\n    dragularService($element.children(), {\\n      scope: $scope\\n    });\\n    $scope.$on(\\'dragulardrag\\', function(e, el) {\\n      e.stopPropagation();\\n      el.className = el.className.replace(\\' ex-moved\\', \\'\\');\\n    });\\n    $scope.$on(\\'dragulardrop\\', function(e, el) {\\n      e.stopPropagation();\\n      $timeout(function() {\\n        el.className += \\' ex-moved\\';\\n      }, 0);\\n    });\\n\\n    $scope.$on(\\'dragularcloned\\', myFn(\\'cloned\\'));\\n    $scope.$on(\\'dragulardrag\\', myFn(\\'drag\\'));\\n    $scope.$on(\\'dragularcancel\\', myFn(\\'cancel\\'));\\n    $scope.$on(\\'dragulardrop\\', myFn(\\'drop\\'));\\n    $scope.$on(\\'dragularremove\\', myFn(\\'remove\\'));\\n    $scope.$on(\\'dragulardragend\\', myFn(\\'dragend\\'));\\n    $scope.$on(\\'dragularshadow\\', myFn(\\'shadow\\'));\\n\\n    function myFn(eventName) {\\n      return function() {\\n        console.log(eventName, arguments);\\n      };\\n    }\\n\\n  }]);\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleHandle/exampleHandle.html\",\"
\\n

Handle

\\n \\n
\\n
\\n
+Move me, but you can use the plus sign to drag me around.
\\n
\\n
\\n
\\n
\\n
\\n        \\n  dragularService([document.getElementById(left), document.getElementById(right)], {\\n    moves: function (el, container, handle) {\\n      return handle.className === \\'handle\\';\\n    }\\n  });\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleIsContainerWithModel/exampleIsContainerWithModel.html\",\"
\\n

isContainer - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}\\n
\\n
\\n
\\n
\\n
\\n
Items1:\\n          
{{items1 | json}}
\\n
\\n
\\n
Cart:\\n          
{{cartModel | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  .controller(\\'IsContainerModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items1 = [{\\n      content: \\'Move me, but you can only drop me in one of these containers.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.cartModel = [];\\n\\n    var containerLeft = document.querySelector(\\'#containerLeft\\');\\n\\n    dragularService.cleanEnviroment();\\n    dragularService([containerLeft], {\\n      containersModel: [$scope.items1],\\n      copy: true,\\n      isContainer: function isContainer (el) {\\n        return el.id === \\'cart\\';\\n      },\\n      isContainerModel: function getModel (){\\n        return $scope.cartModel;\\n      }\\n    });\\n\\n    $scope.removeItem = function removeItem() {\\n      var index = $scope.cartModel.indexOf(this.item);\\n      $scope.cartModel.splice(index, 1);\\n    };\\n\\n  }])\\n        \\n        \\n<!-- HTML -->\\n <div class=\\'wrapper\\' ng-controller="IsContainerModel">\\n    <div class=\\'tableRow\\'>\\n      <div id="containerLeft" class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items1">{{item.content}}</div>\\n      </div>\\n      <div id="cart" class=\\'containerVertical\\'>\\n        <div class=\\'cursorDefault\\' ng-repeat="item in cartModel">{{item.content}}\\n        <button class=\\'cursorDefault\\' ng-click="removeItem()">x</button></div>\\n      </div>\\n    </div>\\n    <div class="tableRow">\\n      <div class=\\'containerVertical\\'>\\n        <pre>Items1:\\n          <br/>{{items1 | json}}</pre>\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <pre>Cart:\\n          <br/>{{cartModel | json}}</pre>\\n      </div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleNameSpaces/exampleNameSpaces.html\",\"
\\n

NameSpaces

\\n \\n
\\n
\\n
try to mix oranges and apples
\\n
apple 2
\\n
apple 3
\\n
apple 4
\\n
\\n
\\n
orange 1
\\n
orange 2
\\n
orange 3
\\n
orange 4
\\n
\\n
\\n
apple 5
\\n
apple 6
\\n
apple 7
\\n
apple 8
\\n
\\n
\\n
mixed 1
\\n
mixed 2
\\n
mixed 3
\\n
mixed 4
\\n
\\n
\\n
\\n      \\ndragularService([$element.children()[0], $element.children()[2]], {\\n  nameSpace: \\'apples\\'\\n});\\ndragularService($element.children()[1], {\\n  nameSpace: \\'oranges\\'\\n});\\ndragularService($element.children()[3], { // mixed\\n  nameSpace: [\\'oranges\\', \\'apples\\']\\n});\\n      \\n    
\\n
\");\n\t$templateCache.put(\"exampleNestedNgRepeat/exampleNestedNgRepeat.html\",\"
\\n

Nested ngRepeat

\\n \\n
\\n
\\n
Row {{$index}}
\\n
{{item.content}}
\\n
\\n
\\n
\\n        \\n  // HTML\\n\\n  <div ng-controller="Example15">\\n    <div ng-repeat="item in items" class=\\'exampleRow\\'>\\n      <div class="row-handle">Row {{$index}}</div>\\n      <div ng-repeat="item in item.items" class="exampleCell">{{item.content}}</div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n        \\n  // CSS\\n\\n  .exampleRow {\\n    display: flex;\\n    flex-direction: row;\\n  }\\n\\n  .exampleCell {\\n    flex-grow: 1;\\n  }\\n\\n  .exampleRow,\\n  .exampleCell {\\n    margin: 10px;\\n    padding: 10px;\\n    background-color: rgba(0, 0, 0, 0.2);\\n    cursor: move;\\n    cursor: grab;\\n    cursor: -moz-grab;\\n    cursor: -webkit-grab;\\n  }\\n        \\n      
\\n
\\n        \\n  // JS\\n\\n  .controller(\\'NestedNgRepeat\\', [\\'$timeout\\', \\'$scope\\', \\'$element\\', \\'dragularService\\', function NestedNgRepeatCtrl($timeout, $scope, $element, dragularService) {\\n    $timeout(function() { // timeount due to ngRepeat to be ready\\n      dragularService($element, {\\n        nameSpace: \\'rows\\',\\n        moves: function rowOnly (el, container, handle) {\\n          return handle.classList.contains(\\'row-handle\\');\\n        }\\n      });\\n      dragularService($element.children(), {\\n        nameSpace: \\'cells\\',\\n        moves: function excludeHandle (el, container, handle) {\\n          return !handle.classList.contains(\\'row-handle\\');\\n        }\\n      });\\n    }, 0);\\n    $scope.items = [{\\n      items: [{\\n        content: \\'Item a1\\'\\n      }, {\\n        content: \\'Item a2\\'\\n      }, {\\n        content: \\'Item a3\\'\\n      }, {\\n        content: \\'Item a4\\'\\n      }]\\n    }, {\\n      items: [{\\n        content: \\'Item b1\\'\\n      }, {\\n        content: \\'Item b2\\'\\n      }, {\\n        content: \\'Item b3\\'\\n      }, {\\n        content: \\'Item b4\\'\\n      }]\\n    }, {\\n      items: [{\\n        content: \\'Item c1\\'\\n      }, {\\n        content: \\'Item c2\\'\\n      }, {\\n        content: \\'Item c3\\'\\n      }, {\\n        content: \\'Item c4\\'\\n      }]\\n    }];\\n  }])\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleNestedNgRepeatWithModel/exampleNestedNgRepeatWithModel.html\",\"
\\n

Nested ngRepeat - with model

\\n \\n
\\n
\\n
\\n
\\n
Row {{::$index}}
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n            
Items:\\n
{{items | json}}
\\n
\\n
\\n
\\n
\\n
\\n    \\n<!-- HTML -->\\n<div ng-controller="NestedNgRepeatWithModel">\\n  <div class=\\'containerVertical\\'>\\n    <div ng-repeat="item in items" class=\\'exampleRow\\'>\\n      <div class="row-handle">Row {{::$index}}</div>\\n      <div class="exampleRow exampleCell containerNested">\\n        <div ng-repeat="item in item.items" class="exampleCell">{{item.content}}</div>\\n      </div>\\n    </div>\\n  </div>\\n</div>\\n    \\n  
\\n
\\n    \\n  // CSS\\n\\n  .exampleRow {\\n    display: flex;\\n    flex-direction: row;\\n  }\\n\\n  .exampleCell {\\n    flex-grow: 1;\\n  }\\n\\n  .exampleRow,\\n  .exampleCell {\\n    margin: 10px;\\n    padding: 10px;\\n    background-color: rgba(0, 0, 0, 0.2);\\n    cursor: move;\\n    cursor: grab;\\n    cursor: -moz-grab;\\n    cursor: -webkit-grab;\\n  }\\n    \\n  
\\n
\\n    \\n  // JS\\n.controller(\\'NestedNgRepeatWithModel\\', [\\'$timeout\\', \\'$scope\\', \\'$element\\', \\'dragularService\\', function NestedNgRepeatWithModelCtrl($timeout, $scope, $element, dragularService) {\\n    $timeout(function() { // timeount due to nested ngRepeat to be ready\\n      var container = $element.children().eq(0).children(),\\n        parentContainers = container.children(),\\n        nestedContainers = [];\\n\\n      dragularService(container, {\\n        moves: function(el, container, handle) {\\n          return handle.classList.contains(\\'row-handle\\');\\n        },\\n        containersModel: $scope.items,\\n        nameSpace: \\'rows\\'\\n      });\\n\\n      // collect nested contianers\\n      for (var i = 0; i < parentContainers.length; i++) {\\n        nestedContainers.push(parentContainers.eq(i).children()[1]);\\n      }\\n\\n      dragularService(nestedContainers, {\\n        moves: function(el, container, handle) {\\n          return !handle.classList.contains(\\'row-handle\\');\\n        },\\n        containersModel: (function getNestedContainersModel(){\\n          var parent = $scope.items,\\n            containersModel = [];\\n          for (var i = 0; i < parent.length; i++) {\\n            containersModel.push(parent[i].items);\\n          }\\n          return containersModel;\\n        })(),\\n        nameSpace: \\'cells\\'\\n      });\\n    }, 0);\\n    $scope.items = [{\\n      items: [{\\n        content: \\'Item a1\\'\\n      }, {\\n        content: \\'Item a2\\'\\n      }, {\\n        content: \\'Item a3\\'\\n      }, {\\n        content: \\'Item a4\\'\\n      }]\\n    }, {\\n      items: [{\\n        content: \\'Item b1\\'\\n      }, {\\n        content: \\'Item b2\\'\\n      }, {\\n        content: \\'Item b3\\'\\n      }, {\\n        content: \\'Item b4\\'\\n      }]\\n    }, {\\n      items: [{\\n        content: \\'Item c1\\'\\n      }, {\\n        content: \\'Item c2\\'\\n      }, {\\n        content: \\'Item c3\\'\\n      }, {\\n        content: \\'Item c4\\'\\n      }]\\n    }];\\n  }])\\n    \\n  
\\n
\\n\");\n\t$templateCache.put(\"exampleNgRepeat/exampleNgRepeat.html\",\"
\\n

ngRepeat

\\n \\n
\\n
\\n
\\n {{item.content}}\\n
\\n
\\n
\\n
\\n        \\n  // HTML:\\n  <div class=\\'containerVertical\\'>\\n    <div ng-repeat="item in items">\\n      {{item.content}}\\n    </div>\\n  </div>\\n\\n  // JS:\\n  dragularService($element.children());\\n  $scope.items = [{\\n    content: \\'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.\\'\\n  },{\\n    content: \\'Item 2\\'\\n  },{\\n    content: \\'Item 3\\'\\n  },{\\n    content: \\'Item 4\\'\\n  }];\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel.html\",\"
\\n

Filtered ngRepeat - with model

\\n \\n
\\n
\\n
\\n \\n
\\n
\\n \\n
\\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n          
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n          
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  .controller(\\'NgRepeatFilteredWithModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', \\'$filter\\', function TodoCtrl($scope, $element, dragularService, $filter) {\\n    $scope.items1 = [{\\n      content: \\'Move me, but you can only drop me in one of these containers.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than these containers, I\\\\\\'ll just come back.\\'\\n    }, {\\n      content: \\'Apple 3\\'\\n    }, {\\n      content: \\'Orange 4\\'\\n    }, {\\n      content: \\'Orange 5\\'\\n    }, {\\n      content: \\'Apple 6\\'\\n    }, {\\n      content: \\'Apple 7\\'\\n    }, {\\n      content: \\'Apple 8\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'Apple 9\\'\\n    }, {\\n      content: \\'Orange 10\\'\\n    }, {\\n      content: \\'Orange 11\\'\\n    }, {\\n      content: \\'Apple 12\\'\\n    }, {\\n      content: \\'Orange 13\\'\\n    }, {\\n      content: \\'Apple 14\\'\\n    }];\\n    $scope.filter1query = \\'Orange\\';\\n    $scope.filter2query = \\'Orange\\';\\n    $scope.filteredModel1 = [];\\n    $scope.filteredModel2 = [];\\n    $scope.getFilteredModel = function (filteredModel, items, filterQuery) {\\n      filteredModel.length = 0;\\n      /*\\n      * Following one-liner is same like:\\n      *   var filteredModelTemp = $filter(\\'filter\\')(items, filterQuery);\\n      *   angular.forEach(filteredModelTemp, function(item){\\n      *     filteredModel.push(item);\\n      *   });\\n      * Or like:\\n      *   var filteredModelTemp = $filter(\\'filter\\')(items, filterQuery);\\n      *   for(var i; i < filteredModelTemp.length; i++){\\n      *     filteredModel.push(filteredModelTemp[i]);\\n      *   }\\n      *\\n      * You cannot just assign filtered array to filteredModel like this:\\n      *   filteredModel = $filter(\\'filter\\')(items, filterQuery);\\n      * Because you would replace the array object you provide to dragular with new one.\\n      * So dragular will continue to use the one it was provided on init.\\n      * Hopefully I make it clear. :)\\n       */\\n      [].push.apply(filteredModel, $filter(\\'filter\\')(items, filterQuery));\\n      return filteredModel;\\n    };\\n    var containers = $element.children().eq(1).children();\\n    dragularService.cleanEnviroment();\\n    dragularService([containers[0],containers[1]],{\\n      containersModel: [$scope.items1, $scope.items2],\\n      containersFilteredModel: [$scope.filteredModel1, $scope.filteredModel2]\\n    });\\n  }]);\\n\\n        \\n        \\n<!-- HTML -->\\n  <div class=\\'wrapper\\' ng-controller="NgRepeatFilteredWithModel">\\n    <div class="tableRow">\\n      <div class=\\'containerVertical\\'>\\n        <input ng-model="filter1query" style="margin:10px 10px">\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <input ng-model="filter2query" style="margin:10px 10px">\\n      </div>\\n    </div>\\n    <div class=\\'tableRow\\'>\\n      <div class=\\'containerVertical\\'>\\n        <div ng-repeat="item in getFilteredModel(filteredModel1, items1, filter1query)">{{item.content}}</div>\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <div ng-repeat="item in getFilteredModel(filteredModel2, items2, filter2query)">{{item.content}}</div>\\n      </div>\\n    </div>\\n    <div class="tableRow">\\n      <div class=\\'containerVertical\\'>\\n        <pre>Items1:\\n          <br/>{{items1 | json}}</pre>\\n      </div>\\n      <div class=\\'containerVertical\\'>\\n        <pre>Items2:\\n          <br/>{{items2 | json}}</pre>\\n      </div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleNgRepeatWithModel/exampleNgRepeatWithModel.html\",\"
\\n

ngRepeat - with model

\\n \\n
\\n
\\n
\\n
\\n {{item.content}}\\n \\n \\n
\\n
\\n
\\n
\\n
\\n
Items:\\n
{{items | json}}
\\n
\\n
\\n
\\n
\\n    \\n  // HTML:\\n   <div class=\\'wrapper\\' ng-controller="NgRepeatWithModel">\\n      <div class=\\'containerVertical\\'>\\n        <div ng-repeat="item in items">\\n          {{item.content}}\\n          <button class=\\'cursorDefault\\' ng-click="addItem()">+</button>\\n          <button class=\\'cursorDefault\\' ng-click="removeItem()">x</button>\\n        </div>\\n    </div>\\n  </div>\\n    \\n  
\\n
\\n    \\n  // JS:\\n  controller(\\'NgRepeatWithModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items = [{\\n      content: \\'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.\\'\\n    }, {\\n      content: \\'Item 2\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    dragularService($element.children().eq(0).children(), {containersModel: $scope.items});\\n    $scope.addItem = function addItem() {\\n      var index = $scope.items.indexOf(this.item) + 1;\\n      $scope.items.splice(index, 0, {\\n        content: this.item.content + \\'-copy\\'\\n      });\\n    };\\n    $scope.removeItem = function removeItem() {\\n      var index = $scope.items.indexOf(this.item);\\n      $scope.items.splice(index, 1);\\n    };\\n  }])\\n    \\n  
\\n
\\n\");\n\t$templateCache.put(\"exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel.html\",\"
\\n

Remove on spill - with model

\\n \\n
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
{{item.content}}
\\n
\\n
\\n
\\n
\\n
Items1:\\n          
{{items1 | json}}
\\n
\\n
\\n
Items2:\\n          
{{items2 | json}}
\\n
\\n
\\n
\\n
\\n        \\n// JS\\n  .controller(\\'RemoveOnSpillWithModel\\', [\\'$scope\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($scope, $element, dragularService) {\\n    $scope.items1 = [{\\n      content: \\'Move me, but you can only drop me in containers.\\'\\n    }, {\\n      content: \\'If you try to drop me somewhere other than containers, I\\\\\\'ll die a fiery death.\\'\\n    }, {\\n      content: \\'Item 3\\'\\n    }, {\\n      content: \\'Item 4\\'\\n    }];\\n    $scope.items2 = [{\\n      content: \\'You can drop me in the left container.\\'\\n    }, {\\n      content: \\'Item 6\\'\\n    }, {\\n      content: \\'Item 7\\'\\n    }, {\\n      content: \\'Item 8\\'\\n    }];\\n    var containers = $element.children().eq(0).children();\\n    dragularService.cleanEnviroment();\\n    dragularService([containers[0],containers[1]],{\\n      containersModel: [$scope.items1, $scope.items2],\\n      removeOnSpill: true\\n    });\\n  }])\\n        \\n        \\n<!-- HTML -->\\n<div class=\\'wrapper\\' ng-controller="Basic">\\n    <div class=\\'tableRow\\'>\\n        <div class=\\'containerVertical\\'>\\n            <div ng-repeat="item in items1">{{item.content}}</div>\\n        </div>\\n        <div class=\\'containerVertical\\'>\\n            <div ng-repeat="item in items2">{{item.content}}</div>\\n        </div>\\n    </div>\\n    <div class="tableRow">\\n        <div class="container">\\n            <div>Items1:\\n                <br/>{{items1 | json}}</div>\\n        </div>\\n        <div class="container">\\n            <div>Items2:\\n                <br/>{{items2 | json}}</div>\\n        </div>\\n    </div>\\n</div>\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"exampleRemoveOnSpill/exampleRemoveOnSpill.html\",\"
\\n

Remove on spill

\\n \\n
\\n
\\n
Move me, but you can only drop me in containers.
\\n
If you try to drop me somewhere other than containers, I\\'ll die a fiery death.
\\n
Item 3.
\\n
Item 6.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
You can drop me in the left container.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n  dragularService([document.getElementById(single)], { removeOnSpill: true });\\n        \\n      
\\n
\");\n\t$templateCache.put(\"exampleRevertOnSpill/exampleRevertOnSpill.html\",\"
\\n

Revert on spill

\\n \\n
\\n
\\n
Move me, but you can only drop me in one of these containers.
\\n
If you try to drop me somewhere other than these containers, I\\'ll just come back.
\\n
Item 3.
\\n
Item 6.
\\n
\\n
\\n
You can drop me in the left container, otherwise I\\'ll stay here.
\\n
Item 4.
\\n
Item 5.
\\n
\\n
\\n
\\n        \\n  dragularService([document.getElementById(left), document.getElementById(right)], { revertOnSpill: true });\\n        \\n      
\\n
\");\n\t$templateCache.put(\"exampleScrollingDrag/exampleScrollingDrag.html\",\"
\\n

Scrolling drag

\\n \\n
\\n
\\n
up
\\n
\\n
Item 1.
\\n
Item 2.
\\n
Item 3.
\\n
Item 4.
\\n
Item 5.
\\n
Item 6.
\\n
Item 7.
\\n
Item 9.
\\n
Item 10.
\\n
Item 11.
\\n
Item 12.
\\n
Item 13.
\\n
\\n
down
\\n
\\n
\\n
\\n
\\n
Item 1.
\\n
Item 2.
\\n
Item 3.
\\n
Item 4.
\\n
Item 5.
\\n
Item 6.
\\n
Item 7.
\\n
Item 9.
\\n
Item 10.
\\n
Item 11.
\\n
Item 12.
\\n
Item 13.
\\n
\\n
\\n
\\n
\\n
\\n        \\n// JS\\ncontroller(\\'ScrollingDrag\\', [\\'$interval\\', \\'$element\\', \\'dragularService\\', function TodoCtrl($interval, $element, dragularService) {\\n\\n\\n    var timer,\\n      leftScrollContainer = document.getElementById(\\'leftScroll\\'),\\n      rightScrollContainer = document.getElementById(\\'rightScroll\\'),\\n      leftTopBar = document.getElementById(\\'leftTopBar\\'),\\n      leftBottomBar = document.getElementById(\\'leftBottomBar\\'),\\n      rightTopBar = document.getElementById(\\'rightTopBar\\'),\\n      rightBottomBar = document.getElementById(\\'rightBottomBar\\');\\n\\n    dragularService.cleanEnviroment();\\n    dragularService([leftScrollContainer, rightScrollContainer]);\\n\\n    registerEvents(leftTopBar, leftScrollContainer, -5);\\n    registerEvents(leftBottomBar, leftScrollContainer, 5);\\n    registerEvents(rightTopBar, rightScrollContainer, -5);\\n    registerEvents(rightBottomBar, rightScrollContainer, 5);\\n\\n    function registerEvents(bar, container, inc, speed) {\\n      if (!speed) {\\n        speed = 20;\\n      }\\n      angular.element(bar).on(\\'dragularenter\\', function() {\\n        container.scrollTop += inc;\\n        timer = $interval(function moveScroll() {\\n          container.scrollTop += inc;\\n        }, speed);\\n      });\\n      angular.element(bar).on(\\'dragularleave dragularrelease\\', function() {\\n        $interval.cancel(timer);\\n      });\\n    }\\n  }])\\n        \\n      
\\n
\\n        \\n<!-- HTML -->\\n<div ng-controller="ScrollingDrag">\\n    <div class="containerVertical scrollingDrag">\\n      <div class="scrollBar" id="leftTopBar">up</div>\\n      <div id="leftScroll" class="scrollingDragInner">\\n        <div>Item 1</div>\\n        <div>Item 2</div>\\n            ...\\n      </div>\\n      <div class="scrollBar" id="leftBottomBar">down</div>\\n    </div>\\n    <div class="containerVertical scrollingDrag">\\n      <div class="scrollBar" id="rightTopBar">up</div>\\n      <div id="rightScroll" class="scrollingDragInner">\\n        <div>Item 1</div>\\n        <div>Item 2</div>\\n            ...\\n      </div>\\n      <div class="scrollBar" id="rightBottomBar">down</div>\\n    </div>\\n  </div>\\n        \\n      
\\n
\\n        \\n// CSS\\n.scrollingDrag {\\n  width: 45%;\\n  display: inline-block;\\n}\\n\\n.scrollingDragInner {\\n  max-height: 200px;\\n  overflow-y: auto;\\n}\\n\\n#rightTopBar,\\n#rightBottomBar {\\n  background: transparent;\\n  position: relative;\\n  height: 20px;\\n}\\n\\n#rightTopBar {\\n  top: 10px;\\n}\\n\\n#rightBottomBar {\\n  bottom: 10px;\\n}\\n\\ndiv.scrollBar {\\n  background: yellow;\\n  text-align: center;\\n  padding: 1px;\\n}\\n\\n        \\n      
\\n
\\n\");\n\t$templateCache.put(\"partials/partial-contribute.html\",\"
\\n
\\n
\\n \\n
\\n
\\n
\\n\");\n\t$templateCache.put(\"partials/partial-docs.html\",\"
\\n
\\n
\\n \\n
\\n \\n
\\n

\\n \\n

\\n \\n
\\n
\\n \\n
\\n \\n
\\n\");\n\t$templateCache.put(\"partials/partial-home.html\",\"
\\n
\\n \\n
\\n
\\n

DRAGULAR

\\n

Angular drag&drop based on dragula.

\\n

Live examples in docs

\\n
\\n
\\n
\\n

Browser support includes every sane browser and **IE7+**. _(Granted you polyfill the functional `Array` methods in ES5)_

\\n

Inspiration

\\n

I am working on huge angular project and I am using several drag&drop libraries in it, one for UI, one for lists, etc.. I want to use one full-featured drag&drop library for whole project. As I could not find any suitable, I decided to create one. I have choosen great library dragula by Nicolas Bevacqua as my starting point, make it more angular and started to put features in it! If you wish light-weight angular version of dragula, there is official angular version of dragula.

\\n

Actual version 4.2.0 is based on dragula 3.6.3 and tested with angular 1.5.5.

\\n

Differences of dragular (against dragula)

\\n
    \\n
  • replaced dragula crossvent with angulars event binding
  • \\n
  • replaced dragula contra.emitter with $scope.$emit if scope provided in options (options.scope)
  • \\n
  • provided as service or directive dragular where options can be passed via atribute dragular
  • \\n
  • automatic direction if not provided in options, instead of default vertical
  • \\n
  • accepting arraylike objects as containers array (jQuery, jQlite collections etc..)
  • \\n
  • accepting custom classes via option.classes
  • \\n
  • namespaced containers groups available via option.nameSpace (containers in same nameSpace cooperate)
  • \\n
  • boundingBox (dragging element can me moved only in specific area)
  • \\n
  • lockX/Y (dragging element can me moved only in specific direction)
  • \\n
  • DOM can be synced with scope model
  • \\n
  • support css selectors to define containers
  • \\n
  • added syntax highlighter to example codes
  • \\n
  • etc..
  • \\n
\\n

Todo

\\n
    \\n
  • improve docs
  • \\n
\\n

Features

\\n
    \\n
  • provided as service and also as directive
  • \\n
  • Super easy to set up
  • \\n
  • No bloated dependencies
  • \\n
  • Figures out sort order on its own
  • \\n
  • A shadow where the item would be dropped offers visual feedback
  • \\n
  • Touch events!
  • \\n
\\n

For installation, usage and examples go to docs

\\n
\\n
\\n \\n
\\n \\n
\\n \\n
\\n\");\n\t$templateCache.put(\"partials/autogenerated/contribute.html\",\"

How to contribute

\\n

It's important to us that you feel you can contribute towards the evolution of Dragular. This can take many forms: from helping to fix bugs or improve the docs, to adding in new features to the source. This guide should help you in making that process as smooth as possible.

\\n

Before contributing, please read the code of conduct.

\\n

Reporting issues

\\n

GitHub Issues is the place to report bugs you may have found in either the core library or any of the examples that are part of the repository. When submitting a bug please do the following:

\\n

1. Search for existing issues. Your bug may have already been fixed or addressed in a development branch version of Dragular, so be sure to search the issues first before putting in a duplicate issue.

\\n

2. Not sure if it's a bug?. Then please ask via issues and tag it [question].

\\n

3. Create an isolated and reproducible test case. If you are reporting a bug, make sure you also have a minimal, runnable, code example that reproduces the problem you have.

\\n

4. Include a live example. After narrowing your code down to only the problem areas, make use of jsFiddle, jsBin, or a link to your live site so that we can view a live example of the problem. (you can start by forking this fiddle)

\\n

5. Share as much information as possible. Include browser version affected, your OS, version of the library, steps to reproduce, etc. "X isn't working!!!1!" will probably just be closed.

\\n

Dev vs. Master

\\n

The dev branch of Dragular is our 'current working' version. It is always ahead of the master branch in terms of features and fixes. However it's also bleeding-edge and experimental and we cannot and do not guarantee it will compile or work for you. Very often we have to break things for a few days while we rebuild and patch. So by all means please export the dev branch and contribute towards it, indeed that is where all Pull Requests should be sent, but do so understanding the API may change beneath you.

\\n

Making Changes

\\n

To take advantage of our npm build script and jshint config it will be easiest for you if you have node.js installed locally.

\\n

You can download node.js from nodejs.org.

\\n

After that you can clone the repository and run npm i inside the cloned folder. This will install dependencies necessary for building the project. For development workflow automation dragular uses gulp >= 3.9.0. Before starting development, make sure that gulp is installed on your machine globally: npm i -g gulp.

\\n

Developing

\\n

There are several gulp tasks that are used for generating different builds:

\\n
    \\n
  • gulp dev - Serves files with BrowserSync server, watches & automatically refreshes connected browsers on changes, generates non-minified but concatenated styles & scripts from the dragular source.
  • \\n
  • gulp dev:docs - Does exactly the same as gulp dev, except it works with the documentation source.
  • \\n
  • gulp build - Concatenates and minifies dragular source files.
  • \\n
  • gulp build:docs - Concatenates and minifies documentation source files.
  • \\n
\\n

Linting

\\n
    \\n
  • gulp lint & gulp lint:docs - Lint JavaScript files.
  • \\n
\\n

Making a pull request

\\n

Once that is ready, make your changes and submit a Pull Request:

\\n
    \\n
  • Send Pull Requests to the dev branch. All Pull Requests must be sent to the dev branch, master is the latest release and PRs to that branch will be closed.

    \\n
  • \\n
  • Ensure changes are jshint validated. Our JSHint configuration file is provided in the repository and you should check against it before submitting.

    \\n
  • \\n
  • Only commit relevant changes. Don't include changes that are not directly relevant to the fix you are making. The more focused a PR is, the faster it will get attention and be merged. Extra files changing only whitespace or trash files will likely get your PR closed.

    \\n
  • \\n
\\n

Dependencies for building from source and running tests:

\\n

Coding style preferences are not contributions

\\n

If your PR is doing little more than changing the Dragular source code into a format / coding style that you prefer then we will automatically close it. All PRs must adhere to the coding style already set-out across the lines of code in Dragular. Your personal preferences for how things should "look" or be structured do not apply here, sorry. PRs should fix bugs, fix documentation or add features. No changes for the sake of change.

\\n

I don't really like git / node.js, but I can fix this bug

\\n

That is fine too. While Pull Requests are the best thing in the world for us, they are not the only way to help. You're welcome to post fixes to our forum or even just email them to us. All we ask is that you still adhere to the guidelines presented here re: JSHint, etc.

\\n\");}]);\n\n/***/ }\n/******/ ])\n});\n;"],"sourceRoot":"/source/"} \ No newline at end of file diff --git a/docs/src/examples/examplesApp.js b/docs/src/examples/examplesApp.js index 5dc1f7e7..da0d36e2 100644 --- a/docs/src/examples/examplesApp.js +++ b/docs/src/examples/examplesApp.js @@ -24,7 +24,7 @@ var NameSpacesCtrl = require('./exampleNameSpaces/exampleNameSpaces'); var NestedNgRepeatCtrl = require('./exampleNestedNgRepeat/exampleNestedNgRepeat'); var NestedNgRepeatWithModelCtrl = require('./exampleNestedNgRepeatWithModel/exampleNestedNgRepeatWithModel'); var NgRepeatCtrl = require('./exampleNgRepeat/exampleNgRepeat'); -var NgRepeatFilteredWithModelCtrl = require('./exampleNgRepeat/exampleNgRepeat'); +var NgRepeatFilteredWithModelCtrl = require('./exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel'); var NgRepeatWithModelCtrl = require('./exampleNgRepeatWithModel/exampleNgRepeatWithModel'); var RemoveOnSpillCtrl = require('./exampleRemoveOnSpill/exampleRemoveOnSpill'); var RemoveOnSpillWithModelCtrl = require('./exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel'); diff --git a/docs/src/examples/partials/partial-home.html b/docs/src/examples/partials/partial-home.html index c15d168a..0e81fc3f 100644 --- a/docs/src/examples/partials/partial-home.html +++ b/docs/src/examples/partials/partial-home.html @@ -12,7 +12,7 @@

DRAGULAR

Browser support includes every sane browser and **IE7+**. _(Granted you polyfill the functional `Array` methods in ES5)_

Inspiration

I am working on huge angular project and I am using several drag&drop libraries in it, one for UI, one for lists, etc.. I want to use one full-featured drag&drop library for whole project. As I could not find any suitable, I decided to create one. I have choosen great library dragula by Nicolas Bevacqua as my starting point, make it more angular and started to put features in it! If you wish light-weight angular version of dragula, there is official angular version of dragula.

-

Actual version 4.1.0 is based on dragula 3.6.3 and tested with angular 1.4.9.

+

Actual version 4.2.0 is based on dragula 3.6.3 and tested with angular 1.5.5.

Differences of dragular (against dragula)

  • replaced dragula crossvent with angulars event binding
  • diff --git a/docs/src/examples/templates.js b/docs/src/examples/templates.js index 79b3788f..55170300 100644 --- a/docs/src/examples/templates.js +++ b/docs/src/examples/templates.js @@ -1,6 +1,6 @@ 'use strict'; module.exports = angular.module("templates", []).run(["$templateCache", function($templateCache) {$templateCache.put("docsInstall/docsInstall.html","

    Install

    \n

    download dragular.js and dragular.css from dist folder

    \n

    OR clone git

    \n
    \ngit clone http://github.com/luckylooke/dragular.git\n
    \n

    OR use npm

    \n
    \n[sudo] npm install dragular\n
    \n

    OR use bower

    \n
    \nbower install dragular\n
    \n

    AND include files into your project

    \n
    \n<link href=\'styles/dragular.css\' rel=\'stylesheet\' type=\'text/css\' />\n<script src=\'scripts/dragular.js\'></script>\n
    \n

    AND put dragularModule into dependency array

    \n
    \nvar app = angular.module(\'myApp\', [\'dragularModule\', \'otherDependencies\']);\n
    \n

    DONE :)

    \n"); -$templateCache.put("exampleBasicWithModel/exampleBasicWithModel.html","
    \n

    Basic - with model

    \n \n
    \n
    \n
    \n
    {{item.content}}
    \n
    \n
    \n
    {{item.content}}
    \n
    \n
    \n
    \n
    \n
    Items1:\n          
    {{items1 | json}}
    \n
    \n
    \n
    Items2:\n          
    {{items2 | json}}
    \n
    \n
    \n
    \n
    \n        \n// JS\n  controller(\'BasicModel\', [\'$scope\', \'$element\', \'dragularService\', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: \'Move me, but you can only drop me in one of these containers.\'\n    }, {\n      content: \'If you try to drop me somewhere other than these containers, I\\\'ll just come back.\'\n    }, {\n      content: \'Item 3\'\n    }, {\n      content: \'Item 4\'\n    }];\n    $scope.items2 = [{\n      content: \'Item 5\'\n    }, {\n      content: \'Item 6\'\n    }, {\n      content: \'Item 7\'\n    }, {\n      content: \'Item 8\'\n    }];\n    var containers = $element.children().children();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2]\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class=\'wrapper\' ng-controller="Basic">\n    <div class=\'tableRow\'>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items1">{{item.content}}</div>\n        </div>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items2">{{item.content}}</div>\n        </div>\n    </div>\n    <div class="tableRow">\n        <div class="container">\n            <div>Items1:\n                <br/>{{items1 | json}}</div>\n        </div>\n        <div class="container">\n            <div>Items2:\n                <br/>{{items2 | json}}</div>\n        </div>\n    </div>\n</div>\n        \n      
    \n
    \n"); $templateCache.put("exampleBasic/exampleBasic.html","
    \n

    Basic

    \n \n
    \n
    \n
    Move me, but you can only drop me in one of these containers.
    \n
    If you try to drop me somewhere other than these containers, I\'ll just come back.
    \n
    Item 3.
    \n
    Item 6.
    \n
    \n
    \n
    You can drop me in the left container, otherwise I\'ll stay here.
    \n
    Try to click me, dragular distinguish drag from click
    \n
    Item 5.
    \n
    \n
    \n
    \n        \n// JS\n  controller(\'Basic\', [\'$element\', \'dragularService\', function TodoCtrl($element, dragularService) {\n    dragularService(\'.containerVertical\');\n  }])\n        \n        \n// CSS\n.clickedClass {\n  background-color: orange !important;\n}\n        \n        \n<!-- HTML -->\n  <div class=\'wrapper\' ng-controller="Basic">\n    <div class=\'containerVertical\'>\n        <div>Move me, but you can only drop me in one of these containers.</div>\n        <div>If you try to drop me somewhere other than these containers, I\'ll just come back.</div>\n        <div>Item 3.</div>\n        <div>Item 6.</div>\n    </div>\n    <div class=\'containerVertical\'>\n        <div>You can drop me in the left container, otherwise I\'ll stay here.</div>\n        <div ng-click=\"clicked = !clicked\" ng-class=\"clicked && \'clickedClass\'\">Try to click me, dragular distinguish drag from click</div>\n        <div>Item 5.</div>\n    </div>\n</div>\n        \n      
    \n
    \n"); +$templateCache.put("exampleBasicWithModel/exampleBasicWithModel.html","
    \n

    Basic - with model

    \n \n
    \n
    \n
    \n
    {{item.content}}
    \n
    \n
    \n
    {{item.content}}
    \n
    \n
    \n
    \n
    \n
    Items1:\n          
    {{items1 | json}}
    \n
    \n
    \n
    Items2:\n          
    {{items2 | json}}
    \n
    \n
    \n
    \n
    \n        \n// JS\n  controller(\'BasicModel\', [\'$scope\', \'$element\', \'dragularService\', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: \'Move me, but you can only drop me in one of these containers.\'\n    }, {\n      content: \'If you try to drop me somewhere other than these containers, I\\\'ll just come back.\'\n    }, {\n      content: \'Item 3\'\n    }, {\n      content: \'Item 4\'\n    }];\n    $scope.items2 = [{\n      content: \'Item 5\'\n    }, {\n      content: \'Item 6\'\n    }, {\n      content: \'Item 7\'\n    }, {\n      content: \'Item 8\'\n    }];\n    var containers = $element.children().children();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2]\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class=\'wrapper\' ng-controller="Basic">\n    <div class=\'tableRow\'>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items1">{{item.content}}</div>\n        </div>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items2">{{item.content}}</div>\n        </div>\n    </div>\n    <div class="tableRow">\n        <div class="container">\n            <div>Items1:\n                <br/>{{items1 | json}}</div>\n        </div>\n        <div class="container">\n            <div>Items2:\n                <br/>{{items2 | json}}</div>\n        </div>\n    </div>\n</div>\n        \n      
    \n
    \n"); $templateCache.put("exampleBoundingBox/exampleBoundingBox.html","
    \n

    BoundingBox

    \n \n
    \n
    \n
    This items cannot cross its example element, just try it your selves.
    \n
    Item 2.
    \n
    Item 3.
    \n
    Item 6.
    \n
    \n
    \n
    This items cannot cross its example element, just try it your selves.
    \n
    Item 4.
    \n
    Item 5.
    \n
    \n
    \n
    \n        \n  dragularService([$element.children(), {\n    boundingBox: $element\n  });\n        \n      
    \n
    "); $templateCache.put("exampleBoundingBoxLockX/exampleBoundingBoxLockX.html","
    \n

    BoundingBox and lockX

    \n \n
    \n
    \n
    \n
    Items are locked in X axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
    \n
    item 2
    \n
    item 3
    \n
    item 4
    \n
    \n
    \n
    \n
    \n        \n  dragularService([$element.children()[0].children(), {\n    boundingBox: $element.children()[0],\n    lockX: true\n  });\n        \n      
    \n
    "); $templateCache.put("exampleBoundingBoxLockY/exampleBoundingBoxLockY.html","
    \n

    BoundingBox and LockY

    \n \n
    \n
    \n
    \n
    Items are locked in Y axis movement and cannot cross its closest parent div.boundingBox, just try it your selves.
    \n
    item 2
    \n
    item 3
    \n
    item 4
    \n
    item 5
    \n
    item 6
    \n
    \n
    \n
    \n
    \n        \n  dragularService([$element.children()[0].children(), {\n    boundingBox: $element.children()[0],\n    lockY: true\n  });\n        \n      
    \n
    "); @@ -20,11 +20,11 @@ $templateCache.put("exampleNestedNgRepeatWithModel/exampleNestedNgRepeatWithMode $templateCache.put("exampleNgRepeat/exampleNgRepeat.html","
    \n

    ngRepeat

    \n \n
    \n
    \n
    \n {{item.content}}\n
    \n
    \n
    \n
    \n        \n  // HTML:\n  <div class=\'containerVertical\'>\n    <div ng-repeat="item in items">\n      {{item.content}}\n    </div>\n  </div>\n\n  // JS:\n  dragularService($element.children());\n  $scope.items = [{\n    content: \'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.\'\n  },{\n    content: \'Item 2\'\n  },{\n    content: \'Item 3\'\n  },{\n    content: \'Item 4\'\n  }];\n        \n      
    \n
    \n"); $templateCache.put("exampleNgRepeatFilteredWithModel/exampleNgRepeatFilteredWithModel.html","
    \n

    Filtered ngRepeat - with model

    \n \n
    \n
    \n
    \n \n
    \n
    \n \n
    \n
    \n
    \n
    \n
    {{item.content}}
    \n
    \n
    \n
    {{item.content}}
    \n
    \n
    \n
    \n
    \n
    Items1:\n          
    {{items1 | json}}
    \n
    \n
    \n
    Items2:\n          
    {{items2 | json}}
    \n
    \n
    \n
    \n
    \n        \n// JS\n  .controller(\'NgRepeatFilteredWithModel\', [\'$scope\', \'$element\', \'dragularService\', \'$filter\', function TodoCtrl($scope, $element, dragularService, $filter) {\n    $scope.items1 = [{\n      content: \'Move me, but you can only drop me in one of these containers.\'\n    }, {\n      content: \'If you try to drop me somewhere other than these containers, I\\\'ll just come back.\'\n    }, {\n      content: \'Apple 3\'\n    }, {\n      content: \'Orange 4\'\n    }, {\n      content: \'Orange 5\'\n    }, {\n      content: \'Apple 6\'\n    }, {\n      content: \'Apple 7\'\n    }, {\n      content: \'Apple 8\'\n    }];\n    $scope.items2 = [{\n      content: \'Apple 9\'\n    }, {\n      content: \'Orange 10\'\n    }, {\n      content: \'Orange 11\'\n    }, {\n      content: \'Apple 12\'\n    }, {\n      content: \'Orange 13\'\n    }, {\n      content: \'Apple 14\'\n    }];\n    $scope.filter1query = \'Orange\';\n    $scope.filter2query = \'Orange\';\n    $scope.filteredModel1 = [];\n    $scope.filteredModel2 = [];\n    $scope.getFilteredModel = function (filteredModel, items, filterQuery) {\n      filteredModel.length = 0;\n      /*\n      * Following one-liner is same like:\n      *   var filteredModelTemp = $filter(\'filter\')(items, filterQuery);\n      *   angular.forEach(filteredModelTemp, function(item){\n      *     filteredModel.push(item);\n      *   });\n      * Or like:\n      *   var filteredModelTemp = $filter(\'filter\')(items, filterQuery);\n      *   for(var i; i < filteredModelTemp.length; i++){\n      *     filteredModel.push(filteredModelTemp[i]);\n      *   }\n      *\n      * You cannot just assign filtered array to filteredModel like this:\n      *   filteredModel = $filter(\'filter\')(items, filterQuery);\n      * Because you would replace the array object you provide to dragular with new one.\n      * So dragular will continue to use the one it was provided on init.\n      * Hopefully I make it clear. :)\n       */\n      [].push.apply(filteredModel, $filter(\'filter\')(items, filterQuery));\n      return filteredModel;\n    };\n    var containers = $element.children().eq(1).children();\n    dragularService.cleanEnviroment();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2],\n      containersFilteredModel: [$scope.filteredModel1, $scope.filteredModel2]\n    });\n  }]);\n\n        \n        \n<!-- HTML -->\n  <div class=\'wrapper\' ng-controller="NgRepeatFilteredWithModel">\n    <div class="tableRow">\n      <div class=\'containerVertical\'>\n        <input ng-model="filter1query" style="margin:10px 10px">\n      </div>\n      <div class=\'containerVertical\'>\n        <input ng-model="filter2query" style="margin:10px 10px">\n      </div>\n    </div>\n    <div class=\'tableRow\'>\n      <div class=\'containerVertical\'>\n        <div ng-repeat="item in getFilteredModel(filteredModel1, items1, filter1query)">{{item.content}}</div>\n      </div>\n      <div class=\'containerVertical\'>\n        <div ng-repeat="item in getFilteredModel(filteredModel2, items2, filter2query)">{{item.content}}</div>\n      </div>\n    </div>\n    <div class="tableRow">\n      <div class=\'containerVertical\'>\n        <pre>Items1:\n          <br/>{{items1 | json}}</pre>\n      </div>\n      <div class=\'containerVertical\'>\n        <pre>Items2:\n          <br/>{{items2 | json}}</pre>\n      </div>\n    </div>\n  </div>\n        \n      
    \n
    \n"); $templateCache.put("exampleNgRepeatWithModel/exampleNgRepeatWithModel.html","
    \n

    ngRepeat - with model

    \n \n
    \n
    \n
    \n
    \n {{item.content}}\n \n \n
    \n
    \n
    \n
    \n
    \n
    Items:\n
    {{items | json}}
    \n
    \n
    \n
    \n
    \n    \n  // HTML:\n   <div class=\'wrapper\' ng-controller="NgRepeatWithModel">\n      <div class=\'containerVertical\'>\n        <div ng-repeat="item in items">\n          {{item.content}}\n          <button class=\'cursorDefault\' ng-click="addItem()">+</button>\n          <button class=\'cursorDefault\' ng-click="removeItem()">x</button>\n        </div>\n    </div>\n  </div>\n    \n  
    \n
    \n    \n  // JS:\n  controller(\'NgRepeatWithModel\', [\'$scope\', \'$element\', \'dragularService\', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items = [{\n      content: \'Try to add or remove some elements (click on +- buttons), you will see that it is not problem for dragular.\'\n    }, {\n      content: \'Item 2\'\n    }, {\n      content: \'Item 3\'\n    }, {\n      content: \'Item 4\'\n    }];\n    dragularService($element.children().eq(0).children(), {containersModel: $scope.items});\n    $scope.addItem = function addItem() {\n      var index = $scope.items.indexOf(this.item) + 1;\n      $scope.items.splice(index, 0, {\n        content: this.item.content + \'-copy\'\n      });\n    };\n    $scope.removeItem = function removeItem() {\n      var index = $scope.items.indexOf(this.item);\n      $scope.items.splice(index, 1);\n    };\n  }])\n    \n  
    \n
    \n"); -$templateCache.put("exampleRemoveOnSpill/exampleRemoveOnSpill.html","
    \n

    Remove on spill

    \n \n
    \n
    \n
    Move me, but you can only drop me in containers.
    \n
    If you try to drop me somewhere other than containers, I\'ll die a fiery death.
    \n
    Item 3.
    \n
    Item 6.
    \n
    Item 4.
    \n
    Item 5.
    \n
    \n
    \n
    You can drop me in the left container.
    \n
    Item 4.
    \n
    Item 5.
    \n
    \n
    \n
    \n        \n  dragularService([document.getElementById(single)], { removeOnSpill: true });\n        \n      
    \n
    "); $templateCache.put("exampleRemoveOnSpillWithModel/exampleRemoveOnSpillWithModel.html","
    \n

    Remove on spill - with model

    \n \n
    \n
    \n
    \n
    {{item.content}}
    \n
    \n
    \n
    {{item.content}}
    \n
    \n
    \n
    \n
    \n
    Items1:\n          
    {{items1 | json}}
    \n
    \n
    \n
    Items2:\n          
    {{items2 | json}}
    \n
    \n
    \n
    \n
    \n        \n// JS\n  .controller(\'RemoveOnSpillWithModel\', [\'$scope\', \'$element\', \'dragularService\', function TodoCtrl($scope, $element, dragularService) {\n    $scope.items1 = [{\n      content: \'Move me, but you can only drop me in containers.\'\n    }, {\n      content: \'If you try to drop me somewhere other than containers, I\\\'ll die a fiery death.\'\n    }, {\n      content: \'Item 3\'\n    }, {\n      content: \'Item 4\'\n    }];\n    $scope.items2 = [{\n      content: \'You can drop me in the left container.\'\n    }, {\n      content: \'Item 6\'\n    }, {\n      content: \'Item 7\'\n    }, {\n      content: \'Item 8\'\n    }];\n    var containers = $element.children().eq(0).children();\n    dragularService.cleanEnviroment();\n    dragularService([containers[0],containers[1]],{\n      containersModel: [$scope.items1, $scope.items2],\n      removeOnSpill: true\n    });\n  }])\n        \n        \n<!-- HTML -->\n<div class=\'wrapper\' ng-controller="Basic">\n    <div class=\'tableRow\'>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items1">{{item.content}}</div>\n        </div>\n        <div class=\'containerVertical\'>\n            <div ng-repeat="item in items2">{{item.content}}</div>\n        </div>\n    </div>\n    <div class="tableRow">\n        <div class="container">\n            <div>Items1:\n                <br/>{{items1 | json}}</div>\n        </div>\n        <div class="container">\n            <div>Items2:\n                <br/>{{items2 | json}}</div>\n        </div>\n    </div>\n</div>\n        \n      
    \n
    \n"); +$templateCache.put("exampleRemoveOnSpill/exampleRemoveOnSpill.html","
    \n

    Remove on spill

    \n \n
    \n
    \n
    Move me, but you can only drop me in containers.
    \n
    If you try to drop me somewhere other than containers, I\'ll die a fiery death.
    \n
    Item 3.
    \n
    Item 6.
    \n
    Item 4.
    \n
    Item 5.
    \n
    \n
    \n
    You can drop me in the left container.
    \n
    Item 4.
    \n
    Item 5.
    \n
    \n
    \n
    \n        \n  dragularService([document.getElementById(single)], { removeOnSpill: true });\n        \n      
    \n
    "); $templateCache.put("exampleRevertOnSpill/exampleRevertOnSpill.html","
    \n

    Revert on spill

    \n \n
    \n
    \n
    Move me, but you can only drop me in one of these containers.
    \n
    If you try to drop me somewhere other than these containers, I\'ll just come back.
    \n
    Item 3.
    \n
    Item 6.
    \n
    \n
    \n
    You can drop me in the left container, otherwise I\'ll stay here.
    \n
    Item 4.
    \n
    Item 5.
    \n
    \n
    \n
    \n        \n  dragularService([document.getElementById(left), document.getElementById(right)], { revertOnSpill: true });\n        \n      
    \n
    "); $templateCache.put("exampleScrollingDrag/exampleScrollingDrag.html","
    \n

    Scrolling drag

    \n \n
    \n
    \n
    up
    \n
    \n
    Item 1.
    \n
    Item 2.
    \n
    Item 3.
    \n
    Item 4.
    \n
    Item 5.
    \n
    Item 6.
    \n
    Item 7.
    \n
    Item 9.
    \n
    Item 10.
    \n
    Item 11.
    \n
    Item 12.
    \n
    Item 13.
    \n
    \n
    down
    \n
    \n
    \n
    \n
    \n
    Item 1.
    \n
    Item 2.
    \n
    Item 3.
    \n
    Item 4.
    \n
    Item 5.
    \n
    Item 6.
    \n
    Item 7.
    \n
    Item 9.
    \n
    Item 10.
    \n
    Item 11.
    \n
    Item 12.
    \n
    Item 13.
    \n
    \n
    \n
    \n
    \n
    \n        \n// JS\ncontroller(\'ScrollingDrag\', [\'$interval\', \'$element\', \'dragularService\', function TodoCtrl($interval, $element, dragularService) {\n\n\n    var timer,\n      leftScrollContainer = document.getElementById(\'leftScroll\'),\n      rightScrollContainer = document.getElementById(\'rightScroll\'),\n      leftTopBar = document.getElementById(\'leftTopBar\'),\n      leftBottomBar = document.getElementById(\'leftBottomBar\'),\n      rightTopBar = document.getElementById(\'rightTopBar\'),\n      rightBottomBar = document.getElementById(\'rightBottomBar\');\n\n    dragularService.cleanEnviroment();\n    dragularService([leftScrollContainer, rightScrollContainer]);\n\n    registerEvents(leftTopBar, leftScrollContainer, -5);\n    registerEvents(leftBottomBar, leftScrollContainer, 5);\n    registerEvents(rightTopBar, rightScrollContainer, -5);\n    registerEvents(rightBottomBar, rightScrollContainer, 5);\n\n    function registerEvents(bar, container, inc, speed) {\n      if (!speed) {\n        speed = 20;\n      }\n      angular.element(bar).on(\'dragularenter\', function() {\n        container.scrollTop += inc;\n        timer = $interval(function moveScroll() {\n          container.scrollTop += inc;\n        }, speed);\n      });\n      angular.element(bar).on(\'dragularleave dragularrelease\', function() {\n        $interval.cancel(timer);\n      });\n    }\n  }])\n        \n      
    \n
    \n        \n<!-- HTML -->\n<div ng-controller="ScrollingDrag">\n    <div class="containerVertical scrollingDrag">\n      <div class="scrollBar" id="leftTopBar">up</div>\n      <div id="leftScroll" class="scrollingDragInner">\n        <div>Item 1</div>\n        <div>Item 2</div>\n            ...\n      </div>\n      <div class="scrollBar" id="leftBottomBar">down</div>\n    </div>\n    <div class="containerVertical scrollingDrag">\n      <div class="scrollBar" id="rightTopBar">up</div>\n      <div id="rightScroll" class="scrollingDragInner">\n        <div>Item 1</div>\n        <div>Item 2</div>\n            ...\n      </div>\n      <div class="scrollBar" id="rightBottomBar">down</div>\n    </div>\n  </div>\n        \n      
    \n
    \n        \n// CSS\n.scrollingDrag {\n  width: 45%;\n  display: inline-block;\n}\n\n.scrollingDragInner {\n  max-height: 200px;\n  overflow-y: auto;\n}\n\n#rightTopBar,\n#rightBottomBar {\n  background: transparent;\n  position: relative;\n  height: 20px;\n}\n\n#rightTopBar {\n  top: 10px;\n}\n\n#rightBottomBar {\n  bottom: 10px;\n}\n\ndiv.scrollBar {\n  background: yellow;\n  text-align: center;\n  padding: 1px;\n}\n\n        \n      
    \n
    \n"); $templateCache.put("partials/partial-contribute.html","
    \n
    \n
    \n \n
    \n
    \n
    \n"); $templateCache.put("partials/partial-docs.html","
    \n
    \n
    \n \n
    \n \n
    \n

    \n \n

    \n \n
    \n
    \n \n
    \n \n
    \n"); -$templateCache.put("partials/partial-home.html","
    \n
    \n \n
    \n
    \n

    DRAGULAR

    \n

    Angular drag&drop based on dragula.

    \n

    Live examples in docs

    \n
    \n
    \n
    \n

    Browser support includes every sane browser and **IE7+**. _(Granted you polyfill the functional `Array` methods in ES5)_

    \n

    Inspiration

    \n

    I am working on huge angular project and I am using several drag&drop libraries in it, one for UI, one for lists, etc.. I want to use one full-featured drag&drop library for whole project. As I could not find any suitable, I decided to create one. I have choosen great library dragula by Nicolas Bevacqua as my starting point, make it more angular and started to put features in it! If you wish light-weight angular version of dragula, there is official angular version of dragula.

    \n

    Actual version 4.1.0 is based on dragula 3.6.3 and tested with angular 1.4.9.

    \n

    Differences of dragular (against dragula)

    \n
      \n
    • replaced dragula crossvent with angulars event binding
    • \n
    • replaced dragula contra.emitter with $scope.$emit if scope provided in options (options.scope)
    • \n
    • provided as service or directive dragular where options can be passed via atribute dragular
    • \n
    • automatic direction if not provided in options, instead of default vertical
    • \n
    • accepting arraylike objects as containers array (jQuery, jQlite collections etc..)
    • \n
    • accepting custom classes via option.classes
    • \n
    • namespaced containers groups available via option.nameSpace (containers in same nameSpace cooperate)
    • \n
    • boundingBox (dragging element can me moved only in specific area)
    • \n
    • lockX/Y (dragging element can me moved only in specific direction)
    • \n
    • DOM can be synced with scope model
    • \n
    • support css selectors to define containers
    • \n
    • added syntax highlighter to example codes
    • \n
    • etc..
    • \n
    \n

    Todo

    \n
      \n
    • improve docs
    • \n
    \n

    Features

    \n
      \n
    • provided as service and also as directive
    • \n
    • Super easy to set up
    • \n
    • No bloated dependencies
    • \n
    • Figures out sort order on its own
    • \n
    • A shadow where the item would be dropped offers visual feedback
    • \n
    • Touch events!
    • \n
    \n

    For installation, usage and examples go to docs

    \n
    \n
    \n \n
    \n \n
    \n \n
    \n"); +$templateCache.put("partials/partial-home.html","
    \n
    \n \n
    \n
    \n

    DRAGULAR

    \n

    Angular drag&drop based on dragula.

    \n

    Live examples in docs

    \n
    \n
    \n
    \n

    Browser support includes every sane browser and **IE7+**. _(Granted you polyfill the functional `Array` methods in ES5)_

    \n

    Inspiration

    \n

    I am working on huge angular project and I am using several drag&drop libraries in it, one for UI, one for lists, etc.. I want to use one full-featured drag&drop library for whole project. As I could not find any suitable, I decided to create one. I have choosen great library dragula by Nicolas Bevacqua as my starting point, make it more angular and started to put features in it! If you wish light-weight angular version of dragula, there is official angular version of dragula.

    \n

    Actual version 4.2.0 is based on dragula 3.6.3 and tested with angular 1.5.5.

    \n

    Differences of dragular (against dragula)

    \n
      \n
    • replaced dragula crossvent with angulars event binding
    • \n
    • replaced dragula contra.emitter with $scope.$emit if scope provided in options (options.scope)
    • \n
    • provided as service or directive dragular where options can be passed via atribute dragular
    • \n
    • automatic direction if not provided in options, instead of default vertical
    • \n
    • accepting arraylike objects as containers array (jQuery, jQlite collections etc..)
    • \n
    • accepting custom classes via option.classes
    • \n
    • namespaced containers groups available via option.nameSpace (containers in same nameSpace cooperate)
    • \n
    • boundingBox (dragging element can me moved only in specific area)
    • \n
    • lockX/Y (dragging element can me moved only in specific direction)
    • \n
    • DOM can be synced with scope model
    • \n
    • support css selectors to define containers
    • \n
    • added syntax highlighter to example codes
    • \n
    • etc..
    • \n
    \n

    Todo

    \n
      \n
    • improve docs
    • \n
    \n

    Features

    \n
      \n
    • provided as service and also as directive
    • \n
    • Super easy to set up
    • \n
    • No bloated dependencies
    • \n
    • Figures out sort order on its own
    • \n
    • A shadow where the item would be dropped offers visual feedback
    • \n
    • Touch events!
    • \n
    \n

    For installation, usage and examples go to docs

    \n
    \n
    \n \n
    \n \n
    \n \n
    \n"); $templateCache.put("partials/autogenerated/contribute.html","

    How to contribute

    \n

    It's important to us that you feel you can contribute towards the evolution of Dragular. This can take many forms: from helping to fix bugs or improve the docs, to adding in new features to the source. This guide should help you in making that process as smooth as possible.

    \n

    Before contributing, please read the code of conduct.

    \n

    Reporting issues

    \n

    GitHub Issues is the place to report bugs you may have found in either the core library or any of the examples that are part of the repository. When submitting a bug please do the following:

    \n

    1. Search for existing issues. Your bug may have already been fixed or addressed in a development branch version of Dragular, so be sure to search the issues first before putting in a duplicate issue.

    \n

    2. Not sure if it's a bug?. Then please ask via issues and tag it [question].

    \n

    3. Create an isolated and reproducible test case. If you are reporting a bug, make sure you also have a minimal, runnable, code example that reproduces the problem you have.

    \n

    4. Include a live example. After narrowing your code down to only the problem areas, make use of jsFiddle, jsBin, or a link to your live site so that we can view a live example of the problem. (you can start by forking this fiddle)

    \n

    5. Share as much information as possible. Include browser version affected, your OS, version of the library, steps to reproduce, etc. "X isn't working!!!1!" will probably just be closed.

    \n

    Dev vs. Master

    \n

    The dev branch of Dragular is our 'current working' version. It is always ahead of the master branch in terms of features and fixes. However it's also bleeding-edge and experimental and we cannot and do not guarantee it will compile or work for you. Very often we have to break things for a few days while we rebuild and patch. So by all means please export the dev branch and contribute towards it, indeed that is where all Pull Requests should be sent, but do so understanding the API may change beneath you.

    \n

    Making Changes

    \n

    To take advantage of our npm build script and jshint config it will be easiest for you if you have node.js installed locally.

    \n

    You can download node.js from nodejs.org.

    \n

    After that you can clone the repository and run npm i inside the cloned folder. This will install dependencies necessary for building the project. For development workflow automation dragular uses gulp >= 3.9.0. Before starting development, make sure that gulp is installed on your machine globally: npm i -g gulp.

    \n

    Developing

    \n

    There are several gulp tasks that are used for generating different builds:

    \n
      \n
    • gulp dev - Serves files with BrowserSync server, watches & automatically refreshes connected browsers on changes, generates non-minified but concatenated styles & scripts from the dragular source.
    • \n
    • gulp dev:docs - Does exactly the same as gulp dev, except it works with the documentation source.
    • \n
    • gulp build - Concatenates and minifies dragular source files.
    • \n
    • gulp build:docs - Concatenates and minifies documentation source files.
    • \n
    \n

    Linting

    \n
      \n
    • gulp lint & gulp lint:docs - Lint JavaScript files.
    • \n
    \n

    Making a pull request

    \n

    Once that is ready, make your changes and submit a Pull Request:

    \n
      \n
    • Send Pull Requests to the dev branch. All Pull Requests must be sent to the dev branch, master is the latest release and PRs to that branch will be closed.

      \n
    • \n
    • Ensure changes are jshint validated. Our JSHint configuration file is provided in the repository and you should check against it before submitting.

      \n
    • \n
    • Only commit relevant changes. Don't include changes that are not directly relevant to the fix you are making. The more focused a PR is, the faster it will get attention and be merged. Extra files changing only whitespace or trash files will likely get your PR closed.

      \n
    • \n
    \n

    Dependencies for building from source and running tests:

    \n

    Coding style preferences are not contributions

    \n

    If your PR is doing little more than changing the Dragular source code into a format / coding style that you prefer then we will automatically close it. All PRs must adhere to the coding style already set-out across the lines of code in Dragular. Your personal preferences for how things should "look" or be structured do not apply here, sorry. PRs should fix bugs, fix documentation or add features. No changes for the sake of change.

    \n

    I don't really like git / node.js, but I can fix this bug

    \n

    That is fine too. While Pull Requests are the best thing in the world for us, they are not the only way to help. You're welcome to post fixes to our forum or even just email them to us. All we ask is that you still adhere to the guidelines presented here re: JSHint, etc.

    \n");}]); \ No newline at end of file diff --git a/gulpfile.js b/gulpfile.js index 6cba9091..2a5b914d 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -36,8 +36,9 @@ var config = { port: '3000', server: './docs' }, - // Predefined scripts configs to keep tasks DRY + // Predefined scripts & styles configs to keep tasks DRY scripts: { + libraryTarget: 'umd', dragular: { type: 'dragular', entryPoint: './src/dragularModule.js', @@ -51,16 +52,34 @@ var config = { dest: './docs/dist' } }, + styles: { + dragular: { + entryPoint: './src/*.css', + bundleName: 'dragular.css', + dest: './dist' + }, + docs: { + entryPoint: [ + './src/*.css', + './docs/src/**/*.css' + ], + bundleName: 'examples.css', + dest: './docs/dist' + } + }, // A flag attribute to switch modes isProd: false }; /* -* scriptDefaults stores current scripts settings (like entry point or +* Defaults stores temporary scripts & styles settings (like entry point or * output directory). This metadata is used to configure the webpack compilation * process. */ -var scriptDefaults = config.scripts.dragular; +var defaults = { + scripts: config.scripts.dragular, + styles: config.styles.dragular +} function handleErrors(err) { gutil.log(err.toString()); @@ -73,15 +92,19 @@ function handleErrors(err) { function buildScript() { function rebundle() { - return gulp.src(scriptDefaults.entryPoint) + return gulp.src(defaults.scripts.entryPoint) .on('error', handleErrors) .pipe(webpack({ watch: config.isProd ? false : true, output: { - filename: scriptDefaults.bundleName + libraryTarget: config.scripts.libraryTarget, + filename: defaults.scripts.bundleName } })) - .pipe(gulpif(config.isProd, gulp.dest(scriptDefaults.dest))) + .pipe(gulpif(config.isProd, gulp.dest(defaults.scripts.dest))) + .pipe(gulpif(config.isProd, size({ + title: 'Non-minified scripts: ' + }))) .pipe(gulpif(config.isProd, sourcemaps.init({loadMaps: true}))) .pipe(gulpif(config.isProd, uglify({ compress: { drop_console: true } @@ -93,12 +116,12 @@ function buildScript() { title: 'Scripts: ' })) .pipe(gulpif(config.isProd, sourcemaps.write('./'))) - .pipe(gulp.dest(scriptDefaults.dest)) + .pipe(gulp.dest(defaults.scripts.dest)) .pipe(gulpif(browserSync.active, browserSync.stream())); } function lintAndRebundle() { - if (scriptDefaults.type === 'dragular') { + if (defaults.scripts.type === 'dragular') { return sequence('lint', rebundle); } @@ -114,13 +137,16 @@ gulp.task('scripts', function() { gulp.task('styles', function() { - return gulp.src(config.dragular.styles) + return gulp.src(defaults.styles.entryPoint) .pipe(autoprefixer({ browsers: [ 'last 15 versions', '> 1%', 'ie 8', 'ie 7' ], cascade: false })) - .pipe(concat('dragular.css')) - .pipe(gulpif(config.isProd, gulp.dest(config.dragular.dest))) + .pipe(concat(defaults.styles.bundleName)) + .pipe(gulpif(config.isProd, gulp.dest(defaults.styles.dest))) + .pipe(gulpif(config.isProd, size({ + title: 'Non-minified styles: ' + }))) .pipe(gulpif(config.isProd, minifyCss())) .pipe(gulpif(config.isProd, rename({ suffix: '.min' @@ -128,25 +154,10 @@ gulp.task('styles', function() { .pipe(size({ title: 'Styles: ' })) - .pipe(gulp.dest(config.dragular.dest)) + .pipe(gulp.dest(defaults.styles.dest)) .pipe(gulpif(browserSync.active, browserSync.stream())); }); -gulp.task('styles:docs', function() { - - return gulp.src([ - config.docs.styles, - config.dragular.styles - ]) - .pipe(autoprefixer({ - browsers: [ 'last 15 versions', '> 1%', 'ie 8', 'ie 7' ], - cascade: false - })) - .pipe(concat('examples.css')) - .pipe(gulp.dest(config.docs.dest)) - .pipe(gulpif(browserSync.active, browserSync.stream())); -}); - gulp.task('lint', function() { return gulp.src([config.dragular.scripts]) @@ -200,7 +211,7 @@ gulp.task('watch', ['serve'], function() { }); gulp.task('watch:docs', ['serve'], function() { - gulp.watch(config.docs.styles, ['styles:docs']); + gulp.watch(config.docs.styles, ['styles']); gulp.watch(config.docs.templates, ['templates:docs']); gulp.watch(config.docs.index, browserSync.reload); gulp.watch('./CONTRIBUTING.md', ['markdown']); @@ -211,17 +222,23 @@ gulp.task('watch:docs', ['serve'], function() { * on changes, generate non-minified but concatenated output. */ gulp.task('dev', function() { - config.isProd = false; - scriptDefaults = config.scripts.dragular; + config.isProd = true; + defaults = { + scripts: config.scripts.dragular, + styles: config.styles.dragular + }; sequence(['scripts', 'styles'], 'watch'); }); gulp.task('dev:docs', function() { - config.isProd = false; - scriptDefaults = config.scripts.docs; + config.isProd = true; + defaults = { + scripts: config.scripts.docs, + styles: config.styles.docs + }; - sequence('markdown', 'templates:docs', ['scripts', 'styles:docs'], 'watch:docs'); + sequence('markdown', 'templates:docs', ['scripts', 'styles'], 'watch:docs'); }); /* @@ -229,14 +246,20 @@ gulp.task('dev:docs', function() { */ gulp.task('build', function() { config.isProd = true; - scriptDefaults = config.scripts.dragular; + defaults = { + scripts: config.scripts.dragular, + styles: config.styles.dragular + }; sequence(['scripts', 'styles'], 'build:docs'); }); gulp.task('build:docs', function() { config.isProd = true; - scriptDefaults = config.scripts.docs; + defaults = { + scripts: config.scripts.docs, + styles: config.styles.docs + }; sequence('markdown', 'templates:docs', ['scripts', 'styles']); }); diff --git a/readme.markdown b/readme.markdown index e85fef16..a63b18cd 100644 --- a/readme.markdown +++ b/readme.markdown @@ -10,7 +10,7 @@ Browser support includes every sane browser and **IE7+**. _(Granted you pol I am working on huge angular project and I am using several drag&drop libraries in it, one for UI, one for lists, etc.. I want to use one full-featured drag&drop library for whole project. As I could not find any suitable, I decided to create one. I have choosen great library [dragula](http://github.com/bevacqua/dragula) by [Nicolas Bevacqua](http://github.com/bevacqua) as my starting point, make it more angular and started to put features in it! If you wish light-weight angular version of dragula, there is [official angular version of dragula](http://github.com/bevacqua/angular-dragula). -Actual version 4.1.0 is based on dragula 3.6.3 and tested with angular 1.4.9. +Actual version 4.2.0 is based on dragula 3.6.3 and tested with angular 1.5.5. # Differences of dragular (against dragula) @@ -160,6 +160,9 @@ For better readability of views. ```html
    ``` +### dragular-on-init atribute + +Same as options.onInit see bellow. ## Options @@ -365,6 +368,10 @@ myEventNames = { In case your draggable items are customized by other directives/attributes, you can use this flag to run compilation of droped item after drop. It is not supposed to be used with containers items rendered by ng-repeat. In such case you are supposed to add directives/attributes to item template and use logic in controller to enable/disable them. +### `options.onInit` + +You can provide function callback called after dragular initialisation with drake as first argument. + ## `Events` diff --git a/src/dragularDirective.js b/src/dragularDirective.js index 97fb492c..032633c7 100644 --- a/src/dragularDirective.js +++ b/src/dragularDirective.js @@ -43,6 +43,10 @@ var dragular = function (dragularService) { options.nameSpace = iAttrs.dragularNameSpace.split(' '); } + if(iAttrs.dragularOnInit){ + options.onInit = $scope.$eval(iAttrs.dragularOnInit); + } + drake = dragularService(iElm[0], options); } }; diff --git a/src/dragularModule.js b/src/dragularModule.js index 2743dd6a..9fd26e20 100644 --- a/src/dragularModule.js +++ b/src/dragularModule.js @@ -4,7 +4,7 @@ var dragularDirective = require('./dragularDirective'); var dragularService = require('./dragularService'); /** - * Dragular 4.1.0 by Luckylooke https://github.com/luckylooke/dragular + * Dragular 4.2.0 by Luckylooke https://github.com/luckylooke/dragular * Angular version of dragula https://github.com/bevacqua/dragula */ module.exports = 'dragularModule'; diff --git a/src/dragularService.js b/src/dragularService.js index 2039abed..78b796bb 100644 --- a/src/dragularService.js +++ b/src/dragularService.js @@ -110,7 +110,8 @@ var dragularService = function ($rootScope, $compile) { boundingBox: false, // lock movement inside this element boundaries mirrorContainer: doc.body, // element for appending mirror ignoreInputTextSelection: true, // text selection in inputs wont be considered as drag - compileItemOnDrop: false + compileItemOnDrop: false, + onInit: false // function callback called after dragular initialisation and providing drake as first argument }, drake = { containers: shared.containers, @@ -129,6 +130,10 @@ var dragularService = function ($rootScope, $compile) { extendOptions(); processOptionsObject(); registerEvents(); + + if(o.onInit){ + o.onInit(drake); + } return drake;