Comparing version 0.1.13 to 0.1.14
@@ -1,2 +0,2 @@ | ||
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.Dui=e():t.Dui=e()}(this,function(){return function(t){function e(o){if(n[o])return n[o].exports;var i=n[o]={exports:{},id:o,loaded:!1};return t[o].call(i.exports,i,i.exports,e),i.loaded=!0,i.exports}var n={};return e.m=t,e.c=n,e.p="/dist/",e(0)}([function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}var i=n(1),r=o(i),a=n(91),u=o(a);t.exports={Modal:r.default,Tip:u.default}},function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var u=function(){function t(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}return function(e,n,o){return n&&t(e.prototype,n),o&&t(e,o),e}}();n(2);var c=n(6),l=o(c),s=n(8),f=o(s),d=n(84),p=o(d),h=n(85),v=o(h),g=n(86),m=o(g),y=n(87),b=o(y),w=n(88),x=o(w),_=n(89),j=o(_),k=n(90),O=o(k);e.default=function(){Object.assign(p.default,l.default);var t=function(t){function e(t){i(this,e);var n=r(this,(e.__proto__||Object.getPrototypeOf(e)).call(this)),o={type:"default",showType:"normal",title:"提示",content:"内容",isSingle:!1,height:"auto",okValue:"确定",cancelValue:"取消",className:"",zIndex:9999,titleIconClass:"",closeClass:p.default.closeIconClass,mask:!0,close:!0,ok:!1,cancel:!1,btnPos:"right",draggable:!1,appendEl:document.body};return n.option=t,n.option=Object.assign({},o,n.option),n.init(),n}return a(e,t),u(e,[{key:"init",value:function(){this.handleOption(),this.render(),this.bindEvent(),this.handleDrag(),this.option.init&&this.option.init.apply(this)}},{key:"handleOption",value:function(){this.handleOptionWidth(),this.handleOptionHeight(),this.handleOptionButton(),this.handleOptionContentHeight(),this.handleOptionContent()}},{key:"handleOptionWidth",value:function(){var t=this.option.width;t=t?parseInt(t,10):p.default.minWidth,p.default.minWidth-t>=0&&(t=p.default.minWidth),p.default.maxWidth-t<0&&(t=p.default.maxWidth),this.option.width=t}},{key:"handleOptionHeight",value:function(){var t=this.option.height;"auto"!==t&&(t=t?parseInt(t,10):p.default.minHeight,p.default.minHeight-t>=0&&(t=p.default.minHeight),p.default.maxHeight-t<0&&(t=p.default.maxHeight),this.option.height=t)}},{key:"handleOptionContentHeight",value:function(){var t=this.option.height,e=p.default.padding,n=p.default.minHeight,o=p.default.maxHeight,i=void 0,r=p.default.hdHeight,a=p.default.ftHeight;if(this.option.ok||this.option.cancel?i=3*e:(i=2*e,a=0),""===this.option.title&&(r=14),"auto"===t){this.option.contentHeight="auto";var u=n-r-a-i,c=o-r-a-i;this.option.contentMaxHeight=c,this.option.contentMinHeight=u}else{var l=t-r-a-i;this.option.contentHeight=l}}},{key:"handleOptionButton",value:function(){var t=this.option.ok,e=this.option.cancel,n=void 0;null==t?this.option.ok=!1:(n="boolean"==typeof t,this.option.ok=!!t,this.option.okValue=n?this.option.okValue:t),null==e?this.option.cancel=!1:(n="boolean"==typeof e,this.option.cancel=!!e,this.option.cancelValue=n?this.option.cancelValue:e),this.option.okFn&&(this.option.ok=!0),this.option.cancelFn&&(this.option.cancel=!0),this.option.btnPosClass="dui-dialog-ft-"+this.option.btnPos}},{key:"handleOptionContent",value:function(){var t=this.option.content,e=t.charAt(0);if("#"===e){var n=v.default.findById(t.slice(1));null!=n&&(this.option.content=v.default.getHtml(n),"script"!==n.tagName.toLowerCase()&&v.default.remove(n))}}},{key:"render",value:function(){this.option.isSingle&&v.default.find(".dui-dialog")&&v.default.remove(v.default.find(".dui-dialog"));var t=v.default.has(".dui-dialog-wrap").length,e=f.default.renderTemp(O.default,this.option);if(0===t&&this.option.mask){var n='<div class="dui-dialog-wrap" style="z-index: '+this.option.zIndex+'"></div>';v.default.appendHTML(document.body,n),j.default.disableScroll()}this.option.mask?this.dialogDom=v.default.appendHTML(v.default.find(".dui-dialog-wrap"),e):("string"==typeof this.option.appendEl&&(this.option.appendEl=v.default.find(this.option.appendEl)),this.dialogDom=v.default.appendHTML(this.option.appendEl,e)),this.show()}},{key:"show",value:function(){switch(this.option.showType){case"normal":v.default.show(this.dialogDom);break;case"fade":this.dialogDom.style.top="-50%",this.dialogDom.style.opacity=0,v.default.show(this.dialogDom),x.default.startMove(this.dialogDom,{top:document.documentElement.clientHeight/2,opacity:100},800)}}},{key:"hide",value:function(){this.destroy()}},{key:"destroy",value:function(){this.unBindEvent();var t=void 0;t=this.option.mask?v.default.has(v.default.find(".dui-dialog-wrap"),".dui-dialog").length:v.default.has(".dui-dialog").length,v.default.remove(this.dialogDom),1===t&&this.option.mask&&(v.default.remove(v.default.find(".dui-dialog-wrap")),j.default.enableScroll()),this.dialogDom=null}},{key:"_okFn",value:function(){this.$emit("ok"),this.option.okFn&&this.option.okFn.apply(this)}},{key:"_cancelFn",value:function(t){this.$emit("cancel"),this.option.cancelFn&&this.option.cancelFn.apply(this),this.$emit("destroy"),t.stopPropagation(),this.hide()}},{key:"_closeFn",value:function(t){this.$emit("close"),this.$emit("destroy"),t.stopPropagation(),this.hide()}},{key:"_escFn",value:function(t){27===t.keyCode&&(this.$emit("esc"),this.$emit("destroy"),t.stopPropagation(),this.hide())}},{key:"handleDrag",value:function(){if(this.option.draggable){var t=v.default.find(this.dialogDom,".dui-dialog-hd");v.default.addClass(t,"z-draggable"),b.default.startDrag(t,this.dialogDom,p.default.boundary(this.dialogDom,this.option.appendEl),this)}}},{key:"bindEvent",value:function(){var t=this.okBtn=v.default.find(this.dialogDom,".J_dialog-ok"),n=this.cancelBtn=v.default.find(this.dialogDom,".J_dialog-cancel"),o=this.closeBtn=v.default.find(this.dialogDom,".J_dialog-close"),i=this.dialogBd=v.default.find(this.dialogDom,".dui-dialog-bd")||v.default.find(this.dialogDom,".dui-dialog-custom-bd");t&&t.addEventListener("click",this.bindOkClick=this._okFn.bind(this),!1),n&&n.addEventListener("click",this.bindCancelClick=this._cancelFn.bind(this),!1),o&&o.addEventListener("click",this.bindCloseClick=this._closeFn.bind(this),!1),i&&i.addEventListener("mousewheel",e.stopPropagation,!1),i&&i.addEventListener("touchmove",e.stopPropagation,!1),document.addEventListener("keydown",this.bindEscClick=this._escFn.bind(this),!1)}},{key:"unBindEvent",value:function(){var t=this.okBtn,n=this.cancelBtn,o=this.closeBtn,i=this.dialogBd;t&&t.removeEventListener("click",this.bindOkClick,!1),n&&n.removeEventListener("click",this.bindCancelClick,!1),o&&o.removeEventListener("click",this.bindCloseClick,!1),i&&i.removeEventListener("mousewheel",e.stopPropagation,!1),i&&i.removeEventListener("touchmove",e.stopPropagation,!1),document.removeEventListener("keydown",this.bindEscClick,!1)}}],[{key:"stopPropagation",value:function(t){t.stopPropagation()}}]),e}(m.default);return t.alert=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"提示",o=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return new t({title:n,content:e,close:o,height:"auto",okFn:function(){this.hide()}})},t.confirm=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"提示",o=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"right";return new Promise(function(r){new t({title:n,content:e,close:o,height:"auto",btnPos:i,okFn:function(){r(!0),this.hide()},cancelFn:function(){r(!1)}})})},t}()},function(t,e){},,,,function(t,e){t.exports={minWidth:"420",minHeight:"170",maxWidth:"920",maxHeight:"580",hdHeight:"45",ftHeight:"30",padding:"16"}},,function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var i=n(9),r=o(i),a=n(82),u=o(a);e.default={extend:u.default,renderTemp:function(t,e){var n=(0,r.default)(t);return n(e)},now:function(){return(new Date).getTime()}}},function(t,e,n){function o(t,e,n){var o=p.imports._.templateSettings||p;n&&s(t,e,n)&&(e=void 0),t=h(t),e=i({},e,o,u);var x,_,j=i({},e.imports,o.imports,u),k=f(j),O=a(j,k),E=0,M=e.interpolate||b,C="__p += '",P=RegExp((e.escape||b).source+"|"+M.source+"|"+(M===d?y:b).source+"|"+(e.evaluate||b).source+"|$","g"),H="sourceURL"in e?"//# sourceURL="+e.sourceURL+"\n":"";t.replace(P,function(e,n,o,i,r,a){return o||(o=i),C+=t.slice(E,a).replace(w,c),n&&(x=!0,C+="' +\n__e("+n+") +\n'"),r&&(_=!0,C+="';\n"+r+";\n__p += '"),o&&(C+="' +\n((__t = ("+o+")) == null ? '' : __t) +\n'"),E=a+e.length,e}),C+="';\n";var T=e.variable;T||(C="with (obj) {\n"+C+"\n}\n"),C=(_?C.replace(v,""):C).replace(g,"$1").replace(m,"$1;"),C="function("+(T||"obj")+") {\n"+(T?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(x?", __e = _.escape":"")+(_?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+C+"return __p\n}";var S=r(function(){return Function(k,H+"return "+C).apply(void 0,O)});if(S.source=C,l(S))throw S;return S}var i=n(10),r=n(60),a=n(65),u=n(67),c=n(68),l=n(61),s=n(39),f=n(69),d=n(72),p=n(73),h=n(77),v=/\b__p \+= '';/g,g=/\b(__p \+=) '' \+/g,m=/(__e\(.*?\)|\b__t\)) \+\n'';/g,y=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,b=/($^)/,w=/['\n\r\u2028\u2029\\]/g;t.exports=o},function(t,e,n){var o=n(11),i=n(30),r=n(43),a=i(function(t,e,n,i){o(e,r(e),t,i)});t.exports=a},function(t,e,n){function o(t,e,n,o){var a=!n;n||(n={});for(var u=-1,c=e.length;++u<c;){var l=e[u],s=o?o(n[l],t[l],l,n,t):void 0;void 0===s&&(s=t[l]),a?r(n,l,s):i(n,l,s)}return n}var i=n(12),r=n(13);t.exports=o},function(t,e,n){function o(t,e,n){var o=t[e];u.call(t,e)&&r(o,n)&&(void 0!==n||e in t)||i(t,e,n)}var i=n(13),r=n(29),a=Object.prototype,u=a.hasOwnProperty;t.exports=o},function(t,e,n){function o(t,e,n){"__proto__"==e&&i?i(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}var i=n(14);t.exports=o},function(t,e,n){var o=n(15),i=function(){try{var t=o(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=i},function(t,e,n){function o(t,e){var n=r(t,e);return i(n)?n:void 0}var i=n(16),r=n(28);t.exports=o},function(t,e,n){function o(t){if(!a(t)||r(t))return!1;var e=i(t)?h:l;return e.test(u(t))}var i=n(17),r=n(25),a=n(24),u=n(27),c=/[\\^$.*+?()[\]{}|]/g,l=/^\[object .+?Constructor\]$/,s=Function.prototype,f=Object.prototype,d=s.toString,p=f.hasOwnProperty,h=RegExp("^"+d.call(p).replace(c,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=o},function(t,e,n){function o(t){if(!r(t))return!1;var e=i(t);return e==u||e==c||e==a||e==l}var i=n(18),r=n(24),a="[object AsyncFunction]",u="[object Function]",c="[object GeneratorFunction]",l="[object Proxy]";t.exports=o},function(t,e,n){function o(t){return null==t?void 0===t?c:u:l&&l in Object(t)?r(t):a(t)}var i=n(19),r=n(22),a=n(23),u="[object Null]",c="[object Undefined]",l=i?i.toStringTag:void 0;t.exports=o},function(t,e,n){var o=n(20),i=o.Symbol;t.exports=i},function(t,e,n){var o=n(21),i="object"==typeof self&&self&&self.Object===Object&&self,r=o||i||Function("return this")();t.exports=r},function(t,e){(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.exports=n}).call(e,function(){return this}())},function(t,e,n){function o(t){var e=a.call(t,c),n=t[c];try{t[c]=void 0;var o=!0}catch(t){}var i=u.call(t);return o&&(e?t[c]=n:delete t[c]),i}var i=n(19),r=Object.prototype,a=r.hasOwnProperty,u=r.toString,c=i?i.toStringTag:void 0;t.exports=o},function(t,e){function n(t){return i.call(t)}var o=Object.prototype,i=o.toString;t.exports=n},function(t,e){function n(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}t.exports=n},function(t,e,n){function o(t){return!!r&&r in t}var i=n(26),r=function(){var t=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();t.exports=o},function(t,e,n){var o=n(20),i=o["__core-js_shared__"];t.exports=i},function(t,e){function n(t){if(null!=t){try{return i.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var o=Function.prototype,i=o.toString;t.exports=n},function(t,e){function n(t,e){return null==t?void 0:t[e]}t.exports=n},function(t,e){function n(t,e){return t===e||t!==t&&e!==e}t.exports=n},function(t,e,n){function o(t){return i(function(e,n){var o=-1,i=n.length,a=i>1?n[i-1]:void 0,u=i>2?n[2]:void 0;for(a=t.length>3&&"function"==typeof a?(i--,a):void 0,u&&r(n[0],n[1],u)&&(a=i<3?void 0:a,i=1),e=Object(e);++o<i;){var c=n[o];c&&t(e,c,o,a)}return e})}var i=n(31),r=n(39);t.exports=o},function(t,e,n){function o(t,e){return a(r(t,e,i),t+"")}var i=n(32),r=n(33),a=n(35);t.exports=o},function(t,e){function n(t){return t}t.exports=n},function(t,e,n){function o(t,e,n){return e=r(void 0===e?t.length-1:e,0),function(){for(var o=arguments,a=-1,u=r(o.length-e,0),c=Array(u);++a<u;)c[a]=o[e+a];a=-1;for(var l=Array(e+1);++a<e;)l[a]=o[a];return l[e]=n(c),i(t,this,l)}}var i=n(34),r=Math.max;t.exports=o},function(t,e){function n(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}t.exports=n},function(t,e,n){var o=n(36),i=n(38),r=i(o);t.exports=r},function(t,e,n){var o=n(37),i=n(14),r=n(32),a=i?function(t,e){return i(t,"toString",{configurable:!0,enumerable:!1,value:o(e),writable:!0})}:r;t.exports=a},function(t,e){function n(t){return function(){return t}}t.exports=n},function(t,e){function n(t){var e=0,n=0;return function(){var a=r(),u=i-(a-n);if(n=a,u>0){if(++e>=o)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var o=800,i=16,r=Date.now;t.exports=n},function(t,e,n){function o(t,e,n){if(!u(n))return!1;var o=typeof e;return!!("number"==o?r(n)&&a(e,n.length):"string"==o&&e in n)&&i(n[e],t)}var i=n(29),r=n(40),a=n(42),u=n(24);t.exports=o},function(t,e,n){function o(t){return null!=t&&r(t.length)&&!i(t)}var i=n(17),r=n(41);t.exports=o},function(t,e){function n(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=o}var o=9007199254740991;t.exports=n},function(t,e){function n(t,e){return e=null==e?o:e,!!e&&("number"==typeof t||i.test(t))&&t>-1&&t%1==0&&t<e}var o=9007199254740991,i=/^(?:0|[1-9]\d*)$/;t.exports=n},function(t,e,n){function o(t){return a(t)?i(t,!0):r(t)}var i=n(44),r=n(57),a=n(40);t.exports=o},function(t,e,n){function o(t,e){var n=a(t),o=!n&&r(t),s=!n&&!o&&u(t),d=!n&&!o&&!s&&l(t),p=n||o||s||d,h=p?i(t.length,String):[],v=h.length;for(var g in t)!e&&!f.call(t,g)||p&&("length"==g||s&&("offset"==g||"parent"==g)||d&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||c(g,v))||h.push(g);return h}var i=n(45),r=n(46),a=n(49),u=n(50),c=n(42),l=n(53),s=Object.prototype,f=s.hasOwnProperty;t.exports=o},function(t,e){function n(t,e){for(var n=-1,o=Array(t);++n<t;)o[n]=e(n);return o}t.exports=n},function(t,e,n){var o=n(47),i=n(48),r=Object.prototype,a=r.hasOwnProperty,u=r.propertyIsEnumerable,c=o(function(){return arguments}())?o:function(t){return i(t)&&a.call(t,"callee")&&!u.call(t,"callee")};t.exports=c},function(t,e,n){function o(t){return r(t)&&i(t)==a}var i=n(18),r=n(48),a="[object Arguments]";t.exports=o},function(t,e){function n(t){return null!=t&&"object"==typeof t}t.exports=n},function(t,e){var n=Array.isArray;t.exports=n},function(t,e,n){(function(t){var o=n(20),i=n(52),r="object"==typeof e&&e&&!e.nodeType&&e,a=r&&"object"==typeof t&&t&&!t.nodeType&&t,u=a&&a.exports===r,c=u?o.Buffer:void 0,l=c?c.isBuffer:void 0,s=l||i;t.exports=s}).call(e,n(51)(t))},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children=[],t.webpackPolyfill=1),t}},function(t,e){function n(){return!1}t.exports=n},function(t,e,n){var o=n(54),i=n(55),r=n(56),a=r&&r.isTypedArray,u=a?i(a):o;t.exports=u},function(t,e,n){function o(t){return a(t)&&r(t.length)&&!!T[i(t)]}var i=n(18),r=n(41),a=n(48),u="[object Arguments]",c="[object Array]",l="[object Boolean]",s="[object Date]",f="[object Error]",d="[object Function]",p="[object Map]",h="[object Number]",v="[object Object]",g="[object RegExp]",m="[object Set]",y="[object String]",b="[object WeakMap]",w="[object ArrayBuffer]",x="[object DataView]",_="[object Float32Array]",j="[object Float64Array]",k="[object Int8Array]",O="[object Int16Array]",E="[object Int32Array]",M="[object Uint8Array]",C="[object Uint8ClampedArray]",P="[object Uint16Array]",H="[object Uint32Array]",T={};T[_]=T[j]=T[k]=T[O]=T[E]=T[M]=T[C]=T[P]=T[H]=!0,T[u]=T[c]=T[w]=T[l]=T[x]=T[s]=T[f]=T[d]=T[p]=T[h]=T[v]=T[g]=T[m]=T[y]=T[b]=!1,t.exports=o},function(t,e){function n(t){return function(e){return t(e)}}t.exports=n},function(t,e,n){(function(t){var o=n(21),i="object"==typeof e&&e&&!e.nodeType&&e,r=i&&"object"==typeof t&&t&&!t.nodeType&&t,a=r&&r.exports===i,u=a&&o.process,c=function(){try{return u&&u.binding&&u.binding("util")}catch(t){}}();t.exports=c}).call(e,n(51)(t))},function(t,e,n){function o(t){if(!i(t))return a(t);var e=r(t),n=[];for(var o in t)("constructor"!=o||!e&&c.call(t,o))&&n.push(o);return n}var i=n(24),r=n(58),a=n(59),u=Object.prototype,c=u.hasOwnProperty;t.exports=o},function(t,e){function n(t){var e=t&&t.constructor,n="function"==typeof e&&e.prototype||o;return t===n}var o=Object.prototype;t.exports=n},function(t,e){function n(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}t.exports=n},function(t,e,n){var o=n(34),i=n(31),r=n(61),a=i(function(t,e){try{return o(t,void 0,e)}catch(t){return r(t)?t:new Error(t)}});t.exports=a},function(t,e,n){function o(t){if(!r(t))return!1;var e=i(t);return e==c||e==u||"string"==typeof t.message&&"string"==typeof t.name&&!a(t)}var i=n(18),r=n(48),a=n(62),u="[object DOMException]",c="[object Error]";t.exports=o},function(t,e,n){function o(t){if(!a(t)||i(t)!=u)return!1;var e=r(t);if(null===e)return!0;var n=f.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&s.call(n)==d}var i=n(18),r=n(63),a=n(48),u="[object Object]",c=Function.prototype,l=Object.prototype,s=c.toString,f=l.hasOwnProperty,d=s.call(Object);t.exports=o},function(t,e,n){var o=n(64),i=o(Object.getPrototypeOf,Object);t.exports=i},function(t,e){function n(t,e){return function(n){return t(e(n))}}t.exports=n},function(t,e,n){function o(t,e){return i(e,function(e){return t[e]})}var i=n(66);t.exports=o},function(t,e){function n(t,e){for(var n=-1,o=null==t?0:t.length,i=Array(o);++n<o;)i[n]=e(t[n],n,t);return i}t.exports=n},function(t,e,n){function o(t,e,n,o){return void 0===t||i(t,r[n])&&!a.call(o,n)?e:t}var i=n(29),r=Object.prototype,a=r.hasOwnProperty;t.exports=o},function(t,e){function n(t){return"\\"+o[t]}var o={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};t.exports=n},function(t,e,n){function o(t){return a(t)?i(t):r(t)}var i=n(44),r=n(70),a=n(40);t.exports=o},function(t,e,n){function o(t){if(!i(t))return r(t);var e=[];for(var n in Object(t))u.call(t,n)&&"constructor"!=n&&e.push(n);return e}var i=n(58),r=n(71),a=Object.prototype,u=a.hasOwnProperty;t.exports=o},function(t,e,n){var o=n(64),i=o(Object.keys,Object);t.exports=i},function(t,e){var n=/<%=([\s\S]+?)%>/g;t.exports=n},function(t,e,n){var o=n(74),i=n(80),r=n(81),a=n(72),u={escape:i,evaluate:r,interpolate:a,variable:"",imports:{_:{escape:o}}};t.exports=u},function(t,e,n){function o(t){return t=r(t),t&&u.test(t)?t.replace(a,i):t}var i=n(75),r=n(77),a=/[&<>"']/g,u=RegExp(a.source);t.exports=o},function(t,e,n){var o=n(76),i={"&":"&","<":"<",">":">",'"':""","'":"'"},r=o(i);t.exports=r},function(t,e){function n(t){return function(e){return null==t?void 0:t[e]}}t.exports=n},function(t,e,n){function o(t){return null==t?"":i(t)}var i=n(78);t.exports=o},function(t,e,n){function o(t){if("string"==typeof t)return t;if(a(t))return r(t,o)+"";if(u(t))return s?s.call(t):"";var e=t+"";return"0"==e&&1/t==-c?"-0":e}var i=n(19),r=n(66),a=n(49),u=n(79),c=1/0,l=i?i.prototype:void 0,s=l?l.toString:void 0;t.exports=o},function(t,e,n){function o(t){return"symbol"==typeof t||r(t)&&i(t)==a}var i=n(18),r=n(48),a="[object Symbol]";t.exports=o},function(t,e){var n=/<%-([\s\S]+?)%>/g;t.exports=n},function(t,e){var n=/<%([\s\S]+?)%>/g;t.exports=n},function(t,e,n){t.exports=n(83)},function(t,e,n){var o=n(11),i=n(30),r=n(43),a=i(function(t,e){o(e,r(e),t)});t.exports=a},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={closeIconClass:"iconfont icon-shanchu5",boundary:function(t){var e=t.offsetWidth,n=t.offsetHeight;return{getLeft:function(t){var n=document.documentElement.clientWidth;return t<e/2?e/2:t>n-e/2?n-e/2:t},getTop:function(t){var e=document.documentElement.clientHeight;return t<n/2?n/2:t>e-n/2?e-n/2:t}}}}},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={addCssText:function(t,e){Array.isArray(t)?t.forEach(function(t){t.style.cssText=e}):t.style.cssText=e},getCss:function(t,e){return t.currentStyle?t.currentStyle[e]:document.defaultView.getComputedStyle(t,!1)[e]},addClass:function(t,e){t.classList.add(e)},removeClass:function(t,e){t.classList.remove(e)},isHide:function(t){return"none"===this.getCss(t,"display")},show:function(t){t.style.display="block"},hide:function(t){t.style.display="none"},getRect:function(t){return t.getBoundingClientRect()},getPoint:function(t){for(var e=t.offsetTop,n=t.offsetLeft;t=t.offsetParent;)e+=t.offsetTop,n+=t.offsetLeft;return{top:e,left:n}},getDataAttr:function(t,e){return t.getAttribute("data-"+e)},html:function(t,e){t.innerHTML=e},getHtml:function(t){return t.innerHTML},has:function(){var t=void 0,e=void 0;1===arguments.length?(t=document,e=arguments.length<=0?void 0:arguments[0]):(t=arguments.length<=0?void 0:arguments[0],e=arguments.length<=1?void 0:arguments[1]);var n=t.querySelectorAll(e);return{length:n.length}},find:function(){var t=void 0,e=void 0;return 1===arguments.length?(t=document,e=arguments.length<=0?void 0:arguments[0]):(t=arguments.length<=0?void 0:arguments[0],e=arguments.length<=1?void 0:arguments[1]),t.querySelector(e)},findById:function(t){return document.getElementById(t)},findAll:function(){var t=void 0,e=void 0;return 1===arguments.length?(t=document,e=arguments.length<=0?void 0:arguments[0]):(t=arguments.length<=0?void 0:arguments[0],e=arguments.length<=1?void 0:arguments[1]),t.querySelectorAll(e)},appendHTML:function(t,e){var n=document.createElement("div"),o=null;return this.html(n,e),o=n.childNodes[0],t.appendChild(o),o},prependHTML:function(t,e){var n=document.createElement("div"),o=null;return this.html(n,e),o=n.childNodes[0],t.insertBefore(o,t.firstChild),o},beforeHTML:function(t,e){var n=document.createElement("div"),o=null;return this.html(n,e),o=n.childNodes[0],t.parentNode.insertBefore(o,t),o},remove:function(t){return t.parentNode&&t.parentNode.removeChild(t),t}}},function(t,e){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i=function(){function t(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}return function(e,n,o){return n&&t(e.prototype,n),o&&t(e,o),e}}(),r=function(){function t(){n(this,t)}return i(t,[{key:"$on",value:function(t,e){var n=void 0;if("object"===("undefined"==typeof t?"undefined":o(t)))for(n in t)({}).hasOwnProperty.call(t,n)&&this.$on(n,t[n]);else{var i=this,r=i._handles||(i._handles={}),a=r[t]||(r[t]=[]);a.push(e)}return this}},{key:"$off",value:function(t,e){var n=this,o=n._handles,i=void 0;if(!n._handles)return n;if(t||(this._handles={}),i=o[t]){if(!e)return o[t]=[],n;for(var r=0,a=i.length;r<a;r++)if(e===i[r])return i.splice(r,1),n}return n}},{key:"$emit",value:function(t){var e=this,n=e._handles,o=t,i=void 0,r=void 0,a=void 0,u=void 0;if(t){if(!n)return e;for(var c=arguments.length,l=Array(c>1?c-1:0),s=1;s<c;s++)l[s-1]=arguments[s];if(i=n[o.slice(1)])for(u=0,r=i.length;u<r;u++)i[u].apply(e,l);if(i=n[o]){for(a=0,r=i.length;a<r;a++)i[a].apply(e,l);return e}}}}]),t}();e.default=r},function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var i=n(85),r=o(i),a=r.default.getCss,u={left:0,top:0,currentX:0,currentY:0,flag:!1};e.default={startDrag:function(t,e,n,o){"auto"!==a(e,"left")&&(u.left=a(e,"left")),"auto"!==a(e,"top")&&(u.top=a(e,"top")),t.onmousedown=function(i){o&&o.$emit("dragStart"),u.flag=!0,i||(i=window.event,t.onselectstart=function(){return!1}),u.currentX=i.clientX,u.currentY=i.clientY,document.onmouseup=function(){u.flag=!1,"auto"!==a(e,"left")&&(u.left=a(e,"left")),"auto"!==a(e,"top")&&(u.top=a(e,"top")),o&&o.$emit("dragEnd"),document.onmousemove=null,document.onmouseup=null},document.onmousemove=function(t){if(u.flag){var o=t.clientX,i=t.clientY,r=o-u.currentX,a=i-u.currentY,c=parseInt(u.left,10)+r,l=parseInt(u.top,10)+a;n&&(c=n.getLeft(c),l=n.getTop(l)),e.style.left=c+"px",e.style.top=l+"px"}}}}}},function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function i(t,e,n,o,i){"undefined"==typeof n&&(n=400,o="linear"),"string"==typeof n?("function"==typeof o&&(i=o),o=n,n=400):"function"==typeof n?(i=n,n=400,o="linear"):"number"==typeof n&&("function"==typeof o?(i=o,o="linear"):"undefined"==typeof o&&(o="linear"));var r={},a=c.default.now(),u=void 0;for(u in e)({}).hasOwnProperty.call(e,u)&&(r[u]=0,"opacity"===u?r[u]=Math.round(100*l(t,u)):r[u]=parseInt(l(t,u),10));clearInterval(t.timer),t.timer=setInterval(function(){var l=c.default.now(),f=n-Math.max(0,a-l+n),d=void 0;for(u in e)({}).hasOwnProperty.call(e,u)&&(d=s[o](f,r[u],e[u]-r[u],n),"opacity"===u?(t.style.opacity=d/100,t.style.filter="alpha(opacity="+d+")"):t.style[u]=d+"px");f===n&&(clearInterval(t.timer),i&&i.call(t))},13)}Object.defineProperty(e,"__esModule",{value:!0});var r=n(85),a=o(r),u=n(8),c=o(u),l=a.default.getCss,s={linear:function(t,e,n,o){return n*t/o+e},easeIn:function(t,e,n,o){return n*(t/=o)*t+e},easeOut:function(t,e,n,o){return-n*(t/=o)*(t-2)+e},easeBoth:function(t,e,n,o){return(t/=o/2)<1?n/2*t*t+e:-n/2*(--t*(t-2)-1)+e},easeInStrong:function(t,e,n,o){return n*(t/=o)*t*t*t+e},easeOutStrong:function(t,e,n,o){return-n*((t=t/o-1)*t*t*t-1)+e},easeBothStrong:function(t,e,n,o){return(t/=o/2)<1?n/2*t*t*t*t+e:-n/2*((t-=2)*t*t*t-2)+e},elasticIn:function(t,e,n,o,i,r){var a=void 0;return 0===t?e:1===(t/=o)?e+n:(r||(r=.3*o),!i||i<Math.abs(n)?(i=n,a=r/4):a=r/(2*Math.PI)*Math.asin(n/i),-(i*Math.pow(2,10*(t-=1))*Math.sin((t*o-a)*(2*Math.PI)/r))+e)},elasticOut:function(t,e,n,o,i,r){var a=void 0;return 0===t?e:1===(t/=o)?e+n:(r||(r=.3*o),!i||i<Math.abs(n)?(i=n,a=r/4):a=r/(2*Math.PI)*Math.asin(n/i),i*Math.pow(2,-10*t)*Math.sin((t*o-a)*(2*Math.PI)/r)+n+e)},elasticBoth:function(t,e,n,o,i,r){var a=void 0;return 0===t?e:2===(t/=o/2)?e+n:(r||(r=o*(.3*1.5)),!i||i<Math.abs(n)?(i=n,a=r/4):a=r/(2*Math.PI)*Math.asin(n/i),t<1?-.5*(i*Math.pow(2,10*(t-=1))*Math.sin((t*o-a)*(2*Math.PI)/r))+e:i*Math.pow(2,-10*(t-=1))*Math.sin((t*o-a)*(2*Math.PI)/r)*.5+n+e)},backIn:function(t,e,n,o,i){return"undefined"==typeof i&&(i=1.70158),n*(t/=o)*t*((i+1)*t-i)+e},backOut:function(t,e,n,o,i){return"undefined"==typeof i&&(i=3.70158),n*((t=t/o-1)*t*((i+1)*t+i)+1)+e},backBoth:function(t,e,n,o,i){return"undefined"==typeof i&&(i=1.70158),(t/=o/2)<1?n/2*(t*t*(((i*=1.525)+1)*t-i))+e:n/2*((t-=2)*t*(((i*=1.525)+1)*t+i)+2)+e},bounceIn:function(t,e,n,o){return n-this.bounceOut(o-t,0,n,o)+e},bounceOut:function(t,e,n,o){return(t/=o)<1/2.75?n*(7.5625*t*t)+e:t<2/2.75?n*(7.5625*(t-=1.5/2.75)*t+.75)+e:t<2.5/2.75?n*(7.5625*(t-=2.25/2.75)*t+.9375)+e:n*(7.5625*(t-=2.625/2.75)*t+.984375)+e},bounceBoth:function(t,e,n,o){return t<o/2?.5*this.bounceIn(2*t,0,n,o)+e:.5*this.bounceOut(2*t-o,0,n,o)+.5*n+e}};e.default={startMove:i}},function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function i(t){t.preventDefault()}function r(t){f[t.keyCode]&&i(t)}function a(){var t=void 0,e=void 0,n=document.documentElement;return t=n.clientWidth,s.default.addClass(n,"dui-dialog-lock-test"),e=n.clientWidth,s.default.removeClass(n,"dui-dialog-lock-test"),e-t}function u(){var t=a();d=window.onwheel,window.onwheel=i,p=window.ontouchmove,window.ontouchmove=i,h=document.onkeydown,document.onkeydown=r,v=!0,s.default.addCssText([document.body,document.documentElement],"overflow-y: hidden; padding-right: "+t+"px")}function c(){v&&(window.onwheel=d,window.ontouchmove=p,document.onkeydown=h,v=!1,s.default.addCssText([document.body,document.documentElement],"overflow-y: visible; padding-right: 0;"))}Object.defineProperty(e,"__esModule",{value:!0});var l=n(85),s=o(l),f={37:1,38:1,39:1,40:1},d=void 0,p=void 0,h=void 0,v=void 0;e.default={disableScroll:u,enableScroll:c}},function(t,e){t.exports='<%if(height != "auto"){ %><div class="dui-dialog <%= className %>" style="display:none;width: <%= width %>px;height: <%= height %>px;z-index: <%= zIndex %>"> <% }else { %><div class="dui-dialog <%= className %>" style="display:none;width: <%= width %>px;height: <%= height %>;z-index: <%= zIndex %>"> <% } %> <% if(close) { %> <i class="dui-dialog-close J_dialog-close <%=closeClass %>" href=javascript:;></i> <% } %> <% if(title != "" && type == "default") { %> <div class=dui-dialog-hd> <% if(titleIconClass == "") { %> <h3 class=dui-dialog-title><%= title %></h3> <% }else { %> <h3 class="dui-dialog-title has-icon"><i class="<%= titleIconClass %>"></i><%= title %></h3> <% } %> </div> <% } %> <% if(title == "" && type == "default") { %> <div style=height:14px></div> <% } %> <% if(type == "custom") { %> <div class=dui-dialog-custom-bd><%= content %></div> <% } %> <% if(type == "default") { %> <% if(contentHeight != "auto"){ %> <div style="height: <%= contentHeight %>px" class=dui-dialog-bd> <% }else { %> <div style="height: <%= contentHeight %>;min-height: <%= contentMinHeight %>px;max-height: <%= contentMaxHeight %>px" class=dui-dialog-bd> <% } %> <%= content %> </div> <% if(ok || cancel) { %> <div class="dui-dialog-ft <%= btnPosClass %>"> <div class=dui-btn-list-g10> <% if(ok) { %> <a class="dui-btn-info J_dialog-ok" href=javascript:;><%= okValue %></a> <% } %> <% if(cancel) { %> <a class="dui-btn J_dialog-cancel" href=javascript:;><%= cancelValue %></a> <% } %> </div> </div> <% } %> <% } %> </div></div></div>'},function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var u=function(){function t(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}return function(e,n,o){return n&&t(e.prototype,n), | ||
o&&t(e,o),e}}();n(2),n(92);var c=n(8),l=o(c),s=n(94),f=o(s),d=n(85),p=o(d),h=n(86),v=o(h),g=n(88),m=o(g),y=n(95),b=o(y),w=n(96),x=o(w),_=n(97),j=o(_);e.default=function(){var t=function(t){function e(t){i(this,e);var n=r(this,(e.__proto__||Object.getPrototypeOf(e)).call(this)),o={tipContent:"这是一段提示"};return n.option=t,n.option=l.default.extend({},o,n.option),n.init(),n}return a(e,t),u(e,[{key:"init",value:function(){this.render(),this.option.init&&this.option.init.apply(this)}},{key:"render",value:function(){this.tipDom=p.default.appendHTML(document.body,this.option.tipContent)}},{key:"show",value:function(){p.default.show(this.tipDom)}},{key:"hide",value:function(){p.default.hide(this.tipDom)}},{key:"destroy",value:function(t){this.$emit("destroy"),t&&t(),p.default.remove(this.tipDom),this.tipDom=null}}]),e}(v.default);return t.showHint=function(e,n){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"top",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[3,5],r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:function(){};p.default.has(".dui-tip-hint").length>0&&p.default.remove(p.default.find(".dui-tip-hint")),"function"==typeof i&&(r=i,i=[3,5]),Array.isArray(i)||(i=[i,i]),2==i.length&&(i[2]=7);var a=void 0,u=void 0,c=void 0,s={tipClass:f.default.tipClassMap[e],marginTop:f.default.hint.marginTop,minWidth:f.default.hint.minWidth,maxWidth:f.default.hint.maxWidth,iconClass:f.default.hint.iconClass[e],hasClose:!1,msg:n};return u=f.default.hint.pos[o],"%"===String(u).slice(-1)&&(u=Math.floor(f.default.hint.pos.rel.clientHeight*(u.slice(0,-1)/100))),n.length<6&&(i=i[0]),n.length>5&&n.length<16&&(i=i[1]),n.length>15&&(s.hasClose=!0,i=i[2]),a=u-f.default.hint.pos.dis,s.top=a,c=l.default.renderTemp(b.default,s),new t({tipContent:c,init:function(){var t=this;p.default.show(this.tipDom),setTimeout(function(){m.default.startMove(t.tipDom,{top:u},function(){n.length>15&&!function(){var e=p.default.find(t.tipDom,".close-btn");e&&(e.onclick=function(){r&&r.apply(t),p.default.hide(t.tipDom),e.onclick=null,t.destroy()})}(),setTimeout(function(){t.tipDom&&m.default.startMove(t.tipDom,{top:a},function(){r&&r.apply(t),p.default.hide(t.tipDom),t.destroy()})},1e3*i)})},10)}})},t.successInfo=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("success",e,"top",n,o)},t.middleSuccessInfo=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("success",e,"middle",n,o)},t.warning=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("warn",e,"top",n,o)},t.middleWarning=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("warn",e,"middle",n,o)},t.otherInfo=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("other",e,"top",n,o)},t.middleOtherInfo=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("other",e,"middle",n,o)},t.info=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("info",e,"top",n,o)},t.middleInfo=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("info",e,"middle",n,o)},t.error=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("error",e,"top",n,o)},t.middleError=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("error",e,"middle",n,o)},t.showUpdateMessage=function(e){function n(t){var e=p.default.find(t,"button");e.onclick=function(){m.default.startMove(t,{opacity:0},400,function(){e.onclick=null,p.default.remove(t);var n=p.default.find(".dui-update-message");0===p.default.has(n,".dui-tip-text").length&&p.default.remove(n)})}}var o={msg:e},i=l.default.renderTemp(x.default,o);0===p.default.has(".dui-update-message").length?(i='<div style="top: '+f.default.updateMessage.top+'" class="dui-update-message">'+i+"</div>",new t({tipContent:i,init:function(){var t=p.default.find(this.tipDom,".dui-tip-text");m.default.startMove(t,{opacity:100},400,function(){n(t)})}})):!function(){var t=p.default.find(".dui-update-message"),e=p.default.prependHTML(t,i);m.default.startMove(e,{opacity:100},400,function(){n(e)})}()},t._showBasicArrow=function(e){if(!e.pos)return void console.error("必须传pos字段,来表明箭头的位置");if(!e.alignElem)return void console.error("必须传el,来决定Tip的显示位置");if(!e.msg)return void console.error("必须传msg");e.tipClass=f.default.tipArrowClassMap[e.pos],e.type=e.type||"default",e.tipType="error"===e.type?"dui-tip-error-arrow":"dui-tip-arrow";var n=l.default.renderTemp(j.default,e);return new t({tipContent:n,init:function(){var t=p.default.getRect(this.tipDom),n=p.default.getRect(e.alignElem),o=p.default.getPoint(e.alignElem),i="position: absolute";switch(e.pos){case"l":i+="; top: "+o.top+"px",i+="; left: "+(o.left-t.width-f.default.arrowSize-e.spacing)+"px";break;case"r":i+="; top: "+o.top+"px",i+="; left: "+(o.left+n.width+f.default.arrowSize+e.spacing)+"px";break;case"t":i+="; top: "+(o.top-t.height-f.default.arrowSize-e.spacing)+"px",i+="; left: "+(o.left+n.width/2-t.width/2)+"px";break;case"b":i+="; top: "+(o.top+n.height+f.default.arrowSize+e.spacing)+"px",i+="; left: "+(n.left+n.width/2-t.width/2)+"px";break;case"bl":i+="; top: "+(o.top+n.height+f.default.arrowSize+e.spacing)+"px",i+="; left: "+o.left+"px";break;case"br":i+="; top: "+(o.top+n.height+f.default.arrowSize+e.spacing)+"px",i+="; left: "+(o.left+n.width-t.width)+"px"}i+="; display: none; opacity: 1",this.tipDom.style.cssText=i}})},t.tooltip=function(e){function n(){i&&i.show()}function o(){i&&i.hide()}var i=void 0,r="string"==typeof e.el?p.default.find(e.el):e.el;return i=t._showBasicArrow({msg:e.msg,pos:e.pos,alignElem:r,spacing:e.spacing||5}).$on("destroy",function(){r.removeEventListener("mouseover",n),r.removeEventListener("mouseout",o)}),r.addEventListener("mouseover",n),r.addEventListener("mouseout",o),i},t.poptip=function(e){function n(){c&&c.show()}function o(){u.timer=setTimeout(function(){c&&c.hide()},300)}function i(){clearTimeout(u.timer)}function r(){c&&c.hide()}var a=this,u=this,c=void 0,l="string"==typeof e.el?p.default.find(e.el):e.el,s=e.trigger?e.trigger:"hover";switch(c=t._showBasicArrow({msg:e.msg,pos:e.pos,alignElem:l,spacing:e.spacing||5}).$on("destroy",function(){switch(s){case"hover":l.removeEventListener("mouseover",n),l.removeEventListener("mouseout",o),a.tipDom.removeEventListener("mouseenter",i),a.tipDom.removeEventListener("mouseleave",r);break;case"click":l.removeEventListener("click",n)}}),s){case"hover":l.addEventListener("mouseover",n),l.addEventListener("mouseout",o),c.tipDom.addEventListener("mouseenter",i),c.tipDom.addEventListener("mouseleave",r);break;case"click":l.addEventListener("click",n)}return c},t.showFormError=function(e){if(!e.el)return void console.error("必须传入el");if(!e.msg)return void console.error("必须传msg");var n="string"==typeof e.el?p.default.find(e.el):e.el,o=t._showBasicArrow({type:"error",msg:e.msg,pos:e.pos,alignElem:n,spacing:e.spacing||0});return o},t}()},function(t,e){},,function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={hint:{marginTop:8,minWidth:250,maxWidth:362,iconClass:{warn:"iconfont icon-tanhao",info:"iconfont icon-jingshi",error:"iconfont icon-cuowu-20160921",success:"iconfont icon-zhengque1",other:"iconfont icon-tanhao"},pos:{rel:document.documentElement,top:"0",middle:"35%",dis:50}},tipClassMap:{success:"dui-tip-success",info:"dui-tip-info",warn:"dui-tip-warning",error:"dui-tip-error",other:"dui-tip"},updateMessage:{top:"2%"},arrowSize:5,tipArrowClassMap:{l:"dui-tip-right-arrow",r:"dui-tip-left-arrow",t:"dui-tip-bottom-arrow",b:"dui-tip-top-arrow",bl:"dui-tip-top-left-arrow",br:"dui-tip-top-right-arrow"}}},function(t,e){t.exports='<div class="dui-tip-hint <%= tipClass %>" style="margin-top: <%=marginTop %>px;top: <%=top %>px;min-width: <%=minWidth %>px;max-width: <%=maxWidth %>px"> <i class="<%= iconClass %>"></i> <p><%= msg %></p> <% if(hasClose) { %> <a class=close-btn>×</a> <% } %> </div>'},function(t,e){t.exports='<div class=dui-tip-text style=opacity:0> <p><%= msg %></p> <div class=close-box> <button class="dui-btn-warning-bordered dui-btn-special dui-btn-small">我知道了</button> </div> </div>'},function(t,e){t.exports='<div style=position:absolute;opacity:0 class="<%= tipType %> <%= tipClass %>"> <%= msg %> </div>'}])}); | ||
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.Dui=e():t.Dui=e()}(this,function(){return function(t){function e(o){if(n[o])return n[o].exports;var i=n[o]={exports:{},id:o,loaded:!1};return t[o].call(i.exports,i,i.exports,e),i.loaded=!0,i.exports}var n={};return e.m=t,e.c=n,e.p="/dist/",e(0)}([function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}var i=n(1),r=o(i),a=n(91),u=o(a);t.exports={Modal:r.default,Tip:u.default}},function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var u=function(){function t(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}return function(e,n,o){return n&&t(e.prototype,n),o&&t(e,o),e}}();n(2);var c=n(6),l=o(c),s=n(8),f=o(s),d=n(84),p=o(d),h=n(85),v=o(h),g=n(86),m=o(g),y=n(87),b=o(y),w=n(88),x=o(w),_=n(89),j=o(_),k=n(90),O=o(k);e.default=function(){Object.assign(p.default,l.default);var t=function(t){function e(t){i(this,e);var n=r(this,(e.__proto__||Object.getPrototypeOf(e)).call(this)),o={type:"default",showType:"normal",title:"提示",content:"内容",isSingle:!1,height:"auto",okValue:"确定",cancelValue:"取消",className:"",zIndex:9999,titleIconClass:"",closeClass:p.default.closeIconClass,mask:!0,close:!0,ok:!1,cancel:!1,btnPos:"right",draggable:!1,appendEl:document.body};return n.option=t,n.option=Object.assign({},o,n.option),n.init(),n}return a(e,t),u(e,[{key:"init",value:function(){this.handleOption(),this.render(),this.bindEvent(),this.handleDrag(),this.option.init&&this.option.init.apply(this)}},{key:"handleOption",value:function(){this.handleOptionWidth(),this.handleOptionHeight(),this.handleOptionButton(),this.handleOptionContentHeight(),this.handleOptionContent()}},{key:"handleOptionWidth",value:function(){var t=this.option.width;t=t?parseInt(t,10):p.default.minWidth,p.default.minWidth-t>=0&&(t=p.default.minWidth),p.default.maxWidth-t<0&&(t=p.default.maxWidth),this.option.width=t}},{key:"handleOptionHeight",value:function(){var t=this.option.height;"auto"!==t&&(t=t?parseInt(t,10):p.default.minHeight,p.default.minHeight-t>=0&&(t=p.default.minHeight),p.default.maxHeight-t<0&&(t=p.default.maxHeight),this.option.height=t)}},{key:"handleOptionContentHeight",value:function(){var t=this.option.height,e=p.default.padding,n=p.default.minHeight,o=p.default.maxHeight,i=void 0,r=p.default.hdHeight,a=p.default.ftHeight;if(this.option.ok||this.option.cancel?i=3*e:(i=2*e,a=0),""===this.option.title&&(r=14),"auto"===t){this.option.contentHeight="auto";var u=n-r-a-i,c=o-r-a-i;this.option.contentMaxHeight=c,this.option.contentMinHeight=u}else{var l=t-r-a-i;this.option.contentHeight=l}}},{key:"handleOptionButton",value:function(){var t=this.option.ok,e=this.option.cancel,n=void 0;null==t?this.option.ok=!1:(n="boolean"==typeof t,this.option.ok=!!t,this.option.okValue=n?this.option.okValue:t),null==e?this.option.cancel=!1:(n="boolean"==typeof e,this.option.cancel=!!e,this.option.cancelValue=n?this.option.cancelValue:e),this.option.okFn&&(this.option.ok=!0),this.option.cancelFn&&(this.option.cancel=!0),this.option.btnPosClass="dui-dialog-ft-"+this.option.btnPos}},{key:"handleOptionContent",value:function(){var t=this.option.content;if("#"===t.charAt(0)){var e=v.default.findById(t.slice(1));null!=e&&(this.option.content=v.default.getHtml(e),"script"!==e.tagName.toLowerCase()&&v.default.remove(e))}}},{key:"render",value:function(){this.option.isSingle&&v.default.find(".dui-dialog")&&v.default.remove(v.default.find(".dui-dialog"));var t=v.default.has(".dui-dialog-wrap").length,e=f.default.renderTemp(O.default,this.option);if(0===t&&this.option.mask){var n='<div class="dui-dialog-wrap" style="z-index: '+this.option.zIndex+'"></div>';v.default.appendHTML(document.body,n),j.default.disableScroll()}this.option.mask?this.dialogDom=v.default.appendHTML(v.default.find(".dui-dialog-wrap"),e):("string"==typeof this.option.appendEl&&(this.option.appendEl=v.default.find(this.option.appendEl)),this.dialogDom=v.default.appendHTML(this.option.appendEl,e)),this.show()}},{key:"show",value:function(){switch(this.option.showType){case"normal":v.default.show(this.dialogDom);break;case"fade":this.dialogDom.style.top="-50%",this.dialogDom.style.opacity=0,v.default.show(this.dialogDom),x.default.startMove(this.dialogDom,{top:document.documentElement.clientHeight/2,opacity:100},800)}}},{key:"hide",value:function(){this.destroy()}},{key:"destroy",value:function(){this.unBindEvent();var t=void 0;t=this.option.mask?v.default.has(v.default.find(".dui-dialog-wrap"),".dui-dialog").length:v.default.has(".dui-dialog").length,v.default.remove(this.dialogDom),1===t&&this.option.mask&&(v.default.remove(v.default.find(".dui-dialog-wrap")),j.default.enableScroll()),this.dialogDom=null}},{key:"_okFn",value:function(){this.$emit("ok"),this.option.okFn&&this.option.okFn.apply(this)}},{key:"_cancelFn",value:function(t){this.$emit("cancel"),this.option.cancelFn&&this.option.cancelFn.apply(this),this.$emit("destroy"),t.stopPropagation(),this.hide()}},{key:"_closeFn",value:function(t){this.$emit("close"),this.$emit("destroy"),t.stopPropagation(),this.hide()}},{key:"_escFn",value:function(t){27===t.keyCode&&(this.$emit("esc"),this.$emit("destroy"),t.stopPropagation(),this.hide())}},{key:"handleDrag",value:function(){if(this.option.draggable){var t=v.default.find(this.dialogDom,".dui-dialog-hd");v.default.addClass(t,"z-draggable"),b.default.startDrag(t,this.dialogDom,p.default.boundary(this.dialogDom,this.option.appendEl),this)}}},{key:"bindEvent",value:function(){var t=this.okBtn=v.default.find(this.dialogDom,".J_dialog-ok"),n=this.cancelBtn=v.default.find(this.dialogDom,".J_dialog-cancel"),o=this.closeBtn=v.default.find(this.dialogDom,".J_dialog-close"),i=this.dialogBd=v.default.find(this.dialogDom,".dui-dialog-bd")||v.default.find(this.dialogDom,".dui-dialog-custom-bd");t&&t.addEventListener("click",this.bindOkClick=this._okFn.bind(this),!1),n&&n.addEventListener("click",this.bindCancelClick=this._cancelFn.bind(this),!1),o&&o.addEventListener("click",this.bindCloseClick=this._closeFn.bind(this),!1),i&&i.addEventListener("mousewheel",e.stopPropagation,!1),i&&i.addEventListener("touchmove",e.stopPropagation,!1),document.addEventListener("keydown",this.bindEscClick=this._escFn.bind(this),!1)}},{key:"unBindEvent",value:function(){var t=this.okBtn,n=this.cancelBtn,o=this.closeBtn,i=this.dialogBd;t&&t.removeEventListener("click",this.bindOkClick,!1),n&&n.removeEventListener("click",this.bindCancelClick,!1),o&&o.removeEventListener("click",this.bindCloseClick,!1),i&&i.removeEventListener("mousewheel",e.stopPropagation,!1),i&&i.removeEventListener("touchmove",e.stopPropagation,!1),document.removeEventListener("keydown",this.bindEscClick,!1)}}],[{key:"stopPropagation",value:function(t){t.stopPropagation()}}]),e}(m.default);return t.alert=function(e){return new t({title:arguments.length>1&&void 0!==arguments[1]?arguments[1]:"提示",content:e,close:!(arguments.length>2&&void 0!==arguments[2])||arguments[2],height:"auto",okFn:function(){this.hide()}})},t.confirm=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"提示",o=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"right";return new Promise(function(r){new t({title:n,content:e,close:o,height:"auto",btnPos:i,okFn:function(){r(!0),this.hide()},cancelFn:function(){r(!1)}})})},t}()},function(t,e){},,,,function(t,e){t.exports={minWidth:"420",minHeight:"170",maxWidth:"920",maxHeight:"580",hdHeight:"45",ftHeight:"30",padding:"16"}},,function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var i=n(9),r=o(i),a=n(82),u=o(a);e.default={extend:u.default,renderTemp:function(t,e){return(0,r.default)(t)(e)},now:function(){return(new Date).getTime()}}},function(t,e,n){function o(t,e,n){var o=p.imports._.templateSettings||p;n&&s(t,e,n)&&(e=void 0),t=h(t),e=i({},e,o,u);var x,_,j=i({},e.imports,o.imports,u),k=f(j),O=a(j,k),E=0,M=e.interpolate||b,C="__p += '",P=RegExp((e.escape||b).source+"|"+M.source+"|"+(M===d?y:b).source+"|"+(e.evaluate||b).source+"|$","g"),H="sourceURL"in e?"//# sourceURL="+e.sourceURL+"\n":"";t.replace(P,function(e,n,o,i,r,a){return o||(o=i),C+=t.slice(E,a).replace(w,c),n&&(x=!0,C+="' +\n__e("+n+") +\n'"),r&&(_=!0,C+="';\n"+r+";\n__p += '"),o&&(C+="' +\n((__t = ("+o+")) == null ? '' : __t) +\n'"),E=a+e.length,e}),C+="';\n";var T=e.variable;T||(C="with (obj) {\n"+C+"\n}\n"),C=(_?C.replace(v,""):C).replace(g,"$1").replace(m,"$1;"),C="function("+(T||"obj")+") {\n"+(T?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(x?", __e = _.escape":"")+(_?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+C+"return __p\n}";var S=r(function(){return Function(k,H+"return "+C).apply(void 0,O)});if(S.source=C,l(S))throw S;return S}var i=n(10),r=n(60),a=n(65),u=n(67),c=n(68),l=n(61),s=n(39),f=n(69),d=n(72),p=n(73),h=n(77),v=/\b__p \+= '';/g,g=/\b(__p \+=) '' \+/g,m=/(__e\(.*?\)|\b__t\)) \+\n'';/g,y=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,b=/($^)/,w=/['\n\r\u2028\u2029\\]/g;t.exports=o},function(t,e,n){var o=n(11),i=n(30),r=n(43),a=i(function(t,e,n,i){o(e,r(e),t,i)});t.exports=a},function(t,e,n){function o(t,e,n,o){var a=!n;n||(n={});for(var u=-1,c=e.length;++u<c;){var l=e[u],s=o?o(n[l],t[l],l,n,t):void 0;void 0===s&&(s=t[l]),a?r(n,l,s):i(n,l,s)}return n}var i=n(12),r=n(13);t.exports=o},function(t,e,n){function o(t,e,n){var o=t[e];u.call(t,e)&&r(o,n)&&(void 0!==n||e in t)||i(t,e,n)}var i=n(13),r=n(29),a=Object.prototype,u=a.hasOwnProperty;t.exports=o},function(t,e,n){function o(t,e,n){"__proto__"==e&&i?i(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}var i=n(14);t.exports=o},function(t,e,n){var o=n(15),i=function(){try{var t=o(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=i},function(t,e,n){function o(t,e){var n=r(t,e);return i(n)?n:void 0}var i=n(16),r=n(28);t.exports=o},function(t,e,n){function o(t){return!(!a(t)||r(t))&&(i(t)?p:c).test(u(t))}var i=n(17),r=n(25),a=n(24),u=n(27),c=/^\[object .+?Constructor\]$/,l=Function.prototype,s=Object.prototype,f=l.toString,d=s.hasOwnProperty,p=RegExp("^"+f.call(d).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=o},function(t,e,n){function o(t){if(!r(t))return!1;var e=i(t);return e==u||e==c||e==a||e==l}var i=n(18),r=n(24),a="[object AsyncFunction]",u="[object Function]",c="[object GeneratorFunction]",l="[object Proxy]";t.exports=o},function(t,e,n){function o(t){return null==t?void 0===t?c:u:l&&l in Object(t)?r(t):a(t)}var i=n(19),r=n(22),a=n(23),u="[object Null]",c="[object Undefined]",l=i?i.toStringTag:void 0;t.exports=o},function(t,e,n){var o=n(20),i=o.Symbol;t.exports=i},function(t,e,n){var o=n(21),i="object"==typeof self&&self&&self.Object===Object&&self,r=o||i||Function("return this")();t.exports=r},function(t,e){(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.exports=n}).call(e,function(){return this}())},function(t,e,n){function o(t){var e=a.call(t,c),n=t[c];try{t[c]=void 0}catch(t){}var o=u.call(t);return e?t[c]=n:delete t[c],o}var i=n(19),r=Object.prototype,a=r.hasOwnProperty,u=r.toString,c=i?i.toStringTag:void 0;t.exports=o},function(t,e){function n(t){return i.call(t)}var o=Object.prototype,i=o.toString;t.exports=n},function(t,e){function n(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}t.exports=n},function(t,e,n){function o(t){return!!r&&r in t}var i=n(26),r=function(){var t=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();t.exports=o},function(t,e,n){var o=n(20),i=o["__core-js_shared__"];t.exports=i},function(t,e){function n(t){if(null!=t){try{return i.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var o=Function.prototype,i=o.toString;t.exports=n},function(t,e){function n(t,e){return null==t?void 0:t[e]}t.exports=n},function(t,e){function n(t,e){return t===e||t!==t&&e!==e}t.exports=n},function(t,e,n){function o(t){return i(function(e,n){var o=-1,i=n.length,a=i>1?n[i-1]:void 0,u=i>2?n[2]:void 0;for(a=t.length>3&&"function"==typeof a?(i--,a):void 0,u&&r(n[0],n[1],u)&&(a=i<3?void 0:a,i=1),e=Object(e);++o<i;){var c=n[o];c&&t(e,c,o,a)}return e})}var i=n(31),r=n(39);t.exports=o},function(t,e,n){function o(t,e){return a(r(t,e,i),t+"")}var i=n(32),r=n(33),a=n(35);t.exports=o},function(t,e){function n(t){return t}t.exports=n},function(t,e,n){function o(t,e,n){return e=r(void 0===e?t.length-1:e,0),function(){for(var o=arguments,a=-1,u=r(o.length-e,0),c=Array(u);++a<u;)c[a]=o[e+a];a=-1;for(var l=Array(e+1);++a<e;)l[a]=o[a];return l[e]=n(c),i(t,this,l)}}var i=n(34),r=Math.max;t.exports=o},function(t,e){function n(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}t.exports=n},function(t,e,n){var o=n(36),i=n(38),r=i(o);t.exports=r},function(t,e,n){var o=n(37),i=n(14),r=n(32),a=i?function(t,e){return i(t,"toString",{configurable:!0,enumerable:!1,value:o(e),writable:!0})}:r;t.exports=a},function(t,e){function n(t){return function(){return t}}t.exports=n},function(t,e){function n(t){var e=0,n=0;return function(){var a=r(),u=i-(a-n);if(n=a,u>0){if(++e>=o)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var o=800,i=16,r=Date.now;t.exports=n},function(t,e,n){function o(t,e,n){if(!u(n))return!1;var o=typeof e;return!!("number"==o?r(n)&&a(e,n.length):"string"==o&&e in n)&&i(n[e],t)}var i=n(29),r=n(40),a=n(42),u=n(24);t.exports=o},function(t,e,n){function o(t){return null!=t&&r(t.length)&&!i(t)}var i=n(17),r=n(41);t.exports=o},function(t,e){function n(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=o}var o=9007199254740991;t.exports=n},function(t,e){function n(t,e){return!!(e=null==e?o:e)&&("number"==typeof t||i.test(t))&&t>-1&&t%1==0&&t<e}var o=9007199254740991,i=/^(?:0|[1-9]\d*)$/;t.exports=n},function(t,e,n){function o(t){return a(t)?i(t,!0):r(t)}var i=n(44),r=n(57),a=n(40);t.exports=o},function(t,e,n){function o(t,e){var n=a(t),o=!n&&r(t),s=!n&&!o&&u(t),d=!n&&!o&&!s&&l(t),p=n||o||s||d,h=p?i(t.length,String):[],v=h.length;for(var g in t)!e&&!f.call(t,g)||p&&("length"==g||s&&("offset"==g||"parent"==g)||d&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||c(g,v))||h.push(g);return h}var i=n(45),r=n(46),a=n(49),u=n(50),c=n(42),l=n(53),s=Object.prototype,f=s.hasOwnProperty;t.exports=o},function(t,e){function n(t,e){for(var n=-1,o=Array(t);++n<t;)o[n]=e(n);return o}t.exports=n},function(t,e,n){var o=n(47),i=n(48),r=Object.prototype,a=r.hasOwnProperty,u=r.propertyIsEnumerable,c=o(function(){return arguments}())?o:function(t){return i(t)&&a.call(t,"callee")&&!u.call(t,"callee")};t.exports=c},function(t,e,n){function o(t){return r(t)&&i(t)==a}var i=n(18),r=n(48),a="[object Arguments]";t.exports=o},function(t,e){function n(t){return null!=t&&"object"==typeof t}t.exports=n},function(t,e){var n=Array.isArray;t.exports=n},function(t,e,n){(function(t){var o=n(20),i=n(52),r="object"==typeof e&&e&&!e.nodeType&&e,a=r&&"object"==typeof t&&t&&!t.nodeType&&t,u=a&&a.exports===r,c=u?o.Buffer:void 0,l=c?c.isBuffer:void 0,s=l||i;t.exports=s}).call(e,n(51)(t))},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children=[],t.webpackPolyfill=1),t}},function(t,e){function n(){return!1}t.exports=n},function(t,e,n){var o=n(54),i=n(55),r=n(56),a=r&&r.isTypedArray,u=a?i(a):o;t.exports=u},function(t,e,n){function o(t){return a(t)&&r(t.length)&&!!u[i(t)]}var i=n(18),r=n(41),a=n(48),u={};u["[object Float32Array]"]=u["[object Float64Array]"]=u["[object Int8Array]"]=u["[object Int16Array]"]=u["[object Int32Array]"]=u["[object Uint8Array]"]=u["[object Uint8ClampedArray]"]=u["[object Uint16Array]"]=u["[object Uint32Array]"]=!0,u["[object Arguments]"]=u["[object Array]"]=u["[object ArrayBuffer]"]=u["[object Boolean]"]=u["[object DataView]"]=u["[object Date]"]=u["[object Error]"]=u["[object Function]"]=u["[object Map]"]=u["[object Number]"]=u["[object Object]"]=u["[object RegExp]"]=u["[object Set]"]=u["[object String]"]=u["[object WeakMap]"]=!1,t.exports=o},function(t,e){function n(t){return function(e){return t(e)}}t.exports=n},function(t,e,n){(function(t){var o=n(21),i="object"==typeof e&&e&&!e.nodeType&&e,r=i&&"object"==typeof t&&t&&!t.nodeType&&t,a=r&&r.exports===i,u=a&&o.process,c=function(){try{return u&&u.binding&&u.binding("util")}catch(t){}}();t.exports=c}).call(e,n(51)(t))},function(t,e,n){function o(t){if(!i(t))return a(t);var e=r(t),n=[];for(var o in t)("constructor"!=o||!e&&c.call(t,o))&&n.push(o);return n}var i=n(24),r=n(58),a=n(59),u=Object.prototype,c=u.hasOwnProperty;t.exports=o},function(t,e){function n(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||o)}var o=Object.prototype;t.exports=n},function(t,e){function n(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}t.exports=n},function(t,e,n){var o=n(34),i=n(31),r=n(61),a=i(function(t,e){try{return o(t,void 0,e)}catch(t){return r(t)?t:new Error(t)}});t.exports=a},function(t,e,n){function o(t){if(!r(t))return!1;var e=i(t);return e==c||e==u||"string"==typeof t.message&&"string"==typeof t.name&&!a(t)}var i=n(18),r=n(48),a=n(62),u="[object DOMException]",c="[object Error]";t.exports=o},function(t,e,n){function o(t){if(!a(t)||i(t)!=u)return!1;var e=r(t);if(null===e)return!0;var n=f.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&s.call(n)==d}var i=n(18),r=n(63),a=n(48),u="[object Object]",c=Function.prototype,l=Object.prototype,s=c.toString,f=l.hasOwnProperty,d=s.call(Object);t.exports=o},function(t,e,n){var o=n(64),i=o(Object.getPrototypeOf,Object);t.exports=i},function(t,e){function n(t,e){return function(n){return t(e(n))}}t.exports=n},function(t,e,n){function o(t,e){return i(e,function(e){return t[e]})}var i=n(66);t.exports=o},function(t,e){function n(t,e){for(var n=-1,o=null==t?0:t.length,i=Array(o);++n<o;)i[n]=e(t[n],n,t);return i}t.exports=n},function(t,e,n){function o(t,e,n,o){return void 0===t||i(t,r[n])&&!a.call(o,n)?e:t}var i=n(29),r=Object.prototype,a=r.hasOwnProperty;t.exports=o},function(t,e){function n(t){return"\\"+o[t]}var o={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};t.exports=n},function(t,e,n){function o(t){return a(t)?i(t):r(t)}var i=n(44),r=n(70),a=n(40);t.exports=o},function(t,e,n){function o(t){if(!i(t))return r(t);var e=[];for(var n in Object(t))u.call(t,n)&&"constructor"!=n&&e.push(n);return e}var i=n(58),r=n(71),a=Object.prototype,u=a.hasOwnProperty;t.exports=o},function(t,e,n){var o=n(64),i=o(Object.keys,Object);t.exports=i},function(t,e){t.exports=/<%=([\s\S]+?)%>/g},function(t,e,n){var o=n(74),i=n(80),r=n(81),a=n(72),u={escape:i,evaluate:r,interpolate:a,variable:"",imports:{_:{escape:o}}};t.exports=u},function(t,e,n){function o(t){return t=r(t),t&&u.test(t)?t.replace(a,i):t}var i=n(75),r=n(77),a=/[&<>"']/g,u=RegExp(a.source);t.exports=o},function(t,e,n){var o=n(76),i={"&":"&","<":"<",">":">",'"':""","'":"'"},r=o(i);t.exports=r},function(t,e){function n(t){return function(e){return null==t?void 0:t[e]}}t.exports=n},function(t,e,n){function o(t){return null==t?"":i(t)}var i=n(78);t.exports=o},function(t,e,n){function o(t){if("string"==typeof t)return t;if(a(t))return r(t,o)+"";if(u(t))return s?s.call(t):"";var e=t+"";return"0"==e&&1/t==-c?"-0":e}var i=n(19),r=n(66),a=n(49),u=n(79),c=1/0,l=i?i.prototype:void 0,s=l?l.toString:void 0;t.exports=o},function(t,e,n){function o(t){return"symbol"==typeof t||r(t)&&i(t)==a}var i=n(18),r=n(48),a="[object Symbol]";t.exports=o},function(t,e){t.exports=/<%-([\s\S]+?)%>/g},function(t,e){t.exports=/<%([\s\S]+?)%>/g},function(t,e,n){t.exports=n(83)},function(t,e,n){var o=n(11),i=n(30),r=n(43),a=i(function(t,e){o(e,r(e),t)});t.exports=a},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={closeIconClass:"iconfont icon-shanchu5",boundary:function(t){var e=t.offsetWidth,n=t.offsetHeight;return{getLeft:function(t){var n=document.documentElement.clientWidth;return t<e/2?e/2:t>n-e/2?n-e/2:t},getTop:function(t){var e=document.documentElement.clientHeight;return t<n/2?n/2:t>e-n/2?e-n/2:t}}}}},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={addCssText:function(t,e){Array.isArray(t)?t.forEach(function(t){t.style.cssText=e}):t.style.cssText=e},getCss:function(t,e){return t.currentStyle?t.currentStyle[e]:document.defaultView.getComputedStyle(t,!1)[e]},addClass:function(t,e){t.classList.add(e)},removeClass:function(t,e){t.classList.remove(e)},isHide:function(t){return"none"===this.getCss(t,"display")},show:function(t){t.style.display="block"},hide:function(t){t.style.display="none"},getRect:function(t){return t.getBoundingClientRect()},getPoint:function(t){for(var e=t.offsetTop,n=t.offsetLeft;t=t.offsetParent;)e+=t.offsetTop,n+=t.offsetLeft;return{top:e,left:n}},getDataAttr:function(t,e){return t.getAttribute("data-"+e)},html:function(t,e){t.innerHTML=e},getHtml:function(t){return t.innerHTML},has:function(){var t=void 0,e=void 0;return 1===arguments.length?(t=document,e=arguments.length<=0?void 0:arguments[0]):(t=arguments.length<=0?void 0:arguments[0],e=arguments.length<=1?void 0:arguments[1]),{length:t.querySelectorAll(e).length}},find:function(){var t=void 0,e=void 0;return 1===arguments.length?(t=document,e=arguments.length<=0?void 0:arguments[0]):(t=arguments.length<=0?void 0:arguments[0],e=arguments.length<=1?void 0:arguments[1]),t.querySelector(e)},findById:function(t){return document.getElementById(t)},findAll:function(){var t=void 0,e=void 0;return 1===arguments.length?(t=document,e=arguments.length<=0?void 0:arguments[0]):(t=arguments.length<=0?void 0:arguments[0],e=arguments.length<=1?void 0:arguments[1]),t.querySelectorAll(e)},appendHTML:function(t,e){var n=document.createElement("div"),o=null;return this.html(n,e),o=n.childNodes[0],t.appendChild(o),o},prependHTML:function(t,e){var n=document.createElement("div"),o=null;return this.html(n,e),o=n.childNodes[0],t.insertBefore(o,t.firstChild),o},beforeHTML:function(t,e){var n=document.createElement("div"),o=null;return this.html(n,e),o=n.childNodes[0],t.parentNode.insertBefore(o,t),o},remove:function(t){return t.parentNode&&t.parentNode.removeChild(t),t}}},function(t,e){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i=function(){function t(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}return function(e,n,o){return n&&t(e.prototype,n),o&&t(e,o),e}}(),r=function(){function t(){n(this,t)}return i(t,[{key:"$on",value:function(t,e){var n=void 0;if("object"===(void 0===t?"undefined":o(t)))for(n in t)({}).hasOwnProperty.call(t,n)&&this.$on(n,t[n]);else{var i=this,r=i._handles||(i._handles={});(r[t]||(r[t]=[])).push(e)}return this}},{key:"$off",value:function(t,e){var n=this,o=n._handles,i=void 0;if(!n._handles)return n;if(t||(this._handles={}),i=o[t]){if(!e)return o[t]=[],n;for(var r=0,a=i.length;r<a;r++)if(e===i[r])return i.splice(r,1),n}return n}},{key:"$emit",value:function(t){var e=this,n=e._handles,o=t,i=void 0,r=void 0,a=void 0,u=void 0;if(t){if(!n)return e;for(var c=arguments.length,l=Array(c>1?c-1:0),s=1;s<c;s++)l[s-1]=arguments[s];if(i=n[o.slice(1)])for(u=0,r=i.length;u<r;u++)i[u].apply(e,l);if(i=n[o]){for(a=0,r=i.length;a<r;a++)i[a].apply(e,l);return e}}}}]),t}();e.default=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(85),i=function(t){return t&&t.__esModule?t:{default:t}}(o),r=i.default.getCss,a={left:0,top:0,currentX:0,currentY:0,flag:!1};e.default={startDrag:function(t,e,n,o){"auto"!==r(e,"left")&&(a.left=r(e,"left")),"auto"!==r(e,"top")&&(a.top=r(e,"top")),t.onmousedown=function(i){o&&o.$emit("dragStart"),a.flag=!0,i||(i=window.event,t.onselectstart=function(){return!1}),a.currentX=i.clientX,a.currentY=i.clientY,document.onmouseup=function(){a.flag=!1,"auto"!==r(e,"left")&&(a.left=r(e,"left")),"auto"!==r(e,"top")&&(a.top=r(e,"top")),o&&o.$emit("dragEnd"),document.onmousemove=null,document.onmouseup=null},document.onmousemove=function(t){if(a.flag){var o=t.clientX,i=t.clientY,r=o-a.currentX,u=i-a.currentY,c=parseInt(a.left,10)+r,l=parseInt(a.top,10)+u;n&&(c=n.getLeft(c),l=n.getTop(l)),e.style.left=c+"px",e.style.top=l+"px"}}}}}},function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function i(t,e,n,o,i){void 0===n&&(n=400,o="linear"),"string"==typeof n?("function"==typeof o&&(i=o),o=n,n=400):"function"==typeof n?(i=n,n=400,o="linear"):"number"==typeof n&&("function"==typeof o?(i=o,o="linear"):void 0===o&&(o="linear"));var r={},a=c.default.now(),u=void 0;for(u in e)({}).hasOwnProperty.call(e,u)&&(r[u]=0,r[u]="opacity"===u?Math.round(100*l(t,u)):parseInt(l(t,u),10));clearInterval(t.timer),t.timer=setInterval(function(){var l=c.default.now(),f=n-Math.max(0,a-l+n),d=void 0;for(u in e)({}).hasOwnProperty.call(e,u)&&(d=s[o](f,r[u],e[u]-r[u],n),"opacity"===u?(t.style.opacity=d/100,t.style.filter="alpha(opacity="+d+")"):t.style[u]=d+"px");f===n&&(clearInterval(t.timer),i&&i.call(t))},13)}Object.defineProperty(e,"__esModule",{value:!0});var r=n(85),a=o(r),u=n(8),c=o(u),l=a.default.getCss,s={linear:function(t,e,n,o){return n*t/o+e},easeIn:function(t,e,n,o){return n*(t/=o)*t+e},easeOut:function(t,e,n,o){return-n*(t/=o)*(t-2)+e},easeBoth:function(t,e,n,o){return(t/=o/2)<1?n/2*t*t+e:-n/2*(--t*(t-2)-1)+e},easeInStrong:function(t,e,n,o){return n*(t/=o)*t*t*t+e},easeOutStrong:function(t,e,n,o){return-n*((t=t/o-1)*t*t*t-1)+e},easeBothStrong:function(t,e,n,o){return(t/=o/2)<1?n/2*t*t*t*t+e:-n/2*((t-=2)*t*t*t-2)+e},elasticIn:function(t,e,n,o,i,r){var a=void 0;return 0===t?e:1==(t/=o)?e+n:(r||(r=.3*o),!i||i<Math.abs(n)?(i=n,a=r/4):a=r/(2*Math.PI)*Math.asin(n/i),-(i*Math.pow(2,10*(t-=1))*Math.sin((t*o-a)*(2*Math.PI)/r))+e)},elasticOut:function(t,e,n,o,i,r){var a=void 0;return 0===t?e:1==(t/=o)?e+n:(r||(r=.3*o),!i||i<Math.abs(n)?(i=n,a=r/4):a=r/(2*Math.PI)*Math.asin(n/i),i*Math.pow(2,-10*t)*Math.sin((t*o-a)*(2*Math.PI)/r)+n+e)},elasticBoth:function(t,e,n,o,i,r){var a=void 0;return 0===t?e:2==(t/=o/2)?e+n:(r||(r=o*(.3*1.5)),!i||i<Math.abs(n)?(i=n,a=r/4):a=r/(2*Math.PI)*Math.asin(n/i),t<1?-.5*(i*Math.pow(2,10*(t-=1))*Math.sin((t*o-a)*(2*Math.PI)/r))+e:i*Math.pow(2,-10*(t-=1))*Math.sin((t*o-a)*(2*Math.PI)/r)*.5+n+e)},backIn:function(t,e,n,o,i){return void 0===i&&(i=1.70158),n*(t/=o)*t*((i+1)*t-i)+e},backOut:function(t,e,n,o,i){return void 0===i&&(i=3.70158),n*((t=t/o-1)*t*((i+1)*t+i)+1)+e},backBoth:function(t,e,n,o,i){return void 0===i&&(i=1.70158),(t/=o/2)<1?n/2*(t*t*((1+(i*=1.525))*t-i))+e:n/2*((t-=2)*t*((1+(i*=1.525))*t+i)+2)+e},bounceIn:function(t,e,n,o){return n-this.bounceOut(o-t,0,n,o)+e},bounceOut:function(t,e,n,o){return(t/=o)<1/2.75?n*(7.5625*t*t)+e:t<2/2.75?n*(7.5625*(t-=1.5/2.75)*t+.75)+e:t<2.5/2.75?n*(7.5625*(t-=2.25/2.75)*t+.9375)+e:n*(7.5625*(t-=2.625/2.75)*t+.984375)+e},bounceBoth:function(t,e,n,o){return t<o/2?.5*this.bounceIn(2*t,0,n,o)+e:.5*this.bounceOut(2*t-o,0,n,o)+.5*n+e}};e.default={startMove:i}},function(t,e,n){"use strict";function o(t){t.preventDefault()}function i(t){s[t.keyCode]&&o(t)}function r(){var t=void 0,e=void 0,n=document.documentElement;return t=n.clientWidth,l.default.addClass(n,"dui-dialog-lock-test"),e=n.clientWidth,l.default.removeClass(n,"dui-dialog-lock-test"),e-t}function a(){var t=r();f=window.onwheel,window.onwheel=o,d=window.ontouchmove,window.ontouchmove=o,p=document.onkeydown,document.onkeydown=i,h=!0,l.default.addCssText([document.body,document.documentElement],"overflow-y: hidden; padding-right: "+t+"px")}function u(){h&&(window.onwheel=f,window.ontouchmove=d,document.onkeydown=p,h=!1,l.default.addCssText([document.body,document.documentElement],"overflow-y: visible; padding-right: 0;"))}Object.defineProperty(e,"__esModule",{value:!0});var c=n(85),l=function(t){return t&&t.__esModule?t:{default:t}}(c),s={37:1,38:1,39:1,40:1},f=void 0,d=void 0,p=void 0,h=void 0;e.default={disableScroll:a,enableScroll:u}},function(t,e){t.exports='<%if(height != "auto"){ %><div class="dui-dialog <%= className %>" style="display:none;width: <%= width %>px;height: <%= height %>px;z-index: <%= zIndex %>"> <% }else { %><div class="dui-dialog <%= className %>" style="display:none;width: <%= width %>px;height: <%= height %>;z-index: <%= zIndex %>"> <% } %> <% if(close) { %> <i class="dui-dialog-close J_dialog-close <%=closeClass %>" href=javascript:;></i> <% } %> <% if(title != "" && type == "default") { %> <div class=dui-dialog-hd> <% if(titleIconClass == "") { %> <h3 class=dui-dialog-title><%= title %></h3> <% }else { %> <h3 class="dui-dialog-title has-icon"><i class="<%= titleIconClass %>"></i><%= title %></h3> <% } %> </div> <% } %> <% if(title == "" && type == "default") { %> <div style=height:14px></div> <% } %> <% if(type == "custom") { %> <div class=dui-dialog-custom-bd><%= content %></div> <% } %> <% if(type == "default") { %> <% if(contentHeight != "auto"){ %> <div style="height: <%= contentHeight %>px" class=dui-dialog-bd> <% }else { %> <div style="height: <%= contentHeight %>;min-height: <%= contentMinHeight %>px;max-height: <%= contentMaxHeight %>px" class=dui-dialog-bd> <% } %> <%= content %> </div> <% if(ok || cancel) { %> <div class="dui-dialog-ft <%= btnPosClass %>"> <div class=dui-btn-list-g10> <% if(ok) { %> <a class="dui-btn-info J_dialog-ok" href=javascript:;><%= okValue %></a> <% } %> <% if(cancel) { %> <a class="dui-btn J_dialog-cancel" href=javascript:;><%= cancelValue %></a> <% } %> </div> </div> <% } %> <% } %> </div></div></div>'},function(t,e,n){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var u=function(){function t(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}return function(e,n,o){return n&&t(e.prototype,n),o&&t(e,o),e}}();n(2),n(92);var c=n(8),l=o(c),s=n(94),f=o(s),d=n(85),p=o(d),h=n(86),v=o(h),g=n(88),m=o(g),y=n(95),b=o(y),w=n(96),x=o(w),_=n(97),j=o(_);e.default=function(){var t=function(t){function e(t){i(this,e) | ||
;var n=r(this,(e.__proto__||Object.getPrototypeOf(e)).call(this)),o={tipContent:"这是一段提示"};return n.option=t,n.option=l.default.extend({},o,n.option),n.init(),n}return a(e,t),u(e,[{key:"init",value:function(){this.render(),this.option.init&&this.option.init.apply(this)}},{key:"render",value:function(){this.tipDom=p.default.appendHTML(document.body,this.option.tipContent)}},{key:"show",value:function(){p.default.show(this.tipDom)}},{key:"hide",value:function(){p.default.hide(this.tipDom)}},{key:"destroy",value:function(t){this.$emit("destroy"),t&&t(),p.default.remove(this.tipDom),this.tipDom=null}}]),e}(v.default);return t.showHint=function(e,n){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"top",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:3,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:function(){};p.default.has(".dui-tip-hint").length>0&&p.default.remove(p.default.find(".dui-tip-hint")),"function"==typeof i&&(r=i,i=[3,!1]),Array.isArray(i)||(i=[i,!1]);var a=i[0],u=void 0,c=void 0,s=void 0,d={tipClass:f.default.tipClassMap[e],marginTop:f.default.hint.marginTop,minWidth:f.default.hint.minWidth,maxWidth:f.default.hint.maxWidth,iconClass:f.default.hint.iconClass[e],hasClose:i[1],msg:n};return c=f.default.hint.pos[o],"%"===String(c).slice(-1)&&(c=Math.floor(f.default.hint.pos.rel.clientHeight*(c.slice(0,-1)/100))),u=c-f.default.hint.pos.dis,d.top=u,s=l.default.renderTemp(b.default,d),new t({tipContent:s,init:function(){var t=this;p.default.show(this.tipDom),setTimeout(function(){m.default.startMove(t.tipDom,{top:c},function(){if(d.hasClose){var e=p.default.find(t.tipDom,".close-btn");e.onclick=function(){r&&r.apply(t),p.default.hide(t.tipDom),e.onclick=null,t.destroy()}}setTimeout(function(){t.tipDom&&m.default.startMove(t.tipDom,{top:u},function(){r&&r.apply(t),p.default.hide(t.tipDom),t.destroy()})},1e3*a)})},10)}})},t.successInfo=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("success",e,"top",n,o)},t.middleSuccessInfo=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("success",e,"middle",n,o)},t.warning=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("warn",e,"top",n,o)},t.middleWarning=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("warn",e,"middle",n,o)},t.otherInfo=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("other",e,"top",n,o)},t.middleOtherInfo=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("other",e,"middle",n,o)},t.info=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("info",e,"top",n,o)},t.middleInfo=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("info",e,"middle",n,o)},t.error=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("error",e,"top",n,o)},t.middleError=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};t.showHint("error",e,"middle",n,o)},t.showUpdateMessage=function(e){function n(t){var e=p.default.find(t,"button");e.onclick=function(){m.default.startMove(t,{opacity:0},400,function(){e.onclick=null,p.default.remove(t);var n=p.default.find(".dui-update-message");0===p.default.has(n,".dui-tip-text").length&&p.default.remove(n)})}}var o={msg:e},i=l.default.renderTemp(x.default,o);if(0===p.default.has(".dui-update-message").length)i='<div style="top: '+f.default.updateMessage.top+'" class="dui-update-message">'+i+"</div>",new t({tipContent:i,init:function(){var t=p.default.find(this.tipDom,".dui-tip-text");m.default.startMove(t,{opacity:100},400,function(){n(t)})}});else{var r=p.default.find(".dui-update-message"),a=p.default.prependHTML(r,i);m.default.startMove(a,{opacity:100},400,function(){n(a)})}},t._showBasicArrow=function(e){return e.pos?e.alignElem?e.msg?(e.tipClass=f.default.tipArrowClassMap[e.pos],e.type=e.type||"default",e.tipType="error"===e.type?"dui-tip-error-arrow":"dui-tip-arrow",new t({tipContent:l.default.renderTemp(j.default,e),init:function(){var t=p.default.getRect(this.tipDom),n=p.default.getRect(e.alignElem),o=p.default.getPoint(e.alignElem),i="position: absolute";switch(e.pos){case"l":i+="; top: "+o.top+"px",i+="; left: "+(o.left-t.width-f.default.arrowSize-e.spacing)+"px";break;case"r":i+="; top: "+o.top+"px",i+="; left: "+(o.left+n.width+f.default.arrowSize+e.spacing)+"px";break;case"t":i+="; top: "+(o.top-t.height-f.default.arrowSize-e.spacing)+"px",i+="; left: "+(o.left+n.width/2-t.width/2)+"px";break;case"b":i+="; top: "+(o.top+n.height+f.default.arrowSize+e.spacing)+"px",i+="; left: "+(n.left+n.width/2-t.width/2)+"px";break;case"bl":i+="; top: "+(o.top+n.height+f.default.arrowSize+e.spacing)+"px",i+="; left: "+o.left+"px";break;case"br":i+="; top: "+(o.top+n.height+f.default.arrowSize+e.spacing)+"px",i+="; left: "+(o.left+n.width-t.width)+"px"}i+="; display: none; opacity: 1",this.tipDom.style.cssText=i}})):void console.error("必须传msg"):void console.error("必须传el,来决定Tip的显示位置"):void console.error("必须传pos字段,来表明箭头的位置")},t.tooltip=function(e){function n(){i&&i.show()}function o(){i&&i.hide()}var i=void 0,r="string"==typeof e.el?p.default.find(e.el):e.el;return i=t._showBasicArrow({msg:e.msg,pos:e.pos,alignElem:r,spacing:e.spacing||5}).$on("destroy",function(){r.removeEventListener("mouseover",n),r.removeEventListener("mouseout",o)}),r.addEventListener("mouseover",n),r.addEventListener("mouseout",o),i},t.poptip=function(e){function n(){c&&c.show()}function o(){u.timer=setTimeout(function(){c&&c.hide()},300)}function i(){clearTimeout(u.timer)}function r(){c&&c.hide()}var a=this,u=this,c=void 0,l="string"==typeof e.el?p.default.find(e.el):e.el,s=e.trigger?e.trigger:"hover";switch(c=t._showBasicArrow({msg:e.msg,pos:e.pos,alignElem:l,spacing:e.spacing||5}).$on("destroy",function(){switch(s){case"hover":l.removeEventListener("mouseover",n),l.removeEventListener("mouseout",o),a.tipDom.removeEventListener("mouseenter",i),a.tipDom.removeEventListener("mouseleave",r);break;case"click":l.removeEventListener("click",n)}}),s){case"hover":l.addEventListener("mouseover",n),l.addEventListener("mouseout",o),c.tipDom.addEventListener("mouseenter",i),c.tipDom.addEventListener("mouseleave",r);break;case"click":l.addEventListener("click",n)}return c},t.showFormError=function(e){if(!e.el)return void console.error("必须传入el");if(!e.msg)return void console.error("必须传msg");var n="string"==typeof e.el?p.default.find(e.el):e.el;return t._showBasicArrow({type:"error",msg:e.msg,pos:e.pos,alignElem:n,spacing:e.spacing||0})},t}()},function(t,e){},,function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={hint:{marginTop:8,minWidth:250,maxWidth:362,iconClass:{warn:"iconfont icon-tanhao",info:"iconfont icon-jingshi",error:"iconfont icon-cuowu-20160921",success:"iconfont icon-zhengque1",other:"iconfont icon-tanhao"},pos:{rel:document.documentElement,top:"0",middle:"35%",dis:50}},tipClassMap:{success:"dui-tip-success",info:"dui-tip-info",warn:"dui-tip-warning",error:"dui-tip-error",other:"dui-tip"},updateMessage:{top:"2%"},arrowSize:5,tipArrowClassMap:{l:"dui-tip-right-arrow",r:"dui-tip-left-arrow",t:"dui-tip-bottom-arrow",b:"dui-tip-top-arrow",bl:"dui-tip-top-left-arrow",br:"dui-tip-top-right-arrow"}}},function(t,e){t.exports='<div class="dui-tip-hint <%= tipClass %>" style="margin-top: <%=marginTop %>px;top: <%=top %>px;min-width: <%=minWidth %>px;max-width: <%=maxWidth %>px"> <i class="<%= iconClass %>"></i> <p><%= msg %></p> <% if(hasClose) { %> <a class=close-btn>×</a> <% } %> </div>'},function(t,e){t.exports='<div class=dui-tip-text style=opacity:0> <p><%= msg %></p> <div class=close-box> <button class="dui-btn-warning-bordered dui-btn-special dui-btn-small">我知道了</button> </div> </div>'},function(t,e){t.exports='<div style=position:absolute;opacity:0 class="<%= tipType %> <%= tipClass %>"> <%= msg %> </div>'}])}); |
@@ -81,3 +81,3 @@ ### 用途 | ||
| pos | string | top | 显示位置,可选值:top / middle | | ||
| time | int | 2 | 提示框显示的时间,单位:秒,默认2s后,动画消失 | | ||
| time | int/array | 3 | 当值为int时,表示提示框显示的时间,单位:秒,默认2s后,动画消失。当值为数组时,第一个为提示框显示的时间,第二个为提示框是否显示关闭按钮(boolean) | | ||
| callback | function | 无 | 提示框消失后的回调处理 | | ||
@@ -84,0 +84,0 @@ |
{ | ||
"name": "Dui", | ||
"version": "0.1.13", | ||
"version": "0.1.14", | ||
"description": "针对某部门的UI组件开发", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -62,3 +62,3 @@ // 引入css | ||
Tip.showHint = (type, msg, pos = "top", time = [3, 5], callback = () => {}) => { | ||
Tip.showHint = (type, msg, pos = "top", time = 3, callback = () => {}) => { | ||
// 先把之前的tip给干掉 | ||
@@ -71,14 +71,11 @@ if (DOM.has(".dui-tip-hint").length > 0) { | ||
callback = time; | ||
time = [3, 5]; // 默认 | ||
time = [3, false]; // 默认 | ||
} | ||
if(!Array.isArray(time)) { | ||
time = [time, time]; | ||
time = [time, false]; | ||
} | ||
if(time.length == 2) { | ||
time[2] = 7; | ||
} | ||
let initialTop, | ||
let t = time[0], | ||
initialTop, | ||
finalTop, | ||
@@ -93,3 +90,3 @@ tipContent; | ||
iconClass: Config.hint.iconClass[type], | ||
hasClose: false, | ||
hasClose: time[1], | ||
msg | ||
@@ -104,15 +101,2 @@ }; | ||
if(msg.length < 6) { | ||
time = time[0]; | ||
} | ||
if(msg.length >5 && msg.length < 16) { | ||
time = time[1]; | ||
} | ||
if (msg.length > 15) { | ||
option.hasClose = true; | ||
time = time[2]; | ||
} | ||
initialTop = finalTop - Config.hint.pos.dis; | ||
@@ -132,12 +116,11 @@ option.top = initialTop; | ||
Animate.startMove(_this.tipDom, { top: finalTop }, () => { | ||
// 如果大于10个字,不自动消失 | ||
if (msg.length > 15) { | ||
// 当存在close时,可以关闭 | ||
if (option.hasClose) { | ||
const close_btn = DOM.find(_this.tipDom, ".close-btn"); | ||
if(close_btn) | ||
close_btn.onclick = () => { | ||
callback && callback.apply(_this); | ||
DOM.hide(_this.tipDom); | ||
close_btn.onclick = null; | ||
_this.destroy(); | ||
} | ||
close_btn.onclick = () => { | ||
callback && callback.apply(_this); | ||
DOM.hide(_this.tipDom); | ||
close_btn.onclick = null; | ||
_this.destroy(); | ||
} | ||
} | ||
@@ -153,3 +136,3 @@ setTimeout(() => { | ||
}); | ||
}, time * 1000); | ||
}, t * 1000); | ||
}); | ||
@@ -156,0 +139,0 @@ }, 10); |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
1502766
22815