(function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e(require("vue")):"function"===typeof define&&define.amd?define([],e):"object"===typeof exports?exports["vueDragComponent"]=e(require("vue")):t["vueDragComponent"]=e(t["Vue"])})("undefined"!==typeof self?self:this,(function(t){return function(t){var e={};function n(i){if(e[i])return e[i].exports;var r=e[i]={i:i,l:!1,exports:{}};return t[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=t,n.c=e,n.d=function(t,e,i){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:i})},n.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)n.d(i,r,function(e){return t[e]}.bind(null,r));return i},n.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="9896")}({"05ce":function(t,e,n){},"07a2":function(t,e,n){var i=n("8a1c");t.exports=function(t){if(i(t))throw TypeError("The method doesn't accept regular expressions");return t}},"0a60":function(t,e){e.f=Object.getOwnPropertySymbols},"0c3c":function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t}},"0fc1":function(t,e,n){var i=n("1e2c"),r=n("d910"),o=n("38b9");t.exports=i?function(t,e,n){return r.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},1025:function(t,e,n){var i=n("3a08"),r=Function.toString;"function"!=typeof i.inspectSource&&(i.inspectSource=function(t){return r.call(t)}),t.exports=i.inspectSource},"18f6":function(t,e){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},1944:function(t,e,n){var i=n("d890"),r=n("0fc1"),o=n("faa8"),s=n("e4db"),a=n("1025"),u=n("b702"),c=u.get,f=u.enforce,h=String(String).split("String");(t.exports=function(t,e,n,a){var u=!!a&&!!a.unsafe,c=!!a&&!!a.enumerable,d=!!a&&!!a.noTargetGet;"function"==typeof n&&("string"!=typeof e||o(n,"name")||r(n,"name",e),f(n).source=h.join("string"==typeof e?e:"")),t!==i?(u?!d&&t[e]&&(c=!0):delete t[e],c?t[e]=n:r(t,e,n)):c?t[e]=n:s(e,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&c(this).source||a(this)}))},"1b99":function(t,e,n){var i=n("d890");t.exports=i},"1c2e":function(t,e,n){"use strict";var i=n("1944"),r=n("857c"),o=n("efe2"),s=n("99ad"),a="toString",u=RegExp.prototype,c=u[a],f=o((function(){return"/a/b"!=c.call({source:"a",flags:"b"})})),h=c.name!=a;(f||h)&&i(RegExp.prototype,a,(function(){var t=r(this),e=String(t.source),n=t.flags,i=String(void 0===n&&t instanceof RegExp&&!("flags"in u)?s.call(t):n);return"/"+e+"/"+i}),{unsafe:!0})},"1c8b":function(t,e,n){var i=n("d890"),r=n("aa6b").f,o=n("0fc1"),s=n("1944"),a=n("e4db"),u=n("c69d"),c=n("e8d6");t.exports=function(t,e){var n,f,h,d,l,p,v=t.target,m=t.global,g=t.stat;if(f=m?i:g?i[v]||a(v,{}):(i[v]||{}).prototype,f)for(h in e){if(l=e[h],t.noTargetGet?(p=r(f,h),d=p&&p.value):d=f[h],n=c(m?h:v+(g?".":"#")+h,t.forced),!n&&void 0!==d){if(typeof l===typeof d)continue;u(l,d)}(t.sham||d&&d.sham)&&o(l,"sham",!0),s(f,h,l,t)}}},"1ca1":function(t,e,n){var i=n("a719"),r=n("74e7"),o=n("90fb"),s=o("species");t.exports=function(t,e){var n;return r(t)&&(n=t.constructor,"function"!=typeof n||n!==Array&&!r(n.prototype)?i(n)&&(n=n[s],null===n&&(n=void 0)):n=void 0),new(void 0===n?Array:n)(0===e?0:e)}},"1e2c":function(t,e,n){var i=n("efe2");t.exports=!i((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},"1ea7":function(t,e,n){var i=n("efe2"),r=n("90fb"),o=n("f594"),s=r("species");t.exports=function(t){return o>=51||!i((function(){var e=[],n=e.constructor={};return n[s]=function(){return{foo:1}},1!==e[t](Boolean).foo}))}},2039:function(t,e,n){var i=n("1e2c"),r=n("efe2"),o=n("ae25");t.exports=!i&&!r((function(){return 7!=Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},2118:function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},"258f":function(t,e,n){var i=n("90fb"),r=n("6d60"),o=n("d910"),s=i("unscopables"),a=Array.prototype;void 0==a[s]&&o.f(a,s,{configurable:!0,value:r(null)}),t.exports=function(t){a[s][t]=!0}},2732:function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},"2a91":function(t,e,n){var i=n("47ae"),r=n("2118"),o=n("90fb"),s=o("toStringTag"),a="Arguments"==r(function(){return arguments}()),u=function(t,e){try{return t[e]}catch(n){}};t.exports=i?r:function(t){var e,n,i;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=u(e=Object(t),s))?n:a?r(e):"Object"==(i=r(e))&&"function"==typeof e.callee?"Arguments":i}},"2eeb":function(t,e,n){"use strict";var i=n("1c8b"),r=n("5dfd").map,o=n("1ea7"),s=n("ff9c"),a=o("map"),u=s("map");i({target:"Array",proto:!0,forced:!a||!u},{map:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}})},3553:function(t,e,n){var i=n("2732");t.exports=function(t){return Object(i(t))}},"38b9":function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},"3a08":function(t,e,n){var i=n("d890"),r=n("e4db"),o="__core-js_shared__",s=i[o]||r(o,{});t.exports=s},"3da3":function(t,e){var n=Math.ceil,i=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?i:n)(t)}},4194:function(t,e,n){"use strict";var i=n("1c8b"),r=n("5dfd").find,o=n("258f"),s=n("ff9c"),a="find",u=!0,c=s(a);a in[]&&Array(1)[a]((function(){u=!1})),i({target:"Array",proto:!0,forced:u||!c},{find:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}}),o(a)},"45af":function(t,e,n){var i=n("da10"),r=n("d88d"),o=n("e1d6"),s=function(t){return function(e,n,s){var a,u=i(e),c=r(u.length),f=o(s,c);if(t&&n!=n){while(c>f)if(a=u[f++],a!=a)return!0}else for(;c>f;f++)if((t||f in u)&&u[f]===n)return t||f||0;return!t&&-1}};t.exports={includes:s(!0),indexOf:s(!1)}},"47ae":function(t,e,n){var i=n("90fb"),r=i("toStringTag"),o={};o[r]="z",t.exports="[object z]"===String(o)},"4fda":function(t,e,n){var i=n("6d7a");t.exports=i("navigator","userAgent")||""},"50fb":function(t,e,n){var i=n("857c"),r=n("d1fd");t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{t=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set,t.call(n,[]),e=n instanceof Array}catch(o){}return function(n,o){return i(n),r(o),e?t.call(n,o):n.__proto__=o,n}}():void 0)},"513c":function(t,e,n){"use strict";var i=n("1e2c"),r=n("d890"),o=n("e8d6"),s=n("1944"),a=n("faa8"),u=n("2118"),c=n("7063"),f=n("9f67"),h=n("efe2"),d=n("6d60"),l=n("b338").f,p=n("aa6b").f,v=n("d910").f,m=n("c10f").trim,g="Number",b=r[g],y=b.prototype,w=u(d(y))==g,z=function(t){var e,n,i,r,o,s,a,u,c=f(t,!1);if("string"==typeof c&&c.length>2)if(c=m(c),e=c.charCodeAt(0),43===e||45===e){if(n=c.charCodeAt(2),88===n||120===n)return NaN}else if(48===e){switch(c.charCodeAt(1)){case 66:case 98:i=2,r=49;break;case 79:case 111:i=8,r=55;break;default:return+c}for(o=c.slice(2),s=o.length,a=0;a<s;a++)if(u=o.charCodeAt(a),u<48||u>r)return NaN;return parseInt(o,i)}return+c};if(o(g,!b(" 0o1")||!b("0b1")||b("+0x1"))){for(var x,M=function(t){var e=arguments.length<1?0:t,n=this;return n instanceof M&&(w?h((function(){y.valueOf.call(n)})):u(n)!=g)?c(new b(z(e)),n,M):z(e)},R=i?l(b):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),S=0;R.length>S;S++)a(b,x=R[S])&&!a(M,x)&&v(M,x,p(b,x));M.prototype=y,y.constructor=M,s(r,g,M)}},5288:function(t,e,n){},"52f9":function(t,e,n){"use strict";var i=n("47ae"),r=n("2a91");t.exports=i?{}.toString:function(){return"[object "+r(this)+"]"}},5355:function(t,e,n){"use strict";var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{ref:"drag",staticClass:"vue-drag-warp",class:t.dragClass,style:t.dragStyle,on:{mousedown:function(e){return e.stopPropagation(),e.preventDefault(),t.handleMouseDown(e)},contextmenu:t.handleContextMenu}},[t._t("default"),t.lineVisible?n("drag-line",{class:t.lineClass}):t._e(),t.resizeVisible?n("drag-resize",{ref:"resize",class:t.resizeClass,attrs:{handles:t.handles},on:{"resize-tl":t.onResizeTlDown,"resize-tr":t.onResizeTrDown,"resize-bl":t.onResizeBlDown,"resize-br":t.onResizeBrDown,"resize-mr":t.onResizeMrDown,"resize-bm":t.onResizeBmDown,"resize-ml":t.onResizeMlDown,"resize-tm":t.onResizeTmDown}}):t._e()],2)},r=[],o=(n("4194"),n("b130"),n("2eeb"),n("513c"),n("e18c"),n("1c2e"),n("90aa"),n("8bbf")),s=n.n(o),a=s.a&&s.a.prototype.$isServer,u=function(){return!a&&document.addEventListener?function(t,e,n){t&&e&&n&&t.addEventListener(e,n,!1)}:function(t,e,n){t&&e&&n&&t.attachEvent("on"+e,n)}}(),c=function(){return!a&&document.removeEventListener?function(t,e,n){t&&e&&t.removeEventListener(e,n,!1)}:function(t,e,n){t&&e&&t.detachEvent("on"+e,n)}}(),f=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"vue-resize-warp"},t._l(t.handleList,(function(e,i){return n("div",{key:i,staticClass:"handle",class:e.className,on:{click:function(t){t.stopPropagation()},mousedown:t.handleMouseDown}})})),0)},h=[],d={props:{handles:{type:Array,default:function(){return["tl","tm","tr","ml","mr","bl","bm","br"]}}},data:function(){return{}},computed:{handleList:function(){var t=[{id:"tl",className:"handle-tl",event:"resize-tl"},{id:"tm",className:"handle-tm",event:"resize-tm"},{id:"tr",className:"handle-tr",event:"resize-tr"},{id:"mr",className:"handle-mr",event:"resize-mr"},{id:"br",className:"handle-br",event:"resize-br"},{id:"bm",className:"handle-bm",event:"resize-bm"},{id:"bl",className:"handle-bl",event:"resize-bl"},{id:"ml",className:"handle-ml",event:"resize-ml"}],e=[];return this.handles.map((function(n){var i=t.find((function(t){return n===t.id}));i&&e.push(i)})),e}},methods:{handleMouseDown:function(t){var e=this.handleList.find((function(e){return e.className===t.target.classList[1]})).event;this.$emit(e,t)}}},l=d;n("e63b");function p(t,e,n,i,r,o,s,a){var u,c="function"===typeof t?t.options:t;if(e&&(c.render=e,c.staticRenderFns=n,c._compiled=!0),i&&(c.functional=!0),o&&(c._scopeId="data-v-"+o),s?(u=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),r&&r.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(s)},c._ssrRegister=u):r&&(u=a?function(){r.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:r),u)if(c.functional){c._injectStyles=u;var f=c.render;c.render=function(t,e){return u.call(e),f(t,e)}}else{var h=c.beforeCreate;c.beforeCreate=h?[].concat(h,u):[u]}return{exports:t,options:c}}var v=p(l,f,h,!1,null,null,null),m=v.exports,g=function(){var t=this,e=t.$createElement;t._self._c;return t._m(0)},b=[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"vue-line-warp"},[n("div",{staticClass:"x-line"}),n("div",{staticClass:"y-line"})])}],y={data:function(){return{}}},w=y,z=(n("a165"),p(w,g,b,!1,null,null,null)),x=z.exports;function M(t,e,n,i){var r,o=!1,s=0;function a(){r&&clearTimeout(r)}function u(){a(),o=!0}function c(){for(var u=arguments.length,c=new Array(u),f=0;f<u;f++)c[f]=arguments[f];var h=this,d=Date.now()-s;function l(){s=Date.now(),n.apply(h,c)}function p(){r=void 0}o||(i&&!r&&l(),a(),void 0===i&&d>t?l():!0!==e&&(r=setTimeout(i?p:l,void 0===i?t-d:t)))}return"boolean"!==typeof e&&(i=n,n=e,e=void 0),c.cancel=u,c}function R(t,e,n){return void 0===n?M(t,e,!1):M(t,n,!1!==e)}var S={name:"Drag",components:{dragResize:m,dragLine:x},props:{z:{type:Number,default:0},left:{type:Number,default:0},top:{type:Number,default:0},active:{type:Boolean,default:!1},parent:{type:Boolean,default:!1},resizable:{type:Boolean,default:!0},resizeInstance:{type:Boolean,default:!1},minWidth:{type:Number,default:0},minHeight:{type:Number,default:0},maxHeight:{type:Number,default:0},maxWidth:{type:Number,default:0},moveEmitDelay:{type:Number,default:0},resizeEmitDelay:{type:Number,default:0},draggable:{type:Boolean,default:!0},initWidth:{type:Number,default:0},initHeight:{type:Number,default:0},dragHandle:{type:String,default:""},dragFilter:{type:String,default:""},disableUserSelect:{type:Boolean,default:!0},componentData:{type:Object,default:function(){return{}}},helpLine:{type:Boolean,default:!1},lineClass:{type:String,default:""},handles:{type:Array,default:function(){return["tl","tm","tr","ml","mr","bl","bm","br"]},validator:function(t){var e=[],n=["tl","tm","tr","ml","mr","bl","bm","br"];return t&&t.length>0&&t.map((function(t){var i=n.find((function(e){return e===t}));i&&e.push(i)})),e}},axis:{type:String,default:"xy",validator:function(t){var e=["x","y","xy"],n=t;return e.includes(n)||(console.error("The value must be one of x, y, xy"),n="xy"),n}},grid:{type:Array,default:function(){return[0,0]}},draggingClass:{type:String,default:"dragging"},resizingClass:{type:String,default:"resizing"},resizeClass:{type:String,default:""}},data:function(){return{x:"",y:"",downX:"",downY:"",resizeDownX:"",resizeDownY:"",downWidth:"",downHeight:"",offsetLeft:"",offsetTop:"",downOffsetLeft:"",downOffsetTop:"",resizeOffsetRight:"",resizeOffsetBottom:"",defaultWidth:"",defaultHeight:"",width:"",height:"",drag:{},flag:"",board:{},resize:{},moveInput:Function,resizeInput:Function,throttleMove:Function,windowResize:Function,dragging:!1,resizing:!1}},destroyed:function(){this.clearAllListener()},computed:{lineVisible:function(){return(this.dragging||this.resizing)&&this.helpLine},resizeVisible:function(){return this.active&&this.resizable},dragStyle:function(){var t=this.width,e=this.height,n=this.y,i=this.x,r=this.disableUserSelect,o=this.z;return{width:"".concat(t,"px"),height:"".concat(e,"px"),top:"".concat(n,"px"),left:"".concat(i,"px"),userSelect:r?"none":"unset",zIndex:o||"unset"}},dragClass:function(){var t=[],e=this.flag,n=this.active,i=this.dragging,r=this.resizing,o=this.draggingClass,s=this.resizingClass,a="".concat(e,"-drag");return e&&t.push(a),n&&t.push("is-active"),i&&t.push(o),r&&t.push(s),t},isX:function(){return"xy"===this.axis||"x"===this.axis},isY:function(){return"xy"===this.axis||"y"===this.axis}},created:function(){},mounted:function(){this.init()},methods:{init:function(){this.handleSetRect();var t=this.drag,e=t.top,n=t.left,i=t.width,r=t.height,o=this.initWidth,s=this.initHeight;this.offsetLeft=n,this.offsetTop=e,this.left>0&&(this.x=this.left+n),this.top>0&&(this.y=this.top+e),this.defaultHeight=r,this.defaultWidth=i,this.moveInput=M(this.moveEmitDelay,this.handleInputMove),this.resizeInput=M(this.resizeEmitDelay,this.handleInputResize),this.throttleMove=M(200,this.handleMouseMove),this.windowResize=R(200,this.initBasicData),u(window,"resize",this.windowResize),o>0&&(this.width=this.initWidth),s>0&&(this.height=this.initHeight),this.validatorProps()},generateId:function(){return Number(Math.random().toString().substr(3,length)+Date.now()).toString(36)},validatorProps:function(){var t=this.initWidth,e=this.minWidth,n=this.initHeight,i=this.minHeight;t>0&&t<e&&console.warn("The initial width cannot be less than the minimum width"),n>0&&n<i&&console.warn("The initial height cannot be less than the minimum height")},handleSetRect:function(){var t=this.$refs.resize;this.board=this.parent?this.$refs.drag.parentElement.getBoundingClientRect():document.body.getBoundingClientRect(),this.resizable&&this.active&&t&&(this.resize=t.$el.querySelectorAll(".handle")[0].getBoundingClientRect()),this.drag=this.$refs.drag.getBoundingClientRect()},handleInputMove:function(t){var e=this.width,n=this.height,i=this.x,r=this.y,o={width:e,height:n,x:i,y:r};this.$emit("dragging",t,o)},handleInputResize:function(t){var e=this.width,n=this.height,i=this.x,r=this.y,o={width:e,height:n,x:i,y:r};this.$emit("resizing",t,o)},initLayoutScheme:function(t){var e=this;this.$nextTick((function(){e.handleSetRect()}));var n=t.path.find((function(t){return t.className.includes("drag-warp")})),i=n.getBoundingClientRect(),r=i.top,o=i.left,s=i.width,a=i.height;this.defaultHeight=a,this.defaultWidth=s,this.downX=t.clientX-o,this.downY=t.clientY-r,this.downOffsetLeft=o,this.downOffsetTop=r},initBasicData:function(){this.handleSetRect();var t=this.$refs.drag.getBoundingClientRect(),e=t.top,n=t.left,i=t.width,r=t.height;this.defaultHeight=r,this.defaultWidth=i,this.downOffsetLeft=n,this.downOffsetTop=e},clearAllListener:function(){c(document,"mouseup",this.handleResizeUp),c(document,"mouseup",this.handleMouseUp),c(document,"mousemove",this.handleMouseMove),c(document,"mousemove",this.handleResizeBrMove),c(document,"mousemove",this.handleResizeMrMove),c(document,"mousemove",this.handleResizeBmMove),c(document,"mousemove",this.handleResizeMlMove),c(document,"mousemove",this.handleResizeTmMove),c(document,"mousemove",this.handleResizeBlMove),c(document,"mousemove",this.handleResizeTrMove),c(document,"mousemove",this.handleResizeTlMove)},handleSetActive:function(t){this.$emit("update:active",!0),this.$emit("active",t,JSON.parse(JSON.stringify(this.componentData)))},handleMouseDown:function(t){var e=this.dragHandle,n=this.dragFilter,i=t.path[0].className,r=!this.active,o=""===e||i.includes(e),s=""===n||!i.includes(n);r&&this.handleSetActive(t),o&&s&&(this.initLayoutScheme(t),this.draggable&&u(document,"mousemove",this.handleMouseMove),u(document,"mouseup",this.handleMouseUp))},handleContextMenu:function(){this.clearAllListener()},handleMouseMove:function(t){var e=this.parent,n=this.downX,i=this.downY,r=this.resizeInstance,o=this.grid,s=this.downOffsetLeft,a=this.downOffsetTop,u=r?this.resize.width:0,c=r?this.resize.height:0,f=e?this.offsetLeft:0,h=e?this.offsetTop:0,d=this.defaultWidth,l=this.defaultHeight,p=t.clientX,v=t.clientY,m=this.board.height,g=this.board.width,b=p-n,y=v-i,w=d+b-f>=g-u,z=l+y-h>=m-c,x=b-f<=0,M=y-h-c<=0,R=g-d+f-u,S=f+u,O=m-l+h-c,T=h+c,D=o[0]?Math.round(b/o[0])*o[0]:b,_=o[1]?Math.round(y/o[1])*o[1]:y;this.isX&&(this.x=x?S:w?R:D),this.isY&&(this.y=M?T:z?O:_),this.dragging=s!==this.x||a!==this.y,this.moveInput(t)},handleMouseUp:function(t){c(document,"mousemove",this.handleMouseMove),c(document,"mouseup",this.handleMouseUp),this.onDragStop(t)},onDragStop:function(t){this.dragging=!1,t.drag={x:this.x,y:this.y},this.$emit("drag-stop",t,JSON.parse(JSON.stringify(this.componentData)))},onResizeStop:function(t){this.resizing=!1,t.drag={x:this.x,y:this.y,width:this.width,heightL:this.height},this.$emit("resize-stop",t,JSON.parse(JSON.stringify(this.componentData)))},handleResizeUp:function(t){c(document,"mousemove",this.handleResizeBrMove),c(document,"mousemove",this.handleResizeMrMove),c(document,"mousemove",this.handleResizeBmMove),c(document,"mousemove",this.handleResizeMlMove),c(document,"mousemove",this.handleResizeTmMove),c(document,"mousemove",this.handleResizeBlMove),c(document,"mousemove",this.handleResizeTrMove),c(document,"mousemove",this.handleResizeTlMove),c(document,"mouseup",this.handleResizeUp),this.onResizeStop(t)},handleResizeBrMove:function(t){this.handleResizeMrMove(t),this.handleResizeBmMove(t),this.resizeInput(t)},handleResizeMlMove:function(t){var e=this.grid,n=this.downWidth,i=this.downOffsetLeft,r=this.minWidth,o=this.resizeDownX,s=this.downHeight,a=this.board,u=this.resize,c=this.resizeInstance,f=this.maxWidth,h=t.clientX,d=c?u.width:0,l=h-o,p=a.left,v=l<0,m=n+l,g=n+Math.abs(l),b=n-l,y=i+l,w=v&&Math.abs(l)+p>=i-d,z=n+(i-p)-d,x=i+n-r,M=0+p+d,R=b<=r,S=i-Math.abs(l),O=e[0]?Math.round(Math.abs(parseFloat(y))/e[0])*e[0]:y,T=e[0]?n-Math.round(l/e[0])*e[0]:b,D=e[0]?n-Math.round(l/e[0])*e[0]:g,_=e[0]?Math.round(Math.abs(S)/e[0])*e[0]:S,E=f>0&&g>=f,N=i-f+n;w?(this.width=z,this.x=M):v?E?(this.width=f,this.x=N):(this.width=D,this.x=_):v?(this.width=m,this.x=i):R?(this.width=r,this.x=x):(this.width=T,this.x=O),this.resizing=n!==this.width||s!==this.height||o!==h,this.resizeInput(t)},handleResizeMrMove:function(t){var e=t.clientX,n=this.downWidth,i=this.downHeight,r=this.resizeDownX,o=this.maxWidth,s=this.resizeInstance,a=this.resize,u=this.grid,c=s?a.width:0,f=0===this.minWidth?l:this.minWidth,h=e-this.resizeDownX,d=this.resizeOffsetRight-c,l=n+h,p=l<=f,v=o>0&&l>=o,m=h>=d,g=n+d,b=u[0]?Math.round(h/u[0])*u[0]+n:l;this.width=p?f:v?o:m?g:b,this.resizing=n!==this.width||i!==this.height||r!==e,this.resizeInput(t)},onResizeMrDown:function(t){this.initResizeData(t),u(document,"mousemove",this.handleResizeMrMove),u(document,"mouseup",this.handleResizeUp),t.stopPropagation()},handleResizeTmMove:function(t){var e=this.downHeight,n=this.downOffsetTop,i=this.resizeDownY,r=this.resizeInstance,o=this.grid,s=this.minHeight,a=this.board,u=this.resizeDownX,c=this.downWidth,f=this.resize,h=this.maxHeight,d=t.clientY,l=t.clientX,p=d-i,v=r?f.height:0,m=a.top,g=p<0,b=e+p,y=e+Math.abs(p),w=e-p,z=n+p,x=g&&Math.abs(p)+m>=n-v,M=e+(n-m)-v,R=n+e-s,S=w<=s,O=n-Math.abs(p),T=o[1]?Math.round(Math.abs(parseFloat(z))/o[1])*o[1]:z,D=o[1]?e-Math.round(p/o[1])*o[1]:w,_=o[1]?e-Math.round(p/o[1])*o[1]:y,E=o[1]?Math.round(Math.abs(O)/o[1])*o[1]:O,N=h>0&&y>=h,j=n-h+e,C=0+m+v;if(x){var I=M<=h?M:h,A=C<=j?j:C;0===h&&(I=M,A=C),this.height=I,this.y=A}else g?N?(this.height=h,this.y=j):(this.height=_,this.y=E):g?(this.height=b,this.y=n):S?(this.height=s,this.y=R):(this.height=D,this.y=T);this.resizing=c!==this.width||e!==this.height||u!==l,this.resizeInput(t)},handleResizeBlMove:function(t){this.handleResizeMlMove(t),this.handleResizeBmMove(t)},handleResizeTrMove:function(t){this.handleResizeTmMove(t),this.handleResizeMrMove(t)},handleResizeTlMove:function(t){this.handleResizeTmMove(t),this.handleResizeMlMove(t)},handleResizeBmMove:function(t){var e=t.clientY,n=t.clientX,i=this.downHeight,r=this.resizeDownX,o=this.downWidth,s=this.minHeight,a=this.resizeOffsetBottom,u=this.resizeDownY,c=this.grid,f=this.maxHeight,h=this.resizeInstance,d=this.resize,l=h?d.width:0,p=e-u,v=a-l,m=i+p,g=m<=s,b=p>=v,y=i+v,w=f>0&&m>=f,z=c[0]?Math.round(p/c[1])*c[1]+i-l:m;this.height=g?s:w?f:b?y:z,this.resizing=o!==this.width||i!==this.height||r!==n,this.resizeInput(t)},onResizeTlDown:function(t){this.initResizeData(t),u(document,"mousemove",this.handleResizeTlMove),u(document,"mouseup",this.handleResizeUp),t.stopPropagation()},onResizeTrDown:function(t){this.initResizeData(t),u(document,"mousemove",this.handleResizeTrMove),u(document,"mouseup",this.handleResizeUp),t.stopPropagation()},onResizeBlDown:function(t){this.initResizeData(t),u(document,"mousemove",this.handleResizeBlMove),u(document,"mouseup",this.handleResizeUp),t.stopPropagation()},onResizeBmDown:function(t){this.initResizeData(t),u(document,"mousemove",this.handleResizeBmMove),u(document,"mouseup",this.handleResizeUp),t.stopPropagation()},onResizeMlDown:function(t){this.initResizeData(t),u(document,"mousemove",this.handleResizeMlMove),u(document,"mouseup",this.handleResizeUp),t.stopPropagation()},onResizeTmDown:function(t){this.initResizeData(t),u(document,"mousemove",this.handleResizeTmMove),u(document,"mouseup",this.handleResizeUp),t.stopPropagation()},initResizeData:function(t){this.handleSetRect();var e=this.board,n=this.drag,i=n.width,r=n.height,o=n.left,s=n.top;this.resizeOffsetRight=e.width-(o-e.left)-i,this.resizeOffsetBottom=e.height-(s-e.top)-r,this.resizeDownX=t.clientX,this.resizeDownY=t.clientY,this.downWidth=i,this.downHeight=r,this.downOffsetTop=s,this.downOffsetLeft=o},onResizeBrDown:function(t){this.initResizeData(t),u(document,"mousemove",this.handleResizeBrMove),u(document,"mouseup",this.handleResizeUp),t.stopPropagation()}}},O=S,T=(n("7654"),p(O,i,r,!1,null,null,null));e["a"]=T.exports},"5dfd":function(t,e,n){var i=n("e349"),r=n("692f"),o=n("3553"),s=n("d88d"),a=n("1ca1"),u=[].push,c=function(t){var e=1==t,n=2==t,c=3==t,f=4==t,h=6==t,d=5==t||h;return function(l,p,v,m){for(var g,b,y=o(l),w=r(y),z=i(p,v,3),x=s(w.length),M=0,R=m||a,S=e?R(l,x):n?R(l,0):void 0;x>M;M++)if((d||M in w)&&(g=w[M],b=z(g,M,y),t))if(e)S[M]=b;else if(b)switch(t){case 3:return!0;case 5:return g;case 6:return M;case 2:u.call(S,g)}else if(f)return!1;return h?-1:c||f?f:S}};t.exports={forEach:c(0),map:c(1),filter:c(2),some:c(3),every:c(4),find:c(5),findIndex:c(6)}},"604f":function(t,e,n){var i=n("d890"),r=n("1025"),o=i.WeakMap;t.exports="function"===typeof o&&/native code/.test(r(o))},"692f":function(t,e,n){var i=n("efe2"),r=n("2118"),o="".split;t.exports=i((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==r(t)?o.call(t,""):Object(t)}:Object},"6d28":function(t,e,n){var i=n("9b9d"),r=n("3a08");(t.exports=function(t,e){return r[t]||(r[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.6.5",mode:i?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},"6d60":function(t,e,n){var i,r=n("857c"),o=n("dbe8"),s=n("18f6"),a=n("d5a8"),u=n("6fdf"),c=n("ae25"),f=n("7db2"),h=">",d="<",l="prototype",p="script",v=f("IE_PROTO"),m=function(){},g=function(t){return d+p+h+t+d+"/"+p+h},b=function(t){t.write(g("")),t.close();var e=t.parentWindow.Object;return t=null,e},y=function(){var t,e=c("iframe"),n="java"+p+":";return e.style.display="none",u.appendChild(e),e.src=String(n),t=e.contentWindow.document,t.open(),t.write(g("document.F=Object")),t.close(),t.F},w=function(){try{i=document.domain&&new ActiveXObject("htmlfile")}catch(e){}w=i?b(i):y();var t=s.length;while(t--)delete w[l][s[t]];return w()};a[v]=!0,t.exports=Object.create||function(t,e){var n;return null!==t?(m[l]=r(t),n=new m,m[l]=null,n[v]=t):n=w(),void 0===e?n:o(n,e)}},"6d7a":function(t,e,n){var i=n("1b99"),r=n("d890"),o=function(t){return"function"==typeof t?t:void 0};t.exports=function(t,e){return arguments.length<2?o(i[t])||o(r[t]):i[t]&&i[t][e]||r[t]&&r[t][e]}},"6fdf":function(t,e,n){var i=n("6d7a");t.exports=i("document","documentElement")},7063:function(t,e,n){var i=n("a719"),r=n("50fb");t.exports=function(t,e,n){var o,s;return r&&"function"==typeof(o=e.constructor)&&o!==n&&i(s=o.prototype)&&s!==n.prototype&&r(t,s),t}},"74cb":function(t,e,n){var i=n("c54b");t.exports=i&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},"74e7":function(t,e,n){var i=n("2118");t.exports=Array.isArray||function(t){return"Array"==i(t)}},7654:function(t,e,n){"use strict";var i=n("5288"),r=n.n(i);r.a},"783d":function(t,e,n){var i=n("90fb"),r=i("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[r]=!1,"/./"[t](e)}catch(i){}}return!1}},"79e4":function(t,e,n){var i,r,o;(function(n,s){r=[],i=s,o="function"===typeof i?i.apply(e,r):i,void 0===o||(t.exports=o)})("undefined"!==typeof self&&self,(function(){function t(){var e=Object.getOwnPropertyDescriptor(document,"currentScript");if(!e&&"currentScript"in document&&document.currentScript)return document.currentScript;if(e&&e.get!==t&&document.currentScript)return document.currentScript;try{throw new Error}catch(l){var n,i,r,o=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,s=/@([^@]*):(\d+):(\d+)\s*$/gi,a=o.exec(l.stack)||s.exec(l.stack),u=a&&a[1]||!1,c=a&&a[2]||!1,f=document.location.href.replace(document.location.hash,""),h=document.getElementsByTagName("script");u===f&&(n=document.documentElement.outerHTML,i=new RegExp("(?:[^\\n]+?\\n){0,"+(c-2)+"}[^<]*<script>([\\d\\D]*?)<\\/script>[\\d\\D]*","i"),r=n.replace(i,"$1").trim());for(var d=0;d<h.length;d++){if("interactive"===h[d].readyState)return h[d];if(h[d].src===u)return h[d];if(u===f&&h[d].innerHTML&&h[d].innerHTML.trim()===r)return h[d]}return null}}return t}))},"7db2":function(t,e,n){var i=n("6d28"),r=n("7e8b"),o=i("keys");t.exports=function(t){return o[t]||(o[t]=r(t))}},"7e8b":function(t,e){var n=0,i=Math.random();t.exports=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++n+i).toString(36)}},"857c":function(t,e,n){var i=n("a719");t.exports=function(t){if(!i(t))throw TypeError(String(t)+" is not an object");return t}},"8a1c":function(t,e,n){var i=n("a719"),r=n("2118"),o=n("90fb"),s=o("match");t.exports=function(t){var e;return i(t)&&(void 0!==(e=t[s])?!!e:"RegExp"==r(t))}},"8bbf":function(e,n){e.exports=t},"8d44":function(t,e,n){var i=n("6d7a"),r=n("b338"),o=n("0a60"),s=n("857c");t.exports=i("Reflect","ownKeys")||function(t){var e=r.f(s(t)),n=o.f;return n?e.concat(n(t)):e}},"90aa":function(t,e,n){"use strict";var i=n("1c8b"),r=n("07a2"),o=n("2732"),s=n("783d");i({target:"String",proto:!0,forced:!s("includes")},{includes:function(t){return!!~String(o(this)).indexOf(r(t),arguments.length>1?arguments[1]:void 0)}})},"90fb":function(t,e,n){var i=n("d890"),r=n("6d28"),o=n("faa8"),s=n("7e8b"),a=n("c54b"),u=n("74cb"),c=r("wks"),f=i.Symbol,h=u?f:f&&f.withoutSetter||s;t.exports=function(t){return o(c,t)||(a&&o(f,t)?c[t]=f[t]:c[t]=h("Symbol."+t)),c[t]}},9701:function(t,e,n){},9896:function(t,e,n){"use strict";if(n.r(e),n.d(e,"install",(function(){return s["b"]})),"undefined"!==typeof window){var i=window.document.currentScript,r=n("79e4");i=r(),"currentScript"in document||Object.defineProperty(document,"currentScript",{get:r});var o=i&&i.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);o&&(n.p=o[1])}var s=n("b635");e["default"]=s["a"]},"99ad":function(t,e,n){"use strict";var i=n("857c");t.exports=function(){var t=i(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e}},"9b9d":function(t,e){t.exports=!1},"9f67":function(t,e,n){var i=n("a719");t.exports=function(t,e){if(!i(t))return t;var n,r;if(e&&"function"==typeof(n=t.toString)&&!i(r=n.call(t)))return r;if("function"==typeof(n=t.valueOf)&&!i(r=n.call(t)))return r;if(!e&&"function"==typeof(n=t.toString)&&!i(r=n.call(t)))return r;throw TypeError("Can't convert object to primitive value")}},a165:function(t,e,n){"use strict";var i=n("05ce"),r=n.n(i);r.a},a719:function(t,e){t.exports=function(t){return"object"===typeof t?null!==t:"function"===typeof t}},aa6b:function(t,e,n){var i=n("1e2c"),r=n("ef71"),o=n("38b9"),s=n("da10"),a=n("9f67"),u=n("faa8"),c=n("2039"),f=Object.getOwnPropertyDescriptor;e.f=i?f:function(t,e){if(t=s(t),e=a(e,!0),c)try{return f(t,e)}catch(n){}if(u(t,e))return o(!r.f.call(t,e),t[e])}},ae25:function(t,e,n){var i=n("d890"),r=n("a719"),o=i.document,s=r(o)&&r(o.createElement);t.exports=function(t){return s?o.createElement(t):{}}},b130:function(t,e,n){"use strict";var i=n("1c8b"),r=n("45af").includes,o=n("258f"),s=n("ff9c"),a=s("indexOf",{ACCESSORS:!0,1:0});i({target:"Array",proto:!0,forced:!a},{includes:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}}),o("includes")},b338:function(t,e,n){var i=n("ead4"),r=n("18f6"),o=r.concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return i(t,o)}},b635:function(t,e,n){"use strict";(function(t){n.d(e,"b",(function(){return r}));n("fc27");var i=n("5355");function r(t){r.installed||(r.installed=!0,t.component("vueDragComponent",i["a"]))}var o={install:r},s=null;"undefined"!==typeof window?s=window.Vue:"undefined"!==typeof t&&(s=t.Vue),s&&s.use(o),e["a"]=i["a"]}).call(this,n("ce00"))},b702:function(t,e,n){var i,r,o,s=n("604f"),a=n("d890"),u=n("a719"),c=n("0fc1"),f=n("faa8"),h=n("7db2"),d=n("d5a8"),l=a.WeakMap,p=function(t){return o(t)?r(t):i(t,{})},v=function(t){return function(e){var n;if(!u(e)||(n=r(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return n}};if(s){var m=new l,g=m.get,b=m.has,y=m.set;i=function(t,e){return y.call(m,t,e),e},r=function(t){return g.call(m,t)||{}},o=function(t){return b.call(m,t)}}else{var w=h("state");d[w]=!0,i=function(t,e){return c(t,w,e),e},r=function(t){return f(t,w)?t[w]:{}},o=function(t){return f(t,w)}}t.exports={set:i,get:r,has:o,enforce:p,getterFor:v}},c10f:function(t,e,n){var i=n("2732"),r=n("fc8c"),o="["+r+"]",s=RegExp("^"+o+o+"*"),a=RegExp(o+o+"*$"),u=function(t){return function(e){var n=String(i(e));return 1&t&&(n=n.replace(s,"")),2&t&&(n=n.replace(a,"")),n}};t.exports={start:u(1),end:u(2),trim:u(3)}},c54b:function(t,e,n){var i=n("efe2");t.exports=!!Object.getOwnPropertySymbols&&!i((function(){return!String(Symbol())}))},c69d:function(t,e,n){var i=n("faa8"),r=n("8d44"),o=n("aa6b"),s=n("d910");t.exports=function(t,e){for(var n=r(e),a=s.f,u=o.f,c=0;c<n.length;c++){var f=n[c];i(t,f)||a(t,f,u(e,f))}}},cbab:function(t,e,n){var i=n("ead4"),r=n("18f6");t.exports=Object.keys||function(t){return i(t,r)}},ce00:function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(i){"object"===typeof window&&(n=window)}t.exports=n},d1fd:function(t,e,n){var i=n("a719");t.exports=function(t){if(!i(t)&&null!==t)throw TypeError("Can't set "+String(t)+" as a prototype");return t}},d5a8:function(t,e){t.exports={}},d88d:function(t,e,n){var i=n("3da3"),r=Math.min;t.exports=function(t){return t>0?r(i(t),9007199254740991):0}},d890:function(t,e,n){(function(e){var n=function(t){return t&&t.Math==Math&&t};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||Function("return this")()}).call(this,n("ce00"))},d910:function(t,e,n){var i=n("1e2c"),r=n("2039"),o=n("857c"),s=n("9f67"),a=Object.defineProperty;e.f=i?a:function(t,e,n){if(o(t),e=s(e,!0),o(n),r)try{return a(t,e,n)}catch(i){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},da10:function(t,e,n){var i=n("692f"),r=n("2732");t.exports=function(t){return i(r(t))}},dbe8:function(t,e,n){var i=n("1e2c"),r=n("d910"),o=n("857c"),s=n("cbab");t.exports=i?Object.defineProperties:function(t,e){o(t);var n,i=s(e),a=i.length,u=0;while(a>u)r.f(t,n=i[u++],e[n]);return t}},e18c:function(t,e,n){var i=n("47ae"),r=n("1944"),o=n("52f9");i||r(Object.prototype,"toString",o,{unsafe:!0})},e1d6:function(t,e,n){var i=n("3da3"),r=Math.max,o=Math.min;t.exports=function(t,e){var n=i(t);return n<0?r(n+e,0):o(n,e)}},e349:function(t,e,n){var i=n("0c3c");t.exports=function(t,e,n){if(i(t),void 0===e)return t;switch(n){case 0:return function(){return t.call(e)};case 1:return function(n){return t.call(e,n)};case 2:return function(n,i){return t.call(e,n,i)};case 3:return function(n,i,r){return t.call(e,n,i,r)}}return function(){return t.apply(e,arguments)}}},e4db:function(t,e,n){var i=n("d890"),r=n("0fc1");t.exports=function(t,e){try{r(i,t,e)}catch(n){i[t]=e}return e}},e63b:function(t,e,n){"use strict";var i=n("9701"),r=n.n(i);r.a},e8d6:function(t,e,n){var i=n("efe2"),r=/#|\.prototype\./,o=function(t,e){var n=a[s(t)];return n==c||n!=u&&("function"==typeof e?i(e):!!e)},s=o.normalize=function(t){return String(t).replace(r,".").toLowerCase()},a=o.data={},u=o.NATIVE="N",c=o.POLYFILL="P";t.exports=o},ead4:function(t,e,n){var i=n("faa8"),r=n("da10"),o=n("45af").indexOf,s=n("d5a8");t.exports=function(t,e){var n,a=r(t),u=0,c=[];for(n in a)!i(s,n)&&i(a,n)&&c.push(n);while(e.length>u)i(a,n=e[u++])&&(~o(c,n)||c.push(n));return c}},ef71:function(t,e,n){"use strict";var i={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor,o=r&&!i.call({1:2},1);e.f=o?function(t){var e=r(this,t);return!!e&&e.enumerable}:i},efe2:function(t,e){t.exports=function(t){try{return!!t()}catch(e){return!0}}},f594:function(t,e,n){var i,r,o=n("d890"),s=n("4fda"),a=o.process,u=a&&a.versions,c=u&&u.v8;c?(i=c.split("."),r=i[0]+i[1]):s&&(i=s.match(/Edge\/(\d+)/),(!i||i[1]>=74)&&(i=s.match(/Chrome\/(\d+)/),i&&(r=i[1]))),t.exports=r&&+r},faa8:function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},fc27:function(t,e,n){},fc8c:function(t,e){t.exports="\t\n\v\f\r                　\u2028\u2029\ufeff"},ff9c:function(t,e,n){var i=n("1e2c"),r=n("efe2"),o=n("faa8"),s=Object.defineProperty,a={},u=function(t){throw t};t.exports=function(t,e){if(o(a,t))return a[t];e||(e={});var n=[][t],c=!!o(e,"ACCESSORS")&&e.ACCESSORS,f=o(e,0)?e[0]:u,h=o(e,1)?e[1]:void 0;return a[t]=!!n&&!r((function(){if(c&&!i)return!0;var t={length:-1};c?s(t,1,{enumerable:!0,get:u}):t[1]=1,n.call(t,f,h)}))}}})["default"]}));
//# sourceMappingURL=vueDragComponent.umd.min.js.map