vue-adny
Version:
vue 兼容2 3 工具库 函数库
24 lines (21 loc) • 28.8 kB
JavaScript
var t,e=(t=new Date,function(e){return function(n){console.log(n,"["+t.getHours()+" : "+t.getMinutes()+" : "+t.getSeconds()+"] ["+e+"] ")}}),n=e("RESOURCES"),r=e("DEBUG"),i=e("FEATURE"),o=function(t){return"config"in t&&"globalProperties"in t.config},a={log:n,debugLog:r,featLog:i};"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;function u(t,e){return t(e={exports:{}},e.exports),e.exports}var s=u((function(t,e){t.exports=function(){var t=1e3,e=6e4,n=36e5,r="millisecond",i="second",o="minute",a="hour",u="day",s="week",c="month",l="quarter",f="year",d="date",h="Invalid Date",v=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,p=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,y={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_")},m=function(t,e,n){var r=String(t);return!r||r.length>=e?t:""+Array(e+1-r.length).join(n)+t},g={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?"+":"-")+m(r,2,"0")+":"+m(i,2,"0")},m:function t(e,n){if(e.date()<n.date())return-t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),i=e.clone().add(r,c),o=n-i<0,a=e.clone().add(r+(o?-1:1),c);return+(-(r+(n-i)/(o?i-a:a-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:c,y:f,w:s,d:u,D:d,h:a,m:o,s:i,ms:r,Q:l}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},b="en",$={};$[b]=y;var E=function(t){return t instanceof _},S=function(t,e,n){var r;if(!t)return b;if("string"==typeof t)$[t]&&(r=t),e&&($[t]=e,r=t);else{var i=t.name;$[i]=t,r=i}return!n&&r&&(b=r),r||!n&&b},w=function(t,e){if(E(t))return t.clone();var n="object"==typeof e?e:{};return n.date=t,n.args=arguments,new _(n)},k=g;k.l=S,k.i=E,k.w=function(t,e){return w(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var _=function(){function y(t){this.$L=S(t.locale,null,!0),this.parse(t)}var m=y.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(k.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match(v);if(r){var i=r[2]-1||0,o=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,o)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,o)}}return new Date(e)}(t),this.$x=t.x||{},this.init()},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},m.$utils=function(){return k},m.isValid=function(){return!(this.$d.toString()===h)},m.isSame=function(t,e){var n=w(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return w(t)<this.startOf(e)},m.isBefore=function(t,e){return this.endOf(e)<w(t)},m.$g=function(t,e,n){return k.u(t)?this[e]:this.set(n,t)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(t,e){var n=this,r=!!k.u(e)||e,l=k.p(t),h=function(t,e){var i=k.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return r?i:i.endOf(u)},v=function(t,e){return k.w(n.toDate()[t].apply(n.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},p=this.$W,y=this.$M,m=this.$D,g="set"+(this.$u?"UTC":"");switch(l){case f:return r?h(1,0):h(31,11);case c:return r?h(1,y):h(0,y+1);case s:var b=this.$locale().weekStart||0,$=(p<b?p+7:p)-b;return h(r?m-$:m+(6-$),y);case u:case d:return v(g+"Hours",0);case a:return v(g+"Minutes",1);case o:return v(g+"Seconds",2);case i:return v(g+"Milliseconds",3);default:return this.clone()}},m.endOf=function(t){return this.startOf(t,!1)},m.$set=function(t,e){var n,s=k.p(t),l="set"+(this.$u?"UTC":""),h=(n={},n[u]=l+"Date",n[d]=l+"Date",n[c]=l+"Month",n[f]=l+"FullYear",n[a]=l+"Hours",n[o]=l+"Minutes",n[i]=l+"Seconds",n[r]=l+"Milliseconds",n)[s],v=s===u?this.$D+(e-this.$W):e;if(s===c||s===f){var p=this.clone().set(d,1);p.$d[h](v),p.init(),this.$d=p.set(d,Math.min(this.$D,p.daysInMonth())).$d}else h&&this.$d[h](v);return this.init(),this},m.set=function(t,e){return this.clone().$set(t,e)},m.get=function(t){return this[k.p(t)]()},m.add=function(r,l){var d,h=this;r=Number(r);var v=k.p(l),p=function(t){var e=w(h);return k.w(e.date(e.date()+Math.round(t*r)),h)};if(v===c)return this.set(c,this.$M+r);if(v===f)return this.set(f,this.$y+r);if(v===u)return p(1);if(v===s)return p(7);var y=(d={},d[o]=e,d[a]=n,d[i]=t,d)[v]||1,m=this.$d.getTime()+r*y;return k.w(m,this)},m.subtract=function(t,e){return this.add(-1*t,e)},m.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return n.invalidDate||h;var r=t||"YYYY-MM-DDTHH:mm:ssZ",i=k.z(this),o=this.$H,a=this.$m,u=this.$M,s=n.weekdays,c=n.months,l=function(t,n,i,o){return t&&(t[n]||t(e,r))||i[n].substr(0,o)},f=function(t){return k.s(o%12||12,t,"0")},d=n.meridiem||function(t,e,n){var r=t<12?"AM":"PM";return n?r.toLowerCase():r},v={YY:String(this.$y).slice(-2),YYYY:this.$y,M:u+1,MM:k.s(u+1,2,"0"),MMM:l(n.monthsShort,u,c,3),MMMM:l(c,u),D:this.$D,DD:k.s(this.$D,2,"0"),d:String(this.$W),dd:l(n.weekdaysMin,this.$W,s,2),ddd:l(n.weekdaysShort,this.$W,s,3),dddd:s[this.$W],H:String(o),HH:k.s(o,2,"0"),h:f(1),hh:f(2),a:d(o,a,!0),A:d(o,a,!1),m:String(a),mm:k.s(a,2,"0"),s:String(this.$s),ss:k.s(this.$s,2,"0"),SSS:k.s(this.$ms,3,"0"),Z:i};return r.replace(p,(function(t,e){return e||v[t]||i.replace(":","")}))},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(r,d,h){var v,p=k.p(d),y=w(r),m=(y.utcOffset()-this.utcOffset())*e,g=this-y,b=k.m(this,y);return b=(v={},v[f]=b/12,v[c]=b,v[l]=b/3,v[s]=(g-m)/6048e5,v[u]=(g-m)/864e5,v[a]=g/n,v[o]=g/e,v[i]=g/t,v)[p]||g,h?b:k.a(b)},m.daysInMonth=function(){return this.endOf(c).$D},m.$locale=function(){return $[this.$L]},m.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=S(t,e,!0);return r&&(n.$L=r),n},m.clone=function(){return k.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},y}(),T=_.prototype;return w.prototype=T,[["$ms",r],["$s",i],["$m",o],["$H",a],["$W",u],["$M",c],["$y",f],["$D",d]].forEach((function(t){T[t[1]]=function(e){return this.$g(e,t[0],t[1])}})),w.extend=function(t,e){return t.$i||(t(e,_,w),t.$i=!0),w},w.locale=S,w.isDayjs=E,w.unix=function(t){return w(1e3*t)},w.en=$[b],w.Ls=$,w.p={},w}()})),c=u((function(t,e){var n,r,i;t.exports=(n="minute",r=/[+-]\d\d(?::?\d\d)?/g,i=/([+-]|\d\d)/g,function(t,e,o){var a=e.prototype;o.utc=function(t){return new e({date:t,utc:!0,args:arguments})},a.utc=function(t){var e=o(this.toDate(),{locale:this.$L,utc:!0});return t?e.add(this.utcOffset(),n):e},a.local=function(){return o(this.toDate(),{locale:this.$L,utc:!1})};var u=a.parse;a.parse=function(t){t.utc&&(this.$u=!0),this.$utils().u(t.$offset)||(this.$offset=t.$offset),u.call(this,t)};var s=a.init;a.init=function(){if(this.$u){var t=this.$d;this.$y=t.getUTCFullYear(),this.$M=t.getUTCMonth(),this.$D=t.getUTCDate(),this.$W=t.getUTCDay(),this.$H=t.getUTCHours(),this.$m=t.getUTCMinutes(),this.$s=t.getUTCSeconds(),this.$ms=t.getUTCMilliseconds()}else s.call(this)};var c=a.utcOffset;a.utcOffset=function(t,e){var o=this.$utils().u;if(o(t))return this.$u?0:o(this.$offset)?c.call(this):this.$offset;if("string"==typeof t&&null===(t=function(t){void 0===t&&(t="");var e=t.match(r);if(!e)return null;var n=(""+e[0]).match(i)||["-",0,0],o=n[0],a=60*+n[1]+ +n[2];return 0===a?0:"+"===o?a:-a}(t)))return this;var a=Math.abs(t)<=16?60*t:t,u=this;if(e)return u.$offset=a,u.$u=0===t,u;if(0!==t){var s=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(u=this.local().add(a+s,n)).$offset=a,u.$x.$localOffset=s}else u=this.utc();return u};var l=a.format;a.format=function(t){var e=t||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return l.call(this,e)},a.valueOf=function(){var t=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||(new Date).getTimezoneOffset());return this.$d.valueOf()-6e4*t},a.isUTC=function(){return!!this.$u},a.toISOString=function(){return this.toDate().toISOString()},a.toString=function(){return this.toDate().toUTCString()};var f=a.toDate;a.toDate=function(t){return"s"===t&&this.$offset?o(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():f.call(this)};var d=a.diff;a.diff=function(t,e,n){if(t&&this.$u===t.$u)return d.call(this,t,e,n);var r=this.local(),i=o(t).local();return d.call(r,i,e,n)}})}));s.extend(c);function l(t,e){return void 0===e&&(e="YYYY-MM-DD HH:mm:ss"),s.utc(t).utcOffset(8).format(e)}var f=function(t,e){var n=e||{},r=Object.prototype.toString;for(var i in t)t.hasOwnProperty(i)&&("object"==typeof t[i]&&null!==t[i]?(n[i]="[object Array]"===r.call(t[i])?[]:{},f(t[i],n[i])):n[i]=t[i]);return n};
/*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */
var d=function(){return d=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},d.apply(this,arguments)},h=function(t){return o(t)?{created:"created",mounted:"mounted",updated:"updated",unMounted:"unmounted"}:{created:"bind",mounted:"inserted",updated:"updated",unMounted:"unbind"}},v={directive:"debounce",event:"click",headExecution:!1,delay:1e3,callback:null},p=function(t){var e,n=h(t),r=d({},v);t.directive(r.directive,((e={})[n.mounted]=function(t,e){var n=e.value;!function(t,e,n,r,i){var o;void 0===t&&(t="click"),void 0===n&&(n=1e3),void 0===i&&(i=!1);var a=!1;e.addEventListener(t,(function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];o&&clearTimeout(o),i&&!a?(r.apply(void 0,t),a=!0):o=setTimeout((function(){!i&&r.apply(void 0,t),a=!1}),n)}))}(n.event,t,n.delay,n.callback,n.headExecution)},e))},y={install:function(t,e){p(t)}},m=function(t,e,n){e&&!n.includes(e)&&t.parentNode&&t.parentNode.removeChild(t)},g={directive:"permission"},b=function(t){var e,n=h(t),r=d({},g);t.directive(r.directive,((e={})[n.mounted]=function(t,e){var n=e.value;m(t,n.permission,n.systemPermission)},e[n.updated]=function(t,e){var n=e.value;m(t,n.permission,n.systemPermission)},e))},$={install:function(t,e){b(t)}},E=function(t,e){document.addEventListener("click",(function(n){!t.contains(n.target)&&e()}),!1)},S={directive:"clickoutside"},w=function(t){var e,n=h(t),r=d({},S);t.directive(r.directive,((e={})[n.mounted]=function(t,e){var n=e.value;E(t,n)},e[n.updated]=function(t,e){var n=e.value;E(t,n)},e))},k={install:function(t,e){w(t)}};function _(t,e,n,r){var i=t-n,o=e-r;return Math.sqrt(i*i+o*o)}function T(t,e){t.dataset.vRippleCountInternal=e.toString()}function M(t){var e;return parseInt(null!==(e=t.dataset.vRippleCountInternal)&&void 0!==e?e:"0",10)}var x,O=function(t,e,n){var r=e.getBoundingClientRect(),i=window.getComputedStyle(e),o=function(t,e){var n=t.x,r=t.y,i=e.top;return{x:n-e.left,y:r-i}}(t,r),a=o.x,u=o.y,s=2.05*function(t,e,n){var r=n.width,i=n.height,o=_(t,e,0,0),a=_(t,e,r,0),u=_(t,e,0,i),s=_(t,e,r,i);return Math.max(o,a,u,s)}(a,u,r),c=function(t){var e=t.borderTopLeftRadius,n=t.borderTopRightRadius,r=t.borderBottomLeftRadius,i=t.borderBottomRightRadius,o=document.createElement("div");return o.style.top="0",o.style.left="0",o.style.width="100%",o.style.height="100%",o.style.position="absolute",o.style.borderRadius=e+" "+n+" "+i+" "+r,o.style.overflow="hidden",o.style.pointerEvents="none",o.style.webkitMaskImage="-webkit-radial-gradient(white, black)",o}(i),l=function(t,e,n,r){var i=document.createElement("div");return i.style.position="absolute",i.style.width=n+"px",i.style.height=n+"px",i.style.top=e+"px",i.style.left=t+"px",i.style.background=r.color,i.style.borderRadius="50%",i.style.opacity=""+r.initialOpacity,i.style.transform="translate(-50%,-50%) scale(0)",i.style.transition="transform "+r.duration+"s "+r.easing+", opacity "+r.duration+"s "+r.easing,i}(a,u,s,n);!function(t){T(t,M(t)+1)}(e);var f="";"static"===i.position&&(e.style.position&&(f=e.style.position),e.style.position="relative"),c.appendChild(l),e.appendChild(c);var d=!1,h=function(t){void 0!==t&&(document.removeEventListener("pointerup",h),document.removeEventListener("pointercancel",h)),d?v():d=!0},v=function(){l.style.transition="opacity 150ms linear",l.style.opacity="0",setTimeout((function(){c.remove(),function(t){T(t,M(t)-1)}(e),0===M(e)&&(!function(t){delete t.dataset.vRippleCountInternal}(e),e.style.position=f)}),150)};document.addEventListener("pointerup",h),document.addEventListener("pointercancel",h);var p=setTimeout((function(){document.removeEventListener("pointercancel",y),requestAnimationFrame((function(){l.style.transform="translate(-50%,-50%) scale(1)",l.style.opacity=""+n.finalOpacity,setTimeout((function(){return h()}),1e3*n.duration)}))}),n.delayTime),y=function(){clearTimeout(p),c.remove(),document.removeEventListener("pointerup",h),document.removeEventListener("pointercancel",h),document.removeEventListener("pointercancel",y)};document.addEventListener("pointercancel",y)},C=new WeakMap,D=d({},{directive:"ripple",color:"currentColor",initialOpacity:.2,finalOpacity:.5,duration:.2,easing:"ease-in-out",delayTime:75,disabled:!1}),L=function(t){var e,n=h(t);t.directive("ripple",((e={})[n.mounted]=function(t,e){var n;C.set(t,null!==(n=e.value)&&void 0!==n?n:{}),t.addEventListener("pointerdown",(function(n){var r,i=C.get(t);(null===(r=e.value)||void 0===r?void 0:r.disabled)||!1!==i&&O(n,t,d(d({},D),i))}))},e.updated=function(t,e){var n;C.set(t,null!==(n=e.value)&&void 0!==n?n:{})},e))},A={install:function(t,e){L(t)}},H=function(t){var e,n=h(t);t.directive("format-time",((e={})[n.created]=function(t,e){!function(t,e){e.formatString="YYYY-MM-DD HH:mm:ss",e.value&&(e.formatString=e.value)}(0,e)},e[n.mounted]=function(t,e){!function(t,e){var n=t.textContent,r=parseInt(n);10===n.length&&(r*=1e3),t.textContent=s(r).format(e.formatString)}(t,e)},e[n.updated]=function(t,e){console.log("时间数据发生动态改变~")},e))},Y={install:function(t,e){H(t)}},R=u((function(t,e){
/*!
* clipboard.js v2.0.8
* https://clipboardjs.com/
*
* Licensed MIT © Zeno Rocha
*/
var n;n=function(){return function(){var t={134:function(t,e,n){n.d(e,{default:function(){return E}});var r=n(279),i=n.n(r),o=n(370),a=n.n(o),u=n(817),s=n.n(u);function c(t){return c="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},c(t)}function l(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}var f=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.resolveOptions(e),this.initSelection()}var e,n,r;return e=t,n=[{key:"resolveOptions",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.action=t.action,this.container=t.container,this.emitter=t.emitter,this.target=t.target,this.text=t.text,this.trigger=t.trigger,this.selectedText=""}},{key:"initSelection",value:function(){this.text?this.selectFake():this.target&&this.selectTarget()}},{key:"createFakeElement",value:function(){var t="rtl"===document.documentElement.getAttribute("dir");this.fakeElem=document.createElement("textarea"),this.fakeElem.style.fontSize="12pt",this.fakeElem.style.border="0",this.fakeElem.style.padding="0",this.fakeElem.style.margin="0",this.fakeElem.style.position="absolute",this.fakeElem.style[t?"right":"left"]="-9999px";var e=window.pageYOffset||document.documentElement.scrollTop;return this.fakeElem.style.top="".concat(e,"px"),this.fakeElem.setAttribute("readonly",""),this.fakeElem.value=this.text,this.fakeElem}},{key:"selectFake",value:function(){var t=this,e=this.createFakeElement();this.fakeHandlerCallback=function(){return t.removeFake()},this.fakeHandler=this.container.addEventListener("click",this.fakeHandlerCallback)||!0,this.container.appendChild(e),this.selectedText=s()(e),this.copyText(),this.removeFake()}},{key:"removeFake",value:function(){this.fakeHandler&&(this.container.removeEventListener("click",this.fakeHandlerCallback),this.fakeHandler=null,this.fakeHandlerCallback=null),this.fakeElem&&(this.container.removeChild(this.fakeElem),this.fakeElem=null)}},{key:"selectTarget",value:function(){this.selectedText=s()(this.target),this.copyText()}},{key:"copyText",value:function(){var t;try{t=document.execCommand(this.action)}catch(e){t=!1}this.handleResult(t)}},{key:"handleResult",value:function(t){this.emitter.emit(t?"success":"error",{action:this.action,text:this.selectedText,trigger:this.trigger,clearSelection:this.clearSelection.bind(this)})}},{key:"clearSelection",value:function(){this.trigger&&this.trigger.focus(),document.activeElement.blur(),window.getSelection().removeAllRanges()}},{key:"destroy",value:function(){this.removeFake()}},{key:"action",set:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"copy";if(this._action=t,"copy"!==this._action&&"cut"!==this._action)throw new Error('Invalid "action" value, use either "copy" or "cut"')},get:function(){return this._action}},{key:"target",set:function(t){if(void 0!==t){if(!t||"object"!==c(t)||1!==t.nodeType)throw new Error('Invalid "target" value, use a valid Element');if("copy"===this.action&&t.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if("cut"===this.action&&(t.hasAttribute("readonly")||t.hasAttribute("disabled")))throw new Error('Invalid "target" attribute. You can\'t cut text from elements with "readonly" or "disabled" attributes');this._target=t}},get:function(){return this._target}}],n&&l(e.prototype,n),r&&l(e,r),t}(),d=f;function h(t){return h="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},h(t)}function v(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function p(t,e){return p=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},p(t,e)}function y(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var n,r=g(t);if(e){var i=g(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return m(this,n)}}function m(t,e){return!e||"object"!==h(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function g(t){return g=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},g(t)}function b(t,e){var n="data-clipboard-".concat(t);if(e.hasAttribute(n))return e.getAttribute(n)}var $=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&p(t,e)}(o,t);var e,n,r,i=y(o);function o(t,e){var n;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,o),(n=i.call(this)).resolveOptions(e),n.listenClick(t),n}return e=o,n=[{key:"resolveOptions",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.action="function"==typeof t.action?t.action:this.defaultAction,this.target="function"==typeof t.target?t.target:this.defaultTarget,this.text="function"==typeof t.text?t.text:this.defaultText,this.container="object"===h(t.container)?t.container:document.body}},{key:"listenClick",value:function(t){var e=this;this.listener=a()(t,"click",(function(t){return e.onClick(t)}))}},{key:"onClick",value:function(t){var e=t.delegateTarget||t.currentTarget;this.clipboardAction&&(this.clipboardAction=null),this.clipboardAction=new d({action:this.action(e),target:this.target(e),text:this.text(e),container:this.container,trigger:e,emitter:this})}},{key:"defaultAction",value:function(t){return b("action",t)}},{key:"defaultTarget",value:function(t){var e=b("target",t);if(e)return document.querySelector(e)}},{key:"defaultText",value:function(t){return b("text",t)}},{key:"destroy",value:function(){this.listener.destroy(),this.clipboardAction&&(this.clipboardAction.destroy(),this.clipboardAction=null)}}],r=[{key:"isSupported",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["copy","cut"],e="string"==typeof t?[t]:t,n=!!document.queryCommandSupported;return e.forEach((function(t){n=n&&!!document.queryCommandSupported(t)})),n}}],n&&v(e.prototype,n),r&&v(e,r),o}(i()),E=$},828:function(t){if("undefined"!=typeof Element&&!Element.prototype.matches){var e=Element.prototype;e.matches=e.matchesSelector||e.mozMatchesSelector||e.msMatchesSelector||e.oMatchesSelector||e.webkitMatchesSelector}t.exports=function(t,e){for(;t&&9!==t.nodeType;){if("function"==typeof t.matches&&t.matches(e))return t;t=t.parentNode}}},438:function(t,e,n){var r=n(828);function i(t,e,n,r,i){var a=o.apply(this,arguments);return t.addEventListener(n,a,i),{destroy:function(){t.removeEventListener(n,a,i)}}}function o(t,e,n,i){return function(n){n.delegateTarget=r(n.target,e),n.delegateTarget&&i.call(t,n)}}t.exports=function(t,e,n,r,o){return"function"==typeof t.addEventListener?i.apply(null,arguments):"function"==typeof n?i.bind(null,document).apply(null,arguments):("string"==typeof t&&(t=document.querySelectorAll(t)),Array.prototype.map.call(t,(function(t){return i(t,e,n,r,o)})))}},879:function(t,e){e.node=function(t){return void 0!==t&&t instanceof HTMLElement&&1===t.nodeType},e.nodeList=function(t){var n=Object.prototype.toString.call(t);return void 0!==t&&("[object NodeList]"===n||"[object HTMLCollection]"===n)&&"length"in t&&(0===t.length||e.node(t[0]))},e.string=function(t){return"string"==typeof t||t instanceof String},e.fn=function(t){return"[object Function]"===Object.prototype.toString.call(t)}},370:function(t,e,n){var r=n(879),i=n(438);t.exports=function(t,e,n){if(!t&&!e&&!n)throw new Error("Missing required arguments");if(!r.string(e))throw new TypeError("Second argument must be a String");if(!r.fn(n))throw new TypeError("Third argument must be a Function");if(r.node(t))return function(t,e,n){return t.addEventListener(e,n),{destroy:function(){t.removeEventListener(e,n)}}}(t,e,n);if(r.nodeList(t))return function(t,e,n){return Array.prototype.forEach.call(t,(function(t){t.addEventListener(e,n)})),{destroy:function(){Array.prototype.forEach.call(t,(function(t){t.removeEventListener(e,n)}))}}}(t,e,n);if(r.string(t))return function(t,e,n){return i(document.body,t,e,n)}(t,e,n);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}},817:function(t){t.exports=function(t){var e;if("SELECT"===t.nodeName)t.focus(),e=t.value;else if("INPUT"===t.nodeName||"TEXTAREA"===t.nodeName){var n=t.hasAttribute("readonly");n||t.setAttribute("readonly",""),t.select(),t.setSelectionRange(0,t.value.length),n||t.removeAttribute("readonly"),e=t.value}else{t.hasAttribute("contenteditable")&&t.focus();var r=window.getSelection(),i=document.createRange();i.selectNodeContents(t),r.removeAllRanges(),r.addRange(i),e=r.toString()}return e}},279:function(t){function e(){}e.prototype={on:function(t,e,n){var r=this.e||(this.e={});return(r[t]||(r[t]=[])).push({fn:e,ctx:n}),this},once:function(t,e,n){var r=this;function i(){r.off(t,i),e.apply(n,arguments)}return i._=e,this.on(t,i,n)},emit:function(t){for(var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),r=0,i=n.length;r<i;r++)n[r].fn.apply(n[r].ctx,e);return this},off:function(t,e){var n=this.e||(this.e={}),r=n[t],i=[];if(r&&e)for(var o=0,a=r.length;o<a;o++)r[o].fn!==e&&r[o].fn._!==e&&i.push(r[o]);return i.length?n[t]=i:delete n[t],this}},t.exports=e,t.exports.TinyEmitter=e}},e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={exports:{}};return t[r](i,i.exports,n),i.exports}return n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,{a:e}),e},n.d=function(t,e){for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n(134)}().default},t.exports=n()})),j=(x=R)&&x.__esModule&&Object.prototype.hasOwnProperty.call(x,"default")?x.default:x,P=function(t){var e,n=h(t);t.directive("copy",((e={})[n.mounted]=function(t,e){if("success"===e.arg)t._vClipboard_success=e.value;else if("error"===e.arg)t._vClipboard_error=e.value;else{var n=new j(t,{text:function(){return e.value},action:function(){return"cut"===e.arg?"cut":"copy"},container:void 0});n.on("success",(function(e){var n=t._vClipboard_success;"function"==typeof n&&n(e)})),n.on("error",(function(e){var n=t._vClipboard_error;"function"==typeof n&&n(e)})),t._vClipboard=n}},e[n.updated]=function(t,e){"success"===e.arg?t._vClipboard_success=e.value:"error"===e.arg?t._vClipboard_error=e.value:(t._vClipboard.text=function(){return e.value},t._vClipboard.action=function(){return"cut"===e.arg?"cut":"copy"})},e[n.unMounted]=function(t,e){"success"===e.arg?delete t._vClipboard_success:"error"===e.arg?delete t._vClipboard_error:(t._vClipboard.destroy(),delete t._vClipboard)},e))},I={install:function(t,e){P(t)}},U=function(t){var e,n=h(t);t.directive("throttle",((e={})[n.mounted]=function(t,e){var n=e.value;!function(t,e,n,r){void 0===t&&(t="click"),void 0===n&&(n=1e3),e.addEventListener(t,(function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var i=0,o=(new Date).getTime();n-(o-i)<=0&&(r(),i=o)}))}(n.event,t,n.delay,n.callback)},e))},F={install:function(t,e){U(t)}},N=function(t){var e,n=h(t);t.directive("longpress",((e={})[n.mounted]=function(t,e){var n=e.value,r=n.fn,i=n.time;"function"==typeof r&&(t._timer=null,t._start=function(e){"mousedown"===e.type&&e.button&&0!==e.button||"touchstart"===e.type&&e.touches&&e.touches.length>1||null===t._timer&&(t._timer=setTimeout((function(){r()}),i),t.addEventListener("contextmenu",(function(t){t.preventDefault()})))},t._cancel=function(e){null!==t._timer&&(clearTimeout(t._timer),t._timer=null)},t.addEventListener("mousedown",t._start),t.addEventListener("touchstart",t._start),t.addEventListener("click",t._cancel),t.addEventListener("mouseout",t._cancel),t.addEventListener("touchend",t._cancel),t.addEventListener("touchcancel",t._cancel))},e[n.unMounted]=function(t,e){e.value,t.removeEventListener("mousedown",t._start),t.removeEventListener("touchstart",t._start),t.removeEventListener("click",t._cancel),t.removeEventListener("mouseout",t._cancel),t.removeEventListener("touchend",t._cancel),t.removeEventListener("touchcancel",t._cancel)},e))},W={install:function(t,e){N(t)}},q={install:function(t,e){!function(t){o(t)?Object.keys(a).forEach((function(e){t.config.globalProperties[e]=a[e]})):Object.keys(a).forEach((function(e){t.prototype[e]=a[e]}))}(t),function(t){o(t)?t.config.globalProperties.$format=l:t.prototype.$format=l}(t),function(t){o(t)?t.config.globalProperties.$deepClone=f:t.prototype.$deepClone=f}(t),p(t),b(t),w(t),L(t),P(t),U(t),N(t),H(t)}};export{k as VClickoutside,I as VClipBoard,y as VDebounce,Y as VFormatTime,W as VLongPress,$ as VPermission,A as VRipple,F as VThrottle,q as default};