(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["components/DragImage/DragImage"],{"0ea8":function(t,e,i){"use strict";i.r(e);var n=i("b514"),a=i("9542");for(var s in a)"default"!==s&&function(t){i.d(e,t,(function(){return a[t]}))}(s);i("a51b");var o,r=i("f0c5"),h=Object(r["a"])(a["default"],n["b"],n["c"],!1,null,"e876b32a",null,!1,n["a"],o);e["default"]=h.exports},"7e25":function(t,e,i){"use strict";(function(t){function i(t,e){var i;if("undefined"===typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(i=n(t))||e&&t&&"number"===typeof t.length){i&&(t=i);var a=0,s=function(){};return{s:s,n:function(){return a>=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function(t){throw t},f:s}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,r=!0,h=!1;return{s:function(){i=t[Symbol.iterator]()},n:function(){var t=i.next();return r=t.done,t},e:function(t){h=!0,o=t},f:function(){try{r||null==i.return||i.return()}finally{if(h)throw o}}}}function n(t,e){if(t){if("string"===typeof t)return a(t,e);var i=Object.prototype.toString.call(t).slice(8,-1);return"Object"===i&&t.constructor&&(i=t.constructor.name),"Map"===i||"Set"===i?Array.from(t):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?a(t,e):void 0}}function a(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,n=new Array(e);i0&&(e.colsValue=e.cols,e.viewWidth=t.width/e.cols),e.imageList=[];var n,a=i(e.list);try{for(a.s();!(n=a.n()).done;){var s=n.value;e.addProperties(s)}}catch(o){a.e(o)}finally{a.f()}})),n.exec()},onChange:function(t,e){var n=this;if(e&&(e.oldX=t.detail.x,e.oldY=t.detail.y,"touch"===t.detail.source)){e.moveEnd&&(e.offset=Math.sqrt(Math.pow(e.oldX-e.absX*this.viewWidth,2)+Math.pow(e.oldY-e.absY*this.viewWidth,2)));var a=Math.floor((t.detail.x+this.viewWidth/2)/this.viewWidth);if(a>=this.colsValue)return;var s=Math.floor((t.detail.y+this.viewWidth/2)/this.viewWidth),o=this.colsValue*s+a;if(e.index!=o&&oo&&t.index>=o&&t.indexe.index?n.change(t,-1):t.id!=e.id&&(t.offset=0,t.x=t.oldX,t.y=t.oldY,setTimeout((function(){n.$nextTick((function(){t.x=t.absX*n.viewWidth,t.y=t.absY*n.viewWidth}))}),0))};for(h.s();!(r=h.n()).done;)u()}catch(l){h.e(l)}finally{h.f()}e.index=o,e.absX=a,e.absY=s}}},change:function(t,e){var i=this;t.index+=e,t.offset=0,t.x=t.oldX,t.y=t.oldY,t.absX=t.index%this.colsValue,t.absY=Math.floor(t.index/this.colsValue),setTimeout((function(){i.$nextTick((function(){t.x=t.absX*i.viewWidth,t.y=t.absY*i.viewWidth}))}),0)},touchstart:function(e){var i=this;t.vibrateShort(),e.disable=!1,this.imageList.forEach((function(t){t.zIndex=t.index+9})),e.zIndex=99,e.moveEnd=!0,this.tempItem=e,this.timer=setTimeout((function(){e.scale=i.scale,e.opacity=i.opacity,clearTimeout(i.timer),i.timer=null}),200)},touchend:function(t){var e=this;this.previewImage(t),t.scale=1,t.opacity=1,t.x=t.oldX,t.y=t.oldY,t.offset=0,t.moveEnd=!1,t.disable=!0,setTimeout((function(){e.$nextTick((function(){t.x=t.absX*e.viewWidth,t.y=t.absY*e.viewWidth,e.tempItem=null,e.changeStatus=!0}))}),0),this.sortList()},previewImage:function(e){if("object"!==typeof e)if(this.chooseImage){this.imageList[e].choosed=!this.imageList[e].choosed;for(var i=1,n=[],a=0;at.index&&(e.index-=1,e.x=e.oldX,e.y=e.oldY,e.absX=e.index%n.colsValue,e.absY=Math.floor(e.index/n.colsValue),n.$nextTick((function(){e.x=e.absX*n.viewWidth,e.y=e.absY*n.viewWidth})))};for(s.s();!(a=s.n()).done;)o()}catch(r){s.e(r)}finally{s.f()}this.add.x=this.imageList.length%this.colsValue*this.viewWidth+"px",this.add.y=Math.floor(this.imageList.length/this.colsValue)*this.viewWidth+"px",this.sortList(),this.$emit("delImage",e)},delImageMp:function(t,e){this.delImage(t,e)},sortList:function(){var t=this.imageList.slice();t.sort((function(t,e){return t.index-e.index}));for(var e=0;e