text: !function t(e,i,n){function o(s,a){if(!i[s]){if(!e[s]){var l="function"==typeof require&&require;if(!a&&l)return l(s,!0);if(r)return r(s,!0);var h=new Error("Cannot find module '"+s+"'");throw h.code="MODULE_NOT_FOUND",h}var c=i[s]={exports:{}};e[s][0].call(c.exports,function(t){var i=e[s][1][t];return o(i?i:t)},c,c.exports,t,e,i,n)}return i[s].exports}for(var r="function"==typeof require&&require,s=0;s<n.length;s++)o(n[s]);return o}({1:[function(t,e,i){"use strict";e.exports=window.Sortable2={};t("./Container.js"),t("./ContainersCollection"),t("./Draggable"),t("./PositionHelper")},{"./Container.js":2,"./ContainersCollection":3,"./Draggable":4,"./PositionHelper":5}],2:[function(t,e,i){"use strict";Sortable2.Container=function(t,e){e=e||{},this._items=null,this._eventObject={},this.element=$(t),this.element.addClass(Sortable2.Container.CSS_CLASS_CONTAINER),this.element.data(Sortable2.Container.DATA_CONTAINER_ID,this),this.isFloating=e.hasOwnProperty("isFloating")?!!e.isFloating:null,this.itemsContainerSelector=e.itemsContainerSelector||"ul",this.coordinates=null,this.paddings=null;var i=[Sortable2.Container.EVENT_RECEIVE,Sortable2.Container.EVENT_CHANGE];$.each(i,function(t,i){var n="on"+i.charAt(0).toUpperCase()+i.slice(1);e[n]&&this.on(i,e[n])}.bind(this))},$.extend(Sortable2.Container,{CSS_CLASS_CONTAINER:"sortable-2-container",DATA_CONTAINER_ID:"__sortable-2-container",EVENT_RECEIVE:"receive",EVENT_CHANGE:"change",findOrCreate:function(t){var e=$(t);return 0===e.length?null:e.data(Sortable2.Container.DATA_CONTAINER_ID)||new Sortable2.Container(e)},find:function(t){return $(t).data(Sortable2.Container.DATA_CONTAINER_ID)||null}}),$.extend(Sortable2.Container.prototype,{on:function(t,e){$(this._eventObject).on(t,e)},off:function(t,e){$(this._eventObject).off(t,e)},getItemsWrapperElement:function(){if(!this.itemsContainerSelector)return this.element;var t=this.element.find(this.itemsContainerSelector).eq(0);return t.length>0?t:null},refresh:function(){null===this.isFloating&&(this.isFloating=!!this.element.attr("data-floating")),this.coordinates=Sortable2.PositionHelper.calcCoordinates(this.element),this._items=[],this.paddings={top:0,right:0,bottom:0,left:0};var t=this.getItemsWrapperElement();t&&(this.paddings={top:parseInt(t.css("paddingTop").replace(/[^0-9.]/g,""),10),right:parseInt(t.css("paddingRight").replace(/[^0-9.]/g,""),10),bottom:parseInt(t.css("paddingBottom").replace(/[^0-9.]/g,""),10),left:parseInt(t.css("paddingLeft").replace(/[^0-9.]/g,""),10)},t.find("> *").each($.proxy(function(t,e){var i=Sortable2.Container.findOrCreate(e);i&&(i.refresh(),this._items.push(i))},this)))},setActive:function(t){this.element.css("background-color",t?"rgba(255, 222, 118, .8)":"")},isEntryPoint:function(t,e){return this.coordinates.x1<=t&&t<this.coordinates.x2&&this.coordinates.y1<=e&&e<this.coordinates.y2},isEntryPointNearEdge:function(t,e,i){if(i){var n=this.coordinates.x2-this.coordinates.x1;return this.coordinates.y1<=e&&e<this.coordinates.y2&&(this.coordinates.x1<=t&&t<this.coordinates.x1+.3*n||this.coordinates.x1+.7*n<=t&&t<this.coordinates.x2)}var o=this.coordinates.y2-this.coordinates.y1;return this.coordinates.x1<=t&&t<this.coordinates.x2&&(this.coordinates.y1<=e&&e<this.coordinates.y1+.3*o||this.coordinates.y1+.7*o<=e&&e<this.coordinates.y2)},findNearEdge:function(t,e){for(var i=null,n=0,o=0,r=this.isFloating?t:e,s=this.isFloating?"x":"y",a=null,l=0,h=this._items.length;h>l;l++){var c=this._items[l],d=c.coordinates[s+2]-c.coordinates[s+1];if(r<c.coordinates[s+1]+d/2)break;i=c;var _=this._items[l+1];_?a=_.coordinates[s+1]-(_.coordinates[s+1]-c.coordinates[s+2])/2:(i=null,a=null)}i||(i=this,n=this.isFloating?this.paddings.left:this.paddings.top,o=this.isFloating?this.paddings.right:this.paddings.bottom);var u=!1,g={x1:i.coordinates.x1+n,x2:i.coordinates.x2-o,y1:i.coordinates.y1+n,y2:i.coordinates.y2-o};return a?g[s+1]=g[s+2]=a:(u=0===this._items.length||r<i.coordinates[s+1]+(i.coordinates[s+2]-i.coordinates[s+1])/2,g[s+1]=g[s+2]=u?i.coordinates[s+1]+n:i.coordinates[s+2]-o),{coordinates:g,place:{element:i===this?i.getItemsWrapperElement():i.element,method:i===this?u?"prependTo":"appendTo":u?"insertBefore":"insertAfter"}}},receive:function(t,e){this._trigger(Sortable2.Container.EVENT_RECEIVE,[t,e]),this._trigger(Sortable2.Container.EVENT_CHANGE)},_trigger:function(t,e){$(this._eventObject).trigger(t,e)}})},{}],3:[function(t,e,i){"use strict";Sortable2.ContainersCollection=function(t){this._selector=t,this._items=[]},$.extend(Sortable2.ContainersCollection,{DATA_CONTAINER_ID:"__sortable-2-container",_bySelector:{},getCollection:function(t){return this._bySelector[t]||(this._bySelector[t]=new Sortable2.ContainersCollection(t)),this._bySelector[t]}}),$.extend(Sortable2.ContainersCollection.prototype,{findAndStore:function(){this._items=[],$(this._selector).each($.proxy(function(t,e){var i=Sortable2.Container.find(e);i&&(i.refresh(),this._items.push(i))},this))},findEntryPointContainer:function(t,e){for(var i=null,n=this._items.length-1;n>=0;n--)if(this._items[n].isEntryPoint(t,e)){if(i)return i.isEntryPointNearEdge(t,e,this._items[n].isFloating)?this._items[n]:i;i=this._items[n];break}return i}})},{}],4:[function(t,e,i){"use strict";Sortable2.Draggable=function(t,e){this._element=$(t),this._helperElement=null,this._placeholderElement=null,this._isDrag=!1,this._isDragMove=!1,this._startPoint=null,this._startElementCoordinates=null,this._activeContainer=null,this._nearEdge=null,e=$.extend(!0,{containersSelector:"ul, ol"},e||{}),this._init(),this.setContainersSelector(e.containersSelector)},$.extend(Sortable2.Draggable,{DATA_ID:"__sortable-2"}),$.extend(Sortable2.Draggable.prototype,{setContainersSelector:function(t){this._containers=Sortable2.ContainersCollection.getCollection(t)},_init:function(){this._element.on("mousedown",$.proxy(this._dragStart,this)),$(window).on("mousemove",$.proxy(this._dragMove,this)).on("mouseup",$.proxy(this._dragEnd,this))},_dragStart:function(t){this._isDrag||(this._isDrag=!0)},_dragMove:function(t){if(this._isDrag){t.preventDefault(),this._isDragMove||(t.stopPropagation(),this._startElementCoordinates=Sortable2.PositionHelper.calcCoordinates(this._element),this._startPoint=Sortable2.PositionHelper.calcPointFromEvent(t),this._containers.findAndStore(),this._helperElement=this._element.clone().appendTo("body"),this._placeholderElement=$("<div />").hide().appendTo("body").css({position:"absolute",outline:"solid 2px #006c9e"})),this._isDragMove=!0;var e=Sortable2.PositionHelper.calcPointFromEvent(t);this._helperElement.css({position:"absolute",left:this._startElementCoordinates.x1-(this._startPoint.x-e.x),top:this._startElementCoordinates.y1-(this._startPoint.y-e.y)});var i=this._containers.findEntryPointContainer(e.x,e.y);this._activeContainer&&this._activeContainer.setActive(!1),this._activeContainer=i,this._activeContainer&&this._activeContainer.setActive(!0),i?(this._nearEdge=i.findNearEdge(e.x,e.y),this._placeholderElement.show().css({left:this._nearEdge.coordinates.x1,top:this._nearEdge.coordinates.y1,width:this._nearEdge.coordinates.x2-this._nearEdge.coordinates.x1,height:this._nearEdge.coordinates.y2-this._nearEdge.coordinates.y1})):(this._nearEdge=null,this._placeholderElement.hide())}},_dragEnd:function(t){if(this._isDrag&&(this._isDrag=!1,this._isDragMove)){if(this._isDragMove=!1,this._activeContainer&&this._nearEdge){var e=$("<div />")[this._nearEdge.place.method](this._nearEdge.place.element);this._activeContainer.receive(this._element,e)}this._nearEdge&&(this._nearEdge=null),this._activeContainer&&(this._activeContainer.setActive(!1),this._activeContainer=null),this._helperElement.remove(),this._placeholderElement.remove()}}})},{}],5:[function(t,e,i){"use strict";Sortable2.PositionHelper={calcPointFromEvent:function(t){return{x:t.pageX,y:t.pageY}},calcCoordinates:function(t){var e=t.offset();return{x1:e.left,x2:e.left+t.outerWidth(),y1:e.top,y2:e.top+t.outerHeight()}}}},{}]},{},[1]);