!function(a){"use strict";"function"==typeofdefine&&define.amd?define(a):"undefined"!=typeofmodule&&"undefined"!=typeofmodule.exports?module.exports=a():"undefined"!=typeofPackage?Sortable=a():window.Sortable=a()}(function(){"use strict";functiona(a,b){if(!a||!a.nodeType||1!==a.nodeType)throw"Sortable: `el` must be HTMLElement, and not "+{}.toString.call(a);this.el=a,this.options=b=s({},b),a[O]=this;varc={group:Math.random(),sort:!0,disabled:!1,store:null,handle:null,scroll:!0,scrollSensitivity:30,scrollSpeed:10,draggable:/[uo]l/i.test(a.nodeName)?"li":">*",ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",ignore:"a, img",filter:null,animation:0,setData:function(a,b){a.setData("Text",b.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0};for(vardinc)!(dinb)&&(b[d]=c[d]);_(b);for(varfinthis)"_"===f.charAt(0)&&(this[f]=this[f].bind(this));this.nativeDraggable=b.forceFallback?!1:U,e(a,"mousedown",this._onTapStart),e(a,"touchstart",this._onTapStart),this.nativeDraggable&&(e(a,"dragover",this),e(a,"dragenter",this)),Z.push(this._onDragOver),b.store&&this.sort(b.store.get(this))}functionb(a){x&&x.state!==a&&(h(x,"display",a?"none":""),!a&&x.state&&y.insertBefore(x,u),x.state=a)}functionc(a,b,c){if(a){c=c||Q;doif(">*"===b&&a.parentNode===c||q(a,b))returna;while(a!==c&&(a=a.parentNode))}returnnull}functiond(a){a.dataTransfer&&(a.dataTransfer.dropEffect="move"),a.preventDefault()}functione(a,b,c){a.addEventListener(b,c,!1)}functionf(a,b,c){a.removeEventListener(b,c,!1)}functiong(a,b,c){if(a)if(a.classList)a.classList[c?"add":"remove"](b);else{vard=(" "+a.className+" ").replace(N," ").replace(" "+b+" "," ");a.className=(d+(c?" "+b:"")).replace(N," ")}}functionh(a,b,c){vard=a&&a.style;if(d){if(void0===c)returnQ.defaultView&&Q.defaultView.getComputedStyle?c=Q.defaultView.getComputedStyle(a,""):a.currentStyle&&(c=a.currentStyle),void0===b?c:c[b];bind||(b="-webkit-"+b),d[b]=c+("string"==typeofc?"":"px")}}functioni(a,b,c){if(a){vard=a.getElementsByTagName(b),e=0,f=d.length;if(c)for(;f>e;e++)c(d[e],e);returnd}return[]}functionj(a,b,c,d,e,f,g){a=a||b[O];varh=Q.createEvent("Event"),i=a.options,j="on"+c.charAt(0).toUpperCase()+c.substr(1);h.initEvent(c,!0,!0),h.to=b,h.from=e||b,h.item=d||b,h.clone=x,h.oldIndex=f,h.newIndex=g,b.dispatchEvent(h),i[j]&&i[j].call(a,h)}functionk(a,b,c,d,e,f){varg,h,i=a[O],j=i.options.onMove;returng=Q.createEvent("Event"),g.initEvent("move",!0,!0),g.to=b,g.from=a,g.dragged=c,g.draggedRect=d,g.related=e||b,g.relatedRect=f||b.getBoundingClientRect(),a.dispatchEvent(g),j&&(h=j.call(i,g)),h}functionl(a){a.draggable=!1}functionm(){W=!1}functionn(a,b){varc=a.lastElementChild,d=c.getBoundingClientRect();return(X(b.clientY-(d.top+d.height))>5||X(b.clientX-(d.right+d.width))>5)&&c}functiono(a){for(varb=a.tagName+a.className+a.src+a.href+a.textContent,c=b.length,d=0;c--;)d+=b.charCodeAt(c);returnd.toString(36)}functionp(a,b){varc=0;if(!a||!a.parentNode)return-1;for(;a&&(a=a.previousElementSibling);)"TEMPLATE"===a.nodeName.toUpperCase()||">*"!==b&&!q(a,b)||c++;returnc}functionq(a,b){if(a){b=b.split(".");varc=b.shift().toUpperCase(),d=newRegExp("\\s("+b.join("|")+")(?=\\s)","g");return!(""!==c&&a.nodeName.toUpperCase()!=c||b.length&&((" "+a.className+" ").match(d)||[]).length!=b.length)}return!1}functionr(a,b){varc,d;returnfunction(){void0===c&&(c=arguments,d=this,setTimeout(function(){1===c.length?a.call(d,c[0]):a.apply(d,c),c=void0},b))}}functions(a,b){if(a&&b)for(varcinb)b.hasOwnProperty(c)&&(a[c]=b[c]);returna}functiont(a){returnS?S(a).clone(!0)[0]:T&&T.dom?T.dom(a).cloneNode(!0):a.cloneNode(!0)}if("undefined"==typeofwindow||!window.document)returnfunction(){thrownewError("Sortable.js requires a window with a document")};varu,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M={},N=/\s+/g,O="Sortable"+(newDate).getTime(),P=window,Q=P.document,R=P.parseInt,S=P.jQuery||P.Zepto,T=P.Polymer,U=!!("draggable"inQ.createElement("div")),V=function(a){retu