mirror of
https://github.com/kuaifan/dootask.git
synced 2025-12-12 19:35:50 +00:00
7 lines
23 KiB
JavaScript
Vendored
7 lines
23 KiB
JavaScript
Vendored
import{c as F}from"./@babel.49d8906a.js";var I={exports:{}};/*!
|
|
* tui-code-snippet.js
|
|
* @version 1.5.2
|
|
* @author NHN. FE Development Lab <dl_javascript@nhn.com>
|
|
* @license MIT
|
|
*/(function(M,H){(function(E,u){M.exports=u()})(F,function(){return function(m){var E={};function u(c){if(E[c])return E[c].exports;var p=E[c]={exports:{},id:c,loaded:!1};return m[c].call(p.exports,p,p.exports,u),p.loaded=!0,p.exports}return u.m=m,u.c=E,u.p="dist",u(0)}([function(m,E,u){var c={},p=u(1),v=p.extend;v(c,p),v(c,u(3)),v(c,u(2)),v(c,u(4)),v(c,u(5)),v(c,u(6)),v(c,u(7)),v(c,u(8)),v(c,u(9)),c.browser=u(10),c.popup=u(11),c.formatDate=u(12),c.defineClass=u(13),c.defineModule=u(14),c.defineNamespace=u(15),c.CustomEvents=u(16),c.Enum=u(17),c.ExMap=u(18),c.HashMap=u(20),c.Map=u(19),m.exports=c},function(m,E,u){var c=u(2),p=u(3),v=0;function h(s,f){var l=Object.prototype.hasOwnProperty,y,g,x,O;for(x=1,O=arguments.length;x<O;x+=1){y=arguments[x];for(g in y)l.call(y,g)&&(s[g]=y[g])}return s}function a(s){return s.__fe_id||(v+=1,s.__fe_id=v),s.__fe_id}function n(s){return c.isExisty(i(s,"__fe_id"))}function o(){v=0}function r(s){var f=[],l;for(l in s)s.hasOwnProperty(l)&&f.push(l);return f}function t(s){var f=arguments.length,l=1;if(f<1)return!0;for(;l<f;l+=1)if(!e(s,arguments[l]))return!1;return!0}function e(s,f){var l=[],y=[],g;if(isNaN(s)&&isNaN(f)&&c.isNumber(s)&&c.isNumber(f)||s===f)return!0;if(c.isFunction(s)&&c.isFunction(f)||s instanceof Date&&f instanceof Date||s instanceof RegExp&&f instanceof RegExp||s instanceof String&&f instanceof String||s instanceof Number&&f instanceof Number)return s.toString()===f.toString();if(!(s instanceof Object&&f instanceof Object)||s.isPrototypeOf(f)||f.isPrototypeOf(s)||s.constructor!==f.constructor||s.prototype!==f.prototype||p.inArray(s,l)>-1||p.inArray(f,y)>-1)return!1;for(g in f){if(f.hasOwnProperty(g)!==s.hasOwnProperty(g))return!1;if(typeof f[g]!=typeof s[g])return!1}for(g in s){if(f.hasOwnProperty(g)!==s.hasOwnProperty(g))return!1;if(typeof f[g]!=typeof s[g])return!1;if(typeof s[g]=="object"||typeof s[g]=="function"){if(l.push(s),y.push(f),!e(s[g],f[g]))return!1;l.pop(),y.pop()}else if(s[g]!==f[g])return!1}return!0}function i(s,f){for(var l=arguments,y=l[0],g=1,x=l.length;g<x;g+=1){if(c.isUndefined(y)||c.isNull(y))return;y=y[l[g]]}return y}m.exports={extend:h,stamp:a,hasStamp:n,resetLastId:o,keys:Object.prototype.keys||r,compareJSON:t,pick:i}},function(m,E){var u=Object.prototype.toString;function c(d){return!p(d)&&!v(d)}function p(d){return d===void 0}function v(d){return d===null}function h(d){return c(d)&&d!==!1}function a(d){return!h(d)}function n(d){var A=c(d)&&(u.call(d)==="[object Arguments]"||!!d.callee);return A}function o(d){return d instanceof Array}function r(d){return d===Object(d)}function t(d){return d instanceof Function}function e(d){return typeof d=="number"||d instanceof Number}function i(d){return typeof d=="string"||d instanceof String}function s(d){return typeof d=="boolean"||d instanceof Boolean}function f(d){return u.call(d)==="[object Array]"}function l(d){return u.call(d)==="[object Function]"}function y(d){return u.call(d)==="[object Number]"}function g(d){return u.call(d)==="[object String]"}function x(d){return u.call(d)==="[object Boolean]"}function O(d){return typeof HTMLElement=="object"?d&&(d instanceof HTMLElement||!!d.nodeType):!!(d&&d.nodeType)}function P(d){return typeof HTMLElement=="object"?d&&d instanceof HTMLElement:!!(d&&d.nodeType&&d.nodeType===1)}function S(d){return!c(d)||N(d)?!0:o(d)||n(d)?d.length===0:r(d)&&!t(d)?!w(d):!0}function N(d){return i(d)&&d===""}function w(d){var A;for(A in d)if(d.hasOwnProperty(A))return!0;return!1}function b(d){return!S(d)}function T(d){return d instanceof Date}function C(d){return u.call(d)==="[object Date]"}m.exports={isExisty:c,isUndefined:p,isNull:v,isTruthy:h,isFalsy:a,isArguments:n,isArray:o,isArraySafe:f,isObject:r,isFunction:t,isFunctionSafe:l,isNumber:e,isNumberSafe:y,isDate:T,isDateSafe:C,isString:i,isStringSafe:g,isBoolean:s,isBooleanSafe:x,isHTMLNode:O,isHTMLTag:P,isEmpty:S,isNotEmpty:b}},function(m,E,u){var c=u(4),p=u(2),v=Array.prototype.slice,h,a=function(r,t,e){var i=[],s;for(p.isUndefined(t)&&(t=r||0,r=0),e=e||1,s=e<0?-1:1,t*=s;r*s<t;r+=e)i.push(r);return i},n=function(){var r=v.call(arguments),t=[];return c.forEach(r,function(e){c.forEach(e,function(i,s){t[s]||(t[s]=[]),t[s].push(i)})}),t},o=function(r,t,e){var i,s;if(e=e||0,!p.isArray(t))return-1;if(Array.prototype.indexOf)return Array.prototype.indexOf.call(t,r,e);for(s=t.length,i=e;e>=0&&i<s;i+=1)if(t[i]===r)return i;return-1};h={inArray:o,range:a,zip:n},m.exports=h},function(m,E,u){var c=u(2),p=u(1);function v(i,s,f){var l=0,y=i.length;for(f=f||null;l<y&&s.call(f,i[l],l,i)!==!1;l+=1);}function h(i,s,f){var l;f=f||null;for(l in i)if(i.hasOwnProperty(l)&&s.call(f,i[l],l,i)===!1)break}function a(i,s,f){c.isArray(i)?v(i,s,f):h(i,s,f)}function n(i,s,f){var l=[];return f=f||null,a(i,function(){l.push(s.apply(f,arguments))}),l}function o(i,s,f){var l=0,y,g,x;for(f=f||null,c.isArray(i)?(g=i.length,x=i[l]):(y=p.keys(i),g=y.length,x=i[y[l+=1]]),l+=1;l<g;l+=1)x=s.call(f,x,i[y?y[l]:l]);return x}function r(i){var s;try{s=Array.prototype.slice.call(i)}catch{s=[],v(i,function(l){s.push(l)})}return s}function t(i,s,f){var l,y;if(f=f||null,!c.isObject(i)||!c.isFunction(s))throw new Error("wrong parameter");return c.isArray(i)?(l=[],y=function(g,x){g.push(x[0])}):(l={},y=function(g,x){g[x[1]]=x[0]}),a(i,function(){s.apply(f,arguments)&&y(l,arguments)},f),l}function e(i,s){var f=n(i,function(l){return l[s]});return f}m.exports={forEachOwnProperties:h,forEachArray:v,forEach:a,toArray:r,map:n,reduce:o,filter:t,pluck:e}},function(m,E){function u(c,p){var v=Array.prototype.slice,h;return c.bind?c.bind.apply(c,v.call(arguments,1)):(h=v.call(arguments,2),function(){return c.apply(p,h.length?h.concat(v.call(arguments)):arguments)})}m.exports={bind:u}},function(m,E){function u(p){function v(){}return v.prototype=p,new v}function c(p,v){var h=u(v.prototype);h.constructor=p,p.prototype=h}m.exports={createObject:u,inherit:c}},function(m,E,u){var c=u(4),p=u(1);function v(o){var r={""":'"',"&":"&","<":"<",">":">","'":"'"," ":" "};return o.replace(/&|<|>|"|'| /g,function(t){return r[t]?r[t]:t})}function h(o){var r={'"':"quot","&":"amp","<":"lt",">":"gt","'":"#39"};return o.replace(/[<>&"']/g,function(t){return r[t]?"&"+r[t]+";":t})}function a(o){return/[<>&"']/.test(o)}function n(o,r){for(var t=0,e=o.length,i={},s,f;t<e;t+=1)f=o.charAt(t),i[f]=1;for(t=0,e=r.length;t<e;t+=1)f=r.charAt(t),i[f]&&(i[f]+=1);return i=c.filter(i,function(l){return l>1}),i=p.keys(i).sort(),s=i.join(""),s}m.exports={decodeHTMLEntity:v,encodeHTMLEntity:h,hasEncodableString:a,getDuplicatedChar:n}},function(m,E){var u={},c=Array.prototype.slice;function p(a,n){var o,r;n=n||0;function t(){r=c.call(arguments),window.clearTimeout(o),o=window.setTimeout(function(){a.apply(null,r)},n)}return t}function v(){return Number(new Date)}function h(a,n){var o,r=!0,t=function(y){a.apply(null,y),o=null},e,i,s;n=n||0,e=u.debounce(t,n);function f(){if(s=c.call(arguments),r){t(s),r=!1;return}i=u.timestamp(),o=o||i,e(s),i-o>=n&&t(s)}function l(){r=!0,o=null}return f.reset=l,f}u.timestamp=v,u.debounce=p,u.throttle=h,m.exports=u},function(m,E,u){var c=u(1),p=u(4),v=u(2),h=7*24*60*60*1e3;function a(r){var t=new Date().getTime();return t-r>h}function n(r,t){var e="https://www.google-analytics.com/collect",i=location.hostname,s="event",f="use",l="TOAST UI "+r+" for "+i+": Statistics",y=window.localStorage.getItem(l);!v.isUndefined(window.tui)&&window.tui.usageStatistics===!1||y&&!a(y)||(window.localStorage.setItem(l,new Date().getTime()),setTimeout(function(){(document.readyState==="interactive"||document.readyState==="complete")&&o(e,{v:1,t:s,tid:t,cid:i,dp:i,dh:r,el:r,ec:f})},1e3))}function o(r,t){var e=p.map(c.keys(t),function(s,f){var l=f===0?"":"&";return l+s+"="+t[s]}).join(""),i=document.createElement("img");return i.src=r+"?"+e,i.style.display="none",document.body.appendChild(i),document.body.removeChild(i),i}m.exports={imagePing:o,sendHostname:n}},function(m,E){var u={chrome:!1,firefox:!1,safari:!1,msie:!1,edge:!1,others:!1,version:0};window&&window.navigator&&c();function c(){var p=window.navigator,v=p.appName.replace(/\s/g,"_"),h=p.userAgent,a=/MSIE\s([0-9]+[.0-9]*)/,n=/Trident.*rv:11\./,o=/Edge\/(\d+)\./,r={firefox:/Firefox\/(\d+)\./,chrome:/Chrome\/(\d+)\./,safari:/Version\/([\d.]+).*Safari\/(\d+)/},t,e,i={Microsoft_Internet_Explorer:function(){var f=h.match(a);f?(u.msie=!0,u.version=parseFloat(f[1])):u.others=!0},Netscape:function(){var f=!1;if(n.exec(h))u.msie=!0,u.version=11,f=!0;else if(o.exec(h))u.edge=!0,u.version=h.match(o)[1],f=!0;else for(t in r)if(r.hasOwnProperty(t)&&(e=h.match(r[t]),e&&e.length>1)){u[t]=f=!0,u.version=parseFloat(e[1]||0);break}f||(u.others=!0)}},s=i[v];s&&i[v]()}m.exports=u},function(m,E,u){var c=u(4),p=u(2),v=u(5),h=u(10),a=u(1),n=0;function o(){this.openedPopup={},this.closeWithParentPopup={},this.postBridgeUrl=""}o.prototype.getPopupList=function(r){var t;return p.isExisty(r)?t=this.openedPopup[r]:t=this.openedPopup,t},o.prototype.openPopup=function(r,t){var e,i,s;if(t=a.extend({popupName:"popup_"+n+"_"+Number(new Date),popupOptionStr:"",useReload:!0,closeWithParent:!0,method:"get",param:{}},t||{}),t.method=t.method.toUpperCase(),this.postBridgeUrl=t.postBridgeUrl||this.postBridgeUrl,s=t.method==="POST"&&t.param&&h.msie&&h.version===11,!p.isExisty(r))throw new Error("Popup#open() need popup url.");n+=1,t.param&&(t.method==="GET"?r=r+(/\?/.test(r)?"&":"?")+this._parameterize(t.param):t.method==="POST"&&(s||(i=this.createForm(r,t.param,t.method,t.popupName),r="about:blank"))),e=this.openedPopup[t.popupName],p.isExisty(e)?e.closed?this.openedPopup[t.popupName]=e=this._open(s,t.param,r,t.popupName,t.popupOptionStr):(t.useReload&&e.location.replace(r),e.focus()):this.openedPopup[t.popupName]=e=this._open(s,t.param,r,t.popupName,t.popupOptionStr),this.closeWithParentPopup[t.popupName]=t.closeWithParent,(!e||e.closed||p.isUndefined(e.closed))&&alert("please enable popup windows for this website"),t.param&&t.method==="POST"&&!s&&(e&&i.submit(),i.parentNode&&i.parentNode.removeChild(i)),window.onunload=v.bind(this.closeAllPopup,this)},o.prototype.close=function(r,t){var e=t||window;r=p.isExisty(r)?r:!1,r&&(window.onunload=null),e.closed||(e.opener=window.location.href,e.close())},o.prototype.closeAllPopup=function(r){var t=p.isExisty(r);c.forEachOwnProperties(this.openedPopup,function(e,i){(t&&this.closeWithParentPopup[i]||!t)&&this.close(!1,e)},this)},o.prototype.focus=function(r){this.getPopupList(r).focus()},o.prototype.parseQuery=function(){var r={},t,e;return t=window.location.search.substr(1),c.forEachArray(t.split("&"),function(i){e=i.split("="),r[decodeURIComponent(e[0])]=decodeURIComponent(e[1])}),r},o.prototype.createForm=function(r,t,e,i,s){var f=document.createElement("form"),l;return s=s||document.body,f.method=e||"POST",f.action=r||"",f.target=i||"",f.style.display="none",c.forEachOwnProperties(t,function(y,g){l=document.createElement("input"),l.name=g,l.type="hidden",l.value=y,f.appendChild(l)}),s.appendChild(f),f},o.prototype._parameterize=function(r){var t=[];return c.forEachOwnProperties(r,function(e,i){t.push(encodeURIComponent(i)+"="+encodeURIComponent(e))}),t.join("&")},o.prototype._open=function(r,t,e,i,s){var f;return r?(f=window.open(this.postBridgeUrl,i,s),setTimeout(function(){f.redirect(e,t)},100)):f=window.open(e,i,s),f},m.exports=new o},function(m,E,u){var c=u(2),p=u(1),v=/[\\]*YYYY|[\\]*YY|[\\]*MMMM|[\\]*MMM|[\\]*MM|[\\]*M|[\\]*DD|[\\]*D|[\\]*HH|[\\]*H|[\\]*A/gi,h=["Invalid month","January","February","March","April","May","June","July","August","September","October","November","December"],a=[0,31,28,31,30,31,30,31,31,30,31,30,31],n={M:function(t){return Number(t.month)},MM:function(t){var e=t.month;return Number(e)<10?"0"+e:e},MMM:function(t){return h[Number(t.month)].substr(0,3)},MMMM:function(t){return h[Number(t.month)]},D:function(t){return Number(t.date)},d:function(t){return n.D(t)},DD:function(t){var e=t.date;return Number(e)<10?"0"+e:e},dd:function(t){return n.DD(t)},YY:function(t){return Number(t.year)%100},yy:function(t){return n.YY(t)},YYYY:function(t){var e="20",i=t.year;return i>69&&i<100&&(e="19"),Number(i)<100?e+String(i):i},yyyy:function(t){return n.YYYY(t)},A:function(t){return t.meridiem},a:function(t){return t.meridiem},hh:function(t){var e=t.hour;return Number(e)<10?"0"+e:e},HH:function(t){return n.hh(t)},h:function(t){return String(Number(t.hour))},H:function(t){return n.h(t)},m:function(t){return String(Number(t.minute))},mm:function(t){var e=t.minute;return Number(e)<10?"0"+e:e}};function o(t,e,i){var s,f,l,y;return t=Number(t),e=Number(e),i=Number(i),s=t>-1&&t<100||t>1969&&t<2070,f=e>0&&e<13,!s||!f?!1:(y=a[e],e===2&&t%4===0&&(t%100!==0||t%400===0)&&(y=29),l=i>0&&i<=y,l)}function r(t,e,i){var s=p.pick(i,"meridiemSet","AM")||"AM",f=p.pick(i,"meridiemSet","PM")||"PM",l,y,g;return c.isDate(e)?y={year:e.getFullYear(),month:e.getMonth()+1,date:e.getDate(),hour:e.getHours(),minute:e.getMinutes()}:y={year:e.year,month:e.month,date:e.date,hour:e.hour,minute:e.minute},o(y.year,y.month,y.date)?(y.meridiem="",/([^\\]|^)[aA]\b/.test(t)&&(l=y.hour>11?f:s,y.hour>12&&(y.hour%=12),y.hour===0&&(y.hour=12),y.meridiem=l),g=t.replace(v,function(x){return x.indexOf("\\")>-1?x.replace(/\\/,""):n[x](y)||""}),g):!1}m.exports=r},function(m,E,u){var c=u(6).inherit,p=u(1).extend;function v(h,a){var n;return a||(a=h,h=null),n=a.init||function(){},h&&c(n,h),a.hasOwnProperty("static")&&(p(n,a.static),delete a.static),p(n.prototype,a),n}m.exports=v},function(m,E,u){var c=u(15),p=u(2),v="initialize";function h(a,n){var o=n||{};return p.isFunction(o[v])&&o[v](),c(a,o)}m.exports=h},function(m,E,u){var c=u(4),p=u(1);function v(h,a,n){var o,r,t,e;return o=h.split("."),o.unshift(window),r=c.reduce(o,function(i,s){return i[s]=i[s]||{},i[s]}),n?(e=o.pop(),t=p.pick.apply(null,o),r=t[e]=a):p.extend(r,a),r}m.exports=v},function(m,E,u){var c=u(4),p=u(2),v=u(1),h=/\s+/g;function a(){this.events=null,this.contexts=null}a.mixin=function(n){v.extend(n.prototype,a.prototype)},a.prototype._getHandlerItem=function(n,o){var r={handler:n};return o&&(r.context=o),r},a.prototype._safeEvent=function(n){var o=this.events,r;return o||(o=this.events={}),n&&(r=o[n],r||(r=[],o[n]=r),o=r),o},a.prototype._safeContext=function(){var n=this.contexts;return n||(n=this.contexts=[]),n},a.prototype._indexOfContext=function(n){for(var o=this._safeContext(),r=0;o[r];){if(n===o[r][0])return r;r+=1}return-1},a.prototype._memorizeContext=function(n){var o,r;!p.isExisty(n)||(o=this._safeContext(),r=this._indexOfContext(n),r>-1?o[r][1]+=1:o.push([n,1]))},a.prototype._forgetContext=function(n){var o,r;!p.isExisty(n)||(o=this._safeContext(),r=this._indexOfContext(n),r>-1&&(o[r][1]-=1,o[r][1]<=0&&o.splice(r,1)))},a.prototype._bindEvent=function(n,o,r){var t=this._safeEvent(n);this._memorizeContext(r),t.push(this._getHandlerItem(o,r))},a.prototype.on=function(n,o,r){var t=this;p.isString(n)?(n=n.split(h),c.forEach(n,function(e){t._bindEvent(e,o,r)})):p.isObject(n)&&(r=o,c.forEach(n,function(e,i){t.on(i,e,r)}))},a.prototype.once=function(n,o,r){var t=this;if(p.isObject(n)){r=o,c.forEach(n,function(i,s){t.once(s,i,r)});return}function e(){o.apply(r,arguments),t.off(n,e,r)}this.on(n,e,r)},a.prototype._spliceMatches=function(n,o){var r=0,t;if(!!p.isArray(n))for(t=n.length;r<t;r+=1)o(n[r])===!0&&(n.splice(r,1),t-=1,r-=1)},a.prototype._matchHandler=function(n){var o=this;return function(r){var t=n===r.handler;return t&&o._forgetContext(r.context),t}},a.prototype._matchContext=function(n){var o=this;return function(r){var t=n===r.context;return t&&o._forgetContext(r.context),t}},a.prototype._matchHandlerAndContext=function(n,o){var r=this;return function(t){var e=n===t.handler,i=o===t.context,s=e&&i;return s&&r._forgetContext(t.context),s}},a.prototype._offByEventName=function(n,o){var r=this,t=c.forEachArray,e=p.isFunction(o),i=r._matchHandler(o);n=n.split(h),t(n,function(s){var f=r._safeEvent(s);e?r._spliceMatches(f,i):(t(f,function(l){r._forgetContext(l.context)}),r.events[s]=[])})},a.prototype._offByHandler=function(n){var o=this,r=this._matchHandler(n);c.forEach(this._safeEvent(),function(t){o._spliceMatches(t,r)})},a.prototype._offByObject=function(n,o){var r=this,t;this._indexOfContext(n)<0?c.forEach(n,function(e,i){r.off(i,e)}):p.isString(o)?(t=this._matchContext(n),r._spliceMatches(this._safeEvent(o),t)):p.isFunction(o)?(t=this._matchHandlerAndContext(o,n),c.forEach(this._safeEvent(),function(e){r._spliceMatches(e,t)})):(t=this._matchContext(n),c.forEach(this._safeEvent(),function(e){r._spliceMatches(e,t)}))},a.prototype.off=function(n,o){p.isString(n)?this._offByEventName(n,o):arguments.length?p.isFunction(n)?this._offByHandler(n):p.isObject(n)&&this._offByObject(n,o):(this.events={},this.contexts=[])},a.prototype.fire=function(n){this.invoke.apply(this,arguments)},a.prototype.invoke=function(n){var o,r,t,e;if(!this.hasListener(n))return!0;for(o=this._safeEvent(n),r=Array.prototype.slice.call(arguments,1),t=0;o[t];){if(e=o[t],e.handler.apply(e.context,r)===!1)return!1;t+=1}return!0},a.prototype.hasListener=function(n){return this.getListenerLength(n)>0},a.prototype.getListenerLength=function(n){var o=this._safeEvent(n);return o.length},m.exports=a},function(m,E,u){var c=u(4),p=u(2),v=function(){try{return Object.defineProperty({},"x",{}),!0}catch{return!1}}(),h=0;function a(n){n&&this.set.apply(this,arguments)}a.prototype.set=function(n){var o=this;p.isArray(n)||(n=c.toArray(arguments)),c.forEach(n,function(t){o._addItem(t)})},a.prototype.getName=function(n){var o=this,r;return c.forEach(this,function(t,e){if(o._isEnumItem(e)&&n===t)return r=e,!1}),r},a.prototype._addItem=function(n){var o;this.hasOwnProperty(n)||(o=this._makeEnumValue(),v?Object.defineProperty(this,n,{enumerable:!0,configurable:!1,writable:!1,value:o}):this[n]=o)},a.prototype._makeEnumValue=function(){var n;return n=h,h+=1,n},a.prototype._isEnumItem=function(n){return p.isNumber(this[n])},m.exports=a},function(m,E,u){var c=u(4),p=u(19),v=["get","has","forEach","keys","values","entries"],h=["delete","clear"];function a(n){this._map=new p(n),this.size=this._map.size}c.forEachArray(v,function(n){a.prototype[n]=function(){return this._map[n].apply(this._map,arguments)}}),c.forEachArray(h,function(n){a.prototype[n]=function(){var o=this._map[n].apply(this._map,arguments);return this.size=this._map.size,o}}),a.prototype.set=function(){return this._map.set.apply(this._map,arguments),this.size=this._map.size,this},a.prototype.setObject=function(n){c.forEachOwnProperties(n,function(o,r){this.set(r,o)},this)},a.prototype.deleteByKeys=function(n){c.forEachArray(n,function(o){this.delete(o)},this)},a.prototype.merge=function(n){n.forEach(function(o,r){this.set(r,o)},this)},a.prototype.filter=function(n){var o=new a;return this.forEach(function(r,t){n(r,t)&&o.set(t,r)}),o},m.exports=a},function(m,E,u){var c=u(4),p=u(2),v=u(3),h=u(10),a=u(5),n={},o={};function r(e,i){this._keys=e,this._valueGetter=i,this._length=this._keys.length,this._index=-1,this._done=!1}r.prototype.next=function(){var e={};do this._index+=1;while(p.isUndefined(this._keys[this._index])&&this._index<this._length);return this._index>=this._length?e.done=!0:(e.done=!1,e.value=this._valueGetter(this._keys[this._index],this._index)),e};function t(e){this._valuesForString={},this._valuesForIndex={},this._keys=[],e&&this._setInitData(e),this.size=0}t.prototype._setInitData=function(e){if(!p.isArray(e))throw new Error("Only Array is supported.");c.forEachArray(e,function(i){this.set(i[0],i[1])},this)},t.prototype._isNaN=function(e){return typeof e=="number"&&e!==e},t.prototype._getKeyIndex=function(e){var i=-1,s;return p.isString(e)?(s=this._valuesForString[e],s&&(i=s.keyIndex)):i=v.inArray(e,this._keys),i},t.prototype._getOriginKey=function(e){var i=e;return e===n?i=void 0:e===o&&(i=NaN),i},t.prototype._getUniqueKey=function(e){var i=e;return p.isUndefined(e)?i=n:this._isNaN(e)&&(i=o),i},t.prototype._getValueObject=function(e,i){if(p.isString(e))return this._valuesForString[e];if(p.isUndefined(i)&&(i=this._getKeyIndex(e)),i>=0)return this._valuesForIndex[i]},t.prototype._getOriginValue=function(e,i){return this._getValueObject(e,i).origin},t.prototype._getKeyValuePair=function(e,i){return[this._getOriginKey(e),this._getOriginValue(e,i)]},t.prototype._createValueObject=function(e,i){return{keyIndex:i,origin:e}},t.prototype.set=function(e,i){var s=this._getUniqueKey(e),f=this._getKeyIndex(s),l;return f<0&&(f=this._keys.push(s)-1,this.size+=1),l=this._createValueObject(i,f),p.isString(e)?this._valuesForString[e]=l:this._valuesForIndex[f]=l,this},t.prototype.get=function(e){var i=this._getUniqueKey(e),s=this._getValueObject(i);return s&&s.origin},t.prototype.keys=function(){return new r(this._keys,a.bind(this._getOriginKey,this))},t.prototype.values=function(){return new r(this._keys,a.bind(this._getOriginValue,this))},t.prototype.entries=function(){return new r(this._keys,a.bind(this._getKeyValuePair,this))},t.prototype.has=function(e){return!!this._getValueObject(e)},t.prototype.delete=function(e){var i;p.isString(e)?this._valuesForString[e]&&(i=this._valuesForString[e].keyIndex,delete this._valuesForString[e]):(i=this._getKeyIndex(e),i>=0&&delete this._valuesForIndex[i]),i>=0&&(delete this._keys[i],this.size-=1)},t.prototype.forEach=function(e,i){i=i||this,c.forEachArray(this._keys,function(s){p.isUndefined(s)||e.call(i,this._getValueObject(s).origin,s,this)},this)},t.prototype.clear=function(){t.call(this)},function(){window.Map&&(h.firefox&&h.version>=37||h.chrome&&h.version>=42)&&(t=window.Map)}(),m.exports=t},function(m,E,u){var c=u(4),p=u(2),v="\xE5";function h(a){this.length=0,a&&this.setObject(a)}h.prototype.set=function(a,n){arguments.length===2?this.setKeyValue(a,n):this.setObject(a)},h.prototype.setKeyValue=function(a,n){this.has(a)||(this.length+=1),this[this.encodeKey(a)]=n},h.prototype.setObject=function(a){var n=this;c.forEachOwnProperties(a,function(o,r){n.setKeyValue(r,o)})},h.prototype.merge=function(a){var n=this;a.each(function(o,r){n.setKeyValue(r,o)})},h.prototype.encodeKey=function(a){return v+a},h.prototype.decodeKey=function(a){var n=a.split(v);return n[n.length-1]},h.prototype.get=function(a){return this[this.encodeKey(a)]},h.prototype.has=function(a){return this.hasOwnProperty(this.encodeKey(a))},h.prototype.remove=function(a){return arguments.length>1&&(a=c.toArray(arguments)),p.isArray(a)?this.removeByKeyArray(a):this.removeByKey(a)},h.prototype.removeByKey=function(a){var n=this.has(a)?this.get(a):null;return n!==null&&(delete this[this.encodeKey(a)],this.length-=1),n},h.prototype.removeByKeyArray=function(a){var n=[],o=this;return c.forEach(a,function(r){n.push(o.removeByKey(r))}),n},h.prototype.removeAll=function(){var a=this;this.each(function(n,o){a.remove(o)})},h.prototype.each=function(a){var n=this,o;c.forEachOwnProperties(this,function(r,t){if(t.charAt(0)===v&&(o=a(r,n.decodeKey(t))),o===!1)return o})},h.prototype.keys=function(){var a=[],n=this;return this.each(function(o,r){a.push(n.decodeKey(r))}),a},h.prototype.find=function(a){var n=[];return this.each(function(o,r){a(o,r)&&n.push(o)}),n},h.prototype.toArray=function(){var a=[];return this.each(function(n){a.push(n)}),a},m.exports=h}])})})(I);export{I as t};
|