>>1,o=e[r];if(!(void 0!==o&&0P(i,n))void 0!==l&&0>P(l,i)?(e[r]=l,e[c]=n,r=c):(e[r]=i,e[a]=n,r=a);else{if(!(void 0!==l&&0>P(l,n)))break e;e[r]=l,e[c]=n,r=c}}}return t}return null}function P(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}var N=[],T=[],_=1,M=null,R=3,A=!1,I=!1,D=!1;function L(e){for(var t=j(T);null!==t;){if(null===t.callback)S(T);else{if(!(t.startTime<=e))break;S(T),t.sortIndex=t.expirationTime,k(N,t)}t=j(T)}}function F(e){if(D=!1,L(e),!I)if(null!==j(N))I=!0,r(z);else{var t=j(T);null!==t&&o(F,t.startTime-e)}}function z(e,n){I=!1,D&&(D=!1,a()),A=!0;var r=R;try{for(L(n),M=j(N);null!==M&&(!(M.expirationTime>n)||e&&!i());){var c=M.callback;if(null!==c){M.callback=null,R=M.priorityLevel;var l=c(M.expirationTime<=n);n=t.unstable_now(),"function"===typeof l?M.callback=l:M===j(N)&&S(N),L(n)}else S(N);M=j(N)}if(null!==M)var u=!0;else{var s=j(T);null!==s&&o(F,s.startTime-n),u=!1}return u}finally{M=null,R=r,A=!1}}function K(e){switch(e){case 1:return-1;case 2:return 250;case 5:return 1073741823;case 4:return 1e4;default:return 5e3}}var V=c;t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(e){e.callback=null},t.unstable_continueExecution=function(){I||A||(I=!0,r(z))},t.unstable_getCurrentPriorityLevel=function(){return R},t.unstable_getFirstCallbackNode=function(){return j(N)},t.unstable_next=function(e){switch(R){case 1:case 2:case 3:var t=3;break;default:t=R}var n=R;R=t;try{return e()}finally{R=n}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=V,t.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=R;R=e;try{return t()}finally{R=n}},t.unstable_scheduleCallback=function(e,n,i){var c=t.unstable_now();if("object"===typeof i&&null!==i){var l=i.delay;l="number"===typeof l&&0c?(e.sortIndex=l,k(T,e),null===j(N)&&e===j(T)&&(D?a():D=!0,o(F,l-c))):(e.sortIndex=i,k(N,e),I||A||(I=!0,r(z))),e},t.unstable_shouldYield=function(){var e=t.unstable_now();L(e);var n=j(N);return n!==M&&null!==M&&null!==n&&null!==n.callback&&n.startTime<=e&&n.expirationTime=0)return;i[t]="set-cookie"===t?(i[t]?i[t]:[]).concat([n]):i[t]?i[t]+", "+n:n}})),i):i}},function(e,t,n){"use strict";var r=n(53);e.exports=r.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function o(e){var r=e;return t&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return e=o(window.location.href),function(t){var n=r.isString(t)?o(t):t;return n.protocol===e.protocol&&n.host===e.host}}():function(){return!0}},function(e,t,n){"use strict";var r=n(53);e.exports=r.isStandardBrowserEnv()?{write:function(e,t,n,o,a,i){var c=[];c.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&c.push("expires="+new Date(n).toGMTString()),r.isString(o)&&c.push("path="+o),r.isString(a)&&c.push("domain="+a),!0===i&&c.push("secure"),document.cookie=c.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},function(e,t,n){"use strict";var r=n(171);function o(e){if("function"!==typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise((function(e){t=e}));var n=this;e((function(e){n.reason||(n.reason=new r(e),t(n.reason))}))}o.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},o.source=function(){var e;return{token:new o((function(t){e=t})),cancel:e}},e.exports=o},function(e,t,n){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},function(e,t,n){"use strict";var r=n(29),o=n(33);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=o(n(0)),i=r(n(250)),c=r(n(35)),l=function(e,t){return a.createElement(c.default,Object.assign({},e,{ref:t,icon:i.default}))};l.displayName="InfoCircleFilled";var u=a.forwardRef(l);t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.default={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"info-circle",theme:"filled"}},function(e,t){e.exports=function(e,t){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,a=void 0;try{for(var i,c=e[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(l){o=!0,a=l}finally{try{r||null==c.return||c.return()}finally{if(o)throw a}}return n}}},function(e,t){e.exports=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r=0||(o[n]=e[n]);return o}},function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(254));function a(e,t,n){var r;return(r=Math.round(e.h)>=60&&Math.round(e.h)<=240?n?Math.round(e.h)-2*t:Math.round(e.h)+2*t:n?Math.round(e.h)+2*t:Math.round(e.h)-2*t)<0?r+=360:r>=360&&(r-=360),r}function i(e,t,n){return 0===e.h&&0===e.s?e.s:((r=n?Math.round(100*e.s)-16*t:4===t?Math.round(100*e.s)+16:Math.round(100*e.s)+5*t)>100&&(r=100),n&&5===t&&r>10&&(r=10),r<6&&(r=6),r);var r}function c(e,t,n){return n?Math.round(100*e.v)+5*t:Math.round(100*e.v)-15*t}t.default=function(e){for(var t=[],n=o.default(e),r=5;r>0;r-=1){var l=n.toHsv(),u=o.default({h:a(l,r,!0),s:i(l,r,!0),v:c(l,r,!0)}).toHexString();t.push(u)}for(t.push(n.toHexString()),r=1;r<=4;r+=1){l=n.toHsv(),u=o.default({h:a(l,r),s:i(l,r),v:c(l,r)}).toHexString();t.push(u)}return t}},function(e,t,n){var r;!function(o){var a=/^\s+/,i=/\s+$/,c=0,l=o.round,u=o.min,s=o.max,f=o.random;function d(e,t){if(t=t||{},(e=e||"")instanceof d)return e;if(!(this instanceof d))return new d(e,t);var n=function(e){var t={r:0,g:0,b:0},n=1,r=null,c=null,l=null,f=!1,d=!1;"string"==typeof e&&(e=function(e){e=e.replace(a,"").replace(i,"").toLowerCase();var t,n=!1;if(T[e])e=T[e],n=!0;else if("transparent"==e)return{r:0,g:0,b:0,a:0,format:"name"};if(t=K.rgb.exec(e))return{r:t[1],g:t[2],b:t[3]};if(t=K.rgba.exec(e))return{r:t[1],g:t[2],b:t[3],a:t[4]};if(t=K.hsl.exec(e))return{h:t[1],s:t[2],l:t[3]};if(t=K.hsla.exec(e))return{h:t[1],s:t[2],l:t[3],a:t[4]};if(t=K.hsv.exec(e))return{h:t[1],s:t[2],v:t[3]};if(t=K.hsva.exec(e))return{h:t[1],s:t[2],v:t[3],a:t[4]};if(t=K.hex8.exec(e))return{r:I(t[1]),g:I(t[2]),b:I(t[3]),a:z(t[4]),format:n?"name":"hex8"};if(t=K.hex6.exec(e))return{r:I(t[1]),g:I(t[2]),b:I(t[3]),format:n?"name":"hex"};if(t=K.hex4.exec(e))return{r:I(t[1]+""+t[1]),g:I(t[2]+""+t[2]),b:I(t[3]+""+t[3]),a:z(t[4]+""+t[4]),format:n?"name":"hex8"};if(t=K.hex3.exec(e))return{r:I(t[1]+""+t[1]),g:I(t[2]+""+t[2]),b:I(t[3]+""+t[3]),format:n?"name":"hex"};return!1}(e));"object"==typeof e&&(V(e.r)&&V(e.g)&&V(e.b)?(p=e.r,h=e.g,v=e.b,t={r:255*R(p,255),g:255*R(h,255),b:255*R(v,255)},f=!0,d="%"===String(e.r).substr(-1)?"prgb":"rgb"):V(e.h)&&V(e.s)&&V(e.v)?(r=L(e.s),c=L(e.v),t=function(e,t,n){e=6*R(e,360),t=R(t,100),n=R(n,100);var r=o.floor(e),a=e-r,i=n*(1-t),c=n*(1-a*t),l=n*(1-(1-a)*t),u=r%6;return{r:255*[n,c,i,i,l,n][u],g:255*[l,n,n,c,i,i][u],b:255*[i,i,l,n,n,c][u]}}(e.h,r,c),f=!0,d="hsv"):V(e.h)&&V(e.s)&&V(e.l)&&(r=L(e.s),l=L(e.l),t=function(e,t,n){var r,o,a;function i(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}if(e=R(e,360),t=R(t,100),n=R(n,100),0===t)r=o=a=n;else{var c=n<.5?n*(1+t):n+t-n*t,l=2*n-c;r=i(l,c,e+1/3),o=i(l,c,e),a=i(l,c,e-1/3)}return{r:255*r,g:255*o,b:255*a}}(e.h,r,l),f=!0,d="hsl"),e.hasOwnProperty("a")&&(n=e.a));var p,h,v;return n=M(n),{ok:f,format:e.format||d,r:u(255,s(t.r,0)),g:u(255,s(t.g,0)),b:u(255,s(t.b,0)),a:n}}(e);this._originalInput=e,this._r=n.r,this._g=n.g,this._b=n.b,this._a=n.a,this._roundA=l(100*this._a)/100,this._format=t.format||n.format,this._gradientType=t.gradientType,this._r<1&&(this._r=l(this._r)),this._g<1&&(this._g=l(this._g)),this._b<1&&(this._b=l(this._b)),this._ok=n.ok,this._tc_id=c++}function p(e,t,n){e=R(e,255),t=R(t,255),n=R(n,255);var r,o,a=s(e,t,n),i=u(e,t,n),c=(a+i)/2;if(a==i)r=o=0;else{var l=a-i;switch(o=c>.5?l/(2-a-i):l/(a+i),a){case e:r=(t-n)/l+(t>1)+720)%360;--t;)r.h=(r.h+o)%360,a.push(d(r));return a}function N(e,t){t=t||6;for(var n=d(e).toHsv(),r=n.h,o=n.s,a=n.v,i=[],c=1/t;t--;)i.push(d({h:r,s:o,v:a})),a=(a+c)%1;return i}d.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var e=this.toRgb();return(299*e.r+587*e.g+114*e.b)/1e3},getLuminance:function(){var e,t,n,r=this.toRgb();return e=r.r/255,t=r.g/255,n=r.b/255,.2126*(e<=.03928?e/12.92:o.pow((e+.055)/1.055,2.4))+.7152*(t<=.03928?t/12.92:o.pow((t+.055)/1.055,2.4))+.0722*(n<=.03928?n/12.92:o.pow((n+.055)/1.055,2.4))},setAlpha:function(e){return this._a=M(e),this._roundA=l(100*this._a)/100,this},toHsv:function(){var e=h(this._r,this._g,this._b);return{h:360*e.h,s:e.s,v:e.v,a:this._a}},toHsvString:function(){var e=h(this._r,this._g,this._b),t=l(360*e.h),n=l(100*e.s),r=l(100*e.v);return 1==this._a?"hsv("+t+", "+n+"%, "+r+"%)":"hsva("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHsl:function(){var e=p(this._r,this._g,this._b);return{h:360*e.h,s:e.s,l:e.l,a:this._a}},toHslString:function(){var e=p(this._r,this._g,this._b),t=l(360*e.h),n=l(100*e.s),r=l(100*e.l);return 1==this._a?"hsl("+t+", "+n+"%, "+r+"%)":"hsla("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHex:function(e){return v(this._r,this._g,this._b,e)},toHexString:function(e){return"#"+this.toHex(e)},toHex8:function(e){return function(e,t,n,r,o){var a=[D(l(e).toString(16)),D(l(t).toString(16)),D(l(n).toString(16)),D(F(r))];if(o&&a[0].charAt(0)==a[0].charAt(1)&&a[1].charAt(0)==a[1].charAt(1)&&a[2].charAt(0)==a[2].charAt(1)&&a[3].charAt(0)==a[3].charAt(1))return a[0].charAt(0)+a[1].charAt(0)+a[2].charAt(0)+a[3].charAt(0);return a.join("")}(this._r,this._g,this._b,this._a,e)},toHex8String:function(e){return"#"+this.toHex8(e)},toRgb:function(){return{r:l(this._r),g:l(this._g),b:l(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+l(this._r)+", "+l(this._g)+", "+l(this._b)+")":"rgba("+l(this._r)+", "+l(this._g)+", "+l(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:l(100*R(this._r,255))+"%",g:l(100*R(this._g,255))+"%",b:l(100*R(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+l(100*R(this._r,255))+"%, "+l(100*R(this._g,255))+"%, "+l(100*R(this._b,255))+"%)":"rgba("+l(100*R(this._r,255))+"%, "+l(100*R(this._g,255))+"%, "+l(100*R(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(_[v(this._r,this._g,this._b,!0)]||!1)},toFilter:function(e){var t="#"+m(this._r,this._g,this._b,this._a),n=t,r=this._gradientType?"GradientType = 1, ":"";if(e){var o=d(e);n="#"+m(o._r,o._g,o._b,o._a)}return"progid:DXImageTransform.Microsoft.gradient("+r+"startColorstr="+t+",endColorstr="+n+")"},toString:function(e){var t=!!e;e=e||this._format;var n=!1,r=this._a<1&&this._a>=0;return t||!r||"hex"!==e&&"hex6"!==e&&"hex3"!==e&&"hex4"!==e&&"hex8"!==e&&"name"!==e?("rgb"===e&&(n=this.toRgbString()),"prgb"===e&&(n=this.toPercentageRgbString()),"hex"!==e&&"hex6"!==e||(n=this.toHexString()),"hex3"===e&&(n=this.toHexString(!0)),"hex4"===e&&(n=this.toHex8String(!0)),"hex8"===e&&(n=this.toHex8String()),"name"===e&&(n=this.toName()),"hsl"===e&&(n=this.toHslString()),"hsv"===e&&(n=this.toHsvString()),n||this.toHexString()):"name"===e&&0===this._a?this.toName():this.toRgbString()},clone:function(){return d(this.toString())},_applyModification:function(e,t){var n=e.apply(null,[this].concat([].slice.call(t)));return this._r=n._r,this._g=n._g,this._b=n._b,this.setAlpha(n._a),this},lighten:function(){return this._applyModification(O,arguments)},brighten:function(){return this._applyModification(w,arguments)},darken:function(){return this._applyModification(x,arguments)},desaturate:function(){return this._applyModification(y,arguments)},saturate:function(){return this._applyModification(b,arguments)},greyscale:function(){return this._applyModification(g,arguments)},spin:function(){return this._applyModification(E,arguments)},_applyCombination:function(e,t){return e.apply(null,[this].concat([].slice.call(t)))},analogous:function(){return this._applyCombination(P,arguments)},complement:function(){return this._applyCombination(C,arguments)},monochromatic:function(){return this._applyCombination(N,arguments)},splitcomplement:function(){return this._applyCombination(S,arguments)},triad:function(){return this._applyCombination(k,arguments)},tetrad:function(){return this._applyCombination(j,arguments)}},d.fromRatio=function(e,t){if("object"==typeof e){var n={};for(var r in e)e.hasOwnProperty(r)&&(n[r]="a"===r?e[r]:L(e[r]));e=n}return d(e,t)},d.equals=function(e,t){return!(!e||!t)&&d(e).toRgbString()==d(t).toRgbString()},d.random=function(){return d.fromRatio({r:f(),g:f(),b:f()})},d.mix=function(e,t,n){n=0===n?0:n||50;var r=d(e).toRgb(),o=d(t).toRgb(),a=n/100;return d({r:(o.r-r.r)*a+r.r,g:(o.g-r.g)*a+r.g,b:(o.b-r.b)*a+r.b,a:(o.a-r.a)*a+r.a})},d.readability=function(e,t){var n=d(e),r=d(t);return(o.max(n.getLuminance(),r.getLuminance())+.05)/(o.min(n.getLuminance(),r.getLuminance())+.05)},d.isReadable=function(e,t,n){var r,o,a=d.readability(e,t);switch(o=!1,(r=function(e){var t,n;t=((e=e||{level:"AA",size:"small"}).level||"AA").toUpperCase(),n=(e.size||"small").toLowerCase(),"AA"!==t&&"AAA"!==t&&(t="AA");"small"!==n&&"large"!==n&&(n="small");return{level:t,size:n}}(n)).level+r.size){case"AAsmall":case"AAAlarge":o=a>=4.5;break;case"AAlarge":o=a>=3;break;case"AAAsmall":o=a>=7}return o},d.mostReadable=function(e,t,n){var r,o,a,i,c=null,l=0;o=(n=n||{}).includeFallbackColors,a=n.level,i=n.size;for(var u=0;ul&&(l=r,c=d(t[u]));return d.isReadable(e,c,{level:a,size:i})||!o?c:(n.includeFallbackColors=!1,d.mostReadable(e,["#fff","#000"],n))};var T=d.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},_=d.hexNames=function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[e[n]]=n);return t}(T);function M(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function R(e,t){(function(e){return"string"==typeof e&&-1!=e.indexOf(".")&&1===parseFloat(e)})(e)&&(e="100%");var n=function(e){return"string"===typeof e&&-1!=e.indexOf("%")}(e);return e=u(t,s(0,parseFloat(e))),n&&(e=parseInt(e*t,10)/100),o.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function A(e){return u(1,s(0,e))}function I(e){return parseInt(e,16)}function D(e){return 1==e.length?"0"+e:""+e}function L(e){return e<=1&&(e=100*e+"%"),e}function F(e){return o.round(255*parseFloat(e)).toString(16)}function z(e){return I(e)/255}var K=function(){var e="(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)",t="[\\s|\\(]+("+e+")[,|\\s]+("+e+")[,|\\s]+("+e+")\\s*\\)?",n="[\\s|\\(]+("+e+")[,|\\s]+("+e+")[,|\\s]+("+e+")[,|\\s]+("+e+")\\s*\\)?";return{CSS_UNIT:new RegExp(e),rgb:new RegExp("rgb"+t),rgba:new RegExp("rgba"+n),hsl:new RegExp("hsl"+t),hsla:new RegExp("hsla"+n),hsv:new RegExp("hsv"+t),hsva:new RegExp("hsva"+n),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function V(e){return!!K.CSS_UNIT.exec(e)}e.exports?e.exports=d:void 0===(r=function(){return d}.call(t,n,t,e))||(e.exports=r)}(Math)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.warning=o,t.note=a,t.resetWarned=function(){r={}},t.call=i,t.warningOnce=c,t.noteOnce=function(e,t){i(a,e,t)},t.default=void 0;var r={};function o(e,t){0}function a(e,t){0}function i(e,t,n){t||r[n]||(e(!1,n),r[n]=!0)}function c(e,t){i(o,e,t)}var l=c;t.default=l},function(e,t,n){"use strict";var r=n(29);Object.defineProperty(t,"__esModule",{value:!0}),t.setTwoToneColor=function(e){var t=(0,i.normalizeTwoToneColors)(e),n=(0,o.default)(t,2),r=n[0],c=n[1];return a.default.setTwoToneColors({primaryColor:r,secondaryColor:c})},t.getTwoToneColor=function(){var e=a.default.getTwoToneColors();if(!e.calculated)return e.primaryColor;return[e.primaryColor,e.secondaryColor]};var o=r(n(9)),a=r(n(176)),i=n(149)},function(e,t,n){"use strict";var r=n(29),o=n(33);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=o(n(0)),i=r(n(258)),c=r(n(35)),l=function(e,t){return a.createElement(c.default,Object.assign({},e,{ref:t,icon:i.default}))};l.displayName="CheckCircleFilled";var u=a.forwardRef(l);t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.default={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"}}]},name:"check-circle",theme:"filled"}},function(e,t,n){"use strict";var r=n(29),o=n(33);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=o(n(0)),i=r(n(260)),c=r(n(35)),l=function(e,t){return a.createElement(c.default,Object.assign({},e,{ref:t,icon:i.default}))};l.displayName="CloseCircleFilled";var u=a.forwardRef(l);t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.default={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm165.4 618.2l-66-.3L512 563.4l-99.3 118.4-66.1.3c-4.4 0-8-3.5-8-8 0-1.9.7-3.7 1.9-5.2l130.1-155L340.5 359a8.32 8.32 0 01-1.9-5.2c0-4.4 3.6-8 8-8l66.1.3L512 464.6l99.3-118.4 66-.3c4.4 0 8 3.5 8 8 0 1.9-.7 3.7-1.9 5.2L553.5 514l130 155c1.2 1.5 1.9 3.3 1.9 5.2 0 4.4-3.6 8-8 8z"}}]},name:"close-circle",theme:"filled"}},function(e,t,n){"use strict";var r=n(29),o=n(33);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=o(n(0)),i=r(n(262)),c=r(n(35)),l=function(e,t){return a.createElement(c.default,Object.assign({},e,{ref:t,icon:i.default}))};l.displayName="ExclamationCircleFilled";var u=a.forwardRef(l);t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.default={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"exclamation-circle",theme:"filled"}},function(e,t,n){"use strict";var r=n(29),o=n(33);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=o(n(0)),i=r(n(264)),c=r(n(35)),l=function(e,t){return a.createElement(c.default,Object.assign({},e,{ref:t,icon:i.default}))};l.displayName="LoadingOutlined";var u=a.forwardRef(l);t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.default={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"}},function(e,t){function n(t,r){return e.exports=n=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},n(t,r)}e.exports=n},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(t)}e.exports=n},function(e,t){e.exports=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(e){return!1}}},function(e,t,n){var r=n(23),o=n(75);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!==typeof t?o(e):t}},function(e,t,n){"use strict";var r=n(270);function o(){}function a(){}a.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,a,i){if(i!==r){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:a,resetWarningCache:o};return n.PropTypes=n,n}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t){e.exports=Array.isArray||function(e){return"[object Array]"==Object.prototype.toString.call(e)}},function(e,t,n){"use strict";var r="function"===typeof Symbol&&Symbol.for,o=r?Symbol.for("react.element"):60103,a=r?Symbol.for("react.portal"):60106,i=r?Symbol.for("react.fragment"):60107,c=r?Symbol.for("react.strict_mode"):60108,l=r?Symbol.for("react.profiler"):60114,u=r?Symbol.for("react.provider"):60109,s=r?Symbol.for("react.context"):60110,f=r?Symbol.for("react.async_mode"):60111,d=r?Symbol.for("react.concurrent_mode"):60111,p=r?Symbol.for("react.forward_ref"):60112,h=r?Symbol.for("react.suspense"):60113,v=r?Symbol.for("react.suspense_list"):60120,m=r?Symbol.for("react.memo"):60115,y=r?Symbol.for("react.lazy"):60116,b=r?Symbol.for("react.block"):60121,g=r?Symbol.for("react.fundamental"):60117,O=r?Symbol.for("react.responder"):60118,w=r?Symbol.for("react.scope"):60119;function x(e){if("object"===typeof e&&null!==e){var t=e.$$typeof;switch(t){case o:switch(e=e.type){case f:case d:case i:case l:case c:case h:return e;default:switch(e=e&&e.$$typeof){case s:case p:case y:case m:case u:return e;default:return t}}case a:return t}}}function E(e){return x(e)===d}t.AsyncMode=f,t.ConcurrentMode=d,t.ContextConsumer=s,t.ContextProvider=u,t.Element=o,t.ForwardRef=p,t.Fragment=i,t.Lazy=y,t.Memo=m,t.Portal=a,t.Profiler=l,t.StrictMode=c,t.Suspense=h,t.isAsyncMode=function(e){return E(e)||x(e)===f},t.isConcurrentMode=E,t.isContextConsumer=function(e){return x(e)===s},t.isContextProvider=function(e){return x(e)===u},t.isElement=function(e){return"object"===typeof e&&null!==e&&e.$$typeof===o},t.isForwardRef=function(e){return x(e)===p},t.isFragment=function(e){return x(e)===i},t.isLazy=function(e){return x(e)===y},t.isMemo=function(e){return x(e)===m},t.isPortal=function(e){return x(e)===a},t.isProfiler=function(e){return x(e)===l},t.isStrictMode=function(e){return x(e)===c},t.isSuspense=function(e){return x(e)===h},t.isValidElementType=function(e){return"string"===typeof e||"function"===typeof e||e===i||e===d||e===l||e===c||e===h||e===v||"object"===typeof e&&null!==e&&(e.$$typeof===y||e.$$typeof===m||e.$$typeof===u||e.$$typeof===s||e.$$typeof===p||e.$$typeof===g||e.$$typeof===O||e.$$typeof===w||e.$$typeof===b)},t.typeOf=x},function(e,t,n){var r=n(173);e.exports=function(e){if(Array.isArray(e))return r(e)}},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}},function(e,t,n){var r=n(276),o=n(108);e.exports=function e(t,n,a,i,c){return t===n||(null==t||null==n||!o(t)&&!o(n)?t!==t&&n!==n:r(t,n,a,i,e,c))}},function(e,t,n){var r=n(277),o=n(184),a=n(311),i=n(315),c=n(337),l=n(152),u=n(185),s=n(187),f="[object Object]",d=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,p,h,v){var m=l(e),y=l(t),b=m?"[object Array]":c(e),g=y?"[object Array]":c(t),O=(b="[object Arguments]"==b?f:b)==f,w=(g="[object Arguments]"==g?f:g)==f,x=b==g;if(x&&u(e)){if(!u(t))return!1;m=!0,O=!1}if(x&&!O)return v||(v=new r),m||s(e)?o(e,t,n,p,h,v):a(e,t,b,n,p,h,v);if(!(1&n)){var E=O&&d.call(e,"__wrapped__"),C=w&&d.call(t,"__wrapped__");if(E||C){var k=E?e.value():e,j=C?t.value():t;return v||(v=new r),h(k,j,n,p,v)}}return!!x&&(v||(v=new r),i(e,t,n,p,h,v))}},function(e,t,n){var r=n(119),o=n(283),a=n(284),i=n(285),c=n(286),l=n(287);function u(e){var t=this.__data__=new r(e);this.size=t.size}u.prototype.clear=o,u.prototype.delete=a,u.prototype.get=i,u.prototype.has=c,u.prototype.set=l,e.exports=u},function(e,t){e.exports=function(){this.__data__=[],this.size=0}},function(e,t,n){var r=n(120),o=Array.prototype.splice;e.exports=function(e){var t=this.__data__,n=r(t,e);return!(n<0)&&(n==t.length-1?t.pop():o.call(t,n,1),--this.size,!0)}},function(e,t,n){var r=n(120);e.exports=function(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}},function(e,t,n){var r=n(120);e.exports=function(e){return r(this.__data__,e)>-1}},function(e,t,n){var r=n(120);e.exports=function(e,t){var n=this.__data__,o=r(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}},function(e,t,n){var r=n(119);e.exports=function(){this.__data__=new r,this.size=0}},function(e,t){e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},function(e,t){e.exports=function(e){return this.__data__.get(e)}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t,n){var r=n(119),o=n(150),a=n(183);e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var i=n.__data__;if(!o||i.length<199)return i.push([e,t]),this.size=++n.size,this;n=this.__data__=new a(i)}return n.set(e,t),this.size=n.size,this}},function(e,t,n){var r=n(180),o=n(291),a=n(121),i=n(182),c=/^\[object .+?Constructor\]$/,l=Function.prototype,u=Object.prototype,s=l.toString,f=u.hasOwnProperty,d=RegExp("^"+s.call(f).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!a(e)||o(e))&&(r(e)?d:c).test(i(e))}},function(e,t,n){var r=n(151),o=Object.prototype,a=o.hasOwnProperty,i=o.toString,c=r?r.toStringTag:void 0;e.exports=function(e){var t=a.call(e,c),n=e[c];try{e[c]=void 0;var r=!0}catch(l){}var o=i.call(e);return r&&(t?e[c]=n:delete e[c]),o}},function(e,t){var n=Object.prototype.toString;e.exports=function(e){return n.call(e)}},function(e,t,n){var r=n(292),o=function(){var e=/[^.]+$/.exec(r&&r.keys&&r.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();e.exports=function(e){return!!o&&o in e}},function(e,t,n){var r=n(64)["__core-js_shared__"];e.exports=r},function(e,t){e.exports=function(e,t){return null==e?void 0:e[t]}},function(e,t,n){var r=n(295),o=n(119),a=n(150);e.exports=function(){this.size=0,this.__data__={hash:new r,map:new(a||o),string:new r}}},function(e,t,n){var r=n(296),o=n(297),a=n(298),i=n(299),c=n(300);function l(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t-1&&e%1==0&&e= 0) continue;\n if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n target[key] = source[key];\n }\n }\n\n return target;\n}","export default function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nexport default function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}","export default function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}","/**\n * @ignore\n * some key-codes definition and utils from closure-library\n * @author yiminghe@gmail.com\n */\nvar KeyCode = {\n /**\n * MAC_ENTER\n */\n MAC_ENTER: 3,\n\n /**\n * BACKSPACE\n */\n BACKSPACE: 8,\n\n /**\n * TAB\n */\n TAB: 9,\n\n /**\n * NUMLOCK on FF/Safari Mac\n */\n NUM_CENTER: 12,\n\n /**\n * ENTER\n */\n ENTER: 13,\n\n /**\n * SHIFT\n */\n SHIFT: 16,\n\n /**\n * CTRL\n */\n CTRL: 17,\n\n /**\n * ALT\n */\n ALT: 18,\n\n /**\n * PAUSE\n */\n PAUSE: 19,\n\n /**\n * CAPS_LOCK\n */\n CAPS_LOCK: 20,\n\n /**\n * ESC\n */\n ESC: 27,\n\n /**\n * SPACE\n */\n SPACE: 32,\n\n /**\n * PAGE_UP\n */\n PAGE_UP: 33,\n\n /**\n * PAGE_DOWN\n */\n PAGE_DOWN: 34,\n\n /**\n * END\n */\n END: 35,\n\n /**\n * HOME\n */\n HOME: 36,\n\n /**\n * LEFT\n */\n LEFT: 37,\n\n /**\n * UP\n */\n UP: 38,\n\n /**\n * RIGHT\n */\n RIGHT: 39,\n\n /**\n * DOWN\n */\n DOWN: 40,\n\n /**\n * PRINT_SCREEN\n */\n PRINT_SCREEN: 44,\n\n /**\n * INSERT\n */\n INSERT: 45,\n\n /**\n * DELETE\n */\n DELETE: 46,\n\n /**\n * ZERO\n */\n ZERO: 48,\n\n /**\n * ONE\n */\n ONE: 49,\n\n /**\n * TWO\n */\n TWO: 50,\n\n /**\n * THREE\n */\n THREE: 51,\n\n /**\n * FOUR\n */\n FOUR: 52,\n\n /**\n * FIVE\n */\n FIVE: 53,\n\n /**\n * SIX\n */\n SIX: 54,\n\n /**\n * SEVEN\n */\n SEVEN: 55,\n\n /**\n * EIGHT\n */\n EIGHT: 56,\n\n /**\n * NINE\n */\n NINE: 57,\n\n /**\n * QUESTION_MARK\n */\n QUESTION_MARK: 63,\n\n /**\n * A\n */\n A: 65,\n\n /**\n * B\n */\n B: 66,\n\n /**\n * C\n */\n C: 67,\n\n /**\n * D\n */\n D: 68,\n\n /**\n * E\n */\n E: 69,\n\n /**\n * F\n */\n F: 70,\n\n /**\n * G\n */\n G: 71,\n\n /**\n * H\n */\n H: 72,\n\n /**\n * I\n */\n I: 73,\n\n /**\n * J\n */\n J: 74,\n\n /**\n * K\n */\n K: 75,\n\n /**\n * L\n */\n L: 76,\n\n /**\n * M\n */\n M: 77,\n\n /**\n * N\n */\n N: 78,\n\n /**\n * O\n */\n O: 79,\n\n /**\n * P\n */\n P: 80,\n\n /**\n * Q\n */\n Q: 81,\n\n /**\n * R\n */\n R: 82,\n\n /**\n * S\n */\n S: 83,\n\n /**\n * T\n */\n T: 84,\n\n /**\n * U\n */\n U: 85,\n\n /**\n * V\n */\n V: 86,\n\n /**\n * W\n */\n W: 87,\n\n /**\n * X\n */\n X: 88,\n\n /**\n * Y\n */\n Y: 89,\n\n /**\n * Z\n */\n Z: 90,\n\n /**\n * META\n */\n META: 91,\n\n /**\n * WIN_KEY_RIGHT\n */\n WIN_KEY_RIGHT: 92,\n\n /**\n * CONTEXT_MENU\n */\n CONTEXT_MENU: 93,\n\n /**\n * NUM_ZERO\n */\n NUM_ZERO: 96,\n\n /**\n * NUM_ONE\n */\n NUM_ONE: 97,\n\n /**\n * NUM_TWO\n */\n NUM_TWO: 98,\n\n /**\n * NUM_THREE\n */\n NUM_THREE: 99,\n\n /**\n * NUM_FOUR\n */\n NUM_FOUR: 100,\n\n /**\n * NUM_FIVE\n */\n NUM_FIVE: 101,\n\n /**\n * NUM_SIX\n */\n NUM_SIX: 102,\n\n /**\n * NUM_SEVEN\n */\n NUM_SEVEN: 103,\n\n /**\n * NUM_EIGHT\n */\n NUM_EIGHT: 104,\n\n /**\n * NUM_NINE\n */\n NUM_NINE: 105,\n\n /**\n * NUM_MULTIPLY\n */\n NUM_MULTIPLY: 106,\n\n /**\n * NUM_PLUS\n */\n NUM_PLUS: 107,\n\n /**\n * NUM_MINUS\n */\n NUM_MINUS: 109,\n\n /**\n * NUM_PERIOD\n */\n NUM_PERIOD: 110,\n\n /**\n * NUM_DIVISION\n */\n NUM_DIVISION: 111,\n\n /**\n * F1\n */\n F1: 112,\n\n /**\n * F2\n */\n F2: 113,\n\n /**\n * F3\n */\n F3: 114,\n\n /**\n * F4\n */\n F4: 115,\n\n /**\n * F5\n */\n F5: 116,\n\n /**\n * F6\n */\n F6: 117,\n\n /**\n * F7\n */\n F7: 118,\n\n /**\n * F8\n */\n F8: 119,\n\n /**\n * F9\n */\n F9: 120,\n\n /**\n * F10\n */\n F10: 121,\n\n /**\n * F11\n */\n F11: 122,\n\n /**\n * F12\n */\n F12: 123,\n\n /**\n * NUMLOCK\n */\n NUMLOCK: 144,\n\n /**\n * SEMICOLON\n */\n SEMICOLON: 186,\n\n /**\n * DASH\n */\n DASH: 189,\n\n /**\n * EQUALS\n */\n EQUALS: 187,\n\n /**\n * COMMA\n */\n COMMA: 188,\n\n /**\n * PERIOD\n */\n PERIOD: 190,\n\n /**\n * SLASH\n */\n SLASH: 191,\n\n /**\n * APOSTROPHE\n */\n APOSTROPHE: 192,\n\n /**\n * SINGLE_QUOTE\n */\n SINGLE_QUOTE: 222,\n\n /**\n * OPEN_SQUARE_BRACKET\n */\n OPEN_SQUARE_BRACKET: 219,\n\n /**\n * BACKSLASH\n */\n BACKSLASH: 220,\n\n /**\n * CLOSE_SQUARE_BRACKET\n */\n CLOSE_SQUARE_BRACKET: 221,\n\n /**\n * WIN_KEY\n */\n WIN_KEY: 224,\n\n /**\n * MAC_FF_META\n */\n MAC_FF_META: 224,\n\n /**\n * WIN_IME\n */\n WIN_IME: 229,\n // ======================== Function ========================\n\n /**\n * whether text and modified key is entered at the same time.\n */\n isTextModifyingKeyEvent: function isTextModifyingKeyEvent(e) {\n var keyCode = e.keyCode;\n\n if (e.altKey && !e.ctrlKey || e.metaKey || // Function keys don't generate text\n keyCode >= KeyCode.F1 && keyCode <= KeyCode.F12) {\n return false;\n } // The following keys are quite harmless, even in combination with\n // CTRL, ALT or SHIFT.\n\n\n switch (keyCode) {\n case KeyCode.ALT:\n case KeyCode.CAPS_LOCK:\n case KeyCode.CONTEXT_MENU:\n case KeyCode.CTRL:\n case KeyCode.DOWN:\n case KeyCode.END:\n case KeyCode.ESC:\n case KeyCode.HOME:\n case KeyCode.INSERT:\n case KeyCode.LEFT:\n case KeyCode.MAC_FF_META:\n case KeyCode.META:\n case KeyCode.NUMLOCK:\n case KeyCode.NUM_CENTER:\n case KeyCode.PAGE_DOWN:\n case KeyCode.PAGE_UP:\n case KeyCode.PAUSE:\n case KeyCode.PRINT_SCREEN:\n case KeyCode.RIGHT:\n case KeyCode.SHIFT:\n case KeyCode.UP:\n case KeyCode.WIN_KEY:\n case KeyCode.WIN_KEY_RIGHT:\n return false;\n\n default:\n return true;\n }\n },\n\n /**\n * whether character is entered.\n */\n isCharacterKey: function isCharacterKey(keyCode) {\n if (keyCode >= KeyCode.ZERO && keyCode <= KeyCode.NINE) {\n return true;\n }\n\n if (keyCode >= KeyCode.NUM_ZERO && keyCode <= KeyCode.NUM_MULTIPLY) {\n return true;\n }\n\n if (keyCode >= KeyCode.A && keyCode <= KeyCode.Z) {\n return true;\n } // Safari sends zero key code for non-latin characters.\n\n\n if (window.navigator.userAgent.indexOf('WebKit') !== -1 && keyCode === 0) {\n return true;\n }\n\n switch (keyCode) {\n case KeyCode.SPACE:\n case KeyCode.QUESTION_MARK:\n case KeyCode.NUM_PLUS:\n case KeyCode.NUM_MINUS:\n case KeyCode.NUM_PERIOD:\n case KeyCode.NUM_DIVISION:\n case KeyCode.SEMICOLON:\n case KeyCode.DASH:\n case KeyCode.EQUALS:\n case KeyCode.COMMA:\n case KeyCode.PERIOD:\n case KeyCode.SLASH:\n case KeyCode.APOSTROPHE:\n case KeyCode.SINGLE_QUOTE:\n case KeyCode.OPEN_SQUARE_BRACKET:\n case KeyCode.BACKSLASH:\n case KeyCode.CLOSE_SQUARE_BRACKET:\n return true;\n\n default:\n return false;\n }\n }\n};\nexport default KeyCode;","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf\";\nexport default function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n if (superClass) setPrototypeOf(subClass, superClass);\n}","'use strict';\n\nfunction checkDCE() {\n /* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */\n if (\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined' ||\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE !== 'function'\n ) {\n return;\n }\n if (process.env.NODE_ENV !== 'production') {\n // This branch is unreachable because this function is only called\n // in production, but the condition is true only in development.\n // Therefore if the branch is still here, dead code elimination wasn't\n // properly applied.\n // Don't change the message. React DevTools relies on it. Also make sure\n // this message doesn't occur elsewhere in this function, or it will cause\n // a false positive.\n throw new Error('^_^');\n }\n try {\n // Verify that the code above has been dead code eliminated (DCE'd).\n __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(checkDCE);\n } catch (err) {\n // DevTools shouldn't crash React, no matter what.\n // We should still report in case we break this code.\n console.error(err);\n }\n}\n\nif (process.env.NODE_ENV === 'production') {\n // DCE check should happen before ReactDOM bundle executes so that\n // DevTools can report bad minification during injection.\n checkDCE();\n module.exports = require('./cjs/react-dom.production.min.js');\n} else {\n module.exports = require('./cjs/react-dom.development.js');\n}\n","import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport toArray from \"rc-util/es/Children/toArray\";\nimport warning from \"rc-util/es/warning\";\nimport { getPosition, isTreeNode } from '../util';\nexport function getKey(key, pos) {\n if (key !== null && key !== undefined) {\n return key;\n }\n\n return pos;\n}\n/**\n * Warning if TreeNode do not provides key\n */\n\nexport function warningWithoutKey() {\n var treeData = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n var keys = new Map();\n\n function dig(list) {\n var path = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n (list || []).forEach(function (treeNode) {\n var key = treeNode.key,\n children = treeNode.children;\n warning(key !== null && key !== undefined, \"Tree node must have a certain key: [\".concat(path).concat(key, \"]\"));\n var recordKey = String(key);\n warning(!keys.has(recordKey) || key === null || key === undefined, \"Same 'key' exist in the Tree: \".concat(recordKey));\n keys.set(recordKey, true);\n dig(children, \"\".concat(path).concat(recordKey, \" > \"));\n });\n }\n\n dig(treeData);\n}\n/**\n * Convert `children` of Tree into `treeData` structure.\n */\n\nexport function convertTreeToData(rootNodes) {\n function dig(node) {\n var treeNodes = toArray(node);\n return treeNodes.map(function (treeNode) {\n // Filter invalidate node\n if (!isTreeNode(treeNode)) {\n warning(!treeNode, 'Tree/TreeNode can only accept TreeNode as children.');\n return null;\n }\n\n var key = treeNode.key;\n\n var _treeNode$props = treeNode.props,\n children = _treeNode$props.children,\n rest = _objectWithoutProperties(_treeNode$props, [\"children\"]);\n\n var dataNode = _objectSpread({\n key: key\n }, rest);\n\n var parsedChildren = dig(children);\n\n if (parsedChildren.length) {\n dataNode.children = parsedChildren;\n }\n\n return dataNode;\n }).filter(function (dataNode) {\n return dataNode;\n });\n }\n\n return dig(rootNodes);\n}\n/**\n * Flat nest tree data into flatten list. This is used for virtual list render.\n * @param treeNodeList Origin data node list\n * @param expandedKeys\n * need expanded keys, provides `true` means all expanded (used in `rc-tree-select`).\n */\n\nexport function flattenTreeData() {\n var treeNodeList = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n var expandedKeys = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];\n var expandedKeySet = new Set(expandedKeys === true ? [] : expandedKeys);\n var flattenList = [];\n\n function dig(list) {\n var parent = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n return list.map(function (treeNode, index) {\n var pos = getPosition(parent ? parent.pos : '0', index);\n var mergedKey = getKey(treeNode.key, pos); // Add FlattenDataNode into list\n\n var flattenNode = _objectSpread(_objectSpread({}, treeNode), {}, {\n parent: parent,\n pos: pos,\n children: null,\n data: treeNode,\n isStart: [].concat(_toConsumableArray(parent ? parent.isStart : []), [index === 0]),\n isEnd: [].concat(_toConsumableArray(parent ? parent.isEnd : []), [index === list.length - 1])\n });\n\n flattenList.push(flattenNode); // Loop treeNode children\n\n if (expandedKeys === true || expandedKeySet.has(mergedKey)) {\n flattenNode.children = dig(treeNode.children || [], flattenNode);\n } else {\n flattenNode.children = [];\n }\n\n return flattenNode;\n });\n }\n\n dig(treeNodeList);\n return flattenList;\n}\n/**\n * Traverse all the data by `treeData`.\n * Please not use it out of the `rc-tree` since we may refactor this code.\n */\n\nexport function traverseDataNodes(dataNodes, callback, externalGetKey) {\n var syntheticGetKey;\n\n if (externalGetKey) {\n if (typeof externalGetKey === 'string') {\n syntheticGetKey = function syntheticGetKey(node) {\n return node[externalGetKey];\n };\n } else if (typeof externalGetKey === 'function') {\n syntheticGetKey = function syntheticGetKey(node) {\n return externalGetKey(node);\n };\n }\n } else {\n syntheticGetKey = function syntheticGetKey(node, pos) {\n return getKey(node.key, pos);\n };\n }\n\n function processNode(node, index, parent) {\n var children = node ? node.children : dataNodes;\n var pos = node ? getPosition(parent.pos, index) : '0'; // Process node if is not root\n\n if (node) {\n var key = syntheticGetKey(node, pos);\n var data = {\n node: node,\n index: index,\n pos: pos,\n key: key,\n parentPos: parent.node ? parent.pos : null,\n level: parent.level + 1\n };\n callback(data);\n } // Process children node\n\n\n if (children) {\n children.forEach(function (subNode, subIndex) {\n processNode(subNode, subIndex, {\n node: node,\n pos: pos,\n level: parent ? parent.level + 1 : -1\n });\n });\n }\n }\n\n processNode(null);\n}\n/**\n * Convert `treeData` into entity records.\n */\n\nexport function convertDataToEntities(dataNodes) {\n var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n initWrapper = _ref.initWrapper,\n processEntity = _ref.processEntity,\n onProcessFinished = _ref.onProcessFinished;\n\n var externalGetKey = arguments.length > 2 ? arguments[2] : undefined;\n var posEntities = {};\n var keyEntities = {};\n var wrapper = {\n posEntities: posEntities,\n keyEntities: keyEntities\n };\n\n if (initWrapper) {\n wrapper = initWrapper(wrapper) || wrapper;\n }\n\n traverseDataNodes(dataNodes, function (item) {\n var node = item.node,\n index = item.index,\n pos = item.pos,\n key = item.key,\n parentPos = item.parentPos,\n level = item.level;\n var entity = {\n node: node,\n index: index,\n key: key,\n pos: pos,\n level: level\n };\n var mergedKey = getKey(key, pos);\n posEntities[pos] = entity;\n keyEntities[mergedKey] = entity; // Fill children\n\n entity.parent = posEntities[parentPos];\n\n if (entity.parent) {\n entity.parent.children = entity.parent.children || [];\n entity.parent.children.push(entity);\n }\n\n if (processEntity) {\n processEntity(entity, wrapper);\n }\n }, externalGetKey);\n\n if (onProcessFinished) {\n onProcessFinished(wrapper);\n }\n\n return wrapper;\n}\n/**\n * Get TreeNode props with Tree props.\n */\n\nexport function getTreeNodeProps(key, _ref2) {\n var expandedKeys = _ref2.expandedKeys,\n selectedKeys = _ref2.selectedKeys,\n loadedKeys = _ref2.loadedKeys,\n loadingKeys = _ref2.loadingKeys,\n checkedKeys = _ref2.checkedKeys,\n halfCheckedKeys = _ref2.halfCheckedKeys,\n dragOverNodeKey = _ref2.dragOverNodeKey,\n dropPosition = _ref2.dropPosition,\n keyEntities = _ref2.keyEntities;\n var entity = keyEntities[key];\n var treeNodeProps = {\n eventKey: key,\n expanded: expandedKeys.indexOf(key) !== -1,\n selected: selectedKeys.indexOf(key) !== -1,\n loaded: loadedKeys.indexOf(key) !== -1,\n loading: loadingKeys.indexOf(key) !== -1,\n checked: checkedKeys.indexOf(key) !== -1,\n halfChecked: halfCheckedKeys.indexOf(key) !== -1,\n pos: String(entity ? entity.pos : ''),\n // [Legacy] Drag props\n dragOver: dragOverNodeKey === key && dropPosition === 0,\n dragOverGapTop: dragOverNodeKey === key && dropPosition === -1,\n dragOverGapBottom: dragOverNodeKey === key && dropPosition === 1\n };\n return treeNodeProps;\n}\nexport function convertNodePropsToEventData(props) {\n var data = props.data,\n expanded = props.expanded,\n selected = props.selected,\n checked = props.checked,\n loaded = props.loaded,\n loading = props.loading,\n halfChecked = props.halfChecked,\n dragOver = props.dragOver,\n dragOverGapTop = props.dragOverGapTop,\n dragOverGapBottom = props.dragOverGapBottom,\n pos = props.pos,\n active = props.active;\n\n var eventData = _objectSpread(_objectSpread({}, data), {}, {\n expanded: expanded,\n selected: selected,\n checked: checked,\n loaded: loaded,\n loading: loading,\n halfChecked: halfChecked,\n dragOver: dragOver,\n dragOverGapTop: dragOverGapTop,\n dragOverGapBottom: dragOverGapBottom,\n pos: pos,\n active: active\n });\n\n if (!('props' in eventData)) {\n Object.defineProperty(eventData, 'props', {\n get: function get() {\n warning(false, 'Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`.');\n return props;\n }\n });\n }\n\n return eventData;\n}","import devWarning, { resetWarned } from \"rc-util/es/warning\";\nexport { resetWarned };\nexport default (function (valid, component, message) {\n devWarning(valid, \"[antd: \".concat(component, \"] \").concat(message));\n});","export default function _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n}","function omit(obj, fields) {\n // eslint-disable-next-line prefer-object-spread\n var shallowCopy = Object.assign({}, obj);\n\n for (var i = 0; i < fields.length; i += 1) {\n var key = fields[i];\n delete shallowCopy[key];\n }\n\n return shallowCopy;\n}\n\nexport default omit;","function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\n\nmodule.exports = _classCallCheck;","function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n module.exports = _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n module.exports = _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}\n\nmodule.exports = _typeof;","import * as React from 'react';\nvar isValidElement = React.isValidElement;\nexport { isValidElement };\nexport function replaceElement(element, replacement, props) {\n if (!isValidElement(element)) return replacement;\n return /*#__PURE__*/React.cloneElement(element, typeof props === 'function' ? props() : props);\n}\nexport function cloneElement(element, props) {\n return replaceElement(element, element, props);\n}","import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\n\n/**\n * Legacy code. Should avoid to use if you are new to import these code.\n */\nimport React from 'react';\nimport warning from \"rc-util/es/warning\";\nimport TreeNode from './TreeNode';\nvar DRAG_SIDE_RANGE = 0.25;\nvar DRAG_MIN_GAP = 2;\nexport function arrDel(list, value) {\n var clone = list.slice();\n var index = clone.indexOf(value);\n\n if (index >= 0) {\n clone.splice(index, 1);\n }\n\n return clone;\n}\nexport function arrAdd(list, value) {\n var clone = list.slice();\n\n if (clone.indexOf(value) === -1) {\n clone.push(value);\n }\n\n return clone;\n}\nexport function posToArr(pos) {\n return pos.split('-');\n}\nexport function getPosition(level, index) {\n return \"\".concat(level, \"-\").concat(index);\n}\nexport function isTreeNode(node) {\n return node && node.type && node.type.isTreeNode;\n}\nexport function getDragNodesKeys(dragNodeKey, keyEntities) {\n var dragNodesKeys = [dragNodeKey];\n var entity = keyEntities[dragNodeKey];\n\n function dig() {\n var list = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n list.forEach(function (_ref) {\n var key = _ref.key,\n children = _ref.children;\n dragNodesKeys.push(key);\n dig(children);\n });\n }\n\n dig(entity.children);\n return dragNodesKeys;\n} // Only used when drag, not affect SSR.\n\nexport function calcDropPosition(event, treeNode) {\n var clientY = event.clientY;\n\n var _treeNode$selectHandl = treeNode.selectHandle.getBoundingClientRect(),\n top = _treeNode$selectHandl.top,\n bottom = _treeNode$selectHandl.bottom,\n height = _treeNode$selectHandl.height;\n\n var des = Math.max(height * DRAG_SIDE_RANGE, DRAG_MIN_GAP);\n\n if (clientY <= top + des) {\n return -1;\n }\n\n if (clientY >= bottom - des) {\n return 1;\n }\n\n return 0;\n}\n/**\n * Return selectedKeys according with multiple prop\n * @param selectedKeys\n * @param props\n * @returns [string]\n */\n\nexport function calcSelectedKeys(selectedKeys, props) {\n if (!selectedKeys) return undefined;\n var multiple = props.multiple;\n\n if (multiple) {\n return selectedKeys.slice();\n }\n\n if (selectedKeys.length) {\n return [selectedKeys[0]];\n }\n\n return selectedKeys;\n}\n\nvar internalProcessProps = function internalProcessProps(props) {\n return props;\n};\n\nexport function convertDataToTree(treeData, processor) {\n if (!treeData) return [];\n\n var _ref2 = processor || {},\n _ref2$processProps = _ref2.processProps,\n processProps = _ref2$processProps === void 0 ? internalProcessProps : _ref2$processProps;\n\n var list = Array.isArray(treeData) ? treeData : [treeData];\n return list.map(function (_ref3) {\n var children = _ref3.children,\n props = _objectWithoutProperties(_ref3, [\"children\"]);\n\n var childrenNodes = convertDataToTree(children, processor);\n return React.createElement(TreeNode, Object.assign({}, processProps(props)), childrenNodes);\n });\n}\n/**\n * Parse `checkedKeys` to { checkedKeys, halfCheckedKeys } style\n */\n\nexport function parseCheckedKeys(keys) {\n if (!keys) {\n return null;\n } // Convert keys to object format\n\n\n var keyProps;\n\n if (Array.isArray(keys)) {\n // [Legacy] Follow the api doc\n keyProps = {\n checkedKeys: keys,\n halfCheckedKeys: undefined\n };\n } else if (_typeof(keys) === 'object') {\n keyProps = {\n checkedKeys: keys.checked || undefined,\n halfCheckedKeys: keys.halfChecked || undefined\n };\n } else {\n warning(false, '`checkedKeys` is not an array or an object');\n return null;\n }\n\n return keyProps;\n}\n/**\n * If user use `autoExpandParent` we should get the list of parent node\n * @param keyList\n * @param keyEntities\n */\n\nexport function conductExpandParent(keyList, keyEntities) {\n var expandedKeys = new Set();\n\n function conductUp(key) {\n if (expandedKeys.has(key)) return;\n var entity = keyEntities[key];\n if (!entity) return;\n expandedKeys.add(key);\n var parent = entity.parent,\n node = entity.node;\n if (node.disabled) return;\n\n if (parent) {\n conductUp(parent.key);\n }\n }\n\n (keyList || []).forEach(function (key) {\n conductUp(key);\n });\n return _toConsumableArray(expandedKeys);\n}\n/**\n * Returns only the data- and aria- key/value pairs\n */\n\nexport function getDataAndAria(props) {\n var omitProps = {};\n Object.keys(props).forEach(function (key) {\n if (key.startsWith('data-') || key.startsWith('aria-')) {\n omitProps[key] = props[key];\n }\n });\n return omitProps;\n}","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nfunction _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}\n\nmodule.exports = _createClass;","var setPrototypeOf = require(\"./setPrototypeOf\");\n\nfunction _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n if (superClass) setPrototypeOf(subClass, superClass);\n}\n\nmodule.exports = _inherits;","var getPrototypeOf = require(\"./getPrototypeOf\");\n\nvar isNativeReflectConstruct = require(\"./isNativeReflectConstruct\");\n\nvar possibleConstructorReturn = require(\"./possibleConstructorReturn\");\n\nfunction _createSuper(Derived) {\n var hasNativeReflectConstruct = isNativeReflectConstruct();\n return function _createSuperInternal() {\n var Super = getPrototypeOf(Derived),\n result;\n\n if (hasNativeReflectConstruct) {\n var NewTarget = getPrototypeOf(this).constructor;\n result = Reflect.construct(Super, arguments, NewTarget);\n } else {\n result = Super.apply(this, arguments);\n }\n\n return possibleConstructorReturn(this, result);\n };\n}\n\nmodule.exports = _createSuper;","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\n\nmodule.exports = _interopRequireDefault;","import getPrototypeOf from \"./getPrototypeOf\";\nimport isNativeReflectConstruct from \"./isNativeReflectConstruct\";\nimport possibleConstructorReturn from \"./possibleConstructorReturn\";\nexport default function _createSuper(Derived) {\n var hasNativeReflectConstruct = isNativeReflectConstruct();\n return function _createSuperInternal() {\n var Super = getPrototypeOf(Derived),\n result;\n\n if (hasNativeReflectConstruct) {\n var NewTarget = getPrototypeOf(this).constructor;\n result = Reflect.construct(Super, arguments, NewTarget);\n } else {\n result = Super.apply(this, arguments);\n }\n\n return possibleConstructorReturn(this, result);\n };\n}","export default function _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n\n try {\n Date.prototype.toString.call(Reflect.construct(Date, [], function () {}));\n return true;\n } catch (e) {\n return false;\n }\n}","var arrayWithoutHoles = require(\"./arrayWithoutHoles\");\n\nvar iterableToArray = require(\"./iterableToArray\");\n\nvar unsupportedIterableToArray = require(\"./unsupportedIterableToArray\");\n\nvar nonIterableSpread = require(\"./nonIterableSpread\");\n\nfunction _toConsumableArray(arr) {\n return arrayWithoutHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableSpread();\n}\n\nmodule.exports = _toConsumableArray;","import Button from './button';\nexport default Button;","var _typeof = require(\"../helpers/typeof\");\n\nfunction _getRequireWildcardCache() {\n if (typeof WeakMap !== \"function\") return null;\n var cache = new WeakMap();\n\n _getRequireWildcardCache = function _getRequireWildcardCache() {\n return cache;\n };\n\n return cache;\n}\n\nfunction _interopRequireWildcard(obj) {\n if (obj && obj.__esModule) {\n return obj;\n }\n\n if (obj === null || _typeof(obj) !== \"object\" && typeof obj !== \"function\") {\n return {\n \"default\": obj\n };\n }\n\n var cache = _getRequireWildcardCache();\n\n if (cache && cache.has(obj)) {\n return cache.get(obj);\n }\n\n var newObj = {};\n var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;\n\n for (var key in obj) {\n if (Object.prototype.hasOwnProperty.call(obj, key)) {\n var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;\n\n if (desc && (desc.get || desc.set)) {\n Object.defineProperty(newObj, key, desc);\n } else {\n newObj[key] = obj[key];\n }\n }\n }\n\n newObj[\"default\"] = obj;\n\n if (cache) {\n cache.set(obj, newObj);\n }\n\n return newObj;\n}\n\nmodule.exports = _interopRequireWildcard;","export default function _extends() {\n _extends = Object.assign || function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n\n return target;\n };\n\n return _extends.apply(this, arguments);\n}","\"use strict\";\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _slicedToArray2 = _interopRequireDefault(require(\"@babel/runtime/helpers/slicedToArray\"));\n\nvar _defineProperty2 = _interopRequireDefault(require(\"@babel/runtime/helpers/defineProperty\"));\n\nvar _objectWithoutProperties2 = _interopRequireDefault(require(\"@babel/runtime/helpers/objectWithoutProperties\"));\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _classnames = _interopRequireDefault(require(\"classnames\"));\n\nvar _IconBase = _interopRequireDefault(require(\"./IconBase\"));\n\nvar _twoTonePrimaryColor = require(\"./twoTonePrimaryColor\");\n\nvar _utils = require(\"../utils\");\n\n// Initial setting\n// should move it to antd main repo?\n(0, _twoTonePrimaryColor.setTwoToneColor)('#1890ff');\nvar Icon = React.forwardRef(function (props, ref) {\n var className = props.className,\n icon = props.icon,\n spin = props.spin,\n rotate = props.rotate,\n tabIndex = props.tabIndex,\n onClick = props.onClick,\n twoToneColor = props.twoToneColor,\n restProps = (0, _objectWithoutProperties2.default)(props, [\"className\", \"icon\", \"spin\", \"rotate\", \"tabIndex\", \"onClick\", \"twoToneColor\"]);\n var classString = (0, _classnames.default)('anticon', (0, _defineProperty2.default)({}, \"anticon-\".concat(icon.name), Boolean(icon.name)), className);\n var svgClassString = (0, _classnames.default)({\n 'anticon-spin': !!spin || icon.name === 'loading'\n });\n var iconTabIndex = tabIndex;\n\n if (iconTabIndex === undefined && onClick) {\n iconTabIndex = -1;\n }\n\n var svgStyle = rotate ? {\n msTransform: \"rotate(\".concat(rotate, \"deg)\"),\n transform: \"rotate(\".concat(rotate, \"deg)\")\n } : undefined;\n\n var _normalizeTwoToneColo = (0, _utils.normalizeTwoToneColors)(twoToneColor),\n _normalizeTwoToneColo2 = (0, _slicedToArray2.default)(_normalizeTwoToneColo, 2),\n primaryColor = _normalizeTwoToneColo2[0],\n secondaryColor = _normalizeTwoToneColo2[1];\n\n return React.createElement(\"span\", Object.assign({\n role: \"img\",\n \"aria-label\": icon.name\n }, restProps, {\n ref: ref,\n tabIndex: iconTabIndex,\n onClick: onClick,\n className: classString\n }), React.createElement(_IconBase.default, {\n className: svgClassString,\n icon: icon,\n primaryColor: primaryColor,\n secondaryColor: secondaryColor,\n style: svgStyle\n }));\n});\nIcon.displayName = 'AntdIcon';\nIcon.getTwoToneColor = _twoTonePrimaryColor.getTwoToneColor;\nIcon.setTwoToneColor = _twoTonePrimaryColor.setTwoToneColor;\nvar _default = Icon;\nexports.default = _default;","export default function _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}","export default function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}","import arrayWithHoles from \"./arrayWithHoles\";\nimport iterableToArrayLimit from \"./iterableToArrayLimit\";\nimport unsupportedIterableToArray from \"./unsupportedIterableToArray\";\nimport nonIterableRest from \"./nonIterableRest\";\nexport default function _slicedToArray(arr, i) {\n return arrayWithHoles(arr) || iterableToArrayLimit(arr, i) || unsupportedIterableToArray(arr, i) || nonIterableRest();\n}","export default function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}","export default function _iterableToArrayLimit(arr, i) {\n if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n var _e = undefined;\n\n try {\n for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n}","import arrayLikeToArray from \"./arrayLikeToArray\";\nexport default function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(n);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);\n}","export default function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","function _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nimport { isMemo } from 'react-is';\nexport function fillRef(ref, node) {\n if (typeof ref === 'function') {\n ref(node);\n } else if (_typeof(ref) === 'object' && ref && 'current' in ref) {\n ref.current = node;\n }\n}\n/**\n * Merge refs into one ref function to support ref passing.\n */\n\nexport function composeRef() {\n for (var _len = arguments.length, refs = new Array(_len), _key = 0; _key < _len; _key++) {\n refs[_key] = arguments[_key];\n }\n\n return function (node) {\n refs.forEach(function (ref) {\n fillRef(ref, node);\n });\n };\n}\nexport function supportRef(nodeOrComponent) {\n var _type$prototype, _nodeOrComponent$prot;\n\n var type = isMemo(nodeOrComponent) ? nodeOrComponent.type.type : nodeOrComponent.type; // Function component node\n\n if (typeof type === 'function' && !((_type$prototype = type.prototype) === null || _type$prototype === void 0 ? void 0 : _type$prototype.render)) {\n return false;\n } // Class component\n\n\n if (typeof nodeOrComponent === 'function' && !((_nodeOrComponent$prot = nodeOrComponent.prototype) === null || _nodeOrComponent$prot === void 0 ? void 0 : _nodeOrComponent$prot.render)) {\n return false;\n }\n\n return true;\n}\n/* eslint-enable */","import createNamedContext from \"./createNameContext\";\n\nconst historyContext = /*#__PURE__*/ createNamedContext(\"Router-History\");\nexport default historyContext;\n","// TODO: Replace with React.createContext once we can assume React 16+\nimport createContext from \"mini-create-react-context\";\n\nconst createNamedContext = name => {\n const context = createContext();\n context.displayName = name;\n\n return context;\n};\n\nexport default createNamedContext;\n","// TODO: Replace with React.createContext once we can assume React 16+\nimport createContext from \"mini-create-react-context\";\n\nconst createNamedContext = name => {\n const context = createContext();\n context.displayName = name;\n\n return context;\n};\n\nconst context = /*#__PURE__*/ createNamedContext(\"Router\");\nexport default context;\n","import React from \"react\";\nimport PropTypes from \"prop-types\";\nimport warning from \"tiny-warning\";\n\nimport HistoryContext from \"./HistoryContext.js\";\nimport RouterContext from \"./RouterContext.js\";\n\n/**\n * The public API for putting history on context.\n */\nclass Router extends React.Component {\n static computeRootMatch(pathname) {\n return { path: \"/\", url: \"/\", params: {}, isExact: pathname === \"/\" };\n }\n\n constructor(props) {\n super(props);\n\n this.state = {\n location: props.history.location\n };\n\n // This is a bit of a hack. We have to start listening for location\n // changes here in the constructor in case there are any s\n // on the initial render. If there are, they will replace/push when\n // they mount and since cDM fires in children before parents, we may\n // get a new location before the is mounted.\n this._isMounted = false;\n this._pendingLocation = null;\n\n if (!props.staticContext) {\n this.unlisten = props.history.listen(location => {\n if (this._isMounted) {\n this.setState({ location });\n } else {\n this._pendingLocation = location;\n }\n });\n }\n }\n\n componentDidMount() {\n this._isMounted = true;\n\n if (this._pendingLocation) {\n this.setState({ location: this._pendingLocation });\n }\n }\n\n componentWillUnmount() {\n if (this.unlisten) this.unlisten();\n }\n\n render() {\n return (\n \n \n \n );\n }\n}\n\nif (__DEV__) {\n Router.propTypes = {\n children: PropTypes.node,\n history: PropTypes.object.isRequired,\n staticContext: PropTypes.object\n };\n\n Router.prototype.componentDidUpdate = function(prevProps) {\n warning(\n prevProps.history === this.props.history,\n \"You cannot change \"\n );\n };\n}\n\nexport default Router;\n","import React from \"react\";\nimport PropTypes from \"prop-types\";\nimport { createMemoryHistory as createHistory } from \"history\";\nimport warning from \"tiny-warning\";\n\nimport Router from \"./Router.js\";\n\n/**\n * The public API for a that stores location in memory.\n */\nclass MemoryRouter extends React.Component {\n history = createHistory(this.props);\n\n render() {\n return ;\n }\n}\n\nif (__DEV__) {\n MemoryRouter.propTypes = {\n initialEntries: PropTypes.array,\n initialIndex: PropTypes.number,\n getUserConfirmation: PropTypes.func,\n keyLength: PropTypes.number,\n children: PropTypes.node\n };\n\n MemoryRouter.prototype.componentDidMount = function() {\n warning(\n !this.props.history,\n \" ignores the history prop. To use a custom history, \" +\n \"use `import { Router }` instead of `import { MemoryRouter as Router }`.\"\n );\n };\n}\n\nexport default MemoryRouter;\n","import React from \"react\";\n\nclass Lifecycle extends React.Component {\n componentDidMount() {\n if (this.props.onMount) this.props.onMount.call(this, this);\n }\n\n componentDidUpdate(prevProps) {\n if (this.props.onUpdate) this.props.onUpdate.call(this, this, prevProps);\n }\n\n componentWillUnmount() {\n if (this.props.onUnmount) this.props.onUnmount.call(this, this);\n }\n\n render() {\n return null;\n }\n}\n\nexport default Lifecycle;\n","import pathToRegexp from \"path-to-regexp\";\n\nconst cache = {};\nconst cacheLimit = 10000;\nlet cacheCount = 0;\n\nfunction compilePath(path) {\n if (cache[path]) return cache[path];\n\n const generator = pathToRegexp.compile(path);\n\n if (cacheCount < cacheLimit) {\n cache[path] = generator;\n cacheCount++;\n }\n\n return generator;\n}\n\n/**\n * Public API for generating a URL pathname from a path and parameters.\n */\nfunction generatePath(path = \"/\", params = {}) {\n return path === \"/\" ? path : compilePath(path)(params, { pretty: true });\n}\n\nexport default generatePath;\n","import React from \"react\";\nimport PropTypes from \"prop-types\";\nimport { createLocation, locationsAreEqual } from \"history\";\nimport invariant from \"tiny-invariant\";\n\nimport Lifecycle from \"./Lifecycle.js\";\nimport RouterContext from \"./RouterContext.js\";\nimport generatePath from \"./generatePath.js\";\n\n/**\n * The public API for navigating programmatically with a component.\n */\nfunction Redirect({ computedMatch, to, push = false }) {\n return (\n \n {context => {\n invariant(context, \"You should not use outside a \");\n\n const { history, staticContext } = context;\n\n const method = push ? history.push : history.replace;\n const location = createLocation(\n computedMatch\n ? typeof to === \"string\"\n ? generatePath(to, computedMatch.params)\n : {\n ...to,\n pathname: generatePath(to.pathname, computedMatch.params)\n }\n : to\n );\n\n // When rendering in a static context,\n // set the new location immediately.\n if (staticContext) {\n method(location);\n return null;\n }\n\n return (\n {\n method(location);\n }}\n onUpdate={(self, prevProps) => {\n const prevLocation = createLocation(prevProps.to);\n if (\n !locationsAreEqual(prevLocation, {\n ...location,\n key: prevLocation.key\n })\n ) {\n method(location);\n }\n }}\n to={to}\n />\n );\n }}\n \n );\n}\n\nif (__DEV__) {\n Redirect.propTypes = {\n push: PropTypes.bool,\n from: PropTypes.string,\n to: PropTypes.oneOfType([PropTypes.string, PropTypes.object]).isRequired\n };\n}\n\nexport default Redirect;\n","import pathToRegexp from \"path-to-regexp\";\n\nconst cache = {};\nconst cacheLimit = 10000;\nlet cacheCount = 0;\n\nfunction compilePath(path, options) {\n const cacheKey = `${options.end}${options.strict}${options.sensitive}`;\n const pathCache = cache[cacheKey] || (cache[cacheKey] = {});\n\n if (pathCache[path]) return pathCache[path];\n\n const keys = [];\n const regexp = pathToRegexp(path, keys, options);\n const result = { regexp, keys };\n\n if (cacheCount < cacheLimit) {\n pathCache[path] = result;\n cacheCount++;\n }\n\n return result;\n}\n\n/**\n * Public API for matching a URL pathname to a path.\n */\nfunction matchPath(pathname, options = {}) {\n if (typeof options === \"string\" || Array.isArray(options)) {\n options = { path: options };\n }\n\n const { path, exact = false, strict = false, sensitive = false } = options;\n\n const paths = [].concat(path);\n\n return paths.reduce((matched, path) => {\n if (!path && path !== \"\") return null;\n if (matched) return matched;\n\n const { regexp, keys } = compilePath(path, {\n end: exact,\n strict,\n sensitive\n });\n const match = regexp.exec(pathname);\n\n if (!match) return null;\n\n const [url, ...values] = match;\n const isExact = pathname === url;\n\n if (exact && !isExact) return null;\n\n return {\n path, // the path used to match\n url: path === \"/\" && url === \"\" ? \"/\" : url, // the matched portion of the URL\n isExact, // whether or not we matched exactly\n params: keys.reduce((memo, key, index) => {\n memo[key.name] = values[index];\n return memo;\n }, {})\n };\n }, null);\n}\n\nexport default matchPath;\n","import React from \"react\";\nimport { isValidElementType } from \"react-is\";\nimport PropTypes from \"prop-types\";\nimport invariant from \"tiny-invariant\";\nimport warning from \"tiny-warning\";\n\nimport RouterContext from \"./RouterContext.js\";\nimport matchPath from \"./matchPath.js\";\n\nfunction isEmptyChildren(children) {\n return React.Children.count(children) === 0;\n}\n\nfunction evalChildrenDev(children, props, path) {\n const value = children(props);\n\n warning(\n value !== undefined,\n \"You returned `undefined` from the `children` function of \" +\n `, but you ` +\n \"should have returned a React element or `null`\"\n );\n\n return value || null;\n}\n\n/**\n * The public API for matching a single path and rendering.\n */\nclass Route extends React.Component {\n render() {\n return (\n \n {context => {\n invariant(context, \"You should not use outside a \");\n\n const location = this.props.location || context.location;\n const match = this.props.computedMatch\n ? this.props.computedMatch // already computed the match for us\n : this.props.path\n ? matchPath(location.pathname, this.props)\n : context.match;\n\n const props = { ...context, location, match };\n\n let { children, component, render } = this.props;\n\n // Preact uses an empty array as children by\n // default, so use null if that's the case.\n if (Array.isArray(children) && children.length === 0) {\n children = null;\n }\n\n return (\n \n {props.match\n ? children\n ? typeof children === \"function\"\n ? __DEV__\n ? evalChildrenDev(children, props, this.props.path)\n : children(props)\n : children\n : component\n ? React.createElement(component, props)\n : render\n ? render(props)\n : null\n : typeof children === \"function\"\n ? __DEV__\n ? evalChildrenDev(children, props, this.props.path)\n : children(props)\n : null}\n \n );\n }}\n \n );\n }\n}\n\nif (__DEV__) {\n Route.propTypes = {\n children: PropTypes.oneOfType([PropTypes.func, PropTypes.node]),\n component: (props, propName) => {\n if (props[propName] && !isValidElementType(props[propName])) {\n return new Error(\n `Invalid prop 'component' supplied to 'Route': the prop is not a valid React component`\n );\n }\n },\n exact: PropTypes.bool,\n location: PropTypes.object,\n path: PropTypes.oneOfType([\n PropTypes.string,\n PropTypes.arrayOf(PropTypes.string)\n ]),\n render: PropTypes.func,\n sensitive: PropTypes.bool,\n strict: PropTypes.bool\n };\n\n Route.prototype.componentDidMount = function() {\n warning(\n !(\n this.props.children &&\n !isEmptyChildren(this.props.children) &&\n this.props.component\n ),\n \"You should not use and in the same route; will be ignored\"\n );\n\n warning(\n !(\n this.props.children &&\n !isEmptyChildren(this.props.children) &&\n this.props.render\n ),\n \"You should not use and in the same route; will be ignored\"\n );\n\n warning(\n !(this.props.component && this.props.render),\n \"You should not use and in the same route; will be ignored\"\n );\n };\n\n Route.prototype.componentDidUpdate = function(prevProps) {\n warning(\n !(this.props.location && !prevProps.location),\n ' elements should not change from uncontrolled to controlled (or vice versa). You initially used no \"location\" prop and then provided one on a subsequent render.'\n );\n\n warning(\n !(!this.props.location && prevProps.location),\n ' elements should not change from controlled to uncontrolled (or vice versa). You provided a \"location\" prop initially but omitted it on a subsequent render.'\n );\n };\n}\n\nexport default Route;\n","import React from \"react\";\nimport PropTypes from \"prop-types\";\nimport { createLocation, createPath } from \"history\";\nimport invariant from \"tiny-invariant\";\nimport warning from \"tiny-warning\";\n\nimport Router from \"./Router.js\";\n\nfunction addLeadingSlash(path) {\n return path.charAt(0) === \"/\" ? path : \"/\" + path;\n}\n\nfunction addBasename(basename, location) {\n if (!basename) return location;\n\n return {\n ...location,\n pathname: addLeadingSlash(basename) + location.pathname\n };\n}\n\nfunction stripBasename(basename, location) {\n if (!basename) return location;\n\n const base = addLeadingSlash(basename);\n\n if (location.pathname.indexOf(base) !== 0) return location;\n\n return {\n ...location,\n pathname: location.pathname.substr(base.length)\n };\n}\n\nfunction createURL(location) {\n return typeof location === \"string\" ? location : createPath(location);\n}\n\nfunction staticHandler(methodName) {\n return () => {\n invariant(false, \"You cannot %s with \", methodName);\n };\n}\n\nfunction noop() {}\n\n/**\n * The public top-level API for a \"static\" , so-called because it\n * can't actually change the current location. Instead, it just records\n * location changes in a context object. Useful mainly in testing and\n * server-rendering scenarios.\n */\nclass StaticRouter extends React.Component {\n navigateTo(location, action) {\n const { basename = \"\", context = {} } = this.props;\n context.action = action;\n context.location = addBasename(basename, createLocation(location));\n context.url = createURL(context.location);\n }\n\n handlePush = location => this.navigateTo(location, \"PUSH\");\n handleReplace = location => this.navigateTo(location, \"REPLACE\");\n handleListen = () => noop;\n handleBlock = () => noop;\n\n render() {\n const { basename = \"\", context = {}, location = \"/\", ...rest } = this.props;\n\n const history = {\n createHref: path => addLeadingSlash(basename + createURL(path)),\n action: \"POP\",\n location: stripBasename(basename, createLocation(location)),\n push: this.handlePush,\n replace: this.handleReplace,\n go: staticHandler(\"go\"),\n goBack: staticHandler(\"goBack\"),\n goForward: staticHandler(\"goForward\"),\n listen: this.handleListen,\n block: this.handleBlock\n };\n\n return ;\n }\n}\n\nif (__DEV__) {\n StaticRouter.propTypes = {\n basename: PropTypes.string,\n context: PropTypes.object,\n location: PropTypes.oneOfType([PropTypes.string, PropTypes.object])\n };\n\n StaticRouter.prototype.componentDidMount = function() {\n warning(\n !this.props.history,\n \" ignores the history prop. To use a custom history, \" +\n \"use `import { Router }` instead of `import { StaticRouter as Router }`.\"\n );\n };\n}\n\nexport default StaticRouter;\n","import React from \"react\";\nimport PropTypes from \"prop-types\";\nimport invariant from \"tiny-invariant\";\nimport warning from \"tiny-warning\";\n\nimport RouterContext from \"./RouterContext.js\";\nimport matchPath from \"./matchPath.js\";\n\n/**\n * The public API for rendering the first that matches.\n */\nclass Switch extends React.Component {\n render() {\n return (\n \n {context => {\n invariant(context, \"You should not use outside a \");\n\n const location = this.props.location || context.location;\n\n let element, match;\n\n // We use React.Children.forEach instead of React.Children.toArray().find()\n // here because toArray adds keys to all child elements and we do not want\n // to trigger an unmount/remount for two s that render the same\n // component at different URLs.\n React.Children.forEach(this.props.children, child => {\n if (match == null && React.isValidElement(child)) {\n element = child;\n\n const path = child.props.path || child.props.from;\n\n match = path\n ? matchPath(location.pathname, { ...child.props, path })\n : context.match;\n }\n });\n\n return match\n ? React.cloneElement(element, { location, computedMatch: match })\n : null;\n }}\n \n );\n }\n}\n\nif (__DEV__) {\n Switch.propTypes = {\n children: PropTypes.node,\n location: PropTypes.object\n };\n\n Switch.prototype.componentDidUpdate = function(prevProps) {\n warning(\n !(this.props.location && !prevProps.location),\n ' elements should not change from uncontrolled to controlled (or vice versa). You initially used no \"location\" prop and then provided one on a subsequent render.'\n );\n\n warning(\n !(!this.props.location && prevProps.location),\n ' elements should not change from controlled to uncontrolled (or vice versa). You provided a \"location\" prop initially but omitted it on a subsequent render.'\n );\n };\n}\n\nexport default Switch;\n","import React from \"react\";\nimport PropTypes from \"prop-types\";\nimport hoistStatics from \"hoist-non-react-statics\";\nimport invariant from \"tiny-invariant\";\n\nimport RouterContext from \"./RouterContext.js\";\n\n/**\n * A public higher-order component to access the imperative API\n */\nfunction withRouter(Component) {\n const displayName = `withRouter(${Component.displayName || Component.name})`;\n const C = props => {\n const { wrappedComponentRef, ...remainingProps } = props;\n\n return (\n \n {context => {\n invariant(\n context,\n `You should not use <${displayName} /> outside a `\n );\n return (\n \n );\n }}\n \n );\n };\n\n C.displayName = displayName;\n C.WrappedComponent = Component;\n\n if (__DEV__) {\n C.propTypes = {\n wrappedComponentRef: PropTypes.oneOfType([\n PropTypes.string,\n PropTypes.func,\n PropTypes.object\n ])\n };\n }\n\n return hoistStatics(C, Component);\n}\n\nexport default withRouter;\n","import React from \"react\";\nimport invariant from \"tiny-invariant\";\n\nimport Context from \"./RouterContext.js\";\nimport HistoryContext from \"./HistoryContext.js\";\nimport matchPath from \"./matchPath.js\";\n\nconst useContext = React.useContext;\n\nexport function useHistory() {\n if (__DEV__) {\n invariant(\n typeof useContext === \"function\",\n \"You must use React >= 16.8 in order to use useHistory()\"\n );\n }\n\n return useContext(HistoryContext);\n}\n\nexport function useLocation() {\n if (__DEV__) {\n invariant(\n typeof useContext === \"function\",\n \"You must use React >= 16.8 in order to use useLocation()\"\n );\n }\n\n return useContext(Context).location;\n}\n\nexport function useParams() {\n if (__DEV__) {\n invariant(\n typeof useContext === \"function\",\n \"You must use React >= 16.8 in order to use useParams()\"\n );\n }\n\n const match = useContext(Context).match;\n return match ? match.params : {};\n}\n\nexport function useRouteMatch(path) {\n if (__DEV__) {\n invariant(\n typeof useContext === \"function\",\n \"You must use React >= 16.8 in order to use useRouteMatch()\"\n );\n }\n\n const location = useLocation();\n const match = useContext(Context).match;\n\n return path ? matchPath(location.pathname, path) : match;\n}\n","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport { generate as generateColor } from '@ant-design/colors';\nimport React, { useEffect } from 'react';\nimport warn from \"rc-util/es/warning\";\nimport { insertCss } from 'insert-css';\nexport function warning(valid, message) {\n warn(valid, \"[@ant-design/icons] \".concat(message));\n}\nexport function isIconDefinition(target) {\n return _typeof(target) === 'object' && typeof target.name === 'string' && typeof target.theme === 'string' && (_typeof(target.icon) === 'object' || typeof target.icon === 'function');\n}\nexport function normalizeAttrs() {\n var attrs = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n return Object.keys(attrs).reduce(function (acc, key) {\n var val = attrs[key];\n\n switch (key) {\n case 'class':\n acc.className = val;\n delete acc.class;\n break;\n\n default:\n acc[key] = val;\n }\n\n return acc;\n }, {});\n}\nexport function generate(node, key, rootProps) {\n if (!rootProps) {\n return React.createElement(node.tag, _objectSpread({\n key: key\n }, normalizeAttrs(node.attrs)), (node.children || []).map(function (child, index) {\n return generate(child, \"\".concat(key, \"-\").concat(node.tag, \"-\").concat(index));\n }));\n }\n\n return React.createElement(node.tag, _objectSpread(_objectSpread({\n key: key\n }, normalizeAttrs(node.attrs)), rootProps), (node.children || []).map(function (child, index) {\n return generate(child, \"\".concat(key, \"-\").concat(node.tag, \"-\").concat(index));\n }));\n}\nexport function getSecondaryColor(primaryColor) {\n // choose the second color\n return generateColor(primaryColor)[0];\n}\nexport function normalizeTwoToneColors(twoToneColor) {\n if (!twoToneColor) {\n return [];\n }\n\n return Array.isArray(twoToneColor) ? twoToneColor : [twoToneColor];\n} // These props make sure that the SVG behaviours like general text.\n// Reference: https://blog.prototypr.io/align-svg-icons-to-text-and-say-goodbye-to-font-icons-d44b3d7b26b4\n\nexport var svgBaseProps = {\n width: '1em',\n height: '1em',\n fill: 'currentColor',\n 'aria-hidden': 'true',\n focusable: 'false'\n};\nexport var iconStyles = \"\\n.anticon {\\n display: inline-block;\\n color: inherit;\\n font-style: normal;\\n line-height: 0;\\n text-align: center;\\n text-transform: none;\\n vertical-align: -0.125em;\\n text-rendering: optimizeLegibility;\\n -webkit-font-smoothing: antialiased;\\n -moz-osx-font-smoothing: grayscale;\\n}\\n\\n.anticon > * {\\n line-height: 1;\\n}\\n\\n.anticon svg {\\n display: inline-block;\\n}\\n\\n.anticon::before {\\n display: none;\\n}\\n\\n.anticon .anticon-icon {\\n display: block;\\n}\\n\\n.anticon[tabindex] {\\n cursor: pointer;\\n}\\n\\n.anticon-spin::before,\\n.anticon-spin {\\n display: inline-block;\\n -webkit-animation: loadingCircle 1s infinite linear;\\n animation: loadingCircle 1s infinite linear;\\n}\\n\\n@-webkit-keyframes loadingCircle {\\n 100% {\\n -webkit-transform: rotate(360deg);\\n transform: rotate(360deg);\\n }\\n}\\n\\n@keyframes loadingCircle {\\n 100% {\\n -webkit-transform: rotate(360deg);\\n transform: rotate(360deg);\\n }\\n}\\n\";\nvar cssInjectedFlag = false;\nexport var useInsertStyles = function useInsertStyles() {\n var styleStr = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : iconStyles;\n useEffect(function () {\n if (!cssInjectedFlag) {\n insertCss(styleStr, {\n prepend: true\n });\n cssInjectedFlag = true;\n }\n }, []);\n};","import _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport { generate, getSecondaryColor, isIconDefinition, warning, useInsertStyles } from '../utils';\nvar twoToneColorPalette = {\n primaryColor: '#333',\n secondaryColor: '#E6E6E6',\n calculated: false\n};\n\nfunction setTwoToneColors(_ref) {\n var primaryColor = _ref.primaryColor,\n secondaryColor = _ref.secondaryColor;\n twoToneColorPalette.primaryColor = primaryColor;\n twoToneColorPalette.secondaryColor = secondaryColor || getSecondaryColor(primaryColor);\n twoToneColorPalette.calculated = !!secondaryColor;\n}\n\nfunction getTwoToneColors() {\n return _objectSpread({}, twoToneColorPalette);\n}\n\nvar IconBase = function IconBase(props) {\n var icon = props.icon,\n className = props.className,\n onClick = props.onClick,\n style = props.style,\n primaryColor = props.primaryColor,\n secondaryColor = props.secondaryColor,\n restProps = _objectWithoutProperties(props, [\"icon\", \"className\", \"onClick\", \"style\", \"primaryColor\", \"secondaryColor\"]);\n\n var colors = twoToneColorPalette;\n\n if (primaryColor) {\n colors = {\n primaryColor: primaryColor,\n secondaryColor: secondaryColor || getSecondaryColor(primaryColor)\n };\n }\n\n useInsertStyles();\n warning(isIconDefinition(icon), \"icon should be icon definiton, but got \".concat(icon));\n\n if (!isIconDefinition(icon)) {\n return null;\n }\n\n var target = icon;\n\n if (target && typeof target.icon === 'function') {\n target = _objectSpread(_objectSpread({}, target), {}, {\n icon: target.icon(colors.primaryColor, colors.secondaryColor)\n });\n }\n\n return generate(target.icon, \"svg-\".concat(target.name), _objectSpread({\n className: className,\n onClick: onClick,\n style: style,\n 'data-icon': target.name,\n width: '1em',\n height: '1em',\n fill: 'currentColor',\n 'aria-hidden': 'true'\n }, restProps));\n};\n\nIconBase.displayName = 'IconReact';\nIconBase.getTwoToneColors = getTwoToneColors;\nIconBase.setTwoToneColors = setTwoToneColors;\nexport default IconBase;","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport ReactIcon from './IconBase';\nimport { normalizeTwoToneColors } from '../utils';\nexport function setTwoToneColor(twoToneColor) {\n var _normalizeTwoToneColo = normalizeTwoToneColors(twoToneColor),\n _normalizeTwoToneColo2 = _slicedToArray(_normalizeTwoToneColo, 2),\n primaryColor = _normalizeTwoToneColo2[0],\n secondaryColor = _normalizeTwoToneColo2[1];\n\n return ReactIcon.setTwoToneColors({\n primaryColor: primaryColor,\n secondaryColor: secondaryColor\n });\n}\nexport function getTwoToneColor() {\n var colors = ReactIcon.getTwoToneColors();\n\n if (!colors.calculated) {\n return colors.primaryColor;\n }\n\n return [colors.primaryColor, colors.secondaryColor];\n}","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport ReactIcon from './IconBase';\nimport { getTwoToneColor, setTwoToneColor } from './twoTonePrimaryColor';\nimport { normalizeTwoToneColors } from '../utils'; // Initial setting\n// should move it to antd main repo?\n\nsetTwoToneColor('#1890ff');\nvar Icon = React.forwardRef(function (props, ref) {\n var className = props.className,\n icon = props.icon,\n spin = props.spin,\n rotate = props.rotate,\n tabIndex = props.tabIndex,\n onClick = props.onClick,\n twoToneColor = props.twoToneColor,\n restProps = _objectWithoutProperties(props, [\"className\", \"icon\", \"spin\", \"rotate\", \"tabIndex\", \"onClick\", \"twoToneColor\"]);\n\n var classString = classNames('anticon', _defineProperty({}, \"anticon-\".concat(icon.name), Boolean(icon.name)), className);\n var svgClassString = classNames({\n 'anticon-spin': !!spin || icon.name === 'loading'\n });\n var iconTabIndex = tabIndex;\n\n if (iconTabIndex === undefined && onClick) {\n iconTabIndex = -1;\n }\n\n var svgStyle = rotate ? {\n msTransform: \"rotate(\".concat(rotate, \"deg)\"),\n transform: \"rotate(\".concat(rotate, \"deg)\")\n } : undefined;\n\n var _normalizeTwoToneColo = normalizeTwoToneColors(twoToneColor),\n _normalizeTwoToneColo2 = _slicedToArray(_normalizeTwoToneColo, 2),\n primaryColor = _normalizeTwoToneColo2[0],\n secondaryColor = _normalizeTwoToneColo2[1];\n\n return React.createElement(\"span\", Object.assign({\n role: \"img\",\n \"aria-label\": icon.name\n }, restProps, {\n ref: ref,\n tabIndex: iconTabIndex,\n onClick: onClick,\n className: classString\n }), React.createElement(ReactIcon, {\n className: svgClassString,\n icon: icon,\n primaryColor: primaryColor,\n secondaryColor: secondaryColor,\n style: svgStyle\n }));\n});\nIcon.displayName = 'AntdIcon';\nIcon.getTwoToneColor = getTwoToneColor;\nIcon.setTwoToneColor = setTwoToneColor;\nexport default Icon;","export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","import defineProperty from \"./defineProperty\";\n\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n if (enumerableOnly) symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nexport default function _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n}","var now = require('performance-now')\n , root = typeof window === 'undefined' ? global : window\n , vendors = ['moz', 'webkit']\n , suffix = 'AnimationFrame'\n , raf = root['request' + suffix]\n , caf = root['cancel' + suffix] || root['cancelRequest' + suffix]\n\nfor(var i = 0; !raf && i < vendors.length; i++) {\n raf = root[vendors[i] + 'Request' + suffix]\n caf = root[vendors[i] + 'Cancel' + suffix]\n || root[vendors[i] + 'CancelRequest' + suffix]\n}\n\n// Some versions of FF have rAF but not cAF\nif(!raf || !caf) {\n var last = 0\n , id = 0\n , queue = []\n , frameDuration = 1000 / 60\n\n raf = function(callback) {\n if(queue.length === 0) {\n var _now = now()\n , next = Math.max(0, frameDuration - (_now - last))\n last = next + _now\n setTimeout(function() {\n var cp = queue.slice(0)\n // Clear queue here to prevent\n // callbacks from appending listeners\n // to the current frame's queue\n queue.length = 0\n for(var i = 0; i < cp.length; i++) {\n if(!cp[i].cancelled) {\n try{\n cp[i].callback(last)\n } catch(e) {\n setTimeout(function() { throw e }, 0)\n }\n }\n }\n }, Math.round(next))\n }\n queue.push({\n handle: ++id,\n callback: callback,\n cancelled: false\n })\n return id\n }\n\n caf = function(handle) {\n for(var i = 0; i < queue.length; i++) {\n if(queue[i].handle === handle) {\n queue[i].cancelled = true\n }\n }\n }\n}\n\nmodule.exports = function(fn) {\n // Wrap in a new function to prevent\n // `cancel` potentially being assigned\n // to the native rAF function\n return raf.call(root, fn)\n}\nmodule.exports.cancel = function() {\n caf.apply(root, arguments)\n}\nmodule.exports.polyfill = function(object) {\n if (!object) {\n object = root;\n }\n object.requestAnimationFrame = raf\n object.cancelAnimationFrame = caf\n}\n","import * as React from 'react';\nvar SizeContext = /*#__PURE__*/React.createContext(undefined);\nexport var SizeContextProvider = function SizeContextProvider(_ref) {\n var children = _ref.children,\n size = _ref.size;\n return /*#__PURE__*/React.createElement(SizeContext.Consumer, null, function (originSize) {\n return /*#__PURE__*/React.createElement(SizeContext.Provider, {\n value: size || originSize\n }, children);\n });\n};\nexport default SizeContext;","// https://stackoverflow.com/questions/46176165/ways-to-get-string-literal-type-of-array-values-without-enum-overhead\nexport var tuple = function tuple() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return args;\n};\nexport var tupleNum = function tupleNum() {\n for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n args[_key2] = arguments[_key2];\n }\n\n return args;\n};","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport { useEffect } from 'react';\nimport classNames from 'classnames';\nimport CSSMotion from 'rc-motion';\nimport TreeNode from './TreeNode';\nimport { getTreeNodeProps } from './utils/treeUtil';\nimport { TreeContext } from './contextTypes';\n\nvar MotionTreeNode = function MotionTreeNode(_ref, ref) {\n var className = _ref.className,\n style = _ref.style,\n motion = _ref.motion,\n motionNodes = _ref.motionNodes,\n motionType = _ref.motionType,\n onOriginMotionStart = _ref.onMotionStart,\n onOriginMotionEnd = _ref.onMotionEnd,\n active = _ref.active,\n treeNodeRequiredProps = _ref.treeNodeRequiredProps,\n props = _objectWithoutProperties(_ref, [\"className\", \"style\", \"motion\", \"motionNodes\", \"motionType\", \"onMotionStart\", \"onMotionEnd\", \"active\", \"treeNodeRequiredProps\"]);\n\n var _React$useState = React.useState(true),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n visible = _React$useState2[0],\n setVisible = _React$useState2[1];\n\n var _React$useContext = React.useContext(TreeContext),\n prefixCls = _React$useContext.prefixCls;\n\n var motionedRef = React.useRef(false);\n\n var onMotionEnd = function onMotionEnd() {\n if (!motionedRef.current) {\n onOriginMotionEnd();\n }\n\n motionedRef.current = true;\n };\n\n useEffect(function () {\n if (motionNodes && motionType === 'hide' && visible) {\n setVisible(false);\n }\n }, [motionNodes]);\n useEffect(function () {\n // Trigger motion only when patched\n if (motionNodes) {\n onOriginMotionStart();\n }\n\n return function () {\n if (motionNodes) {\n onMotionEnd();\n }\n };\n }, []);\n\n if (motionNodes) {\n return React.createElement(CSSMotion, Object.assign({\n ref: ref,\n visible: visible\n }, motion, {\n motionAppear: motionType === 'show',\n onAppearEnd: onMotionEnd,\n onLeaveEnd: onMotionEnd\n }), function (_ref2, motionRef) {\n var motionClassName = _ref2.className,\n motionStyle = _ref2.style;\n return React.createElement(\"div\", {\n ref: motionRef,\n className: classNames(\"\".concat(prefixCls, \"-treenode-motion\"), motionClassName),\n style: motionStyle\n }, motionNodes.map(function (treeNode) {\n var _treeNode$data = treeNode.data,\n key = _treeNode$data.key,\n restProps = _objectWithoutProperties(_treeNode$data, [\"key\"]),\n isStart = treeNode.isStart,\n isEnd = treeNode.isEnd;\n\n delete restProps.children;\n var treeNodeProps = getTreeNodeProps(key, treeNodeRequiredProps);\n return React.createElement(TreeNode, Object.assign({}, restProps, treeNodeProps, {\n active: active,\n data: treeNode.data,\n key: key,\n isStart: isStart,\n isEnd: isEnd\n }));\n }));\n });\n }\n\n return React.createElement(TreeNode, Object.assign({\n domRef: ref,\n className: className,\n style: style\n }, props, {\n active: active\n }));\n};\n\nMotionTreeNode.displayName = 'MotionTreeNode';\nvar RefMotionTreeNode = React.forwardRef(MotionTreeNode);\nexport default RefMotionTreeNode;","export function findExpandedKeys() {\n var prev = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n var next = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];\n var prevLen = prev.length;\n var nextLen = next.length;\n\n if (Math.abs(prevLen - nextLen) !== 1) {\n return {\n add: false,\n key: null\n };\n }\n\n function find(shorter, longer) {\n var cache = new Map();\n shorter.forEach(function (key) {\n cache.set(key, true);\n });\n var keys = longer.filter(function (key) {\n return !cache.has(key);\n });\n return keys.length === 1 ? keys[0] : null;\n }\n\n if (prevLen < nextLen) {\n return {\n add: true,\n key: find(prev, next)\n };\n }\n\n return {\n add: false,\n key: find(next, prev)\n };\n}\nexport function getExpandRange(shorter, longer, key) {\n var shorterStartIndex = shorter.findIndex(function (_ref) {\n var data = _ref.data;\n return data.key === key;\n });\n var shorterEndNode = shorter[shorterStartIndex + 1];\n var longerStartIndex = longer.findIndex(function (_ref2) {\n var data = _ref2.data;\n return data.key === key;\n });\n\n if (shorterEndNode) {\n var longerEndIndex = longer.findIndex(function (_ref3) {\n var data = _ref3.data;\n return data.key === shorterEndNode.data.key;\n });\n return longer.slice(longerStartIndex + 1, longerEndIndex);\n }\n\n return longer.slice(longerStartIndex + 1);\n}","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\n\n/**\n * Handle virtual list of the TreeNodes.\n */\nimport * as React from 'react';\nimport VirtualList from 'rc-virtual-list';\nimport MotionTreeNode from './MotionTreeNode';\nimport { findExpandedKeys, getExpandRange } from './utils/diffUtil';\nimport { getTreeNodeProps, getKey } from './utils/treeUtil';\nvar HIDDEN_STYLE = {\n width: 0,\n height: 0,\n display: 'flex',\n overflow: 'hidden',\n opacity: 0,\n border: 0,\n padding: 0,\n margin: 0\n};\n\nvar noop = function noop() {};\n\nexport var MOTION_KEY = \"RC_TREE_MOTION_\".concat(Math.random());\nvar MotionNode = {\n key: MOTION_KEY\n};\nexport var MotionEntity = {\n key: MOTION_KEY,\n level: 0,\n index: 0,\n pos: '0',\n node: MotionNode\n};\nvar MotionFlattenData = {\n parent: null,\n children: [],\n pos: MotionEntity.pos,\n data: MotionNode,\n\n /** Hold empty list here since we do not use it */\n isStart: [],\n isEnd: []\n};\n/**\n * We only need get visible content items to play the animation.\n */\n\nexport function getMinimumRangeTransitionRange(list, virtual, height, itemHeight) {\n if (virtual === false || !height) {\n return list;\n }\n\n return list.slice(0, Math.ceil(height / itemHeight) + 1);\n}\n\nfunction itemKey(item) {\n var key = item.data.key,\n pos = item.pos;\n return getKey(key, pos);\n}\n\nfunction getAccessibilityPath(item) {\n var path = String(item.data.key);\n var current = item;\n\n while (current.parent) {\n current = current.parent;\n path = \"\".concat(current.data.key, \" > \").concat(path);\n }\n\n return path;\n}\n\nvar RefNodeList = function RefNodeList(props, ref) {\n var prefixCls = props.prefixCls,\n data = props.data,\n selectable = props.selectable,\n checkable = props.checkable,\n expandedKeys = props.expandedKeys,\n selectedKeys = props.selectedKeys,\n checkedKeys = props.checkedKeys,\n loadedKeys = props.loadedKeys,\n loadingKeys = props.loadingKeys,\n halfCheckedKeys = props.halfCheckedKeys,\n keyEntities = props.keyEntities,\n disabled = props.disabled,\n dragging = props.dragging,\n dragOverNodeKey = props.dragOverNodeKey,\n dropPosition = props.dropPosition,\n motion = props.motion,\n height = props.height,\n itemHeight = props.itemHeight,\n virtual = props.virtual,\n focusable = props.focusable,\n activeItem = props.activeItem,\n focused = props.focused,\n tabIndex = props.tabIndex,\n onKeyDown = props.onKeyDown,\n onFocus = props.onFocus,\n onBlur = props.onBlur,\n onActiveChange = props.onActiveChange,\n onListChangeStart = props.onListChangeStart,\n onListChangeEnd = props.onListChangeEnd,\n domProps = _objectWithoutProperties(props, [\"prefixCls\", \"data\", \"selectable\", \"checkable\", \"expandedKeys\", \"selectedKeys\", \"checkedKeys\", \"loadedKeys\", \"loadingKeys\", \"halfCheckedKeys\", \"keyEntities\", \"disabled\", \"dragging\", \"dragOverNodeKey\", \"dropPosition\", \"motion\", \"height\", \"itemHeight\", \"virtual\", \"focusable\", \"activeItem\", \"focused\", \"tabIndex\", \"onKeyDown\", \"onFocus\", \"onBlur\", \"onActiveChange\", \"onListChangeStart\", \"onListChangeEnd\"]); // =============================== Ref ================================\n\n\n var listRef = React.useRef(null);\n React.useImperativeHandle(ref, function () {\n return {\n scrollTo: function scrollTo(scroll) {\n listRef.current.scrollTo(scroll);\n }\n };\n }); // ============================== Motion ==============================\n\n var _React$useState = React.useState(expandedKeys),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n prevExpandedKeys = _React$useState2[0],\n setPrevExpandedKeys = _React$useState2[1];\n\n var _React$useState3 = React.useState(data),\n _React$useState4 = _slicedToArray(_React$useState3, 2),\n prevData = _React$useState4[0],\n setPrevData = _React$useState4[1];\n\n var _React$useState5 = React.useState(data),\n _React$useState6 = _slicedToArray(_React$useState5, 2),\n transitionData = _React$useState6[0],\n setTransitionData = _React$useState6[1];\n\n var _React$useState7 = React.useState([]),\n _React$useState8 = _slicedToArray(_React$useState7, 2),\n transitionRange = _React$useState8[0],\n setTransitionRange = _React$useState8[1];\n\n var _React$useState9 = React.useState(null),\n _React$useState10 = _slicedToArray(_React$useState9, 2),\n motionType = _React$useState10[0],\n setMotionType = _React$useState10[1];\n\n function onMotionEnd() {\n setPrevData(data);\n setTransitionData(data);\n setTransitionRange([]);\n setMotionType(null);\n onListChangeEnd();\n } // Do animation if expanded keys changed\n\n\n React.useEffect(function () {\n setPrevExpandedKeys(expandedKeys);\n var diffExpanded = findExpandedKeys(prevExpandedKeys, expandedKeys);\n\n if (diffExpanded.key !== null) {\n if (diffExpanded.add) {\n var keyIndex = prevData.findIndex(function (_ref) {\n var key = _ref.data.key;\n return key === diffExpanded.key;\n });\n var rangeNodes = getMinimumRangeTransitionRange(getExpandRange(prevData, data, diffExpanded.key), virtual, height, itemHeight);\n var newTransitionData = prevData.slice();\n newTransitionData.splice(keyIndex + 1, 0, MotionFlattenData);\n setTransitionData(newTransitionData);\n setTransitionRange(rangeNodes);\n setMotionType('show');\n } else {\n var _keyIndex = data.findIndex(function (_ref2) {\n var key = _ref2.data.key;\n return key === diffExpanded.key;\n });\n\n var _rangeNodes = getMinimumRangeTransitionRange(getExpandRange(data, prevData, diffExpanded.key), virtual, height, itemHeight);\n\n var _newTransitionData = data.slice();\n\n _newTransitionData.splice(_keyIndex + 1, 0, MotionFlattenData);\n\n setTransitionData(_newTransitionData);\n setTransitionRange(_rangeNodes);\n setMotionType('hide');\n }\n } else if (prevData !== data) {\n // If whole data changed, we just refresh the list\n setPrevData(data);\n setTransitionData(data);\n }\n }, [expandedKeys, data]); // We should clean up motion if is changed by dragging\n\n React.useEffect(function () {\n if (!dragging) {\n onMotionEnd();\n }\n }, [dragging]);\n var mergedData = motion ? transitionData : data;\n var treeNodeRequiredProps = {\n expandedKeys: expandedKeys,\n selectedKeys: selectedKeys,\n loadedKeys: loadedKeys,\n loadingKeys: loadingKeys,\n checkedKeys: checkedKeys,\n halfCheckedKeys: halfCheckedKeys,\n dragOverNodeKey: dragOverNodeKey,\n dropPosition: dropPosition,\n keyEntities: keyEntities\n };\n return React.createElement(React.Fragment, null, focused && activeItem && React.createElement(\"span\", {\n style: HIDDEN_STYLE,\n \"aria-live\": \"assertive\"\n }, getAccessibilityPath(activeItem)), React.createElement(\"div\", {\n role: \"tree\"\n }, React.createElement(\"input\", {\n style: HIDDEN_STYLE,\n disabled: focusable === false || disabled,\n tabIndex: focusable !== false ? tabIndex : null,\n onKeyDown: onKeyDown,\n onFocus: onFocus,\n onBlur: onBlur,\n value: \"\",\n onChange: noop\n })), React.createElement(VirtualList, Object.assign({}, domProps, {\n data: mergedData,\n itemKey: itemKey,\n height: height,\n fullHeight: false,\n virtual: virtual,\n itemHeight: itemHeight,\n prefixCls: \"\".concat(prefixCls, \"-list\"),\n ref: listRef\n }), function (treeNode) {\n var pos = treeNode.pos,\n _treeNode$data = treeNode.data,\n key = _treeNode$data.key,\n restProps = _objectWithoutProperties(_treeNode$data, [\"key\"]),\n isStart = treeNode.isStart,\n isEnd = treeNode.isEnd;\n\n var mergedKey = getKey(key, pos);\n delete restProps.children;\n var treeNodeProps = getTreeNodeProps(mergedKey, treeNodeRequiredProps);\n return React.createElement(MotionTreeNode, Object.assign({}, restProps, treeNodeProps, {\n active: activeItem && key === activeItem.data.key,\n pos: pos,\n data: treeNode.data,\n isStart: isStart,\n isEnd: isEnd,\n motion: motion,\n motionNodes: key === MOTION_KEY ? transitionRange : null,\n motionType: motionType,\n onMotionStart: onListChangeStart,\n onMotionEnd: onMotionEnd,\n treeNodeRequiredProps: treeNodeRequiredProps,\n onMouseMove: function onMouseMove() {\n onActiveChange(null);\n }\n }));\n }));\n};\n\nvar NodeList = React.forwardRef(RefNodeList);\nNodeList.displayName = 'NodeList';\nexport default NodeList;","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\n// TODO: https://www.w3.org/TR/2017/NOTE-wai-aria-practices-1.1-20171214/examples/treeview/treeview-2/treeview-2a.html\n// Fully accessibility support\nimport * as React from 'react';\nimport KeyCode from \"rc-util/es/KeyCode\";\nimport warning from \"rc-util/es/warning\";\nimport classNames from 'classnames';\nimport { TreeContext } from './contextTypes';\nimport { getDataAndAria, getDragNodesKeys, parseCheckedKeys, conductExpandParent, calcSelectedKeys, calcDropPosition, arrAdd, arrDel, posToArr } from './util';\nimport { flattenTreeData, convertTreeToData, convertDataToEntities, warningWithoutKey, convertNodePropsToEventData, getTreeNodeProps } from './utils/treeUtil';\nimport NodeList, { MOTION_KEY, MotionEntity } from './NodeList';\nimport TreeNode from './TreeNode';\nimport { conductCheck } from './utils/conductUtil';\n\nvar Tree = /*#__PURE__*/function (_React$Component) {\n _inherits(Tree, _React$Component);\n\n var _super = _createSuper(Tree);\n\n function Tree() {\n var _this;\n\n _classCallCheck(this, Tree);\n\n _this = _super.apply(this, arguments);\n _this.destroyed = false;\n _this.state = {\n keyEntities: {},\n selectedKeys: [],\n checkedKeys: [],\n halfCheckedKeys: [],\n loadedKeys: [],\n loadingKeys: [],\n expandedKeys: [],\n dragging: false,\n dragNodesKeys: [],\n dragOverNodeKey: null,\n dropPosition: null,\n treeData: [],\n flattenNodes: [],\n focused: false,\n activeKey: null,\n listChanging: false,\n prevProps: null\n };\n _this.listRef = React.createRef();\n\n _this.onNodeDragStart = function (event, node) {\n var _this$state = _this.state,\n expandedKeys = _this$state.expandedKeys,\n keyEntities = _this$state.keyEntities;\n var onDragStart = _this.props.onDragStart;\n var eventKey = node.props.eventKey;\n _this.dragNode = node;\n var newExpandedKeys = arrDel(expandedKeys, eventKey);\n\n _this.setState({\n dragging: true,\n dragNodesKeys: getDragNodesKeys(eventKey, keyEntities)\n });\n\n _this.setExpandedKeys(newExpandedKeys);\n\n if (onDragStart) {\n onDragStart({\n event: event,\n node: convertNodePropsToEventData(node.props)\n });\n }\n };\n /**\n * [Legacy] Select handler is less small than node,\n * so that this will trigger when drag enter node or select handler.\n * This is a little tricky if customize css without padding.\n * Better for use mouse move event to refresh drag state.\n * But let's just keep it to avoid event trigger logic change.\n */\n\n\n _this.onNodeDragEnter = function (event, node) {\n var _this$state2 = _this.state,\n expandedKeys = _this$state2.expandedKeys,\n keyEntities = _this$state2.keyEntities,\n dragNodesKeys = _this$state2.dragNodesKeys;\n var onDragEnter = _this.props.onDragEnter;\n var _node$props = node.props,\n pos = _node$props.pos,\n eventKey = _node$props.eventKey;\n if (!_this.dragNode || dragNodesKeys.indexOf(eventKey) !== -1) return;\n var dropPosition = calcDropPosition(event, node); // Skip if drag node is self\n\n if (_this.dragNode.props.eventKey === eventKey && dropPosition === 0) {\n _this.setState({\n dragOverNodeKey: '',\n dropPosition: null\n });\n\n return;\n } // Ref: https://github.com/react-component/tree/issues/132\n // Add timeout to let onDragLevel fire before onDragEnter,\n // so that we can clean drag props for onDragLeave node.\n // Macro task for this:\n // https://html.spec.whatwg.org/multipage/webappapis.html#clean-up-after-running-script\n\n\n setTimeout(function () {\n // Update drag over node\n _this.setState({\n dragOverNodeKey: eventKey,\n dropPosition: dropPosition\n }); // Side effect for delay drag\n\n\n if (!_this.delayedDragEnterLogic) {\n _this.delayedDragEnterLogic = {};\n }\n\n Object.keys(_this.delayedDragEnterLogic).forEach(function (key) {\n clearTimeout(_this.delayedDragEnterLogic[key]);\n });\n _this.delayedDragEnterLogic[pos] = window.setTimeout(function () {\n if (!_this.state.dragging) return;\n\n var newExpandedKeys = _toConsumableArray(expandedKeys);\n\n var entity = keyEntities[eventKey];\n\n if (entity && (entity.children || []).length) {\n newExpandedKeys = arrAdd(expandedKeys, eventKey);\n }\n\n if (!('expandedKeys' in _this.props)) {\n _this.setExpandedKeys(newExpandedKeys);\n }\n\n if (onDragEnter) {\n onDragEnter({\n event: event,\n node: convertNodePropsToEventData(node.props),\n expandedKeys: newExpandedKeys\n });\n }\n }, 400);\n }, 0);\n };\n\n _this.onNodeDragOver = function (event, node) {\n var dragNodesKeys = _this.state.dragNodesKeys;\n var onDragOver = _this.props.onDragOver;\n var eventKey = node.props.eventKey;\n\n if (dragNodesKeys.indexOf(eventKey) !== -1) {\n return;\n } // Update drag position\n\n\n if (_this.dragNode && eventKey === _this.state.dragOverNodeKey) {\n var dropPosition = calcDropPosition(event, node);\n if (dropPosition === _this.state.dropPosition) return;\n\n _this.setState({\n dropPosition: dropPosition\n });\n }\n\n if (onDragOver) {\n onDragOver({\n event: event,\n node: convertNodePropsToEventData(node.props)\n });\n }\n };\n\n _this.onNodeDragLeave = function (event, node) {\n var onDragLeave = _this.props.onDragLeave;\n\n _this.setState({\n dragOverNodeKey: ''\n });\n\n if (onDragLeave) {\n onDragLeave({\n event: event,\n node: convertNodePropsToEventData(node.props)\n });\n }\n };\n\n _this.onNodeDragEnd = function (event, node) {\n var onDragEnd = _this.props.onDragEnd;\n\n _this.setState({\n dragOverNodeKey: ''\n });\n\n _this.cleanDragState();\n\n if (onDragEnd) {\n onDragEnd({\n event: event,\n node: convertNodePropsToEventData(node.props)\n });\n }\n\n _this.dragNode = null;\n };\n\n _this.onNodeDrop = function (event, node) {\n var _this$state3 = _this.state,\n _this$state3$dragNode = _this$state3.dragNodesKeys,\n dragNodesKeys = _this$state3$dragNode === void 0 ? [] : _this$state3$dragNode,\n dropPosition = _this$state3.dropPosition;\n var onDrop = _this.props.onDrop;\n var _node$props2 = node.props,\n eventKey = _node$props2.eventKey,\n pos = _node$props2.pos;\n\n _this.setState({\n dragOverNodeKey: ''\n });\n\n _this.cleanDragState();\n\n if (dragNodesKeys.indexOf(eventKey) !== -1) {\n warning(false, \"Can not drop to dragNode(include it's children node)\");\n return;\n }\n\n var posArr = posToArr(pos);\n var dropResult = {\n event: event,\n node: convertNodePropsToEventData(node.props),\n dragNode: _this.dragNode ? convertNodePropsToEventData(_this.dragNode.props) : null,\n dragNodesKeys: dragNodesKeys.slice(),\n dropPosition: dropPosition + Number(posArr[posArr.length - 1]),\n dropToGap: false\n };\n\n if (dropPosition !== 0) {\n dropResult.dropToGap = true;\n }\n\n if (onDrop) {\n onDrop(dropResult);\n }\n\n _this.dragNode = null;\n };\n\n _this.cleanDragState = function () {\n var dragging = _this.state.dragging;\n\n if (dragging) {\n _this.setState({\n dragging: false\n });\n }\n };\n\n _this.onNodeClick = function (e, treeNode) {\n var onClick = _this.props.onClick;\n\n if (onClick) {\n onClick(e, treeNode);\n }\n };\n\n _this.onNodeDoubleClick = function (e, treeNode) {\n var onDoubleClick = _this.props.onDoubleClick;\n\n if (onDoubleClick) {\n onDoubleClick(e, treeNode);\n }\n };\n\n _this.onNodeSelect = function (e, treeNode) {\n var selectedKeys = _this.state.selectedKeys;\n var keyEntities = _this.state.keyEntities;\n var _this$props = _this.props,\n onSelect = _this$props.onSelect,\n multiple = _this$props.multiple;\n var selected = treeNode.selected,\n key = treeNode.key;\n var targetSelected = !selected; // Update selected keys\n\n if (!targetSelected) {\n selectedKeys = arrDel(selectedKeys, key);\n } else if (!multiple) {\n selectedKeys = [key];\n } else {\n selectedKeys = arrAdd(selectedKeys, key);\n } // [Legacy] Not found related usage in doc or upper libs\n\n\n var selectedNodes = selectedKeys.map(function (selectedKey) {\n var entity = keyEntities[selectedKey];\n if (!entity) return null;\n return entity.node;\n }).filter(function (node) {\n return node;\n });\n\n _this.setUncontrolledState({\n selectedKeys: selectedKeys\n });\n\n if (onSelect) {\n onSelect(selectedKeys, {\n event: 'select',\n selected: targetSelected,\n node: treeNode,\n selectedNodes: selectedNodes,\n nativeEvent: e.nativeEvent\n });\n }\n };\n\n _this.onNodeCheck = function (e, treeNode, checked) {\n var _this$state4 = _this.state,\n keyEntities = _this$state4.keyEntities,\n oriCheckedKeys = _this$state4.checkedKeys,\n oriHalfCheckedKeys = _this$state4.halfCheckedKeys;\n var _this$props2 = _this.props,\n checkStrictly = _this$props2.checkStrictly,\n onCheck = _this$props2.onCheck;\n var key = treeNode.key; // Prepare trigger arguments\n\n var checkedObj;\n var eventObj = {\n event: 'check',\n node: treeNode,\n checked: checked,\n nativeEvent: e.nativeEvent\n };\n\n if (checkStrictly) {\n var checkedKeys = checked ? arrAdd(oriCheckedKeys, key) : arrDel(oriCheckedKeys, key);\n var halfCheckedKeys = arrDel(oriHalfCheckedKeys, key);\n checkedObj = {\n checked: checkedKeys,\n halfChecked: halfCheckedKeys\n };\n eventObj.checkedNodes = checkedKeys.map(function (checkedKey) {\n return keyEntities[checkedKey];\n }).filter(function (entity) {\n return entity;\n }).map(function (entity) {\n return entity.node;\n });\n\n _this.setUncontrolledState({\n checkedKeys: checkedKeys\n });\n } else {\n // Always fill first\n var _conductCheck = conductCheck([].concat(_toConsumableArray(oriCheckedKeys), [key]), true, keyEntities),\n _checkedKeys = _conductCheck.checkedKeys,\n _halfCheckedKeys = _conductCheck.halfCheckedKeys; // If remove, we do it again to correction\n\n\n if (!checked) {\n var keySet = new Set(_checkedKeys);\n keySet.delete(key);\n\n var _conductCheck2 = conductCheck(Array.from(keySet), {\n checked: false,\n halfCheckedKeys: _halfCheckedKeys\n }, keyEntities);\n\n _checkedKeys = _conductCheck2.checkedKeys;\n _halfCheckedKeys = _conductCheck2.halfCheckedKeys;\n }\n\n checkedObj = _checkedKeys; // [Legacy] This is used for `rc-tree-select`\n\n eventObj.checkedNodes = [];\n eventObj.checkedNodesPositions = [];\n eventObj.halfCheckedKeys = _halfCheckedKeys;\n\n _checkedKeys.forEach(function (checkedKey) {\n var entity = keyEntities[checkedKey];\n if (!entity) return;\n var node = entity.node,\n pos = entity.pos;\n eventObj.checkedNodes.push(node);\n eventObj.checkedNodesPositions.push({\n node: node,\n pos: pos\n });\n });\n\n _this.setUncontrolledState({\n checkedKeys: _checkedKeys\n }, false, {\n halfCheckedKeys: _halfCheckedKeys\n });\n }\n\n if (onCheck) {\n onCheck(checkedObj, eventObj);\n }\n };\n\n _this.onNodeLoad = function (treeNode) {\n return new Promise(function (resolve) {\n // We need to get the latest state of loading/loaded keys\n _this.setState(function (_ref) {\n var _ref$loadedKeys = _ref.loadedKeys,\n loadedKeys = _ref$loadedKeys === void 0 ? [] : _ref$loadedKeys,\n _ref$loadingKeys = _ref.loadingKeys,\n loadingKeys = _ref$loadingKeys === void 0 ? [] : _ref$loadingKeys;\n var _this$props3 = _this.props,\n loadData = _this$props3.loadData,\n onLoad = _this$props3.onLoad;\n var key = treeNode.key;\n\n if (!loadData || loadedKeys.indexOf(key) !== -1 || loadingKeys.indexOf(key) !== -1) {\n // react 15 will warn if return null\n return {};\n } // Process load data\n\n\n var promise = loadData(treeNode);\n promise.then(function () {\n var _this$state5 = _this.state,\n currentLoadedKeys = _this$state5.loadedKeys,\n currentLoadingKeys = _this$state5.loadingKeys;\n var newLoadedKeys = arrAdd(currentLoadedKeys, key);\n var newLoadingKeys = arrDel(currentLoadingKeys, key); // onLoad should trigger before internal setState to avoid `loadData` trigger twice.\n // https://github.com/ant-design/ant-design/issues/12464\n\n if (onLoad) {\n onLoad(newLoadedKeys, {\n event: 'load',\n node: treeNode\n });\n }\n\n _this.setUncontrolledState({\n loadedKeys: newLoadedKeys\n });\n\n _this.setState({\n loadingKeys: newLoadingKeys\n });\n\n resolve();\n });\n return {\n loadingKeys: arrAdd(loadingKeys, key)\n };\n });\n });\n };\n\n _this.onNodeMouseEnter = function (event, node) {\n var onMouseEnter = _this.props.onMouseEnter;\n\n if (onMouseEnter) {\n onMouseEnter({\n event: event,\n node: node\n });\n }\n };\n\n _this.onNodeMouseLeave = function (event, node) {\n var onMouseLeave = _this.props.onMouseLeave;\n\n if (onMouseLeave) {\n onMouseLeave({\n event: event,\n node: node\n });\n }\n };\n\n _this.onNodeContextMenu = function (event, node) {\n var onRightClick = _this.props.onRightClick;\n\n if (onRightClick) {\n event.preventDefault();\n onRightClick({\n event: event,\n node: node\n });\n }\n };\n\n _this.onFocus = function () {\n var onFocus = _this.props.onFocus;\n\n _this.setState({\n focused: true\n });\n\n if (onFocus) {\n onFocus.apply(void 0, arguments);\n }\n };\n\n _this.onBlur = function () {\n var onBlur = _this.props.onBlur;\n\n _this.setState({\n focused: false\n });\n\n _this.onActiveChange(null);\n\n if (onBlur) {\n onBlur.apply(void 0, arguments);\n }\n };\n\n _this.getTreeNodeRequiredProps = function () {\n var _this$state6 = _this.state,\n expandedKeys = _this$state6.expandedKeys,\n selectedKeys = _this$state6.selectedKeys,\n loadedKeys = _this$state6.loadedKeys,\n loadingKeys = _this$state6.loadingKeys,\n checkedKeys = _this$state6.checkedKeys,\n halfCheckedKeys = _this$state6.halfCheckedKeys,\n dragOverNodeKey = _this$state6.dragOverNodeKey,\n dropPosition = _this$state6.dropPosition,\n keyEntities = _this$state6.keyEntities;\n return {\n expandedKeys: expandedKeys || [],\n selectedKeys: selectedKeys || [],\n loadedKeys: loadedKeys || [],\n loadingKeys: loadingKeys || [],\n checkedKeys: checkedKeys || [],\n halfCheckedKeys: halfCheckedKeys || [],\n dragOverNodeKey: dragOverNodeKey,\n dropPosition: dropPosition,\n keyEntities: keyEntities\n };\n }; // =========================== Expanded ===========================\n\n /** Set uncontrolled `expandedKeys`. This will also auto update `flattenNodes`. */\n\n\n _this.setExpandedKeys = function (expandedKeys) {\n var treeData = _this.state.treeData;\n var flattenNodes = flattenTreeData(treeData, expandedKeys);\n\n _this.setUncontrolledState({\n expandedKeys: expandedKeys,\n flattenNodes: flattenNodes\n }, true);\n };\n\n _this.onNodeExpand = function (e, treeNode) {\n var expandedKeys = _this.state.expandedKeys;\n var listChanging = _this.state.listChanging;\n var _this$props4 = _this.props,\n onExpand = _this$props4.onExpand,\n loadData = _this$props4.loadData;\n var key = treeNode.key,\n expanded = treeNode.expanded; // Do nothing when motion is in progress\n\n if (listChanging) {\n return;\n } // Update selected keys\n\n\n var index = expandedKeys.indexOf(key);\n var targetExpanded = !expanded;\n warning(expanded && index !== -1 || !expanded && index === -1, 'Expand state not sync with index check');\n\n if (targetExpanded) {\n expandedKeys = arrAdd(expandedKeys, key);\n } else {\n expandedKeys = arrDel(expandedKeys, key);\n }\n\n _this.setExpandedKeys(expandedKeys);\n\n if (onExpand) {\n onExpand(expandedKeys, {\n node: treeNode,\n expanded: targetExpanded,\n nativeEvent: e.nativeEvent\n });\n } // Async Load data\n\n\n if (targetExpanded && loadData) {\n var loadPromise = _this.onNodeLoad(treeNode);\n\n if (loadPromise) {\n loadPromise.then(function () {\n // [Legacy] Refresh logic\n var newFlattenTreeData = flattenTreeData(_this.state.treeData, expandedKeys);\n\n _this.setUncontrolledState({\n flattenNodes: newFlattenTreeData\n });\n });\n }\n }\n };\n\n _this.onListChangeStart = function () {\n _this.setUncontrolledState({\n listChanging: true\n });\n };\n\n _this.onListChangeEnd = function () {\n setTimeout(function () {\n _this.setUncontrolledState({\n listChanging: false\n });\n });\n }; // =========================== Keyboard ===========================\n\n\n _this.onActiveChange = function (newActiveKey) {\n var activeKey = _this.state.activeKey;\n var onActiveChange = _this.props.onActiveChange;\n\n if (activeKey === newActiveKey) {\n return;\n }\n\n _this.setState({\n activeKey: newActiveKey\n });\n\n if (newActiveKey !== null) {\n _this.scrollTo({\n key: newActiveKey\n });\n }\n\n if (onActiveChange) {\n onActiveChange(newActiveKey);\n }\n };\n\n _this.getActiveItem = function () {\n var _this$state7 = _this.state,\n activeKey = _this$state7.activeKey,\n flattenNodes = _this$state7.flattenNodes;\n\n if (activeKey === null) {\n return null;\n }\n\n return flattenNodes.find(function (_ref2) {\n var key = _ref2.data.key;\n return key === activeKey;\n }) || null;\n };\n\n _this.offsetActiveKey = function (offset) {\n var _this$state8 = _this.state,\n flattenNodes = _this$state8.flattenNodes,\n activeKey = _this$state8.activeKey;\n var index = flattenNodes.findIndex(function (_ref3) {\n var key = _ref3.data.key;\n return key === activeKey;\n }); // Align with index\n\n if (index === -1 && offset < 0) {\n index = flattenNodes.length;\n }\n\n index = (index + offset + flattenNodes.length) % flattenNodes.length;\n var item = flattenNodes[index];\n\n if (item) {\n var key = item.data.key;\n\n _this.onActiveChange(key);\n } else {\n _this.onActiveChange(null);\n }\n };\n\n _this.onKeyDown = function (event) {\n var _this$state9 = _this.state,\n activeKey = _this$state9.activeKey,\n expandedKeys = _this$state9.expandedKeys,\n checkedKeys = _this$state9.checkedKeys;\n var _this$props5 = _this.props,\n onKeyDown = _this$props5.onKeyDown,\n checkable = _this$props5.checkable,\n selectable = _this$props5.selectable; // >>>>>>>>>> Direction\n\n switch (event.which) {\n case KeyCode.UP:\n {\n _this.offsetActiveKey(-1);\n\n event.preventDefault();\n break;\n }\n\n case KeyCode.DOWN:\n {\n _this.offsetActiveKey(1);\n\n event.preventDefault();\n break;\n }\n } // >>>>>>>>>> Expand & Selection\n\n\n var activeItem = _this.getActiveItem();\n\n if (activeItem && activeItem.data) {\n var treeNodeRequiredProps = _this.getTreeNodeRequiredProps();\n\n var expandable = activeItem.data.isLeaf === false || !!(activeItem.data.children || []).length;\n var eventNode = convertNodePropsToEventData(_objectSpread(_objectSpread({}, getTreeNodeProps(activeKey, treeNodeRequiredProps)), {}, {\n data: activeItem.data,\n active: true\n }));\n\n switch (event.which) {\n // >>> Expand\n case KeyCode.LEFT:\n {\n // Collapse if possible\n if (expandable && expandedKeys.includes(activeKey)) {\n _this.onNodeExpand({}, eventNode);\n } else if (activeItem.parent) {\n _this.onActiveChange(activeItem.parent.data.key);\n }\n\n event.preventDefault();\n break;\n }\n\n case KeyCode.RIGHT:\n {\n // Expand if possible\n if (expandable && !expandedKeys.includes(activeKey)) {\n _this.onNodeExpand({}, eventNode);\n } else if (activeItem.children && activeItem.children.length) {\n _this.onActiveChange(activeItem.children[0].data.key);\n }\n\n event.preventDefault();\n break;\n }\n // Selection\n\n case KeyCode.ENTER:\n case KeyCode.SPACE:\n {\n if (checkable && !eventNode.disabled && eventNode.checkable !== false && !eventNode.disableCheckbox) {\n _this.onNodeCheck({}, eventNode, !checkedKeys.includes(activeKey));\n } else if (!checkable && selectable && !eventNode.disabled && eventNode.selectable !== false) {\n _this.onNodeSelect({}, eventNode);\n }\n\n break;\n }\n }\n }\n\n if (onKeyDown) {\n onKeyDown(event);\n }\n };\n /**\n * Only update the value which is not in props\n */\n\n\n _this.setUncontrolledState = function (state) {\n var atomic = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n var forceState = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;\n\n if (_this.destroyed) {\n return;\n }\n\n var needSync = false;\n var allPassed = true;\n var newState = {};\n Object.keys(state).forEach(function (name) {\n if (name in _this.props) {\n allPassed = false;\n return;\n }\n\n needSync = true;\n newState[name] = state[name];\n });\n\n if (needSync && (!atomic || allPassed)) {\n _this.setState(_objectSpread(_objectSpread({}, newState), forceState));\n }\n };\n\n _this.scrollTo = function (scroll) {\n _this.listRef.current.scrollTo(scroll);\n };\n\n return _this;\n }\n\n _createClass(Tree, [{\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n this.destroyed = true;\n }\n }, {\n key: \"render\",\n value: function render() {\n var _classNames;\n\n var _this$state10 = this.state,\n focused = _this$state10.focused,\n flattenNodes = _this$state10.flattenNodes,\n keyEntities = _this$state10.keyEntities,\n dragging = _this$state10.dragging,\n activeKey = _this$state10.activeKey;\n var _this$props6 = this.props,\n prefixCls = _this$props6.prefixCls,\n className = _this$props6.className,\n style = _this$props6.style,\n showLine = _this$props6.showLine,\n focusable = _this$props6.focusable,\n _this$props6$tabIndex = _this$props6.tabIndex,\n tabIndex = _this$props6$tabIndex === void 0 ? 0 : _this$props6$tabIndex,\n selectable = _this$props6.selectable,\n showIcon = _this$props6.showIcon,\n icon = _this$props6.icon,\n switcherIcon = _this$props6.switcherIcon,\n draggable = _this$props6.draggable,\n checkable = _this$props6.checkable,\n checkStrictly = _this$props6.checkStrictly,\n disabled = _this$props6.disabled,\n motion = _this$props6.motion,\n loadData = _this$props6.loadData,\n filterTreeNode = _this$props6.filterTreeNode,\n height = _this$props6.height,\n itemHeight = _this$props6.itemHeight,\n virtual = _this$props6.virtual,\n titleRender = _this$props6.titleRender;\n var domProps = getDataAndAria(this.props);\n return React.createElement(TreeContext.Provider, {\n value: {\n prefixCls: prefixCls,\n selectable: selectable,\n showIcon: showIcon,\n icon: icon,\n switcherIcon: switcherIcon,\n draggable: draggable,\n checkable: checkable,\n checkStrictly: checkStrictly,\n disabled: disabled,\n keyEntities: keyEntities,\n loadData: loadData,\n filterTreeNode: filterTreeNode,\n titleRender: titleRender,\n onNodeClick: this.onNodeClick,\n onNodeDoubleClick: this.onNodeDoubleClick,\n onNodeExpand: this.onNodeExpand,\n onNodeSelect: this.onNodeSelect,\n onNodeCheck: this.onNodeCheck,\n onNodeLoad: this.onNodeLoad,\n onNodeMouseEnter: this.onNodeMouseEnter,\n onNodeMouseLeave: this.onNodeMouseLeave,\n onNodeContextMenu: this.onNodeContextMenu,\n onNodeDragStart: this.onNodeDragStart,\n onNodeDragEnter: this.onNodeDragEnter,\n onNodeDragOver: this.onNodeDragOver,\n onNodeDragLeave: this.onNodeDragLeave,\n onNodeDragEnd: this.onNodeDragEnd,\n onNodeDrop: this.onNodeDrop\n }\n }, React.createElement(\"div\", {\n className: classNames(prefixCls, className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-show-line\"), showLine), _defineProperty(_classNames, \"\".concat(prefixCls, \"-focused\"), focused), _defineProperty(_classNames, \"\".concat(prefixCls, \"-active-focused\"), activeKey !== null), _classNames))\n }, React.createElement(NodeList, Object.assign({\n ref: this.listRef,\n prefixCls: prefixCls,\n style: style,\n data: flattenNodes,\n disabled: disabled,\n selectable: selectable,\n checkable: !!checkable,\n motion: motion,\n dragging: dragging,\n height: height,\n itemHeight: itemHeight,\n virtual: virtual,\n focusable: focusable,\n focused: focused,\n tabIndex: tabIndex,\n activeItem: this.getActiveItem(),\n onFocus: this.onFocus,\n onBlur: this.onBlur,\n onKeyDown: this.onKeyDown,\n onActiveChange: this.onActiveChange,\n onListChangeStart: this.onListChangeStart,\n onListChangeEnd: this.onListChangeEnd\n }, this.getTreeNodeRequiredProps(), domProps))));\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(props, prevState) {\n var prevProps = prevState.prevProps;\n var newState = {\n prevProps: props\n };\n\n function needSync(name) {\n return !prevProps && name in props || prevProps && prevProps[name] !== props[name];\n } // ================== Tree Node ==================\n\n\n var treeData; // Check if `treeData` or `children` changed and save into the state.\n\n if (needSync('treeData')) {\n treeData = props.treeData;\n } else if (needSync('children')) {\n warning(false, '`children` of Tree is deprecated. Please use `treeData` instead.');\n treeData = convertTreeToData(props.children);\n } // Save flatten nodes info and convert `treeData` into keyEntities\n\n\n if (treeData) {\n newState.treeData = treeData;\n var entitiesMap = convertDataToEntities(treeData);\n newState.keyEntities = _objectSpread(_defineProperty({}, MOTION_KEY, MotionEntity), entitiesMap.keyEntities); // Warning if treeNode not provide key\n\n if (process.env.NODE_ENV !== 'production') {\n warningWithoutKey(treeData);\n }\n }\n\n var keyEntities = newState.keyEntities || prevState.keyEntities; // ================ expandedKeys =================\n\n if (needSync('expandedKeys') || prevProps && needSync('autoExpandParent')) {\n newState.expandedKeys = props.autoExpandParent || !prevProps && props.defaultExpandParent ? conductExpandParent(props.expandedKeys, keyEntities) : props.expandedKeys;\n } else if (!prevProps && props.defaultExpandAll) {\n var cloneKeyEntities = _objectSpread({}, keyEntities);\n\n delete cloneKeyEntities[MOTION_KEY];\n newState.expandedKeys = Object.keys(cloneKeyEntities).map(function (key) {\n return cloneKeyEntities[key].key;\n });\n } else if (!prevProps && props.defaultExpandedKeys) {\n newState.expandedKeys = props.autoExpandParent || props.defaultExpandParent ? conductExpandParent(props.defaultExpandedKeys, keyEntities) : props.defaultExpandedKeys;\n }\n\n if (!newState.expandedKeys) {\n delete newState.expandedKeys;\n } // ================ flattenNodes =================\n\n\n if (treeData || newState.expandedKeys) {\n var flattenNodes = flattenTreeData(treeData || prevState.treeData, newState.expandedKeys || prevState.expandedKeys);\n newState.flattenNodes = flattenNodes;\n } // ================ selectedKeys =================\n\n\n if (props.selectable) {\n if (needSync('selectedKeys')) {\n newState.selectedKeys = calcSelectedKeys(props.selectedKeys, props);\n } else if (!prevProps && props.defaultSelectedKeys) {\n newState.selectedKeys = calcSelectedKeys(props.defaultSelectedKeys, props);\n }\n } // ================= checkedKeys =================\n\n\n if (props.checkable) {\n var checkedKeyEntity;\n\n if (needSync('checkedKeys')) {\n checkedKeyEntity = parseCheckedKeys(props.checkedKeys) || {};\n } else if (!prevProps && props.defaultCheckedKeys) {\n checkedKeyEntity = parseCheckedKeys(props.defaultCheckedKeys) || {};\n } else if (treeData) {\n // If `treeData` changed, we also need check it\n checkedKeyEntity = parseCheckedKeys(props.checkedKeys) || {\n checkedKeys: prevState.checkedKeys,\n halfCheckedKeys: prevState.halfCheckedKeys\n };\n }\n\n if (checkedKeyEntity) {\n var _checkedKeyEntity = checkedKeyEntity,\n _checkedKeyEntity$che = _checkedKeyEntity.checkedKeys,\n checkedKeys = _checkedKeyEntity$che === void 0 ? [] : _checkedKeyEntity$che,\n _checkedKeyEntity$hal = _checkedKeyEntity.halfCheckedKeys,\n halfCheckedKeys = _checkedKeyEntity$hal === void 0 ? [] : _checkedKeyEntity$hal;\n\n if (!props.checkStrictly) {\n var conductKeys = conductCheck(checkedKeys, true, keyEntities);\n checkedKeys = conductKeys.checkedKeys;\n halfCheckedKeys = conductKeys.halfCheckedKeys;\n }\n\n newState.checkedKeys = checkedKeys;\n newState.halfCheckedKeys = halfCheckedKeys;\n }\n } // ================= loadedKeys ==================\n\n\n if (needSync('loadedKeys')) {\n newState.loadedKeys = props.loadedKeys;\n }\n\n return newState;\n }\n }]);\n\n return Tree;\n}(React.Component);\n\nTree.defaultProps = {\n prefixCls: 'rc-tree',\n showLine: false,\n showIcon: true,\n selectable: true,\n multiple: false,\n checkable: false,\n disabled: false,\n checkStrictly: false,\n draggable: false,\n defaultExpandParent: true,\n autoExpandParent: false,\n defaultExpandAll: false,\n defaultExpandedKeys: [],\n defaultCheckedKeys: [],\n defaultSelectedKeys: []\n};\nTree.TreeNode = TreeNode;\nexport default Tree;","import Tree from './Tree';\nimport TreeNode from './TreeNode';\nexport { TreeNode };\nexport default Tree;","import React from 'react';\nexport var SelectContext = React.createContext(null);","import React from 'react';\nexport function isDisabled(dataNode, skipType) {\n if (!dataNode) {\n return true;\n }\n\n var _dataNode$data = dataNode.data,\n disabled = _dataNode$data.disabled,\n disableCheckbox = _dataNode$data.disableCheckbox;\n\n switch (skipType) {\n case 'select':\n return disabled;\n\n case 'checkbox':\n return disabled || disableCheckbox;\n }\n\n return false;\n}\nexport default function useKeyValueMapping(cacheKeyMap, cacheValueMap) {\n var getEntityByKey = React.useCallback(function (key) {\n var skipType = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'select';\n var ignoreDisabledCheck = arguments.length > 2 ? arguments[2] : undefined;\n var dataNode = cacheKeyMap.get(key);\n\n if (!ignoreDisabledCheck && isDisabled(dataNode, skipType)) {\n return null;\n }\n\n return dataNode;\n }, [cacheKeyMap]);\n var getEntityByValue = React.useCallback(function (value) {\n var skipType = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'select';\n var ignoreDisabledCheck = arguments.length > 2 ? arguments[2] : undefined;\n var dataNode = cacheValueMap.get(value);\n\n if (!ignoreDisabledCheck && isDisabled(dataNode, skipType)) {\n return null;\n }\n\n return dataNode;\n }, [cacheValueMap]);\n return [getEntityByKey, getEntityByValue];\n}","import React from 'react';\n/**\n * Return cached Key Value map with DataNode.\n * Only re-calculate when `flattenOptions` changed.\n */\n\nexport default function useKeyValueMap(flattenOptions) {\n return React.useMemo(function () {\n var cacheKeyMap = new Map();\n var cacheValueMap = new Map(); // Cache options by key\n\n flattenOptions.forEach(function (dataNode) {\n cacheKeyMap.set(dataNode.key, dataNode);\n cacheValueMap.set(dataNode.data.value, dataNode);\n });\n return [cacheKeyMap, cacheValueMap];\n }, [flattenOptions]);\n}","import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport React from 'react';\nimport KeyCode from \"rc-util/es/KeyCode\";\nimport useMemo from \"rc-util/es/hooks/useMemo\";\nimport Tree from 'rc-tree';\nimport { SelectContext } from './Context';\nimport useKeyValueMapping from './hooks/useKeyValueMapping';\nimport useKeyValueMap from './hooks/useKeyValueMap';\nvar HIDDEN_STYLE = {\n width: 0,\n height: 0,\n display: 'flex',\n overflow: 'hidden',\n opacity: 0,\n border: 0,\n padding: 0,\n margin: 0\n};\n\nvar OptionList = function OptionList(props, ref) {\n var prefixCls = props.prefixCls,\n height = props.height,\n itemHeight = props.itemHeight,\n virtual = props.virtual,\n options = props.options,\n flattenOptions = props.flattenOptions,\n multiple = props.multiple,\n searchValue = props.searchValue,\n onSelect = props.onSelect,\n onToggleOpen = props.onToggleOpen,\n open = props.open,\n notFoundContent = props.notFoundContent,\n onMouseEnter = props.onMouseEnter;\n\n var _React$useContext = React.useContext(SelectContext),\n checkable = _React$useContext.checkable,\n checkedKeys = _React$useContext.checkedKeys,\n halfCheckedKeys = _React$useContext.halfCheckedKeys,\n treeExpandedKeys = _React$useContext.treeExpandedKeys,\n treeDefaultExpandAll = _React$useContext.treeDefaultExpandAll,\n treeDefaultExpandedKeys = _React$useContext.treeDefaultExpandedKeys,\n onTreeExpand = _React$useContext.onTreeExpand,\n treeIcon = _React$useContext.treeIcon,\n showTreeIcon = _React$useContext.showTreeIcon,\n switcherIcon = _React$useContext.switcherIcon,\n treeLine = _React$useContext.treeLine,\n treeNodeFilterProp = _React$useContext.treeNodeFilterProp,\n loadData = _React$useContext.loadData,\n treeLoadedKeys = _React$useContext.treeLoadedKeys,\n treeMotion = _React$useContext.treeMotion,\n onTreeLoad = _React$useContext.onTreeLoad;\n\n var treeRef = React.useRef();\n var memoOptions = useMemo(function () {\n return options;\n }, [open, options], function (prev, next) {\n return next[0] && prev[1] !== next[1];\n });\n\n var _useKeyValueMap = useKeyValueMap(flattenOptions),\n _useKeyValueMap2 = _slicedToArray(_useKeyValueMap, 2),\n cacheKeyMap = _useKeyValueMap2[0],\n cacheValueMap = _useKeyValueMap2[1];\n\n var _useKeyValueMapping = useKeyValueMapping(cacheKeyMap, cacheValueMap),\n _useKeyValueMapping2 = _slicedToArray(_useKeyValueMapping, 2),\n getEntityByKey = _useKeyValueMapping2[0],\n getEntityByValue = _useKeyValueMapping2[1]; // ========================== Values ==========================\n\n\n var valueKeys = React.useMemo(function () {\n return checkedKeys.map(function (val) {\n var entity = getEntityByValue(val);\n return entity ? entity.key : null;\n });\n }, [checkedKeys]);\n var mergedCheckedKeys = React.useMemo(function () {\n if (!checkable) {\n return null;\n }\n\n return {\n checked: valueKeys,\n halfChecked: halfCheckedKeys\n };\n }, [valueKeys, halfCheckedKeys, checkable]); // ========================== Scroll ==========================\n\n React.useEffect(function () {\n // Single mode should scroll to current key\n if (open && !multiple && valueKeys.length) {\n var _treeRef$current;\n\n (_treeRef$current = treeRef.current) === null || _treeRef$current === void 0 ? void 0 : _treeRef$current.scrollTo({\n key: valueKeys[0]\n });\n }\n }, [open]); // ========================== Search ==========================\n\n var lowerSearchValue = String(searchValue).toLowerCase();\n\n var filterTreeNode = function filterTreeNode(treeNode) {\n if (!lowerSearchValue) {\n return false;\n }\n\n return String(treeNode[treeNodeFilterProp]).toLowerCase().includes(lowerSearchValue);\n }; // =========================== Keys ===========================\n\n\n var _React$useState = React.useState(treeDefaultExpandedKeys),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n expandedKeys = _React$useState2[0],\n setExpandedKeys = _React$useState2[1];\n\n var _React$useState3 = React.useState(null),\n _React$useState4 = _slicedToArray(_React$useState3, 2),\n searchExpandedKeys = _React$useState4[0],\n setSearchExpandedKeys = _React$useState4[1];\n\n var mergedExpandedKeys = React.useMemo(function () {\n if (treeExpandedKeys) {\n return _toConsumableArray(treeExpandedKeys);\n }\n\n return searchValue ? searchExpandedKeys : expandedKeys;\n }, [expandedKeys, searchExpandedKeys, lowerSearchValue, treeExpandedKeys]);\n React.useEffect(function () {\n if (searchValue) {\n setSearchExpandedKeys(flattenOptions.map(function (o) {\n return o.key;\n }));\n }\n }, [searchValue]);\n\n var onInternalExpand = function onInternalExpand(keys) {\n setExpandedKeys(keys);\n setSearchExpandedKeys(keys);\n\n if (onTreeExpand) {\n onTreeExpand(keys);\n }\n }; // ========================== Events ==========================\n\n\n var onListMouseDown = function onListMouseDown(event) {\n event.preventDefault();\n };\n\n var onInternalSelect = function onInternalSelect(_, _ref) {\n var key = _ref.node.key;\n var entity = getEntityByKey(key, checkable ? 'checkbox' : 'select');\n\n if (entity !== null) {\n onSelect(entity.data.value, {\n selected: !checkedKeys.includes(entity.data.value)\n });\n }\n\n if (!multiple) {\n onToggleOpen(false);\n }\n }; // ========================= Keyboard =========================\n\n\n var _React$useState5 = React.useState(null),\n _React$useState6 = _slicedToArray(_React$useState5, 2),\n activeKey = _React$useState6[0],\n setActiveKey = _React$useState6[1];\n\n var activeEntity = getEntityByKey(activeKey);\n React.useImperativeHandle(ref, function () {\n return {\n onKeyDown: function onKeyDown(event) {\n var _treeRef$current2;\n\n var which = event.which;\n\n switch (which) {\n // >>> Arrow keys\n case KeyCode.UP:\n case KeyCode.DOWN:\n case KeyCode.LEFT:\n case KeyCode.RIGHT:\n (_treeRef$current2 = treeRef.current) === null || _treeRef$current2 === void 0 ? void 0 : _treeRef$current2.onKeyDown(event);\n break;\n // >>> Select item\n\n case KeyCode.ENTER:\n {\n if (activeEntity !== null) {\n onInternalSelect(null, {\n node: {\n key: activeKey\n },\n selected: !checkedKeys.includes(activeEntity.data.value)\n });\n }\n\n break;\n }\n // >>> Close\n\n case KeyCode.ESC:\n {\n onToggleOpen(false);\n }\n }\n },\n onKeyUp: function onKeyUp() {}\n };\n }); // ========================== Render ==========================\n\n if (memoOptions.length === 0) {\n return React.createElement(\"div\", {\n role: \"listbox\",\n className: \"\".concat(prefixCls, \"-empty\"),\n onMouseDown: onListMouseDown\n }, notFoundContent);\n }\n\n var treeProps = {};\n\n if (treeLoadedKeys) {\n treeProps.loadedKeys = treeLoadedKeys;\n }\n\n if (mergedExpandedKeys) {\n treeProps.expandedKeys = mergedExpandedKeys;\n }\n\n return React.createElement(\"div\", {\n onMouseDown: onListMouseDown,\n onMouseEnter: onMouseEnter\n }, activeEntity && open && React.createElement(\"span\", {\n style: HIDDEN_STYLE,\n \"aria-live\": \"assertive\"\n }, activeEntity.data.value), React.createElement(Tree, Object.assign({\n ref: treeRef,\n focusable: false,\n prefixCls: \"\".concat(prefixCls, \"-tree\"),\n treeData: memoOptions,\n height: height,\n itemHeight: itemHeight,\n virtual: virtual,\n multiple: multiple,\n icon: treeIcon,\n showIcon: showTreeIcon,\n switcherIcon: switcherIcon,\n showLine: treeLine,\n loadData: searchValue ? null : loadData,\n motion: treeMotion,\n // We handle keys by out instead tree self\n checkable: checkable,\n checkStrictly: true,\n checkedKeys: mergedCheckedKeys,\n selectedKeys: !checkable ? valueKeys : [],\n defaultExpandAll: treeDefaultExpandAll\n }, treeProps, {\n // Proxy event out\n onActiveChange: setActiveKey,\n onSelect: onInternalSelect,\n onCheck: onInternalSelect,\n onExpand: onInternalExpand,\n onLoad: onTreeLoad,\n filterTreeNode: filterTreeNode\n })));\n};\n\nvar RefOptionList = React.forwardRef(OptionList);\nRefOptionList.displayName = 'OptionList';\nexport default RefOptionList;","/** This is a placeholder, not real render in dom */\nvar TreeNode = function TreeNode() {\n return null;\n};\n\nexport default TreeNode;","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport React from 'react';\nimport toArray from \"rc-util/es/Children/toArray\";\nimport warning from \"rc-util/es/warning\";\nimport TreeNode from '../TreeNode';\nexport function convertChildrenToData(nodes) {\n return toArray(nodes).map(function (node) {\n if (!React.isValidElement(node) || !node.type) {\n return null;\n }\n\n var key = node.key,\n _node$props = node.props,\n children = _node$props.children,\n value = _node$props.value,\n restProps = _objectWithoutProperties(_node$props, [\"children\", \"value\"]);\n\n var data = _objectSpread({\n key: key,\n value: value\n }, restProps);\n\n var childData = convertChildrenToData(children);\n\n if (childData.length) {\n data.children = childData;\n }\n\n return data;\n }).filter(function (data) {\n return data;\n });\n}\nexport function fillLegacyProps(dataNode) {\n // Skip if not dataNode exist\n if (!dataNode) {\n return dataNode;\n }\n\n var cloneNode = _objectSpread({}, dataNode);\n\n if (!('props' in cloneNode)) {\n Object.defineProperty(cloneNode, 'props', {\n get: function get() {\n warning(false, 'New `rc-tree-select` not support return node instance as argument anymore. Please consider to remove `props` access.');\n return cloneNode;\n }\n });\n }\n\n return cloneNode;\n}\nexport function fillAdditionalInfo(extra, triggerValue, checkedValues, treeData, showPosition) {\n var triggerNode = null;\n var nodeList = null;\n\n function generateMap() {\n function dig(list) {\n var level = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '0';\n var parentIncluded = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n return list.map(function (dataNode, index) {\n var pos = \"\".concat(level, \"-\").concat(index);\n var included = checkedValues.includes(dataNode.value);\n var children = dig(dataNode.children || [], pos, included);\n var node = React.createElement(TreeNode, Object.assign({}, dataNode), children.map(function (child) {\n return child.node;\n })); // Link with trigger node\n\n if (triggerValue === dataNode.value) {\n triggerNode = node;\n }\n\n if (included) {\n var checkedNode = {\n pos: pos,\n node: node,\n children: children\n };\n\n if (!parentIncluded) {\n nodeList.push(checkedNode);\n }\n\n return checkedNode;\n }\n\n return null;\n }).filter(function (node) {\n return node;\n });\n }\n\n if (!nodeList) {\n nodeList = [];\n dig(treeData); // Sort to keep the checked node length\n\n nodeList.sort(function (_ref, _ref2) {\n var val1 = _ref.node.props.value;\n var val2 = _ref2.node.props.value;\n var index1 = checkedValues.indexOf(val1);\n var index2 = checkedValues.indexOf(val2);\n return index1 - index2;\n });\n }\n }\n\n Object.defineProperty(extra, 'triggerNode', {\n get: function get() {\n warning(false, '`triggerNode` is deprecated. Please consider decoupling data with node.');\n generateMap();\n return triggerNode;\n }\n });\n Object.defineProperty(extra, 'allCheckedNodes', {\n get: function get() {\n warning(false, '`allCheckedNodes` is deprecated. Please consider decoupling data with node.');\n generateMap();\n\n if (showPosition) {\n return nodeList;\n }\n\n return nodeList.map(function (_ref3) {\n var node = _ref3.node;\n return node;\n });\n }\n });\n}","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport { flattenTreeData } from \"rc-tree/es/utils/treeUtil\";\nimport { fillLegacyProps } from './legacyUtil';\nexport function toArray(value) {\n if (Array.isArray(value)) {\n return value;\n }\n\n return value !== undefined ? [value] : [];\n}\nexport function findValueOption(values, options) {\n var optionMap = new Map();\n options.forEach(function (flattenItem) {\n var data = flattenItem.data;\n optionMap.set(data.value, data);\n });\n return values.map(function (val) {\n return fillLegacyProps(optionMap.get(val));\n });\n}\nexport function isValueDisabled(value, options) {\n var option = findValueOption([value], options)[0];\n\n if (option) {\n return option.disabled;\n }\n\n return false;\n}\nexport function isCheckDisabled(node) {\n return node.disabled || node.disableCheckbox || node.checkable === false;\n}\n\nfunction getLevel(_ref) {\n var parent = _ref.parent;\n var level = 0;\n var current = parent;\n\n while (current) {\n current = current.parent;\n level += 1;\n }\n\n return level;\n}\n/**\n * Before reuse `rc-tree` logic, we need to add key since TreeSelect use `value` instead of `key`.\n */\n\n\nexport function flattenOptions(options) {\n // Add missing key\n function fillKey(list) {\n return (list || []).map(function (node) {\n var value = node.value,\n key = node.key,\n children = node.children;\n\n var clone = _objectSpread(_objectSpread({}, node), {}, {\n key: 'key' in node ? key : value\n });\n\n if (children) {\n clone.children = fillKey(children);\n }\n\n return clone;\n });\n }\n\n var flattenList = flattenTreeData(fillKey(options), true);\n return flattenList.map(function (node) {\n return {\n key: node.data.key,\n data: node.data,\n level: getLevel(node)\n };\n });\n}\n\nfunction getDefaultFilterOption(optionFilterProp) {\n return function (searchValue, dataNode) {\n var value = dataNode[optionFilterProp];\n return String(value).toLowerCase().includes(String(searchValue).toLowerCase());\n };\n}\n/** Filter options and return a new options by the search text */\n\n\nexport function filterOptions(searchValue, options, _ref2) {\n var optionFilterProp = _ref2.optionFilterProp,\n filterOption = _ref2.filterOption;\n\n if (filterOption === false) {\n return options;\n }\n\n var filterOptionFunc;\n\n if (typeof filterOption === 'function') {\n filterOptionFunc = filterOption;\n } else {\n filterOptionFunc = getDefaultFilterOption(optionFilterProp);\n }\n\n function dig(list) {\n var keepAll = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n return list.map(function (dataNode) {\n var children = dataNode.children;\n var match = keepAll || filterOptionFunc(searchValue, fillLegacyProps(dataNode));\n var childList = dig(children || [], match);\n\n if (match || childList.length) {\n return _objectSpread(_objectSpread({}, dataNode), {}, {\n children: childList\n });\n }\n\n return null;\n }).filter(function (node) {\n return node;\n });\n }\n\n return dig(options);\n}\nexport function getRawValueLabeled(values, prevValue, getEntityByValue, getLabelProp) {\n var valueMap = new Map();\n toArray(prevValue).forEach(function (item) {\n if (item && _typeof(item) === 'object' && 'value' in item) {\n valueMap.set(item.value, item);\n }\n });\n return values.map(function (val) {\n var item = {\n value: val\n };\n var entity = getEntityByValue(val, 'select', true);\n var label = entity ? getLabelProp(entity.data) : val;\n\n if (valueMap.has(val)) {\n var labeledValue = valueMap.get(val);\n item.label = 'label' in labeledValue ? labeledValue.label : label;\n\n if ('halfChecked' in labeledValue) {\n item.halfChecked = labeledValue.halfChecked;\n }\n } else {\n item.label = label;\n }\n\n return item;\n });\n}\nexport function addValue(rawValues, value) {\n var values = new Set(rawValues);\n values.add(value);\n return Array.from(values);\n}\nexport function removeValue(rawValues, value) {\n var values = new Set(rawValues);\n values.delete(value);\n return Array.from(values);\n}","import _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport React from 'react';\nimport warning from \"rc-util/es/warning\";\nimport { convertChildrenToData } from '../utils/legacyUtil';\nvar MAX_WARNING_TIMES = 10;\n\nfunction parseSimpleTreeData(treeData, _ref) {\n var id = _ref.id,\n pId = _ref.pId,\n rootPId = _ref.rootPId;\n var keyNodes = {};\n var rootNodeList = []; // Fill in the map\n\n var nodeList = treeData.map(function (node) {\n var clone = _objectSpread({}, node);\n\n var key = clone[id];\n keyNodes[key] = clone;\n clone.key = clone.key || key;\n return clone;\n }); // Connect tree\n\n nodeList.forEach(function (node) {\n var parentKey = node[pId];\n var parent = keyNodes[parentKey]; // Fill parent\n\n if (parent) {\n parent.children = parent.children || [];\n parent.children.push(node);\n } // Fill root tree node\n\n\n if (parentKey === rootPId || !parent && rootPId === null) {\n rootNodeList.push(node);\n }\n });\n return rootNodeList;\n}\n/**\n * Format `treeData` with `value` & `key` which is used for calculation\n */\n\n\nfunction formatTreeData(treeData, getLabelProp) {\n var warningTimes = 0;\n var valueSet = new Set();\n\n function dig(dataNodes) {\n return (dataNodes || []).map(function (node) {\n var key = node.key,\n value = node.value,\n children = node.children,\n rest = _objectWithoutProperties(node, [\"key\", \"value\", \"children\"]);\n\n var mergedValue = 'value' in node ? value : key;\n\n var dataNode = _objectSpread(_objectSpread({}, rest), {}, {\n key: key !== null && key !== undefined ? key : mergedValue,\n value: mergedValue,\n title: getLabelProp(node)\n }); // Check `key` & `value` and warning user\n\n\n if (process.env.NODE_ENV !== 'production') {\n if (key !== null && key !== undefined && value !== undefined && String(key) !== String(value) && warningTimes < MAX_WARNING_TIMES) {\n warningTimes += 1;\n warning(false, \"`key` or `value` with TreeNode must be the same or you can remove one of them. key: \".concat(key, \", value: \").concat(value, \".\"));\n }\n\n warning(!valueSet.has(value), \"Same `value` exist in the tree: \".concat(value));\n valueSet.add(value);\n }\n\n if ('children' in node) {\n dataNode.children = dig(children);\n }\n\n return dataNode;\n });\n }\n\n return dig(treeData);\n}\n/**\n * Convert `treeData` or `children` into formatted `treeData`.\n * Will not re-calculate if `treeData` or `children` not change.\n */\n\n\nexport default function useTreeData(treeData, children, _ref2) {\n var getLabelProp = _ref2.getLabelProp,\n simpleMode = _ref2.simpleMode;\n var cacheRef = React.useRef({});\n\n if (treeData) {\n cacheRef.current.formatTreeData = cacheRef.current.treeData === treeData ? cacheRef.current.formatTreeData : formatTreeData(simpleMode ? parseSimpleTreeData(treeData, _objectSpread({\n id: 'id',\n pId: 'pId',\n rootPId: null\n }, simpleMode !== true ? simpleMode : {})) : treeData, getLabelProp);\n cacheRef.current.treeData = treeData;\n } else {\n cacheRef.current.formatTreeData = cacheRef.current.children === children ? cacheRef.current.formatTreeData : formatTreeData(convertChildrenToData(children), getLabelProp);\n }\n\n return cacheRef.current.formatTreeData;\n}","import { isCheckDisabled } from './valueUtil';\nexport var SHOW_ALL = 'SHOW_ALL';\nexport var SHOW_PARENT = 'SHOW_PARENT';\nexport var SHOW_CHILD = 'SHOW_CHILD';\nexport function formatStrategyKeys(keys, strategy, keyEntities) {\n var keySet = new Set(keys);\n\n if (strategy === SHOW_CHILD) {\n return keys.filter(function (key) {\n var entity = keyEntities[key];\n\n if (entity && entity.children && entity.children.every(function (_ref) {\n var node = _ref.node;\n return isCheckDisabled(node) || keySet.has(node.key);\n })) {\n return false;\n }\n\n return true;\n });\n }\n\n if (strategy === SHOW_PARENT) {\n return keys.filter(function (key) {\n var entity = keyEntities[key];\n var parent = entity ? entity.parent : null;\n\n if (parent && !isCheckDisabled(parent.node) && keySet.has(parent.node.key)) {\n return false;\n }\n\n return true;\n });\n }\n\n return keys;\n}","import _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport * as React from 'react';\nimport { useMemo } from 'react';\nimport generateSelector from \"rc-select/es/generate\";\nimport { getLabeledValue } from \"rc-select/es/utils/valueUtil\";\nimport { convertDataToEntities } from \"rc-tree/es/utils/treeUtil\";\nimport { conductCheck } from \"rc-tree/es/utils/conductUtil\";\nimport { INTERNAL_PROPS_MARK } from \"rc-select/es/interface/generator\";\nimport useMergedState from \"rc-util/es/hooks/useMergedState\";\nimport warning from \"rc-util/es/warning\";\nimport OptionList from './OptionList';\nimport TreeNode from './TreeNode';\nimport { flattenOptions, filterOptions, isValueDisabled, findValueOption, addValue, removeValue, getRawValueLabeled, toArray } from './utils/valueUtil';\nimport warningProps from './utils/warningPropsUtil';\nimport { SelectContext } from './Context';\nimport useTreeData from './hooks/useTreeData';\nimport useKeyValueMap from './hooks/useKeyValueMap';\nimport useKeyValueMapping from './hooks/useKeyValueMapping';\nimport { formatStrategyKeys, SHOW_ALL, SHOW_PARENT, SHOW_CHILD } from './utils/strategyUtil';\nimport { fillAdditionalInfo } from './utils/legacyUtil';\nimport useSelectValues from './hooks/useSelectValues';\nvar OMIT_PROPS = ['expandedKeys', 'treeData', 'treeCheckable', 'showCheckedStrategy', 'searchPlaceholder', 'treeLine', 'treeIcon', 'showTreeIcon', 'switcherIcon', 'treeNodeFilterProp', 'filterTreeNode', 'dropdownPopupAlign', 'treeDefaultExpandAll', 'treeCheckStrictly', 'treeExpandedKeys', 'treeLoadedKeys', 'treeMotion', 'onTreeExpand', 'onTreeLoad', 'loadData', 'treeDataSimpleMode', 'treeNodeLabelProp', 'treeDefaultExpandedKeys'];\nvar RefSelect = generateSelector({\n prefixCls: 'rc-tree-select',\n components: {\n optionList: OptionList\n },\n // Not use generate since we will handle ourself\n convertChildrenToData: function convertChildrenToData() {\n return null;\n },\n flattenOptions: flattenOptions,\n // Handle `optionLabelProp` in TreeSelect component\n getLabeledValue: getLabeledValue,\n filterOptions: filterOptions,\n isValueDisabled: isValueDisabled,\n findValueOption: findValueOption,\n omitDOMProps: function omitDOMProps(props) {\n var cloneProps = _objectSpread({}, props);\n\n OMIT_PROPS.forEach(function (prop) {\n delete cloneProps[prop];\n });\n return cloneProps;\n }\n});\nRefSelect.displayName = 'Select';\nvar RefTreeSelect = React.forwardRef(function (props, ref) {\n var multiple = props.multiple,\n treeCheckable = props.treeCheckable,\n treeCheckStrictly = props.treeCheckStrictly,\n _props$showCheckedStr = props.showCheckedStrategy,\n showCheckedStrategy = _props$showCheckedStr === void 0 ? 'SHOW_CHILD' : _props$showCheckedStr,\n labelInValue = props.labelInValue,\n loadData = props.loadData,\n treeLoadedKeys = props.treeLoadedKeys,\n _props$treeNodeFilter = props.treeNodeFilterProp,\n treeNodeFilterProp = _props$treeNodeFilter === void 0 ? 'value' : _props$treeNodeFilter,\n treeNodeLabelProp = props.treeNodeLabelProp,\n treeDataSimpleMode = props.treeDataSimpleMode,\n treeData = props.treeData,\n treeExpandedKeys = props.treeExpandedKeys,\n treeDefaultExpandedKeys = props.treeDefaultExpandedKeys,\n treeDefaultExpandAll = props.treeDefaultExpandAll,\n children = props.children,\n treeIcon = props.treeIcon,\n showTreeIcon = props.showTreeIcon,\n switcherIcon = props.switcherIcon,\n treeLine = props.treeLine,\n treeMotion = props.treeMotion,\n filterTreeNode = props.filterTreeNode,\n dropdownPopupAlign = props.dropdownPopupAlign,\n onChange = props.onChange,\n onTreeExpand = props.onTreeExpand,\n onTreeLoad = props.onTreeLoad,\n onDropdownVisibleChange = props.onDropdownVisibleChange,\n onSelect = props.onSelect,\n onDeselect = props.onDeselect;\n var mergedCheckable = treeCheckable || treeCheckStrictly;\n var mergedMultiple = multiple || mergedCheckable;\n var treeConduction = treeCheckable && !treeCheckStrictly;\n var mergedLabelInValue = treeCheckStrictly || labelInValue; // ========================== Ref ==========================\n\n var selectRef = React.useRef(null);\n React.useImperativeHandle(ref, function () {\n return {\n focus: selectRef.current.focus,\n blur: selectRef.current.blur\n };\n }); // ======================= Tree Data =======================\n // Legacy both support `label` or `title` if not set.\n // We have to fallback to function to handle this\n\n var getTreeNodeTitle = function getTreeNodeTitle(node) {\n if (!treeData) {\n return node.title;\n }\n\n return node.label || node.title;\n };\n\n var getTreeNodeLabelProp = function getTreeNodeLabelProp(node) {\n if (treeNodeLabelProp) {\n return node[treeNodeLabelProp];\n }\n\n return getTreeNodeTitle(node);\n };\n\n var mergedTreeData = useTreeData(treeData, children, {\n getLabelProp: getTreeNodeTitle,\n simpleMode: treeDataSimpleMode\n });\n var flattedOptions = useMemo(function () {\n return flattenOptions(mergedTreeData);\n }, [mergedTreeData]);\n\n var _useKeyValueMap = useKeyValueMap(flattedOptions),\n _useKeyValueMap2 = _slicedToArray(_useKeyValueMap, 2),\n cacheKeyMap = _useKeyValueMap2[0],\n cacheValueMap = _useKeyValueMap2[1];\n\n var _useKeyValueMapping = useKeyValueMapping(cacheKeyMap, cacheValueMap),\n _useKeyValueMapping2 = _slicedToArray(_useKeyValueMapping, 2),\n getEntityByKey = _useKeyValueMapping2[0],\n getEntityByValue = _useKeyValueMapping2[1]; // Only generate keyEntities for check conduction when is `treeCheckable`\n\n\n var _useMemo = useMemo(function () {\n if (treeConduction) {\n return convertDataToEntities(mergedTreeData);\n }\n\n return {\n keyEntities: null\n };\n }, [mergedTreeData, treeCheckable, treeCheckStrictly]),\n conductKeyEntities = _useMemo.keyEntities; // ========================= Value =========================\n\n\n var _useMergedState = useMergedState(props.defaultValue, {\n value: props.value\n }),\n _useMergedState2 = _slicedToArray(_useMergedState, 2),\n value = _useMergedState2[0],\n setValue = _useMergedState2[1];\n /** Get `missingRawValues` which not exist in the tree yet */\n\n\n var splitRawValues = function splitRawValues(newRawValues) {\n var missingRawValues = [];\n var existRawValues = []; // Keep missing value in the cache\n\n newRawValues.forEach(function (val) {\n if (getEntityByValue(val)) {\n existRawValues.push(val);\n } else {\n missingRawValues.push(val);\n }\n });\n return {\n missingRawValues: missingRawValues,\n existRawValues: existRawValues\n };\n };\n\n var _useMemo2 = useMemo(function () {\n var valueHalfCheckedKeys = [];\n var newRawValues = [];\n toArray(value).forEach(function (item) {\n if (item && _typeof(item) === 'object' && 'value' in item) {\n if (item.halfChecked && treeCheckStrictly) {\n var entity = getEntityByValue(item.value);\n valueHalfCheckedKeys.push(entity ? entity.key : item.value);\n } else {\n newRawValues.push(item.value);\n }\n } else {\n newRawValues.push(item);\n }\n }); // We need do conduction of values\n\n if (treeConduction) {\n var _splitRawValues = splitRawValues(newRawValues),\n missingRawValues = _splitRawValues.missingRawValues,\n existRawValues = _splitRawValues.existRawValues;\n\n var keyList = existRawValues.map(function (val) {\n return getEntityByValue(val).key;\n });\n\n var _conductCheck = conductCheck(keyList, true, conductKeyEntities),\n checkedKeys = _conductCheck.checkedKeys,\n halfCheckedKeys = _conductCheck.halfCheckedKeys;\n\n return [[].concat(_toConsumableArray(missingRawValues), _toConsumableArray(checkedKeys.map(function (key) {\n return getEntityByKey(key).data.value;\n }))), halfCheckedKeys];\n }\n\n return [newRawValues, valueHalfCheckedKeys];\n }, [value, mergedMultiple, mergedLabelInValue, treeCheckable, treeCheckStrictly]),\n _useMemo3 = _slicedToArray(_useMemo2, 2),\n rawValues = _useMemo3[0],\n rawHalfCheckedKeys = _useMemo3[1];\n\n var selectValues = useSelectValues(rawValues, {\n treeConduction: treeConduction,\n value: value,\n showCheckedStrategy: showCheckedStrategy,\n conductKeyEntities: conductKeyEntities,\n getEntityByValue: getEntityByValue,\n getEntityByKey: getEntityByKey,\n getLabelProp: getTreeNodeLabelProp\n });\n\n var triggerChange = function triggerChange(newRawValues, extra, source) {\n setValue(mergedMultiple ? newRawValues : newRawValues[0]);\n\n if (onChange) {\n var eventValues = newRawValues;\n\n if (treeConduction && showCheckedStrategy !== 'SHOW_ALL') {\n var keyList = newRawValues.map(function (val) {\n var entity = getEntityByValue(val);\n return entity ? entity.key : val;\n });\n var formattedKeyList = formatStrategyKeys(keyList, showCheckedStrategy, conductKeyEntities);\n eventValues = formattedKeyList.map(function (key) {\n var entity = getEntityByKey(key);\n return entity ? entity.data.value : key;\n });\n }\n\n var _ref = extra || {\n triggerValue: undefined,\n selected: undefined\n },\n triggerValue = _ref.triggerValue,\n selected = _ref.selected;\n\n var returnValues = mergedLabelInValue ? getRawValueLabeled(eventValues, value, getEntityByValue, getTreeNodeLabelProp) : eventValues; // We need fill half check back\n\n if (treeCheckStrictly) {\n var halfValues = rawHalfCheckedKeys.map(function (key) {\n var entity = getEntityByKey(key);\n return entity ? entity.data.value : key;\n }).filter(function (val) {\n return !eventValues.includes(val);\n });\n returnValues = [].concat(_toConsumableArray(returnValues), _toConsumableArray(getRawValueLabeled(halfValues, value, getEntityByValue, getTreeNodeLabelProp)));\n }\n\n var additionalInfo = {\n // [Legacy] Always return as array contains label & value\n preValue: selectValues,\n triggerValue: triggerValue\n }; // [Legacy] Fill legacy data if user query.\n // This is expansive that we only fill when user query\n // https://github.com/react-component/tree-select/blob/fe33eb7c27830c9ac70cd1fdb1ebbe7bc679c16a/src/Select.jsx\n\n var showPosition = true;\n\n if (treeCheckStrictly || source === 'selection' && !selected) {\n showPosition = false;\n }\n\n fillAdditionalInfo(additionalInfo, triggerValue, newRawValues, mergedTreeData, showPosition);\n\n if (mergedCheckable) {\n additionalInfo.checked = selected;\n } else {\n additionalInfo.selected = selected;\n }\n\n onChange(mergedMultiple ? returnValues : returnValues[0], mergedLabelInValue ? null : eventValues.map(function (val) {\n var entity = getEntityByValue(val);\n return entity ? getTreeNodeLabelProp(entity.data) : null;\n }), additionalInfo);\n }\n };\n\n var onInternalSelect = function onInternalSelect(selectValue, option, source) {\n var eventValue = mergedLabelInValue ? selectValue : selectValue;\n\n if (!mergedMultiple) {\n // Single mode always set value\n triggerChange([selectValue], {\n selected: true,\n triggerValue: selectValue\n }, source);\n } else {\n var newRawValues = addValue(rawValues, selectValue); // Add keys if tree conduction\n\n if (treeConduction) {\n // Should keep missing values\n var _splitRawValues2 = splitRawValues(newRawValues),\n missingRawValues = _splitRawValues2.missingRawValues,\n existRawValues = _splitRawValues2.existRawValues;\n\n var keyList = existRawValues.map(function (val) {\n return getEntityByValue(val).key;\n });\n\n var _conductCheck2 = conductCheck(keyList, true, conductKeyEntities),\n checkedKeys = _conductCheck2.checkedKeys;\n\n newRawValues = [].concat(_toConsumableArray(missingRawValues), _toConsumableArray(checkedKeys.map(function (key) {\n return getEntityByKey(key).data.value;\n })));\n }\n\n triggerChange(newRawValues, {\n selected: true,\n triggerValue: selectValue\n }, source);\n }\n\n if (onSelect) {\n onSelect(eventValue, option);\n }\n };\n\n var onInternalDeselect = function onInternalDeselect(selectValue, option, source) {\n var eventValue = mergedLabelInValue ? selectValue : selectValue;\n var newRawValues = removeValue(rawValues, selectValue); // Remove keys if tree conduction\n\n if (treeConduction) {\n var _splitRawValues3 = splitRawValues(newRawValues),\n missingRawValues = _splitRawValues3.missingRawValues,\n existRawValues = _splitRawValues3.existRawValues;\n\n var keyList = existRawValues.map(function (val) {\n return getEntityByValue(val).key;\n });\n\n var _conductCheck3 = conductCheck(keyList, {\n checked: false,\n halfCheckedKeys: rawHalfCheckedKeys\n }, conductKeyEntities),\n checkedKeys = _conductCheck3.checkedKeys;\n\n newRawValues = [].concat(_toConsumableArray(missingRawValues), _toConsumableArray(checkedKeys.map(function (key) {\n return getEntityByKey(key).data.value;\n })));\n }\n\n triggerChange(newRawValues, {\n selected: false,\n triggerValue: selectValue\n }, source);\n\n if (onDeselect) {\n onDeselect(eventValue, option);\n }\n };\n\n var onInternalClear = function onInternalClear() {\n triggerChange([], null, 'clear');\n }; // ========================= Open ==========================\n\n\n var onInternalDropdownVisibleChange = React.useCallback(function (open) {\n if (onDropdownVisibleChange) {\n var legacyParam = {};\n Object.defineProperty(legacyParam, 'documentClickClose', {\n get: function get() {\n warning(false, 'Second param of `onDropdownVisibleChange` has been removed.');\n return false;\n }\n });\n onDropdownVisibleChange(open, legacyParam);\n }\n }, [onDropdownVisibleChange]); // ======================== Warning ========================\n\n if (process.env.NODE_ENV !== 'production') {\n warningProps(props);\n } // ======================== Render =========================\n // We pass some props into select props style\n\n\n var selectProps = {\n optionLabelProp: null,\n optionFilterProp: treeNodeFilterProp,\n dropdownAlign: dropdownPopupAlign,\n internalProps: {\n mark: INTERNAL_PROPS_MARK,\n onClear: onInternalClear,\n skipTriggerChange: true,\n skipTriggerSelect: true,\n onRawSelect: onInternalSelect,\n onRawDeselect: onInternalDeselect\n }\n };\n\n if ('filterTreeNode' in props) {\n selectProps.filterOption = filterTreeNode;\n }\n\n return React.createElement(SelectContext.Provider, {\n value: {\n checkable: mergedCheckable,\n loadData: loadData,\n treeLoadedKeys: treeLoadedKeys,\n onTreeLoad: onTreeLoad,\n checkedKeys: rawValues,\n halfCheckedKeys: rawHalfCheckedKeys,\n treeDefaultExpandAll: treeDefaultExpandAll,\n treeExpandedKeys: treeExpandedKeys,\n treeDefaultExpandedKeys: treeDefaultExpandedKeys,\n onTreeExpand: onTreeExpand,\n treeIcon: treeIcon,\n treeMotion: treeMotion,\n showTreeIcon: showTreeIcon,\n switcherIcon: switcherIcon,\n treeLine: treeLine,\n treeNodeFilterProp: treeNodeFilterProp\n }\n }, React.createElement(RefSelect, Object.assign({\n ref: selectRef,\n mode: mergedMultiple ? 'multiple' : null\n }, props, selectProps, {\n value: selectValues,\n // We will handle this ourself since we need calculate conduction\n labelInValue: true,\n options: mergedTreeData,\n onChange: null,\n onSelect: null,\n onDeselect: null,\n onDropdownVisibleChange: onInternalDropdownVisibleChange\n })));\n}); // Use class component since typescript not support generic\n// by `forwardRef` with function component yet.\n\nvar TreeSelect = /*#__PURE__*/function (_React$Component) {\n _inherits(TreeSelect, _React$Component);\n\n var _super = _createSuper(TreeSelect);\n\n function TreeSelect() {\n var _this;\n\n _classCallCheck(this, TreeSelect);\n\n _this = _super.apply(this, arguments);\n _this.selectRef = React.createRef();\n\n _this.focus = function () {\n _this.selectRef.current.focus();\n };\n\n _this.blur = function () {\n _this.selectRef.current.blur();\n };\n\n return _this;\n }\n\n _createClass(TreeSelect, [{\n key: \"render\",\n value: function render() {\n return React.createElement(RefTreeSelect, Object.assign({\n ref: this.selectRef\n }, this.props));\n }\n }]);\n\n return TreeSelect;\n}(React.Component);\n\nTreeSelect.TreeNode = TreeNode;\nTreeSelect.SHOW_ALL = SHOW_ALL;\nTreeSelect.SHOW_PARENT = SHOW_PARENT;\nTreeSelect.SHOW_CHILD = SHOW_CHILD;\nexport default TreeSelect;","import React from 'react';\nimport { getRawValueLabeled } from '../utils/valueUtil';\nimport { formatStrategyKeys } from '../utils/strategyUtil';\n/** Return */\n\nexport default function useSelectValues(rawValues, _ref) {\n var value = _ref.value,\n getEntityByValue = _ref.getEntityByValue,\n getEntityByKey = _ref.getEntityByKey,\n treeConduction = _ref.treeConduction,\n showCheckedStrategy = _ref.showCheckedStrategy,\n conductKeyEntities = _ref.conductKeyEntities,\n getLabelProp = _ref.getLabelProp;\n return React.useMemo(function () {\n var mergedRawValues = rawValues;\n\n if (treeConduction) {\n var rawKeys = formatStrategyKeys(rawValues.map(function (val) {\n var entity = getEntityByValue(val);\n return entity ? entity.key : val;\n }), showCheckedStrategy, conductKeyEntities);\n mergedRawValues = rawKeys.map(function (key) {\n var entity = getEntityByKey(key);\n return entity ? entity.data.value : key;\n });\n }\n\n return getRawValueLabeled(mergedRawValues, value, getEntityByValue, getLabelProp);\n }, [rawValues, value, treeConduction, showCheckedStrategy, getEntityByValue]);\n}","import TreeSelect from './TreeSelect';\nimport TreeNode from './TreeNode';\nimport { SHOW_ALL, SHOW_CHILD, SHOW_PARENT } from './utils/strategyUtil';\nexport { TreeNode, SHOW_ALL, SHOW_CHILD, SHOW_PARENT };\nexport default TreeSelect;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\nimport * as React from 'react';\nimport RcTreeSelect, { TreeNode, SHOW_ALL, SHOW_PARENT, SHOW_CHILD } from 'rc-tree-select';\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport { ConfigConsumer } from '../config-provider';\nimport devWarning from '../_util/devWarning';\nimport getIcons from '../select/utils/iconUtil';\nimport renderSwitcherIcon from '../tree/utils/iconUtil';\nimport SizeContext from '../config-provider/SizeContext';\n\nvar TreeSelect = /*#__PURE__*/function (_React$Component) {\n _inherits(TreeSelect, _React$Component);\n\n var _super = _createSuper(TreeSelect);\n\n function TreeSelect(props) {\n var _this;\n\n _classCallCheck(this, TreeSelect);\n\n _this = _super.call(this, props);\n _this.selectRef = /*#__PURE__*/React.createRef();\n\n _this.renderTreeSelect = function (_ref) {\n var getContextPopupContainer = _ref.getPopupContainer,\n getPrefixCls = _ref.getPrefixCls,\n renderEmpty = _ref.renderEmpty,\n direction = _ref.direction,\n virtual = _ref.virtual,\n dropdownMatchSelectWidth = _ref.dropdownMatchSelectWidth;\n var _this$props = _this.props,\n customizePrefixCls = _this$props.prefixCls,\n customizeSize = _this$props.size,\n className = _this$props.className,\n treeCheckable = _this$props.treeCheckable,\n multiple = _this$props.multiple,\n _this$props$listHeigh = _this$props.listHeight,\n listHeight = _this$props$listHeigh === void 0 ? 256 : _this$props$listHeigh,\n _this$props$listItemH = _this$props.listItemHeight,\n listItemHeight = _this$props$listItemH === void 0 ? 26 : _this$props$listItemH,\n notFoundContent = _this$props.notFoundContent,\n _switcherIcon = _this$props.switcherIcon,\n treeLine = _this$props.treeLine,\n getPopupContainer = _this$props.getPopupContainer,\n dropdownClassName = _this$props.dropdownClassName,\n bordered = _this$props.bordered,\n _this$props$treeIcon = _this$props.treeIcon,\n treeIcon = _this$props$treeIcon === void 0 ? false : _this$props$treeIcon;\n var prefixCls = getPrefixCls('select', customizePrefixCls);\n var treePrefixCls = getPrefixCls('select-tree', customizePrefixCls);\n var treeSelectPrefixCls = getPrefixCls('tree-select', customizePrefixCls);\n var mergedDropdownClassName = classNames(dropdownClassName, \"\".concat(treeSelectPrefixCls, \"-dropdown\"), _defineProperty({}, \"\".concat(treeSelectPrefixCls, \"-dropdown-rtl\"), direction === 'rtl'));\n var isMultiple = !!(treeCheckable || multiple); // ===================== Icons =====================\n\n var _getIcons = getIcons(_extends(_extends({}, _this.props), {\n multiple: isMultiple,\n prefixCls: prefixCls\n })),\n suffixIcon = _getIcons.suffixIcon,\n itemIcon = _getIcons.itemIcon,\n removeIcon = _getIcons.removeIcon,\n clearIcon = _getIcons.clearIcon; // ===================== Empty =====================\n\n\n var mergedNotFound;\n\n if (notFoundContent !== undefined) {\n mergedNotFound = notFoundContent;\n } else {\n mergedNotFound = renderEmpty('Select');\n } // ==================== Render =====================\n\n\n var selectProps = omit(_this.props, ['prefixCls', 'suffixIcon', 'itemIcon', 'removeIcon', 'clearIcon', 'switcherIcon', 'size', 'bordered']);\n return /*#__PURE__*/React.createElement(SizeContext.Consumer, null, function (size) {\n var _classNames2;\n\n var mergedSize = customizeSize || size;\n var mergedClassName = classNames(!customizePrefixCls && treeSelectPrefixCls, (_classNames2 = {}, _defineProperty(_classNames2, \"\".concat(prefixCls, \"-lg\"), mergedSize === 'large'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-sm\"), mergedSize === 'small'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-borderless\"), !bordered), _classNames2), className);\n return /*#__PURE__*/React.createElement(RcTreeSelect, _extends({\n virtual: virtual,\n dropdownMatchSelectWidth: dropdownMatchSelectWidth\n }, selectProps, {\n ref: _this.selectRef,\n prefixCls: prefixCls,\n className: mergedClassName,\n listHeight: listHeight,\n listItemHeight: listItemHeight,\n treeCheckable: treeCheckable ? /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-tree-checkbox-inner\")\n }) : treeCheckable,\n inputIcon: suffixIcon,\n menuItemSelectedIcon: itemIcon,\n removeIcon: removeIcon,\n clearIcon: clearIcon,\n switcherIcon: function switcherIcon(nodeProps) {\n return renderSwitcherIcon(treePrefixCls, _switcherIcon, treeLine, nodeProps);\n },\n showTreeIcon: treeIcon,\n notFoundContent: mergedNotFound,\n getPopupContainer: getPopupContainer || getContextPopupContainer,\n treeMotion: null,\n dropdownClassName: mergedDropdownClassName\n }));\n });\n };\n\n devWarning(props.multiple !== false || !props.treeCheckable, 'TreeSelect', '`multiple` will alway be `true` when `treeCheckable` is true');\n return _this;\n }\n\n _createClass(TreeSelect, [{\n key: \"focus\",\n value: function focus() {\n if (this.selectRef.current) {\n this.selectRef.current.focus();\n }\n }\n }, {\n key: \"blur\",\n value: function blur() {\n if (this.selectRef.current) {\n this.selectRef.current.blur();\n }\n }\n }, {\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderTreeSelect);\n }\n }]);\n\n return TreeSelect;\n}(React.Component);\n\nTreeSelect.TreeNode = TreeNode;\nTreeSelect.SHOW_ALL = SHOW_ALL;\nTreeSelect.SHOW_PARENT = SHOW_PARENT;\nTreeSelect.SHOW_CHILD = SHOW_CHILD;\nTreeSelect.defaultProps = {\n transitionName: 'slide-up',\n choiceTransitionName: '',\n bordered: true\n};\nexport { TreeNode };\nexport default TreeSelect;","import _typeof from \"@babel/runtime/helpers/typeof\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport LoadingOutlined from '@ant-design/icons/LoadingOutlined';\nimport FileOutlined from '@ant-design/icons/FileOutlined';\nimport MinusSquareOutlined from '@ant-design/icons/MinusSquareOutlined';\nimport PlusSquareOutlined from '@ant-design/icons/PlusSquareOutlined';\nimport CaretDownFilled from '@ant-design/icons/CaretDownFilled';\nimport { isValidElement, cloneElement } from '../../_util/reactNode';\nexport default function renderSwitcherIcon(prefixCls, switcherIcon, showLine, _ref) {\n var isLeaf = _ref.isLeaf,\n expanded = _ref.expanded,\n loading = _ref.loading;\n\n if (loading) {\n return /*#__PURE__*/React.createElement(LoadingOutlined, {\n className: \"\".concat(prefixCls, \"-switcher-loading-icon\")\n });\n }\n\n var showLeafIcon;\n\n if (showLine && _typeof(showLine) === 'object') {\n showLeafIcon = showLine.showLeafIcon;\n }\n\n if (isLeaf) {\n if (showLine) {\n if (_typeof(showLine) === 'object' && !showLeafIcon) {\n return /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-switcher-leaf-line\")\n });\n }\n\n return /*#__PURE__*/React.createElement(FileOutlined, {\n className: \"\".concat(prefixCls, \"-switcher-line-icon\")\n });\n }\n\n return null;\n }\n\n var switcherCls = \"\".concat(prefixCls, \"-switcher-icon\");\n\n if (isValidElement(switcherIcon)) {\n return cloneElement(switcherIcon, {\n className: classNames(switcherIcon.props.className || '', switcherCls)\n });\n }\n\n if (switcherIcon) {\n return switcherIcon;\n }\n\n if (showLine) {\n return expanded ? /*#__PURE__*/React.createElement(MinusSquareOutlined, {\n className: \"\".concat(prefixCls, \"-switcher-line-icon\")\n }) : /*#__PURE__*/React.createElement(PlusSquareOutlined, {\n className: \"\".concat(prefixCls, \"-switcher-line-icon\")\n });\n }\n\n return /*#__PURE__*/React.createElement(CaretDownFilled, {\n className: switcherCls\n });\n}","import React from 'react';\nimport { isFragment } from 'react-is';\nexport default function toArray(children) {\n var option = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n var ret = [];\n React.Children.forEach(children, function (child) {\n if ((child === undefined || child === null) && !option.keepEmpty) {\n return;\n }\n\n if (Array.isArray(child)) {\n ret = ret.concat(toArray(child));\n } else if (isFragment(child) && child.props) {\n ret = ret.concat(toArray(child.props.children, option));\n } else {\n ret.push(child);\n }\n });\n return ret;\n}","import _typeof from \"../../helpers/esm/typeof\";\nimport assertThisInitialized from \"./assertThisInitialized\";\nexport default function _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n }\n\n return assertThisInitialized(self);\n}","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nimport _getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function () { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nimport React, { Component } from 'react';\nimport ReactDOM from 'react-dom';\nimport classNames from 'classnames';\n\nvar Notice = /*#__PURE__*/function (_Component) {\n _inherits(Notice, _Component);\n\n var _super = _createSuper(Notice);\n\n function Notice() {\n var _this;\n\n _classCallCheck(this, Notice);\n\n _this = _super.apply(this, arguments);\n _this.closeTimer = null;\n\n _this.close = function (e) {\n if (e) {\n e.stopPropagation();\n }\n\n _this.clearCloseTimer();\n\n var onClose = _this.props.onClose;\n\n if (onClose) {\n onClose();\n }\n };\n\n _this.startCloseTimer = function () {\n if (_this.props.duration) {\n _this.closeTimer = window.setTimeout(function () {\n _this.close();\n }, _this.props.duration * 1000);\n }\n };\n\n _this.clearCloseTimer = function () {\n if (_this.closeTimer) {\n clearTimeout(_this.closeTimer);\n _this.closeTimer = null;\n }\n };\n\n return _this;\n }\n\n _createClass(Notice, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.startCloseTimer();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate(prevProps) {\n if (this.props.duration !== prevProps.duration || this.props.update) {\n this.restartCloseTimer();\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n this.clearCloseTimer();\n }\n }, {\n key: \"restartCloseTimer\",\n value: function restartCloseTimer() {\n this.clearCloseTimer();\n this.startCloseTimer();\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this2 = this;\n\n var _this$props = this.props,\n prefixCls = _this$props.prefixCls,\n className = _this$props.className,\n closable = _this$props.closable,\n closeIcon = _this$props.closeIcon,\n style = _this$props.style,\n onClick = _this$props.onClick,\n children = _this$props.children,\n holder = _this$props.holder;\n var componentClass = \"\".concat(prefixCls, \"-notice\");\n var dataOrAriaAttributeProps = Object.keys(this.props).reduce(function (acc, key) {\n if (key.substr(0, 5) === 'data-' || key.substr(0, 5) === 'aria-' || key === 'role') {\n acc[key] = _this2.props[key];\n }\n\n return acc;\n }, {});\n var node = React.createElement(\"div\", Object.assign({\n className: classNames(componentClass, className, _defineProperty({}, \"\".concat(componentClass, \"-closable\"), closable)),\n style: style,\n onMouseEnter: this.clearCloseTimer,\n onMouseLeave: this.startCloseTimer,\n onClick: onClick\n }, dataOrAriaAttributeProps), React.createElement(\"div\", {\n className: \"\".concat(componentClass, \"-content\")\n }, children), closable ? React.createElement(\"a\", {\n tabIndex: 0,\n onClick: this.close,\n className: \"\".concat(componentClass, \"-close\")\n }, closeIcon || React.createElement(\"span\", {\n className: \"\".concat(componentClass, \"-close-x\")\n })) : null);\n\n if (holder) {\n return ReactDOM.createPortal(node, holder);\n }\n\n return node;\n }\n }]);\n\n return Notice;\n}(Component);\n\nexport { Notice as default };\nNotice.defaultProps = {\n onClose: function onClose() {},\n duration: 1.5,\n style: {\n right: '50%'\n }\n};","import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport * as React from 'react';\nimport Notice from './Notice';\nexport default function useNotification(notificationInstance) {\n var createdRef = React.useRef({});\n\n var _React$useState = React.useState([]),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n elements = _React$useState2[0],\n setElements = _React$useState2[1];\n\n function notify(noticeProps) {\n notificationInstance.add(noticeProps, function (div, props) {\n var key = props.key;\n\n if (div && !createdRef.current[key]) {\n var noticeEle = React.createElement(Notice, Object.assign({}, props, {\n holder: div\n }));\n createdRef.current[key] = noticeEle;\n setElements(function (originElements) {\n return [].concat(_toConsumableArray(originElements), [noticeEle]);\n });\n }\n });\n }\n\n return [notify, React.createElement(React.Fragment, null, elements)];\n}","import _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nimport _getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function () { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nimport React, { Component } from 'react';\nimport ReactDOM from 'react-dom';\nimport Animate from 'rc-animate';\nimport createChainedFunction from \"rc-util/es/createChainedFunction\";\nimport classnames from 'classnames';\nimport Notice from './Notice';\nimport _useNotification from './useNotification';\nvar seed = 0;\nvar now = Date.now();\n\nfunction getUuid() {\n var id = seed;\n seed += 1;\n return \"rcNotification_\".concat(now, \"_\").concat(id);\n}\n\nvar Notification = /*#__PURE__*/function (_Component) {\n _inherits(Notification, _Component);\n\n var _super = _createSuper(Notification);\n\n function Notification() {\n var _this;\n\n _classCallCheck(this, Notification);\n\n _this = _super.apply(this, arguments);\n _this.state = {\n notices: []\n };\n _this.hookRefs = new Map();\n\n _this.add = function (notice, holderCallback) {\n // eslint-disable-next-line no-param-reassign\n notice.key = notice.key || getUuid();\n var key = notice.key;\n var maxCount = _this.props.maxCount;\n\n _this.setState(function (previousState) {\n var notices = previousState.notices;\n var noticeIndex = notices.map(function (v) {\n return v.notice.key;\n }).indexOf(key);\n var updatedNotices = notices.concat();\n\n if (noticeIndex !== -1) {\n updatedNotices.splice(noticeIndex, 1, {\n notice: notice,\n holderCallback: holderCallback\n });\n } else {\n if (maxCount && notices.length >= maxCount) {\n // XXX, use key of first item to update new added (let React to move exsiting\n // instead of remove and mount). Same key was used before for both a) external\n // manual control and b) internal react 'key' prop , which is not that good.\n // eslint-disable-next-line no-param-reassign\n notice.updateKey = updatedNotices[0].notice.updateKey || updatedNotices[0].notice.key;\n updatedNotices.shift();\n }\n\n updatedNotices.push({\n notice: notice,\n holderCallback: holderCallback\n });\n }\n\n return {\n notices: updatedNotices\n };\n });\n };\n\n _this.remove = function (key) {\n _this.setState(function (previousState) {\n return {\n notices: previousState.notices.filter(function (_ref) {\n var notice = _ref.notice;\n return notice.key !== key;\n })\n };\n });\n };\n\n return _this;\n }\n\n _createClass(Notification, [{\n key: \"getTransitionName\",\n value: function getTransitionName() {\n var _this$props = this.props,\n prefixCls = _this$props.prefixCls,\n animation = _this$props.animation;\n var transitionName = this.props.transitionName;\n\n if (!transitionName && animation) {\n transitionName = \"\".concat(prefixCls, \"-\").concat(animation);\n }\n\n return transitionName;\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this2 = this;\n\n var notices = this.state.notices;\n var _this$props2 = this.props,\n prefixCls = _this$props2.prefixCls,\n className = _this$props2.className,\n closeIcon = _this$props2.closeIcon,\n style = _this$props2.style;\n var noticeNodes = notices.map(function (_ref2, index) {\n var notice = _ref2.notice,\n holderCallback = _ref2.holderCallback;\n var update = Boolean(index === notices.length - 1 && notice.updateKey);\n var key = notice.updateKey ? notice.updateKey : notice.key;\n var onClose = createChainedFunction(_this2.remove.bind(_this2, notice.key), notice.onClose);\n\n var noticeProps = _objectSpread(_objectSpread(_objectSpread({\n prefixCls: prefixCls,\n closeIcon: closeIcon\n }, notice), notice.props), {}, {\n key: key,\n update: update,\n onClose: onClose,\n onClick: notice.onClick,\n children: notice.content\n });\n\n if (holderCallback) {\n return React.createElement(\"div\", {\n key: key,\n className: \"\".concat(prefixCls, \"-hook-holder\"),\n ref: function ref(div) {\n if (typeof key === 'undefined') {\n return;\n }\n\n if (div) {\n _this2.hookRefs.set(key, div);\n\n holderCallback(div, noticeProps);\n } else {\n _this2.hookRefs.delete(key);\n }\n }\n });\n }\n\n return React.createElement(Notice, Object.assign({}, noticeProps));\n });\n return React.createElement(\"div\", {\n className: classnames(prefixCls, className),\n style: style\n }, React.createElement(Animate, {\n transitionName: this.getTransitionName()\n }, noticeNodes));\n }\n }]);\n\n return Notification;\n}(Component);\n\nNotification.defaultProps = {\n prefixCls: 'rc-notification',\n animation: 'fade',\n style: {\n top: 65,\n left: '50%'\n }\n};\n\nNotification.newInstance = function newNotificationInstance(properties, callback) {\n var _ref3 = properties || {},\n getContainer = _ref3.getContainer,\n props = _objectWithoutProperties(_ref3, [\"getContainer\"]);\n\n var div = document.createElement('div');\n\n if (getContainer) {\n var root = getContainer();\n root.appendChild(div);\n } else {\n document.body.appendChild(div);\n }\n\n var called = false;\n\n function ref(notification) {\n if (called) {\n return;\n }\n\n called = true;\n callback({\n notice: function notice(noticeProps) {\n notification.add(noticeProps);\n },\n removeNotice: function removeNotice(key) {\n notification.remove(key);\n },\n component: notification,\n destroy: function destroy() {\n ReactDOM.unmountComponentAtNode(div);\n\n if (div.parentNode) {\n div.parentNode.removeChild(div);\n }\n },\n // Hooks\n useNotification: function useNotification() {\n return _useNotification(notification);\n }\n });\n } // Only used for test case usage\n\n\n if (process.env.NODE_ENV === 'test' && properties.TEST_RENDER) {\n properties.TEST_RENDER(React.createElement(Notification, Object.assign({}, props, {\n ref: ref\n })));\n return;\n }\n\n ReactDOM.render(React.createElement(Notification, Object.assign({}, props, {\n ref: ref\n })), div);\n};\n\nexport default Notification;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport RCNotification from 'rc-notification';\nimport LoadingOutlined from '@ant-design/icons/LoadingOutlined';\nimport ExclamationCircleFilled from '@ant-design/icons/ExclamationCircleFilled';\nimport CloseCircleFilled from '@ant-design/icons/CloseCircleFilled';\nimport CheckCircleFilled from '@ant-design/icons/CheckCircleFilled';\nimport InfoCircleFilled from '@ant-design/icons/InfoCircleFilled';\nimport createUseMessage from './hooks/useMessage';\nvar messageInstance;\nvar defaultDuration = 3;\nvar defaultTop;\nvar key = 1;\nvar localPrefixCls = 'ant-message';\nvar transitionName = 'move-up';\nvar getContainer;\nvar maxCount;\nvar rtl = false;\nexport function getKeyThenIncreaseKey() {\n return key++;\n}\n\nfunction setMessageConfig(options) {\n if (options.top !== undefined) {\n defaultTop = options.top;\n messageInstance = null; // delete messageInstance for new defaultTop\n }\n\n if (options.duration !== undefined) {\n defaultDuration = options.duration;\n }\n\n if (options.prefixCls !== undefined) {\n localPrefixCls = options.prefixCls;\n }\n\n if (options.getContainer !== undefined) {\n getContainer = options.getContainer;\n }\n\n if (options.transitionName !== undefined) {\n transitionName = options.transitionName;\n messageInstance = null; // delete messageInstance for new transitionName\n }\n\n if (options.maxCount !== undefined) {\n maxCount = options.maxCount;\n messageInstance = null;\n }\n\n if (options.rtl !== undefined) {\n rtl = options.rtl;\n }\n}\n\nfunction getRCNotificationInstance(args, callback) {\n var prefixCls = args.prefixCls || localPrefixCls;\n\n if (messageInstance) {\n callback({\n prefixCls: prefixCls,\n instance: messageInstance\n });\n return;\n }\n\n RCNotification.newInstance({\n prefixCls: prefixCls,\n transitionName: transitionName,\n style: {\n top: defaultTop\n },\n getContainer: getContainer,\n maxCount: maxCount\n }, function (instance) {\n if (messageInstance) {\n callback({\n prefixCls: prefixCls,\n instance: messageInstance\n });\n return;\n }\n\n messageInstance = instance;\n callback({\n prefixCls: prefixCls,\n instance: instance\n });\n });\n}\n\nvar typeToIcon = {\n info: InfoCircleFilled,\n success: CheckCircleFilled,\n error: CloseCircleFilled,\n warning: ExclamationCircleFilled,\n loading: LoadingOutlined\n};\n\nfunction getRCNoticeProps(args, prefixCls) {\n var _classNames;\n\n var duration = args.duration !== undefined ? args.duration : defaultDuration;\n var IconComponent = typeToIcon[args.type];\n var messageClass = classNames(\"\".concat(prefixCls, \"-custom-content\"), (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(args.type), args.type), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), rtl === true), _classNames));\n return {\n key: args.key,\n duration: duration,\n style: args.style || {},\n className: args.className,\n content: /*#__PURE__*/React.createElement(\"div\", {\n className: messageClass\n }, args.icon || IconComponent && /*#__PURE__*/React.createElement(IconComponent, null), /*#__PURE__*/React.createElement(\"span\", null, args.content)),\n onClose: args.onClose\n };\n}\n\nfunction notice(args) {\n var target = args.key || key++;\n var closePromise = new Promise(function (resolve) {\n var callback = function callback() {\n if (typeof args.onClose === 'function') {\n args.onClose();\n }\n\n return resolve(true);\n };\n\n getRCNotificationInstance(args, function (_ref) {\n var prefixCls = _ref.prefixCls,\n instance = _ref.instance;\n instance.notice(getRCNoticeProps(_extends(_extends({}, args), {\n key: target,\n onClose: callback\n }), prefixCls));\n });\n });\n\n var result = function result() {\n if (messageInstance) {\n messageInstance.removeNotice(target);\n }\n };\n\n result.then = function (filled, rejected) {\n return closePromise.then(filled, rejected);\n };\n\n result.promise = closePromise;\n return result;\n}\n\nfunction isArgsProps(content) {\n return Object.prototype.toString.call(content) === '[object Object]' && !!content.content;\n}\n\nvar api = {\n open: notice,\n config: setMessageConfig,\n destroy: function destroy(messageKey) {\n if (messageInstance) {\n if (messageKey) {\n var _messageInstance = messageInstance,\n removeNotice = _messageInstance.removeNotice;\n removeNotice(messageKey);\n } else {\n var _messageInstance2 = messageInstance,\n destroy = _messageInstance2.destroy;\n destroy();\n messageInstance = null;\n }\n }\n }\n};\nexport function attachTypeApi(originalApi, type) {\n originalApi[type] = function (content, duration, onClose) {\n if (isArgsProps(content)) {\n return originalApi.open(_extends(_extends({}, content), {\n type: type\n }));\n }\n\n if (typeof duration === 'function') {\n onClose = duration;\n duration = undefined;\n }\n\n return originalApi.open({\n content: content,\n duration: duration,\n type: type,\n onClose: onClose\n });\n };\n}\n['success', 'info', 'warning', 'error', 'loading'].forEach(function (type) {\n return attachTypeApi(api, type);\n});\napi.warn = api.warning;\napi.useMessage = createUseMessage(getRCNotificationInstance, getRCNoticeProps);\nexport default api;","import Notification from './Notification';\nexport default Notification;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nimport useRCNotification from \"rc-notification/es/useNotification\";\nimport { ConfigConsumer } from '../../config-provider';\nimport { attachTypeApi, getKeyThenIncreaseKey } from '..';\nexport default function createUseMessage(getRcNotificationInstance, getRCNoticeProps) {\n var useMessage = function useMessage() {\n // We can only get content by render\n var getPrefixCls; // We create a proxy to handle delay created instance\n\n var innerInstance = null;\n var proxy = {\n add: function add(noticeProps, holderCallback) {\n innerInstance === null || innerInstance === void 0 ? void 0 : innerInstance.component.add(noticeProps, holderCallback);\n }\n };\n\n var _useRCNotification = useRCNotification(proxy),\n _useRCNotification2 = _slicedToArray(_useRCNotification, 2),\n hookNotify = _useRCNotification2[0],\n holder = _useRCNotification2[1];\n\n function notify(args) {\n var customizePrefixCls = args.prefixCls;\n var mergedPrefixCls = getPrefixCls('message', customizePrefixCls);\n var target = args.key || getKeyThenIncreaseKey();\n var closePromise = new Promise(function (resolve) {\n var callback = function callback() {\n if (typeof args.onClose === 'function') {\n args.onClose();\n }\n\n return resolve(true);\n };\n\n getRcNotificationInstance(_extends(_extends({}, args), {\n prefixCls: mergedPrefixCls\n }), function (_ref) {\n var prefixCls = _ref.prefixCls,\n instance = _ref.instance;\n innerInstance = instance;\n hookNotify(getRCNoticeProps(_extends(_extends({}, args), {\n key: target,\n onClose: callback\n }), prefixCls));\n });\n });\n\n var result = function result() {\n if (innerInstance) {\n innerInstance.removeNotice(target);\n }\n };\n\n result.then = function (filled, rejected) {\n return closePromise.then(filled, rejected);\n };\n\n result.promise = closePromise;\n return result;\n } // Fill functions\n\n\n var hookApiRef = React.useRef({});\n hookApiRef.current.open = notify;\n ['success', 'info', 'warning', 'error', 'loading'].forEach(function (type) {\n return attachTypeApi(hookApiRef.current, type);\n });\n return [hookApiRef.current, /*#__PURE__*/React.createElement(ConfigConsumer, {\n key: \"holder\"\n }, function (context) {\n getPrefixCls = context.getPrefixCls;\n return holder;\n })];\n };\n\n return useMessage;\n}","import * as React from 'react';\nimport warning from \"rc-util/es/warning\";\nexport var HOOK_MARK = 'RC_FORM_INTERNAL_HOOKS'; // eslint-disable-next-line @typescript-eslint/no-explicit-any\n\nvar warningFunc = function warningFunc() {\n warning(false, 'Can not find FormContext. Please make sure you wrap Field under Form.');\n};\n\nvar Context = React.createContext({\n getFieldValue: warningFunc,\n getFieldsValue: warningFunc,\n getFieldError: warningFunc,\n getFieldsError: warningFunc,\n isFieldsTouched: warningFunc,\n isFieldTouched: warningFunc,\n isFieldValidating: warningFunc,\n isFieldsValidating: warningFunc,\n resetFields: warningFunc,\n setFields: warningFunc,\n setFieldsValue: warningFunc,\n validateFields: warningFunc,\n submit: warningFunc,\n getInternalHooks: function getInternalHooks() {\n warningFunc();\n return {\n dispatch: warningFunc,\n registerField: warningFunc,\n useSubscribe: warningFunc,\n setInitialValues: warningFunc,\n setCallbacks: warningFunc,\n getFields: warningFunc,\n setValidateMessages: warningFunc,\n setPreserve: warningFunc\n };\n }\n});\nexport default Context;","export function toArray(value) {\n if (value === undefined || value === null) {\n return [];\n }\n\n return Array.isArray(value) ? value : [value];\n}","function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {\n try {\n var info = gen[key](arg);\n var value = info.value;\n } catch (error) {\n reject(error);\n return;\n }\n\n if (info.done) {\n resolve(value);\n } else {\n Promise.resolve(value).then(_next, _throw);\n }\n}\n\nexport default function _asyncToGenerator(fn) {\n return function () {\n var self = this,\n args = arguments;\n return new Promise(function (resolve, reject) {\n var gen = fn.apply(self, args);\n\n function _next(value) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"next\", value);\n }\n\n function _throw(err) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"throw\", err);\n }\n\n _next(undefined);\n });\n };\n}","function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\nfunction _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }\n\nfunction _nonIterableSpread() { throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\n\nfunction _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }\n\nfunction _toArray(arr) { return _arrayWithHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableRest(); }\n\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\n\nfunction _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === \"string\") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === \"Object\" && o.constructor) n = o.constructor.name; if (n === \"Map\" || n === \"Set\") return Array.from(o); if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }\n\nfunction _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }\n\nfunction _iterableToArray(iter) { if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter); }\n\nfunction _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }\n\nexport default function set(entity, paths, value) {\n if (!paths.length) {\n return value;\n }\n\n var _paths = _toArray(paths),\n path = _paths[0],\n restPath = _paths.slice(1);\n\n var clone;\n\n if (!entity && typeof path === 'number') {\n clone = [];\n } else if (Array.isArray(entity)) {\n clone = _toConsumableArray(entity);\n } else {\n clone = _objectSpread({}, entity);\n }\n\n clone[path] = set(clone[path], restPath, value);\n return clone;\n}","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport get from \"rc-util/es/utils/get\";\nimport set from \"rc-util/es/utils/set\";\nimport { toArray } from './typeUtil';\n/**\n * Convert name to internal supported format.\n * This function should keep since we still thinking if need support like `a.b.c` format.\n * 'a' => ['a']\n * 123 => [123]\n * ['a', 123] => ['a', 123]\n */\n\nexport function getNamePath(path) {\n return toArray(path);\n}\nexport function getValue(store, namePath) {\n var value = get(store, namePath);\n return value;\n}\nexport function setValue(store, namePath, value) {\n var newStore = set(store, namePath, value);\n return newStore;\n}\nexport function cloneByNamePathList(store, namePathList) {\n var newStore = {};\n namePathList.forEach(function (namePath) {\n var value = getValue(store, namePath);\n newStore = setValue(newStore, namePath, value);\n });\n return newStore;\n}\nexport function containsNamePath(namePathList, namePath) {\n return namePathList && namePathList.some(function (path) {\n return matchNamePath(path, namePath);\n });\n}\n\nfunction isObject(obj) {\n return _typeof(obj) === 'object' && obj !== null && Object.getPrototypeOf(obj) === Object.prototype;\n}\n/**\n * Copy values into store and return a new values object\n * ({ a: 1, b: { c: 2 } }, { a: 4, b: { d: 5 } }) => { a: 4, b: { c: 2, d: 5 } }\n */\n\n\nfunction internalSetValues(store, values) {\n var newStore = Array.isArray(store) ? _toConsumableArray(store) : _objectSpread({}, store);\n\n if (!values) {\n return newStore;\n }\n\n Object.keys(values).forEach(function (key) {\n var prevValue = newStore[key];\n var value = values[key]; // If both are object (but target is not array), we use recursion to set deep value\n\n var recursive = isObject(prevValue) && isObject(value);\n newStore[key] = recursive ? internalSetValues(prevValue, value || {}) : value;\n });\n return newStore;\n}\n\nexport function setValues(store) {\n for (var _len = arguments.length, restValues = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n restValues[_key - 1] = arguments[_key];\n }\n\n return restValues.reduce(function (current, newStore) {\n return internalSetValues(current, newStore);\n }, store);\n}\nexport function matchNamePath(namePath, changedNamePath) {\n if (!namePath || !changedNamePath || namePath.length !== changedNamePath.length) {\n return false;\n }\n\n return namePath.every(function (nameUnit, i) {\n return changedNamePath[i] === nameUnit;\n });\n}\nexport function isSimilar(source, target) {\n if (source === target) {\n return true;\n }\n\n if (!source && target || source && !target) {\n return false;\n }\n\n if (!source || !target || _typeof(source) !== 'object' || _typeof(target) !== 'object') {\n return false;\n }\n\n var sourceKeys = Object.keys(source);\n var targetKeys = Object.keys(target);\n var keys = new Set([].concat(_toConsumableArray(sourceKeys), _toConsumableArray(targetKeys)));\n return _toConsumableArray(keys).every(function (key) {\n var sourceValue = source[key];\n var targetValue = target[key];\n\n if (typeof sourceValue === 'function' && typeof targetValue === 'function') {\n return true;\n }\n\n return sourceValue === targetValue;\n });\n}\nexport function defaultGetValueFromEvent(valuePropName) {\n var event = arguments.length <= 1 ? undefined : arguments[1];\n\n if (event && event.target && valuePropName in event.target) {\n return event.target[valuePropName];\n }\n\n return event;\n}\n/**\n * Moves an array item from one position in an array to another.\n *\n * Note: This is a pure function so a new array will be returned, instead\n * of altering the array argument.\n *\n * @param array Array in which to move an item. (required)\n * @param moveIndex The index of the item to move. (required)\n * @param toIndex The index to move item at moveIndex to. (required)\n */\n\nexport function move(array, moveIndex, toIndex) {\n var length = array.length;\n\n if (moveIndex < 0 || moveIndex >= length || toIndex < 0 || toIndex >= length) {\n return array;\n }\n\n var item = array[moveIndex];\n var diff = moveIndex - toIndex;\n\n if (diff > 0) {\n // move left\n return [].concat(_toConsumableArray(array.slice(0, toIndex)), [item], _toConsumableArray(array.slice(toIndex, moveIndex)), _toConsumableArray(array.slice(moveIndex + 1, length)));\n }\n\n if (diff < 0) {\n // move right\n return [].concat(_toConsumableArray(array.slice(0, moveIndex)), _toConsumableArray(array.slice(moveIndex + 1, toIndex + 1)), [item], _toConsumableArray(array.slice(toIndex + 1, length)));\n }\n\n return array;\n}","export default function get(entity, path) {\n var current = entity;\n\n for (var i = 0; i < path.length; i += 1) {\n if (current === null || current === undefined) {\n return undefined;\n }\n\n current = current[path[i]];\n }\n\n return current;\n}","var typeTemplate = \"'${name}' is not a valid ${type}\";\nexport var defaultValidateMessages = {\n default: \"Validation error on field '${name}'\",\n required: \"'${name}' is required\",\n enum: \"'${name}' must be one of [${enum}]\",\n whitespace: \"'${name}' cannot be empty\",\n date: {\n format: \"'${name}' is invalid for format date\",\n parse: \"'${name}' could not be parsed as date\",\n invalid: \"'${name}' is invalid date\"\n },\n types: {\n string: typeTemplate,\n method: typeTemplate,\n array: typeTemplate,\n object: typeTemplate,\n number: typeTemplate,\n date: typeTemplate,\n boolean: typeTemplate,\n integer: typeTemplate,\n float: typeTemplate,\n regexp: typeTemplate,\n email: typeTemplate,\n url: typeTemplate,\n hex: typeTemplate\n },\n string: {\n len: \"'${name}' must be exactly ${len} characters\",\n min: \"'${name}' must be at least ${min} characters\",\n max: \"'${name}' cannot be longer than ${max} characters\",\n range: \"'${name}' must be between ${min} and ${max} characters\"\n },\n number: {\n len: \"'${name}' must equal ${len}\",\n min: \"'${name}' cannot be less than ${min}\",\n max: \"'${name}' cannot be greater than ${max}\",\n range: \"'${name}' must be between ${min} and ${max}\"\n },\n array: {\n len: \"'${name}' must be exactly ${len} in length\",\n min: \"'${name}' cannot be less than ${min} in length\",\n max: \"'${name}' cannot be greater than ${max} in length\",\n range: \"'${name}' must be between ${min} and ${max} in length\"\n },\n pattern: {\n mismatch: \"'${name}' does not match pattern ${pattern}\"\n }\n};","import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _regeneratorRuntime from \"@babel/runtime/regenerator\";\nimport _asyncToGenerator from \"@babel/runtime/helpers/esm/asyncToGenerator\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport RawAsyncValidator from 'async-validator';\nimport * as React from 'react';\nimport warning from \"rc-util/es/warning\";\nimport { setValues } from './valueUtil';\nimport { defaultValidateMessages } from './messages'; // Remove incorrect original ts define\n\nvar AsyncValidator = RawAsyncValidator;\n/**\n * Replace with template.\n * `I'm ${name}` + { name: 'bamboo' } = I'm bamboo\n */\n\nfunction replaceMessage(template, kv) {\n return template.replace(/\\$\\{\\w+\\}/g, function (str) {\n var key = str.slice(2, -1);\n return kv[key];\n });\n}\n/**\n * We use `async-validator` to validate rules. So have to hot replace the message with validator.\n * { required: '${name} is required' } => { required: () => 'field is required' }\n */\n\n\nfunction convertMessages(messages, name, rule, messageVariables) {\n var kv = _objectSpread(_objectSpread({}, rule), {}, {\n name: name,\n enum: (rule.enum || []).join(', ')\n });\n\n var replaceFunc = function replaceFunc(template, additionalKV) {\n return function () {\n return replaceMessage(template, _objectSpread(_objectSpread({}, kv), additionalKV));\n };\n };\n /* eslint-disable no-param-reassign */\n\n\n function fillTemplate(source) {\n var target = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n Object.keys(source).forEach(function (ruleName) {\n var value = source[ruleName];\n\n if (typeof value === 'string') {\n target[ruleName] = replaceFunc(value, messageVariables);\n } else if (value && _typeof(value) === 'object') {\n target[ruleName] = {};\n fillTemplate(value, target[ruleName]);\n } else {\n target[ruleName] = value;\n }\n });\n return target;\n }\n /* eslint-enable */\n\n\n return fillTemplate(setValues({}, defaultValidateMessages, messages));\n}\n\nfunction validateRule(_x, _x2, _x3, _x4, _x5) {\n return _validateRule.apply(this, arguments);\n}\n/**\n * We use `async-validator` to validate the value.\n * But only check one value in a time to avoid namePath validate issue.\n */\n\n\nfunction _validateRule() {\n _validateRule = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee2(name, value, rule, options, messageVariables) {\n var cloneRule, subRuleField, validator, messages, result, subResults;\n return _regeneratorRuntime.wrap(function _callee2$(_context2) {\n while (1) {\n switch (_context2.prev = _context2.next) {\n case 0:\n cloneRule = _objectSpread({}, rule); // We should special handle array validate\n\n subRuleField = null;\n\n if (cloneRule && cloneRule.type === 'array' && cloneRule.defaultField) {\n subRuleField = cloneRule.defaultField;\n delete cloneRule.defaultField;\n }\n\n validator = new AsyncValidator(_defineProperty({}, name, [cloneRule]));\n messages = convertMessages(options.validateMessages, name, cloneRule, messageVariables);\n validator.messages(messages);\n result = [];\n _context2.prev = 7;\n _context2.next = 10;\n return Promise.resolve(validator.validate(_defineProperty({}, name, value), _objectSpread({}, options)));\n\n case 10:\n _context2.next = 15;\n break;\n\n case 12:\n _context2.prev = 12;\n _context2.t0 = _context2[\"catch\"](7);\n\n if (_context2.t0.errors) {\n result = _context2.t0.errors.map(function (_ref2, index) {\n var message = _ref2.message;\n return (// Wrap ReactNode with `key`\n React.isValidElement(message) ? React.cloneElement(message, {\n key: \"error_\".concat(index)\n }) : message\n );\n });\n } else {\n console.error(_context2.t0);\n result = [messages.default()];\n }\n\n case 15:\n if (!(!result.length && subRuleField)) {\n _context2.next = 20;\n break;\n }\n\n _context2.next = 18;\n return Promise.all(value.map(function (subValue, i) {\n return validateRule(\"\".concat(name, \".\").concat(i), subValue, subRuleField, options, messageVariables);\n }));\n\n case 18:\n subResults = _context2.sent;\n return _context2.abrupt(\"return\", subResults.reduce(function (prev, errors) {\n return [].concat(_toConsumableArray(prev), _toConsumableArray(errors));\n }, []));\n\n case 20:\n return _context2.abrupt(\"return\", result);\n\n case 21:\n case \"end\":\n return _context2.stop();\n }\n }\n }, _callee2, null, [[7, 12]]);\n }));\n return _validateRule.apply(this, arguments);\n}\n\nexport function validateRules(namePath, value, rules, options, validateFirst, messageVariables) {\n var name = namePath.join('.'); // Fill rule with context\n\n var filledRules = rules.map(function (currentRule) {\n var originValidatorFunc = currentRule.validator;\n\n if (!originValidatorFunc) {\n return currentRule;\n }\n\n return _objectSpread(_objectSpread({}, currentRule), {}, {\n validator: function validator(rule, val, callback) {\n var hasPromise = false; // Wrap callback only accept when promise not provided\n\n var wrappedCallback = function wrappedCallback() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n // Wait a tick to make sure return type is a promise\n Promise.resolve().then(function () {\n warning(!hasPromise, 'Your validator function has already return a promise. `callback` will be ignored.');\n\n if (!hasPromise) {\n callback.apply(void 0, args);\n }\n });\n }; // Get promise\n\n\n var promise = originValidatorFunc(rule, val, wrappedCallback);\n hasPromise = promise && typeof promise.then === 'function' && typeof promise.catch === 'function';\n /**\n * 1. Use promise as the first priority.\n * 2. If promise not exist, use callback with warning instead\n */\n\n warning(hasPromise, '`callback` is deprecated. Please return a promise instead.');\n\n if (hasPromise) {\n promise.then(function () {\n callback();\n }).catch(function (err) {\n callback(err);\n });\n }\n }\n });\n });\n var summaryPromise;\n\n if (validateFirst === true) {\n // >>>>> Validate by serialization\n summaryPromise = new Promise( /*#__PURE__*/function () {\n var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(resolve, reject) {\n var i, errors;\n return _regeneratorRuntime.wrap(function _callee$(_context) {\n while (1) {\n switch (_context.prev = _context.next) {\n case 0:\n i = 0;\n\n case 1:\n if (!(i < filledRules.length)) {\n _context.next = 11;\n break;\n }\n\n _context.next = 4;\n return validateRule(name, value, filledRules[i], options, messageVariables);\n\n case 4:\n errors = _context.sent;\n\n if (!errors.length) {\n _context.next = 8;\n break;\n }\n\n reject(errors);\n return _context.abrupt(\"return\");\n\n case 8:\n i += 1;\n _context.next = 1;\n break;\n\n case 11:\n /* eslint-enable */\n resolve([]);\n\n case 12:\n case \"end\":\n return _context.stop();\n }\n }\n }, _callee);\n }));\n\n return function (_x6, _x7) {\n return _ref.apply(this, arguments);\n };\n }());\n } else {\n // >>>>> Validate by parallel\n var rulePromises = filledRules.map(function (rule) {\n return validateRule(name, value, rule, options, messageVariables);\n });\n summaryPromise = (validateFirst ? finishOnFirstFailed(rulePromises) : finishOnAllFailed(rulePromises)).then(function (errors) {\n if (!errors.length) {\n return [];\n }\n\n return Promise.reject(errors);\n });\n } // Internal catch error to avoid console error log.\n\n\n summaryPromise.catch(function (e) {\n return e;\n });\n return summaryPromise;\n}\n\nfunction finishOnAllFailed(_x8) {\n return _finishOnAllFailed.apply(this, arguments);\n}\n\nfunction _finishOnAllFailed() {\n _finishOnAllFailed = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee3(rulePromises) {\n return _regeneratorRuntime.wrap(function _callee3$(_context3) {\n while (1) {\n switch (_context3.prev = _context3.next) {\n case 0:\n return _context3.abrupt(\"return\", Promise.all(rulePromises).then(function (errorsList) {\n var _ref3;\n\n var errors = (_ref3 = []).concat.apply(_ref3, _toConsumableArray(errorsList));\n\n return errors;\n }));\n\n case 1:\n case \"end\":\n return _context3.stop();\n }\n }\n }, _callee3);\n }));\n return _finishOnAllFailed.apply(this, arguments);\n}\n\nfunction finishOnFirstFailed(_x9) {\n return _finishOnFirstFailed.apply(this, arguments);\n}\n\nfunction _finishOnFirstFailed() {\n _finishOnFirstFailed = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee4(rulePromises) {\n var count;\n return _regeneratorRuntime.wrap(function _callee4$(_context4) {\n while (1) {\n switch (_context4.prev = _context4.next) {\n case 0:\n count = 0;\n return _context4.abrupt(\"return\", new Promise(function (resolve) {\n rulePromises.forEach(function (promise) {\n promise.then(function (errors) {\n if (errors.length) {\n resolve(errors);\n }\n\n count += 1;\n\n if (count === rulePromises.length) {\n resolve([]);\n }\n });\n });\n }));\n\n case 2:\n case \"end\":\n return _context4.stop();\n }\n }\n }, _callee4);\n }));\n return _finishOnFirstFailed.apply(this, arguments);\n}","import _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport toChildrenArray from \"rc-util/es/Children/toArray\";\nimport warning from \"rc-util/es/warning\";\nimport * as React from 'react';\nimport FieldContext, { HOOK_MARK } from './FieldContext';\nimport { toArray } from './utils/typeUtil';\nimport { validateRules } from './utils/validateUtil';\nimport { containsNamePath, defaultGetValueFromEvent, getNamePath, getValue } from './utils/valueUtil';\n\nfunction requireUpdate(shouldUpdate, prev, next, prevValue, nextValue, info) {\n if (typeof shouldUpdate === 'function') {\n return shouldUpdate(prev, next, 'source' in info ? {\n source: info.source\n } : {});\n }\n\n return prevValue !== nextValue;\n} // We use Class instead of Hooks here since it will cost much code by using Hooks.\n\n\nvar Field = /*#__PURE__*/function (_React$Component) {\n _inherits(Field, _React$Component);\n\n var _super = _createSuper(Field);\n\n function Field() {\n var _this;\n\n _classCallCheck(this, Field);\n\n _this = _super.apply(this, arguments);\n _this.state = {\n resetCount: 0\n };\n _this.cancelRegisterFunc = null;\n _this.destroy = false;\n /**\n * Follow state should not management in State since it will async update by React.\n * This makes first render of form can not get correct state value.\n */\n\n _this.touched = false;\n /** Mark when touched & validated. Currently only used for `dependencies` */\n\n _this.dirty = false;\n _this.validatePromise = null;\n _this.errors = [];\n\n _this.cancelRegister = function () {\n var _this$props = _this.props,\n preserve = _this$props.preserve,\n isListField = _this$props.isListField;\n\n if (_this.cancelRegisterFunc) {\n _this.cancelRegisterFunc(isListField, preserve);\n }\n\n _this.cancelRegisterFunc = null;\n }; // ================================== Utils ==================================\n\n\n _this.getNamePath = function () {\n var name = _this.props.name;\n var _this$context$prefixN = _this.context.prefixName,\n prefixName = _this$context$prefixN === void 0 ? [] : _this$context$prefixN;\n return name !== undefined ? [].concat(_toConsumableArray(prefixName), _toConsumableArray(name)) : [];\n };\n\n _this.getRules = function () {\n var _this$props$rules = _this.props.rules,\n rules = _this$props$rules === void 0 ? [] : _this$props$rules;\n return rules.map(function (rule) {\n if (typeof rule === 'function') {\n return rule(_this.context);\n }\n\n return rule;\n });\n };\n\n _this.refresh = function () {\n if (_this.destroy) return;\n /**\n * Clean up current node.\n */\n\n _this.setState(function (_ref) {\n var resetCount = _ref.resetCount;\n return {\n resetCount: resetCount + 1\n };\n });\n }; // ========================= Field Entity Interfaces =========================\n // Trigger by store update. Check if need update the component\n\n\n _this.onStoreChange = function (prevStore, namePathList, info) {\n var _this$props2 = _this.props,\n shouldUpdate = _this$props2.shouldUpdate,\n _this$props2$dependen = _this$props2.dependencies,\n dependencies = _this$props2$dependen === void 0 ? [] : _this$props2$dependen,\n onReset = _this$props2.onReset;\n var store = info.store;\n\n var namePath = _this.getNamePath();\n\n var prevValue = _this.getValue(prevStore);\n\n var curValue = _this.getValue(store);\n\n var namePathMatch = namePathList && containsNamePath(namePathList, namePath); // `setFieldsValue` is a quick access to update related status\n\n if (info.type === 'valueUpdate' && info.source === 'external' && prevValue !== curValue) {\n _this.touched = true;\n _this.dirty = true;\n _this.validatePromise = null;\n _this.errors = [];\n }\n\n switch (info.type) {\n case 'reset':\n if (!namePathList || namePathMatch) {\n // Clean up state\n _this.touched = false;\n _this.dirty = false;\n _this.validatePromise = null;\n _this.errors = [];\n\n if (onReset) {\n onReset();\n }\n\n _this.refresh();\n\n return;\n }\n\n break;\n\n case 'setField':\n {\n if (namePathMatch) {\n var data = info.data;\n\n if ('touched' in data) {\n _this.touched = data.touched;\n }\n\n if ('validating' in data && !('originRCField' in data)) {\n _this.validatePromise = data.validating ? Promise.resolve([]) : null;\n }\n\n if ('errors' in data) {\n _this.errors = data.errors || [];\n }\n\n _this.dirty = true;\n\n _this.reRender();\n\n return;\n } // Handle update by `setField` with `shouldUpdate`\n\n\n if (shouldUpdate && !namePath.length && requireUpdate(shouldUpdate, prevStore, store, prevValue, curValue, info)) {\n _this.reRender();\n\n return;\n }\n\n break;\n }\n\n case 'dependenciesUpdate':\n {\n /**\n * Trigger when marked `dependencies` updated. Related fields will all update\n */\n var dependencyList = dependencies.map(getNamePath); // No need for `namePathMath` check and `shouldUpdate` check, since `valueUpdate` will be\n // emitted earlier and they will work there\n // If set it may cause unnecessary twice rerendering\n\n if (dependencyList.some(function (dependency) {\n return containsNamePath(info.relatedFields, dependency);\n })) {\n _this.reRender();\n\n return;\n }\n\n break;\n }\n\n default:\n // 1. If `namePath` exists in `namePathList`, means it's related value and should update\n // For example
\n // If `namePathList` is [['list']] (List value update), Field should be updated\n // If `namePathList` is [['list', 0]] (Field value update), List shouldn't be updated\n // 2.\n // 2.1 If `dependencies` is set, `name` is not set and `shouldUpdate` is not set,\n // don't use `shouldUpdate`. `dependencies` is view as a shortcut if `shouldUpdate`\n // is not provided\n // 2.2 If `shouldUpdate` provided, use customize logic to update the field\n // else to check if value changed\n if (namePathMatch || (!dependencies.length || namePath.length || shouldUpdate) && requireUpdate(shouldUpdate, prevStore, store, prevValue, curValue, info)) {\n _this.reRender();\n\n return;\n }\n\n break;\n }\n\n if (shouldUpdate === true) {\n _this.reRender();\n }\n };\n\n _this.validateRules = function (options) {\n var _this$props3 = _this.props,\n _this$props3$validate = _this$props3.validateFirst,\n validateFirst = _this$props3$validate === void 0 ? false : _this$props3$validate,\n messageVariables = _this$props3.messageVariables;\n\n var _ref2 = options || {},\n triggerName = _ref2.triggerName;\n\n var namePath = _this.getNamePath();\n\n var filteredRules = _this.getRules();\n\n if (triggerName) {\n filteredRules = filteredRules.filter(function (rule) {\n var validateTrigger = rule.validateTrigger;\n\n if (!validateTrigger) {\n return true;\n }\n\n var triggerList = toArray(validateTrigger);\n return triggerList.includes(triggerName);\n });\n }\n\n var promise = validateRules(namePath, _this.getValue(), filteredRules, options, validateFirst, messageVariables);\n _this.dirty = true;\n _this.validatePromise = promise;\n _this.errors = [];\n promise.catch(function (e) {\n return e;\n }).then(function () {\n var errors = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n\n if (_this.validatePromise === promise) {\n _this.validatePromise = null;\n _this.errors = errors;\n\n _this.reRender();\n }\n });\n return promise;\n };\n\n _this.isFieldValidating = function () {\n return !!_this.validatePromise;\n };\n\n _this.isFieldTouched = function () {\n return _this.touched;\n };\n\n _this.isFieldDirty = function () {\n return _this.dirty;\n };\n\n _this.getErrors = function () {\n return _this.errors;\n }; // ============================= Child Component =============================\n\n\n _this.getMeta = function () {\n // Make error & validating in cache to save perf\n _this.prevValidating = _this.isFieldValidating();\n var meta = {\n touched: _this.isFieldTouched(),\n validating: _this.prevValidating,\n errors: _this.errors,\n name: _this.getNamePath()\n };\n return meta;\n }; // Only return validate child node. If invalidate, will do nothing about field.\n\n\n _this.getOnlyChild = function (children) {\n // Support render props\n if (typeof children === 'function') {\n var meta = _this.getMeta();\n\n return _objectSpread(_objectSpread({}, _this.getOnlyChild(children(_this.getControlled(), meta, _this.context))), {}, {\n isFunction: true\n });\n } // Filed element only\n\n\n var childList = toChildrenArray(children);\n\n if (childList.length !== 1 || !React.isValidElement(childList[0])) {\n return {\n child: childList,\n isFunction: false\n };\n }\n\n return {\n child: childList[0],\n isFunction: false\n };\n }; // ============================== Field Control ==============================\n\n\n _this.getValue = function (store) {\n var getFieldsValue = _this.context.getFieldsValue;\n\n var namePath = _this.getNamePath();\n\n return getValue(store || getFieldsValue(true), namePath);\n };\n\n _this.getControlled = function () {\n var childProps = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n var _this$props4 = _this.props,\n trigger = _this$props4.trigger,\n validateTrigger = _this$props4.validateTrigger,\n getValueFromEvent = _this$props4.getValueFromEvent,\n normalize = _this$props4.normalize,\n valuePropName = _this$props4.valuePropName,\n getValueProps = _this$props4.getValueProps;\n var mergedValidateTrigger = validateTrigger !== undefined ? validateTrigger : _this.context.validateTrigger;\n\n var namePath = _this.getNamePath();\n\n var _this$context = _this.context,\n getInternalHooks = _this$context.getInternalHooks,\n getFieldsValue = _this$context.getFieldsValue;\n\n var _getInternalHooks = getInternalHooks(HOOK_MARK),\n dispatch = _getInternalHooks.dispatch;\n\n var value = _this.getValue();\n\n var mergedGetValueProps = getValueProps || function (val) {\n return _defineProperty({}, valuePropName, val);\n }; // eslint-disable-next-line @typescript-eslint/no-explicit-any\n\n\n var originTriggerFunc = childProps[trigger];\n\n var control = _objectSpread(_objectSpread({}, childProps), mergedGetValueProps(value)); // Add trigger\n\n\n control[trigger] = function () {\n // Mark as touched\n _this.touched = true;\n _this.dirty = true;\n var newValue;\n\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n if (getValueFromEvent) {\n newValue = getValueFromEvent.apply(void 0, args);\n } else {\n newValue = defaultGetValueFromEvent.apply(void 0, [valuePropName].concat(args));\n }\n\n if (normalize) {\n newValue = normalize(newValue, value, getFieldsValue(true));\n }\n\n dispatch({\n type: 'updateValue',\n namePath: namePath,\n value: newValue\n });\n\n if (originTriggerFunc) {\n originTriggerFunc.apply(void 0, args);\n }\n }; // Add validateTrigger\n\n\n var validateTriggerList = toArray(mergedValidateTrigger || []);\n validateTriggerList.forEach(function (triggerName) {\n // Wrap additional function of component, so that we can get latest value from store\n var originTrigger = control[triggerName];\n\n control[triggerName] = function () {\n if (originTrigger) {\n originTrigger.apply(void 0, arguments);\n } // Always use latest rules\n\n\n var rules = _this.props.rules;\n\n if (rules && rules.length) {\n // We dispatch validate to root,\n // since it will update related data with other field with same name\n dispatch({\n type: 'validateField',\n namePath: namePath,\n triggerName: triggerName\n });\n }\n };\n });\n return control;\n };\n\n return _this;\n } // ============================== Subscriptions ==============================\n\n\n _createClass(Field, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n var shouldUpdate = this.props.shouldUpdate;\n var getInternalHooks = this.context.getInternalHooks;\n\n var _getInternalHooks2 = getInternalHooks(HOOK_MARK),\n registerField = _getInternalHooks2.registerField;\n\n this.cancelRegisterFunc = registerField(this); // One more render for component in case fields not ready\n\n if (shouldUpdate === true) {\n this.reRender();\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n this.cancelRegister();\n this.destroy = true;\n }\n }, {\n key: \"reRender\",\n value: function reRender() {\n if (this.destroy) return;\n this.forceUpdate();\n }\n }, {\n key: \"render\",\n value: function render() {\n var resetCount = this.state.resetCount;\n var children = this.props.children;\n\n var _this$getOnlyChild = this.getOnlyChild(children),\n child = _this$getOnlyChild.child,\n isFunction = _this$getOnlyChild.isFunction; // Not need to `cloneElement` since user can handle this in render function self\n\n\n var returnChildNode;\n\n if (isFunction) {\n returnChildNode = child;\n } else if (React.isValidElement(child)) {\n returnChildNode = React.cloneElement(child, this.getControlled(child.props));\n } else {\n warning(!child, '`children` of Field is not validate ReactElement.');\n returnChildNode = child;\n }\n\n return React.createElement(React.Fragment, {\n key: resetCount\n }, returnChildNode);\n }\n }]);\n\n return Field;\n}(React.Component);\n\nField.contextType = FieldContext;\nField.defaultProps = {\n trigger: 'onChange',\n valuePropName: 'value'\n};\n\nvar WrapperField = function WrapperField(_ref4) {\n var name = _ref4.name,\n restProps = _objectWithoutProperties(_ref4, [\"name\"]);\n\n var namePath = name !== undefined ? getNamePath(name) : undefined;\n var key = 'keep';\n\n if (!restProps.isListField) {\n key = \"_\".concat((namePath || []).join('_'));\n }\n\n if (process.env.NODE_ENV !== 'production') {\n warning(restProps.preserve !== false || !restProps.isListField, '`preserve` should not apply on Form.List fields.');\n }\n\n return React.createElement(Field, Object.assign({\n key: key,\n name: namePath\n }, restProps));\n};\n\nexport default WrapperField;","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport * as React from 'react';\nimport warning from \"rc-util/es/warning\";\nimport FieldContext from './FieldContext';\nimport Field from './Field';\nimport { move as _move, getNamePath } from './utils/valueUtil';\n\nvar List = function List(_ref) {\n var name = _ref.name,\n children = _ref.children;\n var context = React.useContext(FieldContext);\n var keyRef = React.useRef({\n keys: [],\n id: 0\n });\n var keyManager = keyRef.current; // User should not pass `children` as other type.\n\n if (typeof children !== 'function') {\n warning(false, 'Form.List only accepts function as children.');\n return null;\n }\n\n var parentPrefixName = getNamePath(context.prefixName) || [];\n var prefixName = [].concat(_toConsumableArray(parentPrefixName), _toConsumableArray(getNamePath(name)));\n\n var shouldUpdate = function shouldUpdate(prevValue, nextValue, _ref2) {\n var source = _ref2.source;\n\n if (source === 'internal') {\n return false;\n }\n\n return prevValue !== nextValue;\n };\n\n return React.createElement(FieldContext.Provider, {\n value: _objectSpread(_objectSpread({}, context), {}, {\n prefixName: prefixName\n })\n }, React.createElement(Field, {\n name: [],\n shouldUpdate: shouldUpdate\n }, function (_ref3) {\n var _ref3$value = _ref3.value,\n value = _ref3$value === void 0 ? [] : _ref3$value,\n onChange = _ref3.onChange;\n var getFieldValue = context.getFieldValue;\n\n var getNewValue = function getNewValue() {\n var values = getFieldValue(prefixName || []);\n return values || [];\n };\n /**\n * Always get latest value in case user update fields by `form` api.\n */\n\n\n var operations = {\n add: function add(defaultValue, index) {\n // Mapping keys\n var newValue = getNewValue();\n\n if (index >= 0 && index <= newValue.length) {\n keyManager.keys = [].concat(_toConsumableArray(keyManager.keys.slice(0, index)), [keyManager.id], _toConsumableArray(keyManager.keys.slice(index)));\n onChange([].concat(_toConsumableArray(newValue.slice(0, index)), [defaultValue], _toConsumableArray(newValue.slice(index))));\n } else {\n if (process.env.NODE_ENV !== 'production' && (index < 0 || index > newValue.length)) {\n warning(false, 'The second parameter of the add function should be a valid positive number.');\n }\n\n keyManager.keys = [].concat(_toConsumableArray(keyManager.keys), [keyManager.id]);\n onChange([].concat(_toConsumableArray(newValue), [defaultValue]));\n }\n\n keyManager.id += 1;\n },\n remove: function remove(index) {\n var newValue = getNewValue();\n var indexSet = new Set(Array.isArray(index) ? index : [index]);\n\n if (indexSet.size <= 0) {\n return;\n }\n\n keyManager.keys = keyManager.keys.filter(function (_, keysIndex) {\n return !indexSet.has(keysIndex);\n }); // Trigger store change\n\n onChange(newValue.filter(function (_, valueIndex) {\n return !indexSet.has(valueIndex);\n }));\n },\n move: function move(from, to) {\n if (from === to) {\n return;\n }\n\n var newValue = getNewValue(); // Do not handle out of range\n\n if (from < 0 || from >= newValue.length || to < 0 || to >= newValue.length) {\n return;\n }\n\n keyManager.keys = _move(keyManager.keys, from, to); // Trigger store change\n\n onChange(_move(newValue, from, to));\n }\n };\n var listValue = value || [];\n\n if (!Array.isArray(listValue)) {\n listValue = [];\n\n if (process.env.NODE_ENV !== 'production') {\n warning(false, \"Current value of '\".concat(prefixName.join(' > '), \"' is not an array type.\"));\n }\n }\n\n return children(listValue.map(function (__, index) {\n var key = keyManager.keys[index];\n\n if (key === undefined) {\n keyManager.keys[index] = keyManager.id;\n key = keyManager.keys[index];\n keyManager.id += 1;\n }\n\n return {\n name: index,\n key: key,\n isListField: true\n };\n }), operations);\n }));\n};\n\nexport default List;","import _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport { matchNamePath } from './valueUtil';\n/**\n * NameMap like a `Map` but accepts `string[]` as key.\n */\n\nvar NameMap = /*#__PURE__*/function () {\n function NameMap() {\n _classCallCheck(this, NameMap);\n\n this.list = [];\n }\n\n _createClass(NameMap, [{\n key: \"set\",\n value: function set(key, value) {\n var index = this.list.findIndex(function (item) {\n return matchNamePath(item.key, key);\n });\n\n if (index !== -1) {\n this.list[index].value = value;\n } else {\n this.list.push({\n key: key,\n value: value\n });\n }\n }\n }, {\n key: \"get\",\n value: function get(key) {\n var result = this.list.find(function (item) {\n return matchNamePath(item.key, key);\n });\n return result && result.value;\n }\n }, {\n key: \"update\",\n value: function update(key, updater) {\n var origin = this.get(key);\n var next = updater(origin);\n\n if (!next) {\n this.delete(key);\n } else {\n this.set(key, next);\n }\n }\n }, {\n key: \"delete\",\n value: function _delete(key) {\n this.list = this.list.filter(function (item) {\n return !matchNamePath(item.key, key);\n });\n }\n }, {\n key: \"map\",\n value: function map(callback) {\n return this.list.map(callback);\n }\n }, {\n key: \"toJSON\",\n value: function toJSON() {\n var json = {};\n this.map(function (_ref) {\n var key = _ref.key,\n value = _ref.value;\n json[key.join('.')] = value;\n return null;\n });\n return json;\n }\n }]);\n\n return NameMap;\n}();\n\nexport default NameMap;","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport * as React from 'react';\nimport warning from \"rc-util/es/warning\";\nimport { HOOK_MARK } from './FieldContext';\nimport { allPromiseFinish } from './utils/asyncUtil';\nimport NameMap from './utils/NameMap';\nimport { defaultValidateMessages } from './utils/messages';\nimport { cloneByNamePathList, containsNamePath, getNamePath, getValue, setValue, setValues } from './utils/valueUtil';\nexport var FormStore = function FormStore(forceRootUpdate) {\n var _this = this;\n\n _classCallCheck(this, FormStore);\n\n this.formHooked = false;\n this.subscribable = true;\n this.store = {};\n this.fieldEntities = [];\n this.initialValues = {};\n this.callbacks = {};\n this.validateMessages = null;\n this.preserve = null;\n this.lastValidatePromise = null;\n\n this.getForm = function () {\n return {\n getFieldValue: _this.getFieldValue,\n getFieldsValue: _this.getFieldsValue,\n getFieldError: _this.getFieldError,\n getFieldsError: _this.getFieldsError,\n isFieldsTouched: _this.isFieldsTouched,\n isFieldTouched: _this.isFieldTouched,\n isFieldValidating: _this.isFieldValidating,\n isFieldsValidating: _this.isFieldsValidating,\n resetFields: _this.resetFields,\n setFields: _this.setFields,\n setFieldsValue: _this.setFieldsValue,\n validateFields: _this.validateFields,\n submit: _this.submit,\n getInternalHooks: _this.getInternalHooks\n };\n }; // ======================== Internal Hooks ========================\n\n\n this.getInternalHooks = function (key) {\n if (key === HOOK_MARK) {\n _this.formHooked = true;\n return {\n dispatch: _this.dispatch,\n registerField: _this.registerField,\n useSubscribe: _this.useSubscribe,\n setInitialValues: _this.setInitialValues,\n setCallbacks: _this.setCallbacks,\n setValidateMessages: _this.setValidateMessages,\n getFields: _this.getFields,\n setPreserve: _this.setPreserve\n };\n }\n\n warning(false, '`getInternalHooks` is internal usage. Should not call directly.');\n return null;\n };\n\n this.useSubscribe = function (subscribable) {\n _this.subscribable = subscribable;\n };\n /**\n * First time `setInitialValues` should update store with initial value\n */\n\n\n this.setInitialValues = function (initialValues, init) {\n _this.initialValues = initialValues || {};\n\n if (init) {\n _this.store = setValues({}, initialValues, _this.store);\n }\n };\n\n this.getInitialValue = function (namePath) {\n return getValue(_this.initialValues, namePath);\n };\n\n this.setCallbacks = function (callbacks) {\n _this.callbacks = callbacks;\n };\n\n this.setValidateMessages = function (validateMessages) {\n _this.validateMessages = validateMessages;\n };\n\n this.setPreserve = function (preserve) {\n _this.preserve = preserve;\n }; // ========================== Dev Warning =========================\n\n\n this.timeoutId = null;\n\n this.warningUnhooked = function () {\n if (process.env.NODE_ENV !== 'production' && !_this.timeoutId && typeof window !== 'undefined') {\n _this.timeoutId = window.setTimeout(function () {\n _this.timeoutId = null;\n\n if (!_this.formHooked) {\n warning(false, 'Instance created by `useForm` is not connected to any Form element. Forget to pass `form` prop?');\n }\n });\n }\n }; // ============================ Fields ============================\n\n /**\n * Get registered field entities.\n * @param pure Only return field which has a `name`. Default: false\n */\n\n\n this.getFieldEntities = function () {\n var pure = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n\n if (!pure) {\n return _this.fieldEntities;\n }\n\n return _this.fieldEntities.filter(function (field) {\n return field.getNamePath().length;\n });\n };\n\n this.getFieldsMap = function () {\n var pure = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n var cache = new NameMap();\n\n _this.getFieldEntities(pure).forEach(function (field) {\n var namePath = field.getNamePath();\n cache.set(namePath, field);\n });\n\n return cache;\n };\n\n this.getFieldEntitiesForNamePathList = function (nameList) {\n if (!nameList) {\n return _this.getFieldEntities(true);\n }\n\n var cache = _this.getFieldsMap(true);\n\n return nameList.map(function (name) {\n var namePath = getNamePath(name);\n return cache.get(namePath) || {\n INVALIDATE_NAME_PATH: getNamePath(name)\n };\n });\n };\n\n this.getFieldsValue = function (nameList, filterFunc) {\n _this.warningUnhooked();\n\n if (nameList === true && !filterFunc) {\n return _this.store;\n }\n\n var fieldEntities = _this.getFieldEntitiesForNamePathList(Array.isArray(nameList) ? nameList : null);\n\n var filteredNameList = [];\n fieldEntities.forEach(function (entity) {\n var namePath = 'INVALIDATE_NAME_PATH' in entity ? entity.INVALIDATE_NAME_PATH : entity.getNamePath();\n\n if (!filterFunc) {\n filteredNameList.push(namePath);\n } else {\n var meta = 'getMeta' in entity ? entity.getMeta() : null;\n\n if (filterFunc(meta)) {\n filteredNameList.push(namePath);\n }\n }\n });\n return cloneByNamePathList(_this.store, filteredNameList.map(getNamePath));\n };\n\n this.getFieldValue = function (name) {\n _this.warningUnhooked();\n\n var namePath = getNamePath(name);\n return getValue(_this.store, namePath);\n };\n\n this.getFieldsError = function (nameList) {\n _this.warningUnhooked();\n\n var fieldEntities = _this.getFieldEntitiesForNamePathList(nameList);\n\n return fieldEntities.map(function (entity, index) {\n if (entity && !('INVALIDATE_NAME_PATH' in entity)) {\n return {\n name: entity.getNamePath(),\n errors: entity.getErrors()\n };\n }\n\n return {\n name: getNamePath(nameList[index]),\n errors: []\n };\n });\n };\n\n this.getFieldError = function (name) {\n _this.warningUnhooked();\n\n var namePath = getNamePath(name);\n\n var fieldError = _this.getFieldsError([namePath])[0];\n\n return fieldError.errors;\n };\n\n this.isFieldsTouched = function () {\n _this.warningUnhooked();\n\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var arg0 = args[0],\n arg1 = args[1];\n var namePathList;\n var isAllFieldsTouched = false;\n\n if (args.length === 0) {\n namePathList = null;\n } else if (args.length === 1) {\n if (Array.isArray(arg0)) {\n namePathList = arg0.map(getNamePath);\n isAllFieldsTouched = false;\n } else {\n namePathList = null;\n isAllFieldsTouched = arg0;\n }\n } else {\n namePathList = arg0.map(getNamePath);\n isAllFieldsTouched = arg1;\n }\n\n var testTouched = function testTouched(field) {\n // Not provide `nameList` will check all the fields\n if (!namePathList) {\n return field.isFieldTouched();\n }\n\n var fieldNamePath = field.getNamePath();\n\n if (containsNamePath(namePathList, fieldNamePath)) {\n return field.isFieldTouched();\n }\n\n return isAllFieldsTouched;\n };\n\n return isAllFieldsTouched ? _this.getFieldEntities(true).every(testTouched) : _this.getFieldEntities(true).some(testTouched);\n };\n\n this.isFieldTouched = function (name) {\n _this.warningUnhooked();\n\n return _this.isFieldsTouched([name]);\n };\n\n this.isFieldsValidating = function (nameList) {\n _this.warningUnhooked();\n\n var fieldEntities = _this.getFieldEntities();\n\n if (!nameList) {\n return fieldEntities.some(function (testField) {\n return testField.isFieldValidating();\n });\n }\n\n var namePathList = nameList.map(getNamePath);\n return fieldEntities.some(function (testField) {\n var fieldNamePath = testField.getNamePath();\n return containsNamePath(namePathList, fieldNamePath) && testField.isFieldValidating();\n });\n };\n\n this.isFieldValidating = function (name) {\n _this.warningUnhooked();\n\n return _this.isFieldsValidating([name]);\n };\n /**\n * Reset Field with field `initialValue` prop.\n * Can pass `entities` or `namePathList` or just nothing.\n */\n\n\n this.resetWithFieldInitialValue = function () {\n var info = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n // Create cache\n var cache = new NameMap();\n\n var fieldEntities = _this.getFieldEntities(true);\n\n fieldEntities.forEach(function (field) {\n var initialValue = field.props.initialValue;\n var namePath = field.getNamePath(); // Record only if has `initialValue`\n\n if (initialValue !== undefined) {\n var records = cache.get(namePath) || new Set();\n records.add({\n entity: field,\n value: initialValue\n });\n cache.set(namePath, records);\n }\n }); // Reset\n\n var resetWithFields = function resetWithFields(entities) {\n entities.forEach(function (field) {\n var initialValue = field.props.initialValue;\n\n if (initialValue !== undefined) {\n var namePath = field.getNamePath();\n\n var formInitialValue = _this.getInitialValue(namePath);\n\n if (formInitialValue !== undefined) {\n // Warning if conflict with form initialValues and do not modify value\n warning(false, \"Form already set 'initialValues' with path '\".concat(namePath.join('.'), \"'. Field can not overwrite it.\"));\n } else {\n var records = cache.get(namePath);\n\n if (records && records.size > 1) {\n // Warning if multiple field set `initialValue`and do not modify value\n warning(false, \"Multiple Field with path '\".concat(namePath.join('.'), \"' set 'initialValue'. Can not decide which one to pick.\"));\n } else if (records) {\n var originValue = _this.getFieldValue(namePath); // Set `initialValue`\n\n\n if (!info.skipExist || originValue === undefined) {\n _this.store = setValue(_this.store, namePath, _toConsumableArray(records)[0].value);\n }\n }\n }\n }\n });\n };\n\n var requiredFieldEntities;\n\n if (info.entities) {\n requiredFieldEntities = info.entities;\n } else if (info.namePathList) {\n requiredFieldEntities = [];\n info.namePathList.forEach(function (namePath) {\n var records = cache.get(namePath);\n\n if (records) {\n var _requiredFieldEntitie;\n\n (_requiredFieldEntitie = requiredFieldEntities).push.apply(_requiredFieldEntitie, _toConsumableArray(_toConsumableArray(records).map(function (r) {\n return r.entity;\n })));\n }\n });\n } else {\n requiredFieldEntities = fieldEntities;\n }\n\n resetWithFields(requiredFieldEntities);\n };\n\n this.resetFields = function (nameList) {\n _this.warningUnhooked();\n\n var prevStore = _this.store;\n\n if (!nameList) {\n _this.store = setValues({}, _this.initialValues);\n\n _this.resetWithFieldInitialValue();\n\n _this.notifyObservers(prevStore, null, {\n type: 'reset'\n });\n\n return;\n } // Reset by `nameList`\n\n\n var namePathList = nameList.map(getNamePath);\n namePathList.forEach(function (namePath) {\n var initialValue = _this.getInitialValue(namePath);\n\n _this.store = setValue(_this.store, namePath, initialValue);\n });\n\n _this.resetWithFieldInitialValue({\n namePathList: namePathList\n });\n\n _this.notifyObservers(prevStore, namePathList, {\n type: 'reset'\n });\n };\n\n this.setFields = function (fields) {\n _this.warningUnhooked();\n\n var prevStore = _this.store;\n fields.forEach(function (fieldData) {\n var name = fieldData.name,\n errors = fieldData.errors,\n data = _objectWithoutProperties(fieldData, [\"name\", \"errors\"]);\n\n var namePath = getNamePath(name); // Value\n\n if ('value' in data) {\n _this.store = setValue(_this.store, namePath, data.value);\n }\n\n _this.notifyObservers(prevStore, [namePath], {\n type: 'setField',\n data: fieldData\n });\n });\n };\n\n this.getFields = function () {\n var entities = _this.getFieldEntities(true);\n\n var fields = entities.map(function (field) {\n var namePath = field.getNamePath();\n var meta = field.getMeta();\n\n var fieldData = _objectSpread(_objectSpread({}, meta), {}, {\n name: namePath,\n value: _this.getFieldValue(namePath)\n });\n\n Object.defineProperty(fieldData, 'originRCField', {\n value: true\n });\n return fieldData;\n });\n return fields;\n }; // =========================== Observer ===========================\n\n\n this.registerField = function (entity) {\n _this.fieldEntities.push(entity); // Set initial values\n\n\n if (entity.props.initialValue !== undefined) {\n var prevStore = _this.store;\n\n _this.resetWithFieldInitialValue({\n entities: [entity],\n skipExist: true\n });\n\n _this.notifyObservers(prevStore, [entity.getNamePath()], {\n type: 'valueUpdate',\n source: 'internal'\n });\n } // un-register field callback\n\n\n return function (isListField, preserve) {\n _this.fieldEntities = _this.fieldEntities.filter(function (item) {\n return item !== entity;\n }); // Clean up store value if preserve\n\n var mergedPreserve = preserve !== undefined ? preserve : _this.preserve;\n\n if (mergedPreserve === false && !isListField) {\n var namePath = entity.getNamePath();\n\n if (_this.getFieldValue(namePath) !== undefined) {\n _this.store = setValue(_this.store, namePath, undefined);\n }\n }\n };\n };\n\n this.dispatch = function (action) {\n switch (action.type) {\n case 'updateValue':\n {\n var namePath = action.namePath,\n value = action.value;\n\n _this.updateValue(namePath, value);\n\n break;\n }\n\n case 'validateField':\n {\n var _namePath = action.namePath,\n triggerName = action.triggerName;\n\n _this.validateFields([_namePath], {\n triggerName: triggerName\n });\n\n break;\n }\n\n default: // Currently we don't have other action. Do nothing.\n\n }\n };\n\n this.notifyObservers = function (prevStore, namePathList, info) {\n if (_this.subscribable) {\n var mergedInfo = _objectSpread(_objectSpread({}, info), {}, {\n store: _this.getFieldsValue(true)\n });\n\n _this.getFieldEntities().forEach(function (_ref) {\n var onStoreChange = _ref.onStoreChange;\n onStoreChange(prevStore, namePathList, mergedInfo);\n });\n } else {\n _this.forceRootUpdate();\n }\n };\n\n this.updateValue = function (name, value) {\n var namePath = getNamePath(name);\n var prevStore = _this.store;\n _this.store = setValue(_this.store, namePath, value);\n\n _this.notifyObservers(prevStore, [namePath], {\n type: 'valueUpdate',\n source: 'internal'\n }); // Notify dependencies children with parent update\n\n\n var childrenFields = _this.getDependencyChildrenFields(namePath);\n\n _this.validateFields(childrenFields);\n\n _this.notifyObservers(prevStore, childrenFields, {\n type: 'dependenciesUpdate',\n relatedFields: [namePath].concat(_toConsumableArray(childrenFields))\n }); // trigger callback function\n\n\n var onValuesChange = _this.callbacks.onValuesChange;\n\n if (onValuesChange) {\n var changedValues = cloneByNamePathList(_this.store, [namePath]);\n onValuesChange(changedValues, _this.store);\n }\n\n _this.triggerOnFieldsChange([namePath].concat(_toConsumableArray(childrenFields)));\n }; // Let all child Field get update.\n\n\n this.setFieldsValue = function (store) {\n _this.warningUnhooked();\n\n var prevStore = _this.store;\n\n if (store) {\n _this.store = setValues(_this.store, store);\n }\n\n _this.notifyObservers(prevStore, null, {\n type: 'valueUpdate',\n source: 'external'\n });\n };\n\n this.getDependencyChildrenFields = function (rootNamePath) {\n var children = new Set();\n var childrenFields = [];\n var dependencies2fields = new NameMap();\n /**\n * Generate maps\n * Can use cache to save perf if user report performance issue with this\n */\n\n _this.getFieldEntities().forEach(function (field) {\n var dependencies = field.props.dependencies;\n (dependencies || []).forEach(function (dependency) {\n var dependencyNamePath = getNamePath(dependency);\n dependencies2fields.update(dependencyNamePath, function () {\n var fields = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : new Set();\n fields.add(field);\n return fields;\n });\n });\n });\n\n var fillChildren = function fillChildren(namePath) {\n var fields = dependencies2fields.get(namePath) || new Set();\n fields.forEach(function (field) {\n if (!children.has(field)) {\n children.add(field);\n var fieldNamePath = field.getNamePath();\n\n if (field.isFieldDirty() && fieldNamePath.length) {\n childrenFields.push(fieldNamePath);\n fillChildren(fieldNamePath);\n }\n }\n });\n };\n\n fillChildren(rootNamePath);\n return childrenFields;\n };\n\n this.triggerOnFieldsChange = function (namePathList, filedErrors) {\n var onFieldsChange = _this.callbacks.onFieldsChange;\n\n if (onFieldsChange) {\n var fields = _this.getFields();\n /**\n * Fill errors since `fields` may be replaced by controlled fields\n */\n\n\n if (filedErrors) {\n var cache = new NameMap();\n filedErrors.forEach(function (_ref2) {\n var name = _ref2.name,\n errors = _ref2.errors;\n cache.set(name, errors);\n });\n fields.forEach(function (field) {\n // eslint-disable-next-line no-param-reassign\n field.errors = cache.get(field.name) || field.errors;\n });\n }\n\n var changedFields = fields.filter(function (_ref3) {\n var fieldName = _ref3.name;\n return containsNamePath(namePathList, fieldName);\n });\n onFieldsChange(changedFields, fields);\n }\n }; // =========================== Validate ===========================\n\n\n this.validateFields = function (nameList, options) {\n _this.warningUnhooked();\n\n var provideNameList = !!nameList;\n var namePathList = provideNameList ? nameList.map(getNamePath) : []; // Collect result in promise list\n\n var promiseList = [];\n\n _this.getFieldEntities(true).forEach(function (field) {\n // Add field if not provide `nameList`\n if (!provideNameList) {\n namePathList.push(field.getNamePath());\n } // Skip if without rule\n\n\n if (!field.props.rules || !field.props.rules.length) {\n return;\n }\n\n var fieldNamePath = field.getNamePath(); // Add field validate rule in to promise list\n\n if (!provideNameList || containsNamePath(namePathList, fieldNamePath)) {\n var promise = field.validateRules(_objectSpread({\n validateMessages: _objectSpread(_objectSpread({}, defaultValidateMessages), _this.validateMessages)\n }, options)); // Wrap promise with field\n\n promiseList.push(promise.then(function () {\n return {\n name: fieldNamePath,\n errors: []\n };\n }).catch(function (errors) {\n return Promise.reject({\n name: fieldNamePath,\n errors: errors\n });\n }));\n }\n });\n\n var summaryPromise = allPromiseFinish(promiseList);\n _this.lastValidatePromise = summaryPromise; // Notify fields with rule that validate has finished and need update\n\n summaryPromise.catch(function (results) {\n return results;\n }).then(function (results) {\n var resultNamePathList = results.map(function (_ref4) {\n var name = _ref4.name;\n return name;\n });\n\n _this.notifyObservers(_this.store, resultNamePathList, {\n type: 'validateFinish'\n });\n\n _this.triggerOnFieldsChange(resultNamePathList, results);\n });\n var returnPromise = summaryPromise.then(function () {\n if (_this.lastValidatePromise === summaryPromise) {\n return Promise.resolve(_this.getFieldsValue(namePathList));\n }\n\n return Promise.reject([]);\n }).catch(function (results) {\n var errorList = results.filter(function (result) {\n return result && result.errors.length;\n });\n return Promise.reject({\n values: _this.getFieldsValue(namePathList),\n errorFields: errorList,\n outOfDate: _this.lastValidatePromise !== summaryPromise\n });\n }); // Do not throw in console\n\n returnPromise.catch(function (e) {\n return e;\n });\n return returnPromise;\n }; // ============================ Submit ============================\n\n\n this.submit = function () {\n _this.warningUnhooked();\n\n _this.validateFields().then(function (values) {\n var onFinish = _this.callbacks.onFinish;\n\n if (onFinish) {\n try {\n onFinish(values);\n } catch (err) {\n // Should print error if user `onFinish` callback failed\n console.error(err);\n }\n }\n }).catch(function (e) {\n var onFinishFailed = _this.callbacks.onFinishFailed;\n\n if (onFinishFailed) {\n onFinishFailed(e);\n }\n });\n };\n\n this.forceRootUpdate = forceRootUpdate;\n};\n\nfunction useForm(form) {\n var formRef = React.useRef();\n\n var _React$useState = React.useState(),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n forceUpdate = _React$useState2[1];\n\n if (!formRef.current) {\n if (form) {\n formRef.current = form;\n } else {\n // Create a new FormStore if not provided\n var forceReRender = function forceReRender() {\n forceUpdate({});\n };\n\n var formStore = new FormStore(forceReRender);\n formRef.current = formStore.getForm();\n }\n }\n\n return [formRef.current];\n}\n\nexport default useForm;","export function allPromiseFinish(promiseList) {\n var hasError = false;\n var count = promiseList.length;\n var results = [];\n\n if (!promiseList.length) {\n return Promise.resolve([]);\n }\n\n return new Promise(function (resolve, reject) {\n promiseList.forEach(function (promise, index) {\n promise.catch(function (e) {\n hasError = true;\n return e;\n }).then(function (result) {\n count -= 1;\n results[index] = result;\n\n if (count > 0) {\n return;\n }\n\n if (hasError) {\n reject(results);\n }\n\n resolve(results);\n });\n });\n });\n}","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport * as React from 'react';\nvar FormContext = React.createContext({\n triggerFormChange: function triggerFormChange() {},\n triggerFormFinish: function triggerFormFinish() {},\n registerForm: function registerForm() {},\n unregisterForm: function unregisterForm() {}\n});\n\nvar FormProvider = function FormProvider(_ref) {\n var validateMessages = _ref.validateMessages,\n onFormChange = _ref.onFormChange,\n onFormFinish = _ref.onFormFinish,\n children = _ref.children;\n var formContext = React.useContext(FormContext);\n var formsRef = React.useRef({});\n return React.createElement(FormContext.Provider, {\n value: _objectSpread(_objectSpread({}, formContext), {}, {\n validateMessages: _objectSpread(_objectSpread({}, formContext.validateMessages), validateMessages),\n // =========================================================\n // = Global Form Control =\n // =========================================================\n triggerFormChange: function triggerFormChange(name, changedFields) {\n if (onFormChange) {\n onFormChange(name, {\n changedFields: changedFields,\n forms: formsRef.current\n });\n }\n\n formContext.triggerFormChange(name, changedFields);\n },\n triggerFormFinish: function triggerFormFinish(name, values) {\n if (onFormFinish) {\n onFormFinish(name, {\n values: values,\n forms: formsRef.current\n });\n }\n\n formContext.triggerFormFinish(name, values);\n },\n registerForm: function registerForm(name, form) {\n if (name) {\n formsRef.current = _objectSpread(_objectSpread({}, formsRef.current), {}, _defineProperty({}, name, form));\n }\n\n formContext.registerForm(name, form);\n },\n unregisterForm: function unregisterForm(name) {\n var newForms = _objectSpread({}, formsRef.current);\n\n delete newForms[name];\n formsRef.current = newForms;\n formContext.unregisterForm(name);\n }\n })\n }, children);\n};\n\nexport { FormProvider };\nexport default FormContext;","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport useForm from './useForm';\nimport FieldContext, { HOOK_MARK } from './FieldContext';\nimport FormContext from './FormContext';\nimport { isSimilar } from './utils/valueUtil';\n\nvar Form = function Form(_ref, ref) {\n var name = _ref.name,\n initialValues = _ref.initialValues,\n fields = _ref.fields,\n form = _ref.form,\n preserve = _ref.preserve,\n children = _ref.children,\n _ref$component = _ref.component,\n Component = _ref$component === void 0 ? 'form' : _ref$component,\n validateMessages = _ref.validateMessages,\n _ref$validateTrigger = _ref.validateTrigger,\n validateTrigger = _ref$validateTrigger === void 0 ? 'onChange' : _ref$validateTrigger,\n onValuesChange = _ref.onValuesChange,\n _onFieldsChange = _ref.onFieldsChange,\n _onFinish = _ref.onFinish,\n onFinishFailed = _ref.onFinishFailed,\n restProps = _objectWithoutProperties(_ref, [\"name\", \"initialValues\", \"fields\", \"form\", \"preserve\", \"children\", \"component\", \"validateMessages\", \"validateTrigger\", \"onValuesChange\", \"onFieldsChange\", \"onFinish\", \"onFinishFailed\"]);\n\n var formContext = React.useContext(FormContext); // We customize handle event since Context will makes all the consumer re-render:\n // https://reactjs.org/docs/context.html#contextprovider\n\n var _useForm = useForm(form),\n _useForm2 = _slicedToArray(_useForm, 1),\n formInstance = _useForm2[0];\n\n var _formInstance$getInte = formInstance.getInternalHooks(HOOK_MARK),\n useSubscribe = _formInstance$getInte.useSubscribe,\n setInitialValues = _formInstance$getInte.setInitialValues,\n setCallbacks = _formInstance$getInte.setCallbacks,\n setValidateMessages = _formInstance$getInte.setValidateMessages,\n setPreserve = _formInstance$getInte.setPreserve; // Pass ref with form instance\n\n\n React.useImperativeHandle(ref, function () {\n return formInstance;\n }); // Register form into Context\n\n React.useEffect(function () {\n formContext.registerForm(name, formInstance);\n return function () {\n formContext.unregisterForm(name);\n };\n }, [formContext, formInstance, name]); // Pass props to store\n\n setValidateMessages(_objectSpread(_objectSpread({}, formContext.validateMessages), validateMessages));\n setCallbacks({\n onValuesChange: onValuesChange,\n onFieldsChange: function onFieldsChange(changedFields) {\n formContext.triggerFormChange(name, changedFields);\n\n if (_onFieldsChange) {\n for (var _len = arguments.length, rest = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n rest[_key - 1] = arguments[_key];\n }\n\n _onFieldsChange.apply(void 0, [changedFields].concat(rest));\n }\n },\n onFinish: function onFinish(values) {\n formContext.triggerFormFinish(name, values);\n\n if (_onFinish) {\n _onFinish(values);\n }\n },\n onFinishFailed: onFinishFailed\n });\n setPreserve(preserve); // Set initial value, init store value when first mount\n\n var mountRef = React.useRef(null);\n setInitialValues(initialValues, !mountRef.current);\n\n if (!mountRef.current) {\n mountRef.current = true;\n } // Prepare children by `children` type\n\n\n var childrenNode = children;\n var childrenRenderProps = typeof children === 'function';\n\n if (childrenRenderProps) {\n var values = formInstance.getFieldsValue(true);\n childrenNode = children(values, formInstance);\n } // Not use subscribe when using render props\n\n\n useSubscribe(!childrenRenderProps); // Listen if fields provided. We use ref to save prev data here to avoid additional render\n\n var prevFieldsRef = React.useRef();\n React.useEffect(function () {\n if (!isSimilar(prevFieldsRef.current || [], fields || [])) {\n formInstance.setFields(fields || []);\n }\n\n prevFieldsRef.current = fields;\n }, [fields, formInstance]);\n var formContextValue = React.useMemo(function () {\n return _objectSpread(_objectSpread({}, formInstance), {}, {\n validateTrigger: validateTrigger\n });\n }, [formInstance, validateTrigger]);\n var wrapperNode = React.createElement(FieldContext.Provider, {\n value: formContextValue\n }, childrenNode);\n\n if (Component === false) {\n return wrapperNode;\n }\n\n return React.createElement(Component, Object.assign({}, restProps, {\n onSubmit: function onSubmit(event) {\n event.preventDefault();\n event.stopPropagation();\n formInstance.submit();\n }\n }), wrapperNode);\n};\n\nexport default Form;","import * as React from 'react';\nimport Field from './Field';\nimport List from './List';\nimport useForm from './useForm';\nimport FieldForm from './Form';\nimport { FormProvider } from './FormContext';\nvar InternalForm = React.forwardRef(FieldForm);\nvar RefForm = InternalForm;\nRefForm.FormProvider = FormProvider;\nRefForm.Field = Field;\nRefForm.List = List;\nRefForm.useForm = useForm;\nexport { Field, List, useForm, FormProvider };\nexport default RefForm;","import * as React from 'react';\nimport omit from 'omit.js';\nimport { FormProvider as RcFormProvider } from 'rc-field-form';\nexport var FormContext = /*#__PURE__*/React.createContext({\n labelAlign: 'right',\n vertical: false,\n itemRef: function itemRef() {}\n});\nexport var FormItemContext = /*#__PURE__*/React.createContext({\n updateItemErrors: function updateItemErrors() {}\n});\nexport var FormProvider = function FormProvider(props) {\n var providerProps = omit(props, ['prefixCls']);\n return /*#__PURE__*/React.createElement(RcFormProvider, providerProps);\n};","function isElement(el) {\n return el != null && typeof el === 'object' && el.nodeType === 1;\n}\n\nfunction canOverflow(overflow, skipOverflowHiddenElements) {\n if (skipOverflowHiddenElements && overflow === 'hidden') {\n return false;\n }\n\n return overflow !== 'visible' && overflow !== 'clip';\n}\n\nfunction getFrameElement(el) {\n if (!el.ownerDocument || !el.ownerDocument.defaultView) {\n return null;\n }\n\n try {\n return el.ownerDocument.defaultView.frameElement;\n } catch (e) {\n return null;\n }\n}\n\nfunction isHiddenByFrame(el) {\n var frame = getFrameElement(el);\n\n if (!frame) {\n return false;\n }\n\n return frame.clientHeight < el.scrollHeight || frame.clientWidth < el.scrollWidth;\n}\n\nfunction isScrollable(el, skipOverflowHiddenElements) {\n if (el.clientHeight < el.scrollHeight || el.clientWidth < el.scrollWidth) {\n var style = getComputedStyle(el, null);\n return canOverflow(style.overflowY, skipOverflowHiddenElements) || canOverflow(style.overflowX, skipOverflowHiddenElements) || isHiddenByFrame(el);\n }\n\n return false;\n}\n\nfunction alignNearest(scrollingEdgeStart, scrollingEdgeEnd, scrollingSize, scrollingBorderStart, scrollingBorderEnd, elementEdgeStart, elementEdgeEnd, elementSize) {\n if (elementEdgeStart < scrollingEdgeStart && elementEdgeEnd > scrollingEdgeEnd || elementEdgeStart > scrollingEdgeStart && elementEdgeEnd < scrollingEdgeEnd) {\n return 0;\n }\n\n if (elementEdgeStart <= scrollingEdgeStart && elementSize <= scrollingSize || elementEdgeEnd >= scrollingEdgeEnd && elementSize >= scrollingSize) {\n return elementEdgeStart - scrollingEdgeStart - scrollingBorderStart;\n }\n\n if (elementEdgeEnd > scrollingEdgeEnd && elementSize < scrollingSize || elementEdgeStart < scrollingEdgeStart && elementSize > scrollingSize) {\n return elementEdgeEnd - scrollingEdgeEnd + scrollingBorderEnd;\n }\n\n return 0;\n}\n\nexport default (function (target, options) {\n var scrollMode = options.scrollMode,\n block = options.block,\n inline = options.inline,\n boundary = options.boundary,\n skipOverflowHiddenElements = options.skipOverflowHiddenElements;\n var checkBoundary = typeof boundary === 'function' ? boundary : function (node) {\n return node !== boundary;\n };\n\n if (!isElement(target)) {\n throw new TypeError('Invalid target');\n }\n\n var scrollingElement = document.scrollingElement || document.documentElement;\n var frames = [];\n var cursor = target;\n\n while (isElement(cursor) && checkBoundary(cursor)) {\n cursor = cursor.parentNode;\n\n if (cursor === scrollingElement) {\n frames.push(cursor);\n break;\n }\n\n if (cursor === document.body && isScrollable(cursor) && !isScrollable(document.documentElement)) {\n continue;\n }\n\n if (isScrollable(cursor, skipOverflowHiddenElements)) {\n frames.push(cursor);\n }\n }\n\n var viewportWidth = window.visualViewport ? visualViewport.width : innerWidth;\n var viewportHeight = window.visualViewport ? visualViewport.height : innerHeight;\n var viewportX = window.scrollX || pageXOffset;\n var viewportY = window.scrollY || pageYOffset;\n\n var _target$getBoundingCl = target.getBoundingClientRect(),\n targetHeight = _target$getBoundingCl.height,\n targetWidth = _target$getBoundingCl.width,\n targetTop = _target$getBoundingCl.top,\n targetRight = _target$getBoundingCl.right,\n targetBottom = _target$getBoundingCl.bottom,\n targetLeft = _target$getBoundingCl.left;\n\n var targetBlock = block === 'start' || block === 'nearest' ? targetTop : block === 'end' ? targetBottom : targetTop + targetHeight / 2;\n var targetInline = inline === 'center' ? targetLeft + targetWidth / 2 : inline === 'end' ? targetRight : targetLeft;\n var computations = [];\n\n for (var index = 0; index < frames.length; index++) {\n var frame = frames[index];\n\n var _frame$getBoundingCli = frame.getBoundingClientRect(),\n height = _frame$getBoundingCli.height,\n width = _frame$getBoundingCli.width,\n top = _frame$getBoundingCli.top,\n right = _frame$getBoundingCli.right,\n bottom = _frame$getBoundingCli.bottom,\n left = _frame$getBoundingCli.left;\n\n if (scrollMode === 'if-needed' && targetTop >= 0 && targetLeft >= 0 && targetBottom <= viewportHeight && targetRight <= viewportWidth && targetTop >= top && targetBottom <= bottom && targetLeft >= left && targetRight <= right) {\n return computations;\n }\n\n var frameStyle = getComputedStyle(frame);\n var borderLeft = parseInt(frameStyle.borderLeftWidth, 10);\n var borderTop = parseInt(frameStyle.borderTopWidth, 10);\n var borderRight = parseInt(frameStyle.borderRightWidth, 10);\n var borderBottom = parseInt(frameStyle.borderBottomWidth, 10);\n var blockScroll = 0;\n var inlineScroll = 0;\n var scrollbarWidth = 'offsetWidth' in frame ? frame.offsetWidth - frame.clientWidth - borderLeft - borderRight : 0;\n var scrollbarHeight = 'offsetHeight' in frame ? frame.offsetHeight - frame.clientHeight - borderTop - borderBottom : 0;\n\n if (scrollingElement === frame) {\n if (block === 'start') {\n blockScroll = targetBlock;\n } else if (block === 'end') {\n blockScroll = targetBlock - viewportHeight;\n } else if (block === 'nearest') {\n blockScroll = alignNearest(viewportY, viewportY + viewportHeight, viewportHeight, borderTop, borderBottom, viewportY + targetBlock, viewportY + targetBlock + targetHeight, targetHeight);\n } else {\n blockScroll = targetBlock - viewportHeight / 2;\n }\n\n if (inline === 'start') {\n inlineScroll = targetInline;\n } else if (inline === 'center') {\n inlineScroll = targetInline - viewportWidth / 2;\n } else if (inline === 'end') {\n inlineScroll = targetInline - viewportWidth;\n } else {\n inlineScroll = alignNearest(viewportX, viewportX + viewportWidth, viewportWidth, borderLeft, borderRight, viewportX + targetInline, viewportX + targetInline + targetWidth, targetWidth);\n }\n\n blockScroll = Math.max(0, blockScroll + viewportY);\n inlineScroll = Math.max(0, inlineScroll + viewportX);\n } else {\n if (block === 'start') {\n blockScroll = targetBlock - top - borderTop;\n } else if (block === 'end') {\n blockScroll = targetBlock - bottom + borderBottom + scrollbarHeight;\n } else if (block === 'nearest') {\n blockScroll = alignNearest(top, bottom, height, borderTop, borderBottom + scrollbarHeight, targetBlock, targetBlock + targetHeight, targetHeight);\n } else {\n blockScroll = targetBlock - (top + height / 2) + scrollbarHeight / 2;\n }\n\n if (inline === 'start') {\n inlineScroll = targetInline - left - borderLeft;\n } else if (inline === 'center') {\n inlineScroll = targetInline - (left + width / 2) + scrollbarWidth / 2;\n } else if (inline === 'end') {\n inlineScroll = targetInline - right + borderRight + scrollbarWidth;\n } else {\n inlineScroll = alignNearest(left, right, width, borderLeft, borderRight + scrollbarWidth, targetInline, targetInline + targetWidth, targetWidth);\n }\n\n var scrollLeft = frame.scrollLeft,\n scrollTop = frame.scrollTop;\n blockScroll = Math.max(0, Math.min(scrollTop + blockScroll, frame.scrollHeight - height + scrollbarHeight));\n inlineScroll = Math.max(0, Math.min(scrollLeft + inlineScroll, frame.scrollWidth - width + scrollbarWidth));\n targetBlock += scrollTop - blockScroll;\n targetInline += scrollLeft - inlineScroll;\n }\n\n computations.push({\n el: frame,\n top: blockScroll,\n left: inlineScroll\n });\n }\n\n return computations;\n});","import compute from 'compute-scroll-into-view';\n\nfunction isOptionsObject(options) {\n return options === Object(options) && Object.keys(options).length !== 0;\n}\n\nfunction defaultBehavior(actions, behavior) {\n if (behavior === void 0) {\n behavior = 'auto';\n }\n\n var canSmoothScroll = ('scrollBehavior' in document.body.style);\n actions.forEach(function (_ref) {\n var el = _ref.el,\n top = _ref.top,\n left = _ref.left;\n\n if (el.scroll && canSmoothScroll) {\n el.scroll({\n top: top,\n left: left,\n behavior: behavior\n });\n } else {\n el.scrollTop = top;\n el.scrollLeft = left;\n }\n });\n}\n\nfunction getOptions(options) {\n if (options === false) {\n return {\n block: 'end',\n inline: 'nearest'\n };\n }\n\n if (isOptionsObject(options)) {\n return options;\n }\n\n return {\n block: 'start',\n inline: 'nearest'\n };\n}\n\nfunction scrollIntoView(target, options) {\n var targetIsDetached = !target.ownerDocument.documentElement.contains(target);\n\n if (isOptionsObject(options) && typeof options.behavior === 'function') {\n return options.behavior(targetIsDetached ? [] : compute(target, options));\n }\n\n if (targetIsDetached) {\n return;\n }\n\n var computeOptions = getOptions(options);\n return defaultBehavior(compute(target, computeOptions), computeOptions.behavior);\n}\n\nexport default scrollIntoView;","export function toArray(candidate) {\n if (candidate === undefined || candidate === false) return [];\n return Array.isArray(candidate) ? candidate : [candidate];\n}\nexport function getFieldId(namePath, formName) {\n if (!namePath.length) return undefined;\n var mergedId = namePath.join('_');\n return formName ? \"\".concat(formName, \"_\").concat(mergedId) : mergedId;\n}","import _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport { useRef, useMemo } from 'react';\nimport { useForm as useRcForm } from 'rc-field-form';\nimport scrollIntoView from 'scroll-into-view-if-needed';\nimport { toArray, getFieldId } from '../util';\n\nfunction toNamePathStr(name) {\n var namePath = toArray(name);\n return namePath.join('_');\n}\n\nexport default function useForm(form) {\n var _useRcForm = useRcForm(),\n _useRcForm2 = _slicedToArray(_useRcForm, 1),\n rcForm = _useRcForm2[0];\n\n var itemsRef = useRef({});\n var wrapForm = useMemo(function () {\n return form || _extends(_extends({}, rcForm), {\n __INTERNAL__: {\n itemRef: function itemRef(name) {\n return function (node) {\n var namePathStr = toNamePathStr(name);\n\n if (node) {\n itemsRef.current[namePathStr] = node;\n } else {\n delete itemsRef.current[namePathStr];\n }\n };\n }\n },\n scrollToField: function scrollToField(name) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n var namePath = toArray(name);\n var fieldId = getFieldId(namePath, wrapForm.__INTERNAL__.name);\n var node = fieldId ? document.getElementById(fieldId) : null;\n\n if (node) {\n scrollIntoView(node, _extends({\n scrollMode: 'if-needed',\n block: 'nearest'\n }, options));\n }\n },\n getFieldInstance: function getFieldInstance(name) {\n var namePathStr = toNamePathStr(name);\n return itemsRef.current[namePathStr];\n }\n });\n }, [form, rcForm]);\n return [wrapForm];\n}","import _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport { useMemo } from 'react';\nimport classNames from 'classnames';\nimport FieldForm, { List } from 'rc-field-form';\nimport { ConfigContext } from '../config-provider';\nimport { FormContext } from './context';\nimport useForm from './hooks/useForm';\nimport SizeContext, { SizeContextProvider } from '../config-provider/SizeContext';\n\nvar InternalForm = function InternalForm(props, ref) {\n var _classNames;\n\n var contextSize = React.useContext(SizeContext);\n\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls,\n direction = _React$useContext.direction;\n\n var name = props.name;\n\n var customizePrefixCls = props.prefixCls,\n _props$className = props.className,\n className = _props$className === void 0 ? '' : _props$className,\n _props$size = props.size,\n size = _props$size === void 0 ? contextSize : _props$size,\n form = props.form,\n colon = props.colon,\n labelAlign = props.labelAlign,\n labelCol = props.labelCol,\n wrapperCol = props.wrapperCol,\n hideRequiredMark = props.hideRequiredMark,\n _props$layout = props.layout,\n layout = _props$layout === void 0 ? 'horizontal' : _props$layout,\n scrollToFirstError = props.scrollToFirstError,\n requiredMark = props.requiredMark,\n onFinishFailed = props.onFinishFailed,\n restFormProps = __rest(props, [\"prefixCls\", \"className\", \"size\", \"form\", \"colon\", \"labelAlign\", \"labelCol\", \"wrapperCol\", \"hideRequiredMark\", \"layout\", \"scrollToFirstError\", \"requiredMark\", \"onFinishFailed\"]);\n\n var mergedRequiredMark = useMemo(function () {\n if (requiredMark !== undefined) {\n return requiredMark;\n }\n\n if (hideRequiredMark) {\n return false;\n }\n\n return true;\n }, [hideRequiredMark, requiredMark]);\n var prefixCls = getPrefixCls('form', customizePrefixCls);\n var formClassName = classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(layout), true), _defineProperty(_classNames, \"\".concat(prefixCls, \"-hide-required-mark\"), mergedRequiredMark === false), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(size), size), _classNames), className);\n\n var _useForm = useForm(form),\n _useForm2 = _slicedToArray(_useForm, 1),\n wrapForm = _useForm2[0];\n\n var __INTERNAL__ = wrapForm.__INTERNAL__;\n __INTERNAL__.name = name;\n var formContextValue = useMemo(function () {\n return {\n name: name,\n labelAlign: labelAlign,\n labelCol: labelCol,\n wrapperCol: wrapperCol,\n vertical: layout === 'vertical',\n colon: colon,\n requiredMark: mergedRequiredMark,\n itemRef: __INTERNAL__.itemRef\n };\n }, [name, labelAlign, labelCol, wrapperCol, layout, colon, mergedRequiredMark]);\n React.useImperativeHandle(ref, function () {\n return wrapForm;\n });\n\n var onInternalFinishFailed = function onInternalFinishFailed(errorInfo) {\n if (onFinishFailed) {\n onFinishFailed(errorInfo);\n }\n\n if (scrollToFirstError && errorInfo.errorFields.length) {\n wrapForm.scrollToField(errorInfo.errorFields[0].name);\n }\n };\n\n return /*#__PURE__*/React.createElement(SizeContextProvider, {\n size: size\n }, /*#__PURE__*/React.createElement(FormContext.Provider, {\n value: formContextValue\n }, /*#__PURE__*/React.createElement(FieldForm, _extends({\n id: name\n }, restFormProps, {\n onFinishFailed: onInternalFinishFailed,\n form: wrapForm,\n className: formClassName\n }))));\n};\n\nvar Form = /*#__PURE__*/React.forwardRef(InternalForm);\nexport { useForm, List };\nexport default Form;","import { createContext } from 'react';\nvar RowContext = /*#__PURE__*/createContext({});\nexport default RowContext;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _typeof from \"@babel/runtime/helpers/typeof\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { ConfigConsumer } from '../config-provider';\nimport RowContext from './RowContext';\nimport { tuple } from '../_util/type';\nimport ResponsiveObserve, { responsiveArray } from '../_util/responsiveObserve';\nvar RowAligns = tuple('top', 'middle', 'bottom', 'stretch');\nvar RowJustify = tuple('start', 'end', 'center', 'space-around', 'space-between');\nvar Row = /*#__PURE__*/React.forwardRef(function (props, ref) {\n var _React$useState = React.useState({\n xs: true,\n sm: true,\n md: true,\n lg: true,\n xl: true,\n xxl: true\n }),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n screens = _React$useState2[0],\n setScreens = _React$useState2[1];\n\n var gutterRef = React.useRef();\n gutterRef.current = props.gutter;\n React.useEffect(function () {\n var token = ResponsiveObserve.subscribe(function (screen) {\n var currentGutter = gutterRef.current || 0;\n\n if (!Array.isArray(currentGutter) && _typeof(currentGutter) === 'object' || Array.isArray(currentGutter) && (_typeof(currentGutter[0]) === 'object' || _typeof(currentGutter[1]) === 'object')) {\n setScreens(screen);\n }\n });\n return function () {\n ResponsiveObserve.unsubscribe(token);\n };\n }, []);\n\n var getGutter = function getGutter() {\n var results = [0, 0];\n var _props$gutter = props.gutter,\n gutter = _props$gutter === void 0 ? 0 : _props$gutter;\n var normalizedGutter = Array.isArray(gutter) ? gutter : [gutter, 0];\n normalizedGutter.forEach(function (g, index) {\n if (_typeof(g) === 'object') {\n for (var i = 0; i < responsiveArray.length; i++) {\n var breakpoint = responsiveArray[i];\n\n if (screens[breakpoint] && g[breakpoint] !== undefined) {\n results[index] = g[breakpoint];\n break;\n }\n }\n } else {\n results[index] = g || 0;\n }\n });\n return results;\n };\n\n var renderRow = function renderRow(_ref) {\n var _classNames;\n\n var getPrefixCls = _ref.getPrefixCls,\n direction = _ref.direction;\n\n var customizePrefixCls = props.prefixCls,\n justify = props.justify,\n align = props.align,\n className = props.className,\n style = props.style,\n children = props.children,\n others = __rest(props, [\"prefixCls\", \"justify\", \"align\", \"className\", \"style\", \"children\"]);\n\n var prefixCls = getPrefixCls('row', customizePrefixCls);\n var gutter = getGutter();\n var classes = classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(justify), justify), _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(align), align), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _classNames), className);\n\n var rowStyle = _extends(_extends(_extends({}, gutter[0] > 0 ? {\n marginLeft: gutter[0] / -2,\n marginRight: gutter[0] / -2\n } : {}), gutter[1] > 0 ? {\n marginTop: gutter[1] / -2,\n marginBottom: gutter[1] / 2\n } : {}), style);\n\n var otherProps = _extends({}, others);\n\n delete otherProps.gutter;\n return /*#__PURE__*/React.createElement(RowContext.Provider, {\n value: {\n gutter: gutter\n }\n }, /*#__PURE__*/React.createElement(\"div\", _extends({}, otherProps, {\n className: classes,\n style: rowStyle,\n ref: ref\n }), children));\n };\n\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, renderRow);\n});\nRow.displayName = 'Row';\nexport default Row;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport _typeof from \"@babel/runtime/helpers/typeof\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport RowContext from './RowContext';\nimport { ConfigConsumer } from '../config-provider';\n\nfunction parseFlex(flex) {\n if (typeof flex === 'number') {\n return \"\".concat(flex, \" \").concat(flex, \" auto\");\n }\n\n if (/^\\d+(\\.\\d+)?(px|em|rem|%)$/.test(flex)) {\n return \"0 0 \".concat(flex);\n }\n\n return flex;\n}\n\nvar Col = /*#__PURE__*/React.forwardRef(function (props, ref) {\n var renderCol = function renderCol(_ref) {\n var _classNames;\n\n var getPrefixCls = _ref.getPrefixCls,\n direction = _ref.direction;\n\n var customizePrefixCls = props.prefixCls,\n span = props.span,\n order = props.order,\n offset = props.offset,\n push = props.push,\n pull = props.pull,\n className = props.className,\n children = props.children,\n flex = props.flex,\n style = props.style,\n others = __rest(props, [\"prefixCls\", \"span\", \"order\", \"offset\", \"push\", \"pull\", \"className\", \"children\", \"flex\", \"style\"]);\n\n var prefixCls = getPrefixCls('col', customizePrefixCls);\n var sizeClassObj = {};\n ['xs', 'sm', 'md', 'lg', 'xl', 'xxl'].forEach(function (size) {\n var _extends2;\n\n var sizeProps = {};\n var propSize = props[size];\n\n if (typeof propSize === 'number') {\n sizeProps.span = propSize;\n } else if (_typeof(propSize) === 'object') {\n sizeProps = propSize || {};\n }\n\n delete others[size];\n sizeClassObj = _extends(_extends({}, sizeClassObj), (_extends2 = {}, _defineProperty(_extends2, \"\".concat(prefixCls, \"-\").concat(size, \"-\").concat(sizeProps.span), sizeProps.span !== undefined), _defineProperty(_extends2, \"\".concat(prefixCls, \"-\").concat(size, \"-order-\").concat(sizeProps.order), sizeProps.order || sizeProps.order === 0), _defineProperty(_extends2, \"\".concat(prefixCls, \"-\").concat(size, \"-offset-\").concat(sizeProps.offset), sizeProps.offset || sizeProps.offset === 0), _defineProperty(_extends2, \"\".concat(prefixCls, \"-\").concat(size, \"-push-\").concat(sizeProps.push), sizeProps.push || sizeProps.push === 0), _defineProperty(_extends2, \"\".concat(prefixCls, \"-\").concat(size, \"-pull-\").concat(sizeProps.pull), sizeProps.pull || sizeProps.pull === 0), _defineProperty(_extends2, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _extends2));\n });\n var classes = classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(span), span !== undefined), _defineProperty(_classNames, \"\".concat(prefixCls, \"-order-\").concat(order), order), _defineProperty(_classNames, \"\".concat(prefixCls, \"-offset-\").concat(offset), offset), _defineProperty(_classNames, \"\".concat(prefixCls, \"-push-\").concat(push), push), _defineProperty(_classNames, \"\".concat(prefixCls, \"-pull-\").concat(pull), pull), _classNames), className, sizeClassObj);\n return /*#__PURE__*/React.createElement(RowContext.Consumer, null, function (_ref2) {\n var gutter = _ref2.gutter;\n\n var mergedStyle = _extends({}, style);\n\n if (gutter) {\n mergedStyle = _extends(_extends(_extends({}, gutter[0] > 0 ? {\n paddingLeft: gutter[0] / 2,\n paddingRight: gutter[0] / 2\n } : {}), gutter[1] > 0 ? {\n paddingTop: gutter[1] / 2,\n paddingBottom: gutter[1] / 2\n } : {}), mergedStyle);\n }\n\n if (flex) {\n mergedStyle.flex = parseFlex(flex);\n }\n\n return /*#__PURE__*/React.createElement(\"div\", _extends({}, others, {\n style: mergedStyle,\n className: classes,\n ref: ref\n }), children);\n });\n };\n\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, renderCol);\n});\nCol.displayName = 'Col';\nexport default Col;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport Col from '../grid/col';\nimport { FormContext } from './context';\nimport { useLocaleReceiver } from '../locale-provider/LocaleReceiver';\nimport defaultLocale from '../locale/default';\n\nvar FormItemLabel = function FormItemLabel(_ref) {\n var prefixCls = _ref.prefixCls,\n label = _ref.label,\n htmlFor = _ref.htmlFor,\n labelCol = _ref.labelCol,\n labelAlign = _ref.labelAlign,\n colon = _ref.colon,\n required = _ref.required,\n requiredMark = _ref.requiredMark;\n\n var _useLocaleReceiver = useLocaleReceiver('Form'),\n _useLocaleReceiver2 = _slicedToArray(_useLocaleReceiver, 1),\n formLocale = _useLocaleReceiver2[0];\n\n if (!label) return null;\n return /*#__PURE__*/React.createElement(FormContext.Consumer, {\n key: \"label\"\n }, function (_ref2) {\n var _classNames;\n\n var vertical = _ref2.vertical,\n contextLabelAlign = _ref2.labelAlign,\n contextLabelCol = _ref2.labelCol,\n contextColon = _ref2.colon;\n\n var _a;\n\n var mergedLabelCol = labelCol || contextLabelCol || {};\n var mergedLabelAlign = labelAlign || contextLabelAlign;\n var labelClsBasic = \"\".concat(prefixCls, \"-item-label\");\n var labelColClassName = classNames(labelClsBasic, mergedLabelAlign === 'left' && \"\".concat(labelClsBasic, \"-left\"), mergedLabelCol.className);\n var labelChildren = label; // Keep label is original where there should have no colon\n\n var computedColon = colon === true || contextColon !== false && colon !== false;\n var haveColon = computedColon && !vertical; // Remove duplicated user input colon\n\n if (haveColon && typeof label === 'string' && label.trim() !== '') {\n labelChildren = label.replace(/[:|:]\\s*$/, '');\n } // Add required mark if optional\n\n\n if (requiredMark === 'optional' && !required) {\n labelChildren = /*#__PURE__*/React.createElement(React.Fragment, null, labelChildren, /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-item-optional\")\n }, (formLocale === null || formLocale === void 0 ? void 0 : formLocale.optional) || ((_a = defaultLocale.Form) === null || _a === void 0 ? void 0 : _a.optional)));\n }\n\n var labelClassName = classNames((_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-item-required\"), required), _defineProperty(_classNames, \"\".concat(prefixCls, \"-item-required-mark-optional\"), requiredMark === 'optional'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-item-no-colon\"), !computedColon), _classNames));\n return /*#__PURE__*/React.createElement(Col, _extends({}, mergedLabelCol, {\n className: labelColClassName\n }), /*#__PURE__*/React.createElement(\"label\", {\n htmlFor: htmlFor,\n className: labelClassName,\n title: typeof label === 'string' ? label : ''\n }, labelChildren));\n });\n};\n\nexport default FormItemLabel;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport LoadingOutlined from '@ant-design/icons/LoadingOutlined';\nimport CloseCircleFilled from '@ant-design/icons/CloseCircleFilled';\nimport CheckCircleFilled from '@ant-design/icons/CheckCircleFilled';\nimport ExclamationCircleFilled from '@ant-design/icons/ExclamationCircleFilled';\nimport useMemo from \"rc-util/es/hooks/useMemo\";\nimport CSSMotion from 'rc-motion';\nimport Col from '../grid/col';\nimport { FormContext } from './context';\nimport useCacheErrors from './hooks/useCacheErrors';\nimport useForceUpdate from '../_util/hooks/useForceUpdate';\nvar iconMap = {\n success: CheckCircleFilled,\n warning: ExclamationCircleFilled,\n error: CloseCircleFilled,\n validating: LoadingOutlined\n};\n\nvar FormItemInput = function FormItemInput(_ref) {\n var prefixCls = _ref.prefixCls,\n wrapperCol = _ref.wrapperCol,\n children = _ref.children,\n help = _ref.help,\n errors = _ref.errors,\n onDomErrorVisibleChange = _ref.onDomErrorVisibleChange,\n hasFeedback = _ref.hasFeedback,\n validateStatus = _ref.validateStatus,\n extra = _ref.extra;\n var forceUpdate = useForceUpdate();\n var baseClassName = \"\".concat(prefixCls, \"-item\");\n var formContext = React.useContext(FormContext);\n var mergedWrapperCol = wrapperCol || formContext.wrapperCol || {};\n var className = classNames(\"\".concat(baseClassName, \"-control\"), mergedWrapperCol.className);\n\n var _useCacheErrors = useCacheErrors(errors, function (changedVisible) {\n if (changedVisible) {\n /**\n * We trigger in sync to avoid dom shaking but this get warning in react 16.13.\n * So use Promise to keep in micro async to handle this.\n * https://github.com/ant-design/ant-design/issues/21698#issuecomment-593743485\n */\n Promise.resolve().then(function () {\n onDomErrorVisibleChange(true);\n });\n }\n\n forceUpdate();\n }, !!help),\n _useCacheErrors2 = _slicedToArray(_useCacheErrors, 2),\n visible = _useCacheErrors2[0],\n cacheErrors = _useCacheErrors2[1];\n\n React.useEffect(function () {\n return function () {\n onDomErrorVisibleChange(false);\n };\n }, []);\n var memoErrors = useMemo(function () {\n return cacheErrors;\n }, visible, function (_, nextVisible) {\n return nextVisible;\n }); // Should provides additional icon if `hasFeedback`\n\n var IconNode = validateStatus && iconMap[validateStatus];\n var icon = hasFeedback && IconNode ? /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(baseClassName, \"-children-icon\")\n }, /*#__PURE__*/React.createElement(IconNode, null)) : null; // Pass to sub FormItem should not with col info\n\n var subFormContext = _extends({}, formContext);\n\n delete subFormContext.labelCol;\n delete subFormContext.wrapperCol;\n return /*#__PURE__*/React.createElement(FormContext.Provider, {\n value: subFormContext\n }, /*#__PURE__*/React.createElement(Col, _extends({}, mergedWrapperCol, {\n className: className\n }), /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(baseClassName, \"-control-input\")\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(baseClassName, \"-control-input-content\")\n }, children), icon), /*#__PURE__*/React.createElement(CSSMotion, {\n motionDeadline: 500,\n visible: visible,\n motionName: \"show-help\",\n onLeaveEnd: function onLeaveEnd() {\n onDomErrorVisibleChange(false);\n },\n motionAppear: true,\n removeOnLeave: true\n }, function (_ref2) {\n var motionClassName = _ref2.className;\n return /*#__PURE__*/React.createElement(\"div\", {\n className: classNames(\"\".concat(baseClassName, \"-explain\"), motionClassName),\n key: \"help\"\n }, memoErrors.map(function (error, index) {\n return (\n /*#__PURE__*/\n // eslint-disable-next-line react/no-array-index-key\n React.createElement(\"div\", {\n key: index,\n role: \"alert\"\n }, error)\n );\n }));\n }), extra && /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(baseClassName, \"-extra\")\n }, extra)));\n};\n\nexport default FormItemInput;","import * as React from 'react';\nimport useForceUpdate from '../../_util/hooks/useForceUpdate';\n/**\n * Always debounce error to avoid [error -> null -> error] blink\n */\n\nexport default function useCacheErrors(errors, changeTrigger, directly) {\n var cacheRef = React.useRef({\n errors: errors,\n visible: !!errors.length\n });\n var forceUpdate = useForceUpdate();\n\n var update = function update() {\n var prevVisible = cacheRef.current.visible;\n var newVisible = !!errors.length;\n var prevErrors = cacheRef.current.errors;\n cacheRef.current.errors = errors;\n cacheRef.current.visible = newVisible;\n\n if (prevVisible !== newVisible) {\n changeTrigger(newVisible);\n } else if (prevErrors.length !== errors.length || prevErrors.some(function (prevErr, index) {\n return prevErr !== errors[index];\n })) {\n forceUpdate();\n }\n };\n\n React.useEffect(function () {\n if (!directly) {\n var timeout = setTimeout(update, 10);\n return function () {\n return clearTimeout(timeout);\n };\n }\n }, [errors]);\n\n if (directly) {\n update();\n }\n\n return [cacheRef.current.visible, cacheRef.current.errors];\n}","import _typeof from \"@babel/runtime/helpers/typeof\";\nimport _toConsumableArray from \"@babel/runtime/helpers/toConsumableArray\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport isEqual from 'lodash/isEqual';\nimport classNames from 'classnames';\nimport { Field } from 'rc-field-form';\nimport FieldContext from \"rc-field-form/es/FieldContext\";\nimport { supportRef } from \"rc-util/es/ref\";\nimport omit from 'omit.js';\nimport Row from '../grid/row';\nimport { ConfigContext } from '../config-provider';\nimport { tuple } from '../_util/type';\nimport devWarning from '../_util/devWarning';\nimport FormItemLabel from './FormItemLabel';\nimport FormItemInput from './FormItemInput';\nimport { FormContext, FormItemContext } from './context';\nimport { toArray, getFieldId } from './util';\nimport { cloneElement, isValidElement } from '../_util/reactNode';\nimport useFrameState from './hooks/useFrameState';\nimport useItemRef from './hooks/useItemRef';\nvar ValidateStatuses = tuple('success', 'warning', 'error', 'validating', '');\nvar MemoInput = /*#__PURE__*/React.memo(function (_ref) {\n var children = _ref.children;\n return children;\n}, function (prev, next) {\n return prev.value === next.value && prev.update === next.update;\n});\n\nfunction hasValidName(name) {\n if (name === null) {\n devWarning(false, 'Form.Item', '`null` is passed as `name` property');\n }\n\n return !(name === undefined || name === null);\n}\n\nfunction FormItem(props) {\n var name = props.name,\n fieldKey = props.fieldKey,\n noStyle = props.noStyle,\n dependencies = props.dependencies,\n customizePrefixCls = props.prefixCls,\n style = props.style,\n className = props.className,\n shouldUpdate = props.shouldUpdate,\n hasFeedback = props.hasFeedback,\n help = props.help,\n rules = props.rules,\n validateStatus = props.validateStatus,\n children = props.children,\n required = props.required,\n label = props.label,\n _props$trigger = props.trigger,\n trigger = _props$trigger === void 0 ? 'onChange' : _props$trigger,\n validateTrigger = props.validateTrigger,\n hidden = props.hidden,\n restProps = __rest(props, [\"name\", \"fieldKey\", \"noStyle\", \"dependencies\", \"prefixCls\", \"style\", \"className\", \"shouldUpdate\", \"hasFeedback\", \"help\", \"rules\", \"validateStatus\", \"children\", \"required\", \"label\", \"trigger\", \"validateTrigger\", \"hidden\"]);\n\n var destroyRef = React.useRef(false);\n\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls;\n\n var _React$useContext2 = React.useContext(FormContext),\n formName = _React$useContext2.name,\n requiredMark = _React$useContext2.requiredMark;\n\n var _React$useContext3 = React.useContext(FormItemContext),\n updateItemErrors = _React$useContext3.updateItemErrors;\n\n var _React$useState = React.useState(!!help),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n domErrorVisible = _React$useState2[0],\n innerSetDomErrorVisible = _React$useState2[1];\n\n var prevValidateStatusRef = React.useRef(validateStatus);\n\n var _useFrameState = useFrameState({}),\n _useFrameState2 = _slicedToArray(_useFrameState, 2),\n inlineErrors = _useFrameState2[0],\n setInlineErrors = _useFrameState2[1];\n\n var _React$useContext4 = React.useContext(FieldContext),\n contextValidateTrigger = _React$useContext4.validateTrigger;\n\n var mergedValidateTrigger = validateTrigger !== undefined ? validateTrigger : contextValidateTrigger;\n\n function setDomErrorVisible(visible) {\n if (!destroyRef.current) {\n innerSetDomErrorVisible(visible);\n }\n }\n\n var hasName = hasValidName(name); // Cache Field NamePath\n\n var nameRef = React.useRef([]); // Should clean up if Field removed\n\n React.useEffect(function () {\n return function () {\n destroyRef.current = true;\n updateItemErrors(nameRef.current.join('__SPLIT__'), []);\n };\n }, []);\n var prefixCls = getPrefixCls('form', customizePrefixCls); // ======================== Errors ========================\n // Collect noStyle Field error to the top FormItem\n\n var updateChildItemErrors = noStyle ? updateItemErrors : function (subName, subErrors) {\n setInlineErrors(function () {\n var prevInlineErrors = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n\n if (!isEqual(prevInlineErrors[subName], subErrors)) {\n return _extends(_extends({}, prevInlineErrors), _defineProperty({}, subName, subErrors));\n }\n\n return prevInlineErrors;\n });\n }; // ===================== Children Ref =====================\n\n var getItemRef = useItemRef();\n\n function renderLayout(baseChildren, fieldId, meta, isRequired) {\n var _itemClassName;\n\n var _a;\n\n if (noStyle && !hidden) {\n return baseChildren;\n } // ======================== Errors ========================\n // >>> collect sub errors\n\n\n var subErrorList = [];\n Object.keys(inlineErrors).forEach(function (subName) {\n subErrorList = [].concat(_toConsumableArray(subErrorList), _toConsumableArray(inlineErrors[subName] || []));\n }); // >>> merged errors\n\n var mergedErrors;\n\n if (help !== undefined && help !== null) {\n mergedErrors = toArray(help);\n } else {\n mergedErrors = meta ? meta.errors : [];\n mergedErrors = [].concat(_toConsumableArray(mergedErrors), _toConsumableArray(subErrorList));\n } // ======================== Status ========================\n\n\n var mergedValidateStatus = '';\n\n if (validateStatus !== undefined) {\n mergedValidateStatus = validateStatus;\n } else if (meta === null || meta === void 0 ? void 0 : meta.validating) {\n mergedValidateStatus = 'validating';\n } else if (((_a = meta === null || meta === void 0 ? void 0 : meta.errors) === null || _a === void 0 ? void 0 : _a.length) || subErrorList.length) {\n mergedValidateStatus = 'error';\n } else if (meta === null || meta === void 0 ? void 0 : meta.touched) {\n mergedValidateStatus = 'success';\n }\n\n if (domErrorVisible && help) {\n prevValidateStatusRef.current = mergedValidateStatus;\n }\n\n var itemClassName = (_itemClassName = {}, _defineProperty(_itemClassName, \"\".concat(prefixCls, \"-item\"), true), _defineProperty(_itemClassName, \"\".concat(prefixCls, \"-item-with-help\"), domErrorVisible || help), _defineProperty(_itemClassName, \"\".concat(className), !!className), _defineProperty(_itemClassName, \"\".concat(prefixCls, \"-item-has-feedback\"), mergedValidateStatus && hasFeedback), _defineProperty(_itemClassName, \"\".concat(prefixCls, \"-item-has-success\"), mergedValidateStatus === 'success'), _defineProperty(_itemClassName, \"\".concat(prefixCls, \"-item-has-warning\"), mergedValidateStatus === 'warning'), _defineProperty(_itemClassName, \"\".concat(prefixCls, \"-item-has-error\"), mergedValidateStatus === 'error'), _defineProperty(_itemClassName, \"\".concat(prefixCls, \"-item-has-error-leave\"), !help && domErrorVisible && prevValidateStatusRef.current === 'error'), _defineProperty(_itemClassName, \"\".concat(prefixCls, \"-item-is-validating\"), mergedValidateStatus === 'validating'), _defineProperty(_itemClassName, \"\".concat(prefixCls, \"-item-hidden\"), hidden), _itemClassName); // ======================= Children =======================\n\n return /*#__PURE__*/React.createElement(Row, _extends({\n className: classNames(itemClassName),\n style: style,\n key: \"row\"\n }, omit(restProps, ['colon', 'extra', 'getValueFromEvent', 'getValueProps', 'hasFeedback', 'help', 'htmlFor', 'id', 'initialValue', 'isListField', 'label', 'labelAlign', 'labelCol', 'normalize', 'preserve', 'required', 'validateFirst', 'validateStatus', 'valuePropName', 'wrapperCol'])), /*#__PURE__*/React.createElement(FormItemLabel, _extends({\n htmlFor: fieldId,\n required: isRequired,\n requiredMark: requiredMark\n }, props, {\n prefixCls: prefixCls\n })), /*#__PURE__*/React.createElement(FormItemInput, _extends({}, props, meta, {\n errors: mergedErrors,\n prefixCls: prefixCls,\n onDomErrorVisibleChange: setDomErrorVisible,\n validateStatus: mergedValidateStatus\n }), /*#__PURE__*/React.createElement(FormItemContext.Provider, {\n value: {\n updateItemErrors: updateChildItemErrors\n }\n }, baseChildren)));\n }\n\n var isRenderProps = typeof children === 'function'; // Record for real component render\n\n var updateRef = React.useRef(0);\n updateRef.current += 1;\n\n if (!hasName && !isRenderProps && !dependencies) {\n return renderLayout(children);\n }\n\n var variables = {};\n\n if (typeof label === 'string') {\n variables.label = label;\n }\n\n return /*#__PURE__*/React.createElement(Field, _extends({}, props, {\n messageVariables: variables,\n trigger: trigger,\n validateTrigger: mergedValidateTrigger,\n onReset: function onReset() {\n setDomErrorVisible(false);\n }\n }), function (control, meta, context) {\n var errors = meta.errors;\n var mergedName = toArray(name).length && meta ? meta.name : [];\n var fieldId = getFieldId(mergedName, formName);\n\n if (noStyle) {\n nameRef.current = _toConsumableArray(mergedName);\n\n if (fieldKey) {\n var fieldKeys = Array.isArray(fieldKey) ? fieldKey : [fieldKey];\n nameRef.current = [].concat(_toConsumableArray(mergedName.slice(0, -1)), _toConsumableArray(fieldKeys));\n }\n\n updateItemErrors(nameRef.current.join('__SPLIT__'), errors);\n }\n\n var isRequired = required !== undefined ? required : !!(rules && rules.some(function (rule) {\n if (rule && _typeof(rule) === 'object' && rule.required) {\n return true;\n }\n\n if (typeof rule === 'function') {\n var ruleEntity = rule(context);\n return ruleEntity && ruleEntity.required;\n }\n\n return false;\n })); // ======================= Children =======================\n\n var mergedControl = _extends({}, control);\n\n var childNode = null;\n devWarning(!(shouldUpdate && dependencies), 'Form.Item', \"`shouldUpdate` and `dependencies` shouldn't be used together. See https://ant.design/components/form/#dependencies.\");\n\n if (Array.isArray(children) && hasName) {\n devWarning(false, 'Form.Item', '`children` is array of render props cannot have `name`.');\n childNode = children;\n } else if (isRenderProps && (!(shouldUpdate || dependencies) || hasName)) {\n devWarning(!!(shouldUpdate || dependencies), 'Form.Item', '`children` of render props only work with `shouldUpdate` or `dependencies`.');\n devWarning(!hasName, 'Form.Item', \"Do not use `name` with `children` of render props since it's not a field.\");\n } else if (dependencies && !isRenderProps && !hasName) {\n devWarning(false, 'Form.Item', 'Must set `name` or use render props when `dependencies` is set.');\n } else if (isValidElement(children)) {\n devWarning(children.props.defaultValue === undefined, 'Form.Item', '`defaultValue` will not work on controlled Field. You should use `initialValues` of Form instead.');\n\n var childProps = _extends(_extends({}, children.props), mergedControl);\n\n if (!childProps.id) {\n childProps.id = fieldId;\n }\n\n if (supportRef(children)) {\n childProps.ref = getItemRef(mergedName, children);\n } // We should keep user origin event handler\n\n\n var triggers = new Set([].concat(_toConsumableArray(toArray(trigger)), _toConsumableArray(toArray(mergedValidateTrigger))));\n triggers.forEach(function (eventName) {\n childProps[eventName] = function () {\n var _a2, _c2;\n\n var _a, _b, _c;\n\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n (_a = mergedControl[eventName]) === null || _a === void 0 ? void 0 : (_a2 = _a).call.apply(_a2, [mergedControl].concat(args));\n (_c = (_b = children.props)[eventName]) === null || _c === void 0 ? void 0 : (_c2 = _c).call.apply(_c2, [_b].concat(args));\n };\n });\n childNode = /*#__PURE__*/React.createElement(MemoInput, {\n value: mergedControl[props.valuePropName || 'value'],\n update: updateRef.current\n }, cloneElement(children, childProps));\n } else if (isRenderProps && (shouldUpdate || dependencies) && !hasName) {\n childNode = children(context);\n } else {\n devWarning(!mergedName.length, 'Form.Item', '`name` is only used for validate React element. If you are using Form.Item as layout display, please remove `name` instead.');\n childNode = children;\n }\n\n return renderLayout(childNode, fieldId, meta, isRequired);\n });\n}\n\nexport default FormItem;","import _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nimport { useRef } from 'react';\nimport raf from 'raf';\nexport default function useFrameState(defaultValue) {\n var _React$useState = React.useState(defaultValue),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n value = _React$useState2[0],\n setValue = _React$useState2[1];\n\n var frameRef = useRef(null);\n var batchRef = useRef([]);\n var destroyRef = useRef(false);\n React.useEffect(function () {\n return function () {\n destroyRef.current = true;\n raf.cancel(frameRef.current);\n };\n }, []);\n\n function setFrameValue(updater) {\n if (destroyRef.current) {\n return;\n }\n\n if (frameRef.current === null) {\n batchRef.current = [];\n frameRef.current = raf(function () {\n frameRef.current = null;\n setValue(function (prevValue) {\n var current = prevValue;\n batchRef.current.forEach(function (func) {\n current = func(current);\n });\n return current;\n });\n });\n }\n\n batchRef.current.push(updater);\n }\n\n return [value, setFrameValue];\n}","import _typeof from \"@babel/runtime/helpers/typeof\";\nimport * as React from 'react';\nimport { composeRef } from \"rc-util/es/ref\";\nimport { FormContext } from '../context';\nexport default function useItemRef() {\n var _React$useContext = React.useContext(FormContext),\n itemRef = _React$useContext.itemRef;\n\n var cacheRef = React.useRef({});\n\n function getRef(name, children) {\n var childrenRef = children && _typeof(children) === 'object' && children.ref;\n var nameStr = name.join('_');\n\n if (cacheRef.current.name !== nameStr || cacheRef.current.originRef !== childrenRef) {\n cacheRef.current.name = nameStr;\n cacheRef.current.originRef = childrenRef;\n cacheRef.current.ref = composeRef(itemRef(name), childrenRef);\n }\n\n return cacheRef.current.ref;\n }\n\n return getRef;\n}","import _extends from \"@babel/runtime/helpers/extends\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport { List } from 'rc-field-form';\nimport devWarning from '../_util/devWarning';\n\nvar FormList = function FormList(_a) {\n var children = _a.children,\n props = __rest(_a, [\"children\"]);\n\n devWarning(!!props.name, 'Form.List', 'Miss `name` prop.');\n return /*#__PURE__*/React.createElement(List, props, function (fields, operation) {\n return children(fields.map(function (field) {\n return _extends(_extends({}, field), {\n fieldKey: field.key\n });\n }), operation);\n });\n};\n\nexport default FormList;","import InternalForm, { useForm } from './Form';\nimport Item from './FormItem';\nimport List from './FormList';\nimport { FormProvider } from './context';\nimport devWarning from '../_util/devWarning';\nvar Form = InternalForm;\nForm.Item = Item;\nForm.List = List;\nForm.useForm = useForm;\nForm.Provider = FormProvider;\n\nForm.create = function () {\n devWarning(false, 'Form', 'antd v4 removed `Form.create`. Please remove or use `@ant-design/compatible` instead.');\n};\n\nexport default Form;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _LoadingOutlined = _interopRequireDefault(require('./lib/icons/LoadingOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _LoadingOutlined;\n exports.default = _default;\n module.exports = _default;","import ReactDOM from 'react-dom';\nexport default function addEventListenerWrap(target, eventType, cb, option) {\n /* eslint camelcase: 2 */\n var callback = ReactDOM.unstable_batchedUpdates ? function run(e) {\n ReactDOM.unstable_batchedUpdates(cb, e);\n } : cb;\n\n if (target.addEventListener) {\n target.addEventListener(eventType, callback, option);\n }\n\n return {\n remove: function remove() {\n if (target.removeEventListener) {\n target.removeEventListener(eventType, callback);\n }\n }\n };\n}","'use strict';\n\nvar bind = require('./helpers/bind');\n\n/*global toString:true*/\n\n// utils is a library of generic helper functions non-specific to axios\n\nvar toString = Object.prototype.toString;\n\n/**\n * Determine if a value is an Array\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an Array, otherwise false\n */\nfunction isArray(val) {\n return toString.call(val) === '[object Array]';\n}\n\n/**\n * Determine if a value is undefined\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if the value is undefined, otherwise false\n */\nfunction isUndefined(val) {\n return typeof val === 'undefined';\n}\n\n/**\n * Determine if a value is a Buffer\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Buffer, otherwise false\n */\nfunction isBuffer(val) {\n return val !== null && !isUndefined(val) && val.constructor !== null && !isUndefined(val.constructor)\n && typeof val.constructor.isBuffer === 'function' && val.constructor.isBuffer(val);\n}\n\n/**\n * Determine if a value is an ArrayBuffer\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an ArrayBuffer, otherwise false\n */\nfunction isArrayBuffer(val) {\n return toString.call(val) === '[object ArrayBuffer]';\n}\n\n/**\n * Determine if a value is a FormData\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an FormData, otherwise false\n */\nfunction isFormData(val) {\n return (typeof FormData !== 'undefined') && (val instanceof FormData);\n}\n\n/**\n * Determine if a value is a view on an ArrayBuffer\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false\n */\nfunction isArrayBufferView(val) {\n var result;\n if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) {\n result = ArrayBuffer.isView(val);\n } else {\n result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer);\n }\n return result;\n}\n\n/**\n * Determine if a value is a String\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a String, otherwise false\n */\nfunction isString(val) {\n return typeof val === 'string';\n}\n\n/**\n * Determine if a value is a Number\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Number, otherwise false\n */\nfunction isNumber(val) {\n return typeof val === 'number';\n}\n\n/**\n * Determine if a value is an Object\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is an Object, otherwise false\n */\nfunction isObject(val) {\n return val !== null && typeof val === 'object';\n}\n\n/**\n * Determine if a value is a Date\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Date, otherwise false\n */\nfunction isDate(val) {\n return toString.call(val) === '[object Date]';\n}\n\n/**\n * Determine if a value is a File\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a File, otherwise false\n */\nfunction isFile(val) {\n return toString.call(val) === '[object File]';\n}\n\n/**\n * Determine if a value is a Blob\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Blob, otherwise false\n */\nfunction isBlob(val) {\n return toString.call(val) === '[object Blob]';\n}\n\n/**\n * Determine if a value is a Function\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Function, otherwise false\n */\nfunction isFunction(val) {\n return toString.call(val) === '[object Function]';\n}\n\n/**\n * Determine if a value is a Stream\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a Stream, otherwise false\n */\nfunction isStream(val) {\n return isObject(val) && isFunction(val.pipe);\n}\n\n/**\n * Determine if a value is a URLSearchParams object\n *\n * @param {Object} val The value to test\n * @returns {boolean} True if value is a URLSearchParams object, otherwise false\n */\nfunction isURLSearchParams(val) {\n return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams;\n}\n\n/**\n * Trim excess whitespace off the beginning and end of a string\n *\n * @param {String} str The String to trim\n * @returns {String} The String freed of excess whitespace\n */\nfunction trim(str) {\n return str.replace(/^\\s*/, '').replace(/\\s*$/, '');\n}\n\n/**\n * Determine if we're running in a standard browser environment\n *\n * This allows axios to run in a web worker, and react-native.\n * Both environments support XMLHttpRequest, but not fully standard globals.\n *\n * web workers:\n * typeof window -> undefined\n * typeof document -> undefined\n *\n * react-native:\n * navigator.product -> 'ReactNative'\n * nativescript\n * navigator.product -> 'NativeScript' or 'NS'\n */\nfunction isStandardBrowserEnv() {\n if (typeof navigator !== 'undefined' && (navigator.product === 'ReactNative' ||\n navigator.product === 'NativeScript' ||\n navigator.product === 'NS')) {\n return false;\n }\n return (\n typeof window !== 'undefined' &&\n typeof document !== 'undefined'\n );\n}\n\n/**\n * Iterate over an Array or an Object invoking a function for each item.\n *\n * If `obj` is an Array callback will be called passing\n * the value, index, and complete array for each item.\n *\n * If 'obj' is an Object callback will be called passing\n * the value, key, and complete object for each property.\n *\n * @param {Object|Array} obj The object to iterate\n * @param {Function} fn The callback to invoke for each item\n */\nfunction forEach(obj, fn) {\n // Don't bother if no value provided\n if (obj === null || typeof obj === 'undefined') {\n return;\n }\n\n // Force an array if not already something iterable\n if (typeof obj !== 'object') {\n /*eslint no-param-reassign:0*/\n obj = [obj];\n }\n\n if (isArray(obj)) {\n // Iterate over array values\n for (var i = 0, l = obj.length; i < l; i++) {\n fn.call(null, obj[i], i, obj);\n }\n } else {\n // Iterate over object keys\n for (var key in obj) {\n if (Object.prototype.hasOwnProperty.call(obj, key)) {\n fn.call(null, obj[key], key, obj);\n }\n }\n }\n}\n\n/**\n * Accepts varargs expecting each argument to be an object, then\n * immutably merges the properties of each object and returns result.\n *\n * When multiple objects contain the same key the later object in\n * the arguments list will take precedence.\n *\n * Example:\n *\n * ```js\n * var result = merge({foo: 123}, {foo: 456});\n * console.log(result.foo); // outputs 456\n * ```\n *\n * @param {Object} obj1 Object to merge\n * @returns {Object} Result of all merge properties\n */\nfunction merge(/* obj1, obj2, obj3, ... */) {\n var result = {};\n function assignValue(val, key) {\n if (typeof result[key] === 'object' && typeof val === 'object') {\n result[key] = merge(result[key], val);\n } else {\n result[key] = val;\n }\n }\n\n for (var i = 0, l = arguments.length; i < l; i++) {\n forEach(arguments[i], assignValue);\n }\n return result;\n}\n\n/**\n * Function equal to merge with the difference being that no reference\n * to original objects is kept.\n *\n * @see merge\n * @param {Object} obj1 Object to merge\n * @returns {Object} Result of all merge properties\n */\nfunction deepMerge(/* obj1, obj2, obj3, ... */) {\n var result = {};\n function assignValue(val, key) {\n if (typeof result[key] === 'object' && typeof val === 'object') {\n result[key] = deepMerge(result[key], val);\n } else if (typeof val === 'object') {\n result[key] = deepMerge({}, val);\n } else {\n result[key] = val;\n }\n }\n\n for (var i = 0, l = arguments.length; i < l; i++) {\n forEach(arguments[i], assignValue);\n }\n return result;\n}\n\n/**\n * Extends object a by mutably adding to it the properties of object b.\n *\n * @param {Object} a The object to be extended\n * @param {Object} b The object to copy properties from\n * @param {Object} thisArg The object to bind function to\n * @return {Object} The resulting value of object a\n */\nfunction extend(a, b, thisArg) {\n forEach(b, function assignValue(val, key) {\n if (thisArg && typeof val === 'function') {\n a[key] = bind(val, thisArg);\n } else {\n a[key] = val;\n }\n });\n return a;\n}\n\nmodule.exports = {\n isArray: isArray,\n isArrayBuffer: isArrayBuffer,\n isBuffer: isBuffer,\n isFormData: isFormData,\n isArrayBufferView: isArrayBufferView,\n isString: isString,\n isNumber: isNumber,\n isObject: isObject,\n isUndefined: isUndefined,\n isDate: isDate,\n isFile: isFile,\n isBlob: isBlob,\n isFunction: isFunction,\n isStream: isStream,\n isURLSearchParams: isURLSearchParams,\n isStandardBrowserEnv: isStandardBrowserEnv,\n forEach: forEach,\n merge: merge,\n deepMerge: deepMerge,\n extend: extend,\n trim: trim\n};\n","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nvar canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement); // ================= Transition =================\n// Event wrapper. Copy from react source code\n\nfunction makePrefixMap(styleProp, eventName) {\n var prefixes = {};\n prefixes[styleProp.toLowerCase()] = eventName.toLowerCase();\n prefixes[\"Webkit\".concat(styleProp)] = \"webkit\".concat(eventName);\n prefixes[\"Moz\".concat(styleProp)] = \"moz\".concat(eventName);\n prefixes[\"ms\".concat(styleProp)] = \"MS\".concat(eventName);\n prefixes[\"O\".concat(styleProp)] = \"o\".concat(eventName.toLowerCase());\n return prefixes;\n}\n\nexport function getVendorPrefixes(domSupport, win) {\n var prefixes = {\n animationend: makePrefixMap('Animation', 'AnimationEnd'),\n transitionend: makePrefixMap('Transition', 'TransitionEnd')\n };\n\n if (domSupport) {\n if (!('AnimationEvent' in win)) {\n delete prefixes.animationend.animation;\n }\n\n if (!('TransitionEvent' in win)) {\n delete prefixes.transitionend.transition;\n }\n }\n\n return prefixes;\n}\nvar vendorPrefixes = getVendorPrefixes(canUseDOM, typeof window !== 'undefined' ? window : {});\nvar style = {};\n\nif (canUseDOM) {\n var _document$createEleme = document.createElement('div');\n\n style = _document$createEleme.style;\n}\n\nvar prefixedEventNames = {};\nexport function getVendorPrefixedEventName(eventName) {\n if (prefixedEventNames[eventName]) {\n return prefixedEventNames[eventName];\n }\n\n var prefixMap = vendorPrefixes[eventName];\n\n if (prefixMap) {\n var stylePropList = Object.keys(prefixMap);\n var len = stylePropList.length;\n\n for (var i = 0; i < len; i += 1) {\n var styleProp = stylePropList[i];\n\n if (Object.prototype.hasOwnProperty.call(prefixMap, styleProp) && styleProp in style) {\n prefixedEventNames[eventName] = prefixMap[styleProp];\n return prefixedEventNames[eventName];\n }\n }\n }\n\n return '';\n}\nexport var animationEndName = getVendorPrefixedEventName('animationend');\nexport var transitionEndName = getVendorPrefixedEventName('transitionend');\nexport var supportTransition = !!(animationEndName && transitionEndName);\nexport function getTransitionName(transitionName, transitionType) {\n if (!transitionName) return null;\n\n if (_typeof(transitionName) === 'object') {\n var type = transitionType.replace(/-\\w/g, function (match) {\n return match[1].toUpperCase();\n });\n return transitionName[type];\n }\n\n return \"\".concat(transitionName, \"-\").concat(transitionType);\n}","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\n\n/* eslint-disable react/default-props-match-prop-types, react/no-multi-comp, react/prop-types */\nimport React from 'react';\nimport findDOMNode from \"rc-util/es/Dom/findDOMNode\";\nimport { fillRef } from \"rc-util/es/ref\";\nimport classNames from 'classnames';\nimport raf from 'raf';\nimport { getTransitionName, animationEndName, transitionEndName, supportTransition } from './util/motion';\nvar STATUS_NONE = 'none';\nvar STATUS_APPEAR = 'appear';\nvar STATUS_ENTER = 'enter';\nvar STATUS_LEAVE = 'leave';\n/**\n * `transitionSupport` is used for none transition test case.\n * Default we use browser transition event support check.\n */\n\nexport function genCSSMotion(config) {\n var transitionSupport = config;\n var forwardRef = !!React.forwardRef;\n\n if (_typeof(config) === 'object') {\n transitionSupport = config.transitionSupport;\n forwardRef = 'forwardRef' in config ? config.forwardRef : forwardRef;\n }\n\n function isSupportTransition(props) {\n return !!(props.motionName && transitionSupport);\n }\n\n var CSSMotion = /*#__PURE__*/function (_React$Component) {\n _inherits(CSSMotion, _React$Component);\n\n var _super = _createSuper(CSSMotion);\n\n function CSSMotion() {\n var _this;\n\n _classCallCheck(this, CSSMotion);\n\n _this = _super.apply(this, arguments);\n _this.$cacheEle = null;\n _this.node = null;\n _this.raf = null;\n _this.destroyed = false;\n _this.deadlineId = null;\n _this.state = {\n status: STATUS_NONE,\n statusActive: false,\n newStatus: false,\n statusStyle: null\n };\n\n _this.onDomUpdate = function () {\n var _this$state = _this.state,\n status = _this$state.status,\n newStatus = _this$state.newStatus;\n var _this$props = _this.props,\n onAppearStart = _this$props.onAppearStart,\n onEnterStart = _this$props.onEnterStart,\n onLeaveStart = _this$props.onLeaveStart,\n onAppearActive = _this$props.onAppearActive,\n onEnterActive = _this$props.onEnterActive,\n onLeaveActive = _this$props.onLeaveActive,\n motionAppear = _this$props.motionAppear,\n motionEnter = _this$props.motionEnter,\n motionLeave = _this$props.motionLeave;\n\n if (!isSupportTransition(_this.props)) {\n return;\n } // Event injection\n\n\n var $ele = _this.getElement();\n\n if (_this.$cacheEle !== $ele) {\n _this.removeEventListener(_this.$cacheEle);\n\n _this.addEventListener($ele);\n\n _this.$cacheEle = $ele;\n } // Init status\n\n\n if (newStatus && status === STATUS_APPEAR && motionAppear) {\n _this.updateStatus(onAppearStart, null, null, function () {\n _this.updateActiveStatus(onAppearActive, STATUS_APPEAR);\n });\n } else if (newStatus && status === STATUS_ENTER && motionEnter) {\n _this.updateStatus(onEnterStart, null, null, function () {\n _this.updateActiveStatus(onEnterActive, STATUS_ENTER);\n });\n } else if (newStatus && status === STATUS_LEAVE && motionLeave) {\n _this.updateStatus(onLeaveStart, null, null, function () {\n _this.updateActiveStatus(onLeaveActive, STATUS_LEAVE);\n });\n }\n };\n\n _this.onMotionEnd = function (event) {\n if (event && !event.deadline && event.target !== _this.getElement()) {\n // event exists\n // not initiated by deadline\n // transitionend not fired by inner elements\n return;\n }\n\n var _this$state2 = _this.state,\n status = _this$state2.status,\n statusActive = _this$state2.statusActive;\n var _this$props2 = _this.props,\n onAppearEnd = _this$props2.onAppearEnd,\n onEnterEnd = _this$props2.onEnterEnd,\n onLeaveEnd = _this$props2.onLeaveEnd;\n\n if (status === STATUS_APPEAR && statusActive) {\n _this.updateStatus(onAppearEnd, {\n status: STATUS_NONE\n }, event);\n } else if (status === STATUS_ENTER && statusActive) {\n _this.updateStatus(onEnterEnd, {\n status: STATUS_NONE\n }, event);\n } else if (status === STATUS_LEAVE && statusActive) {\n _this.updateStatus(onLeaveEnd, {\n status: STATUS_NONE\n }, event);\n }\n };\n\n _this.setNodeRef = function (node) {\n var internalRef = _this.props.internalRef;\n _this.node = node;\n fillRef(internalRef, node);\n };\n\n _this.getElement = function () {\n try {\n return findDOMNode(_this.node || _assertThisInitialized(_this));\n } catch (e) {\n /**\n * Fallback to cache element.\n * This is only happen when `motionDeadline` trigger but element removed.\n */\n return _this.$cacheEle;\n }\n };\n\n _this.addEventListener = function ($ele) {\n if (!$ele) return;\n $ele.addEventListener(transitionEndName, _this.onMotionEnd);\n $ele.addEventListener(animationEndName, _this.onMotionEnd);\n };\n\n _this.removeEventListener = function ($ele) {\n if (!$ele) return;\n $ele.removeEventListener(transitionEndName, _this.onMotionEnd);\n $ele.removeEventListener(animationEndName, _this.onMotionEnd);\n };\n\n _this.updateStatus = function (styleFunc, additionalState, event, callback) {\n var statusStyle = styleFunc ? styleFunc(_this.getElement(), event) : null;\n if (statusStyle === false || _this.destroyed) return;\n var nextStep;\n\n if (callback) {\n nextStep = function nextStep() {\n _this.nextFrame(callback);\n };\n }\n\n _this.setState(_objectSpread({\n statusStyle: _typeof(statusStyle) === 'object' ? statusStyle : null,\n newStatus: false\n }, additionalState), nextStep); // Trigger before next frame & after `componentDidMount`\n\n };\n\n _this.updateActiveStatus = function (styleFunc, currentStatus) {\n // `setState` use `postMessage` to trigger at the end of frame.\n // Let's use requestAnimationFrame to update new state in next frame.\n _this.nextFrame(function () {\n var status = _this.state.status;\n if (status !== currentStatus) return;\n var motionDeadline = _this.props.motionDeadline;\n\n _this.updateStatus(styleFunc, {\n statusActive: true\n });\n\n if (motionDeadline > 0) {\n _this.deadlineId = setTimeout(function () {\n _this.onMotionEnd({\n deadline: true\n });\n }, motionDeadline);\n }\n });\n };\n\n _this.nextFrame = function (func) {\n _this.cancelNextFrame();\n\n _this.raf = raf(func);\n };\n\n _this.cancelNextFrame = function () {\n if (_this.raf) {\n raf.cancel(_this.raf);\n _this.raf = null;\n }\n };\n\n return _this;\n }\n\n _createClass(CSSMotion, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.onDomUpdate();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {\n this.onDomUpdate();\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n this.destroyed = true;\n this.removeEventListener(this.$cacheEle);\n this.cancelNextFrame();\n clearTimeout(this.deadlineId);\n }\n }, {\n key: \"render\",\n value: function render() {\n var _classNames;\n\n var _this$state3 = this.state,\n status = _this$state3.status,\n statusActive = _this$state3.statusActive,\n statusStyle = _this$state3.statusStyle;\n var _this$props3 = this.props,\n children = _this$props3.children,\n motionName = _this$props3.motionName,\n visible = _this$props3.visible,\n removeOnLeave = _this$props3.removeOnLeave,\n leavedClassName = _this$props3.leavedClassName,\n eventProps = _this$props3.eventProps;\n if (!children) return null;\n\n if (status === STATUS_NONE || !isSupportTransition(this.props)) {\n if (visible) {\n return children(_objectSpread({}, eventProps), this.setNodeRef);\n }\n\n if (!removeOnLeave) {\n return children(_objectSpread(_objectSpread({}, eventProps), {}, {\n className: leavedClassName\n }), this.setNodeRef);\n }\n\n return null;\n }\n\n return children(_objectSpread(_objectSpread({}, eventProps), {}, {\n className: classNames(getTransitionName(motionName, status), (_classNames = {}, _defineProperty(_classNames, getTransitionName(motionName, \"\".concat(status, \"-active\")), statusActive), _defineProperty(_classNames, motionName, typeof motionName === 'string'), _classNames)),\n style: statusStyle\n }), this.setNodeRef);\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(props, _ref) {\n var prevProps = _ref.prevProps,\n prevStatus = _ref.status;\n if (!isSupportTransition(props)) return {};\n var visible = props.visible,\n motionAppear = props.motionAppear,\n motionEnter = props.motionEnter,\n motionLeave = props.motionLeave,\n motionLeaveImmediately = props.motionLeaveImmediately;\n var newState = {\n prevProps: props\n }; // Clean up status if prop set to false\n\n if (prevStatus === STATUS_APPEAR && !motionAppear || prevStatus === STATUS_ENTER && !motionEnter || prevStatus === STATUS_LEAVE && !motionLeave) {\n newState.status = STATUS_NONE;\n newState.statusActive = false;\n newState.newStatus = false;\n } // Appear\n\n\n if (!prevProps && visible && motionAppear) {\n newState.status = STATUS_APPEAR;\n newState.statusActive = false;\n newState.newStatus = true;\n } // Enter\n\n\n if (prevProps && !prevProps.visible && visible && motionEnter) {\n newState.status = STATUS_ENTER;\n newState.statusActive = false;\n newState.newStatus = true;\n } // Leave\n\n\n if (prevProps && prevProps.visible && !visible && motionLeave || !prevProps && motionLeaveImmediately && !visible && motionLeave) {\n newState.status = STATUS_LEAVE;\n newState.statusActive = false;\n newState.newStatus = true;\n }\n\n return newState;\n }\n }]);\n\n return CSSMotion;\n }(React.Component);\n\n CSSMotion.defaultProps = {\n visible: true,\n motionEnter: true,\n motionAppear: true,\n motionLeave: true,\n removeOnLeave: true\n };\n\n if (!forwardRef) {\n return CSSMotion;\n }\n\n return React.forwardRef(function (props, ref) {\n return React.createElement(CSSMotion, Object.assign({\n internalRef: ref\n }, props));\n });\n}\nexport default genCSSMotion(supportTransition);","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nexport var STATUS_ADD = 'add';\nexport var STATUS_KEEP = 'keep';\nexport var STATUS_REMOVE = 'remove';\nexport var STATUS_REMOVED = 'removed';\nexport function wrapKeyToObject(key) {\n var keyObj;\n\n if (key && _typeof(key) === 'object' && 'key' in key) {\n keyObj = key;\n } else {\n keyObj = {\n key: key\n };\n }\n\n return _objectSpread(_objectSpread({}, keyObj), {}, {\n key: String(keyObj.key)\n });\n}\nexport function parseKeys() {\n var keys = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n return keys.map(wrapKeyToObject);\n}\nexport function diffKeys() {\n var prevKeys = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n var currentKeys = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];\n var list = [];\n var currentIndex = 0;\n var currentLen = currentKeys.length;\n var prevKeyObjects = parseKeys(prevKeys);\n var currentKeyObjects = parseKeys(currentKeys); // Check prev keys to insert or keep\n\n prevKeyObjects.forEach(function (keyObj) {\n var hit = false;\n\n for (var i = currentIndex; i < currentLen; i += 1) {\n var currentKeyObj = currentKeyObjects[i];\n\n if (currentKeyObj.key === keyObj.key) {\n // New added keys should add before current key\n if (currentIndex < i) {\n list = list.concat(currentKeyObjects.slice(currentIndex, i).map(function (obj) {\n return _objectSpread(_objectSpread({}, obj), {}, {\n status: STATUS_ADD\n });\n }));\n currentIndex = i;\n }\n\n list.push(_objectSpread(_objectSpread({}, currentKeyObj), {}, {\n status: STATUS_KEEP\n }));\n currentIndex += 1;\n hit = true;\n break;\n }\n } // If not hit, it means key is removed\n\n\n if (!hit) {\n list.push(_objectSpread(_objectSpread({}, keyObj), {}, {\n status: STATUS_REMOVE\n }));\n }\n }); // Add rest to the list\n\n if (currentIndex < currentLen) {\n list = list.concat(currentKeyObjects.slice(currentIndex).map(function (obj) {\n return _objectSpread(_objectSpread({}, obj), {}, {\n status: STATUS_ADD\n });\n }));\n }\n /**\n * Merge same key when it remove and add again:\n * [1 - add, 2 - keep, 1 - remove] -> [1 - keep, 2 - keep]\n */\n\n\n var keys = {};\n list.forEach(function (_ref) {\n var key = _ref.key;\n keys[key] = (keys[key] || 0) + 1;\n });\n var duplicatedKeys = Object.keys(keys).filter(function (key) {\n return keys[key] > 1;\n });\n duplicatedKeys.forEach(function (matchKey) {\n // Remove `STATUS_REMOVE` node.\n list = list.filter(function (_ref2) {\n var key = _ref2.key,\n status = _ref2.status;\n return key !== matchKey || status !== STATUS_REMOVE;\n }); // Update `STATUS_ADD` to `STATUS_KEEP`\n\n list.forEach(function (node) {\n if (node.key === matchKey) {\n // eslint-disable-next-line no-param-reassign\n node.status = STATUS_KEEP;\n }\n });\n });\n return list;\n}","import _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\n\n/* eslint react/prop-types: 0 */\nimport React from 'react';\nimport OriginCSSMotion from './CSSMotion';\nimport { supportTransition } from './util/motion';\nimport { STATUS_ADD, STATUS_KEEP, STATUS_REMOVE, STATUS_REMOVED, diffKeys, parseKeys } from './util/diff';\nvar MOTION_PROP_NAMES = ['eventProps', 'visible', 'children', 'motionName', 'motionAppear', 'motionEnter', 'motionLeave', 'motionLeaveImmediately', 'motionDeadline', 'removeOnLeave', 'leavedClassName', 'onAppearStart', 'onAppearActive', 'onAppearEnd', 'onEnterStart', 'onEnterActive', 'onEnterEnd', 'onLeaveStart', 'onLeaveActive', 'onLeaveEnd'];\nexport function genCSSMotionList(transitionSupport) {\n var CSSMotion = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : OriginCSSMotion;\n\n var CSSMotionList = /*#__PURE__*/function (_React$Component) {\n _inherits(CSSMotionList, _React$Component);\n\n var _super = _createSuper(CSSMotionList);\n\n function CSSMotionList() {\n var _this;\n\n _classCallCheck(this, CSSMotionList);\n\n _this = _super.apply(this, arguments);\n _this.state = {\n keyEntities: []\n };\n\n _this.removeKey = function (removeKey) {\n _this.setState(function (_ref) {\n var keyEntities = _ref.keyEntities;\n return {\n keyEntities: keyEntities.map(function (entity) {\n if (entity.key !== removeKey) return entity;\n return _objectSpread(_objectSpread({}, entity), {}, {\n status: STATUS_REMOVED\n });\n })\n };\n });\n };\n\n return _this;\n }\n\n _createClass(CSSMotionList, [{\n key: \"render\",\n value: function render() {\n var _this2 = this;\n\n var keyEntities = this.state.keyEntities;\n\n var _this$props = this.props,\n component = _this$props.component,\n children = _this$props.children,\n restProps = _objectWithoutProperties(_this$props, [\"component\", \"children\"]);\n\n var Component = component || React.Fragment;\n var motionProps = {};\n MOTION_PROP_NAMES.forEach(function (prop) {\n motionProps[prop] = restProps[prop];\n delete restProps[prop];\n });\n delete restProps.keys;\n return React.createElement(Component, Object.assign({}, restProps), keyEntities.map(function (_ref2) {\n var status = _ref2.status,\n eventProps = _objectWithoutProperties(_ref2, [\"status\"]);\n\n var visible = status === STATUS_ADD || status === STATUS_KEEP;\n return React.createElement(CSSMotion, Object.assign({}, motionProps, {\n key: eventProps.key,\n visible: visible,\n eventProps: eventProps,\n onLeaveEnd: function onLeaveEnd() {\n if (motionProps.onLeaveEnd) {\n motionProps.onLeaveEnd.apply(motionProps, arguments);\n }\n\n _this2.removeKey(eventProps.key);\n }\n }), children);\n }));\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(_ref3, _ref4) {\n var keys = _ref3.keys;\n var keyEntities = _ref4.keyEntities;\n var parsedKeyObjects = parseKeys(keys); // Always as keep when motion not support\n\n if (!transitionSupport) {\n return {\n keyEntities: parsedKeyObjects.map(function (obj) {\n return _objectSpread(_objectSpread({}, obj), {}, {\n status: STATUS_KEEP\n });\n })\n };\n }\n\n var mixedKeyEntities = diffKeys(keyEntities, parsedKeyObjects);\n var keyEntitiesLen = keyEntities.length;\n return {\n keyEntities: mixedKeyEntities.filter(function (entity) {\n // IE 9 not support Array.prototype.find\n var prevEntity = null;\n\n for (var i = 0; i < keyEntitiesLen; i += 1) {\n var currentEntity = keyEntities[i];\n\n if (currentEntity.key === entity.key) {\n prevEntity = currentEntity;\n break;\n }\n } // Remove if already mark as removed\n\n\n if (prevEntity && prevEntity.status === STATUS_REMOVED && entity.status === STATUS_REMOVE) {\n return false;\n }\n\n return true;\n })\n };\n }\n }]);\n\n return CSSMotionList;\n }(React.Component);\n\n CSSMotionList.defaultProps = {\n component: 'div'\n };\n return CSSMotionList;\n}\nexport default genCSSMotionList(supportTransition);","import CSSMotion from './CSSMotion';\nimport CSSMotionList from './CSSMotionList';\nexport { CSSMotionList };\nexport default CSSMotion;","import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nexport function toArray(value) {\n if (Array.isArray(value)) {\n return value;\n }\n\n return value !== undefined ? [value] : [];\n}\n/**\n * Convert outer props value into internal value\n */\n\nexport function toInnerValue(value, _ref) {\n var labelInValue = _ref.labelInValue,\n combobox = _ref.combobox;\n\n if (value === undefined || value === '' && combobox) {\n return [];\n }\n\n var values = Array.isArray(value) ? value : [value];\n\n if (labelInValue) {\n return values.map(function (_ref2) {\n var key = _ref2.key,\n val = _ref2.value;\n return val !== undefined ? val : key;\n });\n }\n\n return values;\n}\n/**\n * Convert internal value into out event value\n */\n\nexport function toOuterValues(valueList, _ref3) {\n var optionLabelProp = _ref3.optionLabelProp,\n labelInValue = _ref3.labelInValue,\n prevValue = _ref3.prevValue,\n options = _ref3.options,\n getLabeledValue = _ref3.getLabeledValue;\n var values = valueList;\n\n if (labelInValue) {\n values = values.map(function (val) {\n return getLabeledValue(val, {\n options: options,\n prevValue: prevValue,\n labelInValue: labelInValue,\n optionLabelProp: optionLabelProp\n });\n });\n }\n\n return values;\n}\nexport function removeLastEnabledValue(measureValues, values) {\n var newValues = _toConsumableArray(values);\n\n var removeIndex;\n\n for (removeIndex = measureValues.length - 1; removeIndex >= 0; removeIndex -= 1) {\n if (!measureValues[removeIndex].disabled) {\n break;\n }\n }\n\n var removedValue = null;\n\n if (removeIndex !== -1) {\n removedValue = newValues[removeIndex];\n newValues.splice(removeIndex, 1);\n }\n\n return {\n values: newValues,\n removedValue: removedValue\n };\n}\nexport var isClient = typeof window !== 'undefined' && window.document && window.document.documentElement;\n/** Is client side and not jsdom */\n\nexport var isBrowserClient = process.env.NODE_ENV !== 'test' && isClient;\nvar uuid = 0;\n/** Get unique id for accessibility usage */\n\nexport function getUUID() {\n var retId; // Test never reach\n\n /* istanbul ignore if */\n\n if (isBrowserClient) {\n retId = uuid;\n uuid += 1;\n } else {\n retId = 'TEST_OR_SSR';\n }\n\n return retId;\n}","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport { Item } from 'rc-menu';\nimport toArray from \"rc-util/es/Children/toArray\";\nimport classNames from 'classnames';\nimport MenuContext from './MenuContext';\nimport Tooltip from '../tooltip';\nimport { SiderContext } from '../layout/Sider';\nimport { isValidElement } from '../_util/reactNode';\n\nvar MenuItem = /*#__PURE__*/function (_React$Component) {\n _inherits(MenuItem, _React$Component);\n\n var _super = _createSuper(MenuItem);\n\n function MenuItem() {\n var _this;\n\n _classCallCheck(this, MenuItem);\n\n _this = _super.apply(this, arguments);\n\n _this.renderItem = function (_ref) {\n var siderCollapsed = _ref.siderCollapsed;\n var _this$props = _this.props,\n level = _this$props.level,\n className = _this$props.className,\n children = _this$props.children,\n rootPrefixCls = _this$props.rootPrefixCls;\n\n var _a = _this.props,\n title = _a.title,\n icon = _a.icon,\n danger = _a.danger,\n rest = __rest(_a, [\"title\", \"icon\", \"danger\"]);\n\n return /*#__PURE__*/React.createElement(MenuContext.Consumer, null, function (_ref2) {\n var _classNames;\n\n var inlineCollapsed = _ref2.inlineCollapsed,\n direction = _ref2.direction;\n var tooltipTitle = title;\n\n if (typeof title === 'undefined') {\n tooltipTitle = level === 1 ? children : '';\n } else if (title === false) {\n tooltipTitle = '';\n }\n\n var tooltipProps = {\n title: tooltipTitle\n };\n\n if (!siderCollapsed && !inlineCollapsed) {\n tooltipProps.title = null; // Reset `visible` to fix control mode tooltip display not correct\n // ref: https://github.com/ant-design/ant-design/issues/16742\n\n tooltipProps.visible = false;\n }\n\n var childrenLength = toArray(children).length;\n return /*#__PURE__*/React.createElement(Tooltip, _extends({}, tooltipProps, {\n placement: direction === 'rtl' ? 'left' : 'right',\n overlayClassName: \"\".concat(rootPrefixCls, \"-inline-collapsed-tooltip\")\n }), /*#__PURE__*/React.createElement(Item, _extends({}, rest, {\n className: classNames(className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(rootPrefixCls, \"-item-danger\"), danger), _defineProperty(_classNames, \"\".concat(rootPrefixCls, \"-item-only-child\"), (icon ? childrenLength + 1 : childrenLength) === 1), _classNames)),\n title: title\n }), icon, _this.renderItemChildren(inlineCollapsed)));\n });\n };\n\n return _this;\n }\n\n _createClass(MenuItem, [{\n key: \"renderItemChildren\",\n value: function renderItemChildren(inlineCollapsed) {\n var _this$props2 = this.props,\n icon = _this$props2.icon,\n children = _this$props2.children,\n level = _this$props2.level,\n rootPrefixCls = _this$props2.rootPrefixCls; // inline-collapsed.md demo 依赖 span 来隐藏文字,有 icon 属性,则内部包裹一个 span\n // ref: https://github.com/ant-design/ant-design/pull/23456\n\n if (!icon || isValidElement(children) && children.type === 'span') {\n if (children && inlineCollapsed && level === 1 && typeof children === 'string') {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(rootPrefixCls, \"-inline-collapsed-noicon\")\n }, children.charAt(0));\n }\n\n return children;\n }\n\n return /*#__PURE__*/React.createElement(\"span\", null, children);\n }\n }, {\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(SiderContext.Consumer, null, this.renderItem);\n }\n }]);\n\n return MenuItem;\n}(React.Component);\n\nexport { MenuItem as default };\nMenuItem.isMenuItem = true;","// ================== Collapse Motion ==================\nvar getCollapsedHeight = function getCollapsedHeight() {\n return {\n height: 0,\n opacity: 0\n };\n};\n\nvar getRealHeight = function getRealHeight(node) {\n return {\n height: node.scrollHeight,\n opacity: 1\n };\n};\n\nvar getCurrentHeight = function getCurrentHeight(node) {\n return {\n height: node.offsetHeight\n };\n};\n\nvar skipOpacityTransition = function skipOpacityTransition(_, event) {\n return event.propertyName === 'height';\n};\n\nvar collapseMotion = {\n motionName: 'ant-motion-collapse',\n onAppearStart: getCollapsedHeight,\n onEnterStart: getCollapsedHeight,\n onAppearActive: getRealHeight,\n onEnterActive: getRealHeight,\n onLeaveStart: getCurrentHeight,\n onLeaveActive: getCollapsedHeight,\n onAppearEnd: skipOpacityTransition,\n onEnterEnd: skipOpacityTransition,\n onLeaveEnd: skipOpacityTransition,\n motionDeadline: 500\n};\nexport default collapseMotion;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\nimport * as React from 'react';\nimport RcMenu, { Divider, ItemGroup } from 'rc-menu';\nimport classNames from 'classnames';\nimport SubMenu from './SubMenu';\nimport Item from './MenuItem';\nimport { ConfigConsumer } from '../config-provider';\nimport devWarning from '../_util/devWarning';\nimport { SiderContext } from '../layout/Sider';\nimport collapseMotion from '../_util/motion';\nimport MenuContext from './MenuContext';\n\nvar InternalMenu = /*#__PURE__*/function (_React$Component) {\n _inherits(InternalMenu, _React$Component);\n\n var _super = _createSuper(InternalMenu);\n\n function InternalMenu(props) {\n var _this;\n\n _classCallCheck(this, InternalMenu);\n\n _this = _super.call(this, props);\n\n _this.renderMenu = function (_ref) {\n var getPopupContainer = _ref.getPopupContainer,\n getPrefixCls = _ref.getPrefixCls,\n direction = _ref.direction;\n var _this$props = _this.props,\n customizePrefixCls = _this$props.prefixCls,\n className = _this$props.className,\n theme = _this$props.theme;\n var defaultMotions = {\n horizontal: {\n motionName: 'slide-up'\n },\n inline: collapseMotion,\n other: {\n motionName: 'zoom-big'\n }\n };\n var prefixCls = getPrefixCls('menu', customizePrefixCls);\n var menuClassName = classNames(className, \"\".concat(prefixCls, \"-\").concat(theme), _defineProperty({}, \"\".concat(prefixCls, \"-inline-collapsed\"), _this.getInlineCollapsed()));\n return /*#__PURE__*/React.createElement(MenuContext.Provider, {\n value: {\n inlineCollapsed: _this.getInlineCollapsed() || false,\n antdMenuTheme: theme,\n direction: direction\n }\n }, /*#__PURE__*/React.createElement(RcMenu, _extends({\n getPopupContainer: getPopupContainer\n }, _this.props, {\n className: menuClassName,\n prefixCls: prefixCls,\n direction: direction,\n defaultMotions: defaultMotions\n })));\n };\n\n devWarning(!('inlineCollapsed' in props && props.mode !== 'inline'), 'Menu', '`inlineCollapsed` should only be used when `mode` is inline.');\n devWarning(!(props.siderCollapsed !== undefined && 'inlineCollapsed' in props), 'Menu', '`inlineCollapsed` not control Menu under Sider. Should set `collapsed` on Sider instead.');\n return _this;\n }\n\n _createClass(InternalMenu, [{\n key: \"getInlineCollapsed\",\n value: function getInlineCollapsed() {\n var _this$props2 = this.props,\n inlineCollapsed = _this$props2.inlineCollapsed,\n siderCollapsed = _this$props2.siderCollapsed;\n\n if (siderCollapsed !== undefined) {\n return siderCollapsed;\n }\n\n return inlineCollapsed;\n }\n }, {\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderMenu);\n }\n }]);\n\n return InternalMenu;\n}(React.Component);\n\nInternalMenu.defaultProps = {\n className: '',\n theme: 'light',\n focusable: false\n}; // We should keep this as ref-able\n\nvar Menu = /*#__PURE__*/function (_React$Component2) {\n _inherits(Menu, _React$Component2);\n\n var _super2 = _createSuper(Menu);\n\n function Menu() {\n _classCallCheck(this, Menu);\n\n return _super2.apply(this, arguments);\n }\n\n _createClass(Menu, [{\n key: \"render\",\n value: function render() {\n var _this2 = this;\n\n return /*#__PURE__*/React.createElement(SiderContext.Consumer, null, function (context) {\n return /*#__PURE__*/React.createElement(InternalMenu, _extends({}, _this2.props, context));\n });\n }\n }]);\n\n return Menu;\n}(React.Component);\n\nexport { Menu as default };\nMenu.Divider = Divider;\nMenu.Item = Item;\nMenu.SubMenu = SubMenu;\nMenu.ItemGroup = ItemGroup;","export default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n subClass.__proto__ = superClass;\n}","var isProduction = process.env.NODE_ENV === 'production';\nvar prefix = 'Invariant failed';\nfunction invariant(condition, message) {\n if (condition) {\n return;\n }\n if (isProduction) {\n throw new Error(prefix);\n }\n throw new Error(prefix + \": \" + (message || ''));\n}\n\nexport default invariant;\n","import warning from \"rc-util/es/warning\";\n\nfunction removeFromCheckedKeys(halfCheckedKeys, checkedKeys) {\n var filteredKeys = new Set();\n halfCheckedKeys.forEach(function (key) {\n if (!checkedKeys.has(key)) {\n filteredKeys.add(key);\n }\n });\n return filteredKeys;\n}\n\nexport function isCheckDisabled(node) {\n var _ref = node || {},\n disabled = _ref.disabled,\n disableCheckbox = _ref.disableCheckbox,\n checkable = _ref.checkable;\n\n return !!(disabled || disableCheckbox) || checkable === false;\n} // Fill miss keys\n\nfunction fillConductCheck(keys, levelEntities, maxLevel, syntheticGetCheckDisabled) {\n var checkedKeys = new Set(keys);\n var halfCheckedKeys = new Set(); // Add checked keys top to bottom\n\n for (var level = 0; level <= maxLevel; level += 1) {\n var entities = levelEntities.get(level) || new Set();\n entities.forEach(function (entity) {\n var key = entity.key,\n node = entity.node,\n _entity$children = entity.children,\n children = _entity$children === void 0 ? [] : _entity$children;\n\n if (checkedKeys.has(key) && !syntheticGetCheckDisabled(node)) {\n children.filter(function (childEntity) {\n return !syntheticGetCheckDisabled(childEntity.node);\n }).forEach(function (childEntity) {\n checkedKeys.add(childEntity.key);\n });\n }\n });\n } // Add checked keys from bottom to top\n\n\n var visitedKeys = new Set();\n\n for (var _level = maxLevel; _level >= 0; _level -= 1) {\n var _entities = levelEntities.get(_level) || new Set();\n\n _entities.forEach(function (entity) {\n var parent = entity.parent,\n node = entity.node; // Skip if no need to check\n\n if (syntheticGetCheckDisabled(node) || !entity.parent || visitedKeys.has(entity.parent.key)) {\n return;\n } // Skip if parent is disabled\n\n\n if (syntheticGetCheckDisabled(entity.parent.node)) {\n visitedKeys.add(parent.key);\n return;\n }\n\n var allChecked = true;\n var partialChecked = false;\n (parent.children || []).filter(function (childEntity) {\n return !syntheticGetCheckDisabled(childEntity.node);\n }).forEach(function (_ref2) {\n var key = _ref2.key;\n var checked = checkedKeys.has(key);\n\n if (allChecked && !checked) {\n allChecked = false;\n }\n\n if (!partialChecked && (checked || halfCheckedKeys.has(key))) {\n partialChecked = true;\n }\n });\n\n if (allChecked) {\n checkedKeys.add(parent.key);\n }\n\n if (partialChecked) {\n halfCheckedKeys.add(parent.key);\n }\n\n visitedKeys.add(parent.key);\n });\n }\n\n return {\n checkedKeys: Array.from(checkedKeys),\n halfCheckedKeys: Array.from(removeFromCheckedKeys(halfCheckedKeys, checkedKeys))\n };\n} // Remove useless key\n\n\nfunction cleanConductCheck(keys, halfKeys, levelEntities, maxLevel, syntheticGetCheckDisabled) {\n var checkedKeys = new Set(keys);\n var halfCheckedKeys = new Set(halfKeys); // Remove checked keys from top to bottom\n\n for (var level = 0; level <= maxLevel; level += 1) {\n var entities = levelEntities.get(level) || new Set();\n entities.forEach(function (entity) {\n var key = entity.key,\n node = entity.node,\n _entity$children2 = entity.children,\n children = _entity$children2 === void 0 ? [] : _entity$children2;\n\n if (!checkedKeys.has(key) && !halfCheckedKeys.has(key) && !syntheticGetCheckDisabled(node)) {\n children.filter(function (childEntity) {\n return !syntheticGetCheckDisabled(childEntity.node);\n }).forEach(function (childEntity) {\n checkedKeys.delete(childEntity.key);\n });\n }\n });\n } // Remove checked keys form bottom to top\n\n\n halfCheckedKeys = new Set();\n var visitedKeys = new Set();\n\n for (var _level2 = maxLevel; _level2 >= 0; _level2 -= 1) {\n var _entities2 = levelEntities.get(_level2) || new Set();\n\n _entities2.forEach(function (entity) {\n var parent = entity.parent,\n node = entity.node; // Skip if no need to check\n\n if (syntheticGetCheckDisabled(node) || !entity.parent || visitedKeys.has(entity.parent.key)) {\n return;\n } // Skip if parent is disabled\n\n\n if (syntheticGetCheckDisabled(entity.parent.node)) {\n visitedKeys.add(parent.key);\n return;\n }\n\n var allChecked = true;\n var partialChecked = false;\n (parent.children || []).filter(function (childEntity) {\n return !syntheticGetCheckDisabled(childEntity.node);\n }).forEach(function (_ref3) {\n var key = _ref3.key;\n var checked = checkedKeys.has(key);\n\n if (allChecked && !checked) {\n allChecked = false;\n }\n\n if (!partialChecked && (checked || halfCheckedKeys.has(key))) {\n partialChecked = true;\n }\n });\n\n if (!allChecked) {\n checkedKeys.delete(parent.key);\n }\n\n if (partialChecked) {\n halfCheckedKeys.add(parent.key);\n }\n\n visitedKeys.add(parent.key);\n });\n }\n\n return {\n checkedKeys: Array.from(checkedKeys),\n halfCheckedKeys: Array.from(removeFromCheckedKeys(halfCheckedKeys, checkedKeys))\n };\n}\n/**\n * Conduct with keys.\n * @param keyList current key list\n * @param keyEntities key - dataEntity map\n * @param mode `fill` to fill missing key, `clean` to remove useless key\n */\n\n\nexport function conductCheck(keyList, checked, keyEntities, getCheckDisabled) {\n var warningMissKeys = [];\n var syntheticGetCheckDisabled;\n\n if (getCheckDisabled) {\n syntheticGetCheckDisabled = getCheckDisabled;\n } else {\n syntheticGetCheckDisabled = isCheckDisabled;\n } // We only handle exist keys\n\n\n var keys = new Set(keyList.filter(function (key) {\n var hasEntity = !!keyEntities[key];\n\n if (!hasEntity) {\n warningMissKeys.push(key);\n }\n\n return hasEntity;\n }));\n var levelEntities = new Map();\n var maxLevel = 0; // Convert entities by level for calculation\n\n Object.keys(keyEntities).forEach(function (key) {\n var entity = keyEntities[key];\n var level = entity.level;\n var levelSet = levelEntities.get(level);\n\n if (!levelSet) {\n levelSet = new Set();\n levelEntities.set(level, levelSet);\n }\n\n levelSet.add(entity);\n maxLevel = Math.max(maxLevel, level);\n });\n warning(!warningMissKeys.length, \"Tree missing follow keys: \".concat(warningMissKeys.slice(0, 100).map(function (key) {\n return \"'\".concat(key, \"'\");\n }).join(', ')));\n var result;\n\n if (checked === true) {\n result = fillConductCheck(keys, levelEntities, maxLevel, syntheticGetCheckDisabled);\n } else {\n result = cleanConductCheck(keys, checked.halfCheckedKeys, levelEntities, maxLevel, syntheticGetCheckDisabled);\n }\n\n return result;\n}","function isAbsolute(pathname) {\n return pathname.charAt(0) === '/';\n}\n\n// About 1.5x faster than the two-arg version of Array#splice()\nfunction spliceOne(list, index) {\n for (var i = index, k = i + 1, n = list.length; k < n; i += 1, k += 1) {\n list[i] = list[k];\n }\n\n list.pop();\n}\n\n// This implementation is based heavily on node's url.parse\nfunction resolvePathname(to, from) {\n if (from === undefined) from = '';\n\n var toParts = (to && to.split('/')) || [];\n var fromParts = (from && from.split('/')) || [];\n\n var isToAbs = to && isAbsolute(to);\n var isFromAbs = from && isAbsolute(from);\n var mustEndAbs = isToAbs || isFromAbs;\n\n if (to && isAbsolute(to)) {\n // to is absolute\n fromParts = toParts;\n } else if (toParts.length) {\n // to is relative, drop the filename\n fromParts.pop();\n fromParts = fromParts.concat(toParts);\n }\n\n if (!fromParts.length) return '/';\n\n var hasTrailingSlash;\n if (fromParts.length) {\n var last = fromParts[fromParts.length - 1];\n hasTrailingSlash = last === '.' || last === '..' || last === '';\n } else {\n hasTrailingSlash = false;\n }\n\n var up = 0;\n for (var i = fromParts.length; i >= 0; i--) {\n var part = fromParts[i];\n\n if (part === '.') {\n spliceOne(fromParts, i);\n } else if (part === '..') {\n spliceOne(fromParts, i);\n up++;\n } else if (up) {\n spliceOne(fromParts, i);\n up--;\n }\n }\n\n if (!mustEndAbs) for (; up--; up) fromParts.unshift('..');\n\n if (\n mustEndAbs &&\n fromParts[0] !== '' &&\n (!fromParts[0] || !isAbsolute(fromParts[0]))\n )\n fromParts.unshift('');\n\n var result = fromParts.join('/');\n\n if (hasTrailingSlash && result.substr(-1) !== '/') result += '/';\n\n return result;\n}\n\nexport default resolvePathname;\n","function valueOf(obj) {\n return obj.valueOf ? obj.valueOf() : Object.prototype.valueOf.call(obj);\n}\n\nfunction valueEqual(a, b) {\n // Test for strict equality first.\n if (a === b) return true;\n\n // Otherwise, if either of them == null they are not equal.\n if (a == null || b == null) return false;\n\n if (Array.isArray(a)) {\n return (\n Array.isArray(b) &&\n a.length === b.length &&\n a.every(function(item, index) {\n return valueEqual(item, b[index]);\n })\n );\n }\n\n if (typeof a === 'object' || typeof b === 'object') {\n var aValue = valueOf(a);\n var bValue = valueOf(b);\n\n if (aValue !== a || bValue !== b) return valueEqual(aValue, bValue);\n\n return Object.keys(Object.assign({}, a, b)).every(function(key) {\n return valueEqual(a[key], b[key]);\n });\n }\n\n return false;\n}\n\nexport default valueEqual;\n","import _extends from '@babel/runtime/helpers/esm/extends';\nimport resolvePathname from 'resolve-pathname';\nimport valueEqual from 'value-equal';\nimport warning from 'tiny-warning';\nimport invariant from 'tiny-invariant';\n\nfunction addLeadingSlash(path) {\n return path.charAt(0) === '/' ? path : '/' + path;\n}\nfunction stripLeadingSlash(path) {\n return path.charAt(0) === '/' ? path.substr(1) : path;\n}\nfunction hasBasename(path, prefix) {\n return path.toLowerCase().indexOf(prefix.toLowerCase()) === 0 && '/?#'.indexOf(path.charAt(prefix.length)) !== -1;\n}\nfunction stripBasename(path, prefix) {\n return hasBasename(path, prefix) ? path.substr(prefix.length) : path;\n}\nfunction stripTrailingSlash(path) {\n return path.charAt(path.length - 1) === '/' ? path.slice(0, -1) : path;\n}\nfunction parsePath(path) {\n var pathname = path || '/';\n var search = '';\n var hash = '';\n var hashIndex = pathname.indexOf('#');\n\n if (hashIndex !== -1) {\n hash = pathname.substr(hashIndex);\n pathname = pathname.substr(0, hashIndex);\n }\n\n var searchIndex = pathname.indexOf('?');\n\n if (searchIndex !== -1) {\n search = pathname.substr(searchIndex);\n pathname = pathname.substr(0, searchIndex);\n }\n\n return {\n pathname: pathname,\n search: search === '?' ? '' : search,\n hash: hash === '#' ? '' : hash\n };\n}\nfunction createPath(location) {\n var pathname = location.pathname,\n search = location.search,\n hash = location.hash;\n var path = pathname || '/';\n if (search && search !== '?') path += search.charAt(0) === '?' ? search : \"?\" + search;\n if (hash && hash !== '#') path += hash.charAt(0) === '#' ? hash : \"#\" + hash;\n return path;\n}\n\nfunction createLocation(path, state, key, currentLocation) {\n var location;\n\n if (typeof path === 'string') {\n // Two-arg form: push(path, state)\n location = parsePath(path);\n location.state = state;\n } else {\n // One-arg form: push(location)\n location = _extends({}, path);\n if (location.pathname === undefined) location.pathname = '';\n\n if (location.search) {\n if (location.search.charAt(0) !== '?') location.search = '?' + location.search;\n } else {\n location.search = '';\n }\n\n if (location.hash) {\n if (location.hash.charAt(0) !== '#') location.hash = '#' + location.hash;\n } else {\n location.hash = '';\n }\n\n if (state !== undefined && location.state === undefined) location.state = state;\n }\n\n try {\n location.pathname = decodeURI(location.pathname);\n } catch (e) {\n if (e instanceof URIError) {\n throw new URIError('Pathname \"' + location.pathname + '\" could not be decoded. ' + 'This is likely caused by an invalid percent-encoding.');\n } else {\n throw e;\n }\n }\n\n if (key) location.key = key;\n\n if (currentLocation) {\n // Resolve incomplete/relative pathname relative to current location.\n if (!location.pathname) {\n location.pathname = currentLocation.pathname;\n } else if (location.pathname.charAt(0) !== '/') {\n location.pathname = resolvePathname(location.pathname, currentLocation.pathname);\n }\n } else {\n // When there is no prior location and pathname is empty, set it to /\n if (!location.pathname) {\n location.pathname = '/';\n }\n }\n\n return location;\n}\nfunction locationsAreEqual(a, b) {\n return a.pathname === b.pathname && a.search === b.search && a.hash === b.hash && a.key === b.key && valueEqual(a.state, b.state);\n}\n\nfunction createTransitionManager() {\n var prompt = null;\n\n function setPrompt(nextPrompt) {\n process.env.NODE_ENV !== \"production\" ? warning(prompt == null, 'A history supports only one prompt at a time') : void 0;\n prompt = nextPrompt;\n return function () {\n if (prompt === nextPrompt) prompt = null;\n };\n }\n\n function confirmTransitionTo(location, action, getUserConfirmation, callback) {\n // TODO: If another transition starts while we're still confirming\n // the previous one, we may end up in a weird state. Figure out the\n // best way to handle this.\n if (prompt != null) {\n var result = typeof prompt === 'function' ? prompt(location, action) : prompt;\n\n if (typeof result === 'string') {\n if (typeof getUserConfirmation === 'function') {\n getUserConfirmation(result, callback);\n } else {\n process.env.NODE_ENV !== \"production\" ? warning(false, 'A history needs a getUserConfirmation function in order to use a prompt message') : void 0;\n callback(true);\n }\n } else {\n // Return false from a transition hook to cancel the transition.\n callback(result !== false);\n }\n } else {\n callback(true);\n }\n }\n\n var listeners = [];\n\n function appendListener(fn) {\n var isActive = true;\n\n function listener() {\n if (isActive) fn.apply(void 0, arguments);\n }\n\n listeners.push(listener);\n return function () {\n isActive = false;\n listeners = listeners.filter(function (item) {\n return item !== listener;\n });\n };\n }\n\n function notifyListeners() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n listeners.forEach(function (listener) {\n return listener.apply(void 0, args);\n });\n }\n\n return {\n setPrompt: setPrompt,\n confirmTransitionTo: confirmTransitionTo,\n appendListener: appendListener,\n notifyListeners: notifyListeners\n };\n}\n\nvar canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement);\nfunction getConfirmation(message, callback) {\n callback(window.confirm(message)); // eslint-disable-line no-alert\n}\n/**\n * Returns true if the HTML5 history API is supported. Taken from Modernizr.\n *\n * https://github.com/Modernizr/Modernizr/blob/master/LICENSE\n * https://github.com/Modernizr/Modernizr/blob/master/feature-detects/history.js\n * changed to avoid false negatives for Windows Phones: https://github.com/reactjs/react-router/issues/586\n */\n\nfunction supportsHistory() {\n var ua = window.navigator.userAgent;\n if ((ua.indexOf('Android 2.') !== -1 || ua.indexOf('Android 4.0') !== -1) && ua.indexOf('Mobile Safari') !== -1 && ua.indexOf('Chrome') === -1 && ua.indexOf('Windows Phone') === -1) return false;\n return window.history && 'pushState' in window.history;\n}\n/**\n * Returns true if browser fires popstate on hash change.\n * IE10 and IE11 do not.\n */\n\nfunction supportsPopStateOnHashChange() {\n return window.navigator.userAgent.indexOf('Trident') === -1;\n}\n/**\n * Returns false if using go(n) with hash history causes a full page reload.\n */\n\nfunction supportsGoWithoutReloadUsingHash() {\n return window.navigator.userAgent.indexOf('Firefox') === -1;\n}\n/**\n * Returns true if a given popstate event is an extraneous WebKit event.\n * usernames for the fact that Chrome on iOS fires real popstate events\n * containing undefined state when pressing the back button.\n */\n\nfunction isExtraneousPopstateEvent(event) {\n return event.state === undefined && navigator.userAgent.indexOf('CriOS') === -1;\n}\n\nvar PopStateEvent = 'popstate';\nvar HashChangeEvent = 'hashchange';\n\nfunction getHistoryState() {\n try {\n return window.history.state || {};\n } catch (e) {\n // IE 11 sometimes throws when accessing window.history.state\n // See https://github.com/ReactTraining/history/pull/289\n return {};\n }\n}\n/**\n * Creates a history object that uses the HTML5 history API including\n * pushState, replaceState, and the popstate event.\n */\n\n\nfunction createBrowserHistory(props) {\n if (props === void 0) {\n props = {};\n }\n\n !canUseDOM ? process.env.NODE_ENV !== \"production\" ? invariant(false, 'Browser history needs a DOM') : invariant(false) : void 0;\n var globalHistory = window.history;\n var canUseHistory = supportsHistory();\n var needsHashChangeListener = !supportsPopStateOnHashChange();\n var _props = props,\n _props$forceRefresh = _props.forceRefresh,\n forceRefresh = _props$forceRefresh === void 0 ? false : _props$forceRefresh,\n _props$getUserConfirm = _props.getUserConfirmation,\n getUserConfirmation = _props$getUserConfirm === void 0 ? getConfirmation : _props$getUserConfirm,\n _props$keyLength = _props.keyLength,\n keyLength = _props$keyLength === void 0 ? 6 : _props$keyLength;\n var basename = props.basename ? stripTrailingSlash(addLeadingSlash(props.basename)) : '';\n\n function getDOMLocation(historyState) {\n var _ref = historyState || {},\n key = _ref.key,\n state = _ref.state;\n\n var _window$location = window.location,\n pathname = _window$location.pathname,\n search = _window$location.search,\n hash = _window$location.hash;\n var path = pathname + search + hash;\n process.env.NODE_ENV !== \"production\" ? warning(!basename || hasBasename(path, basename), 'You are attempting to use a basename on a page whose URL path does not begin ' + 'with the basename. Expected path \"' + path + '\" to begin with \"' + basename + '\".') : void 0;\n if (basename) path = stripBasename(path, basename);\n return createLocation(path, state, key);\n }\n\n function createKey() {\n return Math.random().toString(36).substr(2, keyLength);\n }\n\n var transitionManager = createTransitionManager();\n\n function setState(nextState) {\n _extends(history, nextState);\n\n history.length = globalHistory.length;\n transitionManager.notifyListeners(history.location, history.action);\n }\n\n function handlePopState(event) {\n // Ignore extraneous popstate events in WebKit.\n if (isExtraneousPopstateEvent(event)) return;\n handlePop(getDOMLocation(event.state));\n }\n\n function handleHashChange() {\n handlePop(getDOMLocation(getHistoryState()));\n }\n\n var forceNextPop = false;\n\n function handlePop(location) {\n if (forceNextPop) {\n forceNextPop = false;\n setState();\n } else {\n var action = 'POP';\n transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {\n if (ok) {\n setState({\n action: action,\n location: location\n });\n } else {\n revertPop(location);\n }\n });\n }\n }\n\n function revertPop(fromLocation) {\n var toLocation = history.location; // TODO: We could probably make this more reliable by\n // keeping a list of keys we've seen in sessionStorage.\n // Instead, we just default to 0 for keys we don't know.\n\n var toIndex = allKeys.indexOf(toLocation.key);\n if (toIndex === -1) toIndex = 0;\n var fromIndex = allKeys.indexOf(fromLocation.key);\n if (fromIndex === -1) fromIndex = 0;\n var delta = toIndex - fromIndex;\n\n if (delta) {\n forceNextPop = true;\n go(delta);\n }\n }\n\n var initialLocation = getDOMLocation(getHistoryState());\n var allKeys = [initialLocation.key]; // Public interface\n\n function createHref(location) {\n return basename + createPath(location);\n }\n\n function push(path, state) {\n process.env.NODE_ENV !== \"production\" ? warning(!(typeof path === 'object' && path.state !== undefined && state !== undefined), 'You should avoid providing a 2nd state argument to push when the 1st ' + 'argument is a location-like object that already has state; it is ignored') : void 0;\n var action = 'PUSH';\n var location = createLocation(path, state, createKey(), history.location);\n transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {\n if (!ok) return;\n var href = createHref(location);\n var key = location.key,\n state = location.state;\n\n if (canUseHistory) {\n globalHistory.pushState({\n key: key,\n state: state\n }, null, href);\n\n if (forceRefresh) {\n window.location.href = href;\n } else {\n var prevIndex = allKeys.indexOf(history.location.key);\n var nextKeys = allKeys.slice(0, prevIndex + 1);\n nextKeys.push(location.key);\n allKeys = nextKeys;\n setState({\n action: action,\n location: location\n });\n }\n } else {\n process.env.NODE_ENV !== \"production\" ? warning(state === undefined, 'Browser history cannot push state in browsers that do not support HTML5 history') : void 0;\n window.location.href = href;\n }\n });\n }\n\n function replace(path, state) {\n process.env.NODE_ENV !== \"production\" ? warning(!(typeof path === 'object' && path.state !== undefined && state !== undefined), 'You should avoid providing a 2nd state argument to replace when the 1st ' + 'argument is a location-like object that already has state; it is ignored') : void 0;\n var action = 'REPLACE';\n var location = createLocation(path, state, createKey(), history.location);\n transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {\n if (!ok) return;\n var href = createHref(location);\n var key = location.key,\n state = location.state;\n\n if (canUseHistory) {\n globalHistory.replaceState({\n key: key,\n state: state\n }, null, href);\n\n if (forceRefresh) {\n window.location.replace(href);\n } else {\n var prevIndex = allKeys.indexOf(history.location.key);\n if (prevIndex !== -1) allKeys[prevIndex] = location.key;\n setState({\n action: action,\n location: location\n });\n }\n } else {\n process.env.NODE_ENV !== \"production\" ? warning(state === undefined, 'Browser history cannot replace state in browsers that do not support HTML5 history') : void 0;\n window.location.replace(href);\n }\n });\n }\n\n function go(n) {\n globalHistory.go(n);\n }\n\n function goBack() {\n go(-1);\n }\n\n function goForward() {\n go(1);\n }\n\n var listenerCount = 0;\n\n function checkDOMListeners(delta) {\n listenerCount += delta;\n\n if (listenerCount === 1 && delta === 1) {\n window.addEventListener(PopStateEvent, handlePopState);\n if (needsHashChangeListener) window.addEventListener(HashChangeEvent, handleHashChange);\n } else if (listenerCount === 0) {\n window.removeEventListener(PopStateEvent, handlePopState);\n if (needsHashChangeListener) window.removeEventListener(HashChangeEvent, handleHashChange);\n }\n }\n\n var isBlocked = false;\n\n function block(prompt) {\n if (prompt === void 0) {\n prompt = false;\n }\n\n var unblock = transitionManager.setPrompt(prompt);\n\n if (!isBlocked) {\n checkDOMListeners(1);\n isBlocked = true;\n }\n\n return function () {\n if (isBlocked) {\n isBlocked = false;\n checkDOMListeners(-1);\n }\n\n return unblock();\n };\n }\n\n function listen(listener) {\n var unlisten = transitionManager.appendListener(listener);\n checkDOMListeners(1);\n return function () {\n checkDOMListeners(-1);\n unlisten();\n };\n }\n\n var history = {\n length: globalHistory.length,\n action: 'POP',\n location: initialLocation,\n createHref: createHref,\n push: push,\n replace: replace,\n go: go,\n goBack: goBack,\n goForward: goForward,\n block: block,\n listen: listen\n };\n return history;\n}\n\nvar HashChangeEvent$1 = 'hashchange';\nvar HashPathCoders = {\n hashbang: {\n encodePath: function encodePath(path) {\n return path.charAt(0) === '!' ? path : '!/' + stripLeadingSlash(path);\n },\n decodePath: function decodePath(path) {\n return path.charAt(0) === '!' ? path.substr(1) : path;\n }\n },\n noslash: {\n encodePath: stripLeadingSlash,\n decodePath: addLeadingSlash\n },\n slash: {\n encodePath: addLeadingSlash,\n decodePath: addLeadingSlash\n }\n};\n\nfunction stripHash(url) {\n var hashIndex = url.indexOf('#');\n return hashIndex === -1 ? url : url.slice(0, hashIndex);\n}\n\nfunction getHashPath() {\n // We can't use window.location.hash here because it's not\n // consistent across browsers - Firefox will pre-decode it!\n var href = window.location.href;\n var hashIndex = href.indexOf('#');\n return hashIndex === -1 ? '' : href.substring(hashIndex + 1);\n}\n\nfunction pushHashPath(path) {\n window.location.hash = path;\n}\n\nfunction replaceHashPath(path) {\n window.location.replace(stripHash(window.location.href) + '#' + path);\n}\n\nfunction createHashHistory(props) {\n if (props === void 0) {\n props = {};\n }\n\n !canUseDOM ? process.env.NODE_ENV !== \"production\" ? invariant(false, 'Hash history needs a DOM') : invariant(false) : void 0;\n var globalHistory = window.history;\n var canGoWithoutReload = supportsGoWithoutReloadUsingHash();\n var _props = props,\n _props$getUserConfirm = _props.getUserConfirmation,\n getUserConfirmation = _props$getUserConfirm === void 0 ? getConfirmation : _props$getUserConfirm,\n _props$hashType = _props.hashType,\n hashType = _props$hashType === void 0 ? 'slash' : _props$hashType;\n var basename = props.basename ? stripTrailingSlash(addLeadingSlash(props.basename)) : '';\n var _HashPathCoders$hashT = HashPathCoders[hashType],\n encodePath = _HashPathCoders$hashT.encodePath,\n decodePath = _HashPathCoders$hashT.decodePath;\n\n function getDOMLocation() {\n var path = decodePath(getHashPath());\n process.env.NODE_ENV !== \"production\" ? warning(!basename || hasBasename(path, basename), 'You are attempting to use a basename on a page whose URL path does not begin ' + 'with the basename. Expected path \"' + path + '\" to begin with \"' + basename + '\".') : void 0;\n if (basename) path = stripBasename(path, basename);\n return createLocation(path);\n }\n\n var transitionManager = createTransitionManager();\n\n function setState(nextState) {\n _extends(history, nextState);\n\n history.length = globalHistory.length;\n transitionManager.notifyListeners(history.location, history.action);\n }\n\n var forceNextPop = false;\n var ignorePath = null;\n\n function locationsAreEqual$$1(a, b) {\n return a.pathname === b.pathname && a.search === b.search && a.hash === b.hash;\n }\n\n function handleHashChange() {\n var path = getHashPath();\n var encodedPath = encodePath(path);\n\n if (path !== encodedPath) {\n // Ensure we always have a properly-encoded hash.\n replaceHashPath(encodedPath);\n } else {\n var location = getDOMLocation();\n var prevLocation = history.location;\n if (!forceNextPop && locationsAreEqual$$1(prevLocation, location)) return; // A hashchange doesn't always == location change.\n\n if (ignorePath === createPath(location)) return; // Ignore this change; we already setState in push/replace.\n\n ignorePath = null;\n handlePop(location);\n }\n }\n\n function handlePop(location) {\n if (forceNextPop) {\n forceNextPop = false;\n setState();\n } else {\n var action = 'POP';\n transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {\n if (ok) {\n setState({\n action: action,\n location: location\n });\n } else {\n revertPop(location);\n }\n });\n }\n }\n\n function revertPop(fromLocation) {\n var toLocation = history.location; // TODO: We could probably make this more reliable by\n // keeping a list of paths we've seen in sessionStorage.\n // Instead, we just default to 0 for paths we don't know.\n\n var toIndex = allPaths.lastIndexOf(createPath(toLocation));\n if (toIndex === -1) toIndex = 0;\n var fromIndex = allPaths.lastIndexOf(createPath(fromLocation));\n if (fromIndex === -1) fromIndex = 0;\n var delta = toIndex - fromIndex;\n\n if (delta) {\n forceNextPop = true;\n go(delta);\n }\n } // Ensure the hash is encoded properly before doing anything else.\n\n\n var path = getHashPath();\n var encodedPath = encodePath(path);\n if (path !== encodedPath) replaceHashPath(encodedPath);\n var initialLocation = getDOMLocation();\n var allPaths = [createPath(initialLocation)]; // Public interface\n\n function createHref(location) {\n var baseTag = document.querySelector('base');\n var href = '';\n\n if (baseTag && baseTag.getAttribute('href')) {\n href = stripHash(window.location.href);\n }\n\n return href + '#' + encodePath(basename + createPath(location));\n }\n\n function push(path, state) {\n process.env.NODE_ENV !== \"production\" ? warning(state === undefined, 'Hash history cannot push state; it is ignored') : void 0;\n var action = 'PUSH';\n var location = createLocation(path, undefined, undefined, history.location);\n transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {\n if (!ok) return;\n var path = createPath(location);\n var encodedPath = encodePath(basename + path);\n var hashChanged = getHashPath() !== encodedPath;\n\n if (hashChanged) {\n // We cannot tell if a hashchange was caused by a PUSH, so we'd\n // rather setState here and ignore the hashchange. The caveat here\n // is that other hash histories in the page will consider it a POP.\n ignorePath = path;\n pushHashPath(encodedPath);\n var prevIndex = allPaths.lastIndexOf(createPath(history.location));\n var nextPaths = allPaths.slice(0, prevIndex + 1);\n nextPaths.push(path);\n allPaths = nextPaths;\n setState({\n action: action,\n location: location\n });\n } else {\n process.env.NODE_ENV !== \"production\" ? warning(false, 'Hash history cannot PUSH the same path; a new entry will not be added to the history stack') : void 0;\n setState();\n }\n });\n }\n\n function replace(path, state) {\n process.env.NODE_ENV !== \"production\" ? warning(state === undefined, 'Hash history cannot replace state; it is ignored') : void 0;\n var action = 'REPLACE';\n var location = createLocation(path, undefined, undefined, history.location);\n transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {\n if (!ok) return;\n var path = createPath(location);\n var encodedPath = encodePath(basename + path);\n var hashChanged = getHashPath() !== encodedPath;\n\n if (hashChanged) {\n // We cannot tell if a hashchange was caused by a REPLACE, so we'd\n // rather setState here and ignore the hashchange. The caveat here\n // is that other hash histories in the page will consider it a POP.\n ignorePath = path;\n replaceHashPath(encodedPath);\n }\n\n var prevIndex = allPaths.indexOf(createPath(history.location));\n if (prevIndex !== -1) allPaths[prevIndex] = path;\n setState({\n action: action,\n location: location\n });\n });\n }\n\n function go(n) {\n process.env.NODE_ENV !== \"production\" ? warning(canGoWithoutReload, 'Hash history go(n) causes a full page reload in this browser') : void 0;\n globalHistory.go(n);\n }\n\n function goBack() {\n go(-1);\n }\n\n function goForward() {\n go(1);\n }\n\n var listenerCount = 0;\n\n function checkDOMListeners(delta) {\n listenerCount += delta;\n\n if (listenerCount === 1 && delta === 1) {\n window.addEventListener(HashChangeEvent$1, handleHashChange);\n } else if (listenerCount === 0) {\n window.removeEventListener(HashChangeEvent$1, handleHashChange);\n }\n }\n\n var isBlocked = false;\n\n function block(prompt) {\n if (prompt === void 0) {\n prompt = false;\n }\n\n var unblock = transitionManager.setPrompt(prompt);\n\n if (!isBlocked) {\n checkDOMListeners(1);\n isBlocked = true;\n }\n\n return function () {\n if (isBlocked) {\n isBlocked = false;\n checkDOMListeners(-1);\n }\n\n return unblock();\n };\n }\n\n function listen(listener) {\n var unlisten = transitionManager.appendListener(listener);\n checkDOMListeners(1);\n return function () {\n checkDOMListeners(-1);\n unlisten();\n };\n }\n\n var history = {\n length: globalHistory.length,\n action: 'POP',\n location: initialLocation,\n createHref: createHref,\n push: push,\n replace: replace,\n go: go,\n goBack: goBack,\n goForward: goForward,\n block: block,\n listen: listen\n };\n return history;\n}\n\nfunction clamp(n, lowerBound, upperBound) {\n return Math.min(Math.max(n, lowerBound), upperBound);\n}\n/**\n * Creates a history object that stores locations in memory.\n */\n\n\nfunction createMemoryHistory(props) {\n if (props === void 0) {\n props = {};\n }\n\n var _props = props,\n getUserConfirmation = _props.getUserConfirmation,\n _props$initialEntries = _props.initialEntries,\n initialEntries = _props$initialEntries === void 0 ? ['/'] : _props$initialEntries,\n _props$initialIndex = _props.initialIndex,\n initialIndex = _props$initialIndex === void 0 ? 0 : _props$initialIndex,\n _props$keyLength = _props.keyLength,\n keyLength = _props$keyLength === void 0 ? 6 : _props$keyLength;\n var transitionManager = createTransitionManager();\n\n function setState(nextState) {\n _extends(history, nextState);\n\n history.length = history.entries.length;\n transitionManager.notifyListeners(history.location, history.action);\n }\n\n function createKey() {\n return Math.random().toString(36).substr(2, keyLength);\n }\n\n var index = clamp(initialIndex, 0, initialEntries.length - 1);\n var entries = initialEntries.map(function (entry) {\n return typeof entry === 'string' ? createLocation(entry, undefined, createKey()) : createLocation(entry, undefined, entry.key || createKey());\n }); // Public interface\n\n var createHref = createPath;\n\n function push(path, state) {\n process.env.NODE_ENV !== \"production\" ? warning(!(typeof path === 'object' && path.state !== undefined && state !== undefined), 'You should avoid providing a 2nd state argument to push when the 1st ' + 'argument is a location-like object that already has state; it is ignored') : void 0;\n var action = 'PUSH';\n var location = createLocation(path, state, createKey(), history.location);\n transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {\n if (!ok) return;\n var prevIndex = history.index;\n var nextIndex = prevIndex + 1;\n var nextEntries = history.entries.slice(0);\n\n if (nextEntries.length > nextIndex) {\n nextEntries.splice(nextIndex, nextEntries.length - nextIndex, location);\n } else {\n nextEntries.push(location);\n }\n\n setState({\n action: action,\n location: location,\n index: nextIndex,\n entries: nextEntries\n });\n });\n }\n\n function replace(path, state) {\n process.env.NODE_ENV !== \"production\" ? warning(!(typeof path === 'object' && path.state !== undefined && state !== undefined), 'You should avoid providing a 2nd state argument to replace when the 1st ' + 'argument is a location-like object that already has state; it is ignored') : void 0;\n var action = 'REPLACE';\n var location = createLocation(path, state, createKey(), history.location);\n transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {\n if (!ok) return;\n history.entries[history.index] = location;\n setState({\n action: action,\n location: location\n });\n });\n }\n\n function go(n) {\n var nextIndex = clamp(history.index + n, 0, history.entries.length - 1);\n var action = 'POP';\n var location = history.entries[nextIndex];\n transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {\n if (ok) {\n setState({\n action: action,\n location: location,\n index: nextIndex\n });\n } else {\n // Mimic the behavior of DOM histories by\n // causing a render after a cancelled POP.\n setState();\n }\n });\n }\n\n function goBack() {\n go(-1);\n }\n\n function goForward() {\n go(1);\n }\n\n function canGo(n) {\n var nextIndex = history.index + n;\n return nextIndex >= 0 && nextIndex < history.entries.length;\n }\n\n function block(prompt) {\n if (prompt === void 0) {\n prompt = false;\n }\n\n return transitionManager.setPrompt(prompt);\n }\n\n function listen(listener) {\n return transitionManager.appendListener(listener);\n }\n\n var history = {\n length: entries.length,\n action: 'POP',\n location: entries[index],\n index: index,\n entries: entries,\n createHref: createHref,\n push: push,\n replace: replace,\n go: go,\n goBack: goBack,\n goForward: goForward,\n canGo: canGo,\n block: block,\n listen: listen\n };\n return history;\n}\n\nexport { createBrowserHistory, createHashHistory, createMemoryHistory, createLocation, locationsAreEqual, parsePath, createPath };\n","var locale = {\n locale: 'en_US',\n today: 'Today',\n now: 'Now',\n backToToday: 'Back to today',\n ok: 'Ok',\n clear: 'Clear',\n month: 'Month',\n year: 'Year',\n timeSelect: 'select time',\n dateSelect: 'select date',\n weekSelect: 'Choose a week',\n monthSelect: 'Choose a month',\n yearSelect: 'Choose a year',\n decadeSelect: 'Choose a decade',\n yearFormat: 'YYYY',\n dateFormat: 'M/D/YYYY',\n dayFormat: 'D',\n dateTimeFormat: 'M/D/YYYY HH:mm:ss',\n monthBeforeYear: true,\n previousMonth: 'Previous month (PageUp)',\n nextMonth: 'Next month (PageDown)',\n previousYear: 'Last year (Control + left)',\n nextYear: 'Next year (Control + right)',\n previousDecade: 'Last decade',\n nextDecade: 'Next decade',\n previousCentury: 'Last century',\n nextCentury: 'Next century'\n};\nexport default locale;","var locale = {\n placeholder: 'Select time',\n rangePlaceholder: ['Start time', 'End time']\n};\nexport default locale;","import _extends from \"@babel/runtime/helpers/extends\";\nimport CalendarLocale from \"rc-picker/es/locale/en_US\";\nimport TimePickerLocale from '../../time-picker/locale/en_US'; // Merge into a locale object\n\nvar locale = {\n lang: _extends({\n placeholder: 'Select date',\n yearPlaceholder: 'Select year',\n quarterPlaceholder: 'Select quarter',\n monthPlaceholder: 'Select month',\n weekPlaceholder: 'Select week',\n rangePlaceholder: ['Start date', 'End date'],\n rangeYearPlaceholder: ['Start year', 'End year'],\n rangeMonthPlaceholder: ['Start month', 'End month'],\n rangeWeekPlaceholder: ['Start week', 'End week']\n }, CalendarLocale),\n timePickerLocale: _extends({}, TimePickerLocale)\n}; // All settings at:\n// https://github.com/ant-design/ant-design/blob/master/components/date-picker/locale/example.json\n\nexport default locale;","import enUS from '../../date-picker/locale/en_US';\nexport default enUS;","/* eslint-disable no-template-curly-in-string */\nimport Pagination from \"rc-pagination/es/locale/en_US\";\nimport DatePicker from '../date-picker/locale/en_US';\nimport TimePicker from '../time-picker/locale/en_US';\nimport Calendar from '../calendar/locale/en_US';\nvar typeTemplate = '${label} is not a valid ${type}';\nvar localeValues = {\n locale: 'en',\n Pagination: Pagination,\n DatePicker: DatePicker,\n TimePicker: TimePicker,\n Calendar: Calendar,\n global: {\n placeholder: 'Please select'\n },\n Table: {\n filterTitle: 'Filter menu',\n filterConfirm: 'OK',\n filterReset: 'Reset',\n filterEmptyText: 'No filters',\n emptyText: 'No data',\n selectAll: 'Select current page',\n selectInvert: 'Invert current page',\n selectionAll: 'Select all data',\n sortTitle: 'Sort',\n expand: 'Expand row',\n collapse: 'Collapse row',\n triggerDesc: 'Click sort by descend',\n triggerAsc: 'Click sort by ascend',\n cancelSort: 'Click to cancel sort'\n },\n Modal: {\n okText: 'OK',\n cancelText: 'Cancel',\n justOkText: 'OK'\n },\n Popconfirm: {\n okText: 'OK',\n cancelText: 'Cancel'\n },\n Transfer: {\n titles: ['', ''],\n searchPlaceholder: 'Search here',\n itemUnit: 'item',\n itemsUnit: 'items',\n remove: 'Remove',\n selectCurrent: 'Select current page',\n removeCurrent: 'Remove current page',\n selectAll: 'Select all data',\n removeAll: 'Remove all data',\n selectInvert: 'Invert current page'\n },\n Upload: {\n uploading: 'Uploading...',\n removeFile: 'Remove file',\n uploadError: 'Upload error',\n previewFile: 'Preview file',\n downloadFile: 'Download file'\n },\n Empty: {\n description: 'No Data'\n },\n Icon: {\n icon: 'icon'\n },\n Text: {\n edit: 'Edit',\n copy: 'Copy',\n copied: 'Copied',\n expand: 'Expand'\n },\n PageHeader: {\n back: 'Back'\n },\n Form: {\n optional: '(optional)',\n defaultValidateMessages: {\n \"default\": 'Field validation error ${label}',\n required: 'Please enter ${label}',\n \"enum\": '${label} must be one of [${enum}]',\n whitespace: '${label} cannot be a blank character',\n date: {\n format: '${label} date format is invalid',\n parse: '${label} cannot be converted to a date',\n invalid: '${label} is an invalid date'\n },\n types: {\n string: typeTemplate,\n method: typeTemplate,\n array: typeTemplate,\n object: typeTemplate,\n number: typeTemplate,\n date: typeTemplate,\n \"boolean\": typeTemplate,\n integer: typeTemplate,\n \"float\": typeTemplate,\n regexp: typeTemplate,\n email: typeTemplate,\n url: typeTemplate,\n hex: typeTemplate\n },\n string: {\n len: '${label} must be ${len} characters',\n min: '${label} at least ${min} characters',\n max: '${label} up to ${max} characters',\n range: '${label} must be between ${min}-${max} characters'\n },\n number: {\n len: '${label} must be equal to ${len}',\n min: '${label} minimum value is ${min}',\n max: '${label} maximum value is ${max}',\n range: '${label} must be between ${min}-${max}'\n },\n array: {\n len: 'Must be ${len} ${label}',\n min: 'At least ${min} ${label}',\n max: 'At most ${max} ${label}',\n range: 'The amount of ${label} must be between ${min}-${max}'\n },\n pattern: {\n mismatch: '${label} does not match the pattern ${pattern}'\n }\n }\n }\n};\nexport default localeValues;","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _toArray from \"@babel/runtime/helpers/esm/toArray\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport warning from \"rc-util/es/warning\";\nimport { toArray } from './commonUtil';\n\nfunction getKey(data, index) {\n var key = data.key;\n var value;\n\n if ('value' in data) {\n value = data.value;\n }\n\n if (key !== null && key !== undefined) {\n return key;\n }\n\n if (value !== undefined) {\n return value;\n }\n\n return \"rc-index-key-\".concat(index);\n}\n/**\n * Flat options into flatten list.\n * We use `optionOnly` here is aim to avoid user use nested option group.\n * Here is simply set `key` to the index if not provided.\n */\n\n\nexport function flattenOptions(options) {\n var flattenList = [];\n\n function dig(list, isGroupOption) {\n list.forEach(function (data) {\n if (isGroupOption || !('options' in data)) {\n // Option\n flattenList.push({\n key: getKey(data, flattenList.length),\n groupOption: isGroupOption,\n data: data\n });\n } else {\n // Option Group\n flattenList.push({\n key: getKey(data, flattenList.length),\n group: true,\n data: data\n });\n dig(data.options, true);\n }\n });\n }\n\n dig(options, false);\n return flattenList;\n}\n/**\n * Inject `props` into `option` for legacy usage\n */\n\nfunction injectPropsWithOption(option) {\n var newOption = _objectSpread({}, option);\n\n if (!('props' in newOption)) {\n Object.defineProperty(newOption, 'props', {\n get: function get() {\n warning(false, 'Return type is option instead of Option instance. Please read value directly instead of reading from `props`.');\n return newOption;\n }\n });\n }\n\n return newOption;\n}\n\nexport function findValueOption(values, options) {\n var _ref = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {},\n _ref$prevValueOptions = _ref.prevValueOptions,\n prevValueOptions = _ref$prevValueOptions === void 0 ? [] : _ref$prevValueOptions;\n\n var optionMap = new Map();\n options.forEach(function (flattenItem) {\n if (!flattenItem.group) {\n var data = flattenItem.data; // Check if match\n\n optionMap.set(data.value, data);\n }\n });\n return values.map(function (val) {\n var option = optionMap.get(val); // Fallback to try to find prev options\n\n if (!option) {\n option = _objectSpread({}, prevValueOptions.find(function (opt) {\n return opt._INTERNAL_OPTION_VALUE_ === val;\n }));\n }\n\n return injectPropsWithOption(option);\n });\n}\nexport var getLabeledValue = function getLabeledValue(value, _ref2) {\n var options = _ref2.options,\n prevValue = _ref2.prevValue,\n labelInValue = _ref2.labelInValue,\n optionLabelProp = _ref2.optionLabelProp;\n var item = findValueOption([value], options)[0];\n var result = {\n value: value\n };\n var prevValItem;\n var prevValues = toArray(prevValue);\n\n if (labelInValue) {\n prevValItem = prevValues.find(function (prevItem) {\n if (_typeof(prevItem) === 'object' && 'value' in prevItem) {\n return prevItem.value === value;\n } // [Legacy] Support `key` as `value`\n\n\n return prevItem.key === value;\n });\n }\n\n if (prevValItem && _typeof(prevValItem) === 'object' && 'label' in prevValItem) {\n result.label = prevValItem.label;\n\n if (item && typeof prevValItem.label === 'string' && typeof item[optionLabelProp] === 'string' && prevValItem.label.trim() !== item[optionLabelProp].trim()) {\n warning(false, '`label` of `value` is not same as `label` in Select options.');\n }\n } else if (item && optionLabelProp in item) {\n result.label = item[optionLabelProp];\n } else {\n result.label = value;\n } // Used for motion control\n\n\n result.key = result.value;\n return result;\n};\n\nfunction toRawString(content) {\n return toArray(content).join('');\n}\n/** Filter single option if match the search text */\n\n\nfunction getFilterFunction(optionFilterProp) {\n return function (searchValue, option) {\n var lowerSearchText = searchValue.toLowerCase(); // Group label search\n\n if ('options' in option) {\n return toRawString(option.label).toLowerCase().includes(lowerSearchText);\n } // Option value search\n\n\n var rawValue = option[optionFilterProp];\n var value = toRawString(rawValue).toLowerCase();\n return value.includes(lowerSearchText) && !option.disabled;\n };\n}\n/** Filter options and return a new options by the search text */\n\n\nexport function filterOptions(searchValue, options, _ref3) {\n var optionFilterProp = _ref3.optionFilterProp,\n filterOption = _ref3.filterOption;\n var filteredOptions = [];\n var filterFunc;\n\n if (filterOption === false) {\n return options;\n }\n\n if (typeof filterOption === 'function') {\n filterFunc = filterOption;\n } else {\n filterFunc = getFilterFunction(optionFilterProp);\n }\n\n options.forEach(function (item) {\n // Group should check child options\n if ('options' in item) {\n // Check group first\n var matchGroup = filterFunc(searchValue, item);\n\n if (matchGroup) {\n filteredOptions.push(item);\n } else {\n // Check option\n var subOptions = item.options.filter(function (subItem) {\n return filterFunc(searchValue, subItem);\n });\n\n if (subOptions.length) {\n filteredOptions.push(_objectSpread(_objectSpread({}, item), {}, {\n options: subOptions\n }));\n }\n }\n\n return;\n }\n\n if (filterFunc(searchValue, injectPropsWithOption(item))) {\n filteredOptions.push(item);\n }\n });\n return filteredOptions;\n}\nexport function getSeparatedContent(text, tokens) {\n if (!tokens || !tokens.length) {\n return null;\n }\n\n var match = false;\n\n function separate(str, _ref4) {\n var _ref5 = _toArray(_ref4),\n token = _ref5[0],\n restTokens = _ref5.slice(1);\n\n if (!token) {\n return [str];\n }\n\n var list = str.split(token);\n match = match || list.length > 1;\n return list.reduce(function (prevList, unitStr) {\n return [].concat(_toConsumableArray(prevList), _toConsumableArray(separate(unitStr, restTokens)));\n }, []).filter(function (unit) {\n return unit;\n });\n }\n\n var list = separate(text, tokens);\n return match ? list : null;\n}\nexport function isValueDisabled(value, options) {\n var option = findValueOption([value], options)[0];\n return option.disabled;\n}\n/**\n * `tags` mode should fill un-list item into the option list\n */\n\nexport function fillOptionsWithMissingValue(options, value, optionLabelProp, labelInValue) {\n var values = toArray(value).slice().sort();\n\n var cloneOptions = _toConsumableArray(options); // Convert options value to set\n\n\n var optionValues = new Set();\n options.forEach(function (opt) {\n if (opt.options) {\n opt.options.forEach(function (subOpt) {\n optionValues.add(subOpt.value);\n });\n } else {\n optionValues.add(opt.value);\n }\n }); // Fill missing value\n\n values.forEach(function (item) {\n var val = labelInValue ? item.value : item;\n\n if (!optionValues.has(val)) {\n var _ref6;\n\n cloneOptions.push(labelInValue ? (_ref6 = {}, _defineProperty(_ref6, optionLabelProp, item.label), _defineProperty(_ref6, \"value\", val), _ref6) : {\n value: val\n });\n }\n });\n return cloneOptions;\n}","import arrayWithHoles from \"./arrayWithHoles\";\nimport iterableToArray from \"./iterableToArray\";\nimport unsupportedIterableToArray from \"./unsupportedIterableToArray\";\nimport nonIterableRest from \"./nonIterableRest\";\nexport default function _toArray(arr) {\n return arrayWithHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableRest();\n}","var START_EVENT_NAME_MAP = {\n transitionstart: {\n transition: 'transitionstart',\n WebkitTransition: 'webkitTransitionStart',\n MozTransition: 'mozTransitionStart',\n OTransition: 'oTransitionStart',\n msTransition: 'MSTransitionStart'\n },\n\n animationstart: {\n animation: 'animationstart',\n WebkitAnimation: 'webkitAnimationStart',\n MozAnimation: 'mozAnimationStart',\n OAnimation: 'oAnimationStart',\n msAnimation: 'MSAnimationStart'\n }\n};\n\nvar END_EVENT_NAME_MAP = {\n transitionend: {\n transition: 'transitionend',\n WebkitTransition: 'webkitTransitionEnd',\n MozTransition: 'mozTransitionEnd',\n OTransition: 'oTransitionEnd',\n msTransition: 'MSTransitionEnd'\n },\n\n animationend: {\n animation: 'animationend',\n WebkitAnimation: 'webkitAnimationEnd',\n MozAnimation: 'mozAnimationEnd',\n OAnimation: 'oAnimationEnd',\n msAnimation: 'MSAnimationEnd'\n }\n};\n\nvar startEvents = [];\nvar endEvents = [];\n\nfunction detectEvents() {\n var testEl = document.createElement('div');\n var style = testEl.style;\n\n if (!('AnimationEvent' in window)) {\n delete START_EVENT_NAME_MAP.animationstart.animation;\n delete END_EVENT_NAME_MAP.animationend.animation;\n }\n\n if (!('TransitionEvent' in window)) {\n delete START_EVENT_NAME_MAP.transitionstart.transition;\n delete END_EVENT_NAME_MAP.transitionend.transition;\n }\n\n function process(EVENT_NAME_MAP, events) {\n for (var baseEventName in EVENT_NAME_MAP) {\n if (EVENT_NAME_MAP.hasOwnProperty(baseEventName)) {\n var baseEvents = EVENT_NAME_MAP[baseEventName];\n for (var styleName in baseEvents) {\n if (styleName in style) {\n events.push(baseEvents[styleName]);\n break;\n }\n }\n }\n }\n }\n\n process(START_EVENT_NAME_MAP, startEvents);\n process(END_EVENT_NAME_MAP, endEvents);\n}\n\nif (typeof window !== 'undefined' && typeof document !== 'undefined') {\n detectEvents();\n}\n\nfunction addEventListener(node, eventName, eventListener) {\n node.addEventListener(eventName, eventListener, false);\n}\n\nfunction removeEventListener(node, eventName, eventListener) {\n node.removeEventListener(eventName, eventListener, false);\n}\n\nvar TransitionEvents = {\n // Start events\n startEvents: startEvents,\n\n addStartEventListener: function addStartEventListener(node, eventListener) {\n if (startEvents.length === 0) {\n window.setTimeout(eventListener, 0);\n return;\n }\n startEvents.forEach(function (startEvent) {\n addEventListener(node, startEvent, eventListener);\n });\n },\n removeStartEventListener: function removeStartEventListener(node, eventListener) {\n if (startEvents.length === 0) {\n return;\n }\n startEvents.forEach(function (startEvent) {\n removeEventListener(node, startEvent, eventListener);\n });\n },\n\n\n // End events\n endEvents: endEvents,\n\n addEndEventListener: function addEndEventListener(node, eventListener) {\n if (endEvents.length === 0) {\n window.setTimeout(eventListener, 0);\n return;\n }\n endEvents.forEach(function (endEvent) {\n addEventListener(node, endEvent, eventListener);\n });\n },\n removeEndEventListener: function removeEndEventListener(node, eventListener) {\n if (endEvents.length === 0) {\n return;\n }\n endEvents.forEach(function (endEvent) {\n removeEventListener(node, endEvent, eventListener);\n });\n }\n};\n\nexport default TransitionEvents;","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nmodule.exports = root;\n","import locale from '../locale/default';\nexport default locale;","import { createContext } from 'react';\nvar LocaleContext = /*#__PURE__*/createContext(undefined);\nexport default LocaleContext;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\nimport * as React from 'react';\nimport defaultLocaleData from './default';\nimport LocaleContext from './context';\n\nvar LocaleReceiver = /*#__PURE__*/function (_React$Component) {\n _inherits(LocaleReceiver, _React$Component);\n\n var _super = _createSuper(LocaleReceiver);\n\n function LocaleReceiver() {\n _classCallCheck(this, LocaleReceiver);\n\n return _super.apply(this, arguments);\n }\n\n _createClass(LocaleReceiver, [{\n key: \"getLocale\",\n value: function getLocale() {\n var _this$props = this.props,\n componentName = _this$props.componentName,\n defaultLocale = _this$props.defaultLocale;\n var locale = defaultLocale || defaultLocaleData[componentName || 'global'];\n var antLocale = this.context;\n var localeFromContext = componentName && antLocale ? antLocale[componentName] : {};\n return _extends(_extends({}, typeof locale === 'function' ? locale() : locale), localeFromContext || {});\n }\n }, {\n key: \"getLocaleCode\",\n value: function getLocaleCode() {\n var antLocale = this.context;\n var localeCode = antLocale && antLocale.locale; // Had use LocaleProvide but didn't set locale\n\n if (antLocale && antLocale.exist && !localeCode) {\n return defaultLocaleData.locale;\n }\n\n return localeCode;\n }\n }, {\n key: \"render\",\n value: function render() {\n return this.props.children(this.getLocale(), this.getLocaleCode(), this.context);\n }\n }]);\n\n return LocaleReceiver;\n}(React.Component);\n\nexport { LocaleReceiver as default };\nLocaleReceiver.defaultProps = {\n componentName: 'global'\n};\nLocaleReceiver.contextType = LocaleContext;\nexport function useLocaleReceiver(componentName, defaultLocale) {\n var antLocale = React.useContext(LocaleContext);\n var componentLocale = React.useMemo(function () {\n var locale = defaultLocale || defaultLocaleData[componentName || 'global'];\n var localeFromContext = componentName && antLocale ? antLocale[componentName] : {};\n return _extends(_extends({}, typeof locale === 'function' ? locale() : locale), localeFromContext || {});\n }, [componentName, defaultLocale, antLocale]);\n return [componentLocale];\n}","import '../../style/index.less';\nimport './index.less';","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport * as React from 'react';\nimport classNames from 'classnames';\n\nvar Indent = function Indent(_ref) {\n var prefixCls = _ref.prefixCls,\n level = _ref.level,\n isStart = _ref.isStart,\n isEnd = _ref.isEnd;\n\n if (!level) {\n return null;\n }\n\n var baseClassName = \"\".concat(prefixCls, \"-indent-unit\");\n var list = [];\n\n for (var i = 0; i < level; i += 1) {\n var _classNames;\n\n list.push(React.createElement(\"span\", {\n key: i,\n className: classNames(baseClassName, (_classNames = {}, _defineProperty(_classNames, \"\".concat(baseClassName, \"-start\"), isStart[i + 1]), _defineProperty(_classNames, \"\".concat(baseClassName, \"-end\"), isEnd[i + 1]), _defineProperty(_classNames, \"\".concat(baseClassName, \"-end-first-level\"), !i && isEnd[0]), _classNames))\n }));\n }\n\n return React.createElement(\"span\", {\n \"aria-hidden\": \"true\",\n className: \"\".concat(prefixCls, \"-indent\")\n }, list);\n};\n\nexport default Indent;","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport * as React from 'react';\nimport classNames from 'classnames'; // @ts-ignore\n\nimport { TreeContext } from './contextTypes';\nimport { getDataAndAria } from './util';\nimport Indent from './Indent';\nimport { convertNodePropsToEventData } from './utils/treeUtil';\nvar ICON_OPEN = 'open';\nvar ICON_CLOSE = 'close';\nvar defaultTitle = '---';\n\nvar InternalTreeNode = /*#__PURE__*/function (_React$Component) {\n _inherits(InternalTreeNode, _React$Component);\n\n var _super = _createSuper(InternalTreeNode);\n\n function InternalTreeNode() {\n var _this;\n\n _classCallCheck(this, InternalTreeNode);\n\n _this = _super.apply(this, arguments);\n _this.state = {\n dragNodeHighlight: false\n };\n\n _this.onSelectorClick = function (e) {\n // Click trigger before select/check operation\n var onNodeClick = _this.props.context.onNodeClick;\n onNodeClick(e, convertNodePropsToEventData(_this.props));\n\n if (_this.isSelectable()) {\n _this.onSelect(e);\n } else {\n _this.onCheck(e);\n }\n };\n\n _this.onSelectorDoubleClick = function (e) {\n var onNodeDoubleClick = _this.props.context.onNodeDoubleClick;\n onNodeDoubleClick(e, convertNodePropsToEventData(_this.props));\n };\n\n _this.onSelect = function (e) {\n if (_this.isDisabled()) return;\n var onNodeSelect = _this.props.context.onNodeSelect;\n e.preventDefault();\n onNodeSelect(e, convertNodePropsToEventData(_this.props));\n };\n\n _this.onCheck = function (e) {\n if (_this.isDisabled()) return;\n var _this$props = _this.props,\n disableCheckbox = _this$props.disableCheckbox,\n checked = _this$props.checked;\n var onNodeCheck = _this.props.context.onNodeCheck;\n if (!_this.isCheckable() || disableCheckbox) return;\n e.preventDefault();\n var targetChecked = !checked;\n onNodeCheck(e, convertNodePropsToEventData(_this.props), targetChecked);\n };\n\n _this.onMouseEnter = function (e) {\n var onNodeMouseEnter = _this.props.context.onNodeMouseEnter;\n onNodeMouseEnter(e, convertNodePropsToEventData(_this.props));\n };\n\n _this.onMouseLeave = function (e) {\n var onNodeMouseLeave = _this.props.context.onNodeMouseLeave;\n onNodeMouseLeave(e, convertNodePropsToEventData(_this.props));\n };\n\n _this.onContextMenu = function (e) {\n var onNodeContextMenu = _this.props.context.onNodeContextMenu;\n onNodeContextMenu(e, convertNodePropsToEventData(_this.props));\n };\n\n _this.onDragStart = function (e) {\n var onNodeDragStart = _this.props.context.onNodeDragStart;\n e.stopPropagation();\n\n _this.setState({\n dragNodeHighlight: true\n });\n\n onNodeDragStart(e, _assertThisInitialized(_this));\n\n try {\n // ie throw error\n // firefox-need-it\n e.dataTransfer.setData('text/plain', '');\n } catch (error) {// empty\n }\n };\n\n _this.onDragEnter = function (e) {\n var onNodeDragEnter = _this.props.context.onNodeDragEnter;\n e.preventDefault();\n e.stopPropagation();\n onNodeDragEnter(e, _assertThisInitialized(_this));\n };\n\n _this.onDragOver = function (e) {\n var onNodeDragOver = _this.props.context.onNodeDragOver;\n e.preventDefault();\n e.stopPropagation();\n onNodeDragOver(e, _assertThisInitialized(_this));\n };\n\n _this.onDragLeave = function (e) {\n var onNodeDragLeave = _this.props.context.onNodeDragLeave;\n e.stopPropagation();\n onNodeDragLeave(e, _assertThisInitialized(_this));\n };\n\n _this.onDragEnd = function (e) {\n var onNodeDragEnd = _this.props.context.onNodeDragEnd;\n e.stopPropagation();\n\n _this.setState({\n dragNodeHighlight: false\n });\n\n onNodeDragEnd(e, _assertThisInitialized(_this));\n };\n\n _this.onDrop = function (e) {\n var onNodeDrop = _this.props.context.onNodeDrop;\n e.preventDefault();\n e.stopPropagation();\n\n _this.setState({\n dragNodeHighlight: false\n });\n\n onNodeDrop(e, _assertThisInitialized(_this));\n }; // Disabled item still can be switch\n\n\n _this.onExpand = function (e) {\n var onNodeExpand = _this.props.context.onNodeExpand;\n onNodeExpand(e, convertNodePropsToEventData(_this.props));\n }; // Drag usage\n\n\n _this.setSelectHandle = function (node) {\n _this.selectHandle = node;\n };\n\n _this.getNodeState = function () {\n var expanded = _this.props.expanded;\n\n if (_this.isLeaf()) {\n return null;\n }\n\n return expanded ? ICON_OPEN : ICON_CLOSE;\n };\n\n _this.hasChildren = function () {\n var eventKey = _this.props.eventKey;\n var keyEntities = _this.props.context.keyEntities;\n\n var _ref = keyEntities[eventKey] || {},\n children = _ref.children;\n\n return !!(children || []).length;\n };\n\n _this.isLeaf = function () {\n var _this$props2 = _this.props,\n isLeaf = _this$props2.isLeaf,\n loaded = _this$props2.loaded;\n var loadData = _this.props.context.loadData;\n\n var hasChildren = _this.hasChildren();\n\n if (isLeaf === false) {\n return false;\n }\n\n return isLeaf || !loadData && !hasChildren || loadData && loaded && !hasChildren;\n };\n\n _this.isDisabled = function () {\n var disabled = _this.props.disabled;\n var treeDisabled = _this.props.context.disabled;\n return !!(treeDisabled || disabled);\n };\n\n _this.isCheckable = function () {\n var checkable = _this.props.checkable;\n var treeCheckable = _this.props.context.checkable; // Return false if tree or treeNode is not checkable\n\n if (!treeCheckable || checkable === false) return false;\n return treeCheckable;\n }; // Load data to avoid default expanded tree without data\n\n\n _this.syncLoadData = function (props) {\n var expanded = props.expanded,\n loading = props.loading,\n loaded = props.loaded;\n var _this$props$context = _this.props.context,\n loadData = _this$props$context.loadData,\n onNodeLoad = _this$props$context.onNodeLoad;\n if (loading) return; // read from state to avoid loadData at same time\n\n if (loadData && expanded && !_this.isLeaf()) {\n // We needn't reload data when has children in sync logic\n // It's only needed in node expanded\n if (!_this.hasChildren() && !loaded) {\n onNodeLoad(convertNodePropsToEventData(_this.props));\n }\n }\n }; // Switcher\n\n\n _this.renderSwitcher = function () {\n var _this$props3 = _this.props,\n expanded = _this$props3.expanded,\n switcherIconFromProps = _this$props3.switcherIcon;\n var _this$props$context2 = _this.props.context,\n prefixCls = _this$props$context2.prefixCls,\n switcherIconFromCtx = _this$props$context2.switcherIcon;\n var switcherIcon = switcherIconFromProps || switcherIconFromCtx;\n\n if (_this.isLeaf()) {\n return React.createElement(\"span\", {\n className: classNames(\"\".concat(prefixCls, \"-switcher\"), \"\".concat(prefixCls, \"-switcher-noop\"))\n }, typeof switcherIcon === 'function' ? switcherIcon(_objectSpread(_objectSpread({}, _this.props), {}, {\n isLeaf: true\n })) : switcherIcon);\n }\n\n var switcherCls = classNames(\"\".concat(prefixCls, \"-switcher\"), \"\".concat(prefixCls, \"-switcher_\").concat(expanded ? ICON_OPEN : ICON_CLOSE));\n return React.createElement(\"span\", {\n onClick: _this.onExpand,\n className: switcherCls\n }, typeof switcherIcon === 'function' ? switcherIcon(_objectSpread(_objectSpread({}, _this.props), {}, {\n isLeaf: false\n })) : switcherIcon);\n }; // Checkbox\n\n\n _this.renderCheckbox = function () {\n var _this$props4 = _this.props,\n checked = _this$props4.checked,\n halfChecked = _this$props4.halfChecked,\n disableCheckbox = _this$props4.disableCheckbox;\n var prefixCls = _this.props.context.prefixCls;\n\n var disabled = _this.isDisabled();\n\n var checkable = _this.isCheckable();\n\n if (!checkable) return null; // [Legacy] Custom element should be separate with `checkable` in future\n\n var $custom = typeof checkable !== 'boolean' ? checkable : null;\n return React.createElement(\"span\", {\n className: classNames(\"\".concat(prefixCls, \"-checkbox\"), checked && \"\".concat(prefixCls, \"-checkbox-checked\"), !checked && halfChecked && \"\".concat(prefixCls, \"-checkbox-indeterminate\"), (disabled || disableCheckbox) && \"\".concat(prefixCls, \"-checkbox-disabled\")),\n onClick: _this.onCheck\n }, $custom);\n };\n\n _this.renderIcon = function () {\n var loading = _this.props.loading;\n var prefixCls = _this.props.context.prefixCls;\n return React.createElement(\"span\", {\n className: classNames(\"\".concat(prefixCls, \"-iconEle\"), \"\".concat(prefixCls, \"-icon__\").concat(_this.getNodeState() || 'docu'), loading && \"\".concat(prefixCls, \"-icon_loading\"))\n });\n }; // Icon + Title\n\n\n _this.renderSelector = function () {\n var dragNodeHighlight = _this.state.dragNodeHighlight;\n var _this$props5 = _this.props,\n title = _this$props5.title,\n selected = _this$props5.selected,\n icon = _this$props5.icon,\n loading = _this$props5.loading,\n data = _this$props5.data;\n var _this$props$context3 = _this.props.context,\n prefixCls = _this$props$context3.prefixCls,\n showIcon = _this$props$context3.showIcon,\n treeIcon = _this$props$context3.icon,\n draggable = _this$props$context3.draggable,\n loadData = _this$props$context3.loadData,\n titleRender = _this$props$context3.titleRender;\n\n var disabled = _this.isDisabled();\n\n var wrapClass = \"\".concat(prefixCls, \"-node-content-wrapper\"); // Icon - Still show loading icon when loading without showIcon\n\n var $icon;\n\n if (showIcon) {\n var currentIcon = icon || treeIcon;\n $icon = currentIcon ? React.createElement(\"span\", {\n className: classNames(\"\".concat(prefixCls, \"-iconEle\"), \"\".concat(prefixCls, \"-icon__customize\"))\n }, typeof currentIcon === 'function' ? currentIcon(_this.props) : currentIcon) : _this.renderIcon();\n } else if (loadData && loading) {\n $icon = _this.renderIcon();\n } // Title\n\n\n var titleNode;\n\n if (typeof title === 'function') {\n titleNode = title(data);\n } else if (titleRender) {\n titleNode = titleRender(data);\n } else {\n titleNode = title;\n }\n\n var $title = React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-title\")\n }, titleNode);\n return React.createElement(\"span\", {\n ref: _this.setSelectHandle,\n title: typeof title === 'string' ? title : '',\n className: classNames(\"\".concat(wrapClass), \"\".concat(wrapClass, \"-\").concat(_this.getNodeState() || 'normal'), !disabled && (selected || dragNodeHighlight) && \"\".concat(prefixCls, \"-node-selected\"), !disabled && draggable && 'draggable'),\n draggable: !disabled && draggable || undefined,\n \"aria-grabbed\": !disabled && draggable || undefined,\n onMouseEnter: _this.onMouseEnter,\n onMouseLeave: _this.onMouseLeave,\n onContextMenu: _this.onContextMenu,\n onClick: _this.onSelectorClick,\n onDoubleClick: _this.onSelectorDoubleClick,\n onDragStart: draggable ? _this.onDragStart : undefined\n }, $icon, $title);\n };\n\n return _this;\n } // Isomorphic needn't load data in server side\n\n\n _createClass(InternalTreeNode, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.syncLoadData(this.props);\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {\n this.syncLoadData(this.props);\n }\n }, {\n key: \"isSelectable\",\n value: function isSelectable() {\n var selectable = this.props.selectable;\n var treeSelectable = this.props.context.selectable; // Ignore when selectable is undefined or null\n\n if (typeof selectable === 'boolean') {\n return selectable;\n }\n\n return treeSelectable;\n }\n }, {\n key: \"render\",\n value: function render() {\n var _classNames;\n\n var _this$props6 = this.props,\n eventKey = _this$props6.eventKey,\n className = _this$props6.className,\n style = _this$props6.style,\n dragOver = _this$props6.dragOver,\n dragOverGapTop = _this$props6.dragOverGapTop,\n dragOverGapBottom = _this$props6.dragOverGapBottom,\n isLeaf = _this$props6.isLeaf,\n isStart = _this$props6.isStart,\n isEnd = _this$props6.isEnd,\n expanded = _this$props6.expanded,\n selected = _this$props6.selected,\n checked = _this$props6.checked,\n halfChecked = _this$props6.halfChecked,\n loading = _this$props6.loading,\n domRef = _this$props6.domRef,\n active = _this$props6.active,\n onMouseMove = _this$props6.onMouseMove,\n otherProps = _objectWithoutProperties(_this$props6, [\"eventKey\", \"className\", \"style\", \"dragOver\", \"dragOverGapTop\", \"dragOverGapBottom\", \"isLeaf\", \"isStart\", \"isEnd\", \"expanded\", \"selected\", \"checked\", \"halfChecked\", \"loading\", \"domRef\", \"active\", \"onMouseMove\"]);\n\n var _this$props$context4 = this.props.context,\n prefixCls = _this$props$context4.prefixCls,\n filterTreeNode = _this$props$context4.filterTreeNode,\n draggable = _this$props$context4.draggable,\n keyEntities = _this$props$context4.keyEntities;\n var disabled = this.isDisabled();\n var dataOrAriaAttributeProps = getDataAndAria(otherProps);\n\n var _ref2 = keyEntities[eventKey] || {},\n level = _ref2.level;\n\n var isEndNode = isEnd[isEnd.length - 1];\n return React.createElement(\"div\", Object.assign({\n ref: domRef,\n className: classNames(className, \"\".concat(prefixCls, \"-treenode\"), (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-treenode-disabled\"), disabled), _defineProperty(_classNames, \"\".concat(prefixCls, \"-treenode-switcher-\").concat(expanded ? 'open' : 'close'), !isLeaf), _defineProperty(_classNames, \"\".concat(prefixCls, \"-treenode-checkbox-checked\"), checked), _defineProperty(_classNames, \"\".concat(prefixCls, \"-treenode-checkbox-indeterminate\"), halfChecked), _defineProperty(_classNames, \"\".concat(prefixCls, \"-treenode-selected\"), selected), _defineProperty(_classNames, \"\".concat(prefixCls, \"-treenode-loading\"), loading), _defineProperty(_classNames, \"\".concat(prefixCls, \"-treenode-active\"), active), _defineProperty(_classNames, \"\".concat(prefixCls, \"-treenode-leaf-last\"), isEndNode), _defineProperty(_classNames, 'drag-over', !disabled && dragOver), _defineProperty(_classNames, 'drag-over-gap-top', !disabled && dragOverGapTop), _defineProperty(_classNames, 'drag-over-gap-bottom', !disabled && dragOverGapBottom), _defineProperty(_classNames, 'filter-node', filterTreeNode && filterTreeNode(convertNodePropsToEventData(this.props))), _classNames)),\n style: style,\n onDragEnter: draggable ? this.onDragEnter : undefined,\n onDragOver: draggable ? this.onDragOver : undefined,\n onDragLeave: draggable ? this.onDragLeave : undefined,\n onDrop: draggable ? this.onDrop : undefined,\n onDragEnd: draggable ? this.onDragEnd : undefined,\n onMouseMove: onMouseMove\n }, dataOrAriaAttributeProps), React.createElement(Indent, {\n prefixCls: prefixCls,\n level: level,\n isStart: isStart,\n isEnd: isEnd\n }), this.renderSwitcher(), this.renderCheckbox(), this.renderSelector());\n }\n }]);\n\n return InternalTreeNode;\n}(React.Component);\n\nvar ContextTreeNode = function ContextTreeNode(props) {\n return React.createElement(TreeContext.Consumer, null, function (context) {\n return React.createElement(InternalTreeNode, Object.assign({}, props, {\n context: context\n }));\n });\n};\n\nContextTreeNode.displayName = 'TreeNode';\nContextTreeNode.defaultProps = {\n title: defaultTitle\n};\nContextTreeNode.isTreeNode = 1;\nexport { InternalTreeNode };\nexport default ContextTreeNode;","function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }\n\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\n\nfunction _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === \"string\") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === \"Object\" && o.constructor) n = o.constructor.name; if (n === \"Map\" || n === \"Set\") return Array.from(o); if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }\n\nfunction _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }\n\nfunction _iterableToArrayLimit(arr, i) { if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i[\"return\"] != null) _i[\"return\"](); } finally { if (_d) throw _e; } } return _arr; }\n\nfunction _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }\n\nimport * as React from 'react';\nexport default function useControlledState(defaultStateValue, option) {\n var _ref = option || {},\n defaultValue = _ref.defaultValue,\n value = _ref.value,\n onChange = _ref.onChange,\n postState = _ref.postState;\n\n var _React$useState = React.useState(function () {\n if (value !== undefined) {\n return value;\n }\n\n if (defaultValue !== undefined) {\n return typeof defaultValue === 'function' ? defaultValue() : defaultValue;\n }\n\n return typeof defaultStateValue === 'function' ? defaultStateValue() : defaultStateValue;\n }),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n innerValue = _React$useState2[0],\n setInnerValue = _React$useState2[1];\n\n var mergedValue = value !== undefined ? value : innerValue;\n\n if (postState) {\n mergedValue = postState(mergedValue);\n }\n\n function triggerChange(newValue) {\n setInnerValue(newValue);\n\n if (mergedValue !== newValue && onChange) {\n onChange(newValue, mergedValue);\n }\n } // Effect of reset value to `undefined`\n\n\n var firstRenderRef = React.useRef(true);\n React.useEffect(function () {\n if (firstRenderRef.current) {\n firstRenderRef.current = false;\n return;\n }\n\n if (value === undefined) {\n setInnerValue(value);\n }\n }, [value]);\n return [mergedValue, triggerChange];\n}","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n\n return target;\n}","import * as React from 'react';\nimport { ConfigContext } from '../config-provider';\n\nvar Empty = function Empty() {\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls;\n\n var prefixCls = getPrefixCls('empty-img-default');\n return /*#__PURE__*/React.createElement(\"svg\", {\n className: prefixCls,\n width: \"184\",\n height: \"152\",\n viewBox: \"0 0 184 152\",\n xmlns: \"http://www.w3.org/2000/svg\"\n }, /*#__PURE__*/React.createElement(\"g\", {\n fill: \"none\",\n fillRule: \"evenodd\"\n }, /*#__PURE__*/React.createElement(\"g\", {\n transform: \"translate(24 31.67)\"\n }, /*#__PURE__*/React.createElement(\"ellipse\", {\n className: \"\".concat(prefixCls, \"-ellipse\"),\n cx: \"67.797\",\n cy: \"106.89\",\n rx: \"67.797\",\n ry: \"12.668\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n className: \"\".concat(prefixCls, \"-path-1\"),\n d: \"M122.034 69.674L98.109 40.229c-1.148-1.386-2.826-2.225-4.593-2.225h-51.44c-1.766 0-3.444.839-4.592 2.225L13.56 69.674v15.383h108.475V69.674z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n className: \"\".concat(prefixCls, \"-path-2\"),\n d: \"M101.537 86.214L80.63 61.102c-1.001-1.207-2.507-1.867-4.048-1.867H31.724c-1.54 0-3.047.66-4.048 1.867L6.769 86.214v13.792h94.768V86.214z\",\n transform: \"translate(13.56)\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n className: \"\".concat(prefixCls, \"-path-3\"),\n d: \"M33.83 0h67.933a4 4 0 0 1 4 4v93.344a4 4 0 0 1-4 4H33.83a4 4 0 0 1-4-4V4a4 4 0 0 1 4-4z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n className: \"\".concat(prefixCls, \"-path-4\"),\n d: \"M42.678 9.953h50.237a2 2 0 0 1 2 2V36.91a2 2 0 0 1-2 2H42.678a2 2 0 0 1-2-2V11.953a2 2 0 0 1 2-2zM42.94 49.767h49.713a2.262 2.262 0 1 1 0 4.524H42.94a2.262 2.262 0 0 1 0-4.524zM42.94 61.53h49.713a2.262 2.262 0 1 1 0 4.525H42.94a2.262 2.262 0 0 1 0-4.525zM121.813 105.032c-.775 3.071-3.497 5.36-6.735 5.36H20.515c-3.238 0-5.96-2.29-6.734-5.36a7.309 7.309 0 0 1-.222-1.79V69.675h26.318c2.907 0 5.25 2.448 5.25 5.42v.04c0 2.971 2.37 5.37 5.277 5.37h34.785c2.907 0 5.277-2.421 5.277-5.393V75.1c0-2.972 2.343-5.426 5.25-5.426h26.318v33.569c0 .617-.077 1.216-.221 1.789z\"\n })), /*#__PURE__*/React.createElement(\"path\", {\n className: \"\".concat(prefixCls, \"-path-5\"),\n d: \"M149.121 33.292l-6.83 2.65a1 1 0 0 1-1.317-1.23l1.937-6.207c-2.589-2.944-4.109-6.534-4.109-10.408C138.802 8.102 148.92 0 161.402 0 173.881 0 184 8.102 184 18.097c0 9.995-10.118 18.097-22.599 18.097-4.528 0-8.744-1.066-12.28-2.902z\"\n }), /*#__PURE__*/React.createElement(\"g\", {\n className: \"\".concat(prefixCls, \"-g\"),\n transform: \"translate(149.65 15.383)\"\n }, /*#__PURE__*/React.createElement(\"ellipse\", {\n cx: \"20.654\",\n cy: \"3.167\",\n rx: \"2.849\",\n ry: \"2.815\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M5.698 5.63H0L2.898.704zM9.259.704h4.985V5.63H9.259z\"\n }))));\n};\n\nexport default Empty;","import * as React from 'react';\nimport { ConfigContext } from '../config-provider';\n\nvar Simple = function Simple() {\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls;\n\n var prefixCls = getPrefixCls('empty-img-simple');\n return /*#__PURE__*/React.createElement(\"svg\", {\n className: prefixCls,\n width: \"64\",\n height: \"41\",\n viewBox: \"0 0 64 41\",\n xmlns: \"http://www.w3.org/2000/svg\"\n }, /*#__PURE__*/React.createElement(\"g\", {\n transform: \"translate(0 1)\",\n fill: \"none\",\n fillRule: \"evenodd\"\n }, /*#__PURE__*/React.createElement(\"ellipse\", {\n className: \"\".concat(prefixCls, \"-ellipse\"),\n cx: \"32\",\n cy: \"33\",\n rx: \"32\",\n ry: \"7\"\n }), /*#__PURE__*/React.createElement(\"g\", {\n className: \"\".concat(prefixCls, \"-g\"),\n fillRule: \"nonzero\"\n }, /*#__PURE__*/React.createElement(\"path\", {\n d: \"M55 12.76L44.854 1.258C44.367.474 43.656 0 42.907 0H21.093c-.749 0-1.46.474-1.947 1.257L9 12.761V22h46v-9.24z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M41.613 15.931c0-1.605.994-2.93 2.227-2.931H55v18.137C55 33.26 53.68 35 52.05 35h-40.1C10.32 35 9 33.259 9 31.137V13h11.16c1.233 0 2.227 1.323 2.227 2.928v.022c0 1.605 1.005 2.901 2.237 2.901h14.752c1.232 0 2.237-1.308 2.237-2.913v-.007z\",\n className: \"\".concat(prefixCls, \"-path\")\n }))));\n};\n\nexport default Simple;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { ConfigConsumer } from '../config-provider';\nimport LocaleReceiver from '../locale-provider/LocaleReceiver';\nimport DefaultEmptyImg from './empty';\nimport SimpleEmptyImg from './simple';\nvar defaultEmptyImg = /*#__PURE__*/React.createElement(DefaultEmptyImg, null);\nvar simpleEmptyImg = /*#__PURE__*/React.createElement(SimpleEmptyImg, null);\n\nvar Empty = function Empty(props) {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, function (_ref) {\n var getPrefixCls = _ref.getPrefixCls,\n direction = _ref.direction;\n\n var className = props.className,\n customizePrefixCls = props.prefixCls,\n _props$image = props.image,\n image = _props$image === void 0 ? defaultEmptyImg : _props$image,\n description = props.description,\n children = props.children,\n imageStyle = props.imageStyle,\n restProps = __rest(props, [\"className\", \"prefixCls\", \"image\", \"description\", \"children\", \"imageStyle\"]);\n\n return /*#__PURE__*/React.createElement(LocaleReceiver, {\n componentName: \"Empty\"\n }, function (locale) {\n var _classNames;\n\n var prefixCls = getPrefixCls('empty', customizePrefixCls);\n var des = typeof description !== 'undefined' ? description : locale.description;\n var alt = typeof des === 'string' ? des : 'empty';\n var imageNode = null;\n\n if (typeof image === 'string') {\n imageNode = /*#__PURE__*/React.createElement(\"img\", {\n alt: alt,\n src: image\n });\n } else {\n imageNode = image;\n }\n\n return /*#__PURE__*/React.createElement(\"div\", _extends({\n className: classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-normal\"), image === simpleEmptyImg), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _classNames), className)\n }, restProps), /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-image\"),\n style: imageStyle\n }, imageNode), des && /*#__PURE__*/React.createElement(\"p\", {\n className: \"\".concat(prefixCls, \"-description\")\n }, des), children && /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-footer\")\n }, children));\n });\n });\n};\n\nEmpty.PRESENTED_IMAGE_DEFAULT = defaultEmptyImg;\nEmpty.PRESENTED_IMAGE_SIMPLE = simpleEmptyImg;\nexport default Empty;","module.exports = require(\"regenerator-runtime\");\n","export default function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nexport default function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _CloseCircleFilled = _interopRequireDefault(require('./lib/icons/CloseCircleFilled'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _CloseCircleFilled;\n exports.default = _default;\n module.exports = _default;","function _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n}\n\nmodule.exports = _assertThisInitialized;","import ReactDOM from 'react-dom';\n/**\n * Return if a node is a DOM node. Else will return by `findDOMNode`\n */\n\nexport default function findDOMNode(node) {\n if (node instanceof HTMLElement) {\n return node;\n }\n\n return ReactDOM.findDOMNode(node);\n}","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport * as React from 'react';\nimport findDOMNode from \"rc-util/es/Dom/findDOMNode\";\nimport toArray from \"rc-util/es/Children/toArray\";\nimport warning from \"rc-util/es/warning\";\nimport { composeRef, supportRef } from \"rc-util/es/ref\";\nimport ResizeObserver from 'resize-observer-polyfill';\nvar INTERNAL_PREFIX_KEY = 'rc-observer-key'; // Still need to be compatible with React 15, we use class component here\n\nvar ReactResizeObserver = /*#__PURE__*/function (_React$Component) {\n _inherits(ReactResizeObserver, _React$Component);\n\n var _super = _createSuper(ReactResizeObserver);\n\n function ReactResizeObserver() {\n var _this;\n\n _classCallCheck(this, ReactResizeObserver);\n\n _this = _super.apply(this, arguments);\n _this.resizeObserver = null;\n _this.childNode = null;\n _this.currentElement = null;\n _this.state = {\n width: 0,\n height: 0,\n offsetHeight: 0,\n offsetWidth: 0\n };\n\n _this.onResize = function (entries) {\n var onResize = _this.props.onResize;\n var target = entries[0].target;\n\n var _target$getBoundingCl = target.getBoundingClientRect(),\n width = _target$getBoundingCl.width,\n height = _target$getBoundingCl.height;\n\n var offsetWidth = target.offsetWidth,\n offsetHeight = target.offsetHeight;\n /**\n * Resize observer trigger when content size changed.\n * In most case we just care about element size,\n * let's use `boundary` instead of `contentRect` here to avoid shaking.\n */\n\n var fixedWidth = Math.floor(width);\n var fixedHeight = Math.floor(height);\n\n if (_this.state.width !== fixedWidth || _this.state.height !== fixedHeight || _this.state.offsetWidth !== offsetWidth || _this.state.offsetHeight !== offsetHeight) {\n var size = {\n width: fixedWidth,\n height: fixedHeight,\n offsetWidth: offsetWidth,\n offsetHeight: offsetHeight\n };\n\n _this.setState(size);\n\n if (onResize) {\n // defer the callback but not defer to next frame\n Promise.resolve().then(function () {\n onResize(_objectSpread(_objectSpread({}, size), {}, {\n offsetWidth: offsetWidth,\n offsetHeight: offsetHeight\n }));\n });\n }\n }\n };\n\n _this.setChildNode = function (node) {\n _this.childNode = node;\n };\n\n return _this;\n }\n\n _createClass(ReactResizeObserver, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.onComponentUpdated();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {\n this.onComponentUpdated();\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n this.destroyObserver();\n }\n }, {\n key: \"onComponentUpdated\",\n value: function onComponentUpdated() {\n var disabled = this.props.disabled; // Unregister if disabled\n\n if (disabled) {\n this.destroyObserver();\n return;\n } // Unregister if element changed\n\n\n var element = findDOMNode(this.childNode || this);\n var elementChanged = element !== this.currentElement;\n\n if (elementChanged) {\n this.destroyObserver();\n this.currentElement = element;\n }\n\n if (!this.resizeObserver && element) {\n this.resizeObserver = new ResizeObserver(this.onResize);\n this.resizeObserver.observe(element);\n }\n }\n }, {\n key: \"destroyObserver\",\n value: function destroyObserver() {\n if (this.resizeObserver) {\n this.resizeObserver.disconnect();\n this.resizeObserver = null;\n }\n }\n }, {\n key: \"render\",\n value: function render() {\n var children = this.props.children;\n var childNodes = toArray(children);\n\n if (childNodes.length > 1) {\n warning(false, 'Find more than one child node with `children` in ResizeObserver. Will only observe first one.');\n } else if (childNodes.length === 0) {\n warning(false, '`children` of ResizeObserver is empty. Nothing is in observe.');\n return null;\n }\n\n var childNode = childNodes[0];\n\n if (React.isValidElement(childNode) && supportRef(childNode)) {\n var ref = childNode.ref;\n childNodes[0] = React.cloneElement(childNode, {\n ref: composeRef(ref, this.setChildNode)\n });\n }\n\n return childNodes.length === 1 ? childNodes[0] : childNodes.map(function (node, index) {\n if (!React.isValidElement(node) || 'key' in node && node.key !== null) {\n return node;\n }\n\n return React.cloneElement(node, {\n key: \"\".concat(INTERNAL_PREFIX_KEY, \"-\").concat(index)\n });\n });\n }\n }]);\n\n return ReactResizeObserver;\n}(React.Component);\n\nReactResizeObserver.displayName = 'ResizeObserver';\nexport default ReactResizeObserver;","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\n\nfunction isPointsEq(a1, a2, isAlignPoint) {\n if (isAlignPoint) {\n return a1[0] === a2[0];\n }\n\n return a1[0] === a2[0] && a1[1] === a2[1];\n}\n\nexport function getAlignFromPlacement(builtinPlacements, placementStr, align) {\n var baseAlign = builtinPlacements[placementStr] || {};\n return _objectSpread(_objectSpread({}, baseAlign), align);\n}\nexport function getAlignPopupClassName(builtinPlacements, prefixCls, align, isAlignPoint) {\n var points = align.points;\n var placements = Object.keys(builtinPlacements);\n\n for (var i = 0; i < placements.length; i += 1) {\n var placement = placements[i];\n\n if (isPointsEq(builtinPlacements[placement].points, points, isAlignPoint)) {\n return \"\".concat(prefixCls, \"-placement-\").concat(placement);\n }\n }\n\n return '';\n}","let vendorPrefix;\n\nconst jsCssMap = {\n Webkit: '-webkit-',\n Moz: '-moz-',\n // IE did it wrong again ...\n ms: '-ms-',\n O: '-o-',\n};\n\nfunction getVendorPrefix() {\n if (vendorPrefix !== undefined) {\n return vendorPrefix;\n }\n vendorPrefix = '';\n const style = document.createElement('p').style;\n const testProp = 'Transform';\n for (const key in jsCssMap) {\n if (key + testProp in style) {\n vendorPrefix = key;\n }\n }\n return vendorPrefix;\n}\n\nfunction getTransitionName() {\n return getVendorPrefix()\n ? `${getVendorPrefix()}TransitionProperty`\n : 'transitionProperty';\n}\n\nexport function getTransformName() {\n return getVendorPrefix() ? `${getVendorPrefix()}Transform` : 'transform';\n}\n\nexport function setTransitionProperty(node, value) {\n const name = getTransitionName();\n if (name) {\n node.style[name] = value;\n if (name !== 'transitionProperty') {\n node.style.transitionProperty = value;\n }\n }\n}\n\nfunction setTransform(node, value) {\n const name = getTransformName();\n if (name) {\n node.style[name] = value;\n if (name !== 'transform') {\n node.style.transform = value;\n }\n }\n}\n\nexport function getTransitionProperty(node) {\n return node.style.transitionProperty || node.style[getTransitionName()];\n}\n\nexport function getTransformXY(node) {\n const style = window.getComputedStyle(node, null);\n const transform =\n style.getPropertyValue('transform') ||\n style.getPropertyValue(getTransformName());\n if (transform && transform !== 'none') {\n const matrix = transform.replace(/[^0-9\\-.,]/g, '').split(',');\n return {\n x: parseFloat(matrix[12] || matrix[4], 0),\n y: parseFloat(matrix[13] || matrix[5], 0),\n };\n }\n return {\n x: 0,\n y: 0,\n };\n}\n\nconst matrix2d = /matrix\\((.*)\\)/;\nconst matrix3d = /matrix3d\\((.*)\\)/;\n\nexport function setTransformXY(node, xy) {\n const style = window.getComputedStyle(node, null);\n const transform =\n style.getPropertyValue('transform') ||\n style.getPropertyValue(getTransformName());\n if (transform && transform !== 'none') {\n let arr;\n let match2d = transform.match(matrix2d);\n if (match2d) {\n match2d = match2d[1];\n arr = match2d.split(',').map(item => {\n return parseFloat(item, 10);\n });\n arr[4] = xy.x;\n arr[5] = xy.y;\n setTransform(node, `matrix(${arr.join(',')})`);\n } else {\n const match3d = transform.match(matrix3d)[1];\n arr = match3d.split(',').map(item => {\n return parseFloat(item, 10);\n });\n arr[12] = xy.x;\n arr[13] = xy.y;\n setTransform(node, `matrix3d(${arr.join(',')})`);\n }\n } else {\n setTransform(\n node,\n `translateX(${xy.x}px) translateY(${xy.y}px) translateZ(0)`,\n );\n }\n}\n","import {\n setTransitionProperty,\n getTransitionProperty,\n getTransformXY,\n setTransformXY,\n getTransformName,\n} from './propertyUtils';\n\nconst RE_NUM = /[\\-+]?(?:\\d*\\.|)\\d+(?:[eE][\\-+]?\\d+|)/.source;\n\nlet getComputedStyleX;\n\n// https://stackoverflow.com/a/3485654/3040605\nfunction forceRelayout(elem) {\n const originalStyle = elem.style.display;\n elem.style.display = 'none';\n elem.offsetHeight; // eslint-disable-line\n elem.style.display = originalStyle;\n}\n\nfunction css(el, name, v) {\n let value = v;\n if (typeof name === 'object') {\n for (const i in name) {\n if (name.hasOwnProperty(i)) {\n css(el, i, name[i]);\n }\n }\n return undefined;\n }\n if (typeof value !== 'undefined') {\n if (typeof value === 'number') {\n value = `${value}px`;\n }\n el.style[name] = value;\n return undefined;\n }\n return getComputedStyleX(el, name);\n}\n\nfunction getClientPosition(elem) {\n let box;\n let x;\n let y;\n const doc = elem.ownerDocument;\n const body = doc.body;\n const docElem = doc && doc.documentElement;\n // 根据 GBS 最新数据,A-Grade Browsers 都已支持 getBoundingClientRect 方法,不用再考虑传统的实现方式\n box = elem.getBoundingClientRect();\n\n // 注:jQuery 还考虑减去 docElem.clientLeft/clientTop\n // 但测试发现,这样反而会导致当 html 和 body 有边距/边框样式时,获取的值不正确\n // 此外,ie6 会忽略 html 的 margin 值,幸运地是没有谁会去设置 html 的 margin\n\n x = box.left;\n y = box.top;\n\n // In IE, most of the time, 2 extra pixels are added to the top and left\n // due to the implicit 2-pixel inset border. In IE6/7 quirks mode and\n // IE6 standards mode, this border can be overridden by setting the\n // document element's border to zero -- thus, we cannot rely on the\n // offset always being 2 pixels.\n\n // In quirks mode, the offset can be determined by querying the body's\n // clientLeft/clientTop, but in standards mode, it is found by querying\n // the document element's clientLeft/clientTop. Since we already called\n // getClientBoundingRect we have already forced a reflow, so it is not\n // too expensive just to query them all.\n\n // ie 下应该减去窗口的边框吧,毕竟默认 absolute 都是相对窗口定位的\n // 窗口边框标准是设 documentElement ,quirks 时设置 body\n // 最好禁止在 body 和 html 上边框 ,但 ie < 9 html 默认有 2px ,减去\n // 但是非 ie 不可能设置窗口边框,body html 也不是窗口 ,ie 可以通过 html,body 设置\n // 标准 ie 下 docElem.clientTop 就是 border-top\n // ie7 html 即窗口边框改变不了。永远为 2\n // 但标准 firefox/chrome/ie9 下 docElem.clientTop 是窗口边框,即使设了 border-top 也为 0\n\n x -= docElem.clientLeft || body.clientLeft || 0;\n y -= docElem.clientTop || body.clientTop || 0;\n\n return {\n left: x,\n top: y,\n };\n}\n\nfunction getScroll(w, top) {\n let ret = w[`page${top ? 'Y' : 'X'}Offset`];\n const method = `scroll${top ? 'Top' : 'Left'}`;\n if (typeof ret !== 'number') {\n const d = w.document;\n // ie6,7,8 standard mode\n ret = d.documentElement[method];\n if (typeof ret !== 'number') {\n // quirks mode\n ret = d.body[method];\n }\n }\n return ret;\n}\n\nfunction getScrollLeft(w) {\n return getScroll(w);\n}\n\nfunction getScrollTop(w) {\n return getScroll(w, true);\n}\n\nfunction getOffset(el) {\n const pos = getClientPosition(el);\n const doc = el.ownerDocument;\n const w = doc.defaultView || doc.parentWindow;\n pos.left += getScrollLeft(w);\n pos.top += getScrollTop(w);\n return pos;\n}\n\n/**\n * A crude way of determining if an object is a window\n * @member util\n */\nfunction isWindow(obj) {\n // must use == for ie8\n /* eslint eqeqeq:0 */\n return obj !== null && obj !== undefined && obj == obj.window;\n}\n\nfunction getDocument(node) {\n if (isWindow(node)) {\n return node.document;\n }\n if (node.nodeType === 9) {\n return node;\n }\n return node.ownerDocument;\n}\n\nfunction _getComputedStyle(elem, name, cs) {\n let computedStyle = cs;\n let val = '';\n const d = getDocument(elem);\n computedStyle = computedStyle || d.defaultView.getComputedStyle(elem, null);\n\n // https://github.com/kissyteam/kissy/issues/61\n if (computedStyle) {\n val = computedStyle.getPropertyValue(name) || computedStyle[name];\n }\n\n return val;\n}\n\nconst _RE_NUM_NO_PX = new RegExp(`^(${RE_NUM})(?!px)[a-z%]+$`, 'i');\nconst RE_POS = /^(top|right|bottom|left)$/;\nconst CURRENT_STYLE = 'currentStyle';\nconst RUNTIME_STYLE = 'runtimeStyle';\nconst LEFT = 'left';\nconst PX = 'px';\n\nfunction _getComputedStyleIE(elem, name) {\n // currentStyle maybe null\n // http://msdn.microsoft.com/en-us/library/ms535231.aspx\n let ret = elem[CURRENT_STYLE] && elem[CURRENT_STYLE][name];\n\n // 当 width/height 设置为百分比时,通过 pixelLeft 方式转换的 width/height 值\n // 一开始就处理了! CUSTOM_STYLE.height,CUSTOM_STYLE.width ,cssHook 解决@2011-08-19\n // 在 ie 下不对,需要直接用 offset 方式\n // borderWidth 等值也有问题,但考虑到 borderWidth 设为百分比的概率很小,这里就不考虑了\n\n // From the awesome hack by Dean Edwards\n // http://erik.eae.net/archives/2007/07/27/18.54.15/#comment-102291\n // If we're not dealing with a regular pixel number\n // but a number that has a weird ending, we need to convert it to pixels\n // exclude left right for relativity\n if (_RE_NUM_NO_PX.test(ret) && !RE_POS.test(name)) {\n // Remember the original values\n const style = elem.style;\n const left = style[LEFT];\n const rsLeft = elem[RUNTIME_STYLE][LEFT];\n\n // prevent flashing of content\n elem[RUNTIME_STYLE][LEFT] = elem[CURRENT_STYLE][LEFT];\n\n // Put in the new values to get a computed value out\n style[LEFT] = name === 'fontSize' ? '1em' : ret || 0;\n ret = style.pixelLeft + PX;\n\n // Revert the changed values\n style[LEFT] = left;\n\n elem[RUNTIME_STYLE][LEFT] = rsLeft;\n }\n return ret === '' ? 'auto' : ret;\n}\n\nif (typeof window !== 'undefined') {\n getComputedStyleX = window.getComputedStyle\n ? _getComputedStyle\n : _getComputedStyleIE;\n}\n\nfunction getOffsetDirection(dir, option) {\n if (dir === 'left') {\n return option.useCssRight ? 'right' : dir;\n }\n return option.useCssBottom ? 'bottom' : dir;\n}\n\nfunction oppositeOffsetDirection(dir) {\n if (dir === 'left') {\n return 'right';\n } else if (dir === 'right') {\n return 'left';\n } else if (dir === 'top') {\n return 'bottom';\n } else if (dir === 'bottom') {\n return 'top';\n }\n}\n\n// 设置 elem 相对 elem.ownerDocument 的坐标\nfunction setLeftTop(elem, offset, option) {\n // set position first, in-case top/left are set even on static elem\n if (css(elem, 'position') === 'static') {\n elem.style.position = 'relative';\n }\n let presetH = -999;\n let presetV = -999;\n const horizontalProperty = getOffsetDirection('left', option);\n const verticalProperty = getOffsetDirection('top', option);\n const oppositeHorizontalProperty = oppositeOffsetDirection(\n horizontalProperty,\n );\n const oppositeVerticalProperty = oppositeOffsetDirection(verticalProperty);\n\n if (horizontalProperty !== 'left') {\n presetH = 999;\n }\n\n if (verticalProperty !== 'top') {\n presetV = 999;\n }\n let originalTransition = '';\n const originalOffset = getOffset(elem);\n if ('left' in offset || 'top' in offset) {\n originalTransition = getTransitionProperty(elem) || '';\n setTransitionProperty(elem, 'none');\n }\n if ('left' in offset) {\n elem.style[oppositeHorizontalProperty] = '';\n elem.style[horizontalProperty] = `${presetH}px`;\n }\n if ('top' in offset) {\n elem.style[oppositeVerticalProperty] = '';\n elem.style[verticalProperty] = `${presetV}px`;\n }\n // force relayout\n forceRelayout(elem);\n const old = getOffset(elem);\n const originalStyle = {};\n for (const key in offset) {\n if (offset.hasOwnProperty(key)) {\n const dir = getOffsetDirection(key, option);\n const preset = key === 'left' ? presetH : presetV;\n const off = originalOffset[key] - old[key];\n if (dir === key) {\n originalStyle[dir] = preset + off;\n } else {\n originalStyle[dir] = preset - off;\n }\n }\n }\n css(elem, originalStyle);\n // force relayout\n forceRelayout(elem);\n if ('left' in offset || 'top' in offset) {\n setTransitionProperty(elem, originalTransition);\n }\n const ret = {};\n for (const key in offset) {\n if (offset.hasOwnProperty(key)) {\n const dir = getOffsetDirection(key, option);\n const off = offset[key] - originalOffset[key];\n if (key === dir) {\n ret[dir] = originalStyle[dir] + off;\n } else {\n ret[dir] = originalStyle[dir] - off;\n }\n }\n }\n css(elem, ret);\n}\n\nfunction setTransform(elem, offset) {\n const originalOffset = getOffset(elem);\n const originalXY = getTransformXY(elem);\n const resultXY = { x: originalXY.x, y: originalXY.y };\n if ('left' in offset) {\n resultXY.x = originalXY.x + offset.left - originalOffset.left;\n }\n if ('top' in offset) {\n resultXY.y = originalXY.y + offset.top - originalOffset.top;\n }\n setTransformXY(elem, resultXY);\n}\n\nfunction setOffset(elem, offset, option) {\n if (option.ignoreShake) {\n const oriOffset = getOffset(elem);\n\n const oLeft = oriOffset.left.toFixed(0);\n const oTop = oriOffset.top.toFixed(0);\n const tLeft = offset.left.toFixed(0);\n const tTop = offset.top.toFixed(0);\n\n if (oLeft === tLeft && oTop === tTop) {\n return;\n }\n }\n\n if (option.useCssRight || option.useCssBottom) {\n setLeftTop(elem, offset, option);\n } else if (\n option.useCssTransform &&\n getTransformName() in document.body.style\n ) {\n setTransform(elem, offset, option);\n } else {\n setLeftTop(elem, offset, option);\n }\n}\n\nfunction each(arr, fn) {\n for (let i = 0; i < arr.length; i++) {\n fn(arr[i]);\n }\n}\n\nfunction isBorderBoxFn(elem) {\n return getComputedStyleX(elem, 'boxSizing') === 'border-box';\n}\n\nconst BOX_MODELS = ['margin', 'border', 'padding'];\nconst CONTENT_INDEX = -1;\nconst PADDING_INDEX = 2;\nconst BORDER_INDEX = 1;\nconst MARGIN_INDEX = 0;\n\nfunction swap(elem, options, callback) {\n const old = {};\n const style = elem.style;\n let name;\n\n // Remember the old values, and insert the new ones\n for (name in options) {\n if (options.hasOwnProperty(name)) {\n old[name] = style[name];\n style[name] = options[name];\n }\n }\n\n callback.call(elem);\n\n // Revert the old values\n for (name in options) {\n if (options.hasOwnProperty(name)) {\n style[name] = old[name];\n }\n }\n}\n\nfunction getPBMWidth(elem, props, which) {\n let value = 0;\n let prop;\n let j;\n let i;\n for (j = 0; j < props.length; j++) {\n prop = props[j];\n if (prop) {\n for (i = 0; i < which.length; i++) {\n let cssProp;\n if (prop === 'border') {\n cssProp = `${prop}${which[i]}Width`;\n } else {\n cssProp = prop + which[i];\n }\n value += parseFloat(getComputedStyleX(elem, cssProp)) || 0;\n }\n }\n }\n return value;\n}\n\nconst domUtils = {\n getParent(element) {\n let parent = element;\n do {\n if (parent.nodeType === 11 && parent.host) {\n parent = parent.host;\n } else {\n parent = parent.parentNode;\n }\n } while (parent && parent.nodeType !== 1 && parent.nodeType !== 9);\n return parent;\n },\n};\n\neach(['Width', 'Height'], name => {\n domUtils[`doc${name}`] = refWin => {\n const d = refWin.document;\n return Math.max(\n // firefox chrome documentElement.scrollHeight< body.scrollHeight\n // ie standard mode : documentElement.scrollHeight> body.scrollHeight\n d.documentElement[`scroll${name}`],\n // quirks : documentElement.scrollHeight 最大等于可视窗口多一点?\n d.body[`scroll${name}`],\n domUtils[`viewport${name}`](d),\n );\n };\n\n domUtils[`viewport${name}`] = win => {\n // pc browser includes scrollbar in window.innerWidth\n const prop = `client${name}`;\n const doc = win.document;\n const body = doc.body;\n const documentElement = doc.documentElement;\n const documentElementProp = documentElement[prop];\n // 标准模式取 documentElement\n // backcompat 取 body\n return (\n (doc.compatMode === 'CSS1Compat' && documentElementProp) ||\n (body && body[prop]) ||\n documentElementProp\n );\n };\n});\n\n/*\n 得到元素的大小信息\n @param elem\n @param name\n @param {String} [extra] 'padding' : (css width) + padding\n 'border' : (css width) + padding + border\n 'margin' : (css width) + padding + border + margin\n */\nfunction getWH(elem, name, ex) {\n let extra = ex;\n if (isWindow(elem)) {\n return name === 'width'\n ? domUtils.viewportWidth(elem)\n : domUtils.viewportHeight(elem);\n } else if (elem.nodeType === 9) {\n return name === 'width'\n ? domUtils.docWidth(elem)\n : domUtils.docHeight(elem);\n }\n const which = name === 'width' ? ['Left', 'Right'] : ['Top', 'Bottom'];\n let borderBoxValue =\n name === 'width'\n ? elem.getBoundingClientRect().width\n : elem.getBoundingClientRect().height;\n const computedStyle = getComputedStyleX(elem);\n const isBorderBox = isBorderBoxFn(elem, computedStyle);\n let cssBoxValue = 0;\n if (\n borderBoxValue === null ||\n borderBoxValue === undefined ||\n borderBoxValue <= 0\n ) {\n borderBoxValue = undefined;\n // Fall back to computed then un computed css if necessary\n cssBoxValue = getComputedStyleX(elem, name);\n if (\n cssBoxValue === null ||\n cssBoxValue === undefined ||\n Number(cssBoxValue) < 0\n ) {\n cssBoxValue = elem.style[name] || 0;\n }\n // Normalize '', auto, and prepare for extra\n cssBoxValue = parseFloat(cssBoxValue) || 0;\n }\n if (extra === undefined) {\n extra = isBorderBox ? BORDER_INDEX : CONTENT_INDEX;\n }\n const borderBoxValueOrIsBorderBox =\n borderBoxValue !== undefined || isBorderBox;\n const val = borderBoxValue || cssBoxValue;\n if (extra === CONTENT_INDEX) {\n if (borderBoxValueOrIsBorderBox) {\n return (\n val - getPBMWidth(elem, ['border', 'padding'], which, computedStyle)\n );\n }\n return cssBoxValue;\n } else if (borderBoxValueOrIsBorderBox) {\n if (extra === BORDER_INDEX) {\n return val;\n }\n return (\n val +\n (extra === PADDING_INDEX\n ? -getPBMWidth(elem, ['border'], which, computedStyle)\n : getPBMWidth(elem, ['margin'], which, computedStyle))\n );\n }\n return (\n cssBoxValue +\n getPBMWidth(elem, BOX_MODELS.slice(extra), which, computedStyle)\n );\n}\n\nconst cssShow = {\n position: 'absolute',\n visibility: 'hidden',\n display: 'block',\n};\n\n// fix #119 : https://github.com/kissyteam/kissy/issues/119\nfunction getWHIgnoreDisplay(...args) {\n let val;\n const elem = args[0];\n // in case elem is window\n // elem.offsetWidth === undefined\n if (elem.offsetWidth !== 0) {\n val = getWH.apply(undefined, args);\n } else {\n swap(elem, cssShow, () => {\n val = getWH.apply(undefined, args);\n });\n }\n return val;\n}\n\neach(['width', 'height'], name => {\n const first = name.charAt(0).toUpperCase() + name.slice(1);\n domUtils[`outer${first}`] = (el, includeMargin) => {\n return (\n el &&\n getWHIgnoreDisplay(el, name, includeMargin ? MARGIN_INDEX : BORDER_INDEX)\n );\n };\n const which = name === 'width' ? ['Left', 'Right'] : ['Top', 'Bottom'];\n\n domUtils[name] = (elem, v) => {\n let val = v;\n if (val !== undefined) {\n if (elem) {\n const computedStyle = getComputedStyleX(elem);\n const isBorderBox = isBorderBoxFn(elem);\n if (isBorderBox) {\n val += getPBMWidth(elem, ['padding', 'border'], which, computedStyle);\n }\n return css(elem, name, val);\n }\n return undefined;\n }\n return elem && getWHIgnoreDisplay(elem, name, CONTENT_INDEX);\n };\n});\n\nfunction mix(to, from) {\n for (const i in from) {\n if (from.hasOwnProperty(i)) {\n to[i] = from[i];\n }\n }\n return to;\n}\n\nconst utils = {\n getWindow(node) {\n if (node && node.document && node.setTimeout) {\n return node;\n }\n const doc = node.ownerDocument || node;\n return doc.defaultView || doc.parentWindow;\n },\n getDocument,\n offset(el, value, option) {\n if (typeof value !== 'undefined') {\n setOffset(el, value, option || {});\n } else {\n return getOffset(el);\n }\n },\n isWindow,\n each,\n css,\n clone(obj) {\n let i;\n const ret = {};\n for (i in obj) {\n if (obj.hasOwnProperty(i)) {\n ret[i] = obj[i];\n }\n }\n const overflow = obj.overflow;\n if (overflow) {\n for (i in obj) {\n if (obj.hasOwnProperty(i)) {\n ret.overflow[i] = obj.overflow[i];\n }\n }\n }\n return ret;\n },\n mix,\n getWindowScrollLeft(w) {\n return getScrollLeft(w);\n },\n getWindowScrollTop(w) {\n return getScrollTop(w);\n },\n merge(...args) {\n const ret = {};\n for (let i = 0; i < args.length; i++) {\n utils.mix(ret, args[i]);\n }\n return ret;\n },\n viewportWidth: 0,\n viewportHeight: 0,\n};\n\nmix(utils, domUtils);\n\nexport default utils;\n","import utils from './utils';\n\n/**\n * 得到会导致元素显示不全的祖先元素\n */\nconst { getParent } = utils;\n\nfunction getOffsetParent(element) {\n if (utils.isWindow(element) || element.nodeType === 9) {\n return null;\n }\n // ie 这个也不是完全可行\n /*\n \n
\n 元素 6 高 100px 宽 50px \n
\n
\n */\n // element.offsetParent does the right thing in ie7 and below. Return parent with layout!\n // In other browsers it only includes elements with position absolute, relative or\n // fixed, not elements with overflow set to auto or scroll.\n // if (UA.ie && ieMode < 8) {\n // return element.offsetParent;\n // }\n // 统一的 offsetParent 方法\n const doc = utils.getDocument(element);\n const body = doc.body;\n let parent;\n let positionStyle = utils.css(element, 'position');\n const skipStatic = positionStyle === 'fixed' || positionStyle === 'absolute';\n\n if (!skipStatic) {\n return element.nodeName.toLowerCase() === 'html'\n ? null\n : getParent(element);\n }\n\n for (\n parent = getParent(element);\n parent && parent !== body && parent.nodeType !== 9;\n parent = getParent(parent)\n ) {\n positionStyle = utils.css(parent, 'position');\n if (positionStyle !== 'static') {\n return parent;\n }\n }\n return null;\n}\n\nexport default getOffsetParent;\n","import utils from './utils';\n\nconst { getParent } = utils;\n\nexport default function isAncestorFixed(element) {\n if (utils.isWindow(element) || element.nodeType === 9) {\n return false;\n }\n\n const doc = utils.getDocument(element);\n const body = doc.body;\n let parent = null;\n for (\n parent = getParent(element);\n parent && parent !== body;\n parent = getParent(parent)\n ) {\n const positionStyle = utils.css(parent, 'position');\n if (positionStyle === 'fixed') {\n return true;\n }\n }\n return false;\n}\n","import utils from './utils';\nimport getOffsetParent from './getOffsetParent';\nimport isAncestorFixed from './isAncestorFixed';\n\n/**\n * 获得元素的显示部分的区域\n */\nfunction getVisibleRectForElement(element, alwaysByViewport) {\n const visibleRect = {\n left: 0,\n right: Infinity,\n top: 0,\n bottom: Infinity,\n };\n let el = getOffsetParent(element);\n const doc = utils.getDocument(element);\n const win = doc.defaultView || doc.parentWindow;\n const body = doc.body;\n const documentElement = doc.documentElement;\n\n // Determine the size of the visible rect by climbing the dom usernameing for\n // all scrollable containers.\n while (el) {\n // clientWidth is zero for inline block elements in ie.\n if (\n (navigator.userAgent.indexOf('MSIE') === -1 || el.clientWidth !== 0) &&\n // body may have overflow set on it, yet we still get the entire\n // viewport. In some browsers, el.offsetParent may be\n // document.documentElement, so check for that too.\n (el !== body &&\n el !== documentElement &&\n utils.css(el, 'overflow') !== 'visible')\n ) {\n const pos = utils.offset(el);\n // add border\n pos.left += el.clientLeft;\n pos.top += el.clientTop;\n visibleRect.top = Math.max(visibleRect.top, pos.top);\n visibleRect.right = Math.min(\n visibleRect.right,\n // consider area without scrollBar\n pos.left + el.clientWidth,\n );\n visibleRect.bottom = Math.min(\n visibleRect.bottom,\n pos.top + el.clientHeight,\n );\n visibleRect.left = Math.max(visibleRect.left, pos.left);\n } else if (el === body || el === documentElement) {\n break;\n }\n el = getOffsetParent(el);\n }\n\n // Set element position to fixed\n // make sure absolute element itself don't affect it's visible area\n // https://github.com/ant-design/ant-design/issues/7601\n let originalPosition = null;\n if (!utils.isWindow(element) && element.nodeType !== 9) {\n originalPosition = element.style.position;\n const position = utils.css(element, 'position');\n if (position === 'absolute') {\n element.style.position = 'fixed';\n }\n }\n\n const scrollX = utils.getWindowScrollLeft(win);\n const scrollY = utils.getWindowScrollTop(win);\n const viewportWidth = utils.viewportWidth(win);\n const viewportHeight = utils.viewportHeight(win);\n let documentWidth = documentElement.scrollWidth;\n let documentHeight = documentElement.scrollHeight;\n\n // scrollXXX on html is sync with body which means overflow: hidden on body gets wrong scrollXXX.\n // We should cut this ourself.\n const bodyStyle = window.getComputedStyle(body);\n if (bodyStyle.overflowX === 'hidden') {\n documentWidth = win.innerWidth;\n }\n if (bodyStyle.overflowY === 'hidden') {\n documentHeight = win.innerHeight;\n }\n\n // Reset element position after calculate the visible area\n if (element.style) {\n element.style.position = originalPosition;\n }\n\n if (alwaysByViewport || isAncestorFixed(element)) {\n // Clip by viewport's size.\n visibleRect.left = Math.max(visibleRect.left, scrollX);\n visibleRect.top = Math.max(visibleRect.top, scrollY);\n visibleRect.right = Math.min(visibleRect.right, scrollX + viewportWidth);\n visibleRect.bottom = Math.min(visibleRect.bottom, scrollY + viewportHeight);\n } else {\n // Clip by document's size.\n const maxVisibleWidth = Math.max(documentWidth, scrollX + viewportWidth);\n visibleRect.right = Math.min(visibleRect.right, maxVisibleWidth);\n\n const maxVisibleHeight = Math.max(documentHeight, scrollY + viewportHeight);\n visibleRect.bottom = Math.min(visibleRect.bottom, maxVisibleHeight);\n }\n\n return visibleRect.top >= 0 &&\n visibleRect.left >= 0 &&\n visibleRect.bottom > visibleRect.top &&\n visibleRect.right > visibleRect.left\n ? visibleRect\n : null;\n}\n\nexport default getVisibleRectForElement;\n","import utils from './utils';\n\nfunction getRegion(node) {\n let offset;\n let w;\n let h;\n if (!utils.isWindow(node) && node.nodeType !== 9) {\n offset = utils.offset(node);\n w = utils.outerWidth(node);\n h = utils.outerHeight(node);\n } else {\n const win = utils.getWindow(node);\n offset = {\n left: utils.getWindowScrollLeft(win),\n top: utils.getWindowScrollTop(win),\n };\n w = utils.viewportWidth(win);\n h = utils.viewportHeight(win);\n }\n offset.width = w;\n offset.height = h;\n return offset;\n}\n\nexport default getRegion;\n","/**\n * 获取 node 上的 align 对齐点 相对于页面的坐标\n */\n\nfunction getAlignOffset(region, align) {\n const V = align.charAt(0);\n const H = align.charAt(1);\n const w = region.width;\n const h = region.height;\n\n let x = region.left;\n let y = region.top;\n\n if (V === 'c') {\n y += h / 2;\n } else if (V === 'b') {\n y += h;\n }\n\n if (H === 'c') {\n x += w / 2;\n } else if (H === 'r') {\n x += w;\n }\n\n return {\n left: x,\n top: y,\n };\n}\n\nexport default getAlignOffset;\n","import getAlignOffset from './getAlignOffset';\n\nfunction getElFuturePos(elRegion, refNodeRegion, points, offset, targetOffset) {\n const p1 = getAlignOffset(refNodeRegion, points[1]);\n const p2 = getAlignOffset(elRegion, points[0]);\n const diff = [p2.left - p1.left, p2.top - p1.top];\n\n return {\n left: Math.round(elRegion.left - diff[0] + offset[0] - targetOffset[0]),\n top: Math.round(elRegion.top - diff[1] + offset[1] - targetOffset[1]),\n };\n}\n\nexport default getElFuturePos;\n","/**\n * align dom node flexibly\n * @author yiminghe@gmail.com\n */\n\nimport utils from '../utils';\nimport getVisibleRectForElement from '../getVisibleRectForElement';\nimport adjustForViewport from '../adjustForViewport';\nimport getRegion from '../getRegion';\nimport getElFuturePos from '../getElFuturePos';\n\n// http://yiminghe.iteye.com/blog/1124720\n\nfunction isFailX(elFuturePos, elRegion, visibleRect) {\n return (\n elFuturePos.left < visibleRect.left ||\n elFuturePos.left + elRegion.width > visibleRect.right\n );\n}\n\nfunction isFailY(elFuturePos, elRegion, visibleRect) {\n return (\n elFuturePos.top < visibleRect.top ||\n elFuturePos.top + elRegion.height > visibleRect.bottom\n );\n}\n\nfunction isCompleteFailX(elFuturePos, elRegion, visibleRect) {\n return (\n elFuturePos.left > visibleRect.right ||\n elFuturePos.left + elRegion.width < visibleRect.left\n );\n}\n\nfunction isCompleteFailY(elFuturePos, elRegion, visibleRect) {\n return (\n elFuturePos.top > visibleRect.bottom ||\n elFuturePos.top + elRegion.height < visibleRect.top\n );\n}\n\nfunction flip(points, reg, map) {\n const ret = [];\n utils.each(points, p => {\n ret.push(\n p.replace(reg, m => {\n return map[m];\n }),\n );\n });\n return ret;\n}\n\nfunction flipOffset(offset, index) {\n offset[index] = -offset[index];\n return offset;\n}\n\nfunction convertOffset(str, offsetLen) {\n let n;\n if (/%$/.test(str)) {\n n = (parseInt(str.substring(0, str.length - 1), 10) / 100) * offsetLen;\n } else {\n n = parseInt(str, 10);\n }\n return n || 0;\n}\n\nfunction normalizeOffset(offset, el) {\n offset[0] = convertOffset(offset[0], el.width);\n offset[1] = convertOffset(offset[1], el.height);\n}\n\n/**\n * @param el\n * @param tgtRegion 参照节点所占的区域: { left, top, width, height }\n * @param align\n */\nfunction doAlign(el, tgtRegion, align, isTgtRegionVisible) {\n let points = align.points;\n let offset = align.offset || [0, 0];\n let targetOffset = align.targetOffset || [0, 0];\n let overflow = align.overflow;\n const source = align.source || el;\n offset = [].concat(offset);\n targetOffset = [].concat(targetOffset);\n overflow = overflow || {};\n const newOverflowCfg = {};\n let fail = 0;\n const alwaysByViewport = !!(overflow && overflow.alwaysByViewport);\n // 当前节点可以被放置的显示区域\n const visibleRect = getVisibleRectForElement(source, alwaysByViewport);\n // 当前节点所占的区域, left/top/width/height\n const elRegion = getRegion(source);\n // 将 offset 转换成数值,支持百分比\n normalizeOffset(offset, elRegion);\n normalizeOffset(targetOffset, tgtRegion);\n // 当前节点将要被放置的位置\n let elFuturePos = getElFuturePos(\n elRegion,\n tgtRegion,\n points,\n offset,\n targetOffset,\n );\n // 当前节点将要所处的区域\n let newElRegion = utils.merge(elRegion, elFuturePos);\n\n // 如果可视区域不能完全放置当前节点时允许调整\n if (\n visibleRect &&\n (overflow.adjustX || overflow.adjustY) &&\n isTgtRegionVisible\n ) {\n if (overflow.adjustX) {\n // 如果横向不能放下\n if (isFailX(elFuturePos, elRegion, visibleRect)) {\n // 对齐位置反下\n const newPoints = flip(points, /[lr]/gi, {\n l: 'r',\n r: 'l',\n });\n // 偏移量也反下\n const newOffset = flipOffset(offset, 0);\n const newTargetOffset = flipOffset(targetOffset, 0);\n const newElFuturePos = getElFuturePos(\n elRegion,\n tgtRegion,\n newPoints,\n newOffset,\n newTargetOffset,\n );\n\n if (!isCompleteFailX(newElFuturePos, elRegion, visibleRect)) {\n fail = 1;\n points = newPoints;\n offset = newOffset;\n targetOffset = newTargetOffset;\n }\n }\n }\n\n if (overflow.adjustY) {\n // 如果纵向不能放下\n if (isFailY(elFuturePos, elRegion, visibleRect)) {\n // 对齐位置反下\n const newPoints = flip(points, /[tb]/gi, {\n t: 'b',\n b: 't',\n });\n // 偏移量也反下\n const newOffset = flipOffset(offset, 1);\n const newTargetOffset = flipOffset(targetOffset, 1);\n const newElFuturePos = getElFuturePos(\n elRegion,\n tgtRegion,\n newPoints,\n newOffset,\n newTargetOffset,\n );\n\n if (!isCompleteFailY(newElFuturePos, elRegion, visibleRect)) {\n fail = 1;\n points = newPoints;\n offset = newOffset;\n targetOffset = newTargetOffset;\n }\n }\n }\n\n // 如果失败,重新计算当前节点将要被放置的位置\n if (fail) {\n elFuturePos = getElFuturePos(\n elRegion,\n tgtRegion,\n points,\n offset,\n targetOffset,\n );\n utils.mix(newElRegion, elFuturePos);\n }\n const isStillFailX = isFailX(elFuturePos, elRegion, visibleRect);\n const isStillFailY = isFailY(elFuturePos, elRegion, visibleRect);\n // 检查反下后的位置是否可以放下了,如果仍然放不下:\n // 1. 复原修改过的定位参数\n if (isStillFailX || isStillFailY) {\n let newPoints = points;\n\n // 重置对应部分的翻转逻辑\n if (isStillFailX) {\n newPoints = flip(points, /[lr]/gi, {\n l: 'r',\n r: 'l',\n });\n }\n if (isStillFailY) {\n newPoints = flip(points, /[tb]/gi, {\n t: 'b',\n b: 't',\n });\n }\n\n points = newPoints;\n\n offset = align.offset || [0, 0];\n targetOffset = align.targetOffset || [0, 0];\n }\n // 2. 只有指定了可以调整当前方向才调整\n newOverflowCfg.adjustX = overflow.adjustX && isStillFailX;\n newOverflowCfg.adjustY = overflow.adjustY && isStillFailY;\n\n // 确实要调整,甚至可能会调整高度宽度\n if (newOverflowCfg.adjustX || newOverflowCfg.adjustY) {\n newElRegion = adjustForViewport(\n elFuturePos,\n elRegion,\n visibleRect,\n newOverflowCfg,\n );\n }\n }\n\n // need judge to in case set fixed with in css on height auto element\n if (newElRegion.width !== elRegion.width) {\n utils.css(\n source,\n 'width',\n utils.width(source) + newElRegion.width - elRegion.width,\n );\n }\n\n if (newElRegion.height !== elRegion.height) {\n utils.css(\n source,\n 'height',\n utils.height(source) + newElRegion.height - elRegion.height,\n );\n }\n\n // https://github.com/kissyteam/kissy/issues/190\n // 相对于屏幕位置没变,而 left/top 变了\n // 例如
\n utils.offset(\n source,\n {\n left: newElRegion.left,\n top: newElRegion.top,\n },\n {\n useCssRight: align.useCssRight,\n useCssBottom: align.useCssBottom,\n useCssTransform: align.useCssTransform,\n ignoreShake: align.ignoreShake,\n },\n );\n\n return {\n points,\n offset,\n targetOffset,\n overflow: newOverflowCfg,\n };\n}\n\nexport default doAlign;\n/**\n * 2012-04-26 yiminghe@gmail.com\n * - 优化智能对齐算法\n * - 慎用 resizeXX\n *\n * 2011-07-13 yiminghe@gmail.com note:\n * - 增加智能对齐,以及大小调整选项\n **/\n","import utils from './utils';\n\nfunction adjustForViewport(elFuturePos, elRegion, visibleRect, overflow) {\n const pos = utils.clone(elFuturePos);\n const size = {\n width: elRegion.width,\n height: elRegion.height,\n };\n\n if (overflow.adjustX && pos.left < visibleRect.left) {\n pos.left = visibleRect.left;\n }\n\n // Left edge inside and right edge outside viewport, try to resize it.\n if (\n overflow.resizeWidth &&\n pos.left >= visibleRect.left &&\n pos.left + size.width > visibleRect.right\n ) {\n size.width -= pos.left + size.width - visibleRect.right;\n }\n\n // Right edge outside viewport, try to move it.\n if (overflow.adjustX && pos.left + size.width > visibleRect.right) {\n // 保证左边界和可视区域左边界对齐\n pos.left = Math.max(visibleRect.right - size.width, visibleRect.left);\n }\n\n // Top edge outside viewport, try to move it.\n if (overflow.adjustY && pos.top < visibleRect.top) {\n pos.top = visibleRect.top;\n }\n\n // Top edge inside and bottom edge outside viewport, try to resize it.\n if (\n overflow.resizeHeight &&\n pos.top >= visibleRect.top &&\n pos.top + size.height > visibleRect.bottom\n ) {\n size.height -= pos.top + size.height - visibleRect.bottom;\n }\n\n // Bottom edge outside viewport, try to move it.\n if (overflow.adjustY && pos.top + size.height > visibleRect.bottom) {\n // 保证上边界和可视区域上边界对齐\n pos.top = Math.max(visibleRect.bottom - size.height, visibleRect.top);\n }\n\n return utils.mix(pos, size);\n}\n\nexport default adjustForViewport;\n","import doAlign from './align';\nimport getOffsetParent from '../getOffsetParent';\nimport getVisibleRectForElement from '../getVisibleRectForElement';\nimport getRegion from '../getRegion';\n\nfunction isOutOfVisibleRect(target, alwaysByViewport) {\n const visibleRect = getVisibleRectForElement(target, alwaysByViewport);\n const targetRegion = getRegion(target);\n\n return (\n !visibleRect ||\n targetRegion.left + targetRegion.width <= visibleRect.left ||\n targetRegion.top + targetRegion.height <= visibleRect.top ||\n targetRegion.left >= visibleRect.right ||\n targetRegion.top >= visibleRect.bottom\n );\n}\n\nfunction alignElement(el, refNode, align) {\n const target = align.target || refNode;\n const refNodeRegion = getRegion(target);\n\n const isTargetNotOutOfVisible = !isOutOfVisibleRect(\n target,\n align.overflow && align.overflow.alwaysByViewport,\n );\n\n return doAlign(el, refNodeRegion, align, isTargetNotOutOfVisible);\n}\n\nalignElement.__getOffsetParent = getOffsetParent;\n\nalignElement.__getVisibleRectForElement = getVisibleRectForElement;\n\nexport default alignElement;\n","import utils from '../utils';\nimport doAlign from './align';\n\n/**\n * `tgtPoint`: { pageX, pageY } or { clientX, clientY }.\n * If client position provided, will internal convert to page position.\n */\n\nfunction alignPoint(el, tgtPoint, align) {\n let pageX;\n let pageY;\n\n const doc = utils.getDocument(el);\n const win = doc.defaultView || doc.parentWindow;\n\n const scrollX = utils.getWindowScrollLeft(win);\n const scrollY = utils.getWindowScrollTop(win);\n const viewportWidth = utils.viewportWidth(win);\n const viewportHeight = utils.viewportHeight(win);\n\n if ('pageX' in tgtPoint) {\n pageX = tgtPoint.pageX;\n } else {\n pageX = scrollX + tgtPoint.clientX;\n }\n\n if ('pageY' in tgtPoint) {\n pageY = tgtPoint.pageY;\n } else {\n pageY = scrollY + tgtPoint.clientY;\n }\n\n const tgtRegion = {\n left: pageX,\n top: pageY,\n width: 0,\n height: 0,\n };\n\n const pointInView =\n pageX >= 0 &&\n pageX <= scrollX + viewportWidth &&\n (pageY >= 0 && pageY <= scrollY + viewportHeight);\n\n // Provide default target point\n const points = [align.points[0], 'cc'];\n\n return doAlign(el, tgtRegion, { ...align, points }, pointInView);\n}\n\nexport default alignPoint;\n","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport ResizeObserver from 'resize-observer-polyfill';\nimport contains from \"rc-util/es/Dom/contains\";\nexport function isSamePoint(prev, next) {\n if (prev === next) return true;\n if (!prev || !next) return false;\n\n if ('pageX' in next && 'pageY' in next) {\n return prev.pageX === next.pageX && prev.pageY === next.pageY;\n }\n\n if ('clientX' in next && 'clientY' in next) {\n return prev.clientX === next.clientX && prev.clientY === next.clientY;\n }\n\n return false;\n}\nexport function restoreFocus(activeElement, container) {\n // Focus back if is in the container\n if (activeElement !== document.activeElement && contains(container, activeElement) && typeof activeElement.focus === 'function') {\n activeElement.focus();\n }\n}\nexport function monitorResize(element, callback) {\n var prevWidth = null;\n var prevHeight = null;\n\n function onResize(_ref) {\n var _ref2 = _slicedToArray(_ref, 1),\n target = _ref2[0].target;\n\n if (!document.contains(target)) return;\n\n var _target$getBoundingCl = target.getBoundingClientRect(),\n width = _target$getBoundingCl.width,\n height = _target$getBoundingCl.height;\n\n var fixedWidth = Math.floor(width);\n var fixedHeight = Math.floor(height);\n\n if (prevWidth !== fixedWidth || prevHeight !== fixedHeight) {\n // https://webkit.org/blog/9997/resizeobserver-in-webkit/\n Promise.resolve().then(function () {\n callback({\n width: fixedWidth,\n height: fixedHeight\n });\n });\n }\n\n prevWidth = fixedWidth;\n prevHeight = fixedHeight;\n }\n\n var resizeObserver = new ResizeObserver(onResize);\n\n if (element) {\n resizeObserver.observe(element);\n }\n\n return function () {\n resizeObserver.disconnect();\n };\n}","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\n\n/**\n * Removed props:\n * - childrenProps\n */\nimport React from 'react';\nimport { composeRef } from \"rc-util/es/ref\";\nimport { alignElement, alignPoint } from 'dom-align';\nimport addEventListener from \"rc-util/es/Dom/addEventListener\";\nimport { isSamePoint, restoreFocus, monitorResize } from './util';\nimport useBuffer from './hooks/useBuffer';\n\nfunction getElement(func) {\n if (typeof func !== 'function') return null;\n return func();\n}\n\nfunction getPoint(point) {\n if (_typeof(point) !== 'object' || !point) return null;\n return point;\n}\n\nvar Align = function Align(_ref, ref) {\n var children = _ref.children,\n disabled = _ref.disabled,\n target = _ref.target,\n align = _ref.align,\n onAlign = _ref.onAlign,\n monitorWindowResize = _ref.monitorWindowResize,\n _ref$monitorBufferTim = _ref.monitorBufferTime,\n monitorBufferTime = _ref$monitorBufferTim === void 0 ? 0 : _ref$monitorBufferTim;\n var cacheRef = React.useRef({});\n var nodeRef = React.useRef();\n var childNode = React.Children.only(children); // ===================== Align ======================\n // We save the props here to avoid closure makes props ood\n\n var forceAlignPropsRef = React.useRef({});\n forceAlignPropsRef.current.disabled = disabled;\n forceAlignPropsRef.current.target = target;\n forceAlignPropsRef.current.onAlign = onAlign;\n\n var _useBuffer = useBuffer(function () {\n var _forceAlignPropsRef$c = forceAlignPropsRef.current,\n latestDisabled = _forceAlignPropsRef$c.disabled,\n latestTarget = _forceAlignPropsRef$c.target;\n\n if (!latestDisabled && latestTarget) {\n var source = nodeRef.current;\n var result;\n var element = getElement(latestTarget);\n var point = getPoint(latestTarget);\n cacheRef.current.element = element;\n cacheRef.current.point = point; // IE lose focus after element realign\n // We should record activeElement and restore later\n\n var _document = document,\n activeElement = _document.activeElement;\n\n if (element) {\n result = alignElement(source, element, align);\n } else if (point) {\n result = alignPoint(source, point, align);\n }\n\n restoreFocus(activeElement, source);\n\n if (onAlign) {\n onAlign(source, result);\n }\n\n return true;\n }\n\n return false;\n }, monitorBufferTime),\n _useBuffer2 = _slicedToArray(_useBuffer, 2),\n _forceAlign = _useBuffer2[0],\n cancelForceAlign = _useBuffer2[1]; // ===================== Effect =====================\n // Listen for target updated\n\n\n var resizeMonitor = React.useRef({\n cancel: function cancel() {}\n }); // Listen for source updated\n\n var sourceResizeMonitor = React.useRef({\n cancel: function cancel() {}\n });\n React.useEffect(function () {\n var element = getElement(target);\n var point = getPoint(target);\n\n if (nodeRef.current !== sourceResizeMonitor.current.element) {\n sourceResizeMonitor.current.cancel();\n sourceResizeMonitor.current.element = nodeRef.current;\n sourceResizeMonitor.current.cancel = monitorResize(nodeRef.current, _forceAlign);\n }\n\n if (cacheRef.current.element !== element || !isSamePoint(cacheRef.current.point, point)) {\n _forceAlign(); // Add resize observer\n\n\n if (resizeMonitor.current.element !== element) {\n resizeMonitor.current.cancel();\n resizeMonitor.current.element = element;\n resizeMonitor.current.cancel = monitorResize(element, _forceAlign);\n }\n }\n }); // Listen for disabled change\n\n React.useEffect(function () {\n if (!disabled) {\n _forceAlign();\n } else {\n cancelForceAlign();\n }\n }, [disabled]); // Listen for window resize\n\n var winResizeRef = React.useRef(null);\n React.useEffect(function () {\n if (monitorWindowResize) {\n if (!winResizeRef.current) {\n winResizeRef.current = addEventListener(window, 'resize', _forceAlign);\n }\n } else if (winResizeRef.current) {\n winResizeRef.current.remove();\n winResizeRef.current = null;\n }\n }, [monitorWindowResize]); // Clear all if unmount\n\n React.useEffect(function () {\n return function () {\n resizeMonitor.current.cancel();\n sourceResizeMonitor.current.cancel();\n if (winResizeRef.current) winResizeRef.current.remove();\n cancelForceAlign();\n };\n }, []); // ====================== Ref =======================\n\n React.useImperativeHandle(ref, function () {\n return {\n forceAlign: function forceAlign() {\n return _forceAlign(true);\n }\n };\n }); // ===================== Render =====================\n\n if (React.isValidElement(childNode)) {\n childNode = React.cloneElement(childNode, {\n ref: composeRef(childNode.ref, nodeRef)\n });\n }\n\n return childNode;\n};\n\nvar RefAlign = React.forwardRef(Align);\nRefAlign.displayName = 'Align';\nexport default RefAlign;","import React from 'react';\nexport default (function (callback, buffer) {\n var calledRef = React.useRef(false);\n var timeoutRef = React.useRef(null);\n\n function cancelTrigger() {\n window.clearTimeout(timeoutRef.current);\n }\n\n function trigger(force) {\n if (!calledRef.current || force === true) {\n if (callback() === false) {\n // Not delay since callback cancelled self\n return;\n }\n\n calledRef.current = true;\n cancelTrigger();\n timeoutRef.current = window.setTimeout(function () {\n calledRef.current = false;\n }, buffer);\n } else {\n cancelTrigger();\n timeoutRef.current = window.setTimeout(function () {\n calledRef.current = false;\n trigger();\n }, buffer);\n }\n }\n\n return [trigger, function () {\n calledRef.current = false;\n cancelTrigger();\n }];\n});","// export this package's api\nimport Align from './Align';\nexport default Align;","import React from 'react';\n\nvar PopupInner = function PopupInner(props, ref) {\n var prefixCls = props.prefixCls,\n className = props.className,\n style = props.style,\n children = props.children,\n onMouseEnter = props.onMouseEnter,\n onMouseLeave = props.onMouseLeave,\n onMouseDown = props.onMouseDown,\n onTouchStart = props.onTouchStart;\n var childNode = children;\n\n if (React.Children.count(children) > 1) {\n childNode = React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-content\")\n }, children);\n }\n\n return React.createElement(\"div\", {\n ref: ref,\n className: className,\n onMouseEnter: onMouseEnter,\n onMouseLeave: onMouseLeave,\n onMouseDown: onMouseDown,\n onTouchStart: onTouchStart,\n style: style\n }, childNode);\n};\n\nvar RefPopupInner = React.forwardRef(PopupInner);\nRefPopupInner.displayName = 'PopupInner';\nexport default RefPopupInner;","export function getMotion(_ref) {\n var prefixCls = _ref.prefixCls,\n motion = _ref.motion,\n animation = _ref.animation,\n transitionName = _ref.transitionName;\n\n if (motion) {\n return motion;\n }\n\n if (animation) {\n return {\n motionName: \"\".concat(prefixCls, \"-\").concat(animation)\n };\n }\n\n if (transitionName) {\n return {\n motionName: transitionName\n };\n }\n\n return null;\n}","import _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\n\n/* eslint-disable no-param-reassign */\nimport React, { Component } from 'react';\nimport raf from 'raf';\nimport Align from 'rc-align';\nimport { composeRef } from \"rc-util/es/ref\";\nimport classNames from 'classnames';\nimport CSSMotion from 'rc-motion';\nimport PopupInner from './PopupInner';\nimport { getMotion } from './utils/legacyUtil';\n\nfunction supportMotion(motion) {\n return motion && motion.motionName;\n}\n\nvar Popup = /*#__PURE__*/function (_Component) {\n _inherits(Popup, _Component);\n\n var _super = _createSuper(Popup);\n\n function Popup() {\n var _this;\n\n _classCallCheck(this, Popup);\n\n _this = _super.apply(this, arguments);\n _this.state = {\n targetWidth: undefined,\n targetHeight: undefined,\n status: null,\n prevVisible: null,\n alignClassName: null,\n inMotion: false\n };\n _this.popupRef = React.createRef();\n _this.alignRef = React.createRef();\n _this.nextFrameState = null;\n _this.nextFrameId = null;\n\n _this.onAlign = function (popupDomNode, align) {\n var status = _this.state.status;\n var _this$props = _this.props,\n getClassNameFromAlign = _this$props.getClassNameFromAlign,\n onAlign = _this$props.onAlign;\n var alignClassName = getClassNameFromAlign(align);\n\n if (status === 'align') {\n _this.setState({\n alignClassName: alignClassName,\n status: 'aligned'\n }, function () {\n _this.alignRef.current.forceAlign();\n });\n } else if (status === 'aligned') {\n _this.setState({\n alignClassName: alignClassName,\n status: 'afterAlign'\n });\n\n onAlign(popupDomNode, align);\n } else {\n _this.setState({\n alignClassName: alignClassName\n });\n }\n };\n\n _this.onMotionEnd = function () {\n var visible = _this.props.visible;\n\n _this.setState({\n status: visible ? 'AfterMotion' : 'stable',\n inMotion: false\n });\n };\n\n _this.setStateOnNextFrame = function (state) {\n _this.cancelFrameState();\n\n _this.nextFrameState = _objectSpread(_objectSpread({}, _this.nextFrameState), state);\n _this.nextFrameId = raf(function () {\n var submitState = _objectSpread({}, _this.nextFrameState);\n\n _this.nextFrameState = null;\n\n _this.setState(submitState);\n });\n };\n\n _this.getMotion = function () {\n return _objectSpread({}, getMotion(_this.props));\n }; // `target` on `rc-align` can accept as a function to get the bind element or a point.\n // ref: https://www.npmjs.com/package/rc-align\n\n\n _this.getAlignTarget = function () {\n var _this$props2 = _this.props,\n point = _this$props2.point,\n getRootDomNode = _this$props2.getRootDomNode;\n\n if (point) {\n return point;\n }\n\n return getRootDomNode;\n };\n\n _this.cancelFrameState = function () {\n raf.cancel(_this.nextFrameId);\n };\n\n _this.renderPopupElement = function () {\n var _this$state = _this.state,\n status = _this$state.status,\n targetHeight = _this$state.targetHeight,\n targetWidth = _this$state.targetWidth,\n alignClassName = _this$state.alignClassName;\n var _this$props3 = _this.props,\n prefixCls = _this$props3.prefixCls,\n className = _this$props3.className,\n style = _this$props3.style,\n stretch = _this$props3.stretch,\n visible = _this$props3.visible,\n align = _this$props3.align,\n destroyPopupOnHide = _this$props3.destroyPopupOnHide,\n onMouseEnter = _this$props3.onMouseEnter,\n onMouseLeave = _this$props3.onMouseLeave,\n onMouseDown = _this$props3.onMouseDown,\n onTouchStart = _this$props3.onTouchStart,\n children = _this$props3.children;\n var mergedClassName = classNames(prefixCls, className, alignClassName);\n var hiddenClassName = \"\".concat(prefixCls, \"-hidden\"); // ================== Style ==================\n\n var sizeStyle = {};\n\n if (stretch) {\n // Stretch with target\n if (stretch.indexOf('height') !== -1) {\n sizeStyle.height = targetHeight;\n } else if (stretch.indexOf('minHeight') !== -1) {\n sizeStyle.minHeight = targetHeight;\n }\n\n if (stretch.indexOf('width') !== -1) {\n sizeStyle.width = targetWidth;\n } else if (stretch.indexOf('minWidth') !== -1) {\n sizeStyle.minWidth = targetWidth;\n }\n }\n\n var mergedStyle = _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, sizeStyle), _this.getZIndexStyle()), style), {}, {\n opacity: status === 'stable' || !visible ? undefined : 0,\n pointerEvents: status === 'stable' || !visible ? undefined : 'none'\n }); // ================= Motions =================\n\n\n var mergedMotion = _this.getMotion();\n\n var mergedMotionVisible = visible;\n\n if (visible && status !== 'beforeMotion' && status !== 'motion' && status !== 'stable') {\n mergedMotion.motionAppear = false;\n mergedMotion.motionEnter = false;\n mergedMotion.motionLeave = false;\n }\n\n if (status === 'afterAlign' || status === 'beforeMotion') {\n mergedMotionVisible = false;\n } // Update trigger to tell if is in motion\n\n\n ['onEnterStart', 'onAppearStart', 'onLeaveStart'].forEach(function (event) {\n var originFunc = mergedMotion === null || mergedMotion === void 0 ? void 0 : mergedMotion[event];\n\n mergedMotion[event] = function () {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n originFunc === null || originFunc === void 0 ? void 0 : originFunc.apply(void 0, args);\n\n _this.setState({\n inMotion: true\n });\n };\n }); // ================== Align ==================\n\n var mergedAlignDisabled = !visible || status !== 'align' && status !== 'aligned' && status !== 'stable'; // ================== Popup ==================\n\n var mergedPopupVisible = true;\n\n if (status === 'stable') {\n mergedPopupVisible = visible;\n } // Only remove popup since mask may still need animation\n\n\n if (destroyPopupOnHide && !mergedPopupVisible) {\n return null;\n }\n\n return React.createElement(CSSMotion, Object.assign({\n visible: mergedMotionVisible\n }, mergedMotion, {\n removeOnLeave: false,\n onEnterEnd: _this.onMotionEnd,\n onLeaveEnd: _this.onMotionEnd,\n leavedClassName: hiddenClassName\n }), function (_ref, motionRef) {\n var motionStyle = _ref.style,\n motionClassName = _ref.className;\n return React.createElement(Align, {\n target: _this.getAlignTarget(),\n key: \"popup\",\n ref: _this.alignRef,\n monitorWindowResize: true,\n disabled: mergedAlignDisabled,\n align: align,\n onAlign: _this.onAlign\n }, React.createElement(PopupInner, {\n prefixCls: prefixCls,\n className: classNames(mergedClassName, motionClassName),\n ref: composeRef(motionRef, _this.popupRef),\n onMouseEnter: onMouseEnter,\n onMouseLeave: onMouseLeave,\n onMouseDown: onMouseDown,\n onTouchStart: onTouchStart,\n style: _objectSpread(_objectSpread({}, mergedStyle), motionStyle)\n }, children));\n });\n };\n\n _this.renderMaskElement = function () {\n var _this$props4 = _this.props,\n mask = _this$props4.mask,\n maskMotion = _this$props4.maskMotion,\n maskTransitionName = _this$props4.maskTransitionName,\n maskAnimation = _this$props4.maskAnimation,\n prefixCls = _this$props4.prefixCls,\n visible = _this$props4.visible;\n\n if (!mask) {\n return null;\n }\n\n var motion = {};\n\n if (maskMotion && maskMotion.motionName) {\n motion = _objectSpread({\n motionAppear: true\n }, getMotion({\n motion: maskMotion,\n prefixCls: prefixCls,\n transitionName: maskTransitionName,\n animation: maskAnimation\n }));\n }\n\n return React.createElement(CSSMotion, Object.assign({}, motion, {\n visible: visible,\n removeOnLeave: true\n }), function (_ref2) {\n var className = _ref2.className;\n return React.createElement(\"div\", {\n style: _this.getZIndexStyle(),\n key: \"mask\",\n className: classNames(\"\".concat(prefixCls, \"-mask\"), className)\n });\n });\n };\n\n return _this;\n }\n\n _createClass(Popup, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.componentDidUpdate();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {\n var status = this.state.status;\n var _this$props5 = this.props,\n getRootDomNode = _this$props5.getRootDomNode,\n visible = _this$props5.visible,\n stretch = _this$props5.stretch; // If there is a pending state update, cancel it, a new one will be set if necessary\n\n this.cancelFrameState();\n\n if (visible && status !== 'stable') {\n switch (status) {\n case null:\n {\n this.setStateOnNextFrame({\n status: stretch ? 'measure' : 'align'\n });\n break;\n }\n\n case 'afterAlign':\n {\n this.setStateOnNextFrame({\n status: supportMotion(this.getMotion()) ? 'beforeMotion' : 'stable'\n });\n break;\n }\n\n case 'AfterMotion':\n {\n this.setStateOnNextFrame({\n status: 'stable'\n });\n break;\n }\n\n default:\n {\n // Go to next status\n var queue = ['measure', 'align', null, 'beforeMotion', 'motion'];\n var index = queue.indexOf(status);\n var nextStatus = queue[index + 1];\n\n if (index !== -1 && nextStatus) {\n this.setStateOnNextFrame({\n status: nextStatus\n });\n }\n }\n }\n } // Measure stretch size\n\n\n if (status === 'measure') {\n var $ele = getRootDomNode();\n\n if ($ele) {\n this.setStateOnNextFrame({\n targetHeight: $ele.offsetHeight,\n targetWidth: $ele.offsetWidth\n });\n }\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n this.cancelFrameState();\n }\n }, {\n key: \"getZIndexStyle\",\n value: function getZIndexStyle() {\n var zIndex = this.props.zIndex;\n return {\n zIndex: zIndex\n };\n }\n }, {\n key: \"render\",\n value: function render() {\n return React.createElement(\"div\", null, this.renderMaskElement(), this.renderPopupElement());\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(_ref3, _ref4) {\n var visible = _ref3.visible,\n props = _objectWithoutProperties(_ref3, [\"visible\"]);\n\n var prevVisible = _ref4.prevVisible,\n status = _ref4.status,\n inMotion = _ref4.inMotion;\n var newState = {\n prevVisible: visible,\n status: status\n };\n var mergedMotion = getMotion(props);\n\n if (prevVisible === null && visible === false) {\n // Init render should always be stable\n newState.status = 'stable';\n newState.inMotion = false;\n } else if (visible !== prevVisible) {\n newState.inMotion = false;\n\n if (visible || supportMotion(mergedMotion) && inMotion) {\n newState.status = null;\n } else {\n newState.status = 'stable';\n }\n\n if (visible) {\n newState.alignClassName = null;\n }\n }\n\n return newState;\n }\n }]);\n\n return Popup;\n}(Component);\n\nexport default Popup;\n/* eslint-enable */","import React from 'react';\nvar TriggerContext = React.createContext(null);\nexport default TriggerContext;","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport contains from \"rc-util/es/Dom/contains\";\nimport findDOMNode from \"rc-util/es/Dom/findDOMNode\";\nimport { composeRef, supportRef } from \"rc-util/es/ref\";\nimport addEventListener from \"rc-util/es/Dom/addEventListener\";\nimport Portal from \"rc-util/es/Portal\";\nimport classNames from 'classnames';\nimport { getAlignFromPlacement, getAlignPopupClassName } from './utils/alignUtil';\nimport Popup from './Popup';\nimport TriggerContext from './context';\n\nfunction noop() {}\n\nfunction returnEmptyString() {\n return '';\n}\n\nfunction returnDocument() {\n return window.document;\n}\n\nvar ALL_HANDLERS = ['onClick', 'onMouseDown', 'onTouchStart', 'onMouseEnter', 'onMouseLeave', 'onFocus', 'onBlur', 'onContextMenu'];\n/**\n * Internal usage. Do not use in your code since this will be removed.\n */\n\nexport function generateTrigger(PortalComponent) {\n var Trigger = /*#__PURE__*/function (_React$Component) {\n _inherits(Trigger, _React$Component);\n\n var _super = _createSuper(Trigger);\n\n function Trigger(props) {\n var _this;\n\n _classCallCheck(this, Trigger);\n\n _this = _super.call(this, props);\n _this.popupRef = React.createRef();\n _this.triggerRef = React.createRef();\n\n _this.onMouseEnter = function (e) {\n var mouseEnterDelay = _this.props.mouseEnterDelay;\n\n _this.fireEvents('onMouseEnter', e);\n\n _this.delaySetPopupVisible(true, mouseEnterDelay, mouseEnterDelay ? null : e);\n };\n\n _this.onMouseMove = function (e) {\n _this.fireEvents('onMouseMove', e);\n\n _this.setPoint(e);\n };\n\n _this.onMouseLeave = function (e) {\n _this.fireEvents('onMouseLeave', e);\n\n _this.delaySetPopupVisible(false, _this.props.mouseLeaveDelay);\n };\n\n _this.onPopupMouseEnter = function () {\n _this.clearDelayTimer();\n };\n\n _this.onPopupMouseLeave = function (e) {\n // https://github.com/react-component/trigger/pull/13\n // react bug?\n if (e.relatedTarget && !e.relatedTarget.setTimeout && _this.popupRef.current && _this.popupRef.current.popupRef.current && contains(_this.popupRef.current.popupRef.current, e.relatedTarget)) {\n return;\n }\n\n _this.delaySetPopupVisible(false, _this.props.mouseLeaveDelay);\n };\n\n _this.onFocus = function (e) {\n _this.fireEvents('onFocus', e); // incase focusin and focusout\n\n\n _this.clearDelayTimer();\n\n if (_this.isFocusToShow()) {\n _this.focusTime = Date.now();\n\n _this.delaySetPopupVisible(true, _this.props.focusDelay);\n }\n };\n\n _this.onMouseDown = function (e) {\n _this.fireEvents('onMouseDown', e);\n\n _this.preClickTime = Date.now();\n };\n\n _this.onTouchStart = function (e) {\n _this.fireEvents('onTouchStart', e);\n\n _this.preTouchTime = Date.now();\n };\n\n _this.onBlur = function (e) {\n _this.fireEvents('onBlur', e);\n\n _this.clearDelayTimer();\n\n if (_this.isBlurToHide()) {\n _this.delaySetPopupVisible(false, _this.props.blurDelay);\n }\n };\n\n _this.onContextMenu = function (e) {\n e.preventDefault();\n\n _this.fireEvents('onContextMenu', e);\n\n _this.setPopupVisible(true, e);\n };\n\n _this.onContextMenuClose = function () {\n if (_this.isContextMenuToShow()) {\n _this.close();\n }\n };\n\n _this.onClick = function (event) {\n _this.fireEvents('onClick', event); // focus will trigger click\n\n\n if (_this.focusTime) {\n var preTime;\n\n if (_this.preClickTime && _this.preTouchTime) {\n preTime = Math.min(_this.preClickTime, _this.preTouchTime);\n } else if (_this.preClickTime) {\n preTime = _this.preClickTime;\n } else if (_this.preTouchTime) {\n preTime = _this.preTouchTime;\n }\n\n if (Math.abs(preTime - _this.focusTime) < 20) {\n return;\n }\n\n _this.focusTime = 0;\n }\n\n _this.preClickTime = 0;\n _this.preTouchTime = 0; // Only prevent default when all the action is click.\n // https://github.com/ant-design/ant-design/issues/17043\n // https://github.com/ant-design/ant-design/issues/17291\n\n if (_this.isClickToShow() && (_this.isClickToHide() || _this.isBlurToHide()) && event && event.preventDefault) {\n event.preventDefault();\n }\n\n var nextVisible = !_this.state.popupVisible;\n\n if (_this.isClickToHide() && !nextVisible || nextVisible && _this.isClickToShow()) {\n _this.setPopupVisible(!_this.state.popupVisible, event);\n }\n };\n\n _this.onPopupMouseDown = function () {\n _this.hasPopupMouseDown = true;\n clearTimeout(_this.mouseDownTimeout);\n _this.mouseDownTimeout = window.setTimeout(function () {\n _this.hasPopupMouseDown = false;\n }, 0);\n\n if (_this.context) {\n var _this$context;\n\n (_this$context = _this.context).onPopupMouseDown.apply(_this$context, arguments);\n }\n };\n\n _this.onDocumentClick = function (event) {\n if (_this.props.mask && !_this.props.maskClosable) {\n return;\n }\n\n var target = event.target;\n\n var root = _this.getRootDomNode();\n\n var popupNode = _this.getPopupDomNode();\n\n if (!contains(root, target) && !contains(popupNode, target) && !_this.hasPopupMouseDown) {\n _this.close();\n }\n };\n\n _this.getRootDomNode = function () {\n var getTriggerDOMNode = _this.props.getTriggerDOMNode;\n\n if (getTriggerDOMNode) {\n return getTriggerDOMNode(_this.triggerRef.current);\n }\n\n try {\n var domNode = findDOMNode(_this.triggerRef.current);\n\n if (domNode) {\n return domNode;\n }\n } catch (err) {// Do nothing\n }\n\n return ReactDOM.findDOMNode(_assertThisInitialized(_this));\n };\n\n _this.getPopupClassNameFromAlign = function (align) {\n var className = [];\n var _this$props = _this.props,\n popupPlacement = _this$props.popupPlacement,\n builtinPlacements = _this$props.builtinPlacements,\n prefixCls = _this$props.prefixCls,\n alignPoint = _this$props.alignPoint,\n getPopupClassNameFromAlign = _this$props.getPopupClassNameFromAlign;\n\n if (popupPlacement && builtinPlacements) {\n className.push(getAlignPopupClassName(builtinPlacements, prefixCls, align, alignPoint));\n }\n\n if (getPopupClassNameFromAlign) {\n className.push(getPopupClassNameFromAlign(align));\n }\n\n return className.join(' ');\n };\n\n _this.getComponent = function () {\n var _this$props2 = _this.props,\n prefixCls = _this$props2.prefixCls,\n destroyPopupOnHide = _this$props2.destroyPopupOnHide,\n popupClassName = _this$props2.popupClassName,\n onPopupAlign = _this$props2.onPopupAlign,\n popupMotion = _this$props2.popupMotion,\n popupAnimation = _this$props2.popupAnimation,\n popupTransitionName = _this$props2.popupTransitionName,\n popupStyle = _this$props2.popupStyle,\n mask = _this$props2.mask,\n maskAnimation = _this$props2.maskAnimation,\n maskTransitionName = _this$props2.maskTransitionName,\n maskMotion = _this$props2.maskMotion,\n zIndex = _this$props2.zIndex,\n popup = _this$props2.popup,\n stretch = _this$props2.stretch,\n alignPoint = _this$props2.alignPoint;\n var _this$state = _this.state,\n popupVisible = _this$state.popupVisible,\n point = _this$state.point;\n\n var align = _this.getPopupAlign();\n\n var mouseProps = {};\n\n if (_this.isMouseEnterToShow()) {\n mouseProps.onMouseEnter = _this.onPopupMouseEnter;\n }\n\n if (_this.isMouseLeaveToHide()) {\n mouseProps.onMouseLeave = _this.onPopupMouseLeave;\n }\n\n mouseProps.onMouseDown = _this.onPopupMouseDown;\n mouseProps.onTouchStart = _this.onPopupMouseDown;\n return React.createElement(Popup, Object.assign({\n prefixCls: prefixCls,\n destroyPopupOnHide: destroyPopupOnHide,\n visible: popupVisible,\n point: alignPoint && point,\n className: popupClassName,\n align: align,\n onAlign: onPopupAlign,\n animation: popupAnimation,\n getClassNameFromAlign: _this.getPopupClassNameFromAlign\n }, mouseProps, {\n stretch: stretch,\n getRootDomNode: _this.getRootDomNode,\n style: popupStyle,\n mask: mask,\n zIndex: zIndex,\n transitionName: popupTransitionName,\n maskAnimation: maskAnimation,\n maskTransitionName: maskTransitionName,\n maskMotion: maskMotion,\n ref: _this.popupRef,\n motion: popupMotion\n }), typeof popup === 'function' ? popup() : popup);\n };\n\n _this.getContainer = function () {\n var _assertThisInitialize = _assertThisInitialized(_this),\n props = _assertThisInitialize.props;\n\n var popupContainer = document.createElement('div'); // Make sure default popup container will never cause scrollbar appearing\n // https://github.com/react-component/trigger/issues/41\n\n popupContainer.style.position = 'absolute';\n popupContainer.style.top = '0';\n popupContainer.style.left = '0';\n popupContainer.style.width = '100%';\n var mountNode = props.getPopupContainer ? props.getPopupContainer(_this.getRootDomNode()) : props.getDocument().body;\n mountNode.appendChild(popupContainer);\n return popupContainer;\n };\n\n _this.setPoint = function (point) {\n var alignPoint = _this.props.alignPoint;\n if (!alignPoint || !point) return;\n\n _this.setState({\n point: {\n pageX: point.pageX,\n pageY: point.pageY\n }\n });\n };\n\n _this.handlePortalUpdate = function () {\n if (_this.state.prevPopupVisible !== _this.state.popupVisible) {\n _this.props.afterPopupVisibleChange(_this.state.popupVisible);\n }\n };\n\n var popupVisible;\n\n if ('popupVisible' in props) {\n popupVisible = !!props.popupVisible;\n } else {\n popupVisible = !!props.defaultPopupVisible;\n }\n\n _this.state = {\n prevPopupVisible: popupVisible,\n popupVisible: popupVisible\n };\n ALL_HANDLERS.forEach(function (h) {\n _this[\"fire\".concat(h)] = function (e) {\n _this.fireEvents(h, e);\n };\n });\n return _this;\n }\n\n _createClass(Trigger, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.componentDidUpdate();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {\n var props = this.props;\n var state = this.state; // We must listen to `mousedown` or `touchstart`, edge case:\n // https://github.com/ant-design/ant-design/issues/5804\n // https://github.com/react-component/calendar/issues/250\n // https://github.com/react-component/trigger/issues/50\n\n if (state.popupVisible) {\n var currentDocument;\n\n if (!this.clickOutsideHandler && (this.isClickToHide() || this.isContextMenuToShow())) {\n currentDocument = props.getDocument();\n this.clickOutsideHandler = addEventListener(currentDocument, 'mousedown', this.onDocumentClick);\n } // always hide on mobile\n\n\n if (!this.touchOutsideHandler) {\n currentDocument = currentDocument || props.getDocument();\n this.touchOutsideHandler = addEventListener(currentDocument, 'touchstart', this.onDocumentClick);\n } // close popup when trigger type contains 'onContextMenu' and document is scrolling.\n\n\n if (!this.contextMenuOutsideHandler1 && this.isContextMenuToShow()) {\n currentDocument = currentDocument || props.getDocument();\n this.contextMenuOutsideHandler1 = addEventListener(currentDocument, 'scroll', this.onContextMenuClose);\n } // close popup when trigger type contains 'onContextMenu' and window is blur.\n\n\n if (!this.contextMenuOutsideHandler2 && this.isContextMenuToShow()) {\n this.contextMenuOutsideHandler2 = addEventListener(window, 'blur', this.onContextMenuClose);\n }\n\n return;\n }\n\n this.clearOutsideHandler();\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n this.clearDelayTimer();\n this.clearOutsideHandler();\n clearTimeout(this.mouseDownTimeout);\n }\n }, {\n key: \"getPopupDomNode\",\n value: function getPopupDomNode() {\n // for test\n if (this.popupRef.current && this.popupRef.current.popupRef.current) {\n return this.popupRef.current.popupRef.current;\n }\n\n return null;\n }\n }, {\n key: \"getPopupAlign\",\n value: function getPopupAlign() {\n var props = this.props;\n var popupPlacement = props.popupPlacement,\n popupAlign = props.popupAlign,\n builtinPlacements = props.builtinPlacements;\n\n if (popupPlacement && builtinPlacements) {\n return getAlignFromPlacement(builtinPlacements, popupPlacement, popupAlign);\n }\n\n return popupAlign;\n }\n /**\n * @param popupVisible Show or not the popup element\n * @param event SyntheticEvent, used for `pointAlign`\n */\n\n }, {\n key: \"setPopupVisible\",\n value: function setPopupVisible(popupVisible, event) {\n var alignPoint = this.props.alignPoint;\n var prevPopupVisible = this.state.popupVisible;\n this.clearDelayTimer();\n\n if (prevPopupVisible !== popupVisible) {\n if (!('popupVisible' in this.props)) {\n this.setState({\n popupVisible: popupVisible,\n prevPopupVisible: prevPopupVisible\n });\n }\n\n this.props.onPopupVisibleChange(popupVisible);\n } // Always record the point position since mouseEnterDelay will delay the show\n\n\n if (alignPoint && event) {\n this.setPoint(event);\n }\n }\n }, {\n key: \"delaySetPopupVisible\",\n value: function delaySetPopupVisible(visible, delayS, event) {\n var _this2 = this;\n\n var delay = delayS * 1000;\n this.clearDelayTimer();\n\n if (delay) {\n var point = event ? {\n pageX: event.pageX,\n pageY: event.pageY\n } : null;\n this.delayTimer = window.setTimeout(function () {\n _this2.setPopupVisible(visible, point);\n\n _this2.clearDelayTimer();\n }, delay);\n } else {\n this.setPopupVisible(visible, event);\n }\n }\n }, {\n key: \"clearDelayTimer\",\n value: function clearDelayTimer() {\n if (this.delayTimer) {\n clearTimeout(this.delayTimer);\n this.delayTimer = null;\n }\n }\n }, {\n key: \"clearOutsideHandler\",\n value: function clearOutsideHandler() {\n if (this.clickOutsideHandler) {\n this.clickOutsideHandler.remove();\n this.clickOutsideHandler = null;\n }\n\n if (this.contextMenuOutsideHandler1) {\n this.contextMenuOutsideHandler1.remove();\n this.contextMenuOutsideHandler1 = null;\n }\n\n if (this.contextMenuOutsideHandler2) {\n this.contextMenuOutsideHandler2.remove();\n this.contextMenuOutsideHandler2 = null;\n }\n\n if (this.touchOutsideHandler) {\n this.touchOutsideHandler.remove();\n this.touchOutsideHandler = null;\n }\n }\n }, {\n key: \"createTwoChains\",\n value: function createTwoChains(event) {\n var childPros = this.props.children.props;\n var props = this.props;\n\n if (childPros[event] && props[event]) {\n return this[\"fire\".concat(event)];\n }\n\n return childPros[event] || props[event];\n }\n }, {\n key: \"isClickToShow\",\n value: function isClickToShow() {\n var _this$props3 = this.props,\n action = _this$props3.action,\n showAction = _this$props3.showAction;\n return action.indexOf('click') !== -1 || showAction.indexOf('click') !== -1;\n }\n }, {\n key: \"isContextMenuToShow\",\n value: function isContextMenuToShow() {\n var _this$props4 = this.props,\n action = _this$props4.action,\n showAction = _this$props4.showAction;\n return action.indexOf('contextMenu') !== -1 || showAction.indexOf('contextMenu') !== -1;\n }\n }, {\n key: \"isClickToHide\",\n value: function isClickToHide() {\n var _this$props5 = this.props,\n action = _this$props5.action,\n hideAction = _this$props5.hideAction;\n return action.indexOf('click') !== -1 || hideAction.indexOf('click') !== -1;\n }\n }, {\n key: \"isMouseEnterToShow\",\n value: function isMouseEnterToShow() {\n var _this$props6 = this.props,\n action = _this$props6.action,\n showAction = _this$props6.showAction;\n return action.indexOf('hover') !== -1 || showAction.indexOf('mouseEnter') !== -1;\n }\n }, {\n key: \"isMouseLeaveToHide\",\n value: function isMouseLeaveToHide() {\n var _this$props7 = this.props,\n action = _this$props7.action,\n hideAction = _this$props7.hideAction;\n return action.indexOf('hover') !== -1 || hideAction.indexOf('mouseLeave') !== -1;\n }\n }, {\n key: \"isFocusToShow\",\n value: function isFocusToShow() {\n var _this$props8 = this.props,\n action = _this$props8.action,\n showAction = _this$props8.showAction;\n return action.indexOf('focus') !== -1 || showAction.indexOf('focus') !== -1;\n }\n }, {\n key: \"isBlurToHide\",\n value: function isBlurToHide() {\n var _this$props9 = this.props,\n action = _this$props9.action,\n hideAction = _this$props9.hideAction;\n return action.indexOf('focus') !== -1 || hideAction.indexOf('blur') !== -1;\n }\n }, {\n key: \"forcePopupAlign\",\n value: function forcePopupAlign() {\n if (this.state.popupVisible && this.popupRef.current && this.popupRef.current.alignRef.current) {\n this.popupRef.current.alignRef.current.forceAlign();\n }\n }\n }, {\n key: \"fireEvents\",\n value: function fireEvents(type, e) {\n var childCallback = this.props.children.props[type];\n\n if (childCallback) {\n childCallback(e);\n }\n\n var callback = this.props[type];\n\n if (callback) {\n callback(e);\n }\n }\n }, {\n key: \"close\",\n value: function close() {\n this.setPopupVisible(false);\n }\n }, {\n key: \"render\",\n value: function render() {\n var popupVisible = this.state.popupVisible;\n var _this$props10 = this.props,\n children = _this$props10.children,\n forceRender = _this$props10.forceRender,\n alignPoint = _this$props10.alignPoint,\n className = _this$props10.className,\n autoDestroy = _this$props10.autoDestroy;\n var child = React.Children.only(children);\n var newChildProps = {\n key: 'trigger'\n };\n\n if (this.isContextMenuToShow()) {\n newChildProps.onContextMenu = this.onContextMenu;\n } else {\n newChildProps.onContextMenu = this.createTwoChains('onContextMenu');\n }\n\n if (this.isClickToHide() || this.isClickToShow()) {\n newChildProps.onClick = this.onClick;\n newChildProps.onMouseDown = this.onMouseDown;\n newChildProps.onTouchStart = this.onTouchStart;\n } else {\n newChildProps.onClick = this.createTwoChains('onClick');\n newChildProps.onMouseDown = this.createTwoChains('onMouseDown');\n newChildProps.onTouchStart = this.createTwoChains('onTouchStart');\n }\n\n if (this.isMouseEnterToShow()) {\n newChildProps.onMouseEnter = this.onMouseEnter;\n\n if (alignPoint) {\n newChildProps.onMouseMove = this.onMouseMove;\n }\n } else {\n newChildProps.onMouseEnter = this.createTwoChains('onMouseEnter');\n }\n\n if (this.isMouseLeaveToHide()) {\n newChildProps.onMouseLeave = this.onMouseLeave;\n } else {\n newChildProps.onMouseLeave = this.createTwoChains('onMouseLeave');\n }\n\n if (this.isFocusToShow() || this.isBlurToHide()) {\n newChildProps.onFocus = this.onFocus;\n newChildProps.onBlur = this.onBlur;\n } else {\n newChildProps.onFocus = this.createTwoChains('onFocus');\n newChildProps.onBlur = this.createTwoChains('onBlur');\n }\n\n var childrenClassName = classNames(child && child.props && child.props.className, className);\n\n if (childrenClassName) {\n newChildProps.className = childrenClassName;\n }\n\n var cloneProps = _objectSpread({}, newChildProps);\n\n if (supportRef(child)) {\n cloneProps.ref = composeRef(this.triggerRef, child.ref);\n }\n\n var trigger = React.cloneElement(child, cloneProps);\n var portal; // prevent unmounting after it's rendered\n\n if (popupVisible || this.popupRef.current || forceRender) {\n portal = React.createElement(PortalComponent, {\n key: \"portal\",\n getContainer: this.getContainer,\n didUpdate: this.handlePortalUpdate\n }, this.getComponent());\n }\n\n if (!popupVisible && autoDestroy) {\n portal = null;\n }\n\n return React.createElement(TriggerContext.Provider, {\n value: {\n onPopupMouseDown: this.onPopupMouseDown\n }\n }, trigger, portal);\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(_ref, prevState) {\n var popupVisible = _ref.popupVisible;\n var newState = {};\n\n if (popupVisible !== undefined && prevState.popupVisible !== popupVisible) {\n newState.popupVisible = popupVisible;\n newState.prevPopupVisible = prevState.popupVisible;\n }\n\n return newState;\n }\n }]);\n\n return Trigger;\n }(React.Component);\n\n Trigger.contextType = TriggerContext;\n Trigger.defaultProps = {\n prefixCls: 'rc-trigger-popup',\n getPopupClassNameFromAlign: returnEmptyString,\n getDocument: returnDocument,\n onPopupVisibleChange: noop,\n afterPopupVisibleChange: noop,\n onPopupAlign: noop,\n popupClassName: '',\n mouseEnterDelay: 0,\n mouseLeaveDelay: 0.1,\n focusDelay: 0,\n blurDelay: 0.15,\n popupStyle: {},\n destroyPopupOnHide: false,\n popupAlign: {},\n defaultPopupVisible: false,\n mask: false,\n maskClosable: true,\n action: [],\n showAction: [],\n hideAction: [],\n autoDestroy: false\n };\n return Trigger;\n}\nexport default generateTrigger(Portal);","export default function contains(root, n) {\n var node = n;\n\n while (node) {\n if (node === root) {\n return true;\n }\n\n node = node.parentNode;\n }\n\n return false;\n}","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport * as React from 'react';\nexport var MiniStoreContext = React.createContext(null);\nvar Provider = /** @class */ (function (_super) {\n __extends(Provider, _super);\n function Provider() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n Provider.prototype.render = function () {\n return (React.createElement(MiniStoreContext.Provider, { value: this.props.store }, this.props.children));\n };\n return Provider;\n}(React.Component));\nexport { Provider };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport * as React from 'react';\nimport shallowEqual from 'shallowequal';\nimport hoistStatics from 'hoist-non-react-statics';\nimport { MiniStoreContext } from './Provider';\nfunction getDisplayName(WrappedComponent) {\n return WrappedComponent.displayName || WrappedComponent.name || 'Component';\n}\nvar defaultMapStateToProps = function () { return ({}); };\nexport function connect(mapStateToProps, options) {\n if (options === void 0) { options = {}; }\n var shouldSubscribe = !!mapStateToProps;\n var finalMapStateToProps = mapStateToProps || defaultMapStateToProps;\n return function wrapWithConnect(WrappedComponent) {\n var Connect = /** @class */ (function (_super) {\n __extends(Connect, _super);\n function Connect(props, context) {\n var _this = _super.call(this, props, context) || this;\n _this.unsubscribe = null;\n _this.handleChange = function () {\n if (!_this.unsubscribe) {\n return;\n }\n var nextState = finalMapStateToProps(_this.store.getState(), _this.props);\n _this.setState({ subscribed: nextState });\n };\n _this.store = _this.context;\n _this.state = {\n subscribed: finalMapStateToProps(_this.store.getState(), props),\n store: _this.store,\n props: props,\n };\n return _this;\n }\n Connect.getDerivedStateFromProps = function (props, prevState) {\n // using ownProps\n if (mapStateToProps && mapStateToProps.length === 2 && props !== prevState.props) {\n return {\n subscribed: finalMapStateToProps(prevState.store.getState(), props),\n props: props,\n };\n }\n return { props: props };\n };\n Connect.prototype.componentDidMount = function () {\n this.trySubscribe();\n };\n Connect.prototype.componentWillUnmount = function () {\n this.tryUnsubscribe();\n };\n Connect.prototype.shouldComponentUpdate = function (nextProps, nextState) {\n return (!shallowEqual(this.props, nextProps) ||\n !shallowEqual(this.state.subscribed, nextState.subscribed));\n };\n Connect.prototype.trySubscribe = function () {\n if (shouldSubscribe) {\n this.unsubscribe = this.store.subscribe(this.handleChange);\n this.handleChange();\n }\n };\n Connect.prototype.tryUnsubscribe = function () {\n if (this.unsubscribe) {\n this.unsubscribe();\n this.unsubscribe = null;\n }\n };\n Connect.prototype.render = function () {\n var props = __assign(__assign(__assign({}, this.props), this.state.subscribed), { store: this.store });\n return React.createElement(WrappedComponent, __assign({}, props, { ref: this.props.miniStoreForwardedRef }));\n };\n Connect.displayName = \"Connect(\" + getDisplayName(WrappedComponent) + \")\";\n Connect.contextType = MiniStoreContext;\n return Connect;\n }(React.Component));\n if (options.forwardRef) {\n var forwarded = React.forwardRef(function (props, ref) {\n return React.createElement(Connect, __assign({}, props, { miniStoreForwardedRef: ref }));\n });\n return hoistStatics(forwarded, WrappedComponent);\n }\n return hoistStatics(Connect, WrappedComponent);\n };\n}\n","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nexport function create(initialState) {\n var state = initialState;\n var listeners = [];\n function setState(partial) {\n state = __assign(__assign({}, state), partial);\n for (var i = 0; i < listeners.length; i++) {\n listeners[i]();\n }\n }\n function getState() {\n return state;\n }\n function subscribe(listener) {\n listeners.push(listener);\n return function unsubscribe() {\n var index = listeners.indexOf(listener);\n listeners.splice(index, 1);\n };\n }\n return {\n setState: setState,\n getState: getState,\n subscribe: subscribe,\n };\n}\n","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\n// MIT License from https://github.com/kaimallea/isMobile\nvar applePhone = /iPhone/i;\nvar appleIpod = /iPod/i;\nvar appleTablet = /iPad/i;\nvar androidPhone = /\\bAndroid(?:.+)Mobile\\b/i; // Match 'Android' AND 'Mobile'\n\nvar androidTablet = /Android/i;\nvar amazonPhone = /\\bAndroid(?:.+)SD4930UR\\b/i;\nvar amazonTablet = /\\bAndroid(?:.+)(?:KF[A-Z]{2,4})\\b/i;\nvar windowsPhone = /Windows Phone/i;\nvar windowsTablet = /\\bWindows(?:.+)ARM\\b/i; // Match 'Windows' AND 'ARM'\n\nvar otherBlackberry = /BlackBerry/i;\nvar otherBlackberry10 = /BB10/i;\nvar otherOpera = /Opera Mini/i;\nvar otherChrome = /\\b(CriOS|Chrome)(?:.+)Mobile/i;\nvar otherFirefox = /Mobile(?:.+)Firefox\\b/i; // Match 'Mobile' AND 'Firefox'\n\nfunction match(regex, userAgent) {\n return regex.test(userAgent);\n}\n\nfunction isMobile(userAgent) {\n var ua = userAgent || (typeof navigator !== 'undefined' ? navigator.userAgent : ''); // Facebook mobile app's integrated browser adds a bunch of strings that\n // match everything. Strip it out if it exists.\n\n var tmp = ua.split('[FBAN');\n\n if (typeof tmp[1] !== 'undefined') {\n var _tmp = tmp;\n\n var _tmp2 = _slicedToArray(_tmp, 1);\n\n ua = _tmp2[0];\n } // Twitter mobile app's integrated browser on iPad adds a \"Twitter for\n // iPhone\" string. Same probably happens on other tablet platforms.\n // This will confuse detection so strip it out if it exists.\n\n\n tmp = ua.split('Twitter');\n\n if (typeof tmp[1] !== 'undefined') {\n var _tmp3 = tmp;\n\n var _tmp4 = _slicedToArray(_tmp3, 1);\n\n ua = _tmp4[0];\n }\n\n var result = {\n apple: {\n phone: match(applePhone, ua) && !match(windowsPhone, ua),\n ipod: match(appleIpod, ua),\n tablet: !match(applePhone, ua) && match(appleTablet, ua) && !match(windowsPhone, ua),\n device: (match(applePhone, ua) || match(appleIpod, ua) || match(appleTablet, ua)) && !match(windowsPhone, ua)\n },\n amazon: {\n phone: match(amazonPhone, ua),\n tablet: !match(amazonPhone, ua) && match(amazonTablet, ua),\n device: match(amazonPhone, ua) || match(amazonTablet, ua)\n },\n android: {\n phone: !match(windowsPhone, ua) && match(amazonPhone, ua) || !match(windowsPhone, ua) && match(androidPhone, ua),\n tablet: !match(windowsPhone, ua) && !match(amazonPhone, ua) && !match(androidPhone, ua) && (match(amazonTablet, ua) || match(androidTablet, ua)),\n device: !match(windowsPhone, ua) && (match(amazonPhone, ua) || match(amazonTablet, ua) || match(androidPhone, ua) || match(androidTablet, ua)) || match(/\\bokhttp\\b/i, ua)\n },\n windows: {\n phone: match(windowsPhone, ua),\n tablet: match(windowsTablet, ua),\n device: match(windowsPhone, ua) || match(windowsTablet, ua)\n },\n other: {\n blackberry: match(otherBlackberry, ua),\n blackberry10: match(otherBlackberry10, ua),\n opera: match(otherOpera, ua),\n firefox: match(otherFirefox, ua),\n chrome: match(otherChrome, ua),\n device: match(otherBlackberry, ua) || match(otherBlackberry10, ua) || match(otherOpera, ua) || match(otherFirefox, ua) || match(otherChrome, ua)\n },\n // Additional\n any: null,\n phone: null,\n tablet: null\n };\n result.any = result.apple.device || result.android.device || result.windows.device || result.other.device; // excludes 'other' devices and ipods, targeting touchscreen phones\n\n result.phone = result.apple.phone || result.android.phone || result.windows.phone;\n result.tablet = result.apple.tablet || result.android.tablet || result.windows.tablet;\n return result;\n}\n\nvar defaultResult = _objectSpread(_objectSpread({}, isMobile()), {}, {\n isMobile: isMobile\n});\n\nexport default defaultResult;","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport * as React from 'react';\nimport isMobile from './utils/isMobile';\nexport function noop() {}\nexport function getKeyFromChildrenIndex(child, menuEventKey, index) {\n var prefix = menuEventKey || '';\n return child.key || \"\".concat(prefix, \"item_\").concat(index);\n}\nexport function getMenuIdFromSubMenuEventKey(eventKey) {\n return \"\".concat(eventKey, \"-menu-\");\n}\nexport function loopMenuItem(children, cb) {\n var index = -1;\n React.Children.forEach(children, function (c) {\n index += 1;\n\n if (c && c.type && c.type.isMenuItemGroup) {\n React.Children.forEach(c.props.children, function (c2) {\n index += 1;\n cb(c2, index);\n });\n } else {\n cb(c, index);\n }\n });\n}\nexport function loopMenuItemRecursively(children, keys, ret) {\n /* istanbul ignore if */\n if (!children || ret.find) {\n return;\n }\n\n React.Children.forEach(children, function (c) {\n if (c) {\n var construct = c.type;\n\n if (!construct || !(construct.isSubMenu || construct.isMenuItem || construct.isMenuItemGroup)) {\n return;\n }\n\n if (keys.indexOf(c.key) !== -1) {\n ret.find = true;\n } else if (c.props.children) {\n loopMenuItemRecursively(c.props.children, keys, ret);\n }\n }\n });\n}\nexport var menuAllProps = ['defaultSelectedKeys', 'selectedKeys', 'defaultOpenKeys', 'openKeys', 'mode', 'getPopupContainer', 'onSelect', 'onDeselect', 'onDestroy', 'openTransitionName', 'openAnimation', 'subMenuOpenDelay', 'subMenuCloseDelay', 'forceSubMenuRender', 'triggerSubMenuAction', 'level', 'selectable', 'multiple', 'onOpenChange', 'visible', 'focusable', 'defaultActiveFirst', 'prefixCls', 'inlineIndent', 'parentMenu', 'title', 'rootPrefixCls', 'eventKey', 'active', 'onItemHover', 'onTitleMouseEnter', 'onTitleMouseLeave', 'onTitleClick', 'popupAlign', 'popupOffset', 'isOpen', 'renderMenuItem', 'manualRef', 'subMenuKey', 'disabled', 'index', 'isSelected', 'store', 'activeKey', 'builtinPlacements', 'overflowedIndicator', 'motion', // the following keys found need to be removed from test regression\n'attribute', 'value', 'popupClassName', 'inlineCollapsed', 'menu', 'theme', 'itemIcon', 'expandIcon']; // ref: https://github.com/ant-design/ant-design/issues/14007\n// ref: https://bugs.chromium.org/p/chromium/issues/detail?id=360889\n// getBoundingClientRect return the full precision value, which is\n// not the same behavior as on chrome. Set the precision to 6 to\n// unify their behavior\n\nexport var getWidth = function getWidth(elem) {\n var includeMargin = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n var width = elem && typeof elem.getBoundingClientRect === 'function' && elem.getBoundingClientRect().width;\n\n if (width) {\n if (includeMargin) {\n var _getComputedStyle = getComputedStyle(elem),\n marginLeft = _getComputedStyle.marginLeft,\n marginRight = _getComputedStyle.marginRight;\n\n width += +marginLeft.replace('px', '') + +marginRight.replace('px', '');\n }\n\n width = +width.toFixed(6);\n }\n\n return width || 0;\n};\nexport var setStyle = function setStyle(elem, styleProperty, value) {\n if (elem && _typeof(elem.style) === 'object') {\n elem.style[styleProperty] = value;\n }\n};\nexport var isMobileDevice = function isMobileDevice() {\n return isMobile.any;\n};","var autoAdjustOverflow = {\n adjustX: 1,\n adjustY: 1\n};\nexport var placements = {\n topLeft: {\n points: ['bl', 'tl'],\n overflow: autoAdjustOverflow,\n offset: [0, -7]\n },\n bottomLeft: {\n points: ['tl', 'bl'],\n overflow: autoAdjustOverflow,\n offset: [0, 7]\n },\n leftTop: {\n points: ['tr', 'tl'],\n overflow: autoAdjustOverflow,\n offset: [-4, 0]\n },\n rightTop: {\n points: ['tl', 'tr'],\n overflow: autoAdjustOverflow,\n offset: [4, 0]\n }\n};\nexport var placementsRtl = {\n topLeft: {\n points: ['bl', 'tl'],\n overflow: autoAdjustOverflow,\n offset: [0, -7]\n },\n bottomLeft: {\n points: ['tl', 'bl'],\n overflow: autoAdjustOverflow,\n offset: [0, 7]\n },\n rightTop: {\n points: ['tr', 'tl'],\n overflow: autoAdjustOverflow,\n offset: [-4, 0]\n },\n leftTop: {\n points: ['tl', 'tr'],\n overflow: autoAdjustOverflow,\n offset: [4, 0]\n }\n};\nexport default placements;","import _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport Trigger from 'rc-trigger';\nimport KeyCode from \"rc-util/es/KeyCode\";\nimport CSSMotion from 'rc-motion';\nimport classNames from 'classnames';\nimport { connect } from 'mini-store';\nimport SubPopupMenu from './SubPopupMenu';\nimport { placements, placementsRtl } from './placements';\nimport { noop, loopMenuItemRecursively, getMenuIdFromSubMenuEventKey, menuAllProps } from './util';\nvar guid = 0;\nvar popupPlacementMap = {\n horizontal: 'bottomLeft',\n vertical: 'rightTop',\n 'vertical-left': 'rightTop',\n 'vertical-right': 'leftTop'\n};\n\nvar updateDefaultActiveFirst = function updateDefaultActiveFirst(store, eventKey, defaultActiveFirst) {\n var menuId = getMenuIdFromSubMenuEventKey(eventKey);\n var state = store.getState();\n store.setState({\n defaultActiveFirst: _objectSpread(_objectSpread({}, state.defaultActiveFirst), {}, _defineProperty({}, menuId, defaultActiveFirst))\n });\n};\n\nexport var SubMenu = /*#__PURE__*/function (_React$Component) {\n _inherits(SubMenu, _React$Component);\n\n var _super = _createSuper(SubMenu);\n\n function SubMenu(props) {\n var _this;\n\n _classCallCheck(this, SubMenu);\n\n _this = _super.call(this, props);\n\n _this.onDestroy = function (key) {\n _this.props.onDestroy(key);\n };\n /**\n * note:\n * This legacy code that `onKeyDown` is called by parent instead of dom self.\n * which need return code to check if this event is handled\n */\n\n\n _this.onKeyDown = function (e) {\n var keyCode = e.keyCode;\n var menu = _this.menuInstance;\n var _this$props = _this.props,\n isOpen = _this$props.isOpen,\n store = _this$props.store;\n\n if (keyCode === KeyCode.ENTER) {\n _this.onTitleClick(e);\n\n updateDefaultActiveFirst(store, _this.props.eventKey, true);\n return true;\n }\n\n if (keyCode === KeyCode.RIGHT) {\n if (isOpen) {\n menu.onKeyDown(e);\n } else {\n _this.triggerOpenChange(true); // need to update current menu's defaultActiveFirst value\n\n\n updateDefaultActiveFirst(store, _this.props.eventKey, true);\n }\n\n return true;\n }\n\n if (keyCode === KeyCode.LEFT) {\n var handled;\n\n if (isOpen) {\n handled = menu.onKeyDown(e);\n } else {\n return undefined;\n }\n\n if (!handled) {\n _this.triggerOpenChange(false);\n\n handled = true;\n }\n\n return handled;\n }\n\n if (isOpen && (keyCode === KeyCode.UP || keyCode === KeyCode.DOWN)) {\n return menu.onKeyDown(e);\n }\n\n return undefined;\n };\n\n _this.onOpenChange = function (e) {\n _this.props.onOpenChange(e);\n };\n\n _this.onPopupVisibleChange = function (visible) {\n _this.triggerOpenChange(visible, visible ? 'mouseenter' : 'mouseleave');\n };\n\n _this.onMouseEnter = function (e) {\n var _this$props2 = _this.props,\n key = _this$props2.eventKey,\n onMouseEnter = _this$props2.onMouseEnter,\n store = _this$props2.store;\n updateDefaultActiveFirst(store, _this.props.eventKey, false);\n onMouseEnter({\n key: key,\n domEvent: e\n });\n };\n\n _this.onMouseLeave = function (e) {\n var _this$props3 = _this.props,\n parentMenu = _this$props3.parentMenu,\n eventKey = _this$props3.eventKey,\n onMouseLeave = _this$props3.onMouseLeave;\n parentMenu.subMenuInstance = _assertThisInitialized(_this);\n onMouseLeave({\n key: eventKey,\n domEvent: e\n });\n };\n\n _this.onTitleMouseEnter = function (domEvent) {\n var _this$props4 = _this.props,\n key = _this$props4.eventKey,\n onItemHover = _this$props4.onItemHover,\n onTitleMouseEnter = _this$props4.onTitleMouseEnter;\n onItemHover({\n key: key,\n hover: true\n });\n onTitleMouseEnter({\n key: key,\n domEvent: domEvent\n });\n };\n\n _this.onTitleMouseLeave = function (e) {\n var _this$props5 = _this.props,\n parentMenu = _this$props5.parentMenu,\n eventKey = _this$props5.eventKey,\n onItemHover = _this$props5.onItemHover,\n onTitleMouseLeave = _this$props5.onTitleMouseLeave;\n parentMenu.subMenuInstance = _assertThisInitialized(_this);\n onItemHover({\n key: eventKey,\n hover: false\n });\n onTitleMouseLeave({\n key: eventKey,\n domEvent: e\n });\n };\n\n _this.onTitleClick = function (e) {\n var _assertThisInitialize = _assertThisInitialized(_this),\n props = _assertThisInitialize.props;\n\n props.onTitleClick({\n key: props.eventKey,\n domEvent: e\n });\n\n if (props.triggerSubMenuAction === 'hover') {\n return;\n }\n\n _this.triggerOpenChange(!props.isOpen, 'click');\n\n updateDefaultActiveFirst(props.store, _this.props.eventKey, false);\n };\n\n _this.onSubMenuClick = function (info) {\n // in the case of overflowed submenu\n // onClick is not copied over\n if (typeof _this.props.onClick === 'function') {\n _this.props.onClick(_this.addKeyPath(info));\n }\n };\n\n _this.onSelect = function (info) {\n _this.props.onSelect(info);\n };\n\n _this.onDeselect = function (info) {\n _this.props.onDeselect(info);\n };\n\n _this.getPrefixCls = function () {\n return \"\".concat(_this.props.rootPrefixCls, \"-submenu\");\n };\n\n _this.getActiveClassName = function () {\n return \"\".concat(_this.getPrefixCls(), \"-active\");\n };\n\n _this.getDisabledClassName = function () {\n return \"\".concat(_this.getPrefixCls(), \"-disabled\");\n };\n\n _this.getSelectedClassName = function () {\n return \"\".concat(_this.getPrefixCls(), \"-selected\");\n };\n\n _this.getOpenClassName = function () {\n return \"\".concat(_this.props.rootPrefixCls, \"-submenu-open\");\n };\n\n _this.saveMenuInstance = function (c) {\n // children menu instance\n _this.menuInstance = c;\n };\n\n _this.addKeyPath = function (info) {\n return _objectSpread(_objectSpread({}, info), {}, {\n keyPath: (info.keyPath || []).concat(_this.props.eventKey)\n });\n };\n\n _this.triggerOpenChange = function (open, type) {\n var key = _this.props.eventKey;\n\n var openChange = function openChange() {\n _this.onOpenChange({\n key: key,\n item: _assertThisInitialized(_this),\n trigger: type,\n open: open\n });\n };\n\n if (type === 'mouseenter') {\n // make sure mouseenter happen after other menu item's mouseleave\n _this.mouseenterTimeout = setTimeout(function () {\n openChange();\n }, 0);\n } else {\n openChange();\n }\n };\n\n _this.isChildrenSelected = function () {\n var ret = {\n find: false\n };\n loopMenuItemRecursively(_this.props.children, _this.props.selectedKeys, ret);\n return ret.find;\n };\n\n _this.isOpen = function () {\n return _this.props.openKeys.indexOf(_this.props.eventKey) !== -1;\n };\n\n _this.adjustWidth = function () {\n /* istanbul ignore if */\n if (!_this.subMenuTitle || !_this.menuInstance) {\n return;\n }\n\n var popupMenu = ReactDOM.findDOMNode(_this.menuInstance);\n\n if (popupMenu.offsetWidth >= _this.subMenuTitle.offsetWidth) {\n return;\n }\n /* istanbul ignore next */\n\n\n popupMenu.style.minWidth = \"\".concat(_this.subMenuTitle.offsetWidth, \"px\");\n };\n\n _this.saveSubMenuTitle = function (subMenuTitle) {\n _this.subMenuTitle = subMenuTitle;\n };\n\n _this.getBaseProps = function () {\n var _assertThisInitialize2 = _assertThisInitialized(_this),\n props = _assertThisInitialize2.props;\n\n return {\n mode: props.mode === 'horizontal' ? 'vertical' : props.mode,\n visible: _this.props.isOpen,\n level: props.level + 1,\n inlineIndent: props.inlineIndent,\n focusable: false,\n onClick: _this.onSubMenuClick,\n onSelect: _this.onSelect,\n onDeselect: _this.onDeselect,\n onDestroy: _this.onDestroy,\n selectedKeys: props.selectedKeys,\n eventKey: \"\".concat(props.eventKey, \"-menu-\"),\n openKeys: props.openKeys,\n motion: props.motion,\n onOpenChange: _this.onOpenChange,\n subMenuOpenDelay: props.subMenuOpenDelay,\n parentMenu: _assertThisInitialized(_this),\n subMenuCloseDelay: props.subMenuCloseDelay,\n forceSubMenuRender: props.forceSubMenuRender,\n triggerSubMenuAction: props.triggerSubMenuAction,\n builtinPlacements: props.builtinPlacements,\n defaultActiveFirst: props.store.getState().defaultActiveFirst[getMenuIdFromSubMenuEventKey(props.eventKey)],\n multiple: props.multiple,\n prefixCls: props.rootPrefixCls,\n id: _this.internalMenuId,\n manualRef: _this.saveMenuInstance,\n itemIcon: props.itemIcon,\n expandIcon: props.expandIcon,\n direction: props.direction\n };\n };\n\n _this.getMotion = function (mode, visible) {\n var _assertThisInitialize3 = _assertThisInitialized(_this),\n haveRendered = _assertThisInitialize3.haveRendered;\n\n var _this$props6 = _this.props,\n motion = _this$props6.motion,\n rootPrefixCls = _this$props6.rootPrefixCls; // don't show transition on first rendering (no animation for opened menu)\n // show appear transition if it's not visible (not sure why)\n // show appear transition if it's not inline mode\n\n var mergedMotion = _objectSpread(_objectSpread({}, motion), {}, {\n leavedClassName: \"\".concat(rootPrefixCls, \"-hidden\"),\n removeOnLeave: false,\n motionAppear: haveRendered || !visible || mode !== 'inline'\n });\n\n return mergedMotion;\n };\n\n var store = props.store,\n eventKey = props.eventKey;\n\n var _store$getState = store.getState(),\n defaultActiveFirst = _store$getState.defaultActiveFirst;\n\n _this.isRootMenu = false;\n var value = false;\n\n if (defaultActiveFirst) {\n value = defaultActiveFirst[eventKey];\n }\n\n updateDefaultActiveFirst(store, eventKey, value);\n return _this;\n }\n\n _createClass(SubMenu, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.componentDidUpdate();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {\n var _this2 = this;\n\n var _this$props7 = this.props,\n mode = _this$props7.mode,\n parentMenu = _this$props7.parentMenu,\n manualRef = _this$props7.manualRef; // invoke customized ref to expose component to mixin\n\n if (manualRef) {\n manualRef(this);\n }\n\n if (mode !== 'horizontal' || !parentMenu.isRootMenu || !this.props.isOpen) {\n return;\n }\n\n this.minWidthTimeout = setTimeout(function () {\n return _this2.adjustWidth();\n }, 0);\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n var _this$props8 = this.props,\n onDestroy = _this$props8.onDestroy,\n eventKey = _this$props8.eventKey;\n\n if (onDestroy) {\n onDestroy(eventKey);\n }\n /* istanbul ignore if */\n\n\n if (this.minWidthTimeout) {\n clearTimeout(this.minWidthTimeout);\n }\n /* istanbul ignore if */\n\n\n if (this.mouseenterTimeout) {\n clearTimeout(this.mouseenterTimeout);\n }\n }\n }, {\n key: \"renderChildren\",\n value: function renderChildren(children) {\n var _this3 = this;\n\n var baseProps = this.getBaseProps(); // [Legacy] getMotion must be called before `haveRendered`\n\n var mergedMotion = this.getMotion(baseProps.mode, baseProps.visible);\n this.haveRendered = true;\n this.haveOpened = this.haveOpened || baseProps.visible || baseProps.forceSubMenuRender; // never rendered not planning to, don't render\n\n if (!this.haveOpened) {\n return React.createElement(\"div\", null);\n }\n\n var direction = baseProps.direction;\n return React.createElement(CSSMotion, Object.assign({\n visible: baseProps.visible\n }, mergedMotion), function (_ref) {\n var className = _ref.className,\n style = _ref.style;\n var mergedClassName = classNames(\"\".concat(baseProps.prefixCls, \"-sub\"), className, _defineProperty({}, \"\".concat(baseProps.prefixCls, \"-rtl\"), direction === 'rtl'));\n return React.createElement(SubPopupMenu, Object.assign({}, baseProps, {\n id: _this3.internalMenuId,\n className: mergedClassName,\n style: style\n }), children);\n });\n }\n }, {\n key: \"render\",\n value: function render() {\n var _classNames2;\n\n var props = _objectSpread({}, this.props);\n\n var isOpen = props.isOpen;\n var prefixCls = this.getPrefixCls();\n var isInlineMode = props.mode === 'inline';\n var className = classNames(prefixCls, \"\".concat(prefixCls, \"-\").concat(props.mode), (_classNames2 = {}, _defineProperty(_classNames2, props.className, !!props.className), _defineProperty(_classNames2, this.getOpenClassName(), isOpen), _defineProperty(_classNames2, this.getActiveClassName(), props.active || isOpen && !isInlineMode), _defineProperty(_classNames2, this.getDisabledClassName(), props.disabled), _defineProperty(_classNames2, this.getSelectedClassName(), this.isChildrenSelected()), _classNames2));\n\n if (!this.internalMenuId) {\n if (props.eventKey) {\n this.internalMenuId = \"\".concat(props.eventKey, \"$Menu\");\n } else {\n guid += 1;\n this.internalMenuId = \"$__$\".concat(guid, \"$Menu\");\n }\n }\n\n var mouseEvents = {};\n var titleClickEvents = {};\n var titleMouseEvents = {};\n\n if (!props.disabled) {\n mouseEvents = {\n onMouseLeave: this.onMouseLeave,\n onMouseEnter: this.onMouseEnter\n }; // only works in title, not outer li\n\n titleClickEvents = {\n onClick: this.onTitleClick\n };\n titleMouseEvents = {\n onMouseEnter: this.onTitleMouseEnter,\n onMouseLeave: this.onTitleMouseLeave\n };\n }\n\n var style = {};\n var direction = props.direction;\n\n if (isInlineMode) {\n if (direction === 'rtl') {\n style.paddingRight = props.inlineIndent * props.level;\n } else {\n style.paddingLeft = props.inlineIndent * props.level;\n }\n }\n\n var ariaOwns = {}; // only set aria-owns when menu is open\n // otherwise it would be an invalid aria-owns value\n // since corresponding node cannot be found\n\n if (this.props.isOpen) {\n ariaOwns = {\n 'aria-owns': this.internalMenuId\n };\n } // expand custom icon should NOT be displayed in menu with horizontal mode.\n\n\n var icon = null;\n\n if (props.mode !== 'horizontal') {\n icon = this.props.expandIcon; // ReactNode\n\n if (typeof this.props.expandIcon === 'function') {\n icon = React.createElement(this.props.expandIcon, _objectSpread({}, this.props));\n }\n }\n\n var title = React.createElement(\"div\", Object.assign({\n ref: this.saveSubMenuTitle,\n style: style,\n className: \"\".concat(prefixCls, \"-title\"),\n role: \"button\"\n }, titleMouseEvents, titleClickEvents, {\n \"aria-expanded\": isOpen\n }, ariaOwns, {\n \"aria-haspopup\": \"true\",\n title: typeof props.title === 'string' ? props.title : undefined\n }), props.title, icon || React.createElement(\"i\", {\n className: \"\".concat(prefixCls, \"-arrow\")\n }));\n var children = this.renderChildren(props.children);\n var getPopupContainer = props.parentMenu.isRootMenu ? props.parentMenu.props.getPopupContainer : function (triggerNode) {\n return triggerNode.parentNode;\n };\n var popupPlacement = popupPlacementMap[props.mode];\n var popupAlign = props.popupOffset ? {\n offset: props.popupOffset\n } : {};\n var popupClassName = props.mode === 'inline' ? '' : props.popupClassName;\n popupClassName += direction === 'rtl' ? \" \".concat(prefixCls, \"-rtl\") : '';\n var disabled = props.disabled,\n triggerSubMenuAction = props.triggerSubMenuAction,\n subMenuOpenDelay = props.subMenuOpenDelay,\n forceSubMenuRender = props.forceSubMenuRender,\n subMenuCloseDelay = props.subMenuCloseDelay,\n builtinPlacements = props.builtinPlacements;\n menuAllProps.forEach(function (key) {\n return delete props[key];\n }); // Set onClick to null, to ignore propagated onClick event\n\n delete props.onClick;\n var placement = direction === 'rtl' ? Object.assign({}, placementsRtl, builtinPlacements) : Object.assign({}, placements, builtinPlacements);\n delete props.direction;\n return React.createElement(\"li\", Object.assign({}, props, mouseEvents, {\n className: className,\n role: \"menuitem\"\n }), isInlineMode && title, isInlineMode && children, !isInlineMode && React.createElement(Trigger, {\n prefixCls: prefixCls,\n popupClassName: classNames(\"\".concat(prefixCls, \"-popup\"), popupClassName),\n getPopupContainer: getPopupContainer,\n builtinPlacements: placement,\n popupPlacement: popupPlacement,\n popupVisible: isOpen,\n popupAlign: popupAlign,\n popup: children,\n action: disabled ? [] : [triggerSubMenuAction],\n mouseEnterDelay: subMenuOpenDelay,\n mouseLeaveDelay: subMenuCloseDelay,\n onPopupVisibleChange: this.onPopupVisibleChange,\n forceRender: forceSubMenuRender\n }, title));\n }\n }]);\n\n return SubMenu;\n}(React.Component);\nSubMenu.defaultProps = {\n onMouseEnter: noop,\n onMouseLeave: noop,\n onTitleMouseEnter: noop,\n onTitleMouseLeave: noop,\n onTitleClick: noop,\n manualRef: noop,\n mode: 'vertical',\n title: ''\n};\nvar connected = connect(function (_ref2, _ref3) {\n var openKeys = _ref2.openKeys,\n activeKey = _ref2.activeKey,\n selectedKeys = _ref2.selectedKeys;\n var eventKey = _ref3.eventKey,\n subMenuKey = _ref3.subMenuKey;\n return {\n isOpen: openKeys.indexOf(eventKey) > -1,\n active: activeKey[subMenuKey] === eventKey,\n selectedKeys: selectedKeys\n };\n})(SubMenu);\nconnected.isSubMenu = true;\nexport default connected;","import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport ResizeObserver from 'resize-observer-polyfill';\nimport SubMenu from './SubMenu';\nimport { getWidth, setStyle, menuAllProps } from './util';\nvar MENUITEM_OVERFLOWED_CLASSNAME = 'menuitem-overflowed';\nvar FLOAT_PRECISION_ADJUST = 0.5;\n\nvar DOMWrap = /*#__PURE__*/function (_React$Component) {\n _inherits(DOMWrap, _React$Component);\n\n var _super = _createSuper(DOMWrap);\n\n function DOMWrap() {\n var _this;\n\n _classCallCheck(this, DOMWrap);\n\n _this = _super.apply(this, arguments);\n _this.resizeObserver = null;\n _this.mutationObserver = null; // original scroll size of the list\n\n _this.originalTotalWidth = 0; // copy of overflowed items\n\n _this.overflowedItems = []; // cache item of the original items (so we can track the size and order)\n\n _this.menuItemSizes = [];\n _this.cancelFrameId = null;\n _this.state = {\n lastVisibleIndex: undefined\n }; // get all valid menuItem nodes\n\n _this.getMenuItemNodes = function () {\n var prefixCls = _this.props.prefixCls;\n var ul = ReactDOM.findDOMNode(_assertThisInitialized(_this));\n\n if (!ul) {\n return [];\n } // filter out all overflowed indicator placeholder\n\n\n return [].slice.call(ul.children).filter(function (node) {\n return node.className.split(' ').indexOf(\"\".concat(prefixCls, \"-overflowed-submenu\")) < 0;\n });\n };\n\n _this.getOverflowedSubMenuItem = function (keyPrefix, overflowedItems, renderPlaceholder) {\n var _this$props = _this.props,\n overflowedIndicator = _this$props.overflowedIndicator,\n level = _this$props.level,\n mode = _this$props.mode,\n prefixCls = _this$props.prefixCls,\n theme = _this$props.theme;\n\n if (level !== 1 || mode !== 'horizontal') {\n return null;\n } // put all the overflowed item inside a submenu\n // with a title of overflow indicator ('...')\n\n\n var copy = _this.props.children[0];\n\n var _copy$props = copy.props,\n throwAway = _copy$props.children,\n title = _copy$props.title,\n propStyle = _copy$props.style,\n rest = _objectWithoutProperties(_copy$props, [\"children\", \"title\", \"style\"]);\n\n var style = _objectSpread({}, propStyle);\n\n var key = \"\".concat(keyPrefix, \"-overflowed-indicator\");\n var eventKey = \"\".concat(keyPrefix, \"-overflowed-indicator\");\n\n if (overflowedItems.length === 0 && renderPlaceholder !== true) {\n style = _objectSpread(_objectSpread({}, style), {}, {\n display: 'none'\n });\n } else if (renderPlaceholder) {\n style = _objectSpread(_objectSpread({}, style), {}, {\n visibility: 'hidden',\n // prevent from taking normal dom space\n position: 'absolute'\n });\n key = \"\".concat(key, \"-placeholder\");\n eventKey = \"\".concat(eventKey, \"-placeholder\");\n }\n\n var popupClassName = theme ? \"\".concat(prefixCls, \"-\").concat(theme) : '';\n var props = {};\n menuAllProps.forEach(function (k) {\n if (rest[k] !== undefined) {\n props[k] = rest[k];\n }\n });\n return React.createElement(SubMenu, Object.assign({\n title: overflowedIndicator,\n className: \"\".concat(prefixCls, \"-overflowed-submenu\"),\n popupClassName: popupClassName\n }, props, {\n key: key,\n eventKey: eventKey,\n disabled: false,\n style: style\n }), overflowedItems);\n }; // memorize rendered menuSize\n\n\n _this.setChildrenWidthAndResize = function () {\n if (_this.props.mode !== 'horizontal') {\n return;\n }\n\n var ul = ReactDOM.findDOMNode(_assertThisInitialized(_this));\n\n if (!ul) {\n return;\n }\n\n var ulChildrenNodes = ul.children;\n\n if (!ulChildrenNodes || ulChildrenNodes.length === 0) {\n return;\n }\n\n var lastOverflowedIndicatorPlaceholder = ul.children[ulChildrenNodes.length - 1]; // need last overflowed indicator for calculating length;\n\n setStyle(lastOverflowedIndicatorPlaceholder, 'display', 'inline-block');\n\n var menuItemNodes = _this.getMenuItemNodes(); // reset display attribute for all hidden elements caused by overflow to calculate updated width\n // and then reset to original state after width calculation\n\n\n var overflowedItems = menuItemNodes.filter(function (c) {\n return c.className.split(' ').indexOf(MENUITEM_OVERFLOWED_CLASSNAME) >= 0;\n });\n overflowedItems.forEach(function (c) {\n setStyle(c, 'display', 'inline-block');\n });\n _this.menuItemSizes = menuItemNodes.map(function (c) {\n return getWidth(c, true);\n });\n overflowedItems.forEach(function (c) {\n setStyle(c, 'display', 'none');\n });\n _this.overflowedIndicatorWidth = getWidth(ul.children[ul.children.length - 1], true);\n _this.originalTotalWidth = _this.menuItemSizes.reduce(function (acc, cur) {\n return acc + cur;\n }, 0);\n\n _this.handleResize(); // prevent the overflowed indicator from taking space;\n\n\n setStyle(lastOverflowedIndicatorPlaceholder, 'display', 'none');\n };\n\n _this.handleResize = function () {\n if (_this.props.mode !== 'horizontal') {\n return;\n }\n\n var ul = ReactDOM.findDOMNode(_assertThisInitialized(_this));\n\n if (!ul) {\n return;\n }\n\n var width = getWidth(ul);\n _this.overflowedItems = [];\n var currentSumWidth = 0; // index for last visible child in horizontal mode\n\n var lastVisibleIndex; // float number comparison could be problematic\n // e.g. 0.1 + 0.2 > 0.3 =====> true\n // thus using FLOAT_PRECISION_ADJUST as buffer to help the situation\n\n if (_this.originalTotalWidth > width + FLOAT_PRECISION_ADJUST) {\n lastVisibleIndex = -1;\n\n _this.menuItemSizes.forEach(function (liWidth) {\n currentSumWidth += liWidth;\n\n if (currentSumWidth + _this.overflowedIndicatorWidth <= width) {\n lastVisibleIndex += 1;\n }\n });\n }\n\n _this.setState({\n lastVisibleIndex: lastVisibleIndex\n });\n };\n\n return _this;\n }\n\n _createClass(DOMWrap, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n var _this2 = this;\n\n this.setChildrenWidthAndResize();\n\n if (this.props.level === 1 && this.props.mode === 'horizontal') {\n var menuUl = ReactDOM.findDOMNode(this);\n\n if (!menuUl) {\n return;\n }\n\n this.resizeObserver = new ResizeObserver(function (entries) {\n entries.forEach(function () {\n var cancelFrameId = _this2.cancelFrameId;\n cancelAnimationFrame(cancelFrameId);\n _this2.cancelFrameId = requestAnimationFrame(_this2.setChildrenWidthAndResize);\n });\n });\n [].slice.call(menuUl.children).concat(menuUl).forEach(function (el) {\n _this2.resizeObserver.observe(el);\n });\n\n if (typeof MutationObserver !== 'undefined') {\n this.mutationObserver = new MutationObserver(function () {\n _this2.resizeObserver.disconnect();\n\n [].slice.call(menuUl.children).concat(menuUl).forEach(function (el) {\n _this2.resizeObserver.observe(el);\n });\n\n _this2.setChildrenWidthAndResize();\n });\n this.mutationObserver.observe(menuUl, {\n attributes: false,\n childList: true,\n subTree: false\n });\n }\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n if (this.resizeObserver) {\n this.resizeObserver.disconnect();\n }\n\n if (this.mutationObserver) {\n this.mutationObserver.disconnect();\n }\n\n cancelAnimationFrame(this.cancelFrameId);\n }\n }, {\n key: \"renderChildren\",\n value: function renderChildren(children) {\n var _this3 = this;\n\n // need to take care of overflowed items in horizontal mode\n var lastVisibleIndex = this.state.lastVisibleIndex;\n return (children || []).reduce(function (acc, childNode, index) {\n var item = childNode;\n\n if (_this3.props.mode === 'horizontal') {\n var overflowed = _this3.getOverflowedSubMenuItem(childNode.props.eventKey, []);\n\n if (lastVisibleIndex !== undefined && _this3.props.className.indexOf(\"\".concat(_this3.props.prefixCls, \"-root\")) !== -1) {\n if (index > lastVisibleIndex) {\n item = React.cloneElement(childNode, // 这里修改 eventKey 是为了防止隐藏状态下还会触发 openkeys 事件\n {\n style: {\n display: 'none'\n },\n eventKey: \"\".concat(childNode.props.eventKey, \"-hidden\"),\n\n /**\n * Legacy code. Here `className` never used:\n * https://github.com/react-component/menu/commit/4cd6b49fce9d116726f4ea00dda85325d6f26500#diff-e2fa48f75c2dd2318295cde428556a76R240\n */\n className: \"\".concat(MENUITEM_OVERFLOWED_CLASSNAME)\n });\n }\n\n if (index === lastVisibleIndex + 1) {\n _this3.overflowedItems = children.slice(lastVisibleIndex + 1).map(function (c) {\n return React.cloneElement(c, // children[index].key will become '.$key' in clone by default,\n // we have to overwrite with the correct key explicitly\n {\n key: c.props.eventKey,\n mode: 'vertical-left'\n });\n });\n overflowed = _this3.getOverflowedSubMenuItem(childNode.props.eventKey, _this3.overflowedItems);\n }\n }\n\n var ret = [].concat(_toConsumableArray(acc), [overflowed, item]);\n\n if (index === children.length - 1) {\n // need a placeholder for calculating overflowed indicator width\n ret.push(_this3.getOverflowedSubMenuItem(childNode.props.eventKey, [], true));\n }\n\n return ret;\n }\n\n return [].concat(_toConsumableArray(acc), [item]);\n }, []);\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this$props2 = this.props,\n visible = _this$props2.visible,\n prefixCls = _this$props2.prefixCls,\n overflowedIndicator = _this$props2.overflowedIndicator,\n mode = _this$props2.mode,\n level = _this$props2.level,\n tag = _this$props2.tag,\n children = _this$props2.children,\n theme = _this$props2.theme,\n rest = _objectWithoutProperties(_this$props2, [\"visible\", \"prefixCls\", \"overflowedIndicator\", \"mode\", \"level\", \"tag\", \"children\", \"theme\"]);\n\n var Tag = tag;\n return React.createElement(Tag, Object.assign({}, rest), this.renderChildren(children));\n }\n }]);\n\n return DOMWrap;\n}(React.Component);\n\nDOMWrap.defaultProps = {\n tag: 'div',\n className: ''\n};\nexport default DOMWrap;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport * as React from 'react';\nimport { connect } from 'mini-store';\nimport KeyCode from \"rc-util/es/KeyCode\";\nimport createChainedFunction from \"rc-util/es/createChainedFunction\";\nimport shallowEqual from 'shallowequal';\nimport classNames from 'classnames';\nimport { getKeyFromChildrenIndex, loopMenuItem, noop, menuAllProps, isMobileDevice } from './util';\nimport DOMWrap from './DOMWrap';\n\nfunction allDisabled(arr) {\n if (!arr.length) {\n return true;\n }\n\n return arr.every(function (c) {\n return !!c.props.disabled;\n });\n}\n\nfunction updateActiveKey(store, menuId, activeKey) {\n var state = store.getState();\n store.setState({\n activeKey: _objectSpread(_objectSpread({}, state.activeKey), {}, _defineProperty({}, menuId, activeKey))\n });\n}\n\nfunction getEventKey(props) {\n // when eventKey not available ,it's menu and return menu id '0-menu-'\n return props.eventKey || '0-menu-';\n}\n\nexport function getActiveKey(props, originalActiveKey) {\n var activeKey = originalActiveKey;\n var children = props.children,\n eventKey = props.eventKey;\n\n if (activeKey) {\n var found;\n loopMenuItem(children, function (c, i) {\n if (c && c.props && !c.props.disabled && activeKey === getKeyFromChildrenIndex(c, eventKey, i)) {\n found = true;\n }\n });\n\n if (found) {\n return activeKey;\n }\n }\n\n activeKey = null;\n\n if (props.defaultActiveFirst) {\n loopMenuItem(children, function (c, i) {\n if (!activeKey && c && !c.props.disabled) {\n activeKey = getKeyFromChildrenIndex(c, eventKey, i);\n }\n });\n return activeKey;\n }\n\n return activeKey;\n}\nexport function saveRef(c) {\n if (c) {\n var index = this.instanceArray.indexOf(c);\n\n if (index !== -1) {\n // update component if it's already inside instanceArray\n this.instanceArray[index] = c;\n } else {\n // add component if it's not in instanceArray yet;\n this.instanceArray.push(c);\n }\n }\n}\nexport var SubPopupMenu = /*#__PURE__*/function (_React$Component) {\n _inherits(SubPopupMenu, _React$Component);\n\n var _super = _createSuper(SubPopupMenu);\n\n function SubPopupMenu(props) {\n var _this;\n\n _classCallCheck(this, SubPopupMenu);\n\n _this = _super.call(this, props);\n /**\n * all keyboard events callbacks run from here at first\n *\n * note:\n * This legacy code that `onKeyDown` is called by parent instead of dom self.\n * which need return code to check if this event is handled\n */\n\n _this.onKeyDown = function (e, callback) {\n var keyCode = e.keyCode;\n var handled;\n\n _this.getFlatInstanceArray().forEach(function (obj) {\n if (obj && obj.props.active && obj.onKeyDown) {\n handled = obj.onKeyDown(e);\n }\n });\n\n if (handled) {\n return 1;\n }\n\n var activeItem = null;\n\n if (keyCode === KeyCode.UP || keyCode === KeyCode.DOWN) {\n activeItem = _this.step(keyCode === KeyCode.UP ? -1 : 1);\n }\n\n if (activeItem) {\n e.preventDefault();\n updateActiveKey(_this.props.store, getEventKey(_this.props), activeItem.props.eventKey);\n\n if (typeof callback === 'function') {\n callback(activeItem);\n }\n\n return 1;\n }\n\n return undefined;\n };\n\n _this.onItemHover = function (e) {\n var key = e.key,\n hover = e.hover;\n updateActiveKey(_this.props.store, getEventKey(_this.props), hover ? key : null);\n };\n\n _this.onDeselect = function (selectInfo) {\n _this.props.onDeselect(selectInfo);\n };\n\n _this.onSelect = function (selectInfo) {\n _this.props.onSelect(selectInfo);\n };\n\n _this.onClick = function (e) {\n _this.props.onClick(e);\n };\n\n _this.onOpenChange = function (e) {\n _this.props.onOpenChange(e);\n };\n\n _this.onDestroy = function (key) {\n /* istanbul ignore next */\n _this.props.onDestroy(key);\n };\n\n _this.getFlatInstanceArray = function () {\n return _this.instanceArray;\n };\n\n _this.step = function (direction) {\n var children = _this.getFlatInstanceArray();\n\n var activeKey = _this.props.store.getState().activeKey[getEventKey(_this.props)];\n\n var len = children.length;\n\n if (!len) {\n return null;\n }\n\n if (direction < 0) {\n children = children.concat().reverse();\n } // find current activeIndex\n\n\n var activeIndex = -1;\n children.every(function (c, ci) {\n if (c && c.props.eventKey === activeKey) {\n activeIndex = ci;\n return false;\n }\n\n return true;\n });\n\n if (!_this.props.defaultActiveFirst && activeIndex !== -1 && allDisabled(children.slice(activeIndex, len - 1))) {\n return undefined;\n }\n\n var start = (activeIndex + 1) % len;\n var i = start;\n\n do {\n var child = children[i];\n\n if (!child || child.props.disabled) {\n i = (i + 1) % len;\n } else {\n return child;\n }\n } while (i !== start);\n\n return null;\n };\n\n _this.renderCommonMenuItem = function (child, i, extraProps) {\n var state = _this.props.store.getState();\n\n var _assertThisInitialize = _assertThisInitialized(_this),\n props = _assertThisInitialize.props;\n\n var key = getKeyFromChildrenIndex(child, props.eventKey, i);\n var childProps = child.props; // https://github.com/ant-design/ant-design/issues/11517#issuecomment-477403055\n\n if (!childProps || typeof child.type === 'string') {\n return child;\n }\n\n var isActive = key === state.activeKey;\n\n var newChildProps = _objectSpread(_objectSpread({\n mode: childProps.mode || props.mode,\n level: props.level,\n inlineIndent: props.inlineIndent,\n renderMenuItem: _this.renderMenuItem,\n rootPrefixCls: props.prefixCls,\n index: i,\n parentMenu: props.parentMenu,\n // customized ref function, need to be invoked manually in child's componentDidMount\n manualRef: childProps.disabled ? undefined : createChainedFunction(child.ref, saveRef.bind(_assertThisInitialized(_this))),\n eventKey: key,\n active: !childProps.disabled && isActive,\n multiple: props.multiple,\n onClick: function onClick(e) {\n (childProps.onClick || noop)(e);\n\n _this.onClick(e);\n },\n onItemHover: _this.onItemHover,\n motion: props.motion,\n subMenuOpenDelay: props.subMenuOpenDelay,\n subMenuCloseDelay: props.subMenuCloseDelay,\n forceSubMenuRender: props.forceSubMenuRender,\n onOpenChange: _this.onOpenChange,\n onDeselect: _this.onDeselect,\n onSelect: _this.onSelect,\n builtinPlacements: props.builtinPlacements,\n itemIcon: childProps.itemIcon || _this.props.itemIcon,\n expandIcon: childProps.expandIcon || _this.props.expandIcon\n }, extraProps), {}, {\n direction: props.direction\n }); // ref: https://github.com/ant-design/ant-design/issues/13943\n\n\n if (props.mode === 'inline' || isMobileDevice()) {\n newChildProps.triggerSubMenuAction = 'click';\n }\n\n return React.cloneElement(child, newChildProps);\n };\n\n _this.renderMenuItem = function (c, i, subMenuKey) {\n /* istanbul ignore if */\n if (!c) {\n return null;\n }\n\n var state = _this.props.store.getState();\n\n var extraProps = {\n openKeys: state.openKeys,\n selectedKeys: state.selectedKeys,\n triggerSubMenuAction: _this.props.triggerSubMenuAction,\n subMenuKey: subMenuKey\n };\n return _this.renderCommonMenuItem(c, i, extraProps);\n };\n\n props.store.setState({\n activeKey: _objectSpread(_objectSpread({}, props.store.getState().activeKey), {}, _defineProperty({}, props.eventKey, getActiveKey(props, props.activeKey)))\n });\n _this.instanceArray = [];\n return _this;\n }\n\n _createClass(SubPopupMenu, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n // invoke customized ref to expose component to mixin\n if (this.props.manualRef) {\n this.props.manualRef(this);\n }\n }\n }, {\n key: \"shouldComponentUpdate\",\n value: function shouldComponentUpdate(nextProps) {\n return this.props.visible || nextProps.visible || this.props.className !== nextProps.className || !shallowEqual(this.props.style, nextProps.style);\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate(prevProps) {\n var props = this.props;\n var originalActiveKey = 'activeKey' in props ? props.activeKey : props.store.getState().activeKey[getEventKey(props)];\n var activeKey = getActiveKey(props, originalActiveKey);\n\n if (activeKey !== originalActiveKey) {\n updateActiveKey(props.store, getEventKey(props), activeKey);\n } else if ('activeKey' in prevProps) {\n // If prev activeKey is not same as current activeKey,\n // we should set it.\n var prevActiveKey = getActiveKey(prevProps, prevProps.activeKey);\n\n if (activeKey !== prevActiveKey) {\n updateActiveKey(props.store, getEventKey(props), activeKey);\n }\n }\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this2 = this;\n\n var props = _extends({}, this.props);\n\n this.instanceArray = [];\n var className = classNames(props.prefixCls, props.className, \"\".concat(props.prefixCls, \"-\").concat(props.mode));\n var domProps = {\n className: className,\n // role could be 'select' and by default set to menu\n role: props.role || 'menu'\n };\n\n if (props.id) {\n domProps.id = props.id;\n }\n\n if (props.focusable) {\n domProps.tabIndex = 0;\n domProps.onKeyDown = this.onKeyDown;\n }\n\n var prefixCls = props.prefixCls,\n eventKey = props.eventKey,\n visible = props.visible,\n level = props.level,\n mode = props.mode,\n overflowedIndicator = props.overflowedIndicator,\n theme = props.theme;\n menuAllProps.forEach(function (key) {\n return delete props[key];\n }); // Otherwise, the propagated click event will trigger another onClick\n\n delete props.onClick;\n return React.createElement(DOMWrap, Object.assign({}, props, {\n prefixCls: prefixCls,\n mode: mode,\n tag: \"ul\",\n level: level,\n theme: theme,\n visible: visible,\n overflowedIndicator: overflowedIndicator\n }, domProps), React.Children.map(props.children, function (c, i) {\n return _this2.renderMenuItem(c, i, eventKey || '0-menu-');\n }));\n }\n }]);\n\n return SubPopupMenu;\n}(React.Component);\nSubPopupMenu.defaultProps = {\n prefixCls: 'rc-menu',\n className: '',\n mode: 'vertical',\n level: 1,\n inlineIndent: 24,\n visible: true,\n focusable: true,\n style: {},\n manualRef: noop\n};\nvar connected = connect()(SubPopupMenu);\nexport default connected;","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport warning from \"rc-util/es/warning\";\nexport function getMotion(_ref, _ref2, menuMode) {\n var prefixCls = _ref.prefixCls,\n motion = _ref.motion,\n _ref$defaultMotions = _ref.defaultMotions,\n defaultMotions = _ref$defaultMotions === void 0 ? {} : _ref$defaultMotions,\n openAnimation = _ref.openAnimation,\n openTransitionName = _ref.openTransitionName;\n var switchingModeFromInline = _ref2.switchingModeFromInline;\n\n if (motion) {\n return motion;\n }\n\n if (_typeof(openAnimation) === 'object' && openAnimation) {\n warning(false, 'Object type of `openAnimation` is removed. Please use `motion` instead.');\n } else if (typeof openAnimation === 'string') {\n return {\n motionName: \"\".concat(prefixCls, \"-open-\").concat(openAnimation)\n };\n }\n\n if (openTransitionName) {\n return {\n motionName: openTransitionName\n };\n } // Default logic\n\n\n var defaultMotion = defaultMotions[menuMode];\n\n if (defaultMotion) {\n return defaultMotion;\n } // When mode switch from inline\n // submenu should hide without animation\n\n\n return switchingModeFromInline ? null : defaultMotions.other;\n}","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport * as React from 'react';\nimport { Provider, create } from 'mini-store';\nimport omit from 'omit.js';\nimport SubPopupMenu, { getActiveKey } from './SubPopupMenu';\nimport { noop } from './util';\nimport { getMotion } from './utils/legacyUtil';\n\nvar Menu = /*#__PURE__*/function (_React$Component) {\n _inherits(Menu, _React$Component);\n\n var _super = _createSuper(Menu);\n\n function Menu(props) {\n var _this;\n\n _classCallCheck(this, Menu);\n\n _this = _super.call(this, props);\n _this.inlineOpenKeys = [];\n\n _this.onSelect = function (selectInfo) {\n var _assertThisInitialize = _assertThisInitialized(_this),\n props = _assertThisInitialize.props;\n\n if (props.selectable) {\n // root menu\n var _this$store$getState = _this.store.getState(),\n _selectedKeys = _this$store$getState.selectedKeys;\n\n var selectedKey = selectInfo.key;\n\n if (props.multiple) {\n _selectedKeys = _selectedKeys.concat([selectedKey]);\n } else {\n _selectedKeys = [selectedKey];\n }\n\n if (!('selectedKeys' in props)) {\n _this.store.setState({\n selectedKeys: _selectedKeys\n });\n }\n\n props.onSelect(_objectSpread(_objectSpread({}, selectInfo), {}, {\n selectedKeys: _selectedKeys\n }));\n }\n };\n\n _this.onClick = function (e) {\n var mode = _this.getRealMenuMode();\n\n var _assertThisInitialize2 = _assertThisInitialized(_this),\n store = _assertThisInitialize2.store,\n onOpenChange = _assertThisInitialize2.props.onOpenChange;\n\n if (mode !== 'inline' && !('openKeys' in _this.props)) {\n // closing vertical popup submenu after click it\n store.setState({\n openKeys: []\n });\n onOpenChange([]);\n }\n\n _this.props.onClick(e);\n }; // onKeyDown needs to be exposed as a instance method\n // e.g., in rc-select, we need to navigate menu item while\n // current active item is rc-select input box rather than the menu itself\n\n\n _this.onKeyDown = function (e, callback) {\n _this.innerMenu.getWrappedInstance().onKeyDown(e, callback);\n };\n\n _this.onOpenChange = function (event) {\n var _assertThisInitialize3 = _assertThisInitialized(_this),\n props = _assertThisInitialize3.props;\n\n var openKeys = _this.store.getState().openKeys.concat();\n\n var changed = false;\n\n var processSingle = function processSingle(e) {\n var oneChanged = false;\n\n if (e.open) {\n oneChanged = openKeys.indexOf(e.key) === -1;\n\n if (oneChanged) {\n openKeys.push(e.key);\n }\n } else {\n var index = openKeys.indexOf(e.key);\n oneChanged = index !== -1;\n\n if (oneChanged) {\n openKeys.splice(index, 1);\n }\n }\n\n changed = changed || oneChanged;\n };\n\n if (Array.isArray(event)) {\n // batch change call\n event.forEach(processSingle);\n } else {\n processSingle(event);\n }\n\n if (changed) {\n if (!('openKeys' in _this.props)) {\n _this.store.setState({\n openKeys: openKeys\n });\n }\n\n props.onOpenChange(openKeys);\n }\n };\n\n _this.onDeselect = function (selectInfo) {\n var _assertThisInitialize4 = _assertThisInitialized(_this),\n props = _assertThisInitialize4.props;\n\n if (props.selectable) {\n var _selectedKeys2 = _this.store.getState().selectedKeys.concat();\n\n var selectedKey = selectInfo.key;\n\n var index = _selectedKeys2.indexOf(selectedKey);\n\n if (index !== -1) {\n _selectedKeys2.splice(index, 1);\n }\n\n if (!('selectedKeys' in props)) {\n _this.store.setState({\n selectedKeys: _selectedKeys2\n });\n }\n\n props.onDeselect(_objectSpread(_objectSpread({}, selectInfo), {}, {\n selectedKeys: _selectedKeys2\n }));\n }\n }; // Restore vertical mode when menu is collapsed responsively when mounted\n // https://github.com/ant-design/ant-design/issues/13104\n // TODO: not a perfect solution,\n // looking a new way to avoid setting switchingModeFromInline in this situation\n\n\n _this.onMouseEnter = function (e) {\n _this.restoreModeVerticalFromInline();\n\n var onMouseEnter = _this.props.onMouseEnter;\n\n if (onMouseEnter) {\n onMouseEnter(e);\n }\n };\n\n _this.onTransitionEnd = function (e) {\n // when inlineCollapsed menu width animation finished\n // https://github.com/ant-design/ant-design/issues/12864\n var widthCollapsed = e.propertyName === 'width' && e.target === e.currentTarget; // Fix SVGElement e.target.className.indexOf is not a function\n // https://github.com/ant-design/ant-design/issues/15699\n\n var className = e.target.className; // SVGAnimatedString.animVal should be identical to SVGAnimatedString.baseVal,\n // unless during an animation.\n\n var classNameValue = Object.prototype.toString.call(className) === '[object SVGAnimatedString]' ? className.animVal : className; // Fix for ,\n // the width transition won't trigger when menu is collapsed\n // https://github.com/ant-design/ant-design-pro/issues/2783\n\n var iconScaled = e.propertyName === 'font-size' && classNameValue.indexOf('anticon') >= 0;\n\n if (widthCollapsed || iconScaled) {\n _this.restoreModeVerticalFromInline();\n }\n };\n\n _this.setInnerMenu = function (node) {\n _this.innerMenu = node;\n };\n\n _this.isRootMenu = true;\n var selectedKeys = props.defaultSelectedKeys;\n var openKeys = props.defaultOpenKeys;\n\n if ('selectedKeys' in props) {\n selectedKeys = props.selectedKeys || [];\n }\n\n if ('openKeys' in props) {\n openKeys = props.openKeys || [];\n }\n\n _this.store = create({\n selectedKeys: selectedKeys,\n openKeys: openKeys,\n activeKey: {\n '0-menu-': getActiveKey(props, props.activeKey)\n }\n });\n _this.state = {\n switchingModeFromInline: false\n };\n return _this;\n }\n\n _createClass(Menu, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.updateMiniStore();\n this.updateMenuDisplay();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate(prevProps) {\n this.updateOpentKeysWhenSwitchMode(prevProps);\n this.updateMiniStore();\n var _this$props = this.props,\n siderCollapsed = _this$props.siderCollapsed,\n inlineCollapsed = _this$props.inlineCollapsed,\n onOpenChange = _this$props.onOpenChange;\n\n if (!prevProps.inlineCollapsed && inlineCollapsed || !prevProps.siderCollapsed && siderCollapsed) {\n onOpenChange([]);\n }\n\n this.updateMenuDisplay();\n }\n }, {\n key: \"updateOpentKeysWhenSwitchMode\",\n value: function updateOpentKeysWhenSwitchMode(prevProps) {\n var nextProps = this.props,\n store = this.store,\n inlineOpenKeys = this.inlineOpenKeys;\n var prevState = store.getState();\n var newState = {};\n\n if (prevProps.mode === 'inline' && nextProps.mode !== 'inline') {\n this.setState({\n switchingModeFromInline: true\n });\n }\n\n if (!('openKeys' in nextProps)) {\n // [Legacy] Old code will return after `openKeys` changed.\n // Not sure the reason, we should keep this logic still.\n if (nextProps.inlineCollapsed && !prevProps.inlineCollapsed || nextProps.siderCollapsed && !prevProps.siderCollapsed) {\n this.setState({\n switchingModeFromInline: true\n });\n this.inlineOpenKeys = prevState.openKeys.concat();\n newState.openKeys = [];\n }\n\n if (!nextProps.inlineCollapsed && prevProps.inlineCollapsed || !nextProps.siderCollapsed && prevProps.siderCollapsed) {\n newState.openKeys = inlineOpenKeys;\n this.inlineOpenKeys = [];\n }\n }\n\n if (Object.keys(newState).length) {\n store.setState(newState);\n }\n }\n }, {\n key: \"updateMenuDisplay\",\n value: function updateMenuDisplay() {\n var collapsedWidth = this.props.collapsedWidth,\n store = this.store,\n prevOpenKeys = this.prevOpenKeys; // https://github.com/ant-design/ant-design/issues/8587\n\n var hideMenu = this.getInlineCollapsed() && (collapsedWidth === 0 || collapsedWidth === '0' || collapsedWidth === '0px');\n\n if (hideMenu) {\n this.prevOpenKeys = store.getState().openKeys.concat();\n this.store.setState({\n openKeys: []\n });\n } else if (prevOpenKeys) {\n this.store.setState({\n openKeys: prevOpenKeys\n });\n this.prevOpenKeys = null;\n }\n }\n }, {\n key: \"getRealMenuMode\",\n value: function getRealMenuMode() {\n var mode = this.props.mode;\n var switchingModeFromInline = this.state.switchingModeFromInline;\n var inlineCollapsed = this.getInlineCollapsed();\n\n if (switchingModeFromInline && inlineCollapsed) {\n return 'inline';\n }\n\n return inlineCollapsed ? 'vertical' : mode;\n }\n }, {\n key: \"getInlineCollapsed\",\n value: function getInlineCollapsed() {\n var _this$props2 = this.props,\n inlineCollapsed = _this$props2.inlineCollapsed,\n siderCollapsed = _this$props2.siderCollapsed;\n\n if (siderCollapsed !== undefined) {\n return siderCollapsed;\n }\n\n return inlineCollapsed;\n }\n }, {\n key: \"restoreModeVerticalFromInline\",\n value: function restoreModeVerticalFromInline() {\n var switchingModeFromInline = this.state.switchingModeFromInline;\n\n if (switchingModeFromInline) {\n this.setState({\n switchingModeFromInline: false\n });\n }\n }\n }, {\n key: \"updateMiniStore\",\n value: function updateMiniStore() {\n if ('selectedKeys' in this.props) {\n this.store.setState({\n selectedKeys: this.props.selectedKeys || []\n });\n }\n\n if ('openKeys' in this.props) {\n this.store.setState({\n openKeys: this.props.openKeys || []\n });\n }\n }\n }, {\n key: \"render\",\n value: function render() {\n var props = _objectSpread({}, omit(this.props, ['collapsedWidth', 'siderCollapsed', 'defaultMotions']));\n\n var mode = this.getRealMenuMode();\n props.className += \" \".concat(props.prefixCls, \"-root\");\n\n if (props.direction === 'rtl') {\n props.className += \" \".concat(props.prefixCls, \"-rtl\");\n }\n\n props = _objectSpread(_objectSpread({}, props), {}, {\n mode: mode,\n onClick: this.onClick,\n onOpenChange: this.onOpenChange,\n onDeselect: this.onDeselect,\n onSelect: this.onSelect,\n onMouseEnter: this.onMouseEnter,\n onTransitionEnd: this.onTransitionEnd,\n parentMenu: this,\n motion: getMotion(this.props, this.state, mode)\n });\n delete props.openAnimation;\n delete props.openTransitionName;\n return React.createElement(Provider, {\n store: this.store\n }, React.createElement(SubPopupMenu, Object.assign({}, props, {\n ref: this.setInnerMenu\n }), this.props.children));\n }\n }]);\n\n return Menu;\n}(React.Component);\n\nMenu.defaultProps = {\n selectable: true,\n onClick: noop,\n onSelect: noop,\n onOpenChange: noop,\n onDeselect: noop,\n defaultSelectedKeys: [],\n defaultOpenKeys: [],\n subMenuOpenDelay: 0.1,\n subMenuCloseDelay: 0.1,\n triggerSubMenuAction: 'hover',\n prefixCls: 'rc-menu',\n className: '',\n mode: 'vertical',\n style: {},\n builtinPlacements: {},\n overflowedIndicator: React.createElement(\"span\", null, \"\\xB7\\xB7\\xB7\")\n};\nexport default Menu;","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport * as React from 'react';\nimport KeyCode from \"rc-util/es/KeyCode\";\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport { connect } from 'mini-store';\nimport { noop, menuAllProps } from './util';\nexport var MenuItem = /*#__PURE__*/function (_React$Component) {\n _inherits(MenuItem, _React$Component);\n\n var _super = _createSuper(MenuItem);\n\n function MenuItem() {\n var _this;\n\n _classCallCheck(this, MenuItem);\n\n _this = _super.apply(this, arguments);\n\n _this.onKeyDown = function (e) {\n var keyCode = e.keyCode;\n\n if (keyCode === KeyCode.ENTER) {\n _this.onClick(e);\n\n return true;\n }\n\n return undefined;\n };\n\n _this.onMouseLeave = function (e) {\n var _this$props = _this.props,\n eventKey = _this$props.eventKey,\n onItemHover = _this$props.onItemHover,\n onMouseLeave = _this$props.onMouseLeave;\n onItemHover({\n key: eventKey,\n hover: false\n });\n onMouseLeave({\n key: eventKey,\n domEvent: e\n });\n };\n\n _this.onMouseEnter = function (e) {\n var _this$props2 = _this.props,\n eventKey = _this$props2.eventKey,\n onItemHover = _this$props2.onItemHover,\n onMouseEnter = _this$props2.onMouseEnter;\n onItemHover({\n key: eventKey,\n hover: true\n });\n onMouseEnter({\n key: eventKey,\n domEvent: e\n });\n };\n\n _this.onClick = function (e) {\n var _this$props3 = _this.props,\n eventKey = _this$props3.eventKey,\n multiple = _this$props3.multiple,\n onClick = _this$props3.onClick,\n onSelect = _this$props3.onSelect,\n onDeselect = _this$props3.onDeselect,\n isSelected = _this$props3.isSelected;\n var info = {\n key: eventKey,\n keyPath: [eventKey],\n item: _assertThisInitialized(_this),\n domEvent: e\n };\n onClick(info);\n\n if (multiple) {\n if (isSelected) {\n onDeselect(info);\n } else {\n onSelect(info);\n }\n } else if (!isSelected) {\n onSelect(info);\n }\n };\n\n _this.saveNode = function (node) {\n _this.node = node;\n };\n\n return _this;\n }\n\n _createClass(MenuItem, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n // invoke customized ref to expose component to mixin\n this.callRef();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {\n this.callRef();\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n var props = this.props;\n\n if (props.onDestroy) {\n props.onDestroy(props.eventKey);\n }\n }\n }, {\n key: \"getPrefixCls\",\n value: function getPrefixCls() {\n return \"\".concat(this.props.rootPrefixCls, \"-item\");\n }\n }, {\n key: \"getActiveClassName\",\n value: function getActiveClassName() {\n return \"\".concat(this.getPrefixCls(), \"-active\");\n }\n }, {\n key: \"getSelectedClassName\",\n value: function getSelectedClassName() {\n return \"\".concat(this.getPrefixCls(), \"-selected\");\n }\n }, {\n key: \"getDisabledClassName\",\n value: function getDisabledClassName() {\n return \"\".concat(this.getPrefixCls(), \"-disabled\");\n }\n }, {\n key: \"callRef\",\n value: function callRef() {\n if (this.props.manualRef) {\n this.props.manualRef(this);\n }\n }\n }, {\n key: \"render\",\n value: function render() {\n var _classNames;\n\n var props = _objectSpread({}, this.props);\n\n var className = classNames(this.getPrefixCls(), props.className, (_classNames = {}, _defineProperty(_classNames, this.getActiveClassName(), !props.disabled && props.active), _defineProperty(_classNames, this.getSelectedClassName(), props.isSelected), _defineProperty(_classNames, this.getDisabledClassName(), props.disabled), _classNames));\n\n var attrs = _objectSpread(_objectSpread({}, props.attribute), {}, {\n title: typeof props.title === 'string' ? props.title : undefined,\n className: className,\n // set to menuitem by default\n role: props.role || 'menuitem',\n 'aria-disabled': props.disabled\n });\n\n if (props.role === 'option') {\n // overwrite to option\n attrs = _objectSpread(_objectSpread({}, attrs), {}, {\n role: 'option',\n 'aria-selected': props.isSelected\n });\n } else if (props.role === null || props.role === 'none') {\n // sometimes we want to specify role inside element\n // Link would be a good example\n // in this case the role on should be \"none\" to\n // remove the implied listitem role.\n // https://www.w3.org/TR/wai-aria-practices-1.1/examples/menubar/menubar-1/menubar-1.html\n attrs.role = 'none';\n } // In case that onClick/onMouseLeave/onMouseEnter is passed down from owner\n\n\n var mouseEvent = {\n onClick: props.disabled ? null : this.onClick,\n onMouseLeave: props.disabled ? null : this.onMouseLeave,\n onMouseEnter: props.disabled ? null : this.onMouseEnter\n };\n\n var style = _objectSpread({}, props.style);\n\n if (props.mode === 'inline') {\n if (props.direction === 'rtl') {\n style.paddingRight = props.inlineIndent * props.level;\n } else {\n style.paddingLeft = props.inlineIndent * props.level;\n }\n }\n\n menuAllProps.forEach(function (key) {\n return delete props[key];\n });\n delete props.direction;\n var icon = this.props.itemIcon;\n\n if (typeof this.props.itemIcon === 'function') {\n // TODO: This is a bug which should fixed after TS refactor\n icon = React.createElement(this.props.itemIcon, this.props);\n }\n\n return React.createElement(\"li\", Object.assign({}, omit(props, ['onClick', 'onMouseEnter', 'onMouseLeave', 'onSelect']), attrs, mouseEvent, {\n style: style,\n ref: this.saveNode\n }), props.children, icon);\n }\n }]);\n\n return MenuItem;\n}(React.Component);\nMenuItem.isMenuItem = true;\nMenuItem.defaultProps = {\n onSelect: noop,\n onMouseEnter: noop,\n onMouseLeave: noop,\n manualRef: noop\n};\nvar connected = connect(function (_ref, _ref2) {\n var activeKey = _ref.activeKey,\n selectedKeys = _ref.selectedKeys;\n var eventKey = _ref2.eventKey,\n subMenuKey = _ref2.subMenuKey;\n return {\n active: activeKey[subMenuKey] === eventKey,\n isSelected: selectedKeys.indexOf(eventKey) !== -1\n };\n})(MenuItem);\nexport default connected;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\nimport * as React from 'react';\nimport { menuAllProps } from './util';\n\nvar MenuItemGroup = /*#__PURE__*/function (_React$Component) {\n _inherits(MenuItemGroup, _React$Component);\n\n var _super = _createSuper(MenuItemGroup);\n\n function MenuItemGroup() {\n var _this;\n\n _classCallCheck(this, MenuItemGroup);\n\n _this = _super.apply(this, arguments);\n\n _this.renderInnerMenuItem = function (item) {\n var _this$props = _this.props,\n renderMenuItem = _this$props.renderMenuItem,\n index = _this$props.index;\n return renderMenuItem(item, index, _this.props.subMenuKey);\n };\n\n return _this;\n }\n\n _createClass(MenuItemGroup, [{\n key: \"render\",\n value: function render() {\n var props = _extends({}, this.props);\n\n var _props$className = props.className,\n className = _props$className === void 0 ? '' : _props$className,\n rootPrefixCls = props.rootPrefixCls;\n var titleClassName = \"\".concat(rootPrefixCls, \"-item-group-title\");\n var listClassName = \"\".concat(rootPrefixCls, \"-item-group-list\");\n var title = props.title,\n children = props.children;\n menuAllProps.forEach(function (key) {\n return delete props[key];\n }); // Set onClick to null, to ignore propagated onClick event\n\n delete props.onClick;\n delete props.direction;\n return React.createElement(\"li\", Object.assign({}, props, {\n className: \"\".concat(className, \" \").concat(rootPrefixCls, \"-item-group\")\n }), React.createElement(\"div\", {\n className: titleClassName,\n title: typeof title === 'string' ? title : undefined\n }, title), React.createElement(\"ul\", {\n className: listClassName\n }, React.Children.map(children, this.renderInnerMenuItem)));\n }\n }]);\n\n return MenuItemGroup;\n}(React.Component);\n\nMenuItemGroup.isMenuItemGroup = true;\nMenuItemGroup.defaultProps = {\n disabled: true\n};\nexport default MenuItemGroup;","import * as React from 'react';\n\nvar Divider = function Divider(_ref) {\n var className = _ref.className,\n rootPrefixCls = _ref.rootPrefixCls,\n style = _ref.style;\n return React.createElement(\"li\", {\n className: \"\".concat(className, \" \").concat(rootPrefixCls, \"-item-divider\"),\n style: style\n });\n};\n\nDivider.defaultProps = {\n // To fix keyboard UX.\n disabled: true,\n className: '',\n style: {}\n};\nexport default Divider;","import Menu from './Menu';\nimport SubMenu from './SubMenu';\nimport MenuItem from './MenuItem';\nimport MenuItemGroup from './MenuItemGroup';\nimport Divider from './Divider';\nexport { SubMenu, MenuItem as Item, MenuItem, MenuItemGroup, MenuItemGroup as ItemGroup, Divider };\nexport default Menu;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nexport var responsiveArray = ['xxl', 'xl', 'lg', 'md', 'sm', 'xs'];\nexport var responsiveMap = {\n xs: '(max-width: 575px)',\n sm: '(min-width: 576px)',\n md: '(min-width: 768px)',\n lg: '(min-width: 992px)',\n xl: '(min-width: 1200px)',\n xxl: '(min-width: 1600px)'\n};\nvar subscribers = new Map();\nvar subUid = -1;\nvar screens = {};\nvar responsiveObserve = {\n matchHandlers: {},\n dispatch: function dispatch(pointMap) {\n screens = pointMap;\n subscribers.forEach(function (func) {\n return func(screens);\n });\n return subscribers.size >= 1;\n },\n subscribe: function subscribe(func) {\n if (!subscribers.size) this.register();\n subUid += 1;\n subscribers.set(subUid, func);\n func(screens);\n return subUid;\n },\n unsubscribe: function unsubscribe(token) {\n subscribers[\"delete\"](token);\n if (!subscribers.size) this.unregister();\n },\n unregister: function unregister() {\n var _this = this;\n\n Object.keys(responsiveMap).forEach(function (screen) {\n var matchMediaQuery = responsiveMap[screen];\n var handler = _this.matchHandlers[matchMediaQuery];\n handler === null || handler === void 0 ? void 0 : handler.mql.removeListener(handler === null || handler === void 0 ? void 0 : handler.listener);\n });\n subscribers.clear();\n },\n register: function register() {\n var _this2 = this;\n\n Object.keys(responsiveMap).forEach(function (screen) {\n var matchMediaQuery = responsiveMap[screen];\n\n var listener = function listener(_ref) {\n var matches = _ref.matches;\n\n _this2.dispatch(_extends(_extends({}, screens), _defineProperty({}, screen, matches)));\n };\n\n var mql = window.matchMedia(matchMediaQuery);\n mql.addListener(listener);\n _this2.matchHandlers[matchMediaQuery] = {\n mql: mql,\n listener: listener\n };\n listener(mql);\n });\n }\n};\nexport default responsiveObserve;","import * as React from 'react';\nimport Empty from '../empty';\nimport { ConfigConsumer } from '.';\n\nvar renderEmpty = function renderEmpty(componentName) {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, function (_ref) {\n var getPrefixCls = _ref.getPrefixCls;\n var prefix = getPrefixCls('empty');\n\n switch (componentName) {\n case 'Table':\n case 'List':\n return /*#__PURE__*/React.createElement(Empty, {\n image: Empty.PRESENTED_IMAGE_SIMPLE\n });\n\n case 'Select':\n case 'TreeSelect':\n case 'Cascader':\n case 'Transfer':\n case 'Mentions':\n return /*#__PURE__*/React.createElement(Empty, {\n image: Empty.PRESENTED_IMAGE_SIMPLE,\n className: \"\".concat(prefix, \"-small\")\n });\n\n default:\n return /*#__PURE__*/React.createElement(Empty, null);\n }\n });\n};\n\nexport default renderEmpty;","import _extends from \"@babel/runtime/helpers/extends\";\nimport * as React from 'react';\nimport defaultRenderEmpty from './renderEmpty';\nexport var ConfigContext = /*#__PURE__*/React.createContext({\n // We provide a default function for Context without provider\n getPrefixCls: function getPrefixCls(suffixCls, customizePrefixCls) {\n if (customizePrefixCls) return customizePrefixCls;\n return suffixCls ? \"ant-\".concat(suffixCls) : 'ant';\n },\n renderEmpty: defaultRenderEmpty\n});\nexport var ConfigConsumer = ConfigContext.Consumer;\nexport function withConfigConsumer(config) {\n return function withConfigConsumerFunc(Component) {\n // Wrap with ConfigConsumer. Since we need compatible with react 15, be care when using ref methods\n var SFC = function SFC(props) {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, function (configProps) {\n var basicPrefixCls = config.prefixCls;\n var getPrefixCls = configProps.getPrefixCls;\n var customizePrefixCls = props.prefixCls;\n var prefixCls = getPrefixCls(basicPrefixCls, customizePrefixCls);\n return /*#__PURE__*/React.createElement(Component, _extends({}, configProps, props, {\n prefixCls: prefixCls\n }));\n });\n };\n\n var cons = Component.constructor;\n var name = cons && cons.displayName || Component.name || 'Component';\n SFC.displayName = \"withConfigConsumer(\".concat(name, \")\");\n return SFC;\n };\n}","import React from \"react\";\nimport { Router } from \"react-router\";\nimport { createBrowserHistory as createHistory } from \"history\";\nimport PropTypes from \"prop-types\";\nimport warning from \"tiny-warning\";\n\n/**\n * The public API for a that uses HTML5 history.\n */\nclass BrowserRouter extends React.Component {\n history = createHistory(this.props);\n\n render() {\n return ;\n }\n}\n\nif (__DEV__) {\n BrowserRouter.propTypes = {\n basename: PropTypes.string,\n children: PropTypes.node,\n forceRefresh: PropTypes.bool,\n getUserConfirmation: PropTypes.func,\n keyLength: PropTypes.number\n };\n\n BrowserRouter.prototype.componentDidMount = function() {\n warning(\n !this.props.history,\n \" ignores the history prop. To use a custom history, \" +\n \"use `import { Router }` instead of `import { BrowserRouter as Router }`.\"\n );\n };\n}\n\nexport default BrowserRouter;\n","import React from \"react\";\nimport { Router } from \"react-router\";\nimport { createHashHistory as createHistory } from \"history\";\nimport PropTypes from \"prop-types\";\nimport warning from \"tiny-warning\";\n\n/**\n * The public API for a that uses window.location.hash.\n */\nclass HashRouter extends React.Component {\n history = createHistory(this.props);\n\n render() {\n return ;\n }\n}\n\nif (__DEV__) {\n HashRouter.propTypes = {\n basename: PropTypes.string,\n children: PropTypes.node,\n getUserConfirmation: PropTypes.func,\n hashType: PropTypes.oneOf([\"hashbang\", \"noslash\", \"slash\"])\n };\n\n HashRouter.prototype.componentDidMount = function() {\n warning(\n !this.props.history,\n \" ignores the history prop. To use a custom history, \" +\n \"use `import { Router }` instead of `import { HashRouter as Router }`.\"\n );\n };\n}\n\nexport default HashRouter;\n","import { createLocation } from \"history\";\n\nexport const resolveToLocation = (to, currentLocation) =>\n typeof to === \"function\" ? to(currentLocation) : to;\n\nexport const normalizeToLocation = (to, currentLocation) => {\n return typeof to === \"string\"\n ? createLocation(to, null, null, currentLocation)\n : to;\n};\n","import React from \"react\";\nimport { __RouterContext as RouterContext } from \"react-router\";\nimport PropTypes from \"prop-types\";\nimport invariant from \"tiny-invariant\";\nimport {\n resolveToLocation,\n normalizeToLocation\n} from \"./utils/locationUtils.js\";\n\n// React 15 compat\nconst forwardRefShim = C => C;\nlet { forwardRef } = React;\nif (typeof forwardRef === \"undefined\") {\n forwardRef = forwardRefShim;\n}\n\nfunction isModifiedEvent(event) {\n return !!(event.metaKey || event.altKey || event.ctrlKey || event.shiftKey);\n}\n\nconst LinkAnchor = forwardRef(\n (\n {\n innerRef, // TODO: deprecate\n navigate,\n onClick,\n ...rest\n },\n forwardedRef\n ) => {\n const { target } = rest;\n\n let props = {\n ...rest,\n onClick: event => {\n try {\n if (onClick) onClick(event);\n } catch (ex) {\n event.preventDefault();\n throw ex;\n }\n\n if (\n !event.defaultPrevented && // onClick prevented default\n event.button === 0 && // ignore everything but left clicks\n (!target || target === \"_self\") && // let browser handle \"target=_blank\" etc.\n !isModifiedEvent(event) // ignore clicks with modifier keys\n ) {\n event.preventDefault();\n navigate();\n }\n }\n };\n\n // React 15 compat\n if (forwardRefShim !== forwardRef) {\n props.ref = forwardedRef || innerRef;\n } else {\n props.ref = innerRef;\n }\n\n /* eslint-disable-next-line jsx-a11y/anchor-has-content */\n return ;\n }\n);\n\nif (__DEV__) {\n LinkAnchor.displayName = \"LinkAnchor\";\n}\n\n/**\n * The public API for rendering a history-aware .\n */\nconst Link = forwardRef(\n (\n {\n component = LinkAnchor,\n replace,\n to,\n innerRef, // TODO: deprecate\n ...rest\n },\n forwardedRef\n ) => {\n return (\n \n {context => {\n invariant(context, \"You should not use outside a \");\n\n const { history } = context;\n\n const location = normalizeToLocation(\n resolveToLocation(to, context.location),\n context.location\n );\n\n const href = location ? history.createHref(location) : \"\";\n const props = {\n ...rest,\n href,\n navigate() {\n const location = resolveToLocation(to, context.location);\n const method = replace ? history.replace : history.push;\n\n method(location);\n }\n };\n\n // React 15 compat\n if (forwardRefShim !== forwardRef) {\n props.ref = forwardedRef || innerRef;\n } else {\n props.innerRef = innerRef;\n }\n\n return React.createElement(component, props);\n }}\n \n );\n }\n);\n\nif (__DEV__) {\n const toType = PropTypes.oneOfType([\n PropTypes.string,\n PropTypes.object,\n PropTypes.func\n ]);\n const refType = PropTypes.oneOfType([\n PropTypes.string,\n PropTypes.func,\n PropTypes.shape({ current: PropTypes.any })\n ]);\n\n Link.displayName = \"Link\";\n\n Link.propTypes = {\n innerRef: refType,\n onClick: PropTypes.func,\n replace: PropTypes.bool,\n target: PropTypes.string,\n to: toType.isRequired\n };\n}\n\nexport default Link;\n","import React from \"react\";\nimport { __RouterContext as RouterContext, matchPath } from \"react-router\";\nimport PropTypes from \"prop-types\";\nimport invariant from \"tiny-invariant\";\nimport Link from \"./Link.js\";\nimport {\n resolveToLocation,\n normalizeToLocation\n} from \"./utils/locationUtils.js\";\n\n// React 15 compat\nconst forwardRefShim = C => C;\nlet { forwardRef } = React;\nif (typeof forwardRef === \"undefined\") {\n forwardRef = forwardRefShim;\n}\n\nfunction joinClassnames(...classnames) {\n return classnames.filter(i => i).join(\" \");\n}\n\n/**\n * A wrapper that knows if it's \"active\" or not.\n */\nconst NavLink = forwardRef(\n (\n {\n \"aria-current\": ariaCurrent = \"page\",\n activeClassName = \"active\",\n activeStyle,\n className: classNameProp,\n exact,\n isActive: isActiveProp,\n location: locationProp,\n sensitive,\n strict,\n style: styleProp,\n to,\n innerRef, // TODO: deprecate\n ...rest\n },\n forwardedRef\n ) => {\n return (\n \n {context => {\n invariant(context, \"You should not use outside a \");\n\n const currentLocation = locationProp || context.location;\n const toLocation = normalizeToLocation(\n resolveToLocation(to, currentLocation),\n currentLocation\n );\n const { pathname: path } = toLocation;\n // Regex taken from: https://github.com/pillarjs/path-to-regexp/blob/master/index.js#L202\n const escapedPath =\n path && path.replace(/([.+*?=^!:${}()[\\]|/\\\\])/g, \"\\\\$1\");\n\n const match = escapedPath\n ? matchPath(currentLocation.pathname, {\n path: escapedPath,\n exact,\n sensitive,\n strict\n })\n : null;\n const isActive = !!(isActiveProp\n ? isActiveProp(match, currentLocation)\n : match);\n\n const className = isActive\n ? joinClassnames(classNameProp, activeClassName)\n : classNameProp;\n const style = isActive ? { ...styleProp, ...activeStyle } : styleProp;\n\n const props = {\n \"aria-current\": (isActive && ariaCurrent) || null,\n className,\n style,\n to: toLocation,\n ...rest\n };\n\n // React 15 compat\n if (forwardRefShim !== forwardRef) {\n props.ref = forwardedRef || innerRef;\n } else {\n props.innerRef = innerRef;\n }\n\n return ;\n }}\n \n );\n }\n);\n\nif (__DEV__) {\n NavLink.displayName = \"NavLink\";\n\n const ariaCurrentType = PropTypes.oneOf([\n \"page\",\n \"step\",\n \"location\",\n \"date\",\n \"time\",\n \"true\"\n ]);\n\n NavLink.propTypes = {\n ...Link.propTypes,\n \"aria-current\": ariaCurrentType,\n activeClassName: PropTypes.string,\n activeStyle: PropTypes.object,\n className: PropTypes.string,\n exact: PropTypes.bool,\n isActive: PropTypes.func,\n location: PropTypes.object,\n sensitive: PropTypes.bool,\n strict: PropTypes.bool,\n style: PropTypes.object\n };\n}\n\nexport default NavLink;\n","//\n\nmodule.exports = function shallowEqual(objA, objB, compare, compareContext) {\n var ret = compare ? compare.call(compareContext, objA, objB) : void 0;\n\n if (ret !== void 0) {\n return !!ret;\n }\n\n if (objA === objB) {\n return true;\n }\n\n if (typeof objA !== \"object\" || !objA || typeof objB !== \"object\" || !objB) {\n return false;\n }\n\n var keysA = Object.keys(objA);\n var keysB = Object.keys(objB);\n\n if (keysA.length !== keysB.length) {\n return false;\n }\n\n var bHasOwnProperty = Object.prototype.hasOwnProperty.bind(objB);\n\n // Test for A's keys different from B.\n for (var idx = 0; idx < keysA.length; idx++) {\n var key = keysA[idx];\n\n if (!bHasOwnProperty(key)) {\n return false;\n }\n\n var valueA = objA[key];\n var valueB = objB[key];\n\n ret = compare ? compare.call(compareContext, valueA, valueB, key) : void 0;\n\n if (ret === false || (ret === void 0 && valueA !== valueB)) {\n return false;\n }\n }\n\n return true;\n};\n","var cached;\nexport default function getScrollBarSize(fresh) {\n if (typeof document === 'undefined') {\n return 0;\n }\n\n if (fresh || cached === undefined) {\n var inner = document.createElement('div');\n inner.style.width = '100%';\n inner.style.height = '200px';\n var outer = document.createElement('div');\n var outerStyle = outer.style;\n outerStyle.position = 'absolute';\n outerStyle.top = 0;\n outerStyle.left = 0;\n outerStyle.pointerEvents = 'none';\n outerStyle.visibility = 'hidden';\n outerStyle.width = '200px';\n outerStyle.height = '150px';\n outerStyle.overflow = 'hidden';\n outer.appendChild(inner);\n document.body.appendChild(outer);\n var widthContained = inner.offsetWidth;\n outer.style.overflow = 'scroll';\n var widthScroll = inner.offsetWidth;\n\n if (widthContained === widthScroll) {\n widthScroll = outer.clientWidth;\n }\n\n document.body.removeChild(outer);\n cached = widthContained - widthScroll;\n }\n\n return cached;\n}","import { createContext } from 'react';\nvar MenuContext = /*#__PURE__*/createContext({\n inlineCollapsed: false\n});\nexport default MenuContext;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _RightOutlined = _interopRequireDefault(require('./lib/icons/RightOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _RightOutlined;\n exports.default = _default;\n module.exports = _default;","import * as React from 'react';\nimport classNames from 'classnames';\n\nvar TransBtn = function TransBtn(_ref) {\n var className = _ref.className,\n customizeIcon = _ref.customizeIcon,\n customizeIconProps = _ref.customizeIconProps,\n _onMouseDown = _ref.onMouseDown,\n onClick = _ref.onClick,\n children = _ref.children;\n var icon;\n\n if (typeof customizeIcon === 'function') {\n icon = customizeIcon(customizeIconProps);\n } else {\n icon = customizeIcon;\n }\n\n return React.createElement(\"span\", {\n className: className,\n onMouseDown: function onMouseDown(event) {\n event.preventDefault();\n\n if (_onMouseDown) {\n _onMouseDown(event);\n }\n },\n style: {\n userSelect: 'none',\n WebkitUserSelect: 'none'\n },\n unselectable: \"on\",\n onClick: onClick,\n \"aria-hidden\": true\n }, icon !== undefined ? icon : React.createElement(\"span\", {\n className: classNames(className.split(/\\s+/).map(function (cls) {\n return \"\".concat(cls, \"-icon\");\n }))\n }, children));\n};\n\nexport default TransBtn;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport CloseCircleFilled from '@ant-design/icons/CloseCircleFilled';\nimport { tuple } from '../_util/type';\nimport { getInputClassName } from './Input';\nimport { cloneElement } from '../_util/reactNode';\nvar ClearableInputType = tuple('text', 'input');\nexport function hasPrefixSuffix(props) {\n return !!(props.prefix || props.suffix || props.allowClear);\n}\n\nvar ClearableLabeledInput = /*#__PURE__*/function (_React$Component) {\n _inherits(ClearableLabeledInput, _React$Component);\n\n var _super = _createSuper(ClearableLabeledInput);\n\n function ClearableLabeledInput() {\n var _this;\n\n _classCallCheck(this, ClearableLabeledInput);\n\n _this = _super.apply(this, arguments);\n /** @private Do not use out of this class. We do not promise this is always keep. */\n\n _this.containerRef = /*#__PURE__*/React.createRef();\n\n _this.onInputMouseUp = function (e) {\n var _a;\n\n if ((_a = _this.containerRef.current) === null || _a === void 0 ? void 0 : _a.contains(e.target)) {\n var triggerFocus = _this.props.triggerFocus;\n triggerFocus();\n }\n };\n\n return _this;\n }\n\n _createClass(ClearableLabeledInput, [{\n key: \"renderClearIcon\",\n value: function renderClearIcon(prefixCls) {\n var _this$props = this.props,\n allowClear = _this$props.allowClear,\n value = _this$props.value,\n disabled = _this$props.disabled,\n readOnly = _this$props.readOnly,\n inputType = _this$props.inputType,\n handleReset = _this$props.handleReset;\n\n if (!allowClear) {\n return null;\n }\n\n var needClear = !disabled && !readOnly && value;\n var className = inputType === ClearableInputType[0] ? \"\".concat(prefixCls, \"-textarea-clear-icon\") : \"\".concat(prefixCls, \"-clear-icon\");\n return /*#__PURE__*/React.createElement(CloseCircleFilled, {\n onClick: handleReset,\n className: classNames(className, _defineProperty({}, \"\".concat(className, \"-hidden\"), !needClear)),\n role: \"button\"\n });\n }\n }, {\n key: \"renderSuffix\",\n value: function renderSuffix(prefixCls) {\n var _this$props2 = this.props,\n suffix = _this$props2.suffix,\n allowClear = _this$props2.allowClear;\n\n if (suffix || allowClear) {\n return /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-suffix\")\n }, this.renderClearIcon(prefixCls), suffix);\n }\n\n return null;\n }\n }, {\n key: \"renderLabeledIcon\",\n value: function renderLabeledIcon(prefixCls, element) {\n var _classNames2;\n\n var _this$props3 = this.props,\n focused = _this$props3.focused,\n value = _this$props3.value,\n prefix = _this$props3.prefix,\n className = _this$props3.className,\n size = _this$props3.size,\n suffix = _this$props3.suffix,\n disabled = _this$props3.disabled,\n allowClear = _this$props3.allowClear,\n direction = _this$props3.direction,\n style = _this$props3.style,\n readOnly = _this$props3.readOnly,\n bordered = _this$props3.bordered;\n var suffixNode = this.renderSuffix(prefixCls);\n\n if (!hasPrefixSuffix(this.props)) {\n return cloneElement(element, {\n value: value\n });\n }\n\n var prefixNode = prefix ? /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-prefix\")\n }, prefix) : null;\n var affixWrapperCls = classNames(className, \"\".concat(prefixCls, \"-affix-wrapper\"), (_classNames2 = {}, _defineProperty(_classNames2, \"\".concat(prefixCls, \"-affix-wrapper-focused\"), focused), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-affix-wrapper-disabled\"), disabled), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-affix-wrapper-sm\"), size === 'small'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-affix-wrapper-lg\"), size === 'large'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-affix-wrapper-input-with-clear-btn\"), suffix && allowClear && value), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-affix-wrapper-rtl\"), direction === 'rtl'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-affix-wrapper-readonly\"), readOnly), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-affix-wrapper-borderless\"), !bordered), _classNames2));\n return /*#__PURE__*/React.createElement(\"span\", {\n ref: this.containerRef,\n className: affixWrapperCls,\n style: style,\n onMouseUp: this.onInputMouseUp\n }, prefixNode, cloneElement(element, {\n style: null,\n value: value,\n className: getInputClassName(prefixCls, bordered, size, disabled)\n }), suffixNode);\n }\n }, {\n key: \"renderInputWithLabel\",\n value: function renderInputWithLabel(prefixCls, labeledElement) {\n var _classNames3, _classNames4;\n\n var _this$props4 = this.props,\n addonBefore = _this$props4.addonBefore,\n addonAfter = _this$props4.addonAfter,\n style = _this$props4.style,\n size = _this$props4.size,\n className = _this$props4.className,\n direction = _this$props4.direction; // Not wrap when there is not addons\n\n if (!addonBefore && !addonAfter) {\n return labeledElement;\n }\n\n var wrapperClassName = \"\".concat(prefixCls, \"-group\");\n var addonClassName = \"\".concat(wrapperClassName, \"-addon\");\n var addonBeforeNode = addonBefore ? /*#__PURE__*/React.createElement(\"span\", {\n className: addonClassName\n }, addonBefore) : null;\n var addonAfterNode = addonAfter ? /*#__PURE__*/React.createElement(\"span\", {\n className: addonClassName\n }, addonAfter) : null;\n var mergedWrapperClassName = classNames(\"\".concat(prefixCls, \"-wrapper\"), (_classNames3 = {}, _defineProperty(_classNames3, wrapperClassName, addonBefore || addonAfter), _defineProperty(_classNames3, \"\".concat(wrapperClassName, \"-rtl\"), direction === 'rtl'), _classNames3));\n var mergedGroupClassName = classNames(className, \"\".concat(prefixCls, \"-group-wrapper\"), (_classNames4 = {}, _defineProperty(_classNames4, \"\".concat(prefixCls, \"-group-wrapper-sm\"), size === 'small'), _defineProperty(_classNames4, \"\".concat(prefixCls, \"-group-wrapper-lg\"), size === 'large'), _defineProperty(_classNames4, \"\".concat(prefixCls, \"-group-wrapper-rtl\"), direction === 'rtl'), _classNames4)); // Need another wrapper for changing display:table to display:inline-block\n // and put style prop in wrapper\n\n return /*#__PURE__*/React.createElement(\"span\", {\n className: mergedGroupClassName,\n style: style\n }, /*#__PURE__*/React.createElement(\"span\", {\n className: mergedWrapperClassName\n }, addonBeforeNode, cloneElement(labeledElement, {\n style: null\n }), addonAfterNode));\n }\n }, {\n key: \"renderTextAreaWithClearIcon\",\n value: function renderTextAreaWithClearIcon(prefixCls, element) {\n var _classNames5;\n\n var _this$props5 = this.props,\n value = _this$props5.value,\n allowClear = _this$props5.allowClear,\n className = _this$props5.className,\n style = _this$props5.style,\n direction = _this$props5.direction,\n bordered = _this$props5.bordered;\n\n if (!allowClear) {\n return cloneElement(element, {\n value: value\n });\n }\n\n var affixWrapperCls = classNames(className, \"\".concat(prefixCls, \"-affix-wrapper\"), \"\".concat(prefixCls, \"-affix-wrapper-textarea-with-clear-btn\"), (_classNames5 = {}, _defineProperty(_classNames5, \"\".concat(prefixCls, \"-affix-wrapper-rtl\"), direction === 'rtl'), _defineProperty(_classNames5, \"\".concat(prefixCls, \"-affix-wrapper-borderless\"), !bordered), _classNames5));\n return /*#__PURE__*/React.createElement(\"span\", {\n className: affixWrapperCls,\n style: style\n }, cloneElement(element, {\n style: null,\n value: value\n }), this.renderClearIcon(prefixCls));\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this$props6 = this.props,\n prefixCls = _this$props6.prefixCls,\n inputType = _this$props6.inputType,\n element = _this$props6.element;\n\n if (inputType === ClearableInputType[0]) {\n return this.renderTextAreaWithClearIcon(prefixCls, element);\n }\n\n return this.renderInputWithLabel(prefixCls, this.renderLabeledIcon(prefixCls, element));\n }\n }]);\n\n return ClearableLabeledInput;\n}(React.Component);\n\nexport default ClearableLabeledInput;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport ClearableLabeledInput, { hasPrefixSuffix } from './ClearableLabeledInput';\nimport { ConfigConsumer } from '../config-provider';\nimport SizeContext from '../config-provider/SizeContext';\nimport devWarning from '../_util/devWarning';\nexport function fixControlledValue(value) {\n if (typeof value === 'undefined' || value === null) {\n return '';\n }\n\n return value;\n}\nexport function resolveOnChange(target, e, onChange) {\n if (onChange) {\n var event = e;\n\n if (e.type === 'click') {\n // click clear icon\n event = Object.create(e);\n event.target = target;\n event.currentTarget = target;\n var originalInputValue = target.value; // change target ref value cause e.target.value should be '' when clear input\n\n target.value = '';\n onChange(event); // reset target ref value\n\n target.value = originalInputValue;\n return;\n }\n\n onChange(event);\n }\n}\nexport function getInputClassName(prefixCls, bordered, size, disabled, direction) {\n var _classNames;\n\n return classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-sm\"), size === 'small'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-lg\"), size === 'large'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-disabled\"), disabled), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-borderless\"), !bordered), _classNames));\n}\n\nvar Input = /*#__PURE__*/function (_React$Component) {\n _inherits(Input, _React$Component);\n\n var _super = _createSuper(Input);\n\n function Input(props) {\n var _this;\n\n _classCallCheck(this, Input);\n\n _this = _super.call(this, props);\n _this.direction = 'ltr';\n\n _this.focus = function () {\n _this.input.focus();\n };\n\n _this.saveClearableInput = function (input) {\n _this.clearableInput = input;\n };\n\n _this.saveInput = function (input) {\n _this.input = input;\n };\n\n _this.onFocus = function (e) {\n var onFocus = _this.props.onFocus;\n\n _this.setState({\n focused: true\n }, _this.clearPasswordValueAttribute);\n\n if (onFocus) {\n onFocus(e);\n }\n };\n\n _this.onBlur = function (e) {\n var onBlur = _this.props.onBlur;\n\n _this.setState({\n focused: false\n }, _this.clearPasswordValueAttribute);\n\n if (onBlur) {\n onBlur(e);\n }\n };\n\n _this.handleReset = function (e) {\n _this.setValue('', function () {\n _this.focus();\n });\n\n resolveOnChange(_this.input, e, _this.props.onChange);\n };\n\n _this.renderInput = function (prefixCls, size, bordered) {\n var input = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};\n var _this$props = _this.props,\n className = _this$props.className,\n addonBefore = _this$props.addonBefore,\n addonAfter = _this$props.addonAfter,\n customizeSize = _this$props.size,\n disabled = _this$props.disabled; // Fix https://fb.me/react-unknown-prop\n\n var otherProps = omit(_this.props, ['prefixCls', 'onPressEnter', 'addonBefore', 'addonAfter', 'prefix', 'suffix', 'allowClear', // Input elements must be either controlled or uncontrolled,\n // specify either the value prop, or the defaultValue prop, but not both.\n 'defaultValue', 'size', 'inputType', 'bordered']);\n return /*#__PURE__*/React.createElement(\"input\", _extends({\n autoComplete: input.autoComplete\n }, otherProps, {\n onChange: _this.handleChange,\n onFocus: _this.onFocus,\n onBlur: _this.onBlur,\n onKeyDown: _this.handleKeyDown,\n className: classNames(getInputClassName(prefixCls, bordered, customizeSize || size, disabled, _this.direction), _defineProperty({}, className, className && !addonBefore && !addonAfter)),\n ref: _this.saveInput\n }));\n };\n\n _this.clearPasswordValueAttribute = function () {\n // https://github.com/ant-design/ant-design/issues/20541\n _this.removePasswordTimeout = setTimeout(function () {\n if (_this.input && _this.input.getAttribute('type') === 'password' && _this.input.hasAttribute('value')) {\n _this.input.removeAttribute('value');\n }\n });\n };\n\n _this.handleChange = function (e) {\n _this.setValue(e.target.value, _this.clearPasswordValueAttribute);\n\n resolveOnChange(_this.input, e, _this.props.onChange);\n };\n\n _this.handleKeyDown = function (e) {\n var _this$props2 = _this.props,\n onPressEnter = _this$props2.onPressEnter,\n onKeyDown = _this$props2.onKeyDown;\n\n if (e.keyCode === 13 && onPressEnter) {\n onPressEnter(e);\n }\n\n if (onKeyDown) {\n onKeyDown(e);\n }\n };\n\n _this.renderComponent = function (_ref) {\n var getPrefixCls = _ref.getPrefixCls,\n direction = _ref.direction,\n input = _ref.input;\n var _this$state = _this.state,\n value = _this$state.value,\n focused = _this$state.focused;\n var _this$props3 = _this.props,\n customizePrefixCls = _this$props3.prefixCls,\n _this$props3$bordered = _this$props3.bordered,\n bordered = _this$props3$bordered === void 0 ? true : _this$props3$bordered;\n var prefixCls = getPrefixCls('input', customizePrefixCls);\n _this.direction = direction;\n return /*#__PURE__*/React.createElement(SizeContext.Consumer, null, function (size) {\n return /*#__PURE__*/React.createElement(ClearableLabeledInput, _extends({\n size: size\n }, _this.props, {\n prefixCls: prefixCls,\n inputType: \"input\",\n value: fixControlledValue(value),\n element: _this.renderInput(prefixCls, size, bordered, input),\n handleReset: _this.handleReset,\n ref: _this.saveClearableInput,\n direction: direction,\n focused: focused,\n triggerFocus: _this.focus,\n bordered: bordered\n }));\n });\n };\n\n var value = typeof props.value === 'undefined' ? props.defaultValue : props.value;\n _this.state = {\n value: value,\n focused: false,\n // eslint-disable-next-line react/no-unused-state\n prevValue: props.value\n };\n return _this;\n }\n\n _createClass(Input, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.clearPasswordValueAttribute();\n } // Since polyfill `getSnapshotBeforeUpdate` need work with `componentDidUpdate`.\n // We keep an empty function here.\n\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {}\n }, {\n key: \"getSnapshotBeforeUpdate\",\n value: function getSnapshotBeforeUpdate(prevProps) {\n if (hasPrefixSuffix(prevProps) !== hasPrefixSuffix(this.props)) {\n devWarning(this.input !== document.activeElement, 'Input', \"When Input is focused, dynamic add or remove prefix / suffix will make it lose focus caused by dom structure change. Read more: https://ant.design/components/input/#FAQ\");\n }\n\n return null;\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n if (this.removePasswordTimeout) {\n clearTimeout(this.removePasswordTimeout);\n }\n }\n }, {\n key: \"blur\",\n value: function blur() {\n this.input.blur();\n }\n }, {\n key: \"select\",\n value: function select() {\n this.input.select();\n }\n }, {\n key: \"setValue\",\n value: function setValue(value, callback) {\n if (this.props.value === undefined) {\n this.setState({\n value: value\n }, callback);\n }\n }\n }, {\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderComponent);\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(nextProps, _ref2) {\n var prevValue = _ref2.prevValue;\n var newState = {\n prevValue: nextProps.value\n };\n\n if (nextProps.value !== undefined || prevValue !== nextProps.value) {\n newState.value = nextProps.value;\n }\n\n return newState;\n }\n }]);\n\n return Input;\n}(React.Component);\n\nInput.defaultProps = {\n type: 'text'\n};\nexport default Input;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { ConfigConsumer } from '../config-provider';\n\nvar Group = function Group(props) {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, function (_ref) {\n var _classNames;\n\n var getPrefixCls = _ref.getPrefixCls,\n direction = _ref.direction;\n var customizePrefixCls = props.prefixCls,\n _props$className = props.className,\n className = _props$className === void 0 ? '' : _props$className;\n var prefixCls = getPrefixCls('input-group', customizePrefixCls);\n var cls = classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-lg\"), props.size === 'large'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-sm\"), props.size === 'small'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-compact\"), props.compact), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _classNames), className);\n return /*#__PURE__*/React.createElement(\"span\", {\n className: cls,\n style: props.style,\n onMouseEnter: props.onMouseEnter,\n onMouseLeave: props.onMouseLeave,\n onFocus: props.onFocus,\n onBlur: props.onBlur\n }, props.children);\n });\n};\n\nexport default Group;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { composeRef } from \"rc-util/es/ref\";\nimport SearchOutlined from '@ant-design/icons/SearchOutlined';\nimport LoadingOutlined from '@ant-design/icons/LoadingOutlined';\nimport Input from './Input';\nimport Button from '../button';\nimport SizeContext from '../config-provider/SizeContext';\nimport { ConfigConsumer } from '../config-provider';\nimport { cloneElement, replaceElement } from '../_util/reactNode';\nvar Search = /*#__PURE__*/React.forwardRef(function (props, ref) {\n var inputRef = React.useRef(null);\n\n var onChange = function onChange(e) {\n var customOnChange = props.onChange,\n customOnSearch = props.onSearch;\n\n if (e && e.target && e.type === 'click' && customOnSearch) {\n customOnSearch(e.target.value, e);\n }\n\n if (customOnChange) {\n customOnChange(e);\n }\n };\n\n var onMouseDown = function onMouseDown(e) {\n var _a;\n\n if (document.activeElement === ((_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.input)) {\n e.preventDefault();\n }\n };\n\n var onSearch = function onSearch(e) {\n var _a;\n\n var customOnSearch = props.onSearch,\n loading = props.loading,\n disabled = props.disabled;\n\n if (loading || disabled) {\n return;\n }\n\n if (customOnSearch) {\n customOnSearch((_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.input.value, e);\n }\n };\n\n var renderLoading = function renderLoading(prefixCls) {\n var enterButton = props.enterButton,\n customizeSize = props.size;\n\n if (enterButton) {\n return /*#__PURE__*/React.createElement(SizeContext.Consumer, {\n key: \"enterButton\"\n }, function (size) {\n return /*#__PURE__*/React.createElement(Button, {\n className: \"\".concat(prefixCls, \"-button\"),\n type: \"primary\",\n size: customizeSize || size\n }, /*#__PURE__*/React.createElement(LoadingOutlined, null));\n });\n }\n\n return /*#__PURE__*/React.createElement(LoadingOutlined, {\n className: \"\".concat(prefixCls, \"-icon\"),\n key: \"loadingIcon\"\n });\n };\n\n var renderSuffix = function renderSuffix(prefixCls) {\n var suffix = props.suffix,\n enterButton = props.enterButton,\n loading = props.loading;\n\n if (loading && !enterButton) {\n return [suffix, renderLoading(prefixCls)];\n }\n\n if (enterButton) return suffix;\n var icon = /*#__PURE__*/React.createElement(SearchOutlined, {\n className: \"\".concat(prefixCls, \"-icon\"),\n key: \"searchIcon\",\n onClick: onSearch\n });\n\n if (suffix) {\n return [replaceElement(suffix, null, {\n key: 'suffix'\n }), icon];\n }\n\n return icon;\n };\n\n var renderAddonAfter = function renderAddonAfter(prefixCls, size) {\n var enterButton = props.enterButton,\n disabled = props.disabled,\n addonAfter = props.addonAfter,\n loading = props.loading;\n var btnClassName = \"\".concat(prefixCls, \"-button\");\n\n if (loading && enterButton) {\n return [renderLoading(prefixCls), addonAfter];\n }\n\n if (!enterButton) return addonAfter;\n var button;\n var enterButtonAsElement = enterButton;\n var isAntdButton = enterButtonAsElement.type && enterButtonAsElement.type.__ANT_BUTTON === true;\n\n if (isAntdButton || enterButtonAsElement.type === 'button') {\n button = cloneElement(enterButtonAsElement, _extends({\n onMouseDown: onMouseDown,\n onClick: onSearch,\n key: 'enterButton'\n }, isAntdButton ? {\n className: btnClassName,\n size: size\n } : {}));\n } else {\n button = /*#__PURE__*/React.createElement(Button, {\n className: btnClassName,\n type: \"primary\",\n size: size,\n disabled: disabled,\n key: \"enterButton\",\n onMouseDown: onMouseDown,\n onClick: onSearch\n }, enterButton === true ? /*#__PURE__*/React.createElement(SearchOutlined, null) : enterButton);\n }\n\n if (addonAfter) {\n return [button, replaceElement(addonAfter, null, {\n key: 'addonAfter'\n })];\n }\n\n return button;\n };\n\n var renderSearch = function renderSearch(_ref) {\n var getPrefixCls = _ref.getPrefixCls,\n direction = _ref.direction;\n\n var customizePrefixCls = props.prefixCls,\n customizeInputPrefixCls = props.inputPrefixCls,\n enterButton = props.enterButton,\n className = props.className,\n customizeSize = props.size,\n restProps = __rest(props, [\"prefixCls\", \"inputPrefixCls\", \"enterButton\", \"className\", \"size\"]);\n\n delete restProps.onSearch;\n delete restProps.loading;\n var prefixCls = getPrefixCls('input-search', customizePrefixCls);\n var inputPrefixCls = getPrefixCls('input', customizeInputPrefixCls);\n\n var getClassName = function getClassName(size) {\n var inputClassName;\n\n if (enterButton) {\n var _classNames;\n\n inputClassName = classNames(prefixCls, className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-enter-button\"), !!enterButton), _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(size), !!size), _classNames));\n } else {\n inputClassName = classNames(prefixCls, className, _defineProperty({}, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'));\n }\n\n return inputClassName;\n };\n\n return /*#__PURE__*/React.createElement(SizeContext.Consumer, null, function (size) {\n return /*#__PURE__*/React.createElement(Input, _extends({\n ref: composeRef(inputRef, ref),\n onPressEnter: onSearch\n }, restProps, {\n size: customizeSize || size,\n prefixCls: inputPrefixCls,\n addonAfter: renderAddonAfter(prefixCls, customizeSize || size),\n suffix: renderSuffix(prefixCls),\n onChange: onChange,\n className: getClassName(customizeSize || size)\n }));\n });\n };\n\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, renderSearch);\n});\nSearch.defaultProps = {\n enterButton: false\n};\nSearch.displayName = 'Search';\nexport default Search;","// Thanks to https://github.com/andreypopp/react-textarea-autosize/\n\n/**\n * calculateNodeHeight(uiTextNode, useCache = false)\n */\nvar HIDDEN_TEXTAREA_STYLE = \"\\n min-height:0 !important;\\n max-height:none !important;\\n height:0 !important;\\n visibility:hidden !important;\\n overflow:hidden !important;\\n position:absolute !important;\\n z-index:-1000 !important;\\n top:0 !important;\\n right:0 !important\\n\";\nvar SIZING_STYLE = ['letter-spacing', 'line-height', 'padding-top', 'padding-bottom', 'font-family', 'font-weight', 'font-size', 'font-variant', 'text-rendering', 'text-transform', 'width', 'text-indent', 'padding-left', 'padding-right', 'border-width', 'box-sizing'];\nvar computedStyleCache = {};\nvar hiddenTextarea;\nexport function calculateNodeStyling(node) {\n var useCache = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n var nodeRef = node.getAttribute('id') || node.getAttribute('data-reactid') || node.getAttribute('name');\n\n if (useCache && computedStyleCache[nodeRef]) {\n return computedStyleCache[nodeRef];\n }\n\n var style = window.getComputedStyle(node);\n var boxSizing = style.getPropertyValue('box-sizing') || style.getPropertyValue('-moz-box-sizing') || style.getPropertyValue('-webkit-box-sizing');\n var paddingSize = parseFloat(style.getPropertyValue('padding-bottom')) + parseFloat(style.getPropertyValue('padding-top'));\n var borderSize = parseFloat(style.getPropertyValue('border-bottom-width')) + parseFloat(style.getPropertyValue('border-top-width'));\n var sizingStyle = SIZING_STYLE.map(function (name) {\n return \"\".concat(name, \":\").concat(style.getPropertyValue(name));\n }).join(';');\n var nodeInfo = {\n sizingStyle: sizingStyle,\n paddingSize: paddingSize,\n borderSize: borderSize,\n boxSizing: boxSizing\n };\n\n if (useCache && nodeRef) {\n computedStyleCache[nodeRef] = nodeInfo;\n }\n\n return nodeInfo;\n}\nexport default function calculateNodeHeight(uiTextNode) {\n var useCache = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n var minRows = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;\n var maxRows = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null;\n\n if (!hiddenTextarea) {\n hiddenTextarea = document.createElement('textarea');\n hiddenTextarea.setAttribute('tab-index', '-1');\n hiddenTextarea.setAttribute('aria-hidden', 'true');\n document.body.appendChild(hiddenTextarea);\n } // Fix wrap=\"off\" issue\n // https://github.com/ant-design/ant-design/issues/6577\n\n\n if (uiTextNode.getAttribute('wrap')) {\n hiddenTextarea.setAttribute('wrap', uiTextNode.getAttribute('wrap'));\n } else {\n hiddenTextarea.removeAttribute('wrap');\n } // Copy all CSS properties that have an impact on the height of the content in\n // the textbox\n\n\n var _calculateNodeStyling = calculateNodeStyling(uiTextNode, useCache),\n paddingSize = _calculateNodeStyling.paddingSize,\n borderSize = _calculateNodeStyling.borderSize,\n boxSizing = _calculateNodeStyling.boxSizing,\n sizingStyle = _calculateNodeStyling.sizingStyle; // Need to have the overflow attribute to hide the scrollbar otherwise\n // text-lines will not calculated properly as the shadow will technically be\n // narrower for content\n\n\n hiddenTextarea.setAttribute('style', \"\".concat(sizingStyle, \";\").concat(HIDDEN_TEXTAREA_STYLE));\n hiddenTextarea.value = uiTextNode.value || uiTextNode.placeholder || '';\n var minHeight = Number.MIN_SAFE_INTEGER;\n var maxHeight = Number.MAX_SAFE_INTEGER;\n var height = hiddenTextarea.scrollHeight;\n var overflowY;\n\n if (boxSizing === 'border-box') {\n // border-box: add border, since height = content + padding + border\n height += borderSize;\n } else if (boxSizing === 'content-box') {\n // remove padding, since height = content\n height -= paddingSize;\n }\n\n if (minRows !== null || maxRows !== null) {\n // measure height of a textarea with a single row\n hiddenTextarea.value = ' ';\n var singleRowHeight = hiddenTextarea.scrollHeight - paddingSize;\n\n if (minRows !== null) {\n minHeight = singleRowHeight * minRows;\n\n if (boxSizing === 'border-box') {\n minHeight = minHeight + paddingSize + borderSize;\n }\n\n height = Math.max(minHeight, height);\n }\n\n if (maxRows !== null) {\n maxHeight = singleRowHeight * maxRows;\n\n if (boxSizing === 'border-box') {\n maxHeight = maxHeight + paddingSize + borderSize;\n }\n\n overflowY = height > maxHeight ? '' : 'hidden';\n height = Math.min(maxHeight, height);\n }\n }\n\n return {\n height: height,\n minHeight: minHeight,\n maxHeight: maxHeight,\n overflowY: overflowY\n };\n}","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nimport _getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nimport * as React from 'react';\nimport ResizeObserver from 'rc-resize-observer';\nimport omit from 'omit.js';\nimport classNames from 'classnames';\nimport calculateNodeHeight from './calculateNodeHeight'; // eslint-disable-next-line @typescript-eslint/naming-convention\n\nvar RESIZE_STATUS;\n\n(function (RESIZE_STATUS) {\n RESIZE_STATUS[RESIZE_STATUS[\"NONE\"] = 0] = \"NONE\";\n RESIZE_STATUS[RESIZE_STATUS[\"RESIZING\"] = 1] = \"RESIZING\";\n RESIZE_STATUS[RESIZE_STATUS[\"RESIZED\"] = 2] = \"RESIZED\";\n})(RESIZE_STATUS || (RESIZE_STATUS = {}));\n\nvar ResizableTextArea = /*#__PURE__*/function (_React$Component) {\n _inherits(ResizableTextArea, _React$Component);\n\n var _super = _createSuper(ResizableTextArea);\n\n function ResizableTextArea(props) {\n var _this;\n\n _classCallCheck(this, ResizableTextArea);\n\n _this = _super.call(this, props);\n\n _this.saveTextArea = function (textArea) {\n _this.textArea = textArea;\n };\n\n _this.handleResize = function (size) {\n var resizeStatus = _this.state.resizeStatus;\n var _this$props = _this.props,\n autoSize = _this$props.autoSize,\n onResize = _this$props.onResize;\n\n if (resizeStatus !== RESIZE_STATUS.NONE) {\n return;\n }\n\n if (typeof onResize === 'function') {\n onResize(size);\n }\n\n if (autoSize) {\n _this.resizeOnNextFrame();\n }\n };\n\n _this.resizeOnNextFrame = function () {\n cancelAnimationFrame(_this.nextFrameActionId);\n _this.nextFrameActionId = requestAnimationFrame(_this.resizeTextarea);\n };\n\n _this.resizeTextarea = function () {\n var autoSize = _this.props.autoSize;\n\n if (!autoSize || !_this.textArea) {\n return;\n }\n\n var minRows = autoSize.minRows,\n maxRows = autoSize.maxRows;\n var textareaStyles = calculateNodeHeight(_this.textArea, false, minRows, maxRows);\n\n _this.setState({\n textareaStyles: textareaStyles,\n resizeStatus: RESIZE_STATUS.RESIZING\n }, function () {\n cancelAnimationFrame(_this.resizeFrameId);\n _this.resizeFrameId = requestAnimationFrame(function () {\n _this.setState({\n resizeStatus: RESIZE_STATUS.RESIZED\n }, function () {\n _this.resizeFrameId = requestAnimationFrame(function () {\n _this.setState({\n resizeStatus: RESIZE_STATUS.NONE\n });\n\n _this.fixFirefoxAutoScroll();\n });\n });\n });\n });\n };\n\n _this.renderTextArea = function () {\n var _this$props2 = _this.props,\n _this$props2$prefixCl = _this$props2.prefixCls,\n prefixCls = _this$props2$prefixCl === void 0 ? 'rc-textarea' : _this$props2$prefixCl,\n autoSize = _this$props2.autoSize,\n onResize = _this$props2.onResize,\n className = _this$props2.className,\n disabled = _this$props2.disabled;\n var _this$state = _this.state,\n textareaStyles = _this$state.textareaStyles,\n resizeStatus = _this$state.resizeStatus;\n var otherProps = omit(_this.props, ['prefixCls', 'onPressEnter', 'autoSize', 'defaultValue', 'onResize']);\n var cls = classNames(prefixCls, className, _defineProperty({}, \"\".concat(prefixCls, \"-disabled\"), disabled)); // Fix https://github.com/ant-design/ant-design/issues/6776\n // Make sure it could be reset when using form.getFieldDecorator\n\n if ('value' in otherProps) {\n otherProps.value = otherProps.value || '';\n }\n\n var style = _objectSpread(_objectSpread(_objectSpread({}, _this.props.style), textareaStyles), resizeStatus === RESIZE_STATUS.RESIZING ? // React will warning when mix `overflow` & `overflowY`.\n // We need to define this separately.\n {\n overflowX: 'hidden',\n overflowY: 'hidden'\n } : null);\n\n return React.createElement(ResizeObserver, {\n onResize: _this.handleResize,\n disabled: !(autoSize || onResize)\n }, React.createElement(\"textarea\", Object.assign({}, otherProps, {\n className: cls,\n style: style,\n ref: _this.saveTextArea\n })));\n };\n\n _this.state = {\n textareaStyles: {},\n resizeStatus: RESIZE_STATUS.NONE\n };\n return _this;\n }\n\n _createClass(ResizableTextArea, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.resizeTextarea();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate(prevProps) {\n // Re-render with the new content then recalculate the height as required.\n if (prevProps.value !== this.props.value) {\n this.resizeTextarea();\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n cancelAnimationFrame(this.nextFrameActionId);\n cancelAnimationFrame(this.resizeFrameId);\n } // https://github.com/ant-design/ant-design/issues/21870\n\n }, {\n key: \"fixFirefoxAutoScroll\",\n value: function fixFirefoxAutoScroll() {\n try {\n if (document.activeElement === this.textArea) {\n var currentStart = this.textArea.selectionStart;\n var currentEnd = this.textArea.selectionEnd;\n this.textArea.setSelectionRange(currentStart, currentEnd);\n }\n } catch (e) {// Fix error in Chrome:\n // Failed to read the 'selectionStart' property from 'HTMLInputElement'\n // http://stackoverflow.com/q/21177489/3040605\n }\n }\n }, {\n key: \"render\",\n value: function render() {\n return this.renderTextArea();\n }\n }]);\n\n return ResizableTextArea;\n}(React.Component);\n\nexport default ResizableTextArea;","import _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nimport _getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nimport * as React from 'react';\nimport ResizableTextArea from './ResizableTextArea';\n\nvar TextArea = /*#__PURE__*/function (_React$Component) {\n _inherits(TextArea, _React$Component);\n\n var _super = _createSuper(TextArea);\n\n function TextArea(props) {\n var _this;\n\n _classCallCheck(this, TextArea);\n\n _this = _super.call(this, props);\n\n _this.focus = function () {\n _this.resizableTextArea.textArea.focus();\n };\n\n _this.saveTextArea = function (resizableTextArea) {\n _this.resizableTextArea = resizableTextArea;\n };\n\n _this.handleChange = function (e) {\n var onChange = _this.props.onChange;\n\n _this.setValue(e.target.value, function () {\n _this.resizableTextArea.resizeTextarea();\n });\n\n if (onChange) {\n onChange(e);\n }\n };\n\n _this.handleKeyDown = function (e) {\n var _this$props = _this.props,\n onPressEnter = _this$props.onPressEnter,\n onKeyDown = _this$props.onKeyDown;\n\n if (e.keyCode === 13 && onPressEnter) {\n onPressEnter(e);\n }\n\n if (onKeyDown) {\n onKeyDown(e);\n }\n };\n\n var value = typeof props.value === 'undefined' || props.value === null ? props.defaultValue : props.value;\n _this.state = {\n value: value\n };\n return _this;\n }\n\n _createClass(TextArea, [{\n key: \"setValue\",\n value: function setValue(value, callback) {\n if (!('value' in this.props)) {\n this.setState({\n value: value\n }, callback);\n }\n }\n }, {\n key: \"blur\",\n value: function blur() {\n this.resizableTextArea.textArea.blur();\n }\n }, {\n key: \"render\",\n value: function render() {\n return React.createElement(ResizableTextArea, Object.assign({}, this.props, {\n value: this.state.value,\n onKeyDown: this.handleKeyDown,\n onChange: this.handleChange,\n ref: this.saveTextArea\n }));\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(nextProps) {\n if ('value' in nextProps) {\n return {\n value: nextProps.value\n };\n }\n\n return null;\n }\n }]);\n\n return TextArea;\n}(React.Component);\n\nexport { ResizableTextArea };\nexport default TextArea;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\nimport * as React from 'react';\nimport RcTextArea from 'rc-textarea';\nimport omit from 'omit.js';\nimport classNames from 'classnames';\nimport ClearableLabeledInput from './ClearableLabeledInput';\nimport { ConfigConsumer } from '../config-provider';\nimport { fixControlledValue, resolveOnChange } from './Input';\n\nvar TextArea = /*#__PURE__*/function (_React$Component) {\n _inherits(TextArea, _React$Component);\n\n var _super = _createSuper(TextArea);\n\n function TextArea(props) {\n var _this;\n\n _classCallCheck(this, TextArea);\n\n _this = _super.call(this, props);\n\n _this.focus = function () {\n _this.resizableTextArea.textArea.focus();\n };\n\n _this.saveTextArea = function (textarea) {\n _this.resizableTextArea = textarea === null || textarea === void 0 ? void 0 : textarea.resizableTextArea;\n };\n\n _this.saveClearableInput = function (clearableInput) {\n _this.clearableInput = clearableInput;\n };\n\n _this.handleChange = function (e) {\n _this.setValue(e.target.value);\n\n resolveOnChange(_this.resizableTextArea.textArea, e, _this.props.onChange);\n };\n\n _this.handleReset = function (e) {\n _this.setValue('', function () {\n _this.focus();\n });\n\n resolveOnChange(_this.resizableTextArea.textArea, e, _this.props.onChange);\n };\n\n _this.renderTextArea = function (prefixCls, bordered) {\n return /*#__PURE__*/React.createElement(RcTextArea, _extends({}, omit(_this.props, ['allowClear', 'bordered']), {\n className: classNames(_this.props.className, _defineProperty({}, \"\".concat(prefixCls, \"-borderless\"), !bordered)),\n prefixCls: prefixCls,\n onChange: _this.handleChange,\n ref: _this.saveTextArea\n }));\n };\n\n _this.renderComponent = function (_ref) {\n var getPrefixCls = _ref.getPrefixCls,\n direction = _ref.direction;\n var value = _this.state.value;\n var _this$props = _this.props,\n customizePrefixCls = _this$props.prefixCls,\n _this$props$bordered = _this$props.bordered,\n bordered = _this$props$bordered === void 0 ? true : _this$props$bordered;\n var prefixCls = getPrefixCls('input', customizePrefixCls);\n return /*#__PURE__*/React.createElement(ClearableLabeledInput, _extends({}, _this.props, {\n prefixCls: prefixCls,\n direction: direction,\n inputType: \"text\",\n value: fixControlledValue(value),\n element: _this.renderTextArea(prefixCls, bordered),\n handleReset: _this.handleReset,\n ref: _this.saveClearableInput,\n triggerFocus: _this.focus,\n bordered: bordered\n }));\n };\n\n var value = typeof props.value === 'undefined' ? props.defaultValue : props.value;\n _this.state = {\n value: value\n };\n return _this;\n }\n\n _createClass(TextArea, [{\n key: \"setValue\",\n value: function setValue(value, callback) {\n if (this.props.value === undefined) {\n this.setState({\n value: value\n }, callback);\n }\n }\n }, {\n key: \"blur\",\n value: function blur() {\n this.resizableTextArea.textArea.blur();\n }\n }, {\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderComponent);\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(nextProps) {\n if (nextProps.value !== undefined) {\n return {\n value: nextProps.value\n };\n }\n\n return null;\n }\n }]);\n\n return TextArea;\n}(React.Component);\n\nexport default TextArea;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport EyeOutlined from '@ant-design/icons/EyeOutlined';\nimport EyeInvisibleOutlined from '@ant-design/icons/EyeInvisibleOutlined';\nimport { useState } from 'react';\nimport { ConfigConsumer } from '../config-provider';\nimport Input from './Input';\nvar ActionMap = {\n click: 'onClick',\n hover: 'onMouseOver'\n};\nvar Password = /*#__PURE__*/React.forwardRef(function (props, ref) {\n var _useState = useState(false),\n _useState2 = _slicedToArray(_useState, 2),\n visible = _useState2[0],\n setVisible = _useState2[1];\n\n var onVisibleChange = function onVisibleChange() {\n var disabled = props.disabled;\n\n if (disabled) {\n return;\n }\n\n setVisible(!visible);\n };\n\n var getIcon = function getIcon(prefixCls) {\n var _iconProps;\n\n var action = props.action,\n _props$iconRender = props.iconRender,\n iconRender = _props$iconRender === void 0 ? function () {\n return null;\n } : _props$iconRender;\n var iconTrigger = ActionMap[action] || '';\n var icon = iconRender(visible);\n var iconProps = (_iconProps = {}, _defineProperty(_iconProps, iconTrigger, onVisibleChange), _defineProperty(_iconProps, \"className\", \"\".concat(prefixCls, \"-icon\")), _defineProperty(_iconProps, \"key\", 'passwordIcon'), _defineProperty(_iconProps, \"onMouseDown\", function onMouseDown(e) {\n // Prevent focused state lost\n // https://github.com/ant-design/ant-design/issues/15173\n e.preventDefault();\n }), _defineProperty(_iconProps, \"onMouseUp\", function onMouseUp(e) {\n // Prevent caret position change\n // https://github.com/ant-design/ant-design/issues/23524\n e.preventDefault();\n }), _iconProps);\n return /*#__PURE__*/React.cloneElement( /*#__PURE__*/React.isValidElement(icon) ? icon : /*#__PURE__*/React.createElement(\"span\", null, icon), iconProps);\n };\n\n var renderPassword = function renderPassword(_ref) {\n var getPrefixCls = _ref.getPrefixCls;\n\n var className = props.className,\n customizePrefixCls = props.prefixCls,\n customizeInputPrefixCls = props.inputPrefixCls,\n size = props.size,\n visibilityToggle = props.visibilityToggle,\n restProps = __rest(props, [\"className\", \"prefixCls\", \"inputPrefixCls\", \"size\", \"visibilityToggle\"]);\n\n var inputPrefixCls = getPrefixCls('input', customizeInputPrefixCls);\n var prefixCls = getPrefixCls('input-password', customizePrefixCls);\n var suffixIcon = visibilityToggle && getIcon(prefixCls);\n var inputClassName = classNames(prefixCls, className, _defineProperty({}, \"\".concat(prefixCls, \"-\").concat(size), !!size));\n\n var omittedProps = _extends(_extends({}, omit(restProps, ['suffix', 'iconRender'])), {\n type: visible ? 'text' : 'password',\n className: inputClassName,\n prefixCls: inputPrefixCls,\n suffix: suffixIcon\n });\n\n if (size) {\n omittedProps.size = size;\n }\n\n return /*#__PURE__*/React.createElement(Input, _extends({\n ref: ref\n }, omittedProps));\n };\n\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, renderPassword);\n});\nPassword.defaultProps = {\n action: 'click',\n visibilityToggle: true,\n iconRender: function iconRender(visible) {\n return visible ? /*#__PURE__*/React.createElement(EyeOutlined, null) : /*#__PURE__*/React.createElement(EyeInvisibleOutlined, null);\n }\n};\nPassword.displayName = 'Password';\nexport default Password;","import Input from './Input';\nimport Group from './Group';\nimport Search from './Search';\nimport TextArea from './TextArea';\nimport Password from './Password';\nInput.Group = Group;\nInput.Search = Search;\nInput.TextArea = TextArea;\nInput.Password = Password;\nexport default Input;","import '../../style/index.less';\nimport './index.less';","var baseIsNative = require('./_baseIsNative'),\n getValue = require('./_getValue');\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nmodule.exports = getNative;\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import arrayLikeToArray from \"./arrayLikeToArray\";\nexport default function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);\n}","import * as React from 'react';\nexport default function useMemo(getValue, condition, shouldUpdate) {\n var cacheRef = React.useRef({});\n\n if (!('value' in cacheRef.current) || shouldUpdate(cacheRef.current.condition, condition)) {\n cacheRef.current.value = getValue();\n cacheRef.current.condition = condition;\n }\n\n return cacheRef.current.value;\n}","import _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nexport default function useForceUpdate() {\n var _React$useReducer = React.useReducer(function (x) {\n return x + 1;\n }, 0),\n _React$useReducer2 = _slicedToArray(_React$useReducer, 2),\n forceUpdate = _React$useReducer2[1];\n\n return forceUpdate;\n}","/**\r\n * A collection of shims that provide minimal functionality of the ES6 collections.\r\n *\r\n * These implementations are not meant to be used outside of the ResizeObserver\r\n * modules as they cover only a limited range of use cases.\r\n */\r\n/* eslint-disable require-jsdoc, valid-jsdoc */\r\nvar MapShim = (function () {\r\n if (typeof Map !== 'undefined') {\r\n return Map;\r\n }\r\n /**\r\n * Returns index in provided array that matches the specified key.\r\n *\r\n * @param {Array} arr\r\n * @param {*} key\r\n * @returns {number}\r\n */\r\n function getIndex(arr, key) {\r\n var result = -1;\r\n arr.some(function (entry, index) {\r\n if (entry[0] === key) {\r\n result = index;\r\n return true;\r\n }\r\n return false;\r\n });\r\n return result;\r\n }\r\n return /** @class */ (function () {\r\n function class_1() {\r\n this.__entries__ = [];\r\n }\r\n Object.defineProperty(class_1.prototype, \"size\", {\r\n /**\r\n * @returns {boolean}\r\n */\r\n get: function () {\r\n return this.__entries__.length;\r\n },\r\n enumerable: true,\r\n configurable: true\r\n });\r\n /**\r\n * @param {*} key\r\n * @returns {*}\r\n */\r\n class_1.prototype.get = function (key) {\r\n var index = getIndex(this.__entries__, key);\r\n var entry = this.__entries__[index];\r\n return entry && entry[1];\r\n };\r\n /**\r\n * @param {*} key\r\n * @param {*} value\r\n * @returns {void}\r\n */\r\n class_1.prototype.set = function (key, value) {\r\n var index = getIndex(this.__entries__, key);\r\n if (~index) {\r\n this.__entries__[index][1] = value;\r\n }\r\n else {\r\n this.__entries__.push([key, value]);\r\n }\r\n };\r\n /**\r\n * @param {*} key\r\n * @returns {void}\r\n */\r\n class_1.prototype.delete = function (key) {\r\n var entries = this.__entries__;\r\n var index = getIndex(entries, key);\r\n if (~index) {\r\n entries.splice(index, 1);\r\n }\r\n };\r\n /**\r\n * @param {*} key\r\n * @returns {void}\r\n */\r\n class_1.prototype.has = function (key) {\r\n return !!~getIndex(this.__entries__, key);\r\n };\r\n /**\r\n * @returns {void}\r\n */\r\n class_1.prototype.clear = function () {\r\n this.__entries__.splice(0);\r\n };\r\n /**\r\n * @param {Function} callback\r\n * @param {*} [ctx=null]\r\n * @returns {void}\r\n */\r\n class_1.prototype.forEach = function (callback, ctx) {\r\n if (ctx === void 0) { ctx = null; }\r\n for (var _i = 0, _a = this.__entries__; _i < _a.length; _i++) {\r\n var entry = _a[_i];\r\n callback.call(ctx, entry[1], entry[0]);\r\n }\r\n };\r\n return class_1;\r\n }());\r\n})();\n\n/**\r\n * Detects whether window and document objects are available in current environment.\r\n */\r\nvar isBrowser = typeof window !== 'undefined' && typeof document !== 'undefined' && window.document === document;\n\n// Returns global object of a current environment.\r\nvar global$1 = (function () {\r\n if (typeof global !== 'undefined' && global.Math === Math) {\r\n return global;\r\n }\r\n if (typeof self !== 'undefined' && self.Math === Math) {\r\n return self;\r\n }\r\n if (typeof window !== 'undefined' && window.Math === Math) {\r\n return window;\r\n }\r\n // eslint-disable-next-line no-new-func\r\n return Function('return this')();\r\n})();\n\n/**\r\n * A shim for the requestAnimationFrame which falls back to the setTimeout if\r\n * first one is not supported.\r\n *\r\n * @returns {number} Requests' identifier.\r\n */\r\nvar requestAnimationFrame$1 = (function () {\r\n if (typeof requestAnimationFrame === 'function') {\r\n // It's required to use a bounded function because IE sometimes throws\r\n // an \"Invalid calling object\" error if rAF is invoked without the global\r\n // object on the left hand side.\r\n return requestAnimationFrame.bind(global$1);\r\n }\r\n return function (callback) { return setTimeout(function () { return callback(Date.now()); }, 1000 / 60); };\r\n})();\n\n// Defines minimum timeout before adding a trailing call.\r\nvar trailingTimeout = 2;\r\n/**\r\n * Creates a wrapper function which ensures that provided callback will be\r\n * invoked only once during the specified delay period.\r\n *\r\n * @param {Function} callback - Function to be invoked after the delay period.\r\n * @param {number} delay - Delay after which to invoke callback.\r\n * @returns {Function}\r\n */\r\nfunction throttle (callback, delay) {\r\n var leadingCall = false, trailingCall = false, lastCallTime = 0;\r\n /**\r\n * Invokes the original callback function and schedules new invocation if\r\n * the \"proxy\" was called during current request.\r\n *\r\n * @returns {void}\r\n */\r\n function resolvePending() {\r\n if (leadingCall) {\r\n leadingCall = false;\r\n callback();\r\n }\r\n if (trailingCall) {\r\n proxy();\r\n }\r\n }\r\n /**\r\n * Callback invoked after the specified delay. It will further postpone\r\n * invocation of the original function delegating it to the\r\n * requestAnimationFrame.\r\n *\r\n * @returns {void}\r\n */\r\n function timeoutCallback() {\r\n requestAnimationFrame$1(resolvePending);\r\n }\r\n /**\r\n * Schedules invocation of the original function.\r\n *\r\n * @returns {void}\r\n */\r\n function proxy() {\r\n var timeStamp = Date.now();\r\n if (leadingCall) {\r\n // Reject immediately following calls.\r\n if (timeStamp - lastCallTime < trailingTimeout) {\r\n return;\r\n }\r\n // Schedule new call to be in invoked when the pending one is resolved.\r\n // This is important for \"transitions\" which never actually start\r\n // immediately so there is a chance that we might miss one if change\r\n // happens amids the pending invocation.\r\n trailingCall = true;\r\n }\r\n else {\r\n leadingCall = true;\r\n trailingCall = false;\r\n setTimeout(timeoutCallback, delay);\r\n }\r\n lastCallTime = timeStamp;\r\n }\r\n return proxy;\r\n}\n\n// Minimum delay before invoking the update of observers.\r\nvar REFRESH_DELAY = 20;\r\n// A list of substrings of CSS properties used to find transition events that\r\n// might affect dimensions of observed elements.\r\nvar transitionKeys = ['top', 'right', 'bottom', 'left', 'width', 'height', 'size', 'weight'];\r\n// Check if MutationObserver is available.\r\nvar mutationObserverSupported = typeof MutationObserver !== 'undefined';\r\n/**\r\n * Singleton controller class which handles updates of ResizeObserver instances.\r\n */\r\nvar ResizeObserverController = /** @class */ (function () {\r\n /**\r\n * Creates a new instance of ResizeObserverController.\r\n *\r\n * @private\r\n */\r\n function ResizeObserverController() {\r\n /**\r\n * Indicates whether DOM listeners have been added.\r\n *\r\n * @private {boolean}\r\n */\r\n this.connected_ = false;\r\n /**\r\n * Tells that controller has subscribed for Mutation Events.\r\n *\r\n * @private {boolean}\r\n */\r\n this.mutationEventsAdded_ = false;\r\n /**\r\n * Keeps reference to the instance of MutationObserver.\r\n *\r\n * @private {MutationObserver}\r\n */\r\n this.mutationsObserver_ = null;\r\n /**\r\n * A list of connected observers.\r\n *\r\n * @private {Array}\r\n */\r\n this.observers_ = [];\r\n this.onTransitionEnd_ = this.onTransitionEnd_.bind(this);\r\n this.refresh = throttle(this.refresh.bind(this), REFRESH_DELAY);\r\n }\r\n /**\r\n * Adds observer to observers list.\r\n *\r\n * @param {ResizeObserverSPI} observer - Observer to be added.\r\n * @returns {void}\r\n */\r\n ResizeObserverController.prototype.addObserver = function (observer) {\r\n if (!~this.observers_.indexOf(observer)) {\r\n this.observers_.push(observer);\r\n }\r\n // Add listeners if they haven't been added yet.\r\n if (!this.connected_) {\r\n this.connect_();\r\n }\r\n };\r\n /**\r\n * Removes observer from observers list.\r\n *\r\n * @param {ResizeObserverSPI} observer - Observer to be removed.\r\n * @returns {void}\r\n */\r\n ResizeObserverController.prototype.removeObserver = function (observer) {\r\n var observers = this.observers_;\r\n var index = observers.indexOf(observer);\r\n // Remove observer if it's present in registry.\r\n if (~index) {\r\n observers.splice(index, 1);\r\n }\r\n // Remove listeners if controller has no connected observers.\r\n if (!observers.length && this.connected_) {\r\n this.disconnect_();\r\n }\r\n };\r\n /**\r\n * Invokes the update of observers. It will continue running updates insofar\r\n * it detects changes.\r\n *\r\n * @returns {void}\r\n */\r\n ResizeObserverController.prototype.refresh = function () {\r\n var changesDetected = this.updateObservers_();\r\n // Continue running updates if changes have been detected as there might\r\n // be future ones caused by CSS transitions.\r\n if (changesDetected) {\r\n this.refresh();\r\n }\r\n };\r\n /**\r\n * Updates every observer from observers list and notifies them of queued\r\n * entries.\r\n *\r\n * @private\r\n * @returns {boolean} Returns \"true\" if any observer has detected changes in\r\n * dimensions of it's elements.\r\n */\r\n ResizeObserverController.prototype.updateObservers_ = function () {\r\n // Collect observers that have active observations.\r\n var activeObservers = this.observers_.filter(function (observer) {\r\n return observer.gatherActive(), observer.hasActive();\r\n });\r\n // Deliver notifications in a separate cycle in order to avoid any\r\n // collisions between observers, e.g. when multiple instances of\r\n // ResizeObserver are tracking the same element and the callback of one\r\n // of them changes content dimensions of the observed target. Sometimes\r\n // this may result in notifications being blocked for the rest of observers.\r\n activeObservers.forEach(function (observer) { return observer.broadcastActive(); });\r\n return activeObservers.length > 0;\r\n };\r\n /**\r\n * Initializes DOM listeners.\r\n *\r\n * @private\r\n * @returns {void}\r\n */\r\n ResizeObserverController.prototype.connect_ = function () {\r\n // Do nothing if running in a non-browser environment or if listeners\r\n // have been already added.\r\n if (!isBrowser || this.connected_) {\r\n return;\r\n }\r\n // Subscription to the \"Transitionend\" event is used as a workaround for\r\n // delayed transitions. This way it's possible to capture at least the\r\n // final state of an element.\r\n document.addEventListener('transitionend', this.onTransitionEnd_);\r\n window.addEventListener('resize', this.refresh);\r\n if (mutationObserverSupported) {\r\n this.mutationsObserver_ = new MutationObserver(this.refresh);\r\n this.mutationsObserver_.observe(document, {\r\n attributes: true,\r\n childList: true,\r\n characterData: true,\r\n subtree: true\r\n });\r\n }\r\n else {\r\n document.addEventListener('DOMSubtreeModified', this.refresh);\r\n this.mutationEventsAdded_ = true;\r\n }\r\n this.connected_ = true;\r\n };\r\n /**\r\n * Removes DOM listeners.\r\n *\r\n * @private\r\n * @returns {void}\r\n */\r\n ResizeObserverController.prototype.disconnect_ = function () {\r\n // Do nothing if running in a non-browser environment or if listeners\r\n // have been already removed.\r\n if (!isBrowser || !this.connected_) {\r\n return;\r\n }\r\n document.removeEventListener('transitionend', this.onTransitionEnd_);\r\n window.removeEventListener('resize', this.refresh);\r\n if (this.mutationsObserver_) {\r\n this.mutationsObserver_.disconnect();\r\n }\r\n if (this.mutationEventsAdded_) {\r\n document.removeEventListener('DOMSubtreeModified', this.refresh);\r\n }\r\n this.mutationsObserver_ = null;\r\n this.mutationEventsAdded_ = false;\r\n this.connected_ = false;\r\n };\r\n /**\r\n * \"Transitionend\" event handler.\r\n *\r\n * @private\r\n * @param {TransitionEvent} event\r\n * @returns {void}\r\n */\r\n ResizeObserverController.prototype.onTransitionEnd_ = function (_a) {\r\n var _b = _a.propertyName, propertyName = _b === void 0 ? '' : _b;\r\n // Detect whether transition may affect dimensions of an element.\r\n var isReflowProperty = transitionKeys.some(function (key) {\r\n return !!~propertyName.indexOf(key);\r\n });\r\n if (isReflowProperty) {\r\n this.refresh();\r\n }\r\n };\r\n /**\r\n * Returns instance of the ResizeObserverController.\r\n *\r\n * @returns {ResizeObserverController}\r\n */\r\n ResizeObserverController.getInstance = function () {\r\n if (!this.instance_) {\r\n this.instance_ = new ResizeObserverController();\r\n }\r\n return this.instance_;\r\n };\r\n /**\r\n * Holds reference to the controller's instance.\r\n *\r\n * @private {ResizeObserverController}\r\n */\r\n ResizeObserverController.instance_ = null;\r\n return ResizeObserverController;\r\n}());\n\n/**\r\n * Defines non-writable/enumerable properties of the provided target object.\r\n *\r\n * @param {Object} target - Object for which to define properties.\r\n * @param {Object} props - Properties to be defined.\r\n * @returns {Object} Target object.\r\n */\r\nvar defineConfigurable = (function (target, props) {\r\n for (var _i = 0, _a = Object.keys(props); _i < _a.length; _i++) {\r\n var key = _a[_i];\r\n Object.defineProperty(target, key, {\r\n value: props[key],\r\n enumerable: false,\r\n writable: false,\r\n configurable: true\r\n });\r\n }\r\n return target;\r\n});\n\n/**\r\n * Returns the global object associated with provided element.\r\n *\r\n * @param {Object} target\r\n * @returns {Object}\r\n */\r\nvar getWindowOf = (function (target) {\r\n // Assume that the element is an instance of Node, which means that it\r\n // has the \"ownerDocument\" property from which we can retrieve a\r\n // corresponding global object.\r\n var ownerGlobal = target && target.ownerDocument && target.ownerDocument.defaultView;\r\n // Return the local global object if it's not possible extract one from\r\n // provided element.\r\n return ownerGlobal || global$1;\r\n});\n\n// Placeholder of an empty content rectangle.\r\nvar emptyRect = createRectInit(0, 0, 0, 0);\r\n/**\r\n * Converts provided string to a number.\r\n *\r\n * @param {number|string} value\r\n * @returns {number}\r\n */\r\nfunction toFloat(value) {\r\n return parseFloat(value) || 0;\r\n}\r\n/**\r\n * Extracts borders size from provided styles.\r\n *\r\n * @param {CSSStyleDeclaration} styles\r\n * @param {...string} positions - Borders positions (top, right, ...)\r\n * @returns {number}\r\n */\r\nfunction getBordersSize(styles) {\r\n var positions = [];\r\n for (var _i = 1; _i < arguments.length; _i++) {\r\n positions[_i - 1] = arguments[_i];\r\n }\r\n return positions.reduce(function (size, position) {\r\n var value = styles['border-' + position + '-width'];\r\n return size + toFloat(value);\r\n }, 0);\r\n}\r\n/**\r\n * Extracts paddings sizes from provided styles.\r\n *\r\n * @param {CSSStyleDeclaration} styles\r\n * @returns {Object} Paddings box.\r\n */\r\nfunction getPaddings(styles) {\r\n var positions = ['top', 'right', 'bottom', 'left'];\r\n var paddings = {};\r\n for (var _i = 0, positions_1 = positions; _i < positions_1.length; _i++) {\r\n var position = positions_1[_i];\r\n var value = styles['padding-' + position];\r\n paddings[position] = toFloat(value);\r\n }\r\n return paddings;\r\n}\r\n/**\r\n * Calculates content rectangle of provided SVG element.\r\n *\r\n * @param {SVGGraphicsElement} target - Element content rectangle of which needs\r\n * to be calculated.\r\n * @returns {DOMRectInit}\r\n */\r\nfunction getSVGContentRect(target) {\r\n var bbox = target.getBBox();\r\n return createRectInit(0, 0, bbox.width, bbox.height);\r\n}\r\n/**\r\n * Calculates content rectangle of provided HTMLElement.\r\n *\r\n * @param {HTMLElement} target - Element for which to calculate the content rectangle.\r\n * @returns {DOMRectInit}\r\n */\r\nfunction getHTMLElementContentRect(target) {\r\n // Client width & height properties can't be\r\n // used exclusively as they provide rounded values.\r\n var clientWidth = target.clientWidth, clientHeight = target.clientHeight;\r\n // By this condition we can catch all non-replaced inline, hidden and\r\n // detached elements. Though elements with width & height properties less\r\n // than 0.5 will be discarded as well.\r\n //\r\n // Without it we would need to implement separate methods for each of\r\n // those cases and it's not possible to perform a precise and performance\r\n // effective test for hidden elements. E.g. even jQuery's ':visible' filter\r\n // gives wrong results for elements with width & height less than 0.5.\r\n if (!clientWidth && !clientHeight) {\r\n return emptyRect;\r\n }\r\n var styles = getWindowOf(target).getComputedStyle(target);\r\n var paddings = getPaddings(styles);\r\n var horizPad = paddings.left + paddings.right;\r\n var vertPad = paddings.top + paddings.bottom;\r\n // Computed styles of width & height are being used because they are the\r\n // only dimensions available to JS that contain non-rounded values. It could\r\n // be possible to utilize the getBoundingClientRect if only it's data wasn't\r\n // affected by CSS transformations let alone paddings, borders and scroll bars.\r\n var width = toFloat(styles.width), height = toFloat(styles.height);\r\n // Width & height include paddings and borders when the 'border-box' box\r\n // model is applied (except for IE).\r\n if (styles.boxSizing === 'border-box') {\r\n // Following conditions are required to handle Internet Explorer which\r\n // doesn't include paddings and borders to computed CSS dimensions.\r\n //\r\n // We can say that if CSS dimensions + paddings are equal to the \"client\"\r\n // properties then it's either IE, and thus we don't need to subtract\r\n // anything, or an element merely doesn't have paddings/borders styles.\r\n if (Math.round(width + horizPad) !== clientWidth) {\r\n width -= getBordersSize(styles, 'left', 'right') + horizPad;\r\n }\r\n if (Math.round(height + vertPad) !== clientHeight) {\r\n height -= getBordersSize(styles, 'top', 'bottom') + vertPad;\r\n }\r\n }\r\n // Following steps can't be applied to the document's root element as its\r\n // client[Width/Height] properties represent viewport area of the window.\r\n // Besides, it's as well not necessary as the itself neither has\r\n // rendered scroll bars nor it can be clipped.\r\n if (!isDocumentElement(target)) {\r\n // In some browsers (only in Firefox, actually) CSS width & height\r\n // include scroll bars size which can be removed at this step as scroll\r\n // bars are the only difference between rounded dimensions + paddings\r\n // and \"client\" properties, though that is not always true in Chrome.\r\n var vertScrollbar = Math.round(width + horizPad) - clientWidth;\r\n var horizScrollbar = Math.round(height + vertPad) - clientHeight;\r\n // Chrome has a rather weird rounding of \"client\" properties.\r\n // E.g. for an element with content width of 314.2px it sometimes gives\r\n // the client width of 315px and for the width of 314.7px it may give\r\n // 314px. And it doesn't happen all the time. So just ignore this delta\r\n // as a non-relevant.\r\n if (Math.abs(vertScrollbar) !== 1) {\r\n width -= vertScrollbar;\r\n }\r\n if (Math.abs(horizScrollbar) !== 1) {\r\n height -= horizScrollbar;\r\n }\r\n }\r\n return createRectInit(paddings.left, paddings.top, width, height);\r\n}\r\n/**\r\n * Checks whether provided element is an instance of the SVGGraphicsElement.\r\n *\r\n * @param {Element} target - Element to be checked.\r\n * @returns {boolean}\r\n */\r\nvar isSVGGraphicsElement = (function () {\r\n // Some browsers, namely IE and Edge, don't have the SVGGraphicsElement\r\n // interface.\r\n if (typeof SVGGraphicsElement !== 'undefined') {\r\n return function (target) { return target instanceof getWindowOf(target).SVGGraphicsElement; };\r\n }\r\n // If it's so, then check that element is at least an instance of the\r\n // SVGElement and that it has the \"getBBox\" method.\r\n // eslint-disable-next-line no-extra-parens\r\n return function (target) { return (target instanceof getWindowOf(target).SVGElement &&\r\n typeof target.getBBox === 'function'); };\r\n})();\r\n/**\r\n * Checks whether provided element is a document element ().\r\n *\r\n * @param {Element} target - Element to be checked.\r\n * @returns {boolean}\r\n */\r\nfunction isDocumentElement(target) {\r\n return target === getWindowOf(target).document.documentElement;\r\n}\r\n/**\r\n * Calculates an appropriate content rectangle for provided html or svg element.\r\n *\r\n * @param {Element} target - Element content rectangle of which needs to be calculated.\r\n * @returns {DOMRectInit}\r\n */\r\nfunction getContentRect(target) {\r\n if (!isBrowser) {\r\n return emptyRect;\r\n }\r\n if (isSVGGraphicsElement(target)) {\r\n return getSVGContentRect(target);\r\n }\r\n return getHTMLElementContentRect(target);\r\n}\r\n/**\r\n * Creates rectangle with an interface of the DOMRectReadOnly.\r\n * Spec: https://drafts.fxtf.org/geometry/#domrectreadonly\r\n *\r\n * @param {DOMRectInit} rectInit - Object with rectangle's x/y coordinates and dimensions.\r\n * @returns {DOMRectReadOnly}\r\n */\r\nfunction createReadOnlyRect(_a) {\r\n var x = _a.x, y = _a.y, width = _a.width, height = _a.height;\r\n // If DOMRectReadOnly is available use it as a prototype for the rectangle.\r\n var Constr = typeof DOMRectReadOnly !== 'undefined' ? DOMRectReadOnly : Object;\r\n var rect = Object.create(Constr.prototype);\r\n // Rectangle's properties are not writable and non-enumerable.\r\n defineConfigurable(rect, {\r\n x: x, y: y, width: width, height: height,\r\n top: y,\r\n right: x + width,\r\n bottom: height + y,\r\n left: x\r\n });\r\n return rect;\r\n}\r\n/**\r\n * Creates DOMRectInit object based on the provided dimensions and the x/y coordinates.\r\n * Spec: https://drafts.fxtf.org/geometry/#dictdef-domrectinit\r\n *\r\n * @param {number} x - X coordinate.\r\n * @param {number} y - Y coordinate.\r\n * @param {number} width - Rectangle's width.\r\n * @param {number} height - Rectangle's height.\r\n * @returns {DOMRectInit}\r\n */\r\nfunction createRectInit(x, y, width, height) {\r\n return { x: x, y: y, width: width, height: height };\r\n}\n\n/**\r\n * Class that is responsible for computations of the content rectangle of\r\n * provided DOM element and for keeping track of it's changes.\r\n */\r\nvar ResizeObservation = /** @class */ (function () {\r\n /**\r\n * Creates an instance of ResizeObservation.\r\n *\r\n * @param {Element} target - Element to be observed.\r\n */\r\n function ResizeObservation(target) {\r\n /**\r\n * Broadcasted width of content rectangle.\r\n *\r\n * @type {number}\r\n */\r\n this.broadcastWidth = 0;\r\n /**\r\n * Broadcasted height of content rectangle.\r\n *\r\n * @type {number}\r\n */\r\n this.broadcastHeight = 0;\r\n /**\r\n * Reference to the last observed content rectangle.\r\n *\r\n * @private {DOMRectInit}\r\n */\r\n this.contentRect_ = createRectInit(0, 0, 0, 0);\r\n this.target = target;\r\n }\r\n /**\r\n * Updates content rectangle and tells whether it's width or height properties\r\n * have changed since the last broadcast.\r\n *\r\n * @returns {boolean}\r\n */\r\n ResizeObservation.prototype.isActive = function () {\r\n var rect = getContentRect(this.target);\r\n this.contentRect_ = rect;\r\n return (rect.width !== this.broadcastWidth ||\r\n rect.height !== this.broadcastHeight);\r\n };\r\n /**\r\n * Updates 'broadcastWidth' and 'broadcastHeight' properties with a data\r\n * from the corresponding properties of the last observed content rectangle.\r\n *\r\n * @returns {DOMRectInit} Last observed content rectangle.\r\n */\r\n ResizeObservation.prototype.broadcastRect = function () {\r\n var rect = this.contentRect_;\r\n this.broadcastWidth = rect.width;\r\n this.broadcastHeight = rect.height;\r\n return rect;\r\n };\r\n return ResizeObservation;\r\n}());\n\nvar ResizeObserverEntry = /** @class */ (function () {\r\n /**\r\n * Creates an instance of ResizeObserverEntry.\r\n *\r\n * @param {Element} target - Element that is being observed.\r\n * @param {DOMRectInit} rectInit - Data of the element's content rectangle.\r\n */\r\n function ResizeObserverEntry(target, rectInit) {\r\n var contentRect = createReadOnlyRect(rectInit);\r\n // According to the specification following properties are not writable\r\n // and are also not enumerable in the native implementation.\r\n //\r\n // Property accessors are not being used as they'd require to define a\r\n // private WeakMap storage which may cause memory leaks in browsers that\r\n // don't support this type of collections.\r\n defineConfigurable(this, { target: target, contentRect: contentRect });\r\n }\r\n return ResizeObserverEntry;\r\n}());\n\nvar ResizeObserverSPI = /** @class */ (function () {\r\n /**\r\n * Creates a new instance of ResizeObserver.\r\n *\r\n * @param {ResizeObserverCallback} callback - Callback function that is invoked\r\n * when one of the observed elements changes it's content dimensions.\r\n * @param {ResizeObserverController} controller - Controller instance which\r\n * is responsible for the updates of observer.\r\n * @param {ResizeObserver} callbackCtx - Reference to the public\r\n * ResizeObserver instance which will be passed to callback function.\r\n */\r\n function ResizeObserverSPI(callback, controller, callbackCtx) {\r\n /**\r\n * Collection of resize observations that have detected changes in dimensions\r\n * of elements.\r\n *\r\n * @private {Array}\r\n */\r\n this.activeObservations_ = [];\r\n /**\r\n * Registry of the ResizeObservation instances.\r\n *\r\n * @private {Map}\r\n */\r\n this.observations_ = new MapShim();\r\n if (typeof callback !== 'function') {\r\n throw new TypeError('The callback provided as parameter 1 is not a function.');\r\n }\r\n this.callback_ = callback;\r\n this.controller_ = controller;\r\n this.callbackCtx_ = callbackCtx;\r\n }\r\n /**\r\n * Starts observing provided element.\r\n *\r\n * @param {Element} target - Element to be observed.\r\n * @returns {void}\r\n */\r\n ResizeObserverSPI.prototype.observe = function (target) {\r\n if (!arguments.length) {\r\n throw new TypeError('1 argument required, but only 0 present.');\r\n }\r\n // Do nothing if current environment doesn't have the Element interface.\r\n if (typeof Element === 'undefined' || !(Element instanceof Object)) {\r\n return;\r\n }\r\n if (!(target instanceof getWindowOf(target).Element)) {\r\n throw new TypeError('parameter 1 is not of type \"Element\".');\r\n }\r\n var observations = this.observations_;\r\n // Do nothing if element is already being observed.\r\n if (observations.has(target)) {\r\n return;\r\n }\r\n observations.set(target, new ResizeObservation(target));\r\n this.controller_.addObserver(this);\r\n // Force the update of observations.\r\n this.controller_.refresh();\r\n };\r\n /**\r\n * Stops observing provided element.\r\n *\r\n * @param {Element} target - Element to stop observing.\r\n * @returns {void}\r\n */\r\n ResizeObserverSPI.prototype.unobserve = function (target) {\r\n if (!arguments.length) {\r\n throw new TypeError('1 argument required, but only 0 present.');\r\n }\r\n // Do nothing if current environment doesn't have the Element interface.\r\n if (typeof Element === 'undefined' || !(Element instanceof Object)) {\r\n return;\r\n }\r\n if (!(target instanceof getWindowOf(target).Element)) {\r\n throw new TypeError('parameter 1 is not of type \"Element\".');\r\n }\r\n var observations = this.observations_;\r\n // Do nothing if element is not being observed.\r\n if (!observations.has(target)) {\r\n return;\r\n }\r\n observations.delete(target);\r\n if (!observations.size) {\r\n this.controller_.removeObserver(this);\r\n }\r\n };\r\n /**\r\n * Stops observing all elements.\r\n *\r\n * @returns {void}\r\n */\r\n ResizeObserverSPI.prototype.disconnect = function () {\r\n this.clearActive();\r\n this.observations_.clear();\r\n this.controller_.removeObserver(this);\r\n };\r\n /**\r\n * Collects observation instances the associated element of which has changed\r\n * it's content rectangle.\r\n *\r\n * @returns {void}\r\n */\r\n ResizeObserverSPI.prototype.gatherActive = function () {\r\n var _this = this;\r\n this.clearActive();\r\n this.observations_.forEach(function (observation) {\r\n if (observation.isActive()) {\r\n _this.activeObservations_.push(observation);\r\n }\r\n });\r\n };\r\n /**\r\n * Invokes initial callback function with a list of ResizeObserverEntry\r\n * instances collected from active resize observations.\r\n *\r\n * @returns {void}\r\n */\r\n ResizeObserverSPI.prototype.broadcastActive = function () {\r\n // Do nothing if observer doesn't have active observations.\r\n if (!this.hasActive()) {\r\n return;\r\n }\r\n var ctx = this.callbackCtx_;\r\n // Create ResizeObserverEntry instance for every active observation.\r\n var entries = this.activeObservations_.map(function (observation) {\r\n return new ResizeObserverEntry(observation.target, observation.broadcastRect());\r\n });\r\n this.callback_.call(ctx, entries, ctx);\r\n this.clearActive();\r\n };\r\n /**\r\n * Clears the collection of active observations.\r\n *\r\n * @returns {void}\r\n */\r\n ResizeObserverSPI.prototype.clearActive = function () {\r\n this.activeObservations_.splice(0);\r\n };\r\n /**\r\n * Tells whether observer has active observations.\r\n *\r\n * @returns {boolean}\r\n */\r\n ResizeObserverSPI.prototype.hasActive = function () {\r\n return this.activeObservations_.length > 0;\r\n };\r\n return ResizeObserverSPI;\r\n}());\n\n// Registry of internal observers. If WeakMap is not available use current shim\r\n// for the Map collection as it has all required methods and because WeakMap\r\n// can't be fully polyfilled anyway.\r\nvar observers = typeof WeakMap !== 'undefined' ? new WeakMap() : new MapShim();\r\n/**\r\n * ResizeObserver API. Encapsulates the ResizeObserver SPI implementation\r\n * exposing only those methods and properties that are defined in the spec.\r\n */\r\nvar ResizeObserver = /** @class */ (function () {\r\n /**\r\n * Creates a new instance of ResizeObserver.\r\n *\r\n * @param {ResizeObserverCallback} callback - Callback that is invoked when\r\n * dimensions of the observed elements change.\r\n */\r\n function ResizeObserver(callback) {\r\n if (!(this instanceof ResizeObserver)) {\r\n throw new TypeError('Cannot call a class as a function.');\r\n }\r\n if (!arguments.length) {\r\n throw new TypeError('1 argument required, but only 0 present.');\r\n }\r\n var controller = ResizeObserverController.getInstance();\r\n var observer = new ResizeObserverSPI(callback, controller, this);\r\n observers.set(this, observer);\r\n }\r\n return ResizeObserver;\r\n}());\r\n// Expose public methods of ResizeObserver.\r\n[\r\n 'observe',\r\n 'unobserve',\r\n 'disconnect'\r\n].forEach(function (method) {\r\n ResizeObserver.prototype[method] = function () {\r\n var _a;\r\n return (_a = observers.get(this))[method].apply(_a, arguments);\r\n };\r\n});\n\nvar index = (function () {\r\n // Export existing implementation if available.\r\n if (typeof global$1.ResizeObserver !== 'undefined') {\r\n return global$1.ResizeObserver;\r\n }\r\n return ResizeObserver;\r\n})();\n\nexport default index;\n","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _CloseOutlined = _interopRequireDefault(require('./lib/icons/CloseOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _CloseOutlined;\n exports.default = _default;\n module.exports = _default;","/**\n * Webpack has bug for import loop, which is not the same behavior as ES module.\n * When util.js imports the TreeNode for tree generate will cause treeContextTypes be empty.\n */\nimport * as React from 'react';\nexport var TreeContext = React.createContext(null);","var attributes = \"accept acceptCharset accessKey action allowFullScreen allowTransparency\\n alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge\\n charSet checked classID className colSpan cols content contentEditable contextMenu\\n controls coords crossOrigin data dateTime default defer dir disabled download draggable\\n encType form formAction formEncType formMethod formNoValidate formTarget frameBorder\\n headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity\\n is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media\\n mediaGroup method min minLength multiple muted name noValidate nonce open\\n optimum pattern placeholder poster preload radioGroup readOnly rel required\\n reversed role rowSpan rows sandbox scope scoped scrolling seamless selected\\n shape size sizes span spellCheck src srcDoc srcLang srcSet start step style\\n summary tabIndex target title type useMap value width wmode wrap\";\nvar eventsName = \"onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown\\n onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick\\n onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown\\n onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel\\n onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough\\n onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata\\n onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError\";\nvar propList = \"\".concat(attributes, \" \").concat(eventsName).split(/[\\s\\n]+/);\n/* eslint-enable max-len */\n\nvar ariaPrefix = 'aria-';\nvar dataPrefix = 'data-';\n\nfunction match(key, prefix) {\n return key.indexOf(prefix) === 0;\n}\n\nexport default function pickAttrs(props) {\n var ariaOnly = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n var attrs = {};\n Object.keys(props).forEach(function (key) {\n if (match(key, ariaPrefix)) {\n attrs[key] = props[key];\n } else if (!ariaOnly && (propList.includes(key) || match(key, dataPrefix))) {\n attrs[key] = props[key];\n }\n });\n return attrs;\n}","/* istanbul ignore next */\n\n/**\n * This is a syntactic sugar for `columns` prop.\n * So HOC will not work on this.\n */\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nfunction ColumnGroup(_) {\n return null;\n}\n\nexport default ColumnGroup;","/* istanbul ignore next */\n\n/**\n * This is a syntactic sugar for `columns` prop.\n * So HOC will not work on this.\n */\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nfunction Column(_) {\n return null;\n}\n\nexport default Column;","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nvar INTERNAL_KEY_PREFIX = 'RC_TABLE_KEY';\n\nfunction toArray(arr) {\n if (arr === undefined || arr === null) {\n return [];\n }\n\n return Array.isArray(arr) ? arr : [arr];\n}\n\nexport function getPathValue(record, path) {\n // Skip if path is empty\n if (!path && typeof path !== 'number') {\n return record;\n }\n\n var pathList = toArray(path);\n var current = record;\n\n for (var i = 0; i < pathList.length; i += 1) {\n if (!current) {\n return null;\n }\n\n var prop = pathList[i];\n current = current[prop];\n }\n\n return current;\n}\nexport function getColumnsKey(columns) {\n var columnKeys = [];\n var keys = {};\n columns.forEach(function (column) {\n var _ref = column || {},\n key = _ref.key,\n dataIndex = _ref.dataIndex;\n\n var mergedKey = key || toArray(dataIndex).join('-') || INTERNAL_KEY_PREFIX;\n\n while (keys[mergedKey]) {\n mergedKey = \"\".concat(mergedKey, \"_next\");\n }\n\n keys[mergedKey] = true;\n columnKeys.push(mergedKey);\n });\n return columnKeys;\n}\nexport function mergeObject() {\n var merged = {};\n /* eslint-disable no-param-reassign */\n\n function fillProps(obj, clone) {\n if (clone) {\n Object.keys(clone).forEach(function (key) {\n var value = clone[key];\n\n if (value && _typeof(value) === 'object') {\n obj[key] = obj[key] || {};\n fillProps(obj[key], value);\n } else {\n obj[key] = value;\n }\n });\n }\n }\n /* eslint-enable */\n\n\n for (var _len = arguments.length, objects = new Array(_len), _key = 0; _key < _len; _key++) {\n objects[_key] = arguments[_key];\n }\n\n objects.forEach(function (clone) {\n fillProps(merged, clone);\n });\n return merged;\n}\nexport function validateValue(val) {\n return val !== null && val !== undefined;\n}","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { supportRef } from \"rc-util/es/ref\";\nimport { getPathValue } from '../utils/valueUtil';\n\nfunction isRenderCell(data) {\n return data && _typeof(data) === 'object' && !Array.isArray(data) && !React.isValidElement(data);\n}\n\nfunction isRefComponent(component) {\n // String tag component also support ref\n if (typeof component === 'string') {\n return true;\n }\n\n return supportRef(component);\n}\n\nfunction Cell(_ref, ref) {\n var _classNames;\n\n var prefixCls = _ref.prefixCls,\n className = _ref.className,\n record = _ref.record,\n index = _ref.index,\n dataIndex = _ref.dataIndex,\n render = _ref.render,\n children = _ref.children,\n _ref$component = _ref.component,\n Component = _ref$component === void 0 ? 'td' : _ref$component,\n colSpan = _ref.colSpan,\n rowSpan = _ref.rowSpan,\n fixLeft = _ref.fixLeft,\n fixRight = _ref.fixRight,\n firstFixLeft = _ref.firstFixLeft,\n lastFixLeft = _ref.lastFixLeft,\n firstFixRight = _ref.firstFixRight,\n lastFixRight = _ref.lastFixRight,\n appendNode = _ref.appendNode,\n _ref$additionalProps = _ref.additionalProps,\n additionalProps = _ref$additionalProps === void 0 ? {} : _ref$additionalProps,\n ellipsis = _ref.ellipsis,\n align = _ref.align,\n rowType = _ref.rowType,\n isSticky = _ref.isSticky;\n var cellPrefixCls = \"\".concat(prefixCls, \"-cell\"); // ==================== Child Node ====================\n\n var cellProps;\n var childNode;\n\n if (children) {\n childNode = children;\n } else {\n var value = getPathValue(record, dataIndex); // Customize render node\n\n childNode = value;\n\n if (render) {\n var renderData = render(value, record, index);\n\n if (isRenderCell(renderData)) {\n childNode = renderData.children;\n cellProps = renderData.props;\n } else {\n childNode = renderData;\n }\n }\n } // Not crash if final `childNode` is not validate ReactNode\n\n\n if (_typeof(childNode) === 'object' && !Array.isArray(childNode) && !React.isValidElement(childNode)) {\n childNode = null;\n }\n\n if (ellipsis && (lastFixLeft || firstFixRight)) {\n childNode = React.createElement(\"span\", {\n className: \"\".concat(cellPrefixCls, \"-content\")\n }, childNode);\n }\n\n var _ref2 = cellProps || {},\n cellColSpan = _ref2.colSpan,\n cellRowSpan = _ref2.rowSpan,\n cellStyle = _ref2.style,\n cellClassName = _ref2.className,\n restCellProps = _objectWithoutProperties(_ref2, [\"colSpan\", \"rowSpan\", \"style\", \"className\"]);\n\n var mergedColSpan = cellColSpan !== undefined ? cellColSpan : colSpan;\n var mergedRowSpan = cellRowSpan !== undefined ? cellRowSpan : rowSpan;\n\n if (mergedColSpan === 0 || mergedRowSpan === 0) {\n return null;\n } // ====================== Fixed =======================\n\n\n var fixedStyle = {};\n var isFixLeft = typeof fixLeft === 'number';\n var isFixRight = typeof fixRight === 'number';\n\n if (isFixLeft) {\n fixedStyle.position = 'sticky';\n fixedStyle.left = fixLeft;\n }\n\n if (isFixRight) {\n fixedStyle.position = 'sticky';\n fixedStyle.right = fixRight;\n } // ====================== Align =======================\n\n\n var alignStyle = {};\n\n if (align) {\n alignStyle.textAlign = align;\n } // ====================== Render ======================\n\n\n var title;\n var ellipsisConfig = ellipsis === true ? {\n showTitle: true\n } : ellipsis;\n\n if (ellipsisConfig && (ellipsisConfig.showTitle || rowType === 'header')) {\n if (typeof childNode === 'string' || typeof childNode === 'number') {\n title = childNode.toString();\n } else if (React.isValidElement(childNode) && typeof childNode.props.children === 'string') {\n title = childNode.props.children;\n }\n }\n\n var componentProps = _objectSpread(_objectSpread(_objectSpread({\n title: title\n }, restCellProps), additionalProps), {}, {\n colSpan: mergedColSpan && mergedColSpan !== 1 ? mergedColSpan : null,\n rowSpan: mergedRowSpan && mergedRowSpan !== 1 ? mergedRowSpan : null,\n className: classNames(cellPrefixCls, className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(cellPrefixCls, \"-fix-left\"), isFixLeft), _defineProperty(_classNames, \"\".concat(cellPrefixCls, \"-fix-left-first\"), firstFixLeft), _defineProperty(_classNames, \"\".concat(cellPrefixCls, \"-fix-left-last\"), lastFixLeft), _defineProperty(_classNames, \"\".concat(cellPrefixCls, \"-fix-right\"), isFixRight), _defineProperty(_classNames, \"\".concat(cellPrefixCls, \"-fix-right-first\"), firstFixRight), _defineProperty(_classNames, \"\".concat(cellPrefixCls, \"-fix-right-last\"), lastFixRight), _defineProperty(_classNames, \"\".concat(cellPrefixCls, \"-ellipsis\"), ellipsis), _defineProperty(_classNames, \"\".concat(cellPrefixCls, \"-with-append\"), appendNode), _defineProperty(_classNames, \"\".concat(cellPrefixCls, \"-fix-sticky\"), (isFixLeft || isFixRight) && isSticky), _classNames), additionalProps.className, cellClassName),\n style: _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, additionalProps.style), alignStyle), fixedStyle), cellStyle),\n ref: isRefComponent(Component) ? ref : null\n });\n\n return React.createElement(Component, Object.assign({}, componentProps), appendNode, childNode);\n}\n\nvar RefCell = React.forwardRef(Cell);\nRefCell.displayName = 'Cell';\nvar MemoCell = React.memo(RefCell, function (prev, next) {\n if (next.shouldCellUpdate) {\n return !next.shouldCellUpdate(next.record, prev.record);\n }\n\n return false;\n});\nexport default MemoCell;","import * as React from 'react';\nvar TableContext = React.createContext(null);\nexport default TableContext;","export function getCellFixedInfo(colStart, colEnd, columns, stickyOffsets, direction) {\n var startColumn = columns[colStart] || {};\n var endColumn = columns[colEnd] || {};\n var fixLeft;\n var fixRight;\n\n if (startColumn.fixed === 'left') {\n fixLeft = stickyOffsets.left[colStart];\n } else if (endColumn.fixed === 'right') {\n fixRight = stickyOffsets.right[colEnd];\n }\n\n var lastFixLeft = false;\n var firstFixRight = false;\n var lastFixRight = false;\n var firstFixLeft = false;\n var nextColumn = columns[colEnd + 1];\n var prevColumn = columns[colStart - 1];\n\n if (direction === 'rtl') {\n if (fixLeft !== undefined) {\n var prevFixLeft = prevColumn && prevColumn.fixed === 'left';\n firstFixLeft = !prevFixLeft;\n } else if (fixRight !== undefined) {\n var nextFixRight = nextColumn && nextColumn.fixed === 'right';\n lastFixRight = !nextFixRight;\n }\n } else if (fixLeft !== undefined) {\n var nextFixLeft = nextColumn && nextColumn.fixed === 'left';\n lastFixLeft = !nextFixLeft;\n } else if (fixRight !== undefined) {\n var prevFixRight = prevColumn && prevColumn.fixed === 'right';\n firstFixRight = !prevFixRight;\n }\n\n return {\n fixLeft: fixLeft,\n fixRight: fixRight,\n lastFixLeft: lastFixLeft,\n firstFixRight: firstFixRight,\n lastFixRight: lastFixRight,\n firstFixLeft: firstFixLeft,\n isSticky: stickyOffsets.isSticky\n };\n}","import * as React from 'react';\nimport Cell from '../Cell';\nimport TableContext from '../context/TableContext';\nimport { getCellFixedInfo } from '../utils/fixUtil';\nimport { getColumnsKey } from '../utils/valueUtil';\n\nfunction HeaderRow(_ref) {\n var cells = _ref.cells,\n stickyOffsets = _ref.stickyOffsets,\n flattenColumns = _ref.flattenColumns,\n RowComponent = _ref.rowComponent,\n CellComponent = _ref.cellComponent,\n onHeaderRow = _ref.onHeaderRow,\n index = _ref.index;\n\n var _React$useContext = React.useContext(TableContext),\n prefixCls = _React$useContext.prefixCls,\n direction = _React$useContext.direction;\n\n var rowProps;\n\n if (onHeaderRow) {\n rowProps = onHeaderRow(cells.map(function (cell) {\n return cell.column;\n }), index);\n }\n\n var columnsKey = getColumnsKey(cells.map(function (cell) {\n return cell.column;\n }));\n return React.createElement(RowComponent, Object.assign({}, rowProps), cells.map(function (cell, cellIndex) {\n var column = cell.column;\n var fixedInfo = getCellFixedInfo(cell.colStart, cell.colEnd, flattenColumns, stickyOffsets, direction);\n var additionalProps;\n\n if (column && column.onHeaderCell) {\n additionalProps = cell.column.onHeaderCell(column);\n }\n\n return React.createElement(Cell, Object.assign({}, cell, {\n ellipsis: column.ellipsis,\n align: column.align,\n component: CellComponent,\n prefixCls: prefixCls,\n key: columnsKey[cellIndex]\n }, fixedInfo, {\n additionalProps: additionalProps,\n rowType: \"header\"\n }));\n }));\n}\n\nHeaderRow.displayName = 'HeaderRow';\nexport default HeaderRow;","import * as React from 'react';\nimport HeaderRow from './HeaderRow';\nimport TableContext from '../context/TableContext';\n\nfunction parseHeaderRows(rootColumns) {\n var rows = [];\n\n function fillRowCells(columns, colIndex) {\n var rowIndex = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;\n // Init rows\n rows[rowIndex] = rows[rowIndex] || [];\n var currentColIndex = colIndex;\n var colSpans = columns.filter(Boolean).map(function (column) {\n var cell = {\n key: column.key,\n className: column.className || '',\n children: column.title,\n column: column,\n colStart: currentColIndex\n };\n var colSpan = 1;\n var subColumns = column.children;\n\n if (subColumns && subColumns.length > 0) {\n colSpan = fillRowCells(subColumns, currentColIndex, rowIndex + 1).reduce(function (total, count) {\n return total + count;\n }, 0);\n cell.hasSubColumns = true;\n }\n\n if ('colSpan' in column) {\n colSpan = column.colSpan;\n }\n\n if ('rowSpan' in column) {\n cell.rowSpan = column.rowSpan;\n }\n\n cell.colSpan = colSpan;\n cell.colEnd = cell.colStart + colSpan - 1;\n rows[rowIndex].push(cell);\n currentColIndex += colSpan;\n return colSpan;\n });\n return colSpans;\n } // Generate `rows` cell data\n\n\n fillRowCells(rootColumns, 0); // Handle `rowSpan`\n\n var rowCount = rows.length;\n\n var _loop = function _loop(rowIndex) {\n rows[rowIndex].forEach(function (cell) {\n if (!('rowSpan' in cell) && !cell.hasSubColumns) {\n // eslint-disable-next-line no-param-reassign\n cell.rowSpan = rowCount - rowIndex;\n }\n });\n };\n\n for (var rowIndex = 0; rowIndex < rowCount; rowIndex += 1) {\n _loop(rowIndex);\n }\n\n return rows;\n}\n\nfunction Header(_ref) {\n var stickyOffsets = _ref.stickyOffsets,\n columns = _ref.columns,\n flattenColumns = _ref.flattenColumns,\n onHeaderRow = _ref.onHeaderRow;\n\n var _React$useContext = React.useContext(TableContext),\n prefixCls = _React$useContext.prefixCls,\n getComponent = _React$useContext.getComponent;\n\n var rows = React.useMemo(function () {\n return parseHeaderRows(columns);\n }, [columns]);\n var WrapperComponent = getComponent(['header', 'wrapper'], 'thead');\n var trComponent = getComponent(['header', 'row'], 'tr');\n var thComponent = getComponent(['header', 'cell'], 'th');\n return React.createElement(WrapperComponent, {\n className: \"\".concat(prefixCls, \"-thead\")\n }, rows.map(function (row, rowIndex) {\n var rowNode = React.createElement(HeaderRow, {\n key: rowIndex,\n flattenColumns: flattenColumns,\n cells: row,\n stickyOffsets: stickyOffsets,\n rowComponent: trComponent,\n cellComponent: thComponent,\n onHeaderRow: onHeaderRow,\n index: rowIndex\n });\n return rowNode;\n }));\n}\n\nexport default Header;","import * as React from 'react';\nimport { INTERNAL_COL_DEFINE } from './utils/legacyUtil';\n\nfunction ColGroup(_ref) {\n var colWidths = _ref.colWidths,\n columns = _ref.columns,\n columCount = _ref.columCount;\n var cols = [];\n var len = columCount || columns.length; // Only insert col with width & additional props\n // Skip if rest col do not have any useful info\n\n var mustInsert = false;\n\n for (var i = len - 1; i >= 0; i -= 1) {\n var width = colWidths[i];\n var column = columns && columns[i];\n var additionalProps = column && column[INTERNAL_COL_DEFINE];\n\n if (width || additionalProps || mustInsert) {\n cols.unshift(React.createElement(\"col\", Object.assign({\n key: i,\n style: {\n width: width,\n minWidth: width\n }\n }, additionalProps)));\n mustInsert = true;\n }\n }\n\n return React.createElement(\"colgroup\", null, cols);\n}\n\nexport default ColGroup;","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport { useMemo } from 'react';\nimport Header from './Header';\nimport ColGroup from '../ColGroup';\nimport TableContext from '../context/TableContext';\n\nfunction useColumnWidth(colWidths, columCount) {\n return useMemo(function () {\n var cloneColumns = [];\n\n for (var i = 0; i < columCount; i += 1) {\n var val = colWidths[i];\n\n if (val !== undefined) {\n cloneColumns[i] = val;\n } else {\n return null;\n }\n }\n\n return cloneColumns;\n }, [colWidths.join('_'), columCount]);\n}\n\nfunction FixedHeader(_ref) {\n var noData = _ref.noData,\n columns = _ref.columns,\n flattenColumns = _ref.flattenColumns,\n colWidths = _ref.colWidths,\n columCount = _ref.columCount,\n stickyOffsets = _ref.stickyOffsets,\n direction = _ref.direction,\n fixHeader = _ref.fixHeader,\n props = _objectWithoutProperties(_ref, [\"noData\", \"columns\", \"flattenColumns\", \"colWidths\", \"columCount\", \"stickyOffsets\", \"direction\", \"fixHeader\"]);\n\n var _React$useContext = React.useContext(TableContext),\n prefixCls = _React$useContext.prefixCls,\n scrollbarSize = _React$useContext.scrollbarSize,\n isSticky = _React$useContext.isSticky;\n\n var combinationScrollBarSize = isSticky && !fixHeader ? 0 : scrollbarSize; // Add scrollbar column\n\n var lastColumn = flattenColumns[flattenColumns.length - 1];\n var ScrollBarColumn = {\n fixed: lastColumn ? lastColumn.fixed : null,\n onHeaderCell: function onHeaderCell() {\n return {\n className: \"\".concat(prefixCls, \"-cell-scrollbar\")\n };\n }\n };\n var columnsWithScrollbar = useMemo(function () {\n return combinationScrollBarSize ? [].concat(_toConsumableArray(columns), [ScrollBarColumn]) : columns;\n }, [combinationScrollBarSize, columns]);\n var flattenColumnsWithScrollbar = useMemo(function () {\n return combinationScrollBarSize ? [].concat(_toConsumableArray(flattenColumns), [ScrollBarColumn]) : flattenColumns;\n }, [combinationScrollBarSize, flattenColumns]); // Calculate the sticky offsets\n\n var headerStickyOffsets = useMemo(function () {\n var right = stickyOffsets.right,\n left = stickyOffsets.left;\n return _objectSpread(_objectSpread({}, stickyOffsets), {}, {\n left: direction === 'rtl' ? [].concat(_toConsumableArray(left.map(function (width) {\n return width + combinationScrollBarSize;\n })), [0]) : left,\n right: direction === 'rtl' ? right : [].concat(_toConsumableArray(right.map(function (width) {\n return width + combinationScrollBarSize;\n })), [0]),\n isSticky: isSticky\n });\n }, [combinationScrollBarSize, stickyOffsets, isSticky]);\n var mergedColumnWidth = useColumnWidth(colWidths, columCount);\n return React.createElement(\"table\", {\n style: {\n tableLayout: 'fixed',\n visibility: noData || mergedColumnWidth ? null : 'hidden'\n }\n }, React.createElement(ColGroup, {\n colWidths: mergedColumnWidth ? [].concat(_toConsumableArray(mergedColumnWidth), [combinationScrollBarSize]) : [],\n columCount: columCount + 1,\n columns: flattenColumnsWithScrollbar\n }), React.createElement(Header, Object.assign({}, props, {\n stickyOffsets: headerStickyOffsets,\n columns: columnsWithScrollbar,\n flattenColumns: flattenColumnsWithScrollbar\n })));\n}\n\nexport default FixedHeader;","import * as React from 'react';\nvar BodyContext = React.createContext(null);\nexport default BodyContext;","import * as React from 'react';\nimport Cell from '../Cell';\nimport TableContext from '../context/TableContext';\n\nfunction ExpandedRow(_ref) {\n var prefixCls = _ref.prefixCls,\n children = _ref.children,\n Component = _ref.component,\n cellComponent = _ref.cellComponent,\n fixHeader = _ref.fixHeader,\n fixColumn = _ref.fixColumn,\n horizonScroll = _ref.horizonScroll,\n className = _ref.className,\n expanded = _ref.expanded,\n componentWidth = _ref.componentWidth,\n colSpan = _ref.colSpan;\n\n var _React$useContext = React.useContext(TableContext),\n scrollbarSize = _React$useContext.scrollbarSize; // Cache render node\n\n\n return React.useMemo(function () {\n var contentNode = children;\n\n if (fixColumn) {\n contentNode = React.createElement(\"div\", {\n style: {\n width: componentWidth - (fixHeader ? scrollbarSize : 0),\n position: 'sticky',\n left: 0,\n overflow: 'hidden'\n },\n className: \"\".concat(prefixCls, \"-expanded-row-fixed\")\n }, contentNode);\n }\n\n return React.createElement(Component, {\n className: className,\n style: {\n display: expanded ? null : 'none'\n }\n }, React.createElement(Cell, {\n component: cellComponent,\n prefixCls: prefixCls,\n colSpan: colSpan\n }, contentNode));\n }, [children, Component, fixHeader, horizonScroll, className, expanded, componentWidth, colSpan, scrollbarSize]);\n}\n\nexport default ExpandedRow;","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport Cell from '../Cell';\nimport TableContext from '../context/TableContext';\nimport BodyContext from '../context/BodyContext';\nimport { getColumnsKey } from '../utils/valueUtil';\nimport ExpandedRow from './ExpandedRow';\n\nfunction BodyRow(props) {\n var className = props.className,\n style = props.style,\n record = props.record,\n index = props.index,\n rowKey = props.rowKey,\n getRowKey = props.getRowKey,\n rowExpandable = props.rowExpandable,\n expandedKeys = props.expandedKeys,\n onRow = props.onRow,\n _props$indent = props.indent,\n indent = _props$indent === void 0 ? 0 : _props$indent,\n RowComponent = props.rowComponent,\n cellComponent = props.cellComponent,\n childrenColumnName = props.childrenColumnName;\n\n var _React$useContext = React.useContext(TableContext),\n prefixCls = _React$useContext.prefixCls,\n fixedInfoList = _React$useContext.fixedInfoList;\n\n var _React$useContext2 = React.useContext(BodyContext),\n fixHeader = _React$useContext2.fixHeader,\n fixColumn = _React$useContext2.fixColumn,\n horizonScroll = _React$useContext2.horizonScroll,\n componentWidth = _React$useContext2.componentWidth,\n flattenColumns = _React$useContext2.flattenColumns,\n expandableType = _React$useContext2.expandableType,\n expandRowByClick = _React$useContext2.expandRowByClick,\n onTriggerExpand = _React$useContext2.onTriggerExpand,\n rowClassName = _React$useContext2.rowClassName,\n expandedRowClassName = _React$useContext2.expandedRowClassName,\n indentSize = _React$useContext2.indentSize,\n expandIcon = _React$useContext2.expandIcon,\n expandedRowRender = _React$useContext2.expandedRowRender,\n expandIconColumnIndex = _React$useContext2.expandIconColumnIndex;\n\n var _React$useState = React.useState(false),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n expandRended = _React$useState2[0],\n setExpandRended = _React$useState2[1];\n\n var expanded = expandedKeys && expandedKeys.has(props.recordKey);\n React.useEffect(function () {\n if (expanded) {\n setExpandRended(true);\n }\n }, [expanded]);\n var rowSupportExpand = expandableType === 'row' && (!rowExpandable || rowExpandable(record)); // Only when row is not expandable and `children` exist in record\n\n var nestExpandable = expandableType === 'nest';\n var hasNestChildren = childrenColumnName && record && record[childrenColumnName];\n var mergedExpandable = rowSupportExpand || nestExpandable; // =========================== onRow ===========================\n\n var additionalProps;\n\n if (onRow) {\n additionalProps = onRow(record, index);\n }\n\n var onClick = function onClick(event) {\n if (expandRowByClick && mergedExpandable) {\n onTriggerExpand(record, event);\n }\n\n if (additionalProps && additionalProps.onClick) {\n var _additionalProps;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n (_additionalProps = additionalProps).onClick.apply(_additionalProps, [event].concat(args));\n }\n }; // ======================== Base tr row ========================\n\n\n var computeRowClassName;\n\n if (typeof rowClassName === 'string') {\n computeRowClassName = rowClassName;\n } else if (typeof rowClassName === 'function') {\n computeRowClassName = rowClassName(record, index, indent);\n }\n\n var columnsKey = getColumnsKey(flattenColumns);\n var baseRowNode = React.createElement(RowComponent, Object.assign({}, additionalProps, {\n \"data-row-key\": rowKey,\n className: classNames(className, \"\".concat(prefixCls, \"-row\"), \"\".concat(prefixCls, \"-row-level-\").concat(indent), computeRowClassName, additionalProps && additionalProps.className),\n style: _objectSpread(_objectSpread({}, style), additionalProps ? additionalProps.style : null),\n onClick: onClick\n }), flattenColumns.map(function (column, colIndex) {\n var render = column.render,\n dataIndex = column.dataIndex,\n columnClassName = column.className;\n var key = columnsKey[colIndex];\n var fixedInfo = fixedInfoList[colIndex]; // ============= Used for nest expandable =============\n\n var appendCellNode;\n\n if (colIndex === (expandIconColumnIndex || 0) && nestExpandable) {\n appendCellNode = React.createElement(React.Fragment, null, React.createElement(\"span\", {\n style: {\n paddingLeft: \"\".concat(indentSize * indent, \"px\")\n },\n className: \"\".concat(prefixCls, \"-row-indent indent-level-\").concat(indent)\n }), expandIcon({\n prefixCls: prefixCls,\n expanded: expanded,\n expandable: hasNestChildren,\n record: record,\n onExpand: onTriggerExpand\n }));\n }\n\n var additionalCellProps;\n\n if (column.onCell) {\n additionalCellProps = column.onCell(record, index);\n }\n\n return React.createElement(Cell, Object.assign({\n className: columnClassName,\n ellipsis: column.ellipsis,\n align: column.align,\n component: cellComponent,\n prefixCls: prefixCls,\n key: key,\n record: record,\n index: index,\n dataIndex: dataIndex,\n render: render,\n shouldCellUpdate: column.shouldCellUpdate\n }, fixedInfo, {\n appendNode: appendCellNode,\n additionalProps: additionalCellProps\n }));\n })); // ======================== Expand Row =========================\n\n var expandRowNode;\n\n if (rowSupportExpand && (expandRended || expanded)) {\n var expandContent = expandedRowRender(record, index, indent + 1, expanded);\n var computedExpandedRowClassName = expandedRowClassName && expandedRowClassName(record, index, indent);\n expandRowNode = React.createElement(ExpandedRow, {\n expanded: expanded,\n className: classNames(\"\".concat(prefixCls, \"-expanded-row\"), \"\".concat(prefixCls, \"-expanded-row-level-\").concat(indent + 1), computedExpandedRowClassName),\n prefixCls: prefixCls,\n fixHeader: fixHeader,\n fixColumn: fixColumn,\n horizonScroll: horizonScroll,\n component: RowComponent,\n componentWidth: componentWidth,\n cellComponent: cellComponent,\n colSpan: flattenColumns.length\n }, expandContent);\n } // ========================= Nest Row ==========================\n\n\n var nestRowNode;\n\n if (hasNestChildren && expanded) {\n nestRowNode = (record[childrenColumnName] || []).map(function (subRecord, subIndex) {\n var subKey = getRowKey(subRecord, subIndex);\n return React.createElement(BodyRow, Object.assign({}, props, {\n key: subKey,\n rowKey: subKey,\n record: subRecord,\n recordKey: subKey,\n index: subIndex,\n indent: indent + 1\n }));\n });\n }\n\n return React.createElement(React.Fragment, null, baseRowNode, expandRowNode, nestRowNode);\n}\n\nBodyRow.displayName = 'BodyRow';\nexport default BodyRow;","import * as React from 'react';\nvar ResizeContext = React.createContext(null);\nexport default ResizeContext;","import * as React from 'react';\nimport ResizeObserver from 'rc-resize-observer';\nimport BodyRow from './BodyRow';\nimport TableContext from '../context/TableContext';\nimport ExpandedRow from './ExpandedRow';\nimport BodyContext from '../context/BodyContext';\nimport { getColumnsKey } from '../utils/valueUtil';\nimport ResizeContext from '../context/ResizeContext';\n\nfunction Body(_ref) {\n var data = _ref.data,\n getRowKey = _ref.getRowKey,\n measureColumnWidth = _ref.measureColumnWidth,\n expandedKeys = _ref.expandedKeys,\n onRow = _ref.onRow,\n rowExpandable = _ref.rowExpandable,\n emptyNode = _ref.emptyNode,\n childrenColumnName = _ref.childrenColumnName;\n\n var _React$useContext = React.useContext(ResizeContext),\n onColumnResize = _React$useContext.onColumnResize;\n\n var _React$useContext2 = React.useContext(TableContext),\n prefixCls = _React$useContext2.prefixCls,\n getComponent = _React$useContext2.getComponent;\n\n var _React$useContext3 = React.useContext(BodyContext),\n fixHeader = _React$useContext3.fixHeader,\n horizonScroll = _React$useContext3.horizonScroll,\n flattenColumns = _React$useContext3.flattenColumns,\n componentWidth = _React$useContext3.componentWidth;\n\n return React.useMemo(function () {\n var WrapperComponent = getComponent(['body', 'wrapper'], 'tbody');\n var trComponent = getComponent(['body', 'row'], 'tr');\n var tdComponent = getComponent(['body', 'cell'], 'td');\n var rows;\n\n if (data.length) {\n rows = data.map(function (record, index) {\n var key = getRowKey(record, index);\n return React.createElement(BodyRow, {\n key: key,\n rowKey: key,\n record: record,\n recordKey: key,\n index: index,\n rowComponent: trComponent,\n cellComponent: tdComponent,\n expandedKeys: expandedKeys,\n onRow: onRow,\n getRowKey: getRowKey,\n rowExpandable: rowExpandable,\n childrenColumnName: childrenColumnName\n });\n });\n } else {\n rows = React.createElement(ExpandedRow, {\n expanded: true,\n className: \"\".concat(prefixCls, \"-placeholder\"),\n prefixCls: prefixCls,\n fixHeader: fixHeader,\n fixColumn: horizonScroll,\n horizonScroll: horizonScroll,\n component: trComponent,\n componentWidth: componentWidth,\n cellComponent: tdComponent,\n colSpan: flattenColumns.length\n }, emptyNode);\n }\n\n var columnsKey = getColumnsKey(flattenColumns);\n return React.createElement(WrapperComponent, {\n className: \"\".concat(prefixCls, \"-tbody\")\n }, measureColumnWidth && React.createElement(\"tr\", {\n \"aria-hidden\": \"true\",\n className: \"\".concat(prefixCls, \"-measure-row\"),\n style: {\n height: 0\n }\n }, columnsKey.map(function (columnKey) {\n return React.createElement(ResizeObserver, {\n key: columnKey,\n onResize: function onResize(_ref2) {\n var offsetWidth = _ref2.offsetWidth;\n onColumnResize(columnKey, offsetWidth);\n }\n }, React.createElement(\"td\", {\n style: {\n padding: 0,\n border: 0,\n height: 0\n }\n }));\n })), rows);\n }, [data, prefixCls, onRow, measureColumnWidth, expandedKeys, getRowKey, getComponent, componentWidth, emptyNode, flattenColumns]);\n}\n\nvar MemoBody = React.memo(Body);\nMemoBody.displayName = 'Body';\nexport default MemoBody;","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport warning from \"rc-util/es/warning\";\nimport toArray from \"rc-util/es/Children/toArray\";\nimport { INTERNAL_COL_DEFINE } from '../utils/legacyUtil';\nexport function convertChildrenToColumns(children) {\n return toArray(children).filter(function (node) {\n return React.isValidElement(node);\n }).map(function (_ref) {\n var key = _ref.key,\n props = _ref.props;\n\n var nodeChildren = props.children,\n restProps = _objectWithoutProperties(props, [\"children\"]);\n\n var column = _objectSpread({\n key: key\n }, restProps);\n\n if (nodeChildren) {\n column.children = convertChildrenToColumns(nodeChildren);\n }\n\n return column;\n });\n}\n\nfunction flatColumns(columns) {\n return columns.reduce(function (list, column) {\n var fixed = column.fixed; // Convert `fixed='true'` to `fixed='left'` instead\n\n var parsedFixed = fixed === true ? 'left' : fixed;\n var subColumns = column.children;\n\n if (subColumns && subColumns.length > 0) {\n return [].concat(_toConsumableArray(list), _toConsumableArray(flatColumns(subColumns).map(function (subColum) {\n return _objectSpread({\n fixed: parsedFixed\n }, subColum);\n })));\n }\n\n return [].concat(_toConsumableArray(list), [_objectSpread(_objectSpread({}, column), {}, {\n fixed: parsedFixed\n })]);\n }, []);\n}\n\nfunction warningFixed(flattenColumns) {\n var allFixLeft = true;\n\n for (var i = 0; i < flattenColumns.length; i += 1) {\n var col = flattenColumns[i];\n\n if (allFixLeft && col.fixed !== 'left') {\n allFixLeft = false;\n } else if (!allFixLeft && col.fixed === 'left') {\n warning(false, \"Index \".concat(i - 1, \" of `columns` missing `fixed='left'` prop.\"));\n break;\n }\n }\n\n var allFixRight = true;\n\n for (var _i = flattenColumns.length - 1; _i >= 0; _i -= 1) {\n var _col = flattenColumns[_i];\n\n if (allFixRight && _col.fixed !== 'right') {\n allFixRight = false;\n } else if (!allFixRight && _col.fixed === 'right') {\n warning(false, \"Index \".concat(_i + 1, \" of `columns` missing `fixed='right'` prop.\"));\n break;\n }\n }\n}\n\nfunction revertForRtl(columns) {\n return columns.map(function (column) {\n var fixed = column.fixed,\n restProps = _objectWithoutProperties(column, [\"fixed\"]); // Convert `fixed='left'` to `fixed='right'` instead\n\n\n var parsedFixed = fixed;\n\n if (fixed === 'left') {\n parsedFixed = 'right';\n } else if (fixed === 'right') {\n parsedFixed = 'left';\n }\n\n return _objectSpread({\n fixed: parsedFixed\n }, restProps);\n });\n}\n/**\n * Parse `columns` & `children` into `columns`.\n */\n\n\nfunction useColumns(_ref2, transformColumns) {\n var prefixCls = _ref2.prefixCls,\n columns = _ref2.columns,\n children = _ref2.children,\n expandable = _ref2.expandable,\n expandedKeys = _ref2.expandedKeys,\n getRowKey = _ref2.getRowKey,\n onTriggerExpand = _ref2.onTriggerExpand,\n expandIcon = _ref2.expandIcon,\n rowExpandable = _ref2.rowExpandable,\n expandIconColumnIndex = _ref2.expandIconColumnIndex,\n direction = _ref2.direction,\n expandRowByClick = _ref2.expandRowByClick;\n var baseColumns = React.useMemo(function () {\n return columns || convertChildrenToColumns(children);\n }, [columns, children]); // Add expand column\n\n var withExpandColumns = React.useMemo(function () {\n if (expandable) {\n var _expandColumn;\n\n var expandColIndex = expandIconColumnIndex || 0;\n var prevColumn = baseColumns[expandColIndex];\n var expandColumn = (_expandColumn = {}, _defineProperty(_expandColumn, INTERNAL_COL_DEFINE, {\n className: \"\".concat(prefixCls, \"-expand-icon-col\")\n }), _defineProperty(_expandColumn, \"title\", ''), _defineProperty(_expandColumn, \"fixed\", prevColumn ? prevColumn.fixed : null), _defineProperty(_expandColumn, \"className\", \"\".concat(prefixCls, \"-row-expand-icon-cell\")), _defineProperty(_expandColumn, \"render\", function render(_, record, index) {\n var rowKey = getRowKey(record, index);\n var expanded = expandedKeys.has(rowKey);\n var recordExpandable = rowExpandable ? rowExpandable(record) : true;\n var icon = expandIcon({\n prefixCls: prefixCls,\n expanded: expanded,\n expandable: recordExpandable,\n record: record,\n onExpand: onTriggerExpand\n });\n\n if (expandRowByClick) {\n return React.createElement(\"span\", {\n onClick: function onClick(e) {\n return e.stopPropagation();\n }\n }, icon);\n }\n\n return icon;\n }), _expandColumn); // Insert expand column in the target position\n\n var cloneColumns = baseColumns.slice();\n\n if (expandColIndex >= 0) {\n cloneColumns.splice(expandColIndex, 0, expandColumn);\n }\n\n return cloneColumns;\n }\n\n return baseColumns;\n }, [expandable, baseColumns, getRowKey, expandedKeys, expandIcon, direction]);\n var mergedColumns = React.useMemo(function () {\n var finalColumns = withExpandColumns;\n\n if (transformColumns) {\n finalColumns = transformColumns(finalColumns);\n } // Always provides at least one column for table display\n\n\n if (!finalColumns.length) {\n finalColumns = [{\n render: function render() {\n return null;\n }\n }];\n }\n\n return finalColumns;\n }, [transformColumns, withExpandColumns, direction]);\n var flattenColumns = React.useMemo(function () {\n if (direction === 'rtl') {\n return revertForRtl(flatColumns(mergedColumns));\n }\n\n return flatColumns(mergedColumns);\n }, [mergedColumns, direction]); // Only check out of production since it's waste for each render\n\n if (process.env.NODE_ENV !== 'production') {\n warningFixed(flattenColumns);\n }\n\n return [mergedColumns, flattenColumns];\n}\n\nexport default useColumns;","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport warning from \"rc-util/es/warning\";\nexport var INTERNAL_COL_DEFINE = 'RC_TABLE_INTERNAL_COL_DEFINE';\nexport function getExpandableProps(props) {\n var expandable = props.expandable,\n legacyExpandableConfig = _objectWithoutProperties(props, [\"expandable\"]);\n\n if ('expandable' in props) {\n return _objectSpread(_objectSpread({}, legacyExpandableConfig), expandable);\n }\n\n if (process.env.NODE_ENV !== 'production' && ['indentSize', 'expandedRowKeys', 'defaultExpandedRowKeys', 'defaultExpandAllRows', 'expandedRowRender', 'expandRowByClick', 'expandIcon', 'onExpand', 'onExpandedRowsChange', 'expandedRowClassName', 'expandIconColumnIndex'].some(function (prop) {\n return prop in props;\n })) {\n warning(false, 'expanded related props have been moved into `expandable`.');\n }\n\n return legacyExpandableConfig;\n}\n/**\n * Returns only data- and aria- key/value pairs\n * @param {object} props\n */\n\nexport function getDataAndAriaProps(props) {\n /* eslint-disable no-param-reassign */\n return Object.keys(props).reduce(function (memo, key) {\n if (key.substr(0, 5) === 'data-' || key.substr(0, 5) === 'aria-') {\n memo[key] = props[key];\n }\n\n return memo;\n }, {});\n /* eslint-enable */\n}","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport { useRef, useState, useEffect } from 'react';\nimport raf from 'raf';\nexport function useFrameState(defaultState) {\n var stateRef = useRef(defaultState);\n\n var _useState = useState({}),\n _useState2 = _slicedToArray(_useState, 2),\n forceUpdate = _useState2[1];\n\n var timeoutRef = useRef(null);\n var updateBatchRef = useRef([]);\n\n function setFrameState(updater) {\n if (timeoutRef.current === null) {\n updateBatchRef.current = [];\n timeoutRef.current = raf(function () {\n updateBatchRef.current.forEach(function (batchUpdater) {\n stateRef.current = batchUpdater(stateRef.current);\n });\n timeoutRef.current = null;\n forceUpdate({});\n });\n }\n\n updateBatchRef.current.push(updater);\n }\n\n useEffect(function () {\n return function () {\n raf.cancel(timeoutRef.current);\n };\n }, []);\n return [stateRef.current, setFrameState];\n}\n/** Lock frame, when frame pass reset the lock. */\n\nexport function useTimeoutLock(defaultState) {\n var frameRef = useRef(defaultState);\n var timeoutRef = useRef(null);\n\n function cleanUp() {\n window.clearTimeout(timeoutRef.current);\n }\n\n function setState(newState) {\n frameRef.current = newState;\n cleanUp();\n timeoutRef.current = window.setTimeout(function () {\n frameRef.current = null;\n timeoutRef.current = null;\n }, 100);\n }\n\n function getState() {\n return frameRef.current;\n }\n\n useEffect(function () {\n return cleanUp;\n }, []);\n return [setState, getState];\n}","import { useMemo } from 'react';\n/**\n * Get sticky column offset width\n */\n\nfunction useStickyOffsets(colWidths, columCount, direction) {\n var stickyOffsets = useMemo(function () {\n var leftOffsets = [];\n var rightOffsets = [];\n var left = 0;\n var right = 0;\n\n for (var start = 0; start < columCount; start += 1) {\n if (direction === 'rtl') {\n // Left offset\n rightOffsets[start] = right;\n right += colWidths[start] || 0; // Right offset\n\n var end = columCount - start - 1;\n leftOffsets[end] = left;\n left += colWidths[end] || 0;\n } else {\n // Left offset\n leftOffsets[start] = left;\n left += colWidths[start] || 0; // Right offset\n\n var _end = columCount - start - 1;\n\n rightOffsets[_end] = right;\n right += colWidths[_end] || 0;\n }\n }\n\n return {\n left: leftOffsets,\n right: rightOffsets\n };\n }, [colWidths, columCount, direction]);\n return stickyOffsets;\n}\n\nexport default useStickyOffsets;","import * as React from 'react';\n\nfunction Panel(_ref) {\n var className = _ref.className,\n children = _ref.children;\n return React.createElement(\"div\", {\n className: className\n }, children);\n}\n\nexport default Panel;","import * as React from 'react';\nimport TableContext from '../context/TableContext';\nimport Cell from './Cell';\nimport Row from './Row';\n\nfunction Footer(_ref) {\n var children = _ref.children;\n\n var _React$useContext = React.useContext(TableContext),\n prefixCls = _React$useContext.prefixCls;\n\n return React.createElement(\"tfoot\", {\n className: \"\".concat(prefixCls, \"-summary\")\n }, children);\n}\n\nexport default Footer;\nexport var FooterComponents = {\n Cell: Cell,\n Row: Row\n};","import * as React from 'react';\nimport Cell from '../Cell';\nimport TableContext from '../context/TableContext';\nexport default function SummaryCell(_ref) {\n var className = _ref.className,\n index = _ref.index,\n children = _ref.children,\n colSpan = _ref.colSpan,\n rowSpan = _ref.rowSpan;\n\n var _React$useContext = React.useContext(TableContext),\n prefixCls = _React$useContext.prefixCls,\n fixedInfoList = _React$useContext.fixedInfoList;\n\n var fixedInfo = fixedInfoList[index];\n return React.createElement(Cell, Object.assign({\n className: className,\n index: index,\n component: \"td\",\n prefixCls: prefixCls,\n record: null,\n dataIndex: null,\n render: function render() {\n return {\n children: children,\n props: {\n colSpan: colSpan,\n rowSpan: rowSpan\n }\n };\n }\n }, fixedInfo));\n}","import * as React from 'react';\nexport default function FooterRow(props) {\n return React.createElement(\"tr\", Object.assign({}, props));\n}","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nexport function renderExpandIcon(_ref) {\n var _classNames;\n\n var prefixCls = _ref.prefixCls,\n record = _ref.record,\n onExpand = _ref.onExpand,\n expanded = _ref.expanded,\n expandable = _ref.expandable;\n var expandClassName = \"\".concat(prefixCls, \"-row-expand-icon\");\n\n if (!expandable) {\n return React.createElement(\"span\", {\n className: classNames(expandClassName, \"\".concat(prefixCls, \"-row-spaced\"))\n });\n }\n\n var onClick = function onClick(event) {\n onExpand(record, event);\n event.stopPropagation();\n };\n\n return React.createElement(\"span\", {\n className: classNames(expandClassName, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-row-expanded\"), expanded), _defineProperty(_classNames, \"\".concat(prefixCls, \"-row-collapsed\"), !expanded), _classNames)),\n onClick: onClick\n });\n}\nexport function findAllChildrenKeys(data, getRowKey, childrenColumnName) {\n var keys = [];\n\n function dig(list) {\n (list || []).forEach(function (item, index) {\n keys.push(getRowKey(item, index));\n dig(item[childrenColumnName]);\n });\n }\n\n dig(data);\n return keys;\n}","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport * as React from 'react';\nimport addEventListener from \"rc-util/es/Dom/addEventListener\";\nimport getScrollBarSize from \"rc-util/es/getScrollBarSize\";\nimport classNames from 'classnames';\nimport { getOffset } from \"rc-util/es/Dom/css\";\nimport TableContext from './context/TableContext';\nimport { useFrameState } from './hooks/useFrame';\n\nvar StickyScrollBar = function StickyScrollBar(_ref, ref) {\n var _scrollBodyRef$curren, _scrollBodyRef$curren2;\n\n var scrollBodyRef = _ref.scrollBodyRef,\n onScroll = _ref.onScroll,\n offsetScroll = _ref.offsetScroll;\n\n var _React$useContext = React.useContext(TableContext),\n prefixCls = _React$useContext.prefixCls;\n\n var bodyScrollWidth = ((_scrollBodyRef$curren = scrollBodyRef.current) === null || _scrollBodyRef$curren === void 0 ? void 0 : _scrollBodyRef$curren.scrollWidth) || 0;\n var bodyWidth = ((_scrollBodyRef$curren2 = scrollBodyRef.current) === null || _scrollBodyRef$curren2 === void 0 ? void 0 : _scrollBodyRef$curren2.clientWidth) || 0;\n var scrollBarWidth = bodyScrollWidth && bodyWidth * (bodyWidth / bodyScrollWidth);\n var scrollBarRef = React.useRef();\n\n var _useFrameState = useFrameState({\n scrollLeft: 0,\n isHiddenScrollBar: false\n }),\n _useFrameState2 = _slicedToArray(_useFrameState, 2),\n frameState = _useFrameState2[0],\n setFrameState = _useFrameState2[1];\n\n var refState = React.useRef({\n delta: 0,\n x: 0\n });\n\n var _React$useState = React.useState(false),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n isActive = _React$useState2[0],\n setActive = _React$useState2[1];\n\n var onMouseUp = function onMouseUp() {\n setActive(false);\n };\n\n var onMouseDown = function onMouseDown(event) {\n event.persist();\n refState.current.delta = event.pageX - frameState.scrollLeft;\n refState.current.x = 0;\n setActive(true);\n event.preventDefault();\n };\n\n var onMouseMove = function onMouseMove(event) {\n var _window;\n\n // https://developer.mozilla.org/en-US/docs/Web/API/MouseEvent/buttons\n var _ref2 = event || ((_window = window) === null || _window === void 0 ? void 0 : _window.event),\n buttons = _ref2.buttons;\n\n if (!isActive || buttons === 0) {\n // If out body mouse up, we can set isActive false when mouse move\n if (isActive) {\n setActive(false);\n }\n\n return;\n }\n\n var left = refState.current.x + event.pageX - refState.current.x - refState.current.delta;\n\n if (left <= 0) {\n left = 0;\n }\n\n if (left + scrollBarWidth >= bodyWidth) {\n left = bodyWidth - scrollBarWidth;\n }\n\n onScroll({\n scrollLeft: left / bodyWidth * (bodyScrollWidth + 2)\n });\n refState.current.x = event.pageX;\n };\n\n var onContainerScroll = function onContainerScroll() {\n var tableOffsetTop = getOffset(scrollBodyRef.current).top;\n var tableBottomOffset = tableOffsetTop + scrollBodyRef.current.offsetHeight;\n var currentClientOffset = document.documentElement.scrollTop + window.innerHeight;\n\n if (tableBottomOffset - getScrollBarSize() <= currentClientOffset || tableOffsetTop >= currentClientOffset - offsetScroll) {\n setFrameState(function (state) {\n return _objectSpread(_objectSpread({}, state), {}, {\n isHiddenScrollBar: true\n });\n });\n } else {\n setFrameState(function (state) {\n return _objectSpread(_objectSpread({}, state), {}, {\n isHiddenScrollBar: false\n });\n });\n }\n };\n\n var setScrollLeft = function setScrollLeft(left) {\n setFrameState(function (state) {\n return _objectSpread(_objectSpread({}, state), {}, {\n scrollLeft: left / bodyScrollWidth * bodyWidth || 0\n });\n });\n };\n\n React.useImperativeHandle(ref, function () {\n return {\n setScrollLeft: setScrollLeft\n };\n });\n React.useEffect(function () {\n var onMouseUpListener = addEventListener(document.body, 'mouseup', onMouseUp, false);\n var onMouseMoveListener = addEventListener(document.body, 'mousemove', onMouseMove, false);\n onContainerScroll();\n return function () {\n onMouseUpListener.remove();\n onMouseMoveListener.remove();\n };\n }, [scrollBarWidth, isActive]);\n React.useEffect(function () {\n var onScrollListener = addEventListener(window, 'scroll', onContainerScroll, false);\n var onResizeListener = addEventListener(window, 'resize', onContainerScroll, false);\n return function () {\n onScrollListener.remove();\n onResizeListener.remove();\n };\n }, []);\n React.useEffect(function () {\n if (!frameState.isHiddenScrollBar) {\n setFrameState(function (state) {\n var _scrollBodyRef$curren3, _scrollBodyRef$curren4;\n\n return _objectSpread(_objectSpread({}, state), {}, {\n scrollLeft: scrollBodyRef.current.scrollLeft / ((_scrollBodyRef$curren3 = scrollBodyRef.current) === null || _scrollBodyRef$curren3 === void 0 ? void 0 : _scrollBodyRef$curren3.scrollWidth) * ((_scrollBodyRef$curren4 = scrollBodyRef.current) === null || _scrollBodyRef$curren4 === void 0 ? void 0 : _scrollBodyRef$curren4.clientWidth)\n });\n });\n }\n }, [frameState.isHiddenScrollBar]);\n\n if (bodyScrollWidth <= bodyWidth || !scrollBarWidth || frameState.isHiddenScrollBar) {\n return null;\n }\n\n return React.createElement(\"div\", {\n style: {\n height: getScrollBarSize(),\n width: bodyWidth,\n bottom: offsetScroll\n },\n className: \"\".concat(prefixCls, \"-sticky-scroll\")\n }, React.createElement(\"div\", {\n onMouseDown: onMouseDown,\n ref: scrollBarRef,\n className: classNames(\"\".concat(prefixCls, \"-sticky-scroll-bar\"), _defineProperty({}, \"\".concat(prefixCls, \"-sticky-scroll-bar-active\"), isActive)),\n style: {\n width: \"\".concat(scrollBarWidth, \"px\"),\n transform: \"translate3d(\".concat(frameState.scrollLeft, \"px, 0, 0)\")\n }\n }));\n};\n\nexport default React.forwardRef(StickyScrollBar);","/* eslint-disable no-nested-ternary */\nvar PIXEL_PATTERN = /margin|padding|width|height|max|min|offset/;\nvar removePixel = {\n left: true,\n top: true\n};\nvar floatMap = {\n cssFloat: 1,\n styleFloat: 1,\n float: 1\n};\n\nfunction getComputedStyle(node) {\n return node.nodeType === 1 ? node.ownerDocument.defaultView.getComputedStyle(node, null) : {};\n}\n\nfunction getStyleValue(node, type, value) {\n type = type.toLowerCase();\n\n if (value === 'auto') {\n if (type === 'height') {\n return node.offsetHeight;\n }\n\n if (type === 'width') {\n return node.offsetWidth;\n }\n }\n\n if (!(type in removePixel)) {\n removePixel[type] = PIXEL_PATTERN.test(type);\n }\n\n return removePixel[type] ? parseFloat(value) || 0 : value;\n}\n\nexport function get(node, name) {\n var length = arguments.length;\n var style = getComputedStyle(node);\n name = floatMap[name] ? 'cssFloat' in node.style ? 'cssFloat' : 'styleFloat' : name;\n return length === 1 ? style : getStyleValue(node, name, style[name] || node.style[name]);\n}\nexport function set(node, name, value) {\n var length = arguments.length;\n name = floatMap[name] ? 'cssFloat' in node.style ? 'cssFloat' : 'styleFloat' : name;\n\n if (length === 3) {\n if (typeof value === 'number' && PIXEL_PATTERN.test(name)) {\n value = \"\".concat(value, \"px\");\n }\n\n node.style[name] = value; // Number\n\n return value;\n }\n\n for (var x in name) {\n if (name.hasOwnProperty(x)) {\n set(node, x, name[x]);\n }\n }\n\n return getComputedStyle(node);\n}\nexport function getOuterWidth(el) {\n if (el === document.body) {\n return document.documentElement.clientWidth;\n }\n\n return el.offsetWidth;\n}\nexport function getOuterHeight(el) {\n if (el === document.body) {\n return window.innerHeight || document.documentElement.clientHeight;\n }\n\n return el.offsetHeight;\n}\nexport function getDocSize() {\n var width = Math.max(document.documentElement.scrollWidth, document.body.scrollWidth);\n var height = Math.max(document.documentElement.scrollHeight, document.body.scrollHeight);\n return {\n width: width,\n height: height\n };\n}\nexport function getClientSize() {\n var width = document.documentElement.clientWidth;\n var height = window.innerHeight || document.documentElement.clientHeight;\n return {\n width: width,\n height: height\n };\n}\nexport function getScroll() {\n return {\n scrollLeft: Math.max(document.documentElement.scrollLeft, document.body.scrollLeft),\n scrollTop: Math.max(document.documentElement.scrollTop, document.body.scrollTop)\n };\n}\nexport function getOffset(node) {\n var box = node.getBoundingClientRect();\n var docElem = document.documentElement; // < ie8 不支持 win.pageXOffset, 则使用 docElem.scrollLeft\n\n return {\n left: box.left + (window.pageXOffset || docElem.scrollLeft) - (docElem.clientLeft || document.body.clientLeft || 0),\n top: box.top + (window.pageYOffset || docElem.scrollTop) - (docElem.clientTop || document.body.clientTop || 0)\n };\n}","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\n\n/**\n * Feature:\n * - fixed not need to set width\n * - support `rowExpandable` to config row expand logic\n * - add `summary` to support `() => ReactNode`\n *\n * Update:\n * - `dataIndex` is `array[]` now\n * - `expandable` wrap all the expand related props\n *\n * Removed:\n * - expandIconAsCell\n * - useFixedHeader\n * - rowRef\n * - columns[number].onCellClick\n * - onRowClick\n * - onRowDoubleClick\n * - onRowMouseEnter\n * - onRowMouseLeave\n * - getBodyWrapper\n * - bodyStyle\n *\n * Deprecated:\n * - All expanded props, move into expandable\n */\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport shallowEqual from 'shallowequal';\nimport warning from \"rc-util/es/warning\";\nimport ResizeObserver from 'rc-resize-observer';\nimport getScrollBarSize from \"rc-util/es/getScrollBarSize\";\nimport ColumnGroup from './sugar/ColumnGroup';\nimport Column from './sugar/Column';\nimport FixedHeader from './Header/FixedHeader';\nimport Header from './Header/Header';\nimport TableContext from './context/TableContext';\nimport BodyContext from './context/BodyContext';\nimport Body from './Body';\nimport useColumns from './hooks/useColumns';\nimport { useFrameState, useTimeoutLock } from './hooks/useFrame';\nimport { getPathValue, mergeObject, validateValue, getColumnsKey } from './utils/valueUtil';\nimport ResizeContext from './context/ResizeContext';\nimport useStickyOffsets from './hooks/useStickyOffsets';\nimport ColGroup from './ColGroup';\nimport { getExpandableProps, getDataAndAriaProps } from './utils/legacyUtil';\nimport Panel from './Panel';\nimport Footer, { FooterComponents } from './Footer';\nimport { findAllChildrenKeys, renderExpandIcon } from './utils/expandUtil';\nimport { getCellFixedInfo } from './utils/fixUtil';\nimport StickyScrollBar from './stickyScrollBar';\nimport useSticky from './hooks/useSticky'; // Used for conditions cache\n\nvar EMPTY_DATA = []; // Used for customize scroll\n\nvar EMPTY_SCROLL_TARGET = {};\nexport var INTERNAL_HOOKS = 'rc-table-internal-hook';\nvar MemoTableContent = React.memo(function (_ref) {\n var children = _ref.children;\n return children;\n}, function (prev, next) {\n if (!shallowEqual(prev.props, next.props)) {\n return false;\n } // No additional render when pinged status change.\n // This is not a bug.\n\n\n return prev.pingLeft !== next.pingLeft || prev.pingRight !== next.pingRight;\n});\n\nfunction Table(props) {\n var _classNames2;\n\n var prefixCls = props.prefixCls,\n className = props.className,\n rowClassName = props.rowClassName,\n style = props.style,\n data = props.data,\n rowKey = props.rowKey,\n scroll = props.scroll,\n tableLayout = props.tableLayout,\n direction = props.direction,\n title = props.title,\n footer = props.footer,\n summary = props.summary,\n id = props.id,\n showHeader = props.showHeader,\n components = props.components,\n emptyText = props.emptyText,\n onRow = props.onRow,\n onHeaderRow = props.onHeaderRow,\n internalHooks = props.internalHooks,\n transformColumns = props.transformColumns,\n internalRefs = props.internalRefs,\n sticky = props.sticky;\n var mergedData = data || EMPTY_DATA;\n var hasData = !!mergedData.length; // ===================== Effects ======================\n\n var _React$useState = React.useState(0),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n scrollbarSize = _React$useState2[0],\n setScrollbarSize = _React$useState2[1];\n\n React.useEffect(function () {\n setScrollbarSize(getScrollBarSize());\n }); // ===================== Warning ======================\n\n if (process.env.NODE_ENV !== 'production') {\n ['onRowClick', 'onRowDoubleClick', 'onRowContextMenu', 'onRowMouseEnter', 'onRowMouseLeave'].forEach(function (name) {\n warning(props[name] === undefined, \"`\".concat(name, \"` is removed, please use `onRow` instead.\"));\n });\n warning(!('getBodyWrapper' in props), '`getBodyWrapper` is deprecated, please use custom `components` instead.');\n } // ==================== Customize =====================\n\n\n var mergedComponents = React.useMemo(function () {\n return mergeObject(components, {});\n }, [components]);\n var getComponent = React.useCallback(function (path, defaultComponent) {\n return getPathValue(mergedComponents, path) || defaultComponent;\n }, [mergedComponents]);\n var getRowKey = React.useMemo(function () {\n if (typeof rowKey === 'function') {\n return rowKey;\n }\n\n return function (record) {\n var key = record && record[rowKey];\n\n if (process.env.NODE_ENV !== 'production') {\n warning(key !== undefined, 'Each record in table should have a unique `key` prop, or set `rowKey` to an unique primary key.');\n }\n\n return key;\n };\n }, [rowKey]); // ====================== Expand ======================\n\n var expandableConfig = getExpandableProps(props);\n var expandIcon = expandableConfig.expandIcon,\n expandedRowKeys = expandableConfig.expandedRowKeys,\n defaultExpandedRowKeys = expandableConfig.defaultExpandedRowKeys,\n defaultExpandAllRows = expandableConfig.defaultExpandAllRows,\n expandedRowRender = expandableConfig.expandedRowRender,\n onExpand = expandableConfig.onExpand,\n onExpandedRowsChange = expandableConfig.onExpandedRowsChange,\n expandRowByClick = expandableConfig.expandRowByClick,\n rowExpandable = expandableConfig.rowExpandable,\n expandIconColumnIndex = expandableConfig.expandIconColumnIndex,\n expandedRowClassName = expandableConfig.expandedRowClassName,\n childrenColumnName = expandableConfig.childrenColumnName,\n indentSize = expandableConfig.indentSize;\n var mergedExpandIcon = expandIcon || renderExpandIcon;\n var mergedChildrenColumnName = childrenColumnName || 'children';\n var expandableType = React.useMemo(function () {\n if (expandedRowRender) {\n return 'row';\n }\n /* eslint-disable no-underscore-dangle */\n\n /**\n * Fix https://github.com/ant-design/ant-design/issues/21154\n * This is a workaround to not to break current behavior.\n * We can remove follow code after final release.\n *\n * To other developer:\n * Do not use `__PARENT_RENDER_ICON__` in prod since we will remove this when refactor\n */\n\n\n if (props.expandable && internalHooks === INTERNAL_HOOKS && props.expandable.__PARENT_RENDER_ICON__ || mergedData.some(function (record) {\n return record && _typeof(record) === 'object' && record[mergedChildrenColumnName];\n })) {\n return 'nest';\n }\n /* eslint-enable */\n\n\n return false;\n }, [!!expandedRowRender, mergedData]);\n\n var _React$useState3 = React.useState(function () {\n if (defaultExpandedRowKeys) {\n return defaultExpandedRowKeys;\n }\n\n if (defaultExpandAllRows) {\n return findAllChildrenKeys(mergedData, getRowKey, mergedChildrenColumnName);\n }\n\n return [];\n }),\n _React$useState4 = _slicedToArray(_React$useState3, 2),\n innerExpandedKeys = _React$useState4[0],\n setInnerExpandedKeys = _React$useState4[1];\n\n var mergedExpandedKeys = React.useMemo(function () {\n return new Set(expandedRowKeys || innerExpandedKeys || []);\n }, [expandedRowKeys, innerExpandedKeys]);\n var onTriggerExpand = React.useCallback(function (record) {\n var key = getRowKey(record, mergedData.indexOf(record));\n var newExpandedKeys;\n var hasKey = mergedExpandedKeys.has(key);\n\n if (hasKey) {\n mergedExpandedKeys.delete(key);\n newExpandedKeys = _toConsumableArray(mergedExpandedKeys);\n } else {\n newExpandedKeys = [].concat(_toConsumableArray(mergedExpandedKeys), [key]);\n }\n\n setInnerExpandedKeys(newExpandedKeys);\n\n if (onExpand) {\n onExpand(!hasKey, record);\n }\n\n if (onExpandedRowsChange) {\n onExpandedRowsChange(newExpandedKeys);\n }\n }, [getRowKey, mergedExpandedKeys, mergedData, onExpand, onExpandedRowsChange]); // ====================== Column ======================\n\n var _React$useState5 = React.useState(0),\n _React$useState6 = _slicedToArray(_React$useState5, 2),\n componentWidth = _React$useState6[0],\n setComponentWidth = _React$useState6[1];\n\n var _useColumns = useColumns(_objectSpread(_objectSpread(_objectSpread({}, props), expandableConfig), {}, {\n expandable: !!expandedRowRender,\n expandedKeys: mergedExpandedKeys,\n getRowKey: getRowKey,\n // https://github.com/ant-design/ant-design/issues/23894\n onTriggerExpand: onTriggerExpand,\n expandIcon: mergedExpandIcon,\n expandIconColumnIndex: expandIconColumnIndex,\n direction: direction\n }), internalHooks === INTERNAL_HOOKS ? transformColumns : null),\n _useColumns2 = _slicedToArray(_useColumns, 2),\n columns = _useColumns2[0],\n flattenColumns = _useColumns2[1];\n\n var columnContext = React.useMemo(function () {\n return {\n columns: columns,\n flattenColumns: flattenColumns\n };\n }, [columns, flattenColumns]); // ====================== Scroll ======================\n\n var fullTableRef = React.useRef();\n var scrollHeaderRef = React.useRef();\n var scrollBodyRef = React.useRef();\n\n var _React$useState7 = React.useState(false),\n _React$useState8 = _slicedToArray(_React$useState7, 2),\n pingedLeft = _React$useState8[0],\n setPingedLeft = _React$useState8[1];\n\n var _React$useState9 = React.useState(false),\n _React$useState10 = _slicedToArray(_React$useState9, 2),\n pingedRight = _React$useState10[0],\n setPingedRight = _React$useState10[1];\n\n var _useFrameState = useFrameState(new Map()),\n _useFrameState2 = _slicedToArray(_useFrameState, 2),\n colsWidths = _useFrameState2[0],\n updateColsWidths = _useFrameState2[1]; // Convert map to number width\n\n\n var colsKeys = getColumnsKey(flattenColumns);\n var pureColWidths = colsKeys.map(function (columnKey) {\n return colsWidths.get(columnKey);\n });\n var colWidths = React.useMemo(function () {\n return pureColWidths;\n }, [pureColWidths.join('_')]);\n var stickyOffsets = useStickyOffsets(colWidths, flattenColumns.length, direction);\n var fixHeader = scroll && validateValue(scroll.y);\n var horizonScroll = scroll && validateValue(scroll.x);\n var fixColumn = horizonScroll && flattenColumns.some(function (_ref2) {\n var fixed = _ref2.fixed;\n return fixed;\n }); // Sticky\n\n var stickyRef = React.useRef();\n\n var _useSticky = useSticky(sticky, prefixCls),\n isSticky = _useSticky.isSticky,\n offsetHeader = _useSticky.offsetHeader,\n offsetScroll = _useSticky.offsetScroll,\n stickyClassName = _useSticky.stickyClassName;\n\n var scrollXStyle;\n var scrollYStyle;\n var scrollTableStyle;\n\n if (fixHeader) {\n scrollYStyle = {\n overflowY: 'scroll',\n maxHeight: scroll.y\n };\n }\n\n if (horizonScroll) {\n scrollXStyle = {\n overflowX: 'auto'\n }; // When no vertical scrollbar, should hide it\n // https://github.com/ant-design/ant-design/pull/20705\n // https://github.com/ant-design/ant-design/issues/21879\n\n if (!fixHeader) {\n scrollYStyle = {\n overflowY: 'hidden'\n };\n }\n\n scrollTableStyle = {\n width: scroll.x === true ? 'auto' : scroll.x,\n minWidth: '100%'\n };\n }\n\n var onColumnResize = React.useCallback(function (columnKey, width) {\n updateColsWidths(function (widths) {\n var newWidths = new Map(widths);\n newWidths.set(columnKey, width);\n return newWidths;\n });\n }, []);\n\n var _useTimeoutLock = useTimeoutLock(null),\n _useTimeoutLock2 = _slicedToArray(_useTimeoutLock, 2),\n setScrollTarget = _useTimeoutLock2[0],\n getScrollTarget = _useTimeoutLock2[1];\n\n function forceScroll(scrollLeft, target) {\n /* eslint-disable no-param-reassign */\n if (target) {\n if (typeof target === 'function') {\n target(scrollLeft);\n } else if (target.scrollLeft !== scrollLeft) {\n target.scrollLeft = scrollLeft;\n }\n }\n /* eslint-enable */\n\n }\n\n var onScroll = function onScroll(_ref3) {\n var currentTarget = _ref3.currentTarget,\n scrollLeft = _ref3.scrollLeft;\n var mergedScrollLeft = typeof scrollLeft === 'number' ? scrollLeft : currentTarget.scrollLeft;\n var compareTarget = currentTarget || EMPTY_SCROLL_TARGET;\n\n if (!getScrollTarget() || getScrollTarget() === compareTarget) {\n var _stickyRef$current;\n\n setScrollTarget(compareTarget);\n forceScroll(mergedScrollLeft, scrollHeaderRef.current);\n forceScroll(mergedScrollLeft, scrollBodyRef.current);\n forceScroll(mergedScrollLeft, (_stickyRef$current = stickyRef.current) === null || _stickyRef$current === void 0 ? void 0 : _stickyRef$current.setScrollLeft);\n }\n\n if (currentTarget) {\n var scrollWidth = currentTarget.scrollWidth,\n clientWidth = currentTarget.clientWidth;\n setPingedLeft(mergedScrollLeft > 0);\n setPingedRight(mergedScrollLeft < scrollWidth - clientWidth);\n }\n };\n\n var triggerOnScroll = function triggerOnScroll() {\n if (scrollBodyRef.current) {\n onScroll({\n currentTarget: scrollBodyRef.current\n });\n }\n };\n\n var onFullTableResize = function onFullTableResize(_ref4) {\n var width = _ref4.width;\n triggerOnScroll();\n setComponentWidth(fullTableRef.current ? fullTableRef.current.offsetWidth : width);\n }; // Sync scroll bar when init or `horizonScroll` changed\n\n\n React.useEffect(function () {\n return triggerOnScroll;\n }, []);\n React.useEffect(function () {\n if (horizonScroll) {\n triggerOnScroll();\n }\n }, [horizonScroll]); // ================== INTERNAL HOOKS ==================\n\n React.useEffect(function () {\n if (internalHooks === INTERNAL_HOOKS && internalRefs) {\n internalRefs.body.current = scrollBodyRef.current;\n }\n }); // ====================== Render ======================\n\n var TableComponent = getComponent(['table'], 'table'); // Table layout\n\n var mergedTableLayout = React.useMemo(function () {\n if (tableLayout) {\n return tableLayout;\n } // https://github.com/ant-design/ant-design/issues/25227\n // When scroll.x is max-content, no need to fix table layout\n // it's width should stretch out to fit content\n\n\n if (fixColumn) {\n return scroll.x === 'max-content' ? 'auto' : 'fixed';\n }\n\n if (fixHeader || flattenColumns.some(function (_ref5) {\n var ellipsis = _ref5.ellipsis;\n return ellipsis;\n })) {\n return 'fixed';\n }\n\n return 'auto';\n }, [fixHeader, fixColumn, flattenColumns, tableLayout]);\n var groupTableNode; // Header props\n\n var headerProps = {\n colWidths: colWidths,\n columCount: flattenColumns.length,\n stickyOffsets: stickyOffsets,\n onHeaderRow: onHeaderRow,\n fixHeader: fixHeader\n }; // Empty\n\n var emptyNode = React.useMemo(function () {\n if (hasData) {\n return null;\n }\n\n if (typeof emptyText === 'function') {\n return emptyText();\n }\n\n return emptyText;\n }, [hasData, emptyText]); // Body\n\n var bodyTable = React.createElement(Body, {\n data: mergedData,\n measureColumnWidth: fixHeader || horizonScroll || isSticky,\n expandedKeys: mergedExpandedKeys,\n rowExpandable: rowExpandable,\n getRowKey: getRowKey,\n onRow: onRow,\n emptyNode: emptyNode,\n childrenColumnName: mergedChildrenColumnName\n });\n var bodyColGroup = React.createElement(ColGroup, {\n colWidths: flattenColumns.map(function (_ref6) {\n var width = _ref6.width;\n return width;\n }),\n columns: flattenColumns\n });\n var footerTable = summary && React.createElement(Footer, null, summary(mergedData));\n var customizeScrollBody = getComponent(['body']);\n\n if (process.env.NODE_ENV !== 'production' && typeof customizeScrollBody === 'function' && hasData && !fixHeader) {\n warning(false, '`components.body` with render props is only work on `scroll.y`.');\n }\n\n if (fixHeader || isSticky) {\n var bodyContent;\n\n if (typeof customizeScrollBody === 'function') {\n bodyContent = customizeScrollBody(mergedData, {\n scrollbarSize: scrollbarSize,\n ref: scrollBodyRef,\n onScroll: onScroll\n });\n headerProps.colWidths = flattenColumns.map(function (_ref7, index) {\n var width = _ref7.width;\n var colWidth = index === columns.length - 1 ? width - scrollbarSize : width;\n\n if (typeof colWidth === 'number' && !Number.isNaN(colWidth)) {\n return colWidth;\n }\n\n warning(false, 'When use `components.body` with render props. Each column should have a fixed value.');\n return 0;\n });\n } else {\n bodyContent = React.createElement(\"div\", {\n style: _objectSpread(_objectSpread({}, scrollXStyle), scrollYStyle),\n onScroll: onScroll,\n ref: scrollBodyRef,\n className: classNames(\"\".concat(prefixCls, \"-body\"))\n }, React.createElement(TableComponent, {\n style: _objectSpread(_objectSpread({}, scrollTableStyle), {}, {\n tableLayout: mergedTableLayout\n })\n }, bodyColGroup, bodyTable, footerTable), isSticky && React.createElement(StickyScrollBar, {\n ref: stickyRef,\n offsetScroll: offsetScroll,\n scrollBodyRef: scrollBodyRef,\n onScroll: onScroll\n }));\n }\n\n groupTableNode = React.createElement(React.Fragment, null, showHeader !== false && React.createElement(\"div\", {\n style: _objectSpread({\n overflow: 'hidden'\n }, isSticky ? {\n top: offsetHeader\n } : {}),\n onScroll: onScroll,\n ref: scrollHeaderRef,\n className: classNames(\"\".concat(prefixCls, \"-header\"), _defineProperty({}, stickyClassName, !!stickyClassName))\n }, React.createElement(FixedHeader, Object.assign({\n noData: !mergedData.length\n }, headerProps, columnContext, {\n direction: direction\n }))), bodyContent);\n } else {\n groupTableNode = React.createElement(\"div\", {\n style: _objectSpread(_objectSpread({}, scrollXStyle), scrollYStyle),\n className: classNames(\"\".concat(prefixCls, \"-content\")),\n onScroll: onScroll,\n ref: scrollBodyRef\n }, React.createElement(TableComponent, {\n style: _objectSpread(_objectSpread({}, scrollTableStyle), {}, {\n tableLayout: mergedTableLayout\n })\n }, bodyColGroup, showHeader !== false && React.createElement(Header, Object.assign({}, headerProps, columnContext)), bodyTable, footerTable));\n }\n\n var ariaProps = getDataAndAriaProps(props);\n var fullTable = React.createElement(\"div\", Object.assign({\n className: classNames(prefixCls, className, (_classNames2 = {}, _defineProperty(_classNames2, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-ping-left\"), pingedLeft), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-ping-right\"), pingedRight), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-layout-fixed\"), tableLayout === 'fixed'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-fixed-header\"), fixHeader), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-fixed-column\"), fixColumn), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-scroll-horizontal\"), horizonScroll), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-has-fix-left\"), flattenColumns[0] && flattenColumns[0].fixed), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-has-fix-right\"), flattenColumns[flattenColumns.length - 1] && flattenColumns[flattenColumns.length - 1].fixed === 'right'), _classNames2)),\n style: style,\n id: id,\n ref: fullTableRef\n }, ariaProps), React.createElement(MemoTableContent, {\n pingLeft: pingedLeft,\n pingRight: pingedRight,\n props: _objectSpread(_objectSpread({}, props), {}, {\n stickyOffsets: stickyOffsets,\n mergedExpandedKeys: mergedExpandedKeys\n })\n }, title && React.createElement(Panel, {\n className: \"\".concat(prefixCls, \"-title\")\n }, title(mergedData)), React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-container\")\n }, groupTableNode), footer && React.createElement(Panel, {\n className: \"\".concat(prefixCls, \"-footer\")\n }, footer(mergedData))));\n\n if (horizonScroll) {\n fullTable = React.createElement(ResizeObserver, {\n onResize: onFullTableResize\n }, fullTable);\n }\n\n var TableContextValue = React.useMemo(function () {\n return {\n prefixCls: prefixCls,\n getComponent: getComponent,\n scrollbarSize: scrollbarSize,\n direction: direction,\n fixedInfoList: flattenColumns.map(function (_, colIndex) {\n return getCellFixedInfo(colIndex, colIndex, flattenColumns, stickyOffsets, direction);\n }),\n isSticky: isSticky\n };\n }, [prefixCls, getComponent, scrollbarSize, direction, flattenColumns, stickyOffsets, direction, isSticky]);\n var BodyContextValue = React.useMemo(function () {\n return _objectSpread(_objectSpread({}, columnContext), {}, {\n tableLayout: mergedTableLayout,\n rowClassName: rowClassName,\n expandedRowClassName: expandedRowClassName,\n componentWidth: componentWidth,\n fixHeader: fixHeader,\n fixColumn: fixColumn,\n horizonScroll: horizonScroll,\n expandIcon: mergedExpandIcon,\n expandableType: expandableType,\n expandRowByClick: expandRowByClick,\n expandedRowRender: expandedRowRender,\n onTriggerExpand: onTriggerExpand,\n expandIconColumnIndex: expandIconColumnIndex,\n indentSize: indentSize\n });\n }, [columnContext, mergedTableLayout, rowClassName, expandedRowClassName, componentWidth, fixHeader, fixColumn, horizonScroll, mergedExpandIcon, expandableType, expandRowByClick, expandedRowRender, onTriggerExpand, expandIconColumnIndex, indentSize]);\n var ResizeContextValue = React.useMemo(function () {\n return {\n onColumnResize: onColumnResize\n };\n }, [onColumnResize]);\n return React.createElement(TableContext.Provider, {\n value: TableContextValue\n }, React.createElement(BodyContext.Provider, {\n value: BodyContextValue\n }, React.createElement(ResizeContext.Provider, {\n value: ResizeContextValue\n }, fullTable)));\n}\n\nTable.Column = Column;\nTable.ColumnGroup = ColumnGroup;\nTable.Summary = FooterComponents;\nTable.defaultProps = {\n rowKey: 'key',\n prefixCls: 'rc-table',\n emptyText: function emptyText() {\n return 'No Data';\n }\n};\nexport default Table;","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport * as React from 'react';\nexport default function useSticky(sticky, prefixCls) {\n return React.useMemo(function () {\n var isSticky = !!sticky;\n return {\n isSticky: isSticky,\n stickyClassName: isSticky ? \"\".concat(prefixCls, \"-sticky-header\") : '',\n offsetHeader: _typeof(sticky) === 'object' ? sticky.offsetHeader || 0 : 0,\n offsetScroll: _typeof(sticky) === 'object' ? sticky.offsetScroll || 0 : 0\n };\n }, [sticky, prefixCls]);\n}","import Table from './Table';\nimport { FooterComponents as Summary } from './Footer';\nimport Column from './sugar/Column';\nimport ColumnGroup from './sugar/ColumnGroup';\nimport { INTERNAL_COL_DEFINE } from './utils/legacyUtil';\nexport { Summary, Column, ColumnGroup, INTERNAL_COL_DEFINE };\nexport default Table;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport debounce from 'lodash/debounce';\nimport { ConfigConsumer } from '../config-provider';\nimport { tuple } from '../_util/type';\nimport { isValidElement, cloneElement } from '../_util/reactNode';\nvar SpinSizes = tuple('small', 'default', 'large'); // Render indicator\n\nvar defaultIndicator = null;\n\nfunction renderIndicator(prefixCls, props) {\n var indicator = props.indicator;\n var dotClassName = \"\".concat(prefixCls, \"-dot\"); // should not be render default indicator when indicator value is null\n\n if (indicator === null) {\n return null;\n }\n\n if (isValidElement(indicator)) {\n return cloneElement(indicator, {\n className: classNames(indicator.props.className, dotClassName)\n });\n }\n\n if (isValidElement(defaultIndicator)) {\n return cloneElement(defaultIndicator, {\n className: classNames(defaultIndicator.props.className, dotClassName)\n });\n }\n\n return /*#__PURE__*/React.createElement(\"span\", {\n className: classNames(dotClassName, \"\".concat(prefixCls, \"-dot-spin\"))\n }, /*#__PURE__*/React.createElement(\"i\", {\n className: \"\".concat(prefixCls, \"-dot-item\")\n }), /*#__PURE__*/React.createElement(\"i\", {\n className: \"\".concat(prefixCls, \"-dot-item\")\n }), /*#__PURE__*/React.createElement(\"i\", {\n className: \"\".concat(prefixCls, \"-dot-item\")\n }), /*#__PURE__*/React.createElement(\"i\", {\n className: \"\".concat(prefixCls, \"-dot-item\")\n }));\n}\n\nfunction shouldDelay(spinning, delay) {\n return !!spinning && !!delay && !isNaN(Number(delay));\n}\n\nvar Spin = /*#__PURE__*/function (_React$Component) {\n _inherits(Spin, _React$Component);\n\n var _super = _createSuper(Spin);\n\n function Spin(props) {\n var _this;\n\n _classCallCheck(this, Spin);\n\n _this = _super.call(this, props);\n\n _this.debouncifyUpdateSpinning = function (props) {\n var _ref = props || _this.props,\n delay = _ref.delay;\n\n if (delay) {\n _this.cancelExistingSpin();\n\n _this.updateSpinning = debounce(_this.originalUpdateSpinning, delay);\n }\n };\n\n _this.updateSpinning = function () {\n var spinning = _this.props.spinning;\n var currentSpinning = _this.state.spinning;\n\n if (currentSpinning !== spinning) {\n _this.setState({\n spinning: spinning\n });\n }\n };\n\n _this.renderSpin = function (_ref2) {\n var _classNames;\n\n var getPrefixCls = _ref2.getPrefixCls,\n direction = _ref2.direction;\n\n var _a = _this.props,\n customizePrefixCls = _a.prefixCls,\n className = _a.className,\n size = _a.size,\n tip = _a.tip,\n wrapperClassName = _a.wrapperClassName,\n style = _a.style,\n restProps = __rest(_a, [\"prefixCls\", \"className\", \"size\", \"tip\", \"wrapperClassName\", \"style\"]);\n\n var spinning = _this.state.spinning;\n var prefixCls = getPrefixCls('spin', customizePrefixCls);\n var spinClassName = classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-sm\"), size === 'small'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-lg\"), size === 'large'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-spinning\"), spinning), _defineProperty(_classNames, \"\".concat(prefixCls, \"-show-text\"), !!tip), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _classNames), className); // fix https://fb.me/react-unknown-prop\n\n var divProps = omit(restProps, ['spinning', 'delay', 'indicator']);\n var spinElement = /*#__PURE__*/React.createElement(\"div\", _extends({}, divProps, {\n style: style,\n className: spinClassName\n }), renderIndicator(prefixCls, _this.props), tip ? /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-text\")\n }, tip) : null);\n\n if (_this.isNestedPattern()) {\n var containerClassName = classNames(\"\".concat(prefixCls, \"-container\"), _defineProperty({}, \"\".concat(prefixCls, \"-blur\"), spinning));\n return /*#__PURE__*/React.createElement(\"div\", _extends({}, divProps, {\n className: classNames(\"\".concat(prefixCls, \"-nested-loading\"), wrapperClassName)\n }), spinning && /*#__PURE__*/React.createElement(\"div\", {\n key: \"loading\"\n }, spinElement), /*#__PURE__*/React.createElement(\"div\", {\n className: containerClassName,\n key: \"container\"\n }, _this.props.children));\n }\n\n return spinElement;\n };\n\n var spinning = props.spinning,\n delay = props.delay;\n var shouldBeDelayed = shouldDelay(spinning, delay);\n _this.state = {\n spinning: spinning && !shouldBeDelayed\n };\n _this.originalUpdateSpinning = _this.updateSpinning;\n\n _this.debouncifyUpdateSpinning(props);\n\n return _this;\n }\n\n _createClass(Spin, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.updateSpinning();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {\n this.debouncifyUpdateSpinning();\n this.updateSpinning();\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n this.cancelExistingSpin();\n }\n }, {\n key: \"cancelExistingSpin\",\n value: function cancelExistingSpin() {\n var updateSpinning = this.updateSpinning;\n\n if (updateSpinning && updateSpinning.cancel) {\n updateSpinning.cancel();\n }\n }\n }, {\n key: \"isNestedPattern\",\n value: function isNestedPattern() {\n return !!(this.props && this.props.children);\n }\n }, {\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderSpin);\n }\n }], [{\n key: \"setDefaultIndicator\",\n value: function setDefaultIndicator(indicator) {\n defaultIndicator = indicator;\n }\n }]);\n\n return Spin;\n}(React.Component);\n\nSpin.defaultProps = {\n spinning: true,\n size: 'default',\n wrapperClassName: ''\n};\nexport default Spin;","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\n\n/* eslint react/prop-types: 0 */\nimport React from 'react';\nimport classNames from 'classnames';\n\nvar Pager = function Pager(props) {\n var _classNames;\n\n var prefixCls = \"\".concat(props.rootPrefixCls, \"-item\");\n var cls = classNames(prefixCls, \"\".concat(prefixCls, \"-\").concat(props.page), (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-active\"), props.active), _defineProperty(_classNames, props.className, !!props.className), _defineProperty(_classNames, \"\".concat(prefixCls, \"-disabled\"), !props.page), _classNames));\n\n var handleClick = function handleClick() {\n props.onClick(props.page);\n };\n\n var handleKeyPress = function handleKeyPress(e) {\n props.onKeyPress(e, props.onClick, props.page);\n };\n\n return /*#__PURE__*/React.createElement(\"li\", {\n title: props.showTitle ? props.page : null,\n className: cls,\n onClick: handleClick,\n onKeyPress: handleKeyPress,\n tabIndex: \"0\"\n }, props.itemRender(props.page, 'page', /*#__PURE__*/React.createElement(\"a\", {\n rel: \"nofollow\"\n }, props.page)));\n};\n\nexport default Pager;","export default {\n ZERO: 48,\n NINE: 57,\n NUMPAD_ZERO: 96,\n NUMPAD_NINE: 105,\n BACKSPACE: 8,\n DELETE: 46,\n ENTER: 13,\n ARROW_UP: 38,\n ARROW_DOWN: 40\n};","import _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nimport _getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\n/* eslint react/prop-types: 0 */\nimport React from 'react';\nimport KEYCODE from './KeyCode';\n\nvar Options = /*#__PURE__*/function (_React$Component) {\n _inherits(Options, _React$Component);\n\n var _super = _createSuper(Options);\n\n function Options() {\n var _this;\n\n _classCallCheck(this, Options);\n\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n _this = _super.call.apply(_super, [this].concat(args));\n _this.state = {\n goInputText: ''\n };\n\n _this.buildOptionText = function (value) {\n return \"\".concat(value, \" \").concat(_this.props.locale.items_per_page);\n };\n\n _this.changeSize = function (value) {\n _this.props.changeSize(Number(value));\n };\n\n _this.handleChange = function (e) {\n _this.setState({\n goInputText: e.target.value\n });\n };\n\n _this.handleBlur = function (e) {\n var _this$props = _this.props,\n goButton = _this$props.goButton,\n quickGo = _this$props.quickGo,\n rootPrefixCls = _this$props.rootPrefixCls;\n var goInputText = _this.state.goInputText;\n\n if (goButton || goInputText === '') {\n return;\n }\n\n if (e.relatedTarget && (e.relatedTarget.className.indexOf(\"\".concat(rootPrefixCls, \"-prev\")) >= 0 || e.relatedTarget.className.indexOf(\"\".concat(rootPrefixCls, \"-next\")) >= 0)) {\n return;\n }\n\n _this.setState({\n goInputText: ''\n });\n\n quickGo(_this.getValidValue());\n };\n\n _this.go = function (e) {\n var goInputText = _this.state.goInputText;\n\n if (goInputText === '') {\n return;\n }\n\n if (e.keyCode === KEYCODE.ENTER || e.type === 'click') {\n _this.setState({\n goInputText: ''\n });\n\n _this.props.quickGo(_this.getValidValue());\n }\n };\n\n return _this;\n }\n\n _createClass(Options, [{\n key: \"getValidValue\",\n value: function getValidValue() {\n var _this$state = this.state,\n goInputText = _this$state.goInputText,\n current = _this$state.current; // eslint-disable-next-line no-restricted-globals\n\n return !goInputText || isNaN(goInputText) ? current : Number(goInputText);\n }\n }, {\n key: \"getPageSizeOptions\",\n value: function getPageSizeOptions() {\n var _this$props2 = this.props,\n pageSize = _this$props2.pageSize,\n pageSizeOptions = _this$props2.pageSizeOptions;\n\n if (pageSizeOptions.some(function (option) {\n return option.toString() === pageSize.toString();\n })) {\n return pageSizeOptions;\n }\n\n return pageSizeOptions.concat([pageSize.toString()]).sort(function (a, b) {\n // eslint-disable-next-line no-restricted-globals\n var numberA = isNaN(Number(a)) ? 0 : Number(a); // eslint-disable-next-line no-restricted-globals\n\n var numberB = isNaN(Number(b)) ? 0 : Number(b);\n return numberA - numberB;\n });\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this2 = this;\n\n var _this$props3 = this.props,\n pageSize = _this$props3.pageSize,\n locale = _this$props3.locale,\n rootPrefixCls = _this$props3.rootPrefixCls,\n changeSize = _this$props3.changeSize,\n quickGo = _this$props3.quickGo,\n goButton = _this$props3.goButton,\n selectComponentClass = _this$props3.selectComponentClass,\n buildOptionText = _this$props3.buildOptionText,\n selectPrefixCls = _this$props3.selectPrefixCls,\n disabled = _this$props3.disabled;\n var goInputText = this.state.goInputText;\n var prefixCls = \"\".concat(rootPrefixCls, \"-options\");\n var Select = selectComponentClass;\n var changeSelect = null;\n var goInput = null;\n var gotoButton = null;\n\n if (!changeSize && !quickGo) {\n return null;\n }\n\n var pageSizeOptions = this.getPageSizeOptions();\n\n if (changeSize && Select) {\n var options = pageSizeOptions.map(function (opt, i) {\n return /*#__PURE__*/React.createElement(Select.Option, {\n key: i,\n value: opt\n }, (buildOptionText || _this2.buildOptionText)(opt));\n });\n changeSelect = /*#__PURE__*/React.createElement(Select, {\n disabled: disabled,\n prefixCls: selectPrefixCls,\n showSearch: false,\n className: \"\".concat(prefixCls, \"-size-changer\"),\n optionLabelProp: \"children\",\n dropdownMatchSelectWidth: false,\n value: (pageSize || pageSizeOptions[0]).toString(),\n onChange: this.changeSize,\n getPopupContainer: function getPopupContainer(triggerNode) {\n return triggerNode.parentNode;\n }\n }, options);\n }\n\n if (quickGo) {\n if (goButton) {\n gotoButton = typeof goButton === 'boolean' ? /*#__PURE__*/React.createElement(\"button\", {\n type: \"button\",\n onClick: this.go,\n onKeyUp: this.go,\n disabled: disabled,\n className: \"\".concat(prefixCls, \"-quick-jumper-button\")\n }, locale.jump_to_confirm) : /*#__PURE__*/React.createElement(\"span\", {\n onClick: this.go,\n onKeyUp: this.go\n }, goButton);\n }\n\n goInput = /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-quick-jumper\")\n }, locale.jump_to, /*#__PURE__*/React.createElement(\"input\", {\n disabled: disabled,\n type: \"text\",\n value: goInputText,\n onChange: this.handleChange,\n onKeyUp: this.go,\n onBlur: this.handleBlur\n }), locale.page, gotoButton);\n }\n\n return /*#__PURE__*/React.createElement(\"li\", {\n className: \"\".concat(prefixCls)\n }, changeSelect, goInput);\n }\n }]);\n\n return Options;\n}(React.Component);\n\nOptions.defaultProps = {\n pageSizeOptions: ['10', '20', '50', '100']\n};\nexport default Options;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nimport _getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\n/* eslint react/prop-types: 0 */\nimport React, { cloneElement, isValidElement } from 'react';\nimport classNames from 'classnames';\nimport Pager from './Pager';\nimport Options from './Options';\nimport KEYCODE from './KeyCode';\nimport LOCALE from './locale/zh_CN';\n\nfunction noop() {}\n\nfunction isInteger(value) {\n return (// eslint-disable-next-line no-restricted-globals\n typeof value === 'number' && isFinite(value) && Math.floor(value) === value\n );\n}\n\nfunction defaultItemRender(page, type, element) {\n return element;\n}\n\nfunction calculatePage(p, state, props) {\n var pageSize = typeof p === 'undefined' ? state.pageSize : p;\n return Math.floor((props.total - 1) / pageSize) + 1;\n}\n\nvar Pagination = /*#__PURE__*/function (_React$Component) {\n _inherits(Pagination, _React$Component);\n\n var _super = _createSuper(Pagination);\n\n function Pagination(props) {\n var _this;\n\n _classCallCheck(this, Pagination);\n\n _this = _super.call(this, props);\n\n _this.getJumpPrevPage = function () {\n return Math.max(1, _this.state.current - (_this.props.showLessItems ? 3 : 5));\n };\n\n _this.getJumpNextPage = function () {\n return Math.min(calculatePage(undefined, _this.state, _this.props), _this.state.current + (_this.props.showLessItems ? 3 : 5));\n };\n\n _this.getItemIcon = function (icon, label) {\n var prefixCls = _this.props.prefixCls;\n var iconNode = icon || /*#__PURE__*/React.createElement(\"button\", {\n type: \"button\",\n \"aria-label\": label,\n className: \"\".concat(prefixCls, \"-item-link\")\n });\n\n if (typeof icon === 'function') {\n iconNode = React.createElement(icon, _objectSpread({}, _this.props));\n }\n\n return iconNode;\n };\n\n _this.savePaginationNode = function (node) {\n _this.paginationNode = node;\n };\n\n _this.isValid = function (page) {\n return isInteger(page) && page !== _this.state.current;\n };\n\n _this.shouldDisplayQuickJumper = function () {\n var _this$props = _this.props,\n showQuickJumper = _this$props.showQuickJumper,\n pageSize = _this$props.pageSize,\n total = _this$props.total;\n\n if (total <= pageSize) {\n return false;\n }\n\n return showQuickJumper;\n };\n\n _this.handleKeyDown = function (e) {\n if (e.keyCode === KEYCODE.ARROW_UP || e.keyCode === KEYCODE.ARROW_DOWN) {\n e.preventDefault();\n }\n };\n\n _this.handleKeyUp = function (e) {\n var value = _this.getValidValue(e);\n\n var currentInputValue = _this.state.currentInputValue;\n\n if (value !== currentInputValue) {\n _this.setState({\n currentInputValue: value\n });\n }\n\n if (e.keyCode === KEYCODE.ENTER) {\n _this.handleChange(value);\n } else if (e.keyCode === KEYCODE.ARROW_UP) {\n _this.handleChange(value - 1);\n } else if (e.keyCode === KEYCODE.ARROW_DOWN) {\n _this.handleChange(value + 1);\n }\n };\n\n _this.changePageSize = function (size) {\n var current = _this.state.current;\n var newCurrent = calculatePage(size, _this.state, _this.props);\n current = current > newCurrent ? newCurrent : current; // fix the issue:\n // Once 'total' is 0, 'current' in 'onShowSizeChange' is 0, which is not correct.\n\n if (newCurrent === 0) {\n // eslint-disable-next-line prefer-destructuring\n current = _this.state.current;\n }\n\n if (typeof size === 'number') {\n if (!('pageSize' in _this.props)) {\n _this.setState({\n pageSize: size\n });\n }\n\n if (!('current' in _this.props)) {\n _this.setState({\n current: current,\n currentInputValue: current\n });\n }\n }\n\n _this.props.onShowSizeChange(current, size);\n\n if ('onChange' in _this.props && _this.props.onChange) {\n _this.props.onChange(current, size);\n }\n };\n\n _this.handleChange = function (p) {\n var disabled = _this.props.disabled;\n var page = p;\n\n if (_this.isValid(page) && !disabled) {\n var currentPage = calculatePage(undefined, _this.state, _this.props);\n\n if (page > currentPage) {\n page = currentPage;\n } else if (page < 1) {\n page = 1;\n }\n\n if (!('current' in _this.props)) {\n _this.setState({\n current: page,\n currentInputValue: page\n });\n }\n\n var pageSize = _this.state.pageSize;\n\n _this.props.onChange(page, pageSize);\n\n return page;\n }\n\n return _this.state.current;\n };\n\n _this.prev = function () {\n if (_this.hasPrev()) {\n _this.handleChange(_this.state.current - 1);\n }\n };\n\n _this.next = function () {\n if (_this.hasNext()) {\n _this.handleChange(_this.state.current + 1);\n }\n };\n\n _this.jumpPrev = function () {\n _this.handleChange(_this.getJumpPrevPage());\n };\n\n _this.jumpNext = function () {\n _this.handleChange(_this.getJumpNextPage());\n };\n\n _this.hasPrev = function () {\n return _this.state.current > 1;\n };\n\n _this.hasNext = function () {\n return _this.state.current < calculatePage(undefined, _this.state, _this.props);\n };\n\n _this.runIfEnter = function (event, callback) {\n if (event.key === 'Enter' || event.charCode === 13) {\n for (var _len = arguments.length, restParams = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {\n restParams[_key - 2] = arguments[_key];\n }\n\n callback.apply(void 0, restParams);\n }\n };\n\n _this.runIfEnterPrev = function (e) {\n _this.runIfEnter(e, _this.prev);\n };\n\n _this.runIfEnterNext = function (e) {\n _this.runIfEnter(e, _this.next);\n };\n\n _this.runIfEnterJumpPrev = function (e) {\n _this.runIfEnter(e, _this.jumpPrev);\n };\n\n _this.runIfEnterJumpNext = function (e) {\n _this.runIfEnter(e, _this.jumpNext);\n };\n\n _this.handleGoTO = function (e) {\n if (e.keyCode === KEYCODE.ENTER || e.type === 'click') {\n _this.handleChange(_this.state.currentInputValue);\n }\n };\n\n var hasOnChange = props.onChange !== noop;\n var hasCurrent = ('current' in props);\n\n if (hasCurrent && !hasOnChange) {\n // eslint-disable-next-line no-console\n console.warn('Warning: You provided a `current` prop to a Pagination component without an `onChange` handler. This will render a read-only component.');\n }\n\n var _current = props.defaultCurrent;\n\n if ('current' in props) {\n // eslint-disable-next-line prefer-destructuring\n _current = props.current;\n }\n\n var _pageSize = props.defaultPageSize;\n\n if ('pageSize' in props) {\n // eslint-disable-next-line prefer-destructuring\n _pageSize = props.pageSize;\n }\n\n _current = Math.min(_current, calculatePage(_pageSize, undefined, props));\n _this.state = {\n current: _current,\n currentInputValue: _current,\n pageSize: _pageSize\n };\n return _this;\n }\n\n _createClass(Pagination, [{\n key: \"componentDidUpdate\",\n value: function componentDidUpdate(prevProps, prevState) {\n // When current page change, fix focused style of prev item\n // A hacky solution of https://github.com/ant-design/ant-design/issues/8948\n var prefixCls = this.props.prefixCls;\n\n if (prevState.current !== this.state.current && this.paginationNode) {\n var lastCurrentNode = this.paginationNode.querySelector(\".\".concat(prefixCls, \"-item-\").concat(prevState.current));\n\n if (lastCurrentNode && document.activeElement === lastCurrentNode) {\n lastCurrentNode.blur();\n }\n }\n }\n }, {\n key: \"getValidValue\",\n value: function getValidValue(e) {\n var inputValue = e.target.value;\n var allPages = calculatePage(undefined, this.state, this.props);\n var currentInputValue = this.state.currentInputValue;\n var value;\n\n if (inputValue === '') {\n value = inputValue; // eslint-disable-next-line no-restricted-globals\n } else if (isNaN(Number(inputValue))) {\n value = currentInputValue;\n } else if (inputValue >= allPages) {\n value = allPages;\n } else {\n value = Number(inputValue);\n }\n\n return value;\n }\n }, {\n key: \"getShowSizeChanger\",\n value: function getShowSizeChanger() {\n var _this$props2 = this.props,\n showSizeChanger = _this$props2.showSizeChanger,\n total = _this$props2.total,\n totalBoundaryShowSizeChanger = _this$props2.totalBoundaryShowSizeChanger;\n\n if (typeof showSizeChanger !== 'undefined') {\n return showSizeChanger;\n }\n\n return total > totalBoundaryShowSizeChanger;\n }\n }, {\n key: \"renderPrev\",\n value: function renderPrev(prevPage) {\n var _this$props3 = this.props,\n prevIcon = _this$props3.prevIcon,\n itemRender = _this$props3.itemRender;\n var prevButton = itemRender(prevPage, 'prev', this.getItemIcon(prevIcon, 'prev page'));\n var disabled = !this.hasPrev();\n return isValidElement(prevButton) ? cloneElement(prevButton, {\n disabled: disabled\n }) : prevButton;\n }\n }, {\n key: \"renderNext\",\n value: function renderNext(nextPage) {\n var _this$props4 = this.props,\n nextIcon = _this$props4.nextIcon,\n itemRender = _this$props4.itemRender;\n var nextButton = itemRender(nextPage, 'next', this.getItemIcon(nextIcon, 'next page'));\n var disabled = !this.hasNext();\n return isValidElement(nextButton) ? cloneElement(nextButton, {\n disabled: disabled\n }) : nextButton;\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this2 = this;\n\n var _this$props5 = this.props,\n prefixCls = _this$props5.prefixCls,\n className = _this$props5.className,\n style = _this$props5.style,\n disabled = _this$props5.disabled,\n hideOnSinglePage = _this$props5.hideOnSinglePage,\n total = _this$props5.total,\n locale = _this$props5.locale,\n showQuickJumper = _this$props5.showQuickJumper,\n showLessItems = _this$props5.showLessItems,\n showTitle = _this$props5.showTitle,\n showTotal = _this$props5.showTotal,\n simple = _this$props5.simple,\n itemRender = _this$props5.itemRender,\n showPrevNextJumpers = _this$props5.showPrevNextJumpers,\n jumpPrevIcon = _this$props5.jumpPrevIcon,\n jumpNextIcon = _this$props5.jumpNextIcon,\n selectComponentClass = _this$props5.selectComponentClass,\n selectPrefixCls = _this$props5.selectPrefixCls,\n pageSizeOptions = _this$props5.pageSizeOptions;\n var _this$state = this.state,\n current = _this$state.current,\n pageSize = _this$state.pageSize,\n currentInputValue = _this$state.currentInputValue; // When hideOnSinglePage is true and there is only 1 page, hide the pager\n\n if (hideOnSinglePage === true && total <= pageSize) {\n return null;\n }\n\n var allPages = calculatePage(undefined, this.state, this.props);\n var pagerList = [];\n var jumpPrev = null;\n var jumpNext = null;\n var firstPager = null;\n var lastPager = null;\n var gotoButton = null;\n var goButton = showQuickJumper && showQuickJumper.goButton;\n var pageBufferSize = showLessItems ? 1 : 2;\n var prevPage = current - 1 > 0 ? current - 1 : 0;\n var nextPage = current + 1 < allPages ? current + 1 : allPages;\n var dataOrAriaAttributeProps = Object.keys(this.props).reduce(function (prev, key) {\n if (key.substr(0, 5) === 'data-' || key.substr(0, 5) === 'aria-' || key === 'role') {\n // eslint-disable-next-line no-param-reassign\n prev[key] = _this2.props[key];\n }\n\n return prev;\n }, {});\n\n if (simple) {\n if (goButton) {\n if (typeof goButton === 'boolean') {\n gotoButton = /*#__PURE__*/React.createElement(\"button\", {\n type: \"button\",\n onClick: this.handleGoTO,\n onKeyUp: this.handleGoTO\n }, locale.jump_to_confirm);\n } else {\n gotoButton = /*#__PURE__*/React.createElement(\"span\", {\n onClick: this.handleGoTO,\n onKeyUp: this.handleGoTO\n }, goButton);\n }\n\n gotoButton = /*#__PURE__*/React.createElement(\"li\", {\n title: showTitle ? \"\".concat(locale.jump_to).concat(current, \"/\").concat(allPages) : null,\n className: \"\".concat(prefixCls, \"-simple-pager\")\n }, gotoButton);\n }\n\n return /*#__PURE__*/React.createElement(\"ul\", _extends({\n className: classNames(prefixCls, \"\".concat(prefixCls, \"-simple\"), _defineProperty({}, \"\".concat(prefixCls, \"-disabled\"), disabled), className),\n style: style,\n ref: this.savePaginationNode\n }, dataOrAriaAttributeProps), /*#__PURE__*/React.createElement(\"li\", {\n title: showTitle ? locale.prev_page : null,\n onClick: this.prev,\n tabIndex: this.hasPrev() ? 0 : null,\n onKeyPress: this.runIfEnterPrev,\n className: classNames(\"\".concat(prefixCls, \"-prev\"), _defineProperty({}, \"\".concat(prefixCls, \"-disabled\"), !this.hasPrev())),\n \"aria-disabled\": !this.hasPrev()\n }, this.renderPrev(prevPage)), /*#__PURE__*/React.createElement(\"li\", {\n title: showTitle ? \"\".concat(current, \"/\").concat(allPages) : null,\n className: \"\".concat(prefixCls, \"-simple-pager\")\n }, /*#__PURE__*/React.createElement(\"input\", {\n type: \"text\",\n value: currentInputValue,\n disabled: disabled,\n onKeyDown: this.handleKeyDown,\n onKeyUp: this.handleKeyUp,\n onChange: this.handleKeyUp,\n size: \"3\"\n }), /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-slash\")\n }, \"/\"), allPages), /*#__PURE__*/React.createElement(\"li\", {\n title: showTitle ? locale.next_page : null,\n onClick: this.next,\n tabIndex: this.hasPrev() ? 0 : null,\n onKeyPress: this.runIfEnterNext,\n className: classNames(\"\".concat(prefixCls, \"-next\"), _defineProperty({}, \"\".concat(prefixCls, \"-disabled\"), !this.hasNext())),\n \"aria-disabled\": !this.hasNext()\n }, this.renderNext(nextPage)), gotoButton);\n }\n\n if (allPages <= 3 + pageBufferSize * 2) {\n var pagerProps = {\n locale: locale,\n rootPrefixCls: prefixCls,\n onClick: this.handleChange,\n onKeyPress: this.runIfEnter,\n showTitle: showTitle,\n itemRender: itemRender\n };\n\n if (!allPages) {\n pagerList.push( /*#__PURE__*/React.createElement(Pager, _extends({}, pagerProps, {\n key: \"noPager\",\n page: allPages,\n className: \"\".concat(prefixCls, \"-disabled\")\n })));\n }\n\n for (var i = 1; i <= allPages; i += 1) {\n var active = current === i;\n pagerList.push( /*#__PURE__*/React.createElement(Pager, _extends({}, pagerProps, {\n key: i,\n page: i,\n active: active\n })));\n }\n } else {\n var prevItemTitle = showLessItems ? locale.prev_3 : locale.prev_5;\n var nextItemTitle = showLessItems ? locale.next_3 : locale.next_5;\n\n if (showPrevNextJumpers) {\n jumpPrev = /*#__PURE__*/React.createElement(\"li\", {\n title: showTitle ? prevItemTitle : null,\n key: \"prev\",\n onClick: this.jumpPrev,\n tabIndex: \"0\",\n onKeyPress: this.runIfEnterJumpPrev,\n className: classNames(\"\".concat(prefixCls, \"-jump-prev\"), _defineProperty({}, \"\".concat(prefixCls, \"-jump-prev-custom-icon\"), !!jumpPrevIcon))\n }, itemRender(this.getJumpPrevPage(), 'jump-prev', this.getItemIcon(jumpPrevIcon, 'prev page')));\n jumpNext = /*#__PURE__*/React.createElement(\"li\", {\n title: showTitle ? nextItemTitle : null,\n key: \"next\",\n tabIndex: \"0\",\n onClick: this.jumpNext,\n onKeyPress: this.runIfEnterJumpNext,\n className: classNames(\"\".concat(prefixCls, \"-jump-next\"), _defineProperty({}, \"\".concat(prefixCls, \"-jump-next-custom-icon\"), !!jumpNextIcon))\n }, itemRender(this.getJumpNextPage(), 'jump-next', this.getItemIcon(jumpNextIcon, 'next page')));\n }\n\n lastPager = /*#__PURE__*/React.createElement(Pager, {\n locale: locale,\n last: true,\n rootPrefixCls: prefixCls,\n onClick: this.handleChange,\n onKeyPress: this.runIfEnter,\n key: allPages,\n page: allPages,\n active: false,\n showTitle: showTitle,\n itemRender: itemRender\n });\n firstPager = /*#__PURE__*/React.createElement(Pager, {\n locale: locale,\n rootPrefixCls: prefixCls,\n onClick: this.handleChange,\n onKeyPress: this.runIfEnter,\n key: 1,\n page: 1,\n active: false,\n showTitle: showTitle,\n itemRender: itemRender\n });\n var left = Math.max(1, current - pageBufferSize);\n var right = Math.min(current + pageBufferSize, allPages);\n\n if (current - 1 <= pageBufferSize) {\n right = 1 + pageBufferSize * 2;\n }\n\n if (allPages - current <= pageBufferSize) {\n left = allPages - pageBufferSize * 2;\n }\n\n for (var _i = left; _i <= right; _i += 1) {\n var _active = current === _i;\n\n pagerList.push( /*#__PURE__*/React.createElement(Pager, {\n locale: locale,\n rootPrefixCls: prefixCls,\n onClick: this.handleChange,\n onKeyPress: this.runIfEnter,\n key: _i,\n page: _i,\n active: _active,\n showTitle: showTitle,\n itemRender: itemRender\n }));\n }\n\n if (current - 1 >= pageBufferSize * 2 && current !== 1 + 2) {\n pagerList[0] = cloneElement(pagerList[0], {\n className: \"\".concat(prefixCls, \"-item-after-jump-prev\")\n });\n pagerList.unshift(jumpPrev);\n }\n\n if (allPages - current >= pageBufferSize * 2 && current !== allPages - 2) {\n pagerList[pagerList.length - 1] = cloneElement(pagerList[pagerList.length - 1], {\n className: \"\".concat(prefixCls, \"-item-before-jump-next\")\n });\n pagerList.push(jumpNext);\n }\n\n if (left !== 1) {\n pagerList.unshift(firstPager);\n }\n\n if (right !== allPages) {\n pagerList.push(lastPager);\n }\n }\n\n var totalText = null;\n\n if (showTotal) {\n totalText = /*#__PURE__*/React.createElement(\"li\", {\n className: \"\".concat(prefixCls, \"-total-text\")\n }, showTotal(total, [total === 0 ? 0 : (current - 1) * pageSize + 1, current * pageSize > total ? total : current * pageSize]));\n }\n\n var prevDisabled = !this.hasPrev() || !allPages;\n var nextDisabled = !this.hasNext() || !allPages;\n return /*#__PURE__*/React.createElement(\"ul\", _extends({\n className: classNames(prefixCls, className, _defineProperty({}, \"\".concat(prefixCls, \"-disabled\"), disabled)),\n style: style,\n unselectable: \"unselectable\",\n ref: this.savePaginationNode\n }, dataOrAriaAttributeProps), totalText, /*#__PURE__*/React.createElement(\"li\", {\n title: showTitle ? locale.prev_page : null,\n onClick: this.prev,\n tabIndex: prevDisabled ? null : 0,\n onKeyPress: this.runIfEnterPrev,\n className: classNames(\"\".concat(prefixCls, \"-prev\"), _defineProperty({}, \"\".concat(prefixCls, \"-disabled\"), prevDisabled)),\n \"aria-disabled\": prevDisabled\n }, this.renderPrev(prevPage)), pagerList, /*#__PURE__*/React.createElement(\"li\", {\n title: showTitle ? locale.next_page : null,\n onClick: this.next,\n tabIndex: nextDisabled ? null : 0,\n onKeyPress: this.runIfEnterNext,\n className: classNames(\"\".concat(prefixCls, \"-next\"), _defineProperty({}, \"\".concat(prefixCls, \"-disabled\"), nextDisabled)),\n \"aria-disabled\": nextDisabled\n }, this.renderNext(nextPage)), /*#__PURE__*/React.createElement(Options, {\n disabled: disabled,\n locale: locale,\n rootPrefixCls: prefixCls,\n selectComponentClass: selectComponentClass,\n selectPrefixCls: selectPrefixCls,\n changeSize: this.getShowSizeChanger() ? this.changePageSize : null,\n current: current,\n pageSize: pageSize,\n pageSizeOptions: pageSizeOptions,\n quickGo: this.shouldDisplayQuickJumper() ? this.handleChange : null,\n goButton: goButton\n }));\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(props, prevState) {\n var newState = {};\n\n if ('current' in props) {\n newState.current = props.current;\n\n if (props.current !== prevState.current) {\n newState.currentInputValue = newState.current;\n }\n }\n\n if ('pageSize' in props && props.pageSize !== prevState.pageSize) {\n var current = prevState.current;\n var newCurrent = calculatePage(props.pageSize, prevState, props);\n current = current > newCurrent ? newCurrent : current;\n\n if (!('current' in props)) {\n newState.current = current;\n newState.currentInputValue = current;\n }\n\n newState.pageSize = props.pageSize;\n }\n\n return newState;\n }\n }]);\n\n return Pagination;\n}(React.Component);\n\nPagination.defaultProps = {\n defaultCurrent: 1,\n total: 0,\n defaultPageSize: 10,\n onChange: noop,\n className: '',\n selectPrefixCls: 'rc-select',\n prefixCls: 'rc-pagination',\n selectComponentClass: null,\n hideOnSinglePage: false,\n showPrevNextJumpers: true,\n showQuickJumper: false,\n showLessItems: false,\n showTitle: true,\n onShowSizeChange: noop,\n locale: LOCALE,\n style: {},\n itemRender: defaultItemRender,\n totalBoundaryShowSizeChanger: 50\n};\nexport default Pagination;","export default {\n // Options.jsx\n items_per_page: '条/页',\n jump_to: '跳至',\n jump_to_confirm: '确定',\n page: '页',\n // Pagination.jsx\n prev_page: '上一页',\n next_page: '下一页',\n prev_5: '向前 5 页',\n next_5: '向后 5 页',\n prev_3: '向前 3 页',\n next_3: '向后 3 页'\n};","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport * as React from 'react';\nimport KeyCode from \"rc-util/es/KeyCode\";\nimport pickAttrs from \"rc-util/es/pickAttrs\";\nimport useMemo from \"rc-util/es/hooks/useMemo\";\nimport classNames from 'classnames';\nimport List from 'rc-virtual-list';\nimport TransBtn from './TransBtn';\n/**\n * Using virtual list of option display.\n * Will fallback to dom if use customize render.\n */\n\nvar OptionList = function OptionList(_ref, ref) {\n var prefixCls = _ref.prefixCls,\n id = _ref.id,\n flattenOptions = _ref.flattenOptions,\n childrenAsData = _ref.childrenAsData,\n values = _ref.values,\n searchValue = _ref.searchValue,\n multiple = _ref.multiple,\n defaultActiveFirstOption = _ref.defaultActiveFirstOption,\n height = _ref.height,\n itemHeight = _ref.itemHeight,\n notFoundContent = _ref.notFoundContent,\n open = _ref.open,\n menuItemSelectedIcon = _ref.menuItemSelectedIcon,\n virtual = _ref.virtual,\n onSelect = _ref.onSelect,\n onToggleOpen = _ref.onToggleOpen,\n onActiveValue = _ref.onActiveValue,\n onScroll = _ref.onScroll,\n onMouseEnter = _ref.onMouseEnter;\n var itemPrefixCls = \"\".concat(prefixCls, \"-item\");\n var memoFlattenOptions = useMemo(function () {\n return flattenOptions;\n }, [open, flattenOptions], function (prev, next) {\n return next[0] && prev[1] !== next[1];\n }); // =========================== List ===========================\n\n var listRef = React.useRef(null);\n\n var onListMouseDown = function onListMouseDown(event) {\n event.preventDefault();\n };\n\n var scrollIntoView = function scrollIntoView(index) {\n if (listRef.current) {\n listRef.current.scrollTo({\n index: index\n });\n }\n }; // ========================== Active ==========================\n\n\n var getEnabledActiveIndex = function getEnabledActiveIndex(index) {\n var offset = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;\n var len = memoFlattenOptions.length;\n\n for (var i = 0; i < len; i += 1) {\n var current = (index + i * offset + len) % len;\n var _memoFlattenOptions$c = memoFlattenOptions[current],\n group = _memoFlattenOptions$c.group,\n data = _memoFlattenOptions$c.data;\n\n if (!group && !data.disabled) {\n return current;\n }\n }\n\n return -1;\n };\n\n var _React$useState = React.useState(function () {\n return getEnabledActiveIndex(0);\n }),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n activeIndex = _React$useState2[0],\n setActiveIndex = _React$useState2[1];\n\n var setActive = function setActive(index) {\n setActiveIndex(index); // Trigger active event\n\n var flattenItem = memoFlattenOptions[index];\n\n if (!flattenItem) {\n onActiveValue(null, -1);\n return;\n }\n\n onActiveValue(flattenItem.data.value, index);\n }; // Auto active first item when list length or searchValue changed\n\n\n React.useEffect(function () {\n setActive(defaultActiveFirstOption !== false ? getEnabledActiveIndex(0) : -1);\n }, [memoFlattenOptions.length, searchValue]); // Auto scroll to item position in single mode\n\n React.useEffect(function () {\n /**\n * React will skip `onChange` when component update.\n * `setActive` function will call root accessibility state update which makes re-render.\n * So we need to delay to let Input component trigger onChange first.\n */\n var timeoutId = setTimeout(function () {\n if (!multiple && open && values.size === 1) {\n var value = Array.from(values)[0];\n var index = memoFlattenOptions.findIndex(function (_ref2) {\n var data = _ref2.data;\n return data.value === value;\n });\n setActive(index);\n scrollIntoView(index);\n }\n });\n return function () {\n return clearTimeout(timeoutId);\n };\n }, [open]); // ========================== Values ==========================\n\n var onSelectValue = function onSelectValue(value) {\n if (value !== undefined) {\n onSelect(value, {\n selected: !values.has(value)\n });\n } // Single mode should always close by select\n\n\n if (!multiple) {\n onToggleOpen(false);\n }\n }; // ========================= Keyboard =========================\n\n\n React.useImperativeHandle(ref, function () {\n return {\n onKeyDown: function onKeyDown(event) {\n var which = event.which;\n\n switch (which) {\n // >>> Arrow keys\n case KeyCode.UP:\n case KeyCode.DOWN:\n {\n var offset = 0;\n\n if (which === KeyCode.UP) {\n offset = -1;\n } else if (which === KeyCode.DOWN) {\n offset = 1;\n }\n\n if (offset !== 0) {\n var nextActiveIndex = getEnabledActiveIndex(activeIndex + offset, offset);\n scrollIntoView(nextActiveIndex);\n setActive(nextActiveIndex);\n }\n\n break;\n }\n // >>> Select\n\n case KeyCode.ENTER:\n {\n // value\n var item = memoFlattenOptions[activeIndex];\n\n if (item && !item.data.disabled) {\n onSelectValue(item.data.value);\n } else {\n onSelectValue(undefined);\n }\n\n if (open) {\n event.preventDefault();\n }\n\n break;\n }\n // >>> Close\n\n case KeyCode.ESC:\n {\n onToggleOpen(false);\n }\n }\n },\n onKeyUp: function onKeyUp() {},\n scrollTo: function scrollTo(index) {\n scrollIntoView(index);\n }\n };\n }); // ========================== Render ==========================\n\n if (memoFlattenOptions.length === 0) {\n return React.createElement(\"div\", {\n role: \"listbox\",\n id: \"\".concat(id, \"_list\"),\n className: \"\".concat(itemPrefixCls, \"-empty\"),\n onMouseDown: onListMouseDown\n }, notFoundContent);\n }\n\n function renderItem(index) {\n var item = memoFlattenOptions[index];\n if (!item) return null;\n var itemData = item.data || {};\n var value = itemData.value,\n label = itemData.label,\n children = itemData.children;\n var attrs = pickAttrs(itemData, true);\n var mergedLabel = childrenAsData ? children : label;\n return item ? React.createElement(\"div\", Object.assign({\n \"aria-label\": typeof mergedLabel === 'string' ? mergedLabel : null\n }, attrs, {\n key: index,\n role: \"option\",\n id: \"\".concat(id, \"_list_\").concat(index),\n \"aria-selected\": values.has(value)\n }), value) : null;\n }\n\n return React.createElement(React.Fragment, null, React.createElement(\"div\", {\n role: \"listbox\",\n id: \"\".concat(id, \"_list\"),\n style: {\n height: 0,\n width: 0,\n overflow: 'hidden'\n }\n }, renderItem(activeIndex - 1), renderItem(activeIndex), renderItem(activeIndex + 1)), React.createElement(List, {\n itemKey: \"key\",\n ref: listRef,\n data: memoFlattenOptions,\n height: height,\n itemHeight: itemHeight,\n fullHeight: false,\n onMouseDown: onListMouseDown,\n onScroll: onScroll,\n virtual: virtual,\n onMouseEnter: onMouseEnter\n }, function (_ref3, itemIndex) {\n var _classNames;\n\n var group = _ref3.group,\n groupOption = _ref3.groupOption,\n data = _ref3.data;\n var label = data.label,\n key = data.key; // Group\n\n if (group) {\n return React.createElement(\"div\", {\n className: classNames(itemPrefixCls, \"\".concat(itemPrefixCls, \"-group\"))\n }, label !== undefined ? label : key);\n }\n\n var disabled = data.disabled,\n value = data.value,\n title = data.title,\n children = data.children,\n style = data.style,\n className = data.className,\n otherProps = _objectWithoutProperties(data, [\"disabled\", \"value\", \"title\", \"children\", \"style\", \"className\"]); // Option\n\n\n var selected = values.has(value);\n var optionPrefixCls = \"\".concat(itemPrefixCls, \"-option\");\n var optionClassName = classNames(itemPrefixCls, optionPrefixCls, className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(optionPrefixCls, \"-grouped\"), groupOption), _defineProperty(_classNames, \"\".concat(optionPrefixCls, \"-active\"), activeIndex === itemIndex && !disabled), _defineProperty(_classNames, \"\".concat(optionPrefixCls, \"-disabled\"), disabled), _defineProperty(_classNames, \"\".concat(optionPrefixCls, \"-selected\"), selected), _classNames));\n var mergedLabel = childrenAsData ? children : label;\n var iconVisible = !menuItemSelectedIcon || typeof menuItemSelectedIcon === 'function' || selected;\n return React.createElement(\"div\", Object.assign({}, otherProps, {\n \"aria-selected\": selected,\n className: optionClassName,\n title: title,\n onMouseMove: function onMouseMove() {\n if (activeIndex === itemIndex || disabled) {\n return;\n }\n\n setActive(itemIndex);\n },\n onClick: function onClick() {\n if (!disabled) {\n onSelectValue(value);\n }\n },\n style: style\n }), React.createElement(\"div\", {\n className: \"\".concat(optionPrefixCls, \"-content\")\n }, mergedLabel || value), React.isValidElement(menuItemSelectedIcon) || selected, iconVisible && React.createElement(TransBtn, {\n className: \"\".concat(itemPrefixCls, \"-option-state\"),\n customizeIcon: menuItemSelectedIcon,\n customizeIconProps: {\n isSelected: selected\n }\n }, selected ? '✓' : null));\n }));\n};\n\nvar RefOptionList = React.forwardRef(OptionList);\nRefOptionList.displayName = 'OptionList';\nexport default RefOptionList;","/** This is a placeholder, not real render in dom */\nvar Option = function Option() {\n return null;\n};\n\nOption.isSelectOption = true;\nexport default Option;","/** This is a placeholder, not real render in dom */\nvar OptGroup = function OptGroup() {\n return null;\n};\n\nOptGroup.isSelectOptGroup = true;\nexport default OptGroup;","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport toArray from \"rc-util/es/Children/toArray\";\n\nfunction convertNodeToOption(node) {\n var key = node.key,\n _node$props = node.props,\n children = _node$props.children,\n value = _node$props.value,\n restProps = _objectWithoutProperties(_node$props, [\"children\", \"value\"]);\n\n return _objectSpread({\n key: key,\n value: value !== undefined ? value : key,\n children: children\n }, restProps);\n}\n\nexport function convertChildrenToData(nodes) {\n var optionOnly = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n return toArray(nodes).map(function (node, index) {\n if (!React.isValidElement(node) || !node.type) {\n return null;\n }\n\n var isSelectOptGroup = node.type.isSelectOptGroup,\n key = node.key,\n _node$props2 = node.props,\n children = _node$props2.children,\n restProps = _objectWithoutProperties(_node$props2, [\"children\"]);\n\n if (optionOnly || !isSelectOptGroup) {\n return convertNodeToOption(node);\n }\n\n return _objectSpread(_objectSpread({\n key: \"__RC_SELECT_GRP__\".concat(key === null ? index : key, \"__\"),\n label: key\n }, restProps), {}, {\n options: convertChildrenToData(children)\n });\n }).filter(function (data) {\n return data;\n });\n}","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport * as React from 'react';\nimport warning, { noteOnce } from \"rc-util/es/warning\";\nimport toNodeArray from \"rc-util/es/Children/toArray\";\nimport { convertChildrenToData } from './legacyUtil';\nimport { toArray } from './commonUtil';\n\nfunction warningProps(props) {\n var mode = props.mode,\n options = props.options,\n children = props.children,\n backfill = props.backfill,\n allowClear = props.allowClear,\n placeholder = props.placeholder,\n getInputElement = props.getInputElement,\n showSearch = props.showSearch,\n onSearch = props.onSearch,\n defaultOpen = props.defaultOpen,\n autoFocus = props.autoFocus,\n labelInValue = props.labelInValue,\n value = props.value,\n inputValue = props.inputValue,\n optionLabelProp = props.optionLabelProp;\n var multiple = mode === 'multiple' || mode === 'tags';\n var mergedShowSearch = showSearch !== undefined ? showSearch : multiple || mode === 'combobox';\n var mergedOptions = options || convertChildrenToData(children); // `tags` should not set option as disabled\n\n warning(mode !== 'tags' || mergedOptions.every(function (opt) {\n return !opt.disabled;\n }), 'Please avoid setting option to disabled in tags mode since user can always type text as tag.'); // `combobox` & `tags` should option be `string` type\n\n if (mode === 'tags' || mode === 'combobox') {\n var hasNumberValue = mergedOptions.some(function (item) {\n if (item.options) {\n return item.options.some(function (opt) {\n return typeof ('value' in opt ? opt.value : opt.key) === 'number';\n });\n }\n\n return typeof ('value' in item ? item.value : item.key) === 'number';\n });\n warning(!hasNumberValue, '`value` of Option should not use number type when `mode` is `tags` or `combobox`.');\n } // `combobox` should not use `optionLabelProp`\n\n\n warning(mode !== 'combobox' || !optionLabelProp, '`combobox` mode not support `optionLabelProp`. Please set `value` on Option directly.'); // Only `combobox` support `backfill`\n\n warning(mode === 'combobox' || !backfill, '`backfill` only works with `combobox` mode.'); // Only `combobox` support `getInputElement`\n\n warning(mode === 'combobox' || !getInputElement, '`getInputElement` only work with `combobox` mode.'); // Customize `getInputElement` should not use `allowClear` & `placeholder`\n\n noteOnce(mode !== 'combobox' || !getInputElement || !allowClear || !placeholder, 'Customize `getInputElement` should customize clear and placeholder logic instead of configuring `allowClear` and `placeholder`.'); // `onSearch` should use in `combobox` or `showSearch`\n\n if (onSearch && !mergedShowSearch && mode !== 'combobox' && mode !== 'tags') {\n warning(false, '`onSearch` should work with `showSearch` instead of use alone.');\n }\n\n noteOnce(!defaultOpen || autoFocus, '`defaultOpen` makes Select open without focus which means it will not close by click outside. You can set `autoFocus` if needed.');\n\n if (value !== undefined && value !== null) {\n var values = toArray(value);\n warning(!labelInValue || values.every(function (val) {\n return _typeof(val) === 'object' && ('key' in val || 'value' in val);\n }), '`value` should in shape of `{ value: string | number, label?: ReactNode }` when you set `labelInValue` to `true`');\n warning(!multiple || Array.isArray(value), '`value` should be array when `mode` is `multiple` or `tags`');\n } // Syntactic sugar should use correct children type\n\n\n if (children) {\n var invalidateChildType = null;\n toNodeArray(children).some(function (node) {\n if (!React.isValidElement(node) || !node.type) {\n return false;\n }\n\n var type = node.type;\n\n if (type.isSelectOption) {\n return false;\n }\n\n if (type.isSelectOptGroup) {\n var allChildrenValid = toNodeArray(node.props.children).every(function (subNode) {\n if (!React.isValidElement(subNode) || !node.type || subNode.type.isSelectOption) {\n return true;\n }\n\n invalidateChildType = subNode.type;\n return false;\n });\n\n if (allChildrenValid) {\n return false;\n }\n\n return true;\n }\n\n invalidateChildType = type;\n return true;\n });\n\n if (invalidateChildType) {\n warning(false, \"`children` should be `Select.Option` or `Select.OptGroup` instead of `\".concat(invalidateChildType.displayName || invalidateChildType.name || invalidateChildType, \"`.\"));\n }\n\n warning(inputValue === undefined, '`inputValue` is deprecated, please use `searchValue` instead.');\n }\n}\n\nexport default warningProps;","import _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/esm/createSuper\";\n\n/**\n * To match accessibility requirement, we always provide an input in the component.\n * Other element will not set `tabIndex` to avoid `onBlur` sequence problem.\n * For focused select, we set `aria-live=\"polite\"` to update the accessibility content.\n *\n * ref:\n * - keyboard: https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/listbox_role#Keyboard_interactions\n *\n * New api:\n * - listHeight\n * - listItemHeight\n * - component\n *\n * Remove deprecated api:\n * - multiple\n * - tags\n * - combobox\n * - firstActiveValue\n * - dropdownMenuStyle\n * - openClassName (Not list in api)\n *\n * Update:\n * - `backfill` only support `combobox` mode\n * - `combobox` mode not support `labelInValue` since it's meaningless\n * - `getInputElement` only support `combobox` mode\n * - `onChange` return OptionData instead of ReactNode\n * - `filterOption` `onChange` `onSelect` accept OptionData instead of ReactNode\n * - `combobox` mode trigger `onChange` will get `undefined` if no `value` match in Option\n * - `combobox` mode not support `optionLabelProp`\n */\nimport * as React from 'react';\nimport SelectOptionList from './OptionList';\nimport Option from './Option';\nimport OptGroup from './OptGroup';\nimport { convertChildrenToData as convertSelectChildrenToData } from './utils/legacyUtil';\nimport { getLabeledValue as getSelectLabeledValue, filterOptions as selectDefaultFilterOptions, isValueDisabled as isSelectValueDisabled, findValueOption as findSelectValueOption, flattenOptions, fillOptionsWithMissingValue } from './utils/valueUtil';\nimport generateSelector from './generate';\nimport warningProps from './utils/warningPropsUtil';\nvar RefSelect = generateSelector({\n prefixCls: 'rc-select',\n components: {\n optionList: SelectOptionList\n },\n convertChildrenToData: convertSelectChildrenToData,\n flattenOptions: flattenOptions,\n getLabeledValue: getSelectLabeledValue,\n filterOptions: selectDefaultFilterOptions,\n isValueDisabled: isSelectValueDisabled,\n findValueOption: findSelectValueOption,\n warningProps: warningProps,\n fillOptionsWithMissingValue: fillOptionsWithMissingValue\n});\n/**\n * Typescript not support generic with function component,\n * we have to wrap an class component to handle this.\n */\n\nvar Select = /*#__PURE__*/function (_React$Component) {\n _inherits(Select, _React$Component);\n\n var _super = _createSuper(Select);\n\n function Select() {\n var _this;\n\n _classCallCheck(this, Select);\n\n _this = _super.apply(this, arguments);\n _this.selectRef = React.createRef();\n\n _this.focus = function () {\n _this.selectRef.current.focus();\n };\n\n _this.blur = function () {\n _this.selectRef.current.blur();\n };\n\n return _this;\n }\n\n _createClass(Select, [{\n key: \"render\",\n value: function render() {\n return React.createElement(RefSelect, Object.assign({\n ref: this.selectRef\n }, this.props));\n }\n }]);\n\n return Select;\n}(React.Component);\n\nSelect.Option = Option;\nSelect.OptGroup = OptGroup;\nexport default Select;","import Select from './Select';\nimport Option from './Option';\nimport OptGroup from './OptGroup';\nexport { Option, OptGroup };\nexport default Select;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\n// TODO: 4.0 - codemod should help to change `filterOption` to support node props.\nimport * as React from 'react';\nimport omit from 'omit.js';\nimport classNames from 'classnames';\nimport RcSelect, { Option, OptGroup } from 'rc-select';\nimport { ConfigConsumer } from '../config-provider';\nimport getIcons from './utils/iconUtil';\nimport SizeContext from '../config-provider/SizeContext'; // We still use class here since `forwardRef` not support generic in typescript\n\nvar Select = /*#__PURE__*/function (_React$Component) {\n _inherits(Select, _React$Component);\n\n var _super = _createSuper(Select);\n\n function Select() {\n var _this;\n\n _classCallCheck(this, Select);\n\n _this = _super.apply(this, arguments);\n _this.selectRef = /*#__PURE__*/React.createRef();\n\n _this.focus = function () {\n if (_this.selectRef.current) {\n _this.selectRef.current.focus();\n }\n };\n\n _this.blur = function () {\n if (_this.selectRef.current) {\n _this.selectRef.current.blur();\n }\n };\n\n _this.getMode = function () {\n var mode = _this.props.mode;\n\n if (mode === 'combobox') {\n return undefined;\n }\n\n if (mode === Select.SECRET_COMBOBOX_MODE_DO_NOT_USE) {\n return 'combobox';\n }\n\n return mode;\n };\n\n _this.renderSelect = function (_ref) {\n var getContextPopupContainer = _ref.getPopupContainer,\n getPrefixCls = _ref.getPrefixCls,\n renderEmpty = _ref.renderEmpty,\n direction = _ref.direction,\n virtual = _ref.virtual,\n dropdownMatchSelectWidth = _ref.dropdownMatchSelectWidth;\n var _this$props = _this.props,\n customizePrefixCls = _this$props.prefixCls,\n notFoundContent = _this$props.notFoundContent,\n className = _this$props.className,\n customizeSize = _this$props.size,\n _this$props$listHeigh = _this$props.listHeight,\n listHeight = _this$props$listHeigh === void 0 ? 256 : _this$props$listHeigh,\n _this$props$listItemH = _this$props.listItemHeight,\n listItemHeight = _this$props$listItemH === void 0 ? 24 : _this$props$listItemH,\n getPopupContainer = _this$props.getPopupContainer,\n dropdownClassName = _this$props.dropdownClassName,\n bordered = _this$props.bordered;\n var prefixCls = getPrefixCls('select', customizePrefixCls);\n\n var mode = _this.getMode();\n\n var isMultiple = mode === 'multiple' || mode === 'tags'; // ===================== Empty =====================\n\n var mergedNotFound;\n\n if (notFoundContent !== undefined) {\n mergedNotFound = notFoundContent;\n } else if (mode === 'combobox') {\n mergedNotFound = null;\n } else {\n mergedNotFound = renderEmpty('Select');\n } // ===================== Icons =====================\n\n\n var _getIcons = getIcons(_extends(_extends({}, _this.props), {\n multiple: isMultiple,\n prefixCls: prefixCls\n })),\n suffixIcon = _getIcons.suffixIcon,\n itemIcon = _getIcons.itemIcon,\n removeIcon = _getIcons.removeIcon,\n clearIcon = _getIcons.clearIcon;\n\n var selectProps = omit(_this.props, ['prefixCls', 'suffixIcon', 'itemIcon', 'removeIcon', 'clearIcon', 'size', 'bordered']);\n var rcSelectRtlDropDownClassName = classNames(dropdownClassName, _defineProperty({}, \"\".concat(prefixCls, \"-dropdown-\").concat(direction), direction === 'rtl'));\n return /*#__PURE__*/React.createElement(SizeContext.Consumer, null, function (size) {\n var _classNames2;\n\n var mergedSize = customizeSize || size;\n var mergedClassName = classNames(className, (_classNames2 = {}, _defineProperty(_classNames2, \"\".concat(prefixCls, \"-lg\"), mergedSize === 'large'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-sm\"), mergedSize === 'small'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-borderless\"), !bordered), _classNames2));\n return /*#__PURE__*/React.createElement(RcSelect, _extends({\n ref: _this.selectRef,\n virtual: virtual,\n dropdownMatchSelectWidth: dropdownMatchSelectWidth\n }, selectProps, {\n listHeight: listHeight,\n listItemHeight: listItemHeight,\n mode: mode,\n prefixCls: prefixCls,\n direction: direction,\n inputIcon: suffixIcon,\n menuItemSelectedIcon: itemIcon,\n removeIcon: removeIcon,\n clearIcon: clearIcon,\n notFoundContent: mergedNotFound,\n className: mergedClassName,\n getPopupContainer: getPopupContainer || getContextPopupContainer,\n dropdownClassName: rcSelectRtlDropDownClassName\n }));\n });\n };\n\n return _this;\n }\n\n _createClass(Select, [{\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderSelect);\n }\n }]);\n\n return Select;\n}(React.Component);\n\nSelect.Option = Option;\nSelect.OptGroup = OptGroup;\nSelect.SECRET_COMBOBOX_MODE_DO_NOT_USE = 'SECRET_COMBOBOX_MODE_DO_NOT_USE';\nSelect.defaultProps = {\n transitionName: 'slide-up',\n choiceTransitionName: '',\n bordered: true\n};\nexport default Select;","import _extends from \"@babel/runtime/helpers/extends\";\nimport * as React from 'react';\nimport Select from '../select';\n\nvar MiniSelect = function MiniSelect(props) {\n return /*#__PURE__*/React.createElement(Select, _extends({\n size: \"small\"\n }, props));\n};\n\nMiniSelect.Option = Select.Option;\nexport default MiniSelect;","import _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport { useEffect, useState } from 'react';\nimport ResponsiveObserve from '../../_util/responsiveObserve';\n\nfunction useBreakpoint() {\n var _useState = useState({}),\n _useState2 = _slicedToArray(_useState, 2),\n screens = _useState2[0],\n setScreens = _useState2[1];\n\n useEffect(function () {\n var token = ResponsiveObserve.subscribe(function (supportScreens) {\n setScreens(supportScreens);\n });\n return function () {\n return ResponsiveObserve.unsubscribe(token);\n };\n }, []);\n return screens;\n}\n\nexport default useBreakpoint;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport RcPagination from 'rc-pagination';\nimport enUS from \"rc-pagination/es/locale/en_US\";\nimport classNames from 'classnames';\nimport LeftOutlined from '@ant-design/icons/LeftOutlined';\nimport RightOutlined from '@ant-design/icons/RightOutlined';\nimport DoubleLeftOutlined from '@ant-design/icons/DoubleLeftOutlined';\nimport DoubleRightOutlined from '@ant-design/icons/DoubleRightOutlined';\nimport MiniSelect from './MiniSelect';\nimport Select from '../select';\nimport LocaleReceiver from '../locale-provider/LocaleReceiver';\nimport { ConfigContext } from '../config-provider';\nimport useBreakpoint from '../grid/hooks/useBreakpoint';\n\nvar Pagination = function Pagination(_a) {\n var customizePrefixCls = _a.prefixCls,\n customizeSelectPrefixCls = _a.selectPrefixCls,\n className = _a.className,\n size = _a.size,\n customLocale = _a.locale,\n restProps = __rest(_a, [\"prefixCls\", \"selectPrefixCls\", \"className\", \"size\", \"locale\"]);\n\n var _useBreakpoint = useBreakpoint(),\n xs = _useBreakpoint.xs;\n\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls,\n direction = _React$useContext.direction;\n\n var prefixCls = getPrefixCls('pagination', customizePrefixCls);\n\n var getIconsProps = function getIconsProps() {\n var ellipsis = /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-item-ellipsis\")\n }, \"\\u2022\\u2022\\u2022\");\n var prevIcon = /*#__PURE__*/React.createElement(\"button\", {\n className: \"\".concat(prefixCls, \"-item-link\"),\n type: \"button\",\n tabIndex: -1\n }, /*#__PURE__*/React.createElement(LeftOutlined, null));\n var nextIcon = /*#__PURE__*/React.createElement(\"button\", {\n className: \"\".concat(prefixCls, \"-item-link\"),\n type: \"button\",\n tabIndex: -1\n }, /*#__PURE__*/React.createElement(RightOutlined, null));\n var jumpPrevIcon = /*#__PURE__*/React.createElement(\"a\", {\n className: \"\".concat(prefixCls, \"-item-link\")\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-item-container\")\n }, /*#__PURE__*/React.createElement(DoubleLeftOutlined, {\n className: \"\".concat(prefixCls, \"-item-link-icon\")\n }), ellipsis));\n var jumpNextIcon = /*#__PURE__*/React.createElement(\"a\", {\n className: \"\".concat(prefixCls, \"-item-link\")\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-item-container\")\n }, /*#__PURE__*/React.createElement(DoubleRightOutlined, {\n className: \"\".concat(prefixCls, \"-item-link-icon\")\n }), ellipsis)); // change arrows direction in right-to-left direction\n\n if (direction === 'rtl') {\n var _ref = [nextIcon, prevIcon];\n prevIcon = _ref[0];\n nextIcon = _ref[1];\n var _ref2 = [jumpNextIcon, jumpPrevIcon];\n jumpPrevIcon = _ref2[0];\n jumpNextIcon = _ref2[1];\n }\n\n return {\n prevIcon: prevIcon,\n nextIcon: nextIcon,\n jumpPrevIcon: jumpPrevIcon,\n jumpNextIcon: jumpNextIcon\n };\n };\n\n var renderPagination = function renderPagination(contextLocale) {\n var locale = _extends(_extends({}, contextLocale), customLocale);\n\n var isSmall = size === 'small' || !!(xs && !size && restProps.responsive);\n var selectPrefixCls = getPrefixCls('select', customizeSelectPrefixCls);\n var extendedClassName = classNames(className, _defineProperty({\n mini: isSmall\n }, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'));\n return /*#__PURE__*/React.createElement(RcPagination, _extends({}, restProps, {\n prefixCls: prefixCls,\n selectPrefixCls: selectPrefixCls\n }, getIconsProps(), {\n className: extendedClassName,\n selectComponentClass: isSmall ? MiniSelect : Select,\n locale: locale\n }));\n };\n\n return /*#__PURE__*/React.createElement(LocaleReceiver, {\n componentName: \"Pagination\",\n defaultLocale: enUS\n }, renderPagination);\n};\n\nexport default Pagination;","import Pagination from './Pagination';\nexport default Pagination;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport _typeof from \"@babel/runtime/helpers/typeof\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport { useState } from 'react';\nexport var DEFAULT_PAGE_SIZE = 10;\nexport function getPaginationParam(pagination, mergedPagination) {\n var param = {\n current: mergedPagination.current,\n pageSize: mergedPagination.pageSize\n };\n var paginationObj = pagination && _typeof(pagination) === 'object' ? pagination : {};\n Object.keys(paginationObj).forEach(function (pageProp) {\n var value = mergedPagination[pageProp];\n\n if (typeof value !== 'function') {\n param[pageProp] = value;\n }\n });\n return param;\n}\n\nfunction extendsObject() {\n var result = {};\n\n for (var _len = arguments.length, list = new Array(_len), _key = 0; _key < _len; _key++) {\n list[_key] = arguments[_key];\n }\n\n list.forEach(function (obj) {\n if (obj) {\n Object.keys(obj).forEach(function (key) {\n var val = obj[key];\n\n if (val !== undefined) {\n result[key] = val;\n }\n });\n }\n });\n return result;\n}\n\nexport default function usePagination(total, pagination, onChange) {\n var _a = pagination && _typeof(pagination) === 'object' ? pagination : {},\n _a$total = _a.total,\n paginationTotal = _a$total === void 0 ? 0 : _a$total,\n paginationObj = __rest(_a, [\"total\"]);\n\n var _useState = useState(function () {\n return {\n current: 'defaultCurrent' in paginationObj ? paginationObj.defaultCurrent : 1,\n pageSize: 'defaultPageSize' in paginationObj ? paginationObj.defaultPageSize : DEFAULT_PAGE_SIZE\n };\n }),\n _useState2 = _slicedToArray(_useState, 2),\n innerPagination = _useState2[0],\n setInnerPagination = _useState2[1]; // ============ Basic Pagination Config ============\n\n\n var mergedPagination = extendsObject(innerPagination, paginationObj, {\n total: paginationTotal > 0 ? paginationTotal : total\n });\n\n if (!paginationTotal) {\n // Reset `current` if data length changed. Only reset when paginationObj do not have total\n var maxPage = Math.ceil(total / mergedPagination.pageSize);\n\n if (maxPage < mergedPagination.current) {\n mergedPagination.current = 1;\n }\n }\n\n var refreshPagination = function refreshPagination() {\n var current = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 1;\n var pageSize = arguments.length > 1 ? arguments[1] : undefined;\n setInnerPagination(_extends(_extends({}, mergedPagination), {\n current: current,\n pageSize: pageSize || mergedPagination.pageSize\n }));\n };\n\n var onInternalChange = function onInternalChange(current, pageSize) {\n var paginationPageSize = mergedPagination === null || mergedPagination === void 0 ? void 0 : mergedPagination.pageSize;\n\n if (pageSize && pageSize !== paginationPageSize) {\n current = 1;\n if (pagination && pagination.onShowSizeChange) pagination.onShowSizeChange(current, pageSize);\n }\n\n if (pagination && pagination.onChange) pagination.onChange(current, pageSize);\n refreshPagination(current, pageSize);\n onChange(current, pageSize || paginationPageSize);\n };\n\n if (pagination === false) {\n return [{}, function () {}];\n }\n\n return [_extends(_extends({}, mergedPagination), {\n onChange: onInternalChange\n }), refreshPagination];\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/esm/createClass\";\nimport _inherits from \"@babel/runtime/helpers/esm/inherits\";\nimport _possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nimport _getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\n// eslint-disable-next-line import/no-extraneous-dependencies\nimport React, { Component } from 'react';\nimport classNames from 'classnames';\n\nvar Checkbox = /*#__PURE__*/function (_Component) {\n _inherits(Checkbox, _Component);\n\n var _super = _createSuper(Checkbox);\n\n function Checkbox(props) {\n var _this;\n\n _classCallCheck(this, Checkbox);\n\n _this = _super.call(this, props);\n\n _this.handleChange = function (e) {\n var _this$props = _this.props,\n disabled = _this$props.disabled,\n onChange = _this$props.onChange;\n\n if (disabled) {\n return;\n }\n\n if (!('checked' in _this.props)) {\n _this.setState({\n checked: e.target.checked\n });\n }\n\n if (onChange) {\n onChange({\n target: _objectSpread(_objectSpread({}, _this.props), {}, {\n checked: e.target.checked\n }),\n stopPropagation: function stopPropagation() {\n e.stopPropagation();\n },\n preventDefault: function preventDefault() {\n e.preventDefault();\n },\n nativeEvent: e.nativeEvent\n });\n }\n };\n\n _this.saveInput = function (node) {\n _this.input = node;\n };\n\n var checked = 'checked' in props ? props.checked : props.defaultChecked;\n _this.state = {\n checked: checked\n };\n return _this;\n }\n\n _createClass(Checkbox, [{\n key: \"focus\",\n value: function focus() {\n this.input.focus();\n }\n }, {\n key: \"blur\",\n value: function blur() {\n this.input.blur();\n }\n }, {\n key: \"render\",\n value: function render() {\n var _classNames;\n\n var _this$props2 = this.props,\n prefixCls = _this$props2.prefixCls,\n className = _this$props2.className,\n style = _this$props2.style,\n name = _this$props2.name,\n id = _this$props2.id,\n type = _this$props2.type,\n disabled = _this$props2.disabled,\n readOnly = _this$props2.readOnly,\n tabIndex = _this$props2.tabIndex,\n onClick = _this$props2.onClick,\n onFocus = _this$props2.onFocus,\n onBlur = _this$props2.onBlur,\n autoFocus = _this$props2.autoFocus,\n value = _this$props2.value,\n required = _this$props2.required,\n others = _objectWithoutProperties(_this$props2, [\"prefixCls\", \"className\", \"style\", \"name\", \"id\", \"type\", \"disabled\", \"readOnly\", \"tabIndex\", \"onClick\", \"onFocus\", \"onBlur\", \"autoFocus\", \"value\", \"required\"]);\n\n var globalProps = Object.keys(others).reduce(function (prev, key) {\n if (key.substr(0, 5) === 'aria-' || key.substr(0, 5) === 'data-' || key === 'role') {\n // eslint-disable-next-line no-param-reassign\n prev[key] = others[key];\n }\n\n return prev;\n }, {});\n var checked = this.state.checked;\n var classString = classNames(prefixCls, className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-checked\"), checked), _defineProperty(_classNames, \"\".concat(prefixCls, \"-disabled\"), disabled), _classNames));\n return /*#__PURE__*/React.createElement(\"span\", {\n className: classString,\n style: style\n }, /*#__PURE__*/React.createElement(\"input\", _extends({\n name: name,\n id: id,\n type: type,\n required: required,\n readOnly: readOnly,\n disabled: disabled,\n tabIndex: tabIndex,\n className: \"\".concat(prefixCls, \"-input\"),\n checked: !!checked,\n onClick: onClick,\n onFocus: onFocus,\n onBlur: onBlur,\n onChange: this.handleChange,\n autoFocus: autoFocus,\n ref: this.saveInput,\n value: value\n }, globalProps)), /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-inner\")\n }));\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(props, state) {\n if ('checked' in props) {\n return _objectSpread(_objectSpread({}, state), {}, {\n checked: props.checked\n });\n }\n\n return null;\n }\n }]);\n\n return Checkbox;\n}(Component);\n\nCheckbox.defaultProps = {\n prefixCls: 'rc-checkbox',\n className: '',\n style: {},\n type: 'checkbox',\n defaultChecked: false,\n onFocus: function onFocus() {},\n onBlur: function onBlur() {},\n onChange: function onChange() {}\n};\nexport default Checkbox;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _toConsumableArray from \"@babel/runtime/helpers/toConsumableArray\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport Checkbox from './Checkbox';\nimport { ConfigConsumer } from '../config-provider';\nexport var GroupContext = /*#__PURE__*/React.createContext(null);\n\nvar CheckboxGroup = /*#__PURE__*/function (_React$PureComponent) {\n _inherits(CheckboxGroup, _React$PureComponent);\n\n var _super = _createSuper(CheckboxGroup);\n\n function CheckboxGroup(props) {\n var _this;\n\n _classCallCheck(this, CheckboxGroup);\n\n _this = _super.call(this, props);\n\n _this.cancelValue = function (value) {\n _this.setState(function (_ref) {\n var registeredValues = _ref.registeredValues;\n return {\n registeredValues: registeredValues.filter(function (val) {\n return val !== value;\n })\n };\n });\n };\n\n _this.registerValue = function (value) {\n _this.setState(function (_ref2) {\n var registeredValues = _ref2.registeredValues;\n return {\n registeredValues: [].concat(_toConsumableArray(registeredValues), [value])\n };\n });\n };\n\n _this.toggleOption = function (option) {\n var registeredValues = _this.state.registeredValues;\n\n var optionIndex = _this.state.value.indexOf(option.value);\n\n var value = _toConsumableArray(_this.state.value);\n\n if (optionIndex === -1) {\n value.push(option.value);\n } else {\n value.splice(optionIndex, 1);\n }\n\n if (!('value' in _this.props)) {\n _this.setState({\n value: value\n });\n }\n\n var onChange = _this.props.onChange;\n\n if (onChange) {\n var options = _this.getOptions();\n\n onChange(value.filter(function (val) {\n return registeredValues.indexOf(val) !== -1;\n }).sort(function (a, b) {\n var indexA = options.findIndex(function (opt) {\n return opt.value === a;\n });\n var indexB = options.findIndex(function (opt) {\n return opt.value === b;\n });\n return indexA - indexB;\n }));\n }\n };\n\n _this.renderGroup = function (_ref3) {\n var getPrefixCls = _ref3.getPrefixCls,\n direction = _ref3.direction;\n\n var _assertThisInitialize = _assertThisInitialized(_this),\n props = _assertThisInitialize.props,\n state = _assertThisInitialize.state;\n\n var customizePrefixCls = props.prefixCls,\n className = props.className,\n style = props.style,\n options = props.options,\n restProps = __rest(props, [\"prefixCls\", \"className\", \"style\", \"options\"]);\n\n var prefixCls = getPrefixCls('checkbox', customizePrefixCls);\n var groupPrefixCls = \"\".concat(prefixCls, \"-group\");\n var domProps = omit(restProps, ['children', 'defaultValue', 'value', 'onChange', 'disabled']);\n var children = props.children;\n\n if (options && options.length > 0) {\n children = _this.getOptions().map(function (option) {\n return /*#__PURE__*/React.createElement(Checkbox, {\n prefixCls: prefixCls,\n key: option.value.toString(),\n disabled: 'disabled' in option ? option.disabled : props.disabled,\n value: option.value,\n checked: state.value.indexOf(option.value) !== -1,\n onChange: option.onChange,\n className: \"\".concat(groupPrefixCls, \"-item\"),\n style: option.style\n }, option.label);\n });\n }\n\n var context = {\n toggleOption: _this.toggleOption,\n value: _this.state.value,\n disabled: _this.props.disabled,\n name: _this.props.name,\n // https://github.com/ant-design/ant-design/issues/16376\n registerValue: _this.registerValue,\n cancelValue: _this.cancelValue\n };\n var classString = classNames(groupPrefixCls, className, _defineProperty({}, \"\".concat(groupPrefixCls, \"-rtl\"), direction === 'rtl'));\n return /*#__PURE__*/React.createElement(\"div\", _extends({\n className: classString,\n style: style\n }, domProps), /*#__PURE__*/React.createElement(GroupContext.Provider, {\n value: context\n }, children));\n };\n\n _this.state = {\n value: props.value || props.defaultValue || [],\n registeredValues: []\n };\n return _this;\n }\n\n _createClass(CheckboxGroup, [{\n key: \"getOptions\",\n value: function getOptions() {\n var options = this.props.options; // https://github.com/Microsoft/TypeScript/issues/7960\n\n return options.map(function (option) {\n if (typeof option === 'string') {\n return {\n label: option,\n value: option\n };\n }\n\n return option;\n });\n }\n }, {\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderGroup);\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(nextProps) {\n if ('value' in nextProps) {\n return {\n value: nextProps.value || []\n };\n }\n\n return null;\n }\n }]);\n\n return CheckboxGroup;\n}(React.PureComponent);\n\nCheckboxGroup.defaultProps = {\n options: []\n};\nexport default CheckboxGroup;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport RcCheckbox from 'rc-checkbox';\nimport { GroupContext } from './Group';\nimport { ConfigConsumer } from '../config-provider';\nimport devWarning from '../_util/devWarning';\n\nvar Checkbox = /*#__PURE__*/function (_React$PureComponent) {\n _inherits(Checkbox, _React$PureComponent);\n\n var _super = _createSuper(Checkbox);\n\n function Checkbox() {\n var _this;\n\n _classCallCheck(this, Checkbox);\n\n _this = _super.apply(this, arguments);\n\n _this.saveCheckbox = function (node) {\n _this.rcCheckbox = node;\n };\n\n _this.renderCheckbox = function (_ref) {\n var _classNames;\n\n var getPrefixCls = _ref.getPrefixCls,\n direction = _ref.direction;\n\n var _assertThisInitialize = _assertThisInitialized(_this),\n props = _assertThisInitialize.props,\n context = _assertThisInitialize.context;\n\n var customizePrefixCls = props.prefixCls,\n className = props.className,\n children = props.children,\n indeterminate = props.indeterminate,\n style = props.style,\n onMouseEnter = props.onMouseEnter,\n onMouseLeave = props.onMouseLeave,\n restProps = __rest(props, [\"prefixCls\", \"className\", \"children\", \"indeterminate\", \"style\", \"onMouseEnter\", \"onMouseLeave\"]);\n\n var checkboxGroup = context;\n var prefixCls = getPrefixCls('checkbox', customizePrefixCls);\n\n var checkboxProps = _extends({}, restProps);\n\n if (checkboxGroup) {\n checkboxProps.onChange = function () {\n if (restProps.onChange) {\n restProps.onChange.apply(restProps, arguments);\n }\n\n checkboxGroup.toggleOption({\n label: children,\n value: props.value\n });\n };\n\n checkboxProps.name = checkboxGroup.name;\n checkboxProps.checked = checkboxGroup.value.indexOf(props.value) !== -1;\n checkboxProps.disabled = props.disabled || checkboxGroup.disabled;\n }\n\n var classString = classNames(className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-wrapper\"), true), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-wrapper-checked\"), checkboxProps.checked), _defineProperty(_classNames, \"\".concat(prefixCls, \"-wrapper-disabled\"), checkboxProps.disabled), _classNames));\n var checkboxClass = classNames(_defineProperty({}, \"\".concat(prefixCls, \"-indeterminate\"), indeterminate));\n return (\n /*#__PURE__*/\n // eslint-disable-next-line jsx-a11y/label-has-associated-control\n React.createElement(\"label\", {\n className: classString,\n style: style,\n onMouseEnter: onMouseEnter,\n onMouseLeave: onMouseLeave\n }, /*#__PURE__*/React.createElement(RcCheckbox, _extends({}, checkboxProps, {\n prefixCls: prefixCls,\n className: checkboxClass,\n ref: _this.saveCheckbox\n })), children !== undefined && /*#__PURE__*/React.createElement(\"span\", null, children))\n );\n };\n\n return _this;\n }\n\n _createClass(Checkbox, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n var _a;\n\n var value = this.props.value;\n (_a = this.context) === null || _a === void 0 ? void 0 : _a.registerValue(value);\n devWarning('checked' in this.props || this.context || !('value' in this.props), 'Checkbox', '`value` is not a valid prop, do you mean `checked`?');\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate(_ref2) {\n var prevValue = _ref2.value;\n\n var _a, _b;\n\n var value = this.props.value;\n\n if (value !== prevValue) {\n (_a = this.context) === null || _a === void 0 ? void 0 : _a.cancelValue(prevValue);\n (_b = this.context) === null || _b === void 0 ? void 0 : _b.registerValue(value);\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n var _a;\n\n var value = this.props.value;\n (_a = this.context) === null || _a === void 0 ? void 0 : _a.cancelValue(value);\n }\n }, {\n key: \"focus\",\n value: function focus() {\n this.rcCheckbox.focus();\n }\n }, {\n key: \"blur\",\n value: function blur() {\n this.rcCheckbox.blur();\n }\n }, {\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderCheckbox);\n }\n }]);\n\n return Checkbox;\n}(React.PureComponent);\n\nCheckbox.__ANT_CHECKBOX = true;\nCheckbox.defaultProps = {\n indeterminate: false\n};\nCheckbox.contextType = GroupContext;\nexport default Checkbox;","import Checkbox from './Checkbox';\nimport Group from './Group';\nCheckbox.Group = Group;\nexport default Checkbox;","import * as React from 'react';\nvar RadioGroupContext = /*#__PURE__*/React.createContext(null);\nexport var RadioGroupContextProvider = RadioGroupContext.Provider;\nexport default RadioGroupContext;","import _typeof from \"@babel/runtime/helpers/typeof\";\nexport function fillRef(ref, node) {\n if (typeof ref === 'function') {\n ref(node);\n } else if (_typeof(ref) === 'object' && ref && 'current' in ref) {\n ref.current = node;\n }\n}\nexport function composeRef() {\n for (var _len = arguments.length, refs = new Array(_len), _key = 0; _key < _len; _key++) {\n refs[_key] = arguments[_key];\n }\n\n return function (node) {\n refs.forEach(function (ref) {\n fillRef(ref, node);\n });\n };\n}","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport RcCheckbox from 'rc-checkbox';\nimport classNames from 'classnames';\nimport { ConfigContext } from '../config-provider';\nimport RadioGroupContext from './context';\nimport { composeRef } from '../_util/ref';\nimport devWarning from '../_util/devWarning';\n\nvar InternalRadio = function InternalRadio(props, ref) {\n var _classNames;\n\n var context = React.useContext(RadioGroupContext);\n\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls,\n direction = _React$useContext.direction;\n\n var innerRef = React.useRef();\n var mergedRef = composeRef(ref, innerRef);\n React.useEffect(function () {\n devWarning(!('optionType' in props), 'Radio', '`optionType` is only support in Radio.Group.');\n }, []);\n\n var onChange = function onChange(e) {\n if (props.onChange) {\n props.onChange(e);\n }\n\n if (context === null || context === void 0 ? void 0 : context.onChange) {\n context.onChange(e);\n }\n };\n\n var customizePrefixCls = props.prefixCls,\n className = props.className,\n children = props.children,\n style = props.style,\n restProps = __rest(props, [\"prefixCls\", \"className\", \"children\", \"style\"]);\n\n var prefixCls = getPrefixCls('radio', customizePrefixCls);\n\n var radioProps = _extends({}, restProps);\n\n if (context) {\n radioProps.name = context.name;\n radioProps.onChange = onChange;\n radioProps.checked = props.value === context.value;\n radioProps.disabled = props.disabled || context.disabled;\n }\n\n var wrapperClassString = classNames(className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-wrapper\"), true), _defineProperty(_classNames, \"\".concat(prefixCls, \"-wrapper-checked\"), radioProps.checked), _defineProperty(_classNames, \"\".concat(prefixCls, \"-wrapper-disabled\"), radioProps.disabled), _defineProperty(_classNames, \"\".concat(prefixCls, \"-wrapper-rtl\"), direction === 'rtl'), _classNames));\n return (\n /*#__PURE__*/\n // eslint-disable-next-line jsx-a11y/label-has-associated-control\n React.createElement(\"label\", {\n className: wrapperClassString,\n style: style,\n onMouseEnter: props.onMouseEnter,\n onMouseLeave: props.onMouseLeave\n }, /*#__PURE__*/React.createElement(RcCheckbox, _extends({}, radioProps, {\n prefixCls: prefixCls,\n ref: mergedRef\n })), children !== undefined ? /*#__PURE__*/React.createElement(\"span\", null, children) : null)\n );\n};\n\nvar Radio = /*#__PURE__*/React.forwardRef(InternalRadio);\nRadio.displayName = 'Radio';\nRadio.defaultProps = {\n type: 'radio'\n};\nexport default Radio;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport useMergedState from \"rc-util/es/hooks/useMergedState\";\nimport Radio from './radio';\nimport { ConfigContext } from '../config-provider';\nimport SizeContext from '../config-provider/SizeContext';\nimport { RadioGroupContextProvider } from './context';\nvar RadioGroup = /*#__PURE__*/React.forwardRef(function (props, ref) {\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls,\n direction = _React$useContext.direction;\n\n var size = React.useContext(SizeContext);\n\n var _useMergedState = useMergedState(props.defaultValue, {\n value: props.value\n }),\n _useMergedState2 = _slicedToArray(_useMergedState, 2),\n value = _useMergedState2[0],\n setValue = _useMergedState2[1];\n\n var onRadioChange = function onRadioChange(ev) {\n var lastValue = value;\n var val = ev.target.value;\n\n if (!('value' in props)) {\n setValue(val);\n }\n\n var onChange = props.onChange;\n\n if (onChange && val !== lastValue) {\n onChange(ev);\n }\n };\n\n var renderGroup = function renderGroup() {\n var _classNames;\n\n var customizePrefixCls = props.prefixCls,\n _props$className = props.className,\n className = _props$className === void 0 ? '' : _props$className,\n options = props.options,\n optionType = props.optionType,\n buttonStyle = props.buttonStyle,\n disabled = props.disabled,\n children = props.children,\n customizeSize = props.size,\n style = props.style,\n id = props.id,\n onMouseEnter = props.onMouseEnter,\n onMouseLeave = props.onMouseLeave;\n var prefixCls = getPrefixCls('radio', customizePrefixCls);\n var groupPrefixCls = \"\".concat(prefixCls, \"-group\");\n var childrenToRender = children; // 如果存在 options, 优先使用\n\n if (options && options.length > 0) {\n var optionsPrefixCls = optionType === 'button' ? \"\".concat(prefixCls, \"-button\") : prefixCls;\n childrenToRender = options.map(function (option) {\n if (typeof option === 'string') {\n // 此处类型自动推导为 string\n return /*#__PURE__*/React.createElement(Radio, {\n ref: ref,\n key: option,\n prefixCls: optionsPrefixCls,\n disabled: disabled,\n value: option,\n checked: value === option\n }, option);\n } // 此处类型自动推导为 { label: string value: string }\n\n\n return /*#__PURE__*/React.createElement(Radio, {\n ref: ref,\n key: \"radio-group-value-options-\".concat(option.value),\n prefixCls: optionsPrefixCls,\n disabled: option.disabled || disabled,\n value: option.value,\n checked: value === option.value,\n style: option.style\n }, option.label);\n });\n }\n\n var mergedSize = customizeSize || size;\n var classString = classNames(groupPrefixCls, \"\".concat(groupPrefixCls, \"-\").concat(buttonStyle), (_classNames = {}, _defineProperty(_classNames, \"\".concat(groupPrefixCls, \"-\").concat(mergedSize), mergedSize), _defineProperty(_classNames, \"\".concat(groupPrefixCls, \"-rtl\"), direction === 'rtl'), _classNames), className);\n return /*#__PURE__*/React.createElement(\"div\", {\n className: classString,\n style: style,\n onMouseEnter: onMouseEnter,\n onMouseLeave: onMouseLeave,\n id: id\n }, childrenToRender);\n };\n\n return /*#__PURE__*/React.createElement(RadioGroupContextProvider, {\n value: {\n onChange: onRadioChange,\n value: value,\n disabled: props.disabled,\n name: props.name\n }\n }, renderGroup());\n});\nRadioGroup.defaultProps = {\n buttonStyle: 'outline'\n};\nexport default /*#__PURE__*/React.memo(RadioGroup);","import _extends from \"@babel/runtime/helpers/extends\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport Radio from './radio';\nimport { ConfigContext } from '../config-provider';\nimport RadioGroupContext from './context';\n\nvar RadioButton = function RadioButton(props, ref) {\n var radioGroupContext = React.useContext(RadioGroupContext);\n\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls;\n\n var customizePrefixCls = props.prefixCls,\n radioProps = __rest(props, [\"prefixCls\"]);\n\n var prefixCls = getPrefixCls('radio-button', customizePrefixCls);\n\n if (radioGroupContext) {\n radioProps.checked = props.value === radioGroupContext.value;\n radioProps.disabled = props.disabled || radioGroupContext.disabled;\n }\n\n return /*#__PURE__*/React.createElement(Radio, _extends({\n prefixCls: prefixCls\n }, radioProps, {\n type: \"radio\",\n ref: ref\n }));\n};\n\nexport default /*#__PURE__*/React.forwardRef(RadioButton);","import InternalRadio from './radio';\nimport Group from './group';\nimport Button from './radioButton';\nvar Radio = InternalRadio;\nRadio.Button = Button;\nRadio.Group = Group;\nexport { Button, Group };\nexport default Radio;","import _toArray from \"@babel/runtime/helpers/toArray\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport _toConsumableArray from \"@babel/runtime/helpers/toConsumableArray\";\nimport _typeof from \"@babel/runtime/helpers/typeof\";\nimport * as React from 'react';\nimport { useState, useCallback, useMemo } from 'react';\nimport DownOutlined from '@ant-design/icons/DownOutlined';\nimport { convertDataToEntities } from \"rc-tree/es/utils/treeUtil\";\nimport { conductCheck } from \"rc-tree/es/utils/conductUtil\";\nimport { arrAdd, arrDel } from \"rc-tree/es/util\";\nimport { INTERNAL_COL_DEFINE } from 'rc-table';\nimport useMergedState from \"rc-util/es/hooks/useMergedState\";\nimport Checkbox from '../../checkbox';\nimport Dropdown from '../../dropdown';\nimport Menu from '../../menu';\nimport Radio from '../../radio';\nimport devWarning from '../../_util/devWarning'; // TODO: warning if use ajax!!!\n\nexport var SELECTION_ALL = 'SELECT_ALL';\nexport var SELECTION_INVERT = 'SELECT_INVERT';\n\nfunction getFixedType(column) {\n return column && column.fixed;\n}\n\nfunction flattenData(data, childrenColumnName) {\n var list = [];\n (data || []).forEach(function (record) {\n list.push(record);\n\n if (record && _typeof(record) === 'object' && childrenColumnName in record) {\n list = [].concat(_toConsumableArray(list), _toConsumableArray(flattenData(record[childrenColumnName], childrenColumnName)));\n }\n });\n return list;\n}\n\nexport default function useSelection(rowSelection, config) {\n var _ref = rowSelection || {},\n preserveSelectedRowKeys = _ref.preserveSelectedRowKeys,\n selectedRowKeys = _ref.selectedRowKeys,\n getCheckboxProps = _ref.getCheckboxProps,\n onSelectionChange = _ref.onChange,\n onSelect = _ref.onSelect,\n onSelectAll = _ref.onSelectAll,\n onSelectInvert = _ref.onSelectInvert,\n onSelectMultiple = _ref.onSelectMultiple,\n selectionColWidth = _ref.columnWidth,\n selectionType = _ref.type,\n selections = _ref.selections,\n fixed = _ref.fixed,\n customizeRenderCell = _ref.renderCell,\n hideSelectAll = _ref.hideSelectAll,\n _ref$checkStrictly = _ref.checkStrictly,\n checkStrictly = _ref$checkStrictly === void 0 ? true : _ref$checkStrictly;\n\n var prefixCls = config.prefixCls,\n data = config.data,\n pageData = config.pageData,\n getRecordByKey = config.getRecordByKey,\n getRowKey = config.getRowKey,\n expandType = config.expandType,\n childrenColumnName = config.childrenColumnName,\n tableLocale = config.locale,\n expandIconColumnIndex = config.expandIconColumnIndex,\n getPopupContainer = config.getPopupContainer; // ======================== Caches ========================\n\n var preserveRecordsRef = React.useRef(new Map()); // ========================= Keys =========================\n\n var _useMergedState = useMergedState(selectedRowKeys || [], {\n value: selectedRowKeys\n }),\n _useMergedState2 = _slicedToArray(_useMergedState, 2),\n mergedSelectedKeys = _useMergedState2[0],\n setMergedSelectedKeys = _useMergedState2[1];\n\n var _useMemo = useMemo(function () {\n return checkStrictly ? {\n keyEntities: null\n } : convertDataToEntities(data, undefined, getRowKey);\n }, [data, getRowKey, checkStrictly]),\n keyEntities = _useMemo.keyEntities; // Get flatten data\n\n\n var flattedData = useMemo(function () {\n return flattenData(pageData, childrenColumnName);\n }, [pageData, childrenColumnName]); // Get all checkbox props\n\n var checkboxPropsMap = useMemo(function () {\n var map = new Map();\n flattedData.forEach(function (record, index) {\n var key = getRowKey(record, index);\n var checkboxProps = (getCheckboxProps ? getCheckboxProps(record) : null) || {};\n map.set(key, checkboxProps);\n\n if (process.env.NODE_ENV !== 'production' && ('checked' in checkboxProps || 'defaultChecked' in checkboxProps)) {\n devWarning(false, 'Table', 'Do not set `checked` or `defaultChecked` in `getCheckboxProps`. Please use `selectedRowKeys` instead.');\n }\n });\n return map;\n }, [flattedData, getRowKey, getCheckboxProps]);\n var isCheckboxDisabled = useCallback(function (r) {\n var _a;\n\n return !!((_a = checkboxPropsMap.get(getRowKey(r))) === null || _a === void 0 ? void 0 : _a.disabled);\n }, [checkboxPropsMap, getRowKey]);\n\n var _useMemo2 = useMemo(function () {\n if (checkStrictly) {\n return [mergedSelectedKeys, []];\n }\n\n var _conductCheck = conductCheck(mergedSelectedKeys, true, keyEntities, isCheckboxDisabled),\n checkedKeys = _conductCheck.checkedKeys,\n halfCheckedKeys = _conductCheck.halfCheckedKeys;\n\n return [checkedKeys, halfCheckedKeys];\n }, [mergedSelectedKeys, checkStrictly, keyEntities, isCheckboxDisabled]),\n _useMemo3 = _slicedToArray(_useMemo2, 2),\n derivedSelectedKeys = _useMemo3[0],\n derivedHalfSelectedKeys = _useMemo3[1];\n\n var derivedSelectedKeySet = useMemo(function () {\n var keys = selectionType === 'radio' ? derivedSelectedKeys.slice(0, 1) : derivedSelectedKeys;\n return new Set(keys);\n }, [derivedSelectedKeys, selectionType]);\n var derivedHalfSelectedKeySet = useMemo(function () {\n return selectionType === 'radio' ? new Set() : new Set(derivedHalfSelectedKeys);\n }, [derivedHalfSelectedKeys, selectionType]); // Save last selected key to enable range selection\n\n var _useState = useState(null),\n _useState2 = _slicedToArray(_useState, 2),\n lastSelectedKey = _useState2[0],\n setLastSelectedKey = _useState2[1]; // Reset if rowSelection reset\n\n\n React.useEffect(function () {\n if (!rowSelection) {\n setMergedSelectedKeys([]);\n }\n }, [!!rowSelection]);\n var setSelectedKeys = useCallback(function (keys) {\n var availableKeys;\n var records;\n\n if (preserveSelectedRowKeys) {\n // Keep key if mark as preserveSelectedRowKeys\n var newCache = new Map();\n availableKeys = keys;\n records = keys.map(function (key) {\n var record = getRecordByKey(key);\n\n if (!record && preserveRecordsRef.current.has(key)) {\n record = preserveRecordsRef.current.get(key);\n }\n\n newCache.set(key, record);\n return record;\n }); // Refresh to new cache\n\n preserveRecordsRef.current = newCache;\n } else {\n // Filter key which not exist in the `dataSource`\n availableKeys = [];\n records = [];\n keys.forEach(function (key) {\n var record = getRecordByKey(key);\n\n if (record !== undefined) {\n availableKeys.push(key);\n records.push(record);\n }\n });\n }\n\n setMergedSelectedKeys(availableKeys);\n\n if (onSelectionChange) {\n onSelectionChange(availableKeys, records);\n }\n }, [setMergedSelectedKeys, getRecordByKey, onSelectionChange, preserveSelectedRowKeys]); // ====================== Selections ======================\n // Trigger single `onSelect` event\n\n var triggerSingleSelection = useCallback(function (key, selected, keys, event) {\n if (onSelect) {\n var rows = keys.map(function (k) {\n return getRecordByKey(k);\n });\n onSelect(getRecordByKey(key), selected, rows, event);\n }\n\n setSelectedKeys(keys);\n }, [onSelect, getRecordByKey, setSelectedKeys]);\n var mergedSelections = useMemo(function () {\n if (!selections || hideSelectAll) {\n return null;\n }\n\n var selectionList = selections === true ? [SELECTION_ALL, SELECTION_INVERT] : selections;\n return selectionList.map(function (selection) {\n if (selection === SELECTION_ALL) {\n return {\n key: 'all',\n text: tableLocale.selectionAll,\n onSelect: function onSelect() {\n setSelectedKeys(data.map(function (record, index) {\n return getRowKey(record, index);\n }));\n }\n };\n }\n\n if (selection === SELECTION_INVERT) {\n return {\n key: 'invert',\n text: tableLocale.selectInvert,\n onSelect: function onSelect() {\n var keySet = new Set(derivedSelectedKeySet);\n pageData.forEach(function (record, index) {\n var key = getRowKey(record, index);\n\n if (keySet.has(key)) {\n keySet[\"delete\"](key);\n } else {\n keySet.add(key);\n }\n });\n var keys = Array.from(keySet);\n setSelectedKeys(keys);\n\n if (onSelectInvert) {\n devWarning(false, 'Table', '`onSelectInvert` will be removed in future. Please use `onChange` instead.');\n onSelectInvert(keys);\n }\n }\n };\n }\n\n return selection;\n });\n }, [selections, derivedSelectedKeySet, pageData, getRowKey, onSelectInvert, setSelectedKeys]); // ======================= Columns ========================\n\n var transformColumns = useCallback(function (columns) {\n if (!rowSelection) {\n return columns;\n } // Support selection\n\n\n var keySet = new Set(derivedSelectedKeySet); // Record key only need check with enabled\n\n var recordKeys = flattedData.map(getRowKey).filter(function (key) {\n return !checkboxPropsMap.get(key).disabled;\n });\n var checkedCurrentAll = recordKeys.every(function (key) {\n return keySet.has(key);\n });\n var checkedCurrentSome = recordKeys.some(function (key) {\n return keySet.has(key);\n });\n\n var onSelectAllChange = function onSelectAllChange() {\n var changeKeys = [];\n\n if (checkedCurrentAll) {\n recordKeys.forEach(function (key) {\n keySet[\"delete\"](key);\n changeKeys.push(key);\n });\n } else {\n recordKeys.forEach(function (key) {\n if (!keySet.has(key)) {\n keySet.add(key);\n changeKeys.push(key);\n }\n });\n }\n\n var keys = Array.from(keySet);\n setSelectedKeys(keys);\n\n if (onSelectAll) {\n onSelectAll(!checkedCurrentAll, keys.map(function (k) {\n return getRecordByKey(k);\n }), changeKeys.map(function (k) {\n return getRecordByKey(k);\n }));\n }\n }; // ===================== Render =====================\n // Title Cell\n\n\n var title;\n\n if (selectionType !== 'radio') {\n var customizeSelections;\n\n if (mergedSelections) {\n var menu = /*#__PURE__*/React.createElement(Menu, {\n getPopupContainer: getPopupContainer\n }, mergedSelections.map(function (selection, index) {\n var key = selection.key,\n text = selection.text,\n onSelectionClick = selection.onSelect;\n return /*#__PURE__*/React.createElement(Menu.Item, {\n key: key || index,\n onClick: function onClick() {\n if (onSelectionClick) {\n onSelectionClick(recordKeys);\n }\n }\n }, text);\n }));\n customizeSelections = /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-selection-extra\")\n }, /*#__PURE__*/React.createElement(Dropdown, {\n overlay: menu,\n getPopupContainer: getPopupContainer\n }, /*#__PURE__*/React.createElement(\"span\", null, /*#__PURE__*/React.createElement(DownOutlined, null))));\n }\n\n var allDisabled = flattedData.every(function (record, index) {\n var key = getRowKey(record, index);\n var checkboxProps = checkboxPropsMap.get(key) || {};\n return checkboxProps.disabled;\n });\n title = !hideSelectAll && /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-selection\")\n }, /*#__PURE__*/React.createElement(Checkbox, {\n checked: !allDisabled && !!flattedData.length && checkedCurrentAll,\n indeterminate: !checkedCurrentAll && checkedCurrentSome,\n onChange: onSelectAllChange,\n disabled: flattedData.length === 0 || allDisabled\n }), customizeSelections);\n } // Body Cell\n\n\n var renderCell;\n\n if (selectionType === 'radio') {\n renderCell = function renderCell(_, record, index) {\n var key = getRowKey(record, index);\n var checked = keySet.has(key);\n return {\n node: /*#__PURE__*/React.createElement(Radio, _extends({}, checkboxPropsMap.get(key), {\n checked: checked,\n onClick: function onClick(e) {\n return e.stopPropagation();\n },\n onChange: function onChange(event) {\n if (!keySet.has(key)) {\n triggerSingleSelection(key, true, [key], event.nativeEvent);\n }\n }\n })),\n checked: checked\n };\n };\n } else {\n renderCell = function renderCell(_, record, index) {\n var _a;\n\n var key = getRowKey(record, index);\n var checked = keySet.has(key);\n var indeterminate = derivedHalfSelectedKeySet.has(key);\n var checkboxProps = checkboxPropsMap.get(key);\n var mergedIndeterminate;\n\n if (expandType === 'nest') {\n mergedIndeterminate = indeterminate;\n devWarning(!(typeof (checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.indeterminate) === 'boolean'), 'Table', 'set `indeterminate` using `rowSelection.getCheckboxProps` is not allowed with tree structured dataSource.');\n } else {\n mergedIndeterminate = (_a = checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.indeterminate) !== null && _a !== void 0 ? _a : indeterminate;\n } // Record checked\n\n\n return {\n node: /*#__PURE__*/React.createElement(Checkbox, _extends({}, checkboxProps, {\n indeterminate: mergedIndeterminate,\n checked: checked,\n onClick: function onClick(e) {\n return e.stopPropagation();\n },\n onChange: function onChange(_ref2) {\n var nativeEvent = _ref2.nativeEvent;\n var shiftKey = nativeEvent.shiftKey;\n var startIndex = -1;\n var endIndex = -1; // Get range of this\n\n if (shiftKey && checkStrictly) {\n var pointKeys = new Set([lastSelectedKey, key]);\n recordKeys.some(function (recordKey, recordIndex) {\n if (pointKeys.has(recordKey)) {\n if (startIndex === -1) {\n startIndex = recordIndex;\n } else {\n endIndex = recordIndex;\n return true;\n }\n }\n\n return false;\n });\n }\n\n if (endIndex !== -1 && startIndex !== endIndex && checkStrictly) {\n // Batch update selections\n var rangeKeys = recordKeys.slice(startIndex, endIndex + 1);\n var changedKeys = [];\n\n if (checked) {\n rangeKeys.forEach(function (recordKey) {\n if (keySet.has(recordKey)) {\n changedKeys.push(recordKey);\n keySet[\"delete\"](recordKey);\n }\n });\n } else {\n rangeKeys.forEach(function (recordKey) {\n if (!keySet.has(recordKey)) {\n changedKeys.push(recordKey);\n keySet.add(recordKey);\n }\n });\n }\n\n var keys = Array.from(keySet);\n setSelectedKeys(keys);\n\n if (onSelectMultiple) {\n onSelectMultiple(!checked, keys.map(function (recordKey) {\n return getRecordByKey(recordKey);\n }), changedKeys.map(function (recordKey) {\n return getRecordByKey(recordKey);\n }));\n }\n } else {\n // Single record selected\n var originCheckedKeys = derivedSelectedKeys;\n\n if (checkStrictly) {\n var checkedKeys = checked ? arrDel(originCheckedKeys, key) : arrAdd(originCheckedKeys, key);\n triggerSingleSelection(key, !checked, checkedKeys, nativeEvent);\n } else {\n // Always fill first\n var result = conductCheck([].concat(_toConsumableArray(originCheckedKeys), [key]), true, keyEntities, isCheckboxDisabled);\n var _checkedKeys = result.checkedKeys,\n halfCheckedKeys = result.halfCheckedKeys;\n var nextCheckedKeys = _checkedKeys; // If remove, we do it again to correction\n\n if (checked) {\n var tempKeySet = new Set(_checkedKeys);\n tempKeySet[\"delete\"](key);\n nextCheckedKeys = conductCheck(Array.from(tempKeySet), {\n checked: false,\n halfCheckedKeys: halfCheckedKeys\n }, keyEntities, isCheckboxDisabled).checkedKeys;\n }\n\n triggerSingleSelection(key, !checked, nextCheckedKeys, nativeEvent);\n }\n }\n\n setLastSelectedKey(key);\n }\n })),\n checked: checked\n };\n };\n }\n\n var renderSelectionCell = function renderSelectionCell(_, record, index) {\n var _renderCell = renderCell(_, record, index),\n node = _renderCell.node,\n checked = _renderCell.checked;\n\n if (customizeRenderCell) {\n return customizeRenderCell(checked, record, index, node);\n }\n\n return node;\n }; // Columns\n\n\n var selectionColumn = _defineProperty({\n width: selectionColWidth,\n className: \"\".concat(prefixCls, \"-selection-column\"),\n title: rowSelection.columnTitle || title,\n render: renderSelectionCell\n }, INTERNAL_COL_DEFINE, {\n className: \"\".concat(prefixCls, \"-selection-col\")\n });\n\n if (expandType === 'row' && columns.length && !expandIconColumnIndex) {\n var _columns = _toArray(columns),\n expandColumn = _columns[0],\n restColumns = _columns.slice(1);\n\n var selectionFixed = fixed || getFixedType(restColumns[0]);\n\n if (selectionFixed) {\n expandColumn.fixed = selectionFixed;\n }\n\n return [expandColumn, _extends(_extends({}, selectionColumn), {\n fixed: selectionFixed\n })].concat(_toConsumableArray(restColumns));\n }\n\n return [_extends(_extends({}, selectionColumn), {\n fixed: fixed || getFixedType(columns[0])\n })].concat(_toConsumableArray(columns));\n }, [getRowKey, flattedData, rowSelection, derivedSelectedKeys, derivedSelectedKeySet, derivedHalfSelectedKeySet, selectionColWidth, mergedSelections, expandType, lastSelectedKey, checkboxPropsMap, onSelectMultiple, triggerSingleSelection, isCheckboxDisabled]);\n return [transformColumns, derivedSelectedKeySet];\n}","export function getColumnKey(column, defaultKey) {\n if ('key' in column && column.key !== undefined && column.key !== null) {\n return column.key;\n }\n\n if (column.dataIndex) {\n return Array.isArray(column.dataIndex) ? column.dataIndex.join('.') : column.dataIndex;\n }\n\n return defaultKey;\n}\nexport function getColumnPos(index, pos) {\n return pos ? \"\".concat(pos, \"-\").concat(index) : \"\".concat(index);\n}\nexport function renderColumnTitle(title, props) {\n if (typeof title === 'function') {\n return title(props);\n }\n\n return title;\n}","import _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport _toConsumableArray from \"@babel/runtime/helpers/toConsumableArray\";\nimport _typeof from \"@babel/runtime/helpers/typeof\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport CaretDownOutlined from '@ant-design/icons/CaretDownOutlined';\nimport CaretUpOutlined from '@ant-design/icons/CaretUpOutlined';\nimport Tooltip from '../../tooltip';\nimport { getColumnKey, getColumnPos, renderColumnTitle } from '../util';\nvar ASCEND = 'ascend';\nvar DESCEND = 'descend';\n\nfunction getMultiplePriority(column) {\n if (_typeof(column.sorter) === 'object' && typeof column.sorter.multiple === 'number') {\n return column.sorter.multiple;\n }\n\n return false;\n}\n\nfunction getSortFunction(sorter) {\n if (typeof sorter === 'function') {\n return sorter;\n }\n\n if (sorter && _typeof(sorter) === 'object' && sorter.compare) {\n return sorter.compare;\n }\n\n return false;\n}\n\nfunction nextSortDirection(sortDirections, current) {\n if (!current) {\n return sortDirections[0];\n }\n\n return sortDirections[sortDirections.indexOf(current) + 1];\n}\n\nfunction collectSortStates(columns, init, pos) {\n var sortStates = [];\n\n function pushState(column, columnPos) {\n sortStates.push({\n column: column,\n key: getColumnKey(column, columnPos),\n multiplePriority: getMultiplePriority(column),\n sortOrder: column.sortOrder\n });\n }\n\n (columns || []).forEach(function (column, index) {\n var columnPos = getColumnPos(index, pos);\n\n if (column.children) {\n if ('sortOrder' in column) {\n // Controlled\n pushState(column, columnPos);\n }\n\n sortStates = [].concat(_toConsumableArray(sortStates), _toConsumableArray(collectSortStates(column.children, init, columnPos)));\n } else if (column.sorter) {\n if ('sortOrder' in column) {\n // Controlled\n pushState(column, columnPos);\n } else if (init && column.defaultSortOrder) {\n // Default sorter\n sortStates.push({\n column: column,\n key: getColumnKey(column, columnPos),\n multiplePriority: getMultiplePriority(column),\n sortOrder: column.defaultSortOrder\n });\n }\n }\n });\n return sortStates;\n}\n\nfunction injectSorter(prefixCls, columns, sorterSates, triggerSorter, defaultSortDirections, tableLocale, tableShowSorterTooltip, pos) {\n return (columns || []).map(function (column, index) {\n var columnPos = getColumnPos(index, pos);\n var newColumn = column;\n\n if (newColumn.sorter) {\n var sortDirections = newColumn.sortDirections || defaultSortDirections;\n var showSorterTooltip = newColumn.showSorterTooltip === undefined ? tableShowSorterTooltip : newColumn.showSorterTooltip;\n var columnKey = getColumnKey(newColumn, columnPos);\n var sorterState = sorterSates.find(function (_ref) {\n var key = _ref.key;\n return key === columnKey;\n });\n var sorterOrder = sorterState ? sorterState.sortOrder : null;\n var nextSortOrder = nextSortDirection(sortDirections, sorterOrder);\n var upNode = sortDirections.includes(ASCEND) && /*#__PURE__*/React.createElement(CaretUpOutlined, {\n className: classNames(\"\".concat(prefixCls, \"-column-sorter-up\"), {\n active: sorterOrder === ASCEND\n })\n });\n var downNode = sortDirections.includes(DESCEND) && /*#__PURE__*/React.createElement(CaretDownOutlined, {\n className: classNames(\"\".concat(prefixCls, \"-column-sorter-down\"), {\n active: sorterOrder === DESCEND\n })\n });\n\n var _ref2 = tableLocale || {},\n cancelSort = _ref2.cancelSort,\n triggerAsc = _ref2.triggerAsc,\n triggerDesc = _ref2.triggerDesc;\n\n var sortTip = cancelSort;\n\n if (nextSortOrder === DESCEND) {\n sortTip = triggerDesc;\n } else if (nextSortOrder === ASCEND) {\n sortTip = triggerAsc;\n }\n\n newColumn = _extends(_extends({}, newColumn), {\n className: classNames(newColumn.className, _defineProperty({}, \"\".concat(prefixCls, \"-column-sort\"), sorterOrder)),\n title: function title(renderProps) {\n var renderSortTitle = /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-column-sorters\")\n }, /*#__PURE__*/React.createElement(\"span\", null, renderColumnTitle(column.title, renderProps)), /*#__PURE__*/React.createElement(\"span\", {\n className: classNames(\"\".concat(prefixCls, \"-column-sorter\"), _defineProperty({}, \"\".concat(prefixCls, \"-column-sorter-full\"), upNode && downNode))\n }, /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-column-sorter-inner\")\n }, upNode, downNode)));\n return showSorterTooltip ? /*#__PURE__*/React.createElement(Tooltip, {\n title: sortTip\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-column-sorters-with-tooltip\")\n }, renderSortTitle)) : renderSortTitle;\n },\n onHeaderCell: function onHeaderCell(col) {\n var cell = column.onHeaderCell && column.onHeaderCell(col) || {};\n var originOnClick = cell.onClick;\n\n cell.onClick = function (event) {\n triggerSorter({\n column: column,\n key: columnKey,\n sortOrder: nextSortOrder,\n multiplePriority: getMultiplePriority(column)\n });\n\n if (originOnClick) {\n originOnClick(event);\n }\n };\n\n cell.className = classNames(cell.className, \"\".concat(prefixCls, \"-column-has-sorters\"));\n return cell;\n }\n });\n }\n\n if ('children' in newColumn) {\n newColumn = _extends(_extends({}, newColumn), {\n children: injectSorter(prefixCls, newColumn.children, sorterSates, triggerSorter, defaultSortDirections, tableLocale, tableShowSorterTooltip, columnPos)\n });\n }\n\n return newColumn;\n });\n}\n\nfunction stateToInfo(sorterStates) {\n var column = sorterStates.column,\n sortOrder = sorterStates.sortOrder;\n return {\n column: column,\n order: sortOrder,\n field: column.dataIndex,\n columnKey: column.key\n };\n}\n\nfunction generateSorterInfo(sorterStates) {\n var list = sorterStates.filter(function (_ref3) {\n var sortOrder = _ref3.sortOrder;\n return sortOrder;\n }).map(stateToInfo); // =========== Legacy compatible support ===========\n // https://github.com/ant-design/ant-design/pull/19226\n\n if (list.length === 0 && sorterStates.length) {\n return _extends(_extends({}, stateToInfo(sorterStates[sorterStates.length - 1])), {\n column: undefined\n });\n }\n\n if (list.length <= 1) {\n return list[0] || {};\n }\n\n return list;\n}\n\nexport function getSortData(data, sortStates, childrenColumnName) {\n var innerSorterStates = sortStates.slice().sort(function (a, b) {\n return b.multiplePriority - a.multiplePriority;\n });\n var cloneData = data.slice();\n var runningSorters = innerSorterStates.filter(function (_ref4) {\n var sorter = _ref4.column.sorter,\n sortOrder = _ref4.sortOrder;\n return getSortFunction(sorter) && sortOrder;\n }); // Skip if no sorter needed\n\n if (!runningSorters.length) {\n return cloneData;\n }\n\n return cloneData.sort(function (record1, record2) {\n for (var i = 0; i < runningSorters.length; i += 1) {\n var sorterState = runningSorters[i];\n var sorter = sorterState.column.sorter,\n sortOrder = sorterState.sortOrder;\n var compareFn = getSortFunction(sorter);\n\n if (compareFn && sortOrder) {\n var compareResult = compareFn(record1, record2, sortOrder);\n\n if (compareResult !== 0) {\n return sortOrder === ASCEND ? compareResult : -compareResult;\n }\n }\n }\n\n return 0;\n }).map(function (record) {\n var subRecords = record[childrenColumnName];\n\n if (subRecords) {\n return _extends(_extends({}, record), _defineProperty({}, childrenColumnName, getSortData(subRecords, sortStates, childrenColumnName)));\n }\n\n return record;\n });\n}\nexport default function useFilterSorter(_ref5) {\n var prefixCls = _ref5.prefixCls,\n mergedColumns = _ref5.mergedColumns,\n onSorterChange = _ref5.onSorterChange,\n sortDirections = _ref5.sortDirections,\n tableLocale = _ref5.tableLocale,\n showSorterTooltip = _ref5.showSorterTooltip;\n\n var _React$useState = React.useState(collectSortStates(mergedColumns, true)),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n sortStates = _React$useState2[0],\n setSortStates = _React$useState2[1];\n\n var mergedSorterStates = React.useMemo(function () {\n var validate = true;\n var collectedStates = collectSortStates(mergedColumns, false); // Return if not controlled\n\n if (!collectedStates.length) {\n return sortStates;\n }\n\n var validateStates = [];\n\n function patchStates(state) {\n if (validate) {\n validateStates.push(state);\n } else {\n validateStates.push(_extends(_extends({}, state), {\n sortOrder: null\n }));\n }\n }\n\n var multipleMode = null;\n collectedStates.forEach(function (state) {\n if (multipleMode === null) {\n patchStates(state);\n\n if (state.sortOrder) {\n if (state.multiplePriority === false) {\n validate = false;\n } else {\n multipleMode = true;\n }\n }\n } else if (multipleMode && state.multiplePriority !== false) {\n patchStates(state);\n } else {\n validate = false;\n patchStates(state);\n }\n });\n return validateStates;\n }, [mergedColumns, sortStates]); // Get render columns title required props\n\n var columnTitleSorterProps = React.useMemo(function () {\n var sortColumns = mergedSorterStates.map(function (_ref6) {\n var column = _ref6.column,\n sortOrder = _ref6.sortOrder;\n return {\n column: column,\n order: sortOrder\n };\n });\n return {\n sortColumns: sortColumns,\n // Legacy\n sortColumn: sortColumns[0] && sortColumns[0].column,\n sortOrder: sortColumns[0] && sortColumns[0].order\n };\n }, [mergedSorterStates]);\n\n function triggerSorter(sortState) {\n var newSorterStates;\n\n if (sortState.multiplePriority === false || !mergedSorterStates.length || mergedSorterStates[0].multiplePriority === false) {\n newSorterStates = [sortState];\n } else {\n newSorterStates = [].concat(_toConsumableArray(mergedSorterStates.filter(function (_ref7) {\n var key = _ref7.key;\n return key !== sortState.key;\n })), [sortState]);\n }\n\n setSortStates(newSorterStates);\n onSorterChange(generateSorterInfo(newSorterStates), newSorterStates);\n }\n\n var transformColumns = function transformColumns(innerColumns) {\n return injectSorter(prefixCls, innerColumns, mergedSorterStates, triggerSorter, sortDirections, tableLocale, showSorterTooltip);\n };\n\n var getSorters = function getSorters() {\n return generateSorterInfo(mergedSorterStates);\n };\n\n return [transformColumns, mergedSorterStates, columnTitleSorterProps, getSorters];\n}","import * as React from 'react';\n\nvar FilterDropdownMenuWrapper = function FilterDropdownMenuWrapper(props) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: props.className,\n onClick: function onClick(e) {\n return e.stopPropagation();\n }\n }, props.children);\n};\n\nexport default FilterDropdownMenuWrapper;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport isEqual from 'lodash/isEqual';\nimport FilterFilled from '@ant-design/icons/FilterFilled';\nimport Button from '../../../button';\nimport Menu from '../../../menu';\nimport Checkbox from '../../../checkbox';\nimport Radio from '../../../radio';\nimport Dropdown from '../../../dropdown';\nimport Empty from '../../../empty';\nimport FilterDropdownMenuWrapper from './FilterWrapper';\nimport useSyncState from '../../../_util/hooks/useSyncState';\nimport { ConfigContext } from '../../../config-provider/context';\nvar SubMenu = Menu.SubMenu,\n MenuItem = Menu.Item;\n\nfunction hasSubMenu(filters) {\n return filters.some(function (_ref) {\n var children = _ref.children;\n return children;\n });\n}\n\nfunction renderFilterItems(_ref2) {\n var filters = _ref2.filters,\n prefixCls = _ref2.prefixCls,\n filteredKeys = _ref2.filteredKeys,\n filterMultiple = _ref2.filterMultiple,\n locale = _ref2.locale;\n\n if (filters.length === 0) {\n // wrapped with <>> to avoid react warning\n // https://github.com/ant-design/ant-design/issues/25979\n return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Empty, {\n image: Empty.PRESENTED_IMAGE_SIMPLE,\n description: locale.filterEmptyText,\n style: {\n margin: '16px 0'\n },\n imageStyle: {\n height: 24\n }\n }));\n }\n\n return filters.map(function (filter, index) {\n var key = String(filter.value);\n\n if (filter.children) {\n return /*#__PURE__*/React.createElement(SubMenu, {\n key: key || index,\n title: filter.text,\n popupClassName: \"\".concat(prefixCls, \"-dropdown-submenu\")\n }, renderFilterItems({\n filters: filter.children,\n prefixCls: prefixCls,\n filteredKeys: filteredKeys,\n filterMultiple: filterMultiple,\n locale: locale\n }));\n }\n\n var Component = filterMultiple ? Checkbox : Radio;\n return /*#__PURE__*/React.createElement(MenuItem, {\n key: filter.value !== undefined ? key : index\n }, /*#__PURE__*/React.createElement(Component, {\n checked: filteredKeys.includes(key)\n }), /*#__PURE__*/React.createElement(\"span\", null, filter.text));\n });\n}\n\nfunction FilterDropdown(props) {\n var _a;\n\n var prefixCls = props.prefixCls,\n column = props.column,\n dropdownPrefixCls = props.dropdownPrefixCls,\n columnKey = props.columnKey,\n filterMultiple = props.filterMultiple,\n filterState = props.filterState,\n triggerFilter = props.triggerFilter,\n locale = props.locale,\n children = props.children,\n getPopupContainer = props.getPopupContainer;\n var filterDropdownVisible = column.filterDropdownVisible,\n onFilterDropdownVisibleChange = column.onFilterDropdownVisibleChange;\n\n var _React$useState = React.useState(false),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n visible = _React$useState2[0],\n setVisible = _React$useState2[1];\n\n var filtered = !!(filterState && (((_a = filterState.filteredKeys) === null || _a === void 0 ? void 0 : _a.length) || filterState.forceFiltered));\n\n var triggerVisible = function triggerVisible(newVisible) {\n setVisible(newVisible);\n\n if (onFilterDropdownVisibleChange) {\n onFilterDropdownVisibleChange(newVisible);\n }\n };\n\n var mergedVisible = typeof filterDropdownVisible === 'boolean' ? filterDropdownVisible : visible; // ===================== Select Keys =====================\n\n var propFilteredKeys = filterState && filterState.filteredKeys;\n\n var _useSyncState = useSyncState(propFilteredKeys || []),\n _useSyncState2 = _slicedToArray(_useSyncState, 2),\n getFilteredKeysSync = _useSyncState2[0],\n setFilteredKeysSync = _useSyncState2[1];\n\n var onSelectKeys = function onSelectKeys(_ref3) {\n var selectedKeys = _ref3.selectedKeys;\n setFilteredKeysSync(selectedKeys);\n };\n\n React.useEffect(function () {\n onSelectKeys({\n selectedKeys: propFilteredKeys || []\n });\n }, [propFilteredKeys]); // ====================== Open Keys ======================\n\n var _React$useState3 = React.useState([]),\n _React$useState4 = _slicedToArray(_React$useState3, 2),\n openKeys = _React$useState4[0],\n setOpenKeys = _React$useState4[1];\n\n var openRef = React.useRef();\n\n var onOpenChange = function onOpenChange(keys) {\n openRef.current = window.setTimeout(function () {\n setOpenKeys(keys);\n });\n };\n\n var onMenuClick = function onMenuClick() {\n window.clearTimeout(openRef.current);\n };\n\n React.useEffect(function () {\n return function () {\n window.clearTimeout(openRef.current);\n };\n }, []); // ======================= Submit ========================\n\n var internalTriggerFilter = function internalTriggerFilter(keys) {\n triggerVisible(false);\n var mergedKeys = keys && keys.length ? keys : null;\n\n if (mergedKeys === null && (!filterState || !filterState.filteredKeys)) {\n return null;\n }\n\n if (isEqual(mergedKeys, filterState === null || filterState === void 0 ? void 0 : filterState.filteredKeys)) {\n return null;\n }\n\n triggerFilter({\n column: column,\n key: columnKey,\n filteredKeys: mergedKeys\n });\n };\n\n var onConfirm = function onConfirm() {\n internalTriggerFilter(getFilteredKeysSync());\n };\n\n var onReset = function onReset() {\n setFilteredKeysSync([]);\n internalTriggerFilter([]);\n };\n\n var onVisibleChange = function onVisibleChange(newVisible) {\n if (newVisible && propFilteredKeys !== undefined) {\n // Sync filteredKeys on appear in controlled mode (propFilteredKeys !== undefiend)\n setFilteredKeysSync(propFilteredKeys || []);\n }\n\n triggerVisible(newVisible); // Default will filter when closed\n\n if (!newVisible && !column.filterDropdown) {\n onConfirm();\n }\n }; // ======================== Style ========================\n\n\n var dropdownMenuClass = classNames(_defineProperty({}, \"\".concat(dropdownPrefixCls, \"-menu-without-submenu\"), !hasSubMenu(column.filters || [])));\n var dropdownContent;\n\n if (typeof column.filterDropdown === 'function') {\n dropdownContent = column.filterDropdown({\n prefixCls: \"\".concat(dropdownPrefixCls, \"-custom\"),\n setSelectedKeys: function setSelectedKeys(selectedKeys) {\n return onSelectKeys({\n selectedKeys: selectedKeys\n });\n },\n selectedKeys: getFilteredKeysSync(),\n confirm: onConfirm,\n clearFilters: onReset,\n filters: column.filters,\n visible: mergedVisible\n });\n } else if (column.filterDropdown) {\n dropdownContent = column.filterDropdown;\n } else {\n var selectedKeys = getFilteredKeysSync() || [];\n dropdownContent = /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Menu, {\n multiple: filterMultiple,\n prefixCls: \"\".concat(dropdownPrefixCls, \"-menu\"),\n className: dropdownMenuClass,\n onClick: onMenuClick,\n onSelect: onSelectKeys,\n onDeselect: onSelectKeys,\n selectedKeys: selectedKeys,\n getPopupContainer: getPopupContainer,\n openKeys: openKeys,\n onOpenChange: onOpenChange\n }, renderFilterItems({\n filters: column.filters || [],\n prefixCls: prefixCls,\n filteredKeys: getFilteredKeysSync(),\n filterMultiple: filterMultiple,\n locale: locale\n })), /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-dropdown-btns\")\n }, /*#__PURE__*/React.createElement(Button, {\n type: \"link\",\n size: \"small\",\n disabled: selectedKeys.length === 0,\n onClick: onReset\n }, locale.filterReset), /*#__PURE__*/React.createElement(Button, {\n type: \"primary\",\n size: \"small\",\n onClick: onConfirm\n }, locale.filterConfirm)));\n }\n\n var menu = /*#__PURE__*/React.createElement(FilterDropdownMenuWrapper, {\n className: \"\".concat(prefixCls, \"-dropdown\")\n }, dropdownContent);\n var filterIcon;\n\n if (typeof column.filterIcon === 'function') {\n filterIcon = column.filterIcon(filtered);\n } else if (column.filterIcon) {\n filterIcon = column.filterIcon;\n } else {\n filterIcon = /*#__PURE__*/React.createElement(FilterFilled, null);\n }\n\n var _React$useContext = React.useContext(ConfigContext),\n direction = _React$useContext.direction;\n\n return /*#__PURE__*/React.createElement(\"div\", {\n className: classNames(\"\".concat(prefixCls, \"-column\"))\n }, /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-column-title\")\n }, children), /*#__PURE__*/React.createElement(\"span\", {\n className: classNames(\"\".concat(prefixCls, \"-trigger-container\"), _defineProperty({}, \"\".concat(prefixCls, \"-trigger-container-open\"), mergedVisible)),\n onClick: function onClick(e) {\n e.stopPropagation();\n }\n }, /*#__PURE__*/React.createElement(Dropdown, {\n overlay: menu,\n trigger: ['click'],\n visible: mergedVisible,\n onVisibleChange: onVisibleChange,\n getPopupContainer: getPopupContainer,\n placement: direction === 'rtl' ? 'bottomLeft' : 'bottomRight'\n }, /*#__PURE__*/React.createElement(\"span\", {\n role: \"button\",\n tabIndex: -1,\n className: classNames(\"\".concat(prefixCls, \"-trigger\"), {\n active: filtered\n })\n }, filterIcon))));\n}\n\nexport default FilterDropdown;","import * as React from 'react';\nimport useForceUpdate from './useForceUpdate';\nexport default function useSyncState(initialValue) {\n var ref = React.useRef(initialValue);\n var forceUpdate = useForceUpdate();\n return [function () {\n return ref.current;\n }, function (newValue) {\n ref.current = newValue; // re-render\n\n forceUpdate();\n }];\n}","import _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport _toConsumableArray from \"@babel/runtime/helpers/toConsumableArray\";\nimport * as React from 'react';\nimport { getColumnPos, renderColumnTitle, getColumnKey } from '../../util';\nimport FilterDropdown from './FilterDropdown';\n\nfunction collectFilterStates(columns, init, pos) {\n var filterStates = [];\n (columns || []).forEach(function (column, index) {\n var columnPos = getColumnPos(index, pos);\n\n if ('children' in column) {\n filterStates = [].concat(_toConsumableArray(filterStates), _toConsumableArray(collectFilterStates(column.children, init, columnPos)));\n } else if (column.filters || 'filterDropdown' in column || 'onFilter' in column) {\n if ('filteredValue' in column) {\n // Controlled\n filterStates.push({\n column: column,\n key: getColumnKey(column, columnPos),\n filteredKeys: column.filteredValue,\n forceFiltered: column.filtered\n });\n } else {\n // Uncontrolled\n filterStates.push({\n column: column,\n key: getColumnKey(column, columnPos),\n filteredKeys: init && column.defaultFilteredValue ? column.defaultFilteredValue : undefined,\n forceFiltered: column.filtered\n });\n }\n }\n });\n return filterStates;\n}\n\nfunction injectFilter(prefixCls, dropdownPrefixCls, columns, filterStates, triggerFilter, getPopupContainer, locale, pos) {\n return columns.map(function (column, index) {\n var columnPos = getColumnPos(index, pos);\n var _column$filterMultipl = column.filterMultiple,\n filterMultiple = _column$filterMultipl === void 0 ? true : _column$filterMultipl;\n\n if (column.filters || 'filterDropdown' in column) {\n var columnKey = getColumnKey(column, columnPos);\n var filterState = filterStates.find(function (_ref) {\n var key = _ref.key;\n return columnKey === key;\n });\n return _extends(_extends({}, column), {\n title: function title(renderProps) {\n return /*#__PURE__*/React.createElement(FilterDropdown, {\n prefixCls: \"\".concat(prefixCls, \"-filter\"),\n dropdownPrefixCls: dropdownPrefixCls,\n column: column,\n columnKey: columnKey,\n filterState: filterState,\n filterMultiple: filterMultiple,\n triggerFilter: triggerFilter,\n locale: locale,\n getPopupContainer: getPopupContainer\n }, renderColumnTitle(column.title, renderProps));\n }\n });\n }\n\n if ('children' in column) {\n return _extends(_extends({}, column), {\n children: injectFilter(prefixCls, dropdownPrefixCls, column.children, filterStates, triggerFilter, getPopupContainer, locale, columnPos)\n });\n }\n\n return column;\n });\n}\n\nfunction generateFilterInfo(filterStates) {\n var currentFilters = {};\n filterStates.forEach(function (_ref2) {\n var key = _ref2.key,\n filteredKeys = _ref2.filteredKeys;\n currentFilters[key] = filteredKeys || null;\n });\n return currentFilters;\n}\n\nfunction flattenKeys(filters) {\n var keys = [];\n (filters || []).forEach(function (_ref3) {\n var value = _ref3.value,\n children = _ref3.children;\n keys.push(value);\n\n if (children) {\n keys = [].concat(_toConsumableArray(keys), _toConsumableArray(flattenKeys(children)));\n }\n });\n return keys;\n}\n\nexport function getFilterData(data, filterStates) {\n return filterStates.reduce(function (currentData, filterState) {\n var _filterState$column = filterState.column,\n onFilter = _filterState$column.onFilter,\n filters = _filterState$column.filters,\n filteredKeys = filterState.filteredKeys;\n\n if (onFilter && filteredKeys && filteredKeys.length) {\n return currentData.filter(function (record) {\n return filteredKeys.some(function (key) {\n var keys = flattenKeys(filters);\n var keyIndex = keys.findIndex(function (k) {\n return String(k) === String(key);\n });\n var realKey = keyIndex !== -1 ? keys[keyIndex] : key;\n return onFilter(realKey, record);\n });\n });\n }\n\n return currentData;\n }, data);\n}\n\nfunction useFilter(_ref4) {\n var prefixCls = _ref4.prefixCls,\n dropdownPrefixCls = _ref4.dropdownPrefixCls,\n mergedColumns = _ref4.mergedColumns,\n onFilterChange = _ref4.onFilterChange,\n getPopupContainer = _ref4.getPopupContainer,\n tableLocale = _ref4.locale;\n\n var _React$useState = React.useState(collectFilterStates(mergedColumns, true)),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n filterStates = _React$useState2[0],\n setFilterStates = _React$useState2[1];\n\n var mergedFilterStates = React.useMemo(function () {\n var collectedStates = collectFilterStates(mergedColumns, false); // Return if not controlled\n\n if (collectedStates.every(function (_ref5) {\n var filteredKeys = _ref5.filteredKeys;\n return filteredKeys === undefined;\n })) {\n return filterStates;\n }\n\n return collectedStates;\n }, [mergedColumns, filterStates]);\n var getFilters = React.useCallback(function () {\n return generateFilterInfo(mergedFilterStates);\n }, [mergedFilterStates]);\n\n var triggerFilter = function triggerFilter(filterState) {\n var newFilterStates = mergedFilterStates.filter(function (_ref6) {\n var key = _ref6.key;\n return key !== filterState.key;\n });\n newFilterStates.push(filterState);\n setFilterStates(newFilterStates);\n onFilterChange(generateFilterInfo(newFilterStates), newFilterStates);\n };\n\n var transformColumns = function transformColumns(innerColumns) {\n return injectFilter(prefixCls, dropdownPrefixCls, innerColumns, mergedFilterStates, triggerFilter, getPopupContainer, tableLocale);\n };\n\n return [transformColumns, mergedFilterStates, getFilters];\n}\n\nexport default useFilter;","import _extends from \"@babel/runtime/helpers/extends\";\nimport * as React from 'react';\nimport { renderColumnTitle } from '../util';\n\nfunction fillTitle(columns, columnTitleProps) {\n return columns.map(function (column) {\n var cloneColumn = _extends({}, column);\n\n cloneColumn.title = renderColumnTitle(column.title, columnTitleProps);\n\n if ('children' in cloneColumn) {\n cloneColumn.children = fillTitle(cloneColumn.children, columnTitleProps);\n }\n\n return cloneColumn;\n });\n}\n\nexport default function useTitleColumns(columnTitleProps) {\n var filledColumns = React.useCallback(function (columns) {\n return fillTitle(columns, columnTitleProps);\n }, [columnTitleProps]);\n return [filledColumns];\n}","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport * as React from 'react';\nimport classNames from 'classnames';\n\nfunction renderExpandIcon(locale) {\n return function expandIcon(_ref) {\n var _classNames;\n\n var prefixCls = _ref.prefixCls,\n onExpand = _ref.onExpand,\n record = _ref.record,\n expanded = _ref.expanded,\n expandable = _ref.expandable;\n var iconPrefix = \"\".concat(prefixCls, \"-row-expand-icon\");\n return /*#__PURE__*/React.createElement(\"button\", {\n type: \"button\",\n onClick: function onClick(e) {\n onExpand(record, e);\n e.stopPropagation();\n },\n className: classNames(iconPrefix, (_classNames = {}, _defineProperty(_classNames, \"\".concat(iconPrefix, \"-spaced\"), !expandable), _defineProperty(_classNames, \"\".concat(iconPrefix, \"-expanded\"), expandable && expanded), _defineProperty(_classNames, \"\".concat(iconPrefix, \"-collapsed\"), expandable && !expanded), _classNames)),\n \"aria-label\": expanded ? locale.collapse : locale.expand\n });\n };\n}\n\nexport default renderExpandIcon;","export function isWindow(obj) {\n return obj !== null && obj !== undefined && obj === obj.window;\n}\nexport default function getScroll(target, top) {\n if (typeof window === 'undefined') {\n return 0;\n }\n\n var method = top ? 'scrollTop' : 'scrollLeft';\n var result = 0;\n\n if (isWindow(target)) {\n result = target[top ? 'pageYOffset' : 'pageXOffset'];\n } else if (target instanceof Document) {\n result = target.documentElement[method];\n } else if (target) {\n result = target[method];\n }\n\n if (target && !isWindow(target) && typeof result !== 'number') {\n result = (target.ownerDocument || target).documentElement[method];\n }\n\n return result;\n}","// eslint-disable-next-line import/prefer-default-export\nexport function easeInOutCubic(t, b, c, d) {\n var cc = c - b;\n t /= d / 2;\n\n if (t < 1) {\n return cc / 2 * t * t * t + b;\n } // eslint-disable-next-line no-return-assign\n\n\n return cc / 2 * ((t -= 2) * t * t + 2) + b;\n}","import raf from 'raf';\nimport getScroll, { isWindow } from './getScroll';\nimport { easeInOutCubic } from './easings';\nexport default function scrollTo(y) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n var _options$getContainer = options.getContainer,\n getContainer = _options$getContainer === void 0 ? function () {\n return window;\n } : _options$getContainer,\n callback = options.callback,\n _options$duration = options.duration,\n duration = _options$duration === void 0 ? 450 : _options$duration;\n var container = getContainer();\n var scrollTop = getScroll(container, true);\n var startTime = Date.now();\n\n var frameFunc = function frameFunc() {\n var timestamp = Date.now();\n var time = timestamp - startTime;\n var nextScrollTop = easeInOutCubic(time > duration ? duration : time, scrollTop, y, duration);\n\n if (isWindow(container)) {\n container.scrollTo(window.pageXOffset, nextScrollTop);\n } else if (container instanceof HTMLDocument || container.constructor.name === 'HTMLDocument') {\n container.documentElement.scrollTop = nextScrollTop;\n } else {\n container.scrollTop = nextScrollTop;\n }\n\n if (time < duration) {\n raf(frameFunc);\n } else if (typeof callback === 'function') {\n callback();\n }\n };\n\n raf(frameFunc);\n}","import defaultLocale from './default';\nexport default defaultLocale;","/* istanbul ignore next */\n\n/**\n * This is a syntactic sugar for `columns` prop.\n * So HOC will not work on this.\n */\n// eslint-disable-next-line no-unused-vars\nfunction Column(_) {\n return null;\n}\n\nexport default Column;","/* istanbul ignore next */\n\n/**\n * This is a syntactic sugar for `columns` prop.\n * So HOC will not work on this.\n */\n// eslint-disable-next-line no-unused-vars\nfunction ColumnGroup(_) {\n return null;\n}\n\nexport default ColumnGroup;","import _typeof from \"@babel/runtime/helpers/typeof\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport RcTable, { Summary } from 'rc-table';\nimport { INTERNAL_HOOKS } from \"rc-table/es/Table\";\nimport { convertChildrenToColumns } from \"rc-table/es/hooks/useColumns\";\nimport Spin from '../spin';\nimport Pagination from '../pagination';\nimport { ConfigContext } from '../config-provider/context';\nimport usePagination, { DEFAULT_PAGE_SIZE, getPaginationParam } from './hooks/usePagination';\nimport useLazyKVMap from './hooks/useLazyKVMap';\nimport useSelection, { SELECTION_ALL, SELECTION_INVERT } from './hooks/useSelection';\nimport useSorter, { getSortData } from './hooks/useSorter';\nimport useFilter, { getFilterData } from './hooks/useFilter';\nimport useTitleColumns from './hooks/useTitleColumns';\nimport renderExpandIcon from './ExpandIcon';\nimport scrollTo from '../_util/scrollTo';\nimport defaultLocale from '../locale/en_US';\nimport SizeContext from '../config-provider/SizeContext';\nimport Column from './Column';\nimport ColumnGroup from './ColumnGroup';\nimport devWarning from '../_util/devWarning';\nimport useBreakpoint from '../grid/hooks/useBreakpoint';\nvar EMPTY_LIST = [];\n\nfunction Table(props) {\n var _classNames3;\n\n var customizePrefixCls = props.prefixCls,\n className = props.className,\n style = props.style,\n customizeSize = props.size,\n bordered = props.bordered,\n customizeDropdownPrefixCls = props.dropdownPrefixCls,\n dataSource = props.dataSource,\n pagination = props.pagination,\n rowSelection = props.rowSelection,\n rowKey = props.rowKey,\n rowClassName = props.rowClassName,\n columns = props.columns,\n children = props.children,\n legacyChildrenColumnName = props.childrenColumnName,\n onChange = props.onChange,\n getPopupContainer = props.getPopupContainer,\n loading = props.loading,\n expandIcon = props.expandIcon,\n expandable = props.expandable,\n expandedRowRender = props.expandedRowRender,\n expandIconColumnIndex = props.expandIconColumnIndex,\n indentSize = props.indentSize,\n scroll = props.scroll,\n sortDirections = props.sortDirections,\n locale = props.locale,\n _props$showSorterTool = props.showSorterTooltip,\n showSorterTooltip = _props$showSorterTool === void 0 ? true : _props$showSorterTool;\n devWarning(!(typeof rowKey === 'function' && rowKey.length > 1), 'Table', '`index` parameter of `rowKey` function is deprecated. There is no guarantee that it will work as expected.');\n var screens = useBreakpoint();\n var mergedColumns = React.useMemo(function () {\n var matched = new Set(Object.keys(screens).filter(function (m) {\n return screens[m];\n }));\n return (columns || convertChildrenToColumns(children)).filter(function (c) {\n return !c.responsive || c.responsive.some(function (r) {\n return matched.has(r);\n });\n });\n }, [children, columns, screens]);\n var tableProps = omit(props, ['className', 'style', 'columns']);\n var size = React.useContext(SizeContext);\n\n var _React$useContext = React.useContext(ConfigContext),\n _React$useContext$loc = _React$useContext.locale,\n contextLocale = _React$useContext$loc === void 0 ? defaultLocale : _React$useContext$loc,\n renderEmpty = _React$useContext.renderEmpty,\n direction = _React$useContext.direction;\n\n var mergedSize = customizeSize || size;\n\n var tableLocale = _extends(_extends({}, contextLocale.Table), locale);\n\n var rawData = dataSource || EMPTY_LIST;\n\n var _React$useContext2 = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext2.getPrefixCls;\n\n var prefixCls = getPrefixCls('table', customizePrefixCls);\n var dropdownPrefixCls = getPrefixCls('dropdown', customizeDropdownPrefixCls);\n\n var mergedExpandable = _extends({\n childrenColumnName: legacyChildrenColumnName,\n expandIconColumnIndex: expandIconColumnIndex\n }, expandable);\n\n var _mergedExpandable$chi = mergedExpandable.childrenColumnName,\n childrenColumnName = _mergedExpandable$chi === void 0 ? 'children' : _mergedExpandable$chi;\n var expandType = React.useMemo(function () {\n if (rawData.some(function (item) {\n var _a;\n\n return (_a = item) === null || _a === void 0 ? void 0 : _a[childrenColumnName];\n })) {\n return 'nest';\n }\n\n if (expandedRowRender || expandable && expandable.expandedRowRender) {\n return 'row';\n }\n\n return null;\n }, [rawData]);\n var internalRefs = {\n body: React.useRef()\n }; // ============================ RowKey ============================\n\n var getRowKey = React.useMemo(function () {\n if (typeof rowKey === 'function') {\n return rowKey;\n }\n\n return function (record) {\n var _a;\n\n return (_a = record) === null || _a === void 0 ? void 0 : _a[rowKey];\n };\n }, [rowKey]);\n\n var _useLazyKVMap = useLazyKVMap(rawData, childrenColumnName, getRowKey),\n _useLazyKVMap2 = _slicedToArray(_useLazyKVMap, 1),\n getRecordByKey = _useLazyKVMap2[0]; // ============================ Events =============================\n\n\n var changeEventInfo = {};\n\n var triggerOnChange = function triggerOnChange(info, action) {\n var reset = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n\n var changeInfo = _extends(_extends({}, changeEventInfo), info);\n\n if (reset) {\n changeEventInfo.resetPagination(); // Reset event param\n\n if (changeInfo.pagination.current) {\n changeInfo.pagination.current = 1;\n } // Trigger pagination events\n\n\n if (pagination && pagination.onChange) {\n pagination.onChange(1, changeInfo.pagination.pageSize);\n }\n }\n\n if (scroll && scroll.scrollToFirstRowOnChange !== false && internalRefs.body.current) {\n scrollTo(0, {\n getContainer: function getContainer() {\n return internalRefs.body.current;\n }\n });\n }\n\n if (onChange) {\n onChange(changeInfo.pagination, changeInfo.filters, changeInfo.sorter, {\n currentDataSource: getFilterData(getSortData(rawData, changeInfo.sorterStates, childrenColumnName), changeInfo.filterStates),\n action: action\n });\n }\n };\n /**\n * Controlled state in `columns` is not a good idea that makes too many code (1000+ line?)\n * to read state out and then put it back to title render.\n * Move these code into `hooks` but still too complex.\n * We should provides Table props like `sorter` & `filter` to handle control in next big version.\n */\n // ============================ Sorter =============================\n\n\n var onSorterChange = function onSorterChange(sorter, sorterStates) {\n triggerOnChange({\n sorter: sorter,\n sorterStates: sorterStates\n }, 'sort', false);\n };\n\n var _useSorter = useSorter({\n prefixCls: prefixCls,\n mergedColumns: mergedColumns,\n onSorterChange: onSorterChange,\n sortDirections: sortDirections || ['ascend', 'descend'],\n tableLocale: tableLocale,\n showSorterTooltip: showSorterTooltip\n }),\n _useSorter2 = _slicedToArray(_useSorter, 4),\n transformSorterColumns = _useSorter2[0],\n sortStates = _useSorter2[1],\n sorterTitleProps = _useSorter2[2],\n getSorters = _useSorter2[3];\n\n var sortedData = React.useMemo(function () {\n return getSortData(rawData, sortStates, childrenColumnName);\n }, [rawData, sortStates]);\n changeEventInfo.sorter = getSorters();\n changeEventInfo.sorterStates = sortStates; // ============================ Filter ============================\n\n var onFilterChange = function onFilterChange(filters, filterStates) {\n triggerOnChange({\n filters: filters,\n filterStates: filterStates\n }, 'filter', true);\n };\n\n var _useFilter = useFilter({\n prefixCls: prefixCls,\n locale: tableLocale,\n dropdownPrefixCls: dropdownPrefixCls,\n mergedColumns: mergedColumns,\n onFilterChange: onFilterChange,\n getPopupContainer: getPopupContainer\n }),\n _useFilter2 = _slicedToArray(_useFilter, 3),\n transformFilterColumns = _useFilter2[0],\n filterStates = _useFilter2[1],\n getFilters = _useFilter2[2];\n\n var mergedData = getFilterData(sortedData, filterStates);\n changeEventInfo.filters = getFilters();\n changeEventInfo.filterStates = filterStates; // ============================ Column ============================\n\n var columnTitleProps = React.useMemo(function () {\n return _extends({}, sorterTitleProps);\n }, [sorterTitleProps]);\n\n var _useTitleColumns = useTitleColumns(columnTitleProps),\n _useTitleColumns2 = _slicedToArray(_useTitleColumns, 1),\n transformTitleColumns = _useTitleColumns2[0]; // ========================== Pagination ==========================\n\n\n var onPaginationChange = function onPaginationChange(current, pageSize) {\n triggerOnChange({\n pagination: _extends(_extends({}, changeEventInfo.pagination), {\n current: current,\n pageSize: pageSize\n })\n }, 'paginate');\n };\n\n var _usePagination = usePagination(mergedData.length, pagination, onPaginationChange),\n _usePagination2 = _slicedToArray(_usePagination, 2),\n mergedPagination = _usePagination2[0],\n resetPagination = _usePagination2[1];\n\n changeEventInfo.pagination = pagination === false ? {} : getPaginationParam(pagination, mergedPagination);\n changeEventInfo.resetPagination = resetPagination; // ============================= Data =============================\n\n var pageData = React.useMemo(function () {\n if (pagination === false || !mergedPagination.pageSize) {\n return mergedData;\n }\n\n var _mergedPagination$cur = mergedPagination.current,\n current = _mergedPagination$cur === void 0 ? 1 : _mergedPagination$cur,\n total = mergedPagination.total,\n _mergedPagination$pag = mergedPagination.pageSize,\n pageSize = _mergedPagination$pag === void 0 ? DEFAULT_PAGE_SIZE : _mergedPagination$pag; // Dynamic table data\n\n if (mergedData.length < total) {\n if (mergedData.length > pageSize) {\n devWarning(false, 'Table', '`dataSource` length is less than `pagination.total` but large than `pagination.pageSize`. Please make sure your config correct data with async mode.');\n return mergedData.slice((current - 1) * pageSize, current * pageSize);\n }\n\n return mergedData;\n }\n\n return mergedData.slice((current - 1) * pageSize, current * pageSize);\n }, [!!pagination, mergedData, mergedPagination && mergedPagination.current, mergedPagination && mergedPagination.pageSize, mergedPagination && mergedPagination.total]); // ========================== Selections ==========================\n\n var _useSelection = useSelection(rowSelection, {\n prefixCls: prefixCls,\n data: mergedData,\n pageData: pageData,\n getRowKey: getRowKey,\n getRecordByKey: getRecordByKey,\n expandType: expandType,\n childrenColumnName: childrenColumnName,\n locale: tableLocale,\n expandIconColumnIndex: mergedExpandable.expandIconColumnIndex,\n getPopupContainer: getPopupContainer\n }),\n _useSelection2 = _slicedToArray(_useSelection, 2),\n transformSelectionColumns = _useSelection2[0],\n selectedKeySet = _useSelection2[1];\n\n var internalRowClassName = function internalRowClassName(record, index, indent) {\n var mergedRowClassName;\n\n if (typeof rowClassName === 'function') {\n mergedRowClassName = classNames(rowClassName(record, index, indent));\n } else {\n mergedRowClassName = classNames(rowClassName);\n }\n\n return classNames(_defineProperty({}, \"\".concat(prefixCls, \"-row-selected\"), selectedKeySet.has(getRowKey(record, index))), mergedRowClassName);\n }; // ========================== Expandable ==========================\n // Pass origin render status into `rc-table`, this can be removed when refactor with `rc-table`\n\n\n mergedExpandable.__PARENT_RENDER_ICON__ = mergedExpandable.expandIcon; // Customize expandable icon\n\n mergedExpandable.expandIcon = mergedExpandable.expandIcon || expandIcon || renderExpandIcon(tableLocale); // Adjust expand icon index, no overwrite expandIconColumnIndex if set.\n\n if (expandType === 'nest' && mergedExpandable.expandIconColumnIndex === undefined) {\n mergedExpandable.expandIconColumnIndex = rowSelection ? 1 : 0;\n } else if (mergedExpandable.expandIconColumnIndex > 0 && rowSelection) {\n mergedExpandable.expandIconColumnIndex -= 1;\n } // Indent size\n\n\n if (typeof mergedExpandable.indentSize !== 'number') {\n mergedExpandable.indentSize = typeof indentSize === 'number' ? indentSize : 15;\n } // ============================ Render ============================\n\n\n var transformColumns = React.useCallback(function (innerColumns) {\n return transformTitleColumns(transformSelectionColumns(transformFilterColumns(transformSorterColumns(innerColumns))));\n }, [transformSorterColumns, transformFilterColumns, transformSelectionColumns]);\n var topPaginationNode;\n var bottomPaginationNode;\n\n if (pagination !== false) {\n var paginationSize;\n\n if (mergedPagination.size) {\n paginationSize = mergedPagination.size;\n } else {\n paginationSize = mergedSize === 'small' || mergedSize === 'middle' ? 'small' : undefined;\n }\n\n var renderPagination = function renderPagination(position) {\n return /*#__PURE__*/React.createElement(Pagination, _extends({\n className: \"\".concat(prefixCls, \"-pagination \").concat(prefixCls, \"-pagination-\").concat(position)\n }, mergedPagination, {\n size: paginationSize\n }));\n };\n\n var defaultPosition = direction === 'rtl' ? 'left' : 'right';\n\n if (mergedPagination.position !== null && Array.isArray(mergedPagination.position)) {\n var topPos = mergedPagination.position.find(function (p) {\n return p.indexOf('top') !== -1;\n });\n var bottomPos = mergedPagination.position.find(function (p) {\n return p.indexOf('bottom') !== -1;\n });\n\n if (!topPos && !bottomPos) {\n bottomPaginationNode = renderPagination(defaultPosition);\n } else {\n if (topPos) {\n topPaginationNode = renderPagination(topPos.toLowerCase().replace('top', ''));\n }\n\n if (bottomPos) {\n bottomPaginationNode = renderPagination(bottomPos.toLowerCase().replace('bottom', ''));\n }\n }\n } else {\n bottomPaginationNode = renderPagination(defaultPosition);\n }\n } // >>>>>>>>> Spinning\n\n\n var spinProps;\n\n if (typeof loading === 'boolean') {\n spinProps = {\n spinning: loading\n };\n } else if (_typeof(loading) === 'object') {\n spinProps = _extends({\n spinning: true\n }, loading);\n }\n\n var wrapperClassNames = classNames(\"\".concat(prefixCls, \"-wrapper\"), className, _defineProperty({}, \"\".concat(prefixCls, \"-wrapper-rtl\"), direction === 'rtl'));\n return /*#__PURE__*/React.createElement(\"div\", {\n className: wrapperClassNames,\n style: style\n }, /*#__PURE__*/React.createElement(Spin, _extends({\n spinning: false\n }, spinProps), topPaginationNode, /*#__PURE__*/React.createElement(RcTable, _extends({}, tableProps, {\n columns: mergedColumns,\n direction: direction,\n expandable: mergedExpandable,\n prefixCls: prefixCls,\n className: classNames((_classNames3 = {}, _defineProperty(_classNames3, \"\".concat(prefixCls, \"-middle\"), mergedSize === 'middle'), _defineProperty(_classNames3, \"\".concat(prefixCls, \"-small\"), mergedSize === 'small'), _defineProperty(_classNames3, \"\".concat(prefixCls, \"-bordered\"), bordered), _defineProperty(_classNames3, \"\".concat(prefixCls, \"-empty\"), rawData.length === 0), _classNames3)),\n data: pageData,\n rowKey: getRowKey,\n rowClassName: internalRowClassName,\n emptyText: locale && locale.emptyText || renderEmpty('Table') // Internal\n ,\n internalHooks: INTERNAL_HOOKS,\n internalRefs: internalRefs,\n transformColumns: transformColumns\n })), mergedData && mergedData.length > 0 && bottomPaginationNode));\n}\n\nTable.defaultProps = {\n rowKey: 'key'\n};\nTable.SELECTION_ALL = SELECTION_ALL;\nTable.SELECTION_INVERT = SELECTION_INVERT;\nTable.Column = Column;\nTable.ColumnGroup = ColumnGroup;\nTable.Summary = Summary;\nexport default Table;","import _typeof from \"@babel/runtime/helpers/typeof\";\nimport * as React from 'react';\nexport default function useLazyKVMap(data, childrenColumnName, getRowKey) {\n var mapCacheRef = React.useRef({});\n\n function getRecordByKey(key) {\n if (!mapCacheRef.current || mapCacheRef.current.data !== data || mapCacheRef.current.childrenColumnName !== childrenColumnName || mapCacheRef.current.getRowKey !== getRowKey) {\n /* eslint-disable no-inner-declarations */\n var dig = function dig(records) {\n records.forEach(function (record, index) {\n var rowKey = getRowKey(record, index);\n kvMap.set(rowKey, record);\n\n if (record && _typeof(record) === 'object' && childrenColumnName in record) {\n dig(record[childrenColumnName] || []);\n }\n });\n };\n /* eslint-enable */\n\n\n var kvMap = new Map();\n dig(data);\n mapCacheRef.current = {\n data: data,\n childrenColumnName: childrenColumnName,\n kvMap: kvMap,\n getRowKey: getRowKey\n };\n }\n\n return mapCacheRef.current.kvMap.get(key);\n }\n\n return [getRecordByKey];\n}","import Table from './Table';\nexport default Table;","var autoAdjustOverflow = {\n adjustX: 1,\n adjustY: 1\n};\nvar targetOffset = [0, 0];\nvar placements = {\n topLeft: {\n points: ['bl', 'tl'],\n overflow: autoAdjustOverflow,\n offset: [0, -4],\n targetOffset: targetOffset\n },\n topCenter: {\n points: ['bc', 'tc'],\n overflow: autoAdjustOverflow,\n offset: [0, -4],\n targetOffset: targetOffset\n },\n topRight: {\n points: ['br', 'tr'],\n overflow: autoAdjustOverflow,\n offset: [0, -4],\n targetOffset: targetOffset\n },\n bottomLeft: {\n points: ['tl', 'bl'],\n overflow: autoAdjustOverflow,\n offset: [0, 4],\n targetOffset: targetOffset\n },\n bottomCenter: {\n points: ['tc', 'bc'],\n overflow: autoAdjustOverflow,\n offset: [0, 4],\n targetOffset: targetOffset\n },\n bottomRight: {\n points: ['tr', 'br'],\n overflow: autoAdjustOverflow,\n offset: [0, 4],\n targetOffset: targetOffset\n }\n};\nexport default placements;","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport Trigger from 'rc-trigger';\nimport classNames from 'classnames';\nimport Placements from './placements';\n\nfunction Dropdown(props, ref) {\n var _props$arrow = props.arrow,\n arrow = _props$arrow === void 0 ? false : _props$arrow,\n _props$prefixCls = props.prefixCls,\n prefixCls = _props$prefixCls === void 0 ? 'rc-dropdown' : _props$prefixCls,\n transitionName = props.transitionName,\n animation = props.animation,\n align = props.align,\n _props$placement = props.placement,\n placement = _props$placement === void 0 ? 'bottomLeft' : _props$placement,\n _props$placements = props.placements,\n placements = _props$placements === void 0 ? Placements : _props$placements,\n getPopupContainer = props.getPopupContainer,\n showAction = props.showAction,\n hideAction = props.hideAction,\n overlayClassName = props.overlayClassName,\n overlayStyle = props.overlayStyle,\n visible = props.visible,\n _props$trigger = props.trigger,\n trigger = _props$trigger === void 0 ? ['hover'] : _props$trigger,\n otherProps = _objectWithoutProperties(props, [\"arrow\", \"prefixCls\", \"transitionName\", \"animation\", \"align\", \"placement\", \"placements\", \"getPopupContainer\", \"showAction\", \"hideAction\", \"overlayClassName\", \"overlayStyle\", \"visible\", \"trigger\"]);\n\n var _React$useState = React.useState(),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n triggerVisible = _React$useState2[0],\n setTriggerVisible = _React$useState2[1];\n\n var mergedVisible = 'visible' in props ? visible : triggerVisible;\n var triggerRef = React.useRef(null);\n React.useImperativeHandle(ref, function () {\n return triggerRef.current;\n });\n\n var getOverlayElement = function getOverlayElement() {\n var overlay = props.overlay;\n var overlayElement;\n\n if (typeof overlay === 'function') {\n overlayElement = overlay();\n } else {\n overlayElement = overlay;\n }\n\n return overlayElement;\n };\n\n var onClick = function onClick(e) {\n var onOverlayClick = props.onOverlayClick;\n var overlayProps = getOverlayElement().props;\n setTriggerVisible(false);\n\n if (onOverlayClick) {\n onOverlayClick(e);\n }\n\n if (overlayProps.onClick) {\n overlayProps.onClick(e);\n }\n };\n\n var onVisibleChange = function onVisibleChange(visible) {\n var onVisibleChange = props.onVisibleChange;\n setTriggerVisible(visible);\n\n if (typeof onVisibleChange === 'function') {\n onVisibleChange(visible);\n }\n };\n\n var getMenuElement = function getMenuElement() {\n var overlayElement = getOverlayElement();\n var extraOverlayProps = {\n prefixCls: \"\".concat(prefixCls, \"-menu\"),\n onClick: onClick\n };\n\n if (typeof overlayElement.type === 'string') {\n delete extraOverlayProps.prefixCls;\n }\n\n return React.createElement(React.Fragment, null, arrow && React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-arrow\")\n }), React.cloneElement(overlayElement, extraOverlayProps));\n };\n\n var getMenuElementOrLambda = function getMenuElementOrLambda() {\n var overlay = props.overlay;\n\n if (typeof overlay === 'function') {\n return getMenuElement;\n }\n\n return getMenuElement();\n };\n\n var getMinOverlayWidthMatchTrigger = function getMinOverlayWidthMatchTrigger() {\n var minOverlayWidthMatchTrigger = props.minOverlayWidthMatchTrigger,\n alignPoint = props.alignPoint;\n\n if ('minOverlayWidthMatchTrigger' in props) {\n return minOverlayWidthMatchTrigger;\n }\n\n return !alignPoint;\n };\n\n var getOpenClassName = function getOpenClassName() {\n var openClassName = props.openClassName;\n\n if (openClassName !== undefined) {\n return openClassName;\n }\n\n return \"\".concat(prefixCls, \"-open\");\n };\n\n var renderChildren = function renderChildren() {\n var children = props.children;\n var childrenProps = children.props ? children.props : {};\n var childClassName = classNames(childrenProps.className, getOpenClassName());\n return triggerVisible && children ? React.cloneElement(children, {\n className: childClassName\n }) : children;\n };\n\n var triggerHideAction = hideAction;\n\n if (!triggerHideAction && trigger.indexOf('contextMenu') !== -1) {\n triggerHideAction = ['click'];\n }\n\n return React.createElement(Trigger, Object.assign({}, otherProps, {\n prefixCls: prefixCls,\n ref: triggerRef,\n popupClassName: classNames(overlayClassName, _defineProperty({}, \"\".concat(prefixCls, \"-show-arrow\"), arrow)),\n popupStyle: overlayStyle,\n builtinPlacements: placements,\n action: trigger,\n showAction: showAction,\n hideAction: triggerHideAction || [],\n popupPlacement: placement,\n popupAlign: align,\n popupTransitionName: transitionName,\n popupAnimation: animation,\n popupVisible: mergedVisible,\n stretch: getMinOverlayWidthMatchTrigger() ? 'minWidth' : '',\n popup: getMenuElementOrLambda(),\n onPopupVisibleChange: onVisibleChange,\n getPopupContainer: getPopupContainer\n }), renderChildren());\n}\n\nexport default React.forwardRef(Dropdown);","import Dropdown from './Dropdown';\nexport default Dropdown;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport EllipsisOutlined from '@ant-design/icons/EllipsisOutlined';\nimport Button from '../button';\nimport { ConfigContext } from '../config-provider';\nimport Dropdown from './dropdown';\nvar ButtonGroup = Button.Group;\n\nvar DropdownButton = function DropdownButton(props) {\n var _React$useContext = React.useContext(ConfigContext),\n getContextPopupContainer = _React$useContext.getPopupContainer,\n getPrefixCls = _React$useContext.getPrefixCls,\n direction = _React$useContext.direction;\n\n var customizePrefixCls = props.prefixCls,\n type = props.type,\n disabled = props.disabled,\n onClick = props.onClick,\n htmlType = props.htmlType,\n children = props.children,\n className = props.className,\n overlay = props.overlay,\n trigger = props.trigger,\n align = props.align,\n visible = props.visible,\n onVisibleChange = props.onVisibleChange,\n placement = props.placement,\n getPopupContainer = props.getPopupContainer,\n href = props.href,\n _props$icon = props.icon,\n icon = _props$icon === void 0 ? /*#__PURE__*/React.createElement(EllipsisOutlined, null) : _props$icon,\n title = props.title,\n buttonsRender = props.buttonsRender,\n restProps = __rest(props, [\"prefixCls\", \"type\", \"disabled\", \"onClick\", \"htmlType\", \"children\", \"className\", \"overlay\", \"trigger\", \"align\", \"visible\", \"onVisibleChange\", \"placement\", \"getPopupContainer\", \"href\", \"icon\", \"title\", \"buttonsRender\"]);\n\n var prefixCls = getPrefixCls('dropdown-button', customizePrefixCls);\n var dropdownProps = {\n align: align,\n overlay: overlay,\n disabled: disabled,\n trigger: disabled ? [] : trigger,\n onVisibleChange: onVisibleChange,\n getPopupContainer: getPopupContainer || getContextPopupContainer\n };\n\n if ('visible' in props) {\n dropdownProps.visible = visible;\n }\n\n if ('placement' in props) {\n dropdownProps.placement = placement;\n } else {\n dropdownProps.placement = direction === 'rtl' ? 'bottomLeft' : 'bottomRight';\n }\n\n var leftButton = /*#__PURE__*/React.createElement(Button, {\n type: type,\n disabled: disabled,\n onClick: onClick,\n htmlType: htmlType,\n href: href,\n title: title\n }, children);\n var rightButton = /*#__PURE__*/React.createElement(Button, {\n type: type,\n icon: icon\n });\n\n var _buttonsRender = buttonsRender([leftButton, rightButton]),\n _buttonsRender2 = _slicedToArray(_buttonsRender, 2),\n leftButtonToRender = _buttonsRender2[0],\n rightButtonToRender = _buttonsRender2[1];\n\n return /*#__PURE__*/React.createElement(ButtonGroup, _extends({}, restProps, {\n className: classNames(prefixCls, className)\n }), leftButtonToRender, /*#__PURE__*/React.createElement(Dropdown, dropdownProps, rightButtonToRender));\n};\n\nDropdownButton.__ANT_BUTTON = true;\nDropdownButton.defaultProps = {\n type: 'default',\n buttonsRender: function buttonsRender(buttons) {\n return buttons;\n }\n};\nexport default DropdownButton;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport * as React from 'react';\nimport RcDropdown from 'rc-dropdown';\nimport classNames from 'classnames';\nimport RightOutlined from '@ant-design/icons/RightOutlined';\nimport DropdownButton from './dropdown-button';\nimport { ConfigContext } from '../config-provider';\nimport devWarning from '../_util/devWarning';\nimport { tuple } from '../_util/type';\nimport { cloneElement } from '../_util/reactNode';\nvar Placements = tuple('topLeft', 'topCenter', 'topRight', 'bottomLeft', 'bottomCenter', 'bottomRight');\n\nvar Dropdown = function Dropdown(props) {\n var _React$useContext = React.useContext(ConfigContext),\n getContextPopupContainer = _React$useContext.getPopupContainer,\n getPrefixCls = _React$useContext.getPrefixCls,\n direction = _React$useContext.direction;\n\n var getTransitionName = function getTransitionName() {\n var _props$placement = props.placement,\n placement = _props$placement === void 0 ? '' : _props$placement,\n transitionName = props.transitionName;\n\n if (transitionName !== undefined) {\n return transitionName;\n }\n\n if (placement.indexOf('top') >= 0) {\n return 'slide-down';\n }\n\n return 'slide-up';\n };\n\n var renderOverlay = function renderOverlay(prefixCls) {\n // rc-dropdown already can process the function of overlay, but we have check logic here.\n // So we need render the element to check and pass back to rc-dropdown.\n var overlay = props.overlay;\n var overlayNode;\n\n if (typeof overlay === 'function') {\n overlayNode = overlay();\n } else {\n overlayNode = overlay;\n }\n\n overlayNode = React.Children.only(typeof overlayNode === 'string' ? /*#__PURE__*/React.createElement(\"span\", null, overlayNode) : overlayNode);\n var overlayProps = overlayNode.props; // Warning if use other mode\n\n devWarning(!overlayProps.mode || overlayProps.mode === 'vertical', 'Dropdown', \"mode=\\\"\".concat(overlayProps.mode, \"\\\" is not supported for Dropdown's Menu.\")); // menu cannot be selectable in dropdown defaultly\n // menu should be focusable in dropdown defaultly\n\n var _overlayProps$selecta = overlayProps.selectable,\n selectable = _overlayProps$selecta === void 0 ? false : _overlayProps$selecta,\n _overlayProps$focusab = overlayProps.focusable,\n focusable = _overlayProps$focusab === void 0 ? true : _overlayProps$focusab;\n var expandIcon = /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-menu-submenu-arrow\")\n }, /*#__PURE__*/React.createElement(RightOutlined, {\n className: \"\".concat(prefixCls, \"-menu-submenu-arrow-icon\")\n }));\n var fixedModeOverlay = typeof overlayNode.type === 'string' ? overlayNode : cloneElement(overlayNode, {\n mode: 'vertical',\n selectable: selectable,\n focusable: focusable,\n expandIcon: expandIcon\n });\n return fixedModeOverlay;\n };\n\n var getPlacement = function getPlacement() {\n var placement = props.placement;\n\n if (placement !== undefined) {\n return placement;\n }\n\n return direction === 'rtl' ? 'bottomRight' : 'bottomLeft';\n };\n\n var arrow = props.arrow,\n customizePrefixCls = props.prefixCls,\n children = props.children,\n trigger = props.trigger,\n disabled = props.disabled,\n getPopupContainer = props.getPopupContainer,\n overlayClassName = props.overlayClassName;\n var prefixCls = getPrefixCls('dropdown', customizePrefixCls);\n var child = React.Children.only(children);\n var dropdownTrigger = cloneElement(child, {\n className: classNames(child.props.className, \"\".concat(prefixCls, \"-trigger\"), _defineProperty({}, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl')),\n disabled: disabled\n });\n var overlayClassNameCustomized = classNames(overlayClassName, _defineProperty({}, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'));\n var triggerActions = disabled ? [] : trigger;\n var alignPoint;\n\n if (triggerActions && triggerActions.indexOf('contextMenu') !== -1) {\n alignPoint = true;\n }\n\n return /*#__PURE__*/React.createElement(RcDropdown, _extends({\n arrow: arrow,\n alignPoint: alignPoint\n }, props, {\n overlayClassName: overlayClassNameCustomized,\n prefixCls: prefixCls,\n getPopupContainer: getPopupContainer || getContextPopupContainer,\n transitionName: getTransitionName(),\n trigger: triggerActions,\n overlay: function overlay() {\n return renderOverlay(prefixCls);\n },\n placement: getPlacement()\n }), dropdownTrigger);\n};\n\nDropdown.Button = DropdownButton;\nDropdown.defaultProps = {\n mouseEnterDelay: 0.15,\n mouseLeaveDelay: 0.1\n};\nexport default Dropdown;","import Dropdown from './dropdown';\nexport default Dropdown;","import _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\n\nvar UnreachableException = function UnreachableException(value) {\n _classCallCheck(this, UnreachableException);\n\n return new Error(\"unreachable case: \".concat(JSON.stringify(value)));\n};\n\nexport { UnreachableException as default };","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { ConfigConsumer } from '../config-provider';\nimport UnreachableException from '../_util/unreachableException';\n\nvar ButtonGroup = function ButtonGroup(props) {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, function (_ref) {\n var _classNames;\n\n var getPrefixCls = _ref.getPrefixCls,\n direction = _ref.direction;\n\n var customizePrefixCls = props.prefixCls,\n size = props.size,\n className = props.className,\n others = __rest(props, [\"prefixCls\", \"size\", \"className\"]);\n\n var prefixCls = getPrefixCls('btn-group', customizePrefixCls); // large => lg\n // small => sm\n\n var sizeCls = '';\n\n switch (size) {\n case 'large':\n sizeCls = 'lg';\n break;\n\n case 'small':\n sizeCls = 'sm';\n break;\n\n case 'middle':\n case undefined:\n break;\n\n default:\n // eslint-disable-next-line no-console\n console.warn(new UnreachableException(size));\n }\n\n var classes = classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(sizeCls), sizeCls), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _classNames), className);\n return /*#__PURE__*/React.createElement(\"div\", _extends({}, others, {\n className: classes\n }));\n });\n};\n\nexport default ButtonGroup;","import * as React from 'react';\nimport classNames from 'classnames';\nimport CSSMotion from 'rc-motion';\nimport LoadingOutlined from '@ant-design/icons/LoadingOutlined';\n\nvar getCollapsedWidth = function getCollapsedWidth() {\n return {\n width: 0,\n opacity: 0,\n transform: 'scale(0)'\n };\n};\n\nvar getRealWidth = function getRealWidth(node) {\n return {\n width: node.scrollWidth,\n opacity: 1,\n transform: 'scale(1)'\n };\n};\n\nexport default function LoadingIcon(_ref) {\n var prefixCls = _ref.prefixCls,\n loading = _ref.loading,\n existIcon = _ref.existIcon;\n var visible = !!loading;\n\n if (existIcon) {\n return /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-loading-icon\")\n }, /*#__PURE__*/React.createElement(LoadingOutlined, null));\n }\n\n return /*#__PURE__*/React.createElement(CSSMotion, {\n visible: visible // We do not really use this motionName\n ,\n motionName: \"\".concat(prefixCls, \"-loading-icon-motion\"),\n removeOnLeave: true,\n onAppearStart: getCollapsedWidth,\n onAppearActive: getRealWidth,\n onEnterStart: getCollapsedWidth,\n onEnterActive: getRealWidth,\n onLeaveStart: getRealWidth,\n onLeaveActive: getCollapsedWidth\n }, function (_ref2, ref) {\n var className = _ref2.className,\n style = _ref2.style;\n return /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-loading-icon\"),\n style: style,\n ref: ref\n }, /*#__PURE__*/React.createElement(LoadingOutlined, {\n className: classNames(className)\n }));\n });\n}","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport _typeof from \"@babel/runtime/helpers/typeof\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n/* eslint-disable react/button-has-type */\n\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport Group from './button-group';\nimport { ConfigContext } from '../config-provider';\nimport Wave from '../_util/wave';\nimport { tuple } from '../_util/type';\nimport devWarning from '../_util/devWarning';\nimport SizeContext from '../config-provider/SizeContext';\nimport LoadingIcon from './LoadingIcon';\nimport { cloneElement } from '../_util/reactNode';\nvar rxTwoCNChar = /^[\\u4e00-\\u9fa5]{2}$/;\nvar isTwoCNChar = rxTwoCNChar.test.bind(rxTwoCNChar);\n\nfunction isString(str) {\n return typeof str === 'string';\n}\n\nfunction isUnborderedButtonType(type) {\n return type === 'text' || type === 'link';\n} // Insert one space between two chinese characters automatically.\n\n\nfunction insertSpace(child, needInserted) {\n // Check the child if is undefined or null.\n if (child == null) {\n return;\n }\n\n var SPACE = needInserted ? ' ' : ''; // strictNullChecks oops.\n\n if (typeof child !== 'string' && typeof child !== 'number' && isString(child.type) && isTwoCNChar(child.props.children)) {\n return cloneElement(child, {\n children: child.props.children.split('').join(SPACE)\n });\n }\n\n if (typeof child === 'string') {\n if (isTwoCNChar(child)) {\n child = child.split('').join(SPACE);\n }\n\n return /*#__PURE__*/React.createElement(\"span\", null, child);\n }\n\n return child;\n}\n\nfunction spaceChildren(children, needInserted) {\n var isPrevChildPure = false;\n var childList = [];\n React.Children.forEach(children, function (child) {\n var type = _typeof(child);\n\n var isCurrentChildPure = type === 'string' || type === 'number';\n\n if (isPrevChildPure && isCurrentChildPure) {\n var lastIndex = childList.length - 1;\n var lastChild = childList[lastIndex];\n childList[lastIndex] = \"\".concat(lastChild).concat(child);\n } else {\n childList.push(child);\n }\n\n isPrevChildPure = isCurrentChildPure;\n }); // Pass to React.Children.map to auto fill key\n\n return React.Children.map(childList, function (child) {\n return insertSpace(child, needInserted);\n });\n}\n\nvar ButtonTypes = tuple('default', 'primary', 'ghost', 'dashed', 'link', 'text');\nvar ButtonShapes = tuple('circle', 'circle-outline', 'round');\nvar ButtonHTMLTypes = tuple('submit', 'button', 'reset');\nexport function convertLegacyProps(type) {\n if (type === 'danger') {\n return {\n danger: true\n };\n }\n\n return {\n type: type\n };\n}\n\nvar InternalButton = function InternalButton(props, ref) {\n var _classNames;\n\n var loading = props.loading,\n customizePrefixCls = props.prefixCls,\n type = props.type,\n danger = props.danger,\n shape = props.shape,\n customizeSize = props.size,\n className = props.className,\n children = props.children,\n icon = props.icon,\n ghost = props.ghost,\n block = props.block,\n rest = __rest(props, [\"loading\", \"prefixCls\", \"type\", \"danger\", \"shape\", \"size\", \"className\", \"children\", \"icon\", \"ghost\", \"block\"]);\n\n var size = React.useContext(SizeContext);\n\n var _React$useState = React.useState(!!loading),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n innerLoading = _React$useState2[0],\n setLoading = _React$useState2[1];\n\n var _React$useState3 = React.useState(false),\n _React$useState4 = _slicedToArray(_React$useState3, 2),\n hasTwoCNChar = _React$useState4[0],\n setHasTwoCNChar = _React$useState4[1];\n\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls,\n autoInsertSpaceInButton = _React$useContext.autoInsertSpaceInButton,\n direction = _React$useContext.direction;\n\n var buttonRef = ref || /*#__PURE__*/React.createRef();\n var delayTimeoutRef = React.useRef();\n\n var isNeedInserted = function isNeedInserted() {\n return React.Children.count(children) === 1 && !icon && !isUnborderedButtonType(type);\n };\n\n var fixTwoCNChar = function fixTwoCNChar() {\n // Fix for HOC usage like \n if (!buttonRef || !buttonRef.current || autoInsertSpaceInButton === false) {\n return;\n }\n\n var buttonText = buttonRef.current.textContent;\n\n if (isNeedInserted() && isTwoCNChar(buttonText)) {\n if (!hasTwoCNChar) {\n setHasTwoCNChar(true);\n }\n } else if (hasTwoCNChar) {\n setHasTwoCNChar(false);\n }\n }; // =============== Update Loading ===============\n\n\n var loadingOrDelay;\n\n if (_typeof(loading) === 'object' && loading.delay) {\n loadingOrDelay = loading.delay || true;\n } else {\n loadingOrDelay = !!loading;\n }\n\n React.useEffect(function () {\n clearTimeout(delayTimeoutRef.current);\n\n if (typeof loadingOrDelay === 'number') {\n delayTimeoutRef.current = window.setTimeout(function () {\n setLoading(loadingOrDelay);\n }, loadingOrDelay);\n } else {\n setLoading(loadingOrDelay);\n }\n }, [loadingOrDelay]);\n React.useEffect(function () {\n fixTwoCNChar();\n }, [buttonRef]);\n\n var handleClick = function handleClick(e) {\n var onClick = props.onClick;\n\n if (innerLoading) {\n return;\n }\n\n if (onClick) {\n onClick(e);\n }\n };\n\n devWarning(!(typeof icon === 'string' && icon.length > 2), 'Button', \"`icon` is using ReactNode instead of string naming in v4. Please check `\".concat(icon, \"` at https://ant.design/components/icon\"));\n devWarning(!(ghost && isUnborderedButtonType(type)), 'Button', \"`link` or `text` button can't be a `ghost` button.\");\n var prefixCls = getPrefixCls('btn', customizePrefixCls);\n var autoInsertSpace = autoInsertSpaceInButton !== false; // large => lg\n // small => sm\n\n var sizeCls = '';\n\n switch (customizeSize || size) {\n case 'large':\n sizeCls = 'lg';\n break;\n\n case 'small':\n sizeCls = 'sm';\n break;\n\n default:\n break;\n }\n\n var iconType = innerLoading ? 'loading' : icon;\n var classes = classNames(prefixCls, className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(type), type), _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(shape), shape), _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(sizeCls), sizeCls), _defineProperty(_classNames, \"\".concat(prefixCls, \"-icon-only\"), !children && children !== 0 && iconType), _defineProperty(_classNames, \"\".concat(prefixCls, \"-background-ghost\"), ghost && !isUnborderedButtonType(type)), _defineProperty(_classNames, \"\".concat(prefixCls, \"-loading\"), innerLoading), _defineProperty(_classNames, \"\".concat(prefixCls, \"-two-chinese-chars\"), hasTwoCNChar && autoInsertSpace), _defineProperty(_classNames, \"\".concat(prefixCls, \"-block\"), block), _defineProperty(_classNames, \"\".concat(prefixCls, \"-dangerous\"), !!danger), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _classNames));\n var iconNode = icon && !innerLoading ? icon : /*#__PURE__*/React.createElement(LoadingIcon, {\n existIcon: !!icon,\n prefixCls: prefixCls,\n loading: !!innerLoading\n });\n var kids = children || children === 0 ? spaceChildren(children, isNeedInserted() && autoInsertSpace) : null;\n var linkButtonRestProps = omit(rest, ['htmlType', 'loading']);\n\n if (linkButtonRestProps.href !== undefined) {\n return /*#__PURE__*/React.createElement(\"a\", _extends({}, linkButtonRestProps, {\n className: classes,\n onClick: handleClick,\n ref: buttonRef\n }), iconNode, kids);\n } // React does not recognize the `htmlType` prop on a DOM element. Here we pick it out of `rest`.\n\n\n var _a = rest,\n htmlType = _a.htmlType,\n otherProps = __rest(_a, [\"htmlType\"]);\n\n var buttonNode = /*#__PURE__*/React.createElement(\"button\", _extends({}, omit(otherProps, ['loading']), {\n type: htmlType,\n className: classes,\n onClick: handleClick,\n ref: buttonRef\n }), iconNode, kids);\n\n if (isUnborderedButtonType(type)) {\n return buttonNode;\n }\n\n return /*#__PURE__*/React.createElement(Wave, null, buttonNode);\n};\n\nvar Button = /*#__PURE__*/React.forwardRef(InternalButton);\nButton.displayName = 'Button';\nButton.defaultProps = {\n loading: false,\n ghost: false,\n block: false,\n htmlType: 'button'\n};\nButton.Group = Group;\nButton.__ANT_BUTTON = true;\nexport default Button;","var isNumeric = function isNumeric(value) {\n return !isNaN(parseFloat(value)) && isFinite(value);\n};\n\nexport default isNumeric;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport BarsOutlined from '@ant-design/icons/BarsOutlined';\nimport RightOutlined from '@ant-design/icons/RightOutlined';\nimport LeftOutlined from '@ant-design/icons/LeftOutlined';\nimport { LayoutContext } from './layout';\nimport { ConfigConsumer } from '../config-provider';\nimport isNumeric from '../_util/isNumeric';\nvar dimensionMaxMap = {\n xs: '479.98px',\n sm: '575.98px',\n md: '767.98px',\n lg: '991.98px',\n xl: '1199.98px',\n xxl: '1599.98px'\n};\nexport var SiderContext = /*#__PURE__*/React.createContext({});\n\nvar generateId = function () {\n var i = 0;\n return function () {\n var prefix = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';\n i += 1;\n return \"\".concat(prefix).concat(i);\n };\n}();\n\nvar InternalSider = /*#__PURE__*/function (_React$Component) {\n _inherits(InternalSider, _React$Component);\n\n var _super = _createSuper(InternalSider);\n\n function InternalSider(props) {\n var _this;\n\n _classCallCheck(this, InternalSider);\n\n _this = _super.call(this, props);\n\n _this.responsiveHandler = function (mql) {\n _this.setState({\n below: mql.matches\n });\n\n var onBreakpoint = _this.props.onBreakpoint;\n var collapsed = _this.state.collapsed;\n\n if (onBreakpoint) {\n onBreakpoint(mql.matches);\n }\n\n if (collapsed !== mql.matches) {\n _this.setCollapsed(mql.matches, 'responsive');\n }\n };\n\n _this.setCollapsed = function (collapsed, type) {\n if (!('collapsed' in _this.props)) {\n _this.setState({\n collapsed: collapsed\n });\n }\n\n var onCollapse = _this.props.onCollapse;\n\n if (onCollapse) {\n onCollapse(collapsed, type);\n }\n };\n\n _this.toggle = function () {\n var collapsed = !_this.state.collapsed;\n\n _this.setCollapsed(collapsed, 'clickTrigger');\n };\n\n _this.renderSider = function (_ref) {\n var _classNames;\n\n var getPrefixCls = _ref.getPrefixCls;\n\n var _a = _this.props,\n customizePrefixCls = _a.prefixCls,\n className = _a.className,\n theme = _a.theme,\n collapsible = _a.collapsible,\n reverseArrow = _a.reverseArrow,\n trigger = _a.trigger,\n style = _a.style,\n width = _a.width,\n collapsedWidth = _a.collapsedWidth,\n zeroWidthTriggerStyle = _a.zeroWidthTriggerStyle,\n children = _a.children,\n others = __rest(_a, [\"prefixCls\", \"className\", \"theme\", \"collapsible\", \"reverseArrow\", \"trigger\", \"style\", \"width\", \"collapsedWidth\", \"zeroWidthTriggerStyle\", \"children\"]);\n\n var _this$state = _this.state,\n collapsed = _this$state.collapsed,\n below = _this$state.below;\n var prefixCls = getPrefixCls('layout-sider', customizePrefixCls);\n var divProps = omit(others, ['collapsed', 'defaultCollapsed', 'onCollapse', 'breakpoint', 'onBreakpoint', 'siderHook', 'zeroWidthTriggerStyle']);\n var rawWidth = collapsed ? collapsedWidth : width; // use \"px\" as fallback unit for width\n\n var siderWidth = isNumeric(rawWidth) ? \"\".concat(rawWidth, \"px\") : String(rawWidth); // special trigger when collapsedWidth == 0\n\n var zeroWidthTrigger = parseFloat(String(collapsedWidth || 0)) === 0 ? /*#__PURE__*/React.createElement(\"span\", {\n onClick: _this.toggle,\n className: classNames(\"\".concat(prefixCls, \"-zero-width-trigger\"), \"\".concat(prefixCls, \"-zero-width-trigger-\").concat(reverseArrow ? 'right' : 'left')),\n style: zeroWidthTriggerStyle\n }, trigger || /*#__PURE__*/React.createElement(BarsOutlined, null)) : null;\n var iconObj = {\n expanded: reverseArrow ? /*#__PURE__*/React.createElement(RightOutlined, null) : /*#__PURE__*/React.createElement(LeftOutlined, null),\n collapsed: reverseArrow ? /*#__PURE__*/React.createElement(LeftOutlined, null) : /*#__PURE__*/React.createElement(RightOutlined, null)\n };\n var status = collapsed ? 'collapsed' : 'expanded';\n var defaultTrigger = iconObj[status];\n var triggerDom = trigger !== null ? zeroWidthTrigger || /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-trigger\"),\n onClick: _this.toggle,\n style: {\n width: siderWidth\n }\n }, trigger || defaultTrigger) : null;\n\n var divStyle = _extends(_extends({}, style), {\n flex: \"0 0 \".concat(siderWidth),\n maxWidth: siderWidth,\n minWidth: siderWidth,\n width: siderWidth\n });\n\n var siderCls = classNames(className, prefixCls, \"\".concat(prefixCls, \"-\").concat(theme), (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-collapsed\"), !!collapsed), _defineProperty(_classNames, \"\".concat(prefixCls, \"-has-trigger\"), collapsible && trigger !== null && !zeroWidthTrigger), _defineProperty(_classNames, \"\".concat(prefixCls, \"-below\"), !!below), _defineProperty(_classNames, \"\".concat(prefixCls, \"-zero-width\"), parseFloat(siderWidth) === 0), _classNames));\n return /*#__PURE__*/React.createElement(\"aside\", _extends({\n className: siderCls\n }, divProps, {\n style: divStyle\n }), /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-children\")\n }, children), collapsible || below && zeroWidthTrigger ? triggerDom : null);\n };\n\n _this.uniqueId = generateId('ant-sider-');\n var matchMedia;\n\n if (typeof window !== 'undefined') {\n matchMedia = window.matchMedia;\n }\n\n if (matchMedia && props.breakpoint && props.breakpoint in dimensionMaxMap) {\n _this.mql = matchMedia(\"(max-width: \".concat(dimensionMaxMap[props.breakpoint], \")\"));\n }\n\n var collapsed;\n\n if ('collapsed' in props) {\n collapsed = props.collapsed;\n } else {\n collapsed = props.defaultCollapsed;\n }\n\n _this.state = {\n collapsed: collapsed,\n below: false\n };\n return _this;\n }\n\n _createClass(InternalSider, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n var _a;\n\n if (this.mql) {\n this.mql.addListener(this.responsiveHandler);\n this.responsiveHandler(this.mql);\n }\n\n (_a = this.props) === null || _a === void 0 ? void 0 : _a.siderHook.addSider(this.uniqueId);\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n var _a, _b;\n\n (_a = this === null || this === void 0 ? void 0 : this.mql) === null || _a === void 0 ? void 0 : _a.removeListener(this.responsiveHandler);\n (_b = this.props) === null || _b === void 0 ? void 0 : _b.siderHook.removeSider(this.uniqueId);\n }\n }, {\n key: \"render\",\n value: function render() {\n var collapsed = this.state.collapsed;\n var collapsedWidth = this.props.collapsedWidth;\n return /*#__PURE__*/React.createElement(SiderContext.Provider, {\n value: {\n siderCollapsed: collapsed,\n collapsedWidth: collapsedWidth\n }\n }, /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderSider));\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(nextProps) {\n if ('collapsed' in nextProps) {\n return {\n collapsed: nextProps.collapsed\n };\n }\n\n return null;\n }\n }]);\n\n return InternalSider;\n}(React.Component);\n\nInternalSider.defaultProps = {\n collapsible: false,\n defaultCollapsed: false,\n reverseArrow: false,\n width: 200,\n collapsedWidth: 80,\n style: {},\n theme: 'dark'\n}; // eslint-disable-next-line react/prefer-stateless-function\n\nvar Sider = /*#__PURE__*/function (_React$Component2) {\n _inherits(Sider, _React$Component2);\n\n var _super2 = _createSuper(Sider);\n\n function Sider() {\n _classCallCheck(this, Sider);\n\n return _super2.apply(this, arguments);\n }\n\n _createClass(Sider, [{\n key: \"render\",\n value: function render() {\n var _this2 = this;\n\n return /*#__PURE__*/React.createElement(LayoutContext.Consumer, null, function (context) {\n return /*#__PURE__*/React.createElement(InternalSider, _extends({}, context, _this2.props));\n });\n }\n }]);\n\n return Sider;\n}(React.Component);\n\nexport { Sider as default };","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0) t[p[i]] = s[p[i]];\n }return t;\n};\nimport * as React from 'react';\n\nvar LazyRenderBox = function (_React$Component) {\n _inherits(LazyRenderBox, _React$Component);\n\n function LazyRenderBox() {\n _classCallCheck(this, LazyRenderBox);\n\n return _possibleConstructorReturn(this, _React$Component.apply(this, arguments));\n }\n\n LazyRenderBox.prototype.shouldComponentUpdate = function shouldComponentUpdate(nextProps) {\n if (nextProps.forceRender) {\n return true;\n }\n return !!nextProps.hiddenClassName || !!nextProps.visible;\n };\n\n LazyRenderBox.prototype.render = function render() {\n var _a = this.props,\n className = _a.className,\n hiddenClassName = _a.hiddenClassName,\n visible = _a.visible,\n forceRender = _a.forceRender,\n restProps = __rest(_a, [\"className\", \"hiddenClassName\", \"visible\", \"forceRender\"]);\n var useClassName = className;\n if (!!hiddenClassName && !visible) {\n useClassName += \" \" + hiddenClassName;\n }\n return React.createElement(\"div\", _extends({}, restProps, { className: useClassName }));\n };\n\n return LazyRenderBox;\n}(React.Component);\n\nexport default LazyRenderBox;","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport KeyCode from 'rc-util/es/KeyCode';\nimport contains from 'rc-util/es/Dom/contains';\nimport Animate from 'rc-animate';\nimport LazyRenderBox from './LazyRenderBox';\nvar uuid = 0;\n/* eslint react/no-is-mounted:0 */\nfunction getScroll(w, top) {\n var ret = w['page' + (top ? 'Y' : 'X') + 'Offset'];\n var method = 'scroll' + (top ? 'Top' : 'Left');\n if (typeof ret !== 'number') {\n var d = w.document;\n ret = d.documentElement[method];\n if (typeof ret !== 'number') {\n ret = d.body[method];\n }\n }\n return ret;\n}\nfunction setTransformOrigin(node, value) {\n var style = node.style;\n ['Webkit', 'Moz', 'Ms', 'ms'].forEach(function (prefix) {\n style[prefix + 'TransformOrigin'] = value;\n });\n style['transformOrigin'] = value;\n}\nfunction offset(el) {\n var rect = el.getBoundingClientRect();\n var pos = {\n left: rect.left,\n top: rect.top\n };\n var doc = el.ownerDocument;\n var w = doc.defaultView || doc.parentWindow;\n pos.left += getScroll(w);\n pos.top += getScroll(w, true);\n return pos;\n}\n\nvar Dialog = function (_React$Component) {\n _inherits(Dialog, _React$Component);\n\n function Dialog(props) {\n _classCallCheck(this, Dialog);\n\n var _this = _possibleConstructorReturn(this, _React$Component.call(this, props));\n\n _this.inTransition = false;\n _this.onAnimateLeave = function () {\n var _this$props = _this.props,\n afterClose = _this$props.afterClose,\n getOpenCount = _this$props.getOpenCount;\n // need demo?\n // https://github.com/react-component/dialog/pull/28\n\n if (_this.wrap) {\n _this.wrap.style.display = 'none';\n }\n _this.inTransition = false;\n // 如果没有打开的状态,则清除 effect 和 overflow: hidden;\n // https://github.com/ant-design/ant-design/issues/21539\n if (!getOpenCount()) {\n _this.switchScrollingEffect();\n }\n if (afterClose) {\n afterClose();\n }\n };\n _this.onDialogMouseDown = function () {\n _this.dialogMouseDown = true;\n };\n _this.onMaskMouseUp = function () {\n if (_this.dialogMouseDown) {\n _this.timeoutId = setTimeout(function () {\n _this.dialogMouseDown = false;\n }, 0);\n }\n };\n _this.onMaskClick = function (e) {\n // android trigger click on open (fastclick??)\n if (Date.now() - _this.openTime < 300) {\n return;\n }\n if (e.target === e.currentTarget && !_this.dialogMouseDown) {\n _this.close(e);\n }\n };\n _this.onKeyDown = function (e) {\n var props = _this.props;\n if (props.keyboard && e.keyCode === KeyCode.ESC) {\n e.stopPropagation();\n _this.close(e);\n return;\n }\n // keep focus inside dialog\n if (props.visible) {\n if (e.keyCode === KeyCode.TAB) {\n var activeElement = document.activeElement;\n var sentinelStart = _this.sentinelStart;\n if (e.shiftKey) {\n if (activeElement === sentinelStart) {\n _this.sentinelEnd.focus();\n }\n } else if (activeElement === _this.sentinelEnd) {\n sentinelStart.focus();\n }\n }\n }\n };\n _this.getDialogElement = function () {\n var props = _this.props;\n var closable = props.closable;\n var prefixCls = props.prefixCls;\n var dest = {};\n if (props.width !== undefined) {\n dest.width = props.width;\n }\n if (props.height !== undefined) {\n dest.height = props.height;\n }\n var footer = void 0;\n if (props.footer) {\n footer = React.createElement(\"div\", { className: prefixCls + '-footer', ref: _this.saveRef('footer') }, props.footer);\n }\n var header = void 0;\n if (props.title) {\n header = React.createElement(\"div\", { className: prefixCls + '-header', ref: _this.saveRef('header') }, React.createElement(\"div\", { className: prefixCls + '-title', id: _this.titleId }, props.title));\n }\n var closer = void 0;\n if (closable) {\n closer = React.createElement(\"button\", { type: \"button\", onClick: _this.close, \"aria-label\": \"Close\", className: prefixCls + '-close' }, props.closeIcon || React.createElement(\"span\", { className: prefixCls + '-close-x' }));\n }\n var style = _extends({}, props.style, dest);\n var sentinelStyle = { width: 0, height: 0, overflow: 'hidden', outline: 'none' };\n var transitionName = _this.getTransitionName();\n var dialogElement = React.createElement(LazyRenderBox, { key: \"dialog-element\", role: \"document\", ref: _this.saveRef('dialog'), style: style, className: prefixCls + ' ' + (props.className || ''), visible: props.visible, forceRender: props.forceRender, onMouseDown: _this.onDialogMouseDown }, React.createElement(\"div\", { tabIndex: 0, ref: _this.saveRef('sentinelStart'), style: sentinelStyle, \"aria-hidden\": \"true\" }), React.createElement(\"div\", { className: prefixCls + '-content' }, closer, header, React.createElement(\"div\", _extends({ className: prefixCls + '-body', style: props.bodyStyle, ref: _this.saveRef('body') }, props.bodyProps), props.children), footer), React.createElement(\"div\", { tabIndex: 0, ref: _this.saveRef('sentinelEnd'), style: sentinelStyle, \"aria-hidden\": \"true\" }));\n return React.createElement(Animate, { key: \"dialog\", showProp: \"visible\", onLeave: _this.onAnimateLeave, transitionName: transitionName, component: \"\", transitionAppear: true }, props.visible || !props.destroyOnClose ? dialogElement : null);\n };\n _this.getZIndexStyle = function () {\n var style = {};\n var props = _this.props;\n if (props.zIndex !== undefined) {\n style.zIndex = props.zIndex;\n }\n return style;\n };\n _this.getWrapStyle = function () {\n return _extends({}, _this.getZIndexStyle(), _this.props.wrapStyle);\n };\n _this.getMaskStyle = function () {\n return _extends({}, _this.getZIndexStyle(), _this.props.maskStyle);\n };\n _this.getMaskElement = function () {\n var props = _this.props;\n var maskElement = void 0;\n if (props.mask) {\n var maskTransition = _this.getMaskTransitionName();\n maskElement = React.createElement(LazyRenderBox, _extends({ style: _this.getMaskStyle(), key: \"mask\", className: props.prefixCls + '-mask', hiddenClassName: props.prefixCls + '-mask-hidden', visible: props.visible }, props.maskProps));\n if (maskTransition) {\n maskElement = React.createElement(Animate, { key: \"mask\", showProp: \"visible\", transitionAppear: true, component: \"\", transitionName: maskTransition }, maskElement);\n }\n }\n return maskElement;\n };\n _this.getMaskTransitionName = function () {\n var props = _this.props;\n var transitionName = props.maskTransitionName;\n var animation = props.maskAnimation;\n if (!transitionName && animation) {\n transitionName = props.prefixCls + '-' + animation;\n }\n return transitionName;\n };\n _this.getTransitionName = function () {\n var props = _this.props;\n var transitionName = props.transitionName;\n var animation = props.animation;\n if (!transitionName && animation) {\n transitionName = props.prefixCls + '-' + animation;\n }\n return transitionName;\n };\n _this.close = function (e) {\n var onClose = _this.props.onClose;\n\n if (onClose) {\n onClose(e);\n }\n };\n _this.saveRef = function (name) {\n return function (node) {\n _this[name] = node;\n };\n };\n _this.titleId = 'rcDialogTitle' + uuid++;\n _this.switchScrollingEffect = props.switchScrollingEffect || function () {};\n return _this;\n }\n\n Dialog.prototype.componentDidMount = function componentDidMount() {\n this.componentDidUpdate({});\n // if forceRender is true, set element style display to be none;\n if (this.props.forceRender && this.props.visible) {\n return;\n }\n if ((this.props.forceRender || this.props.getContainer === false && !this.props.visible) && this.wrap) {\n this.wrap.style.display = 'none';\n }\n };\n\n Dialog.prototype.componentDidUpdate = function componentDidUpdate(prevProps) {\n var _props = this.props,\n visible = _props.visible,\n mask = _props.mask,\n focusTriggerAfterClose = _props.focusTriggerAfterClose;\n\n var mousePosition = this.props.mousePosition;\n if (visible) {\n // first show\n if (!prevProps.visible) {\n this.openTime = Date.now();\n this.switchScrollingEffect();\n this.tryFocus();\n var dialogNode = ReactDOM.findDOMNode(this.dialog);\n if (mousePosition) {\n var elOffset = offset(dialogNode);\n setTransformOrigin(dialogNode, mousePosition.x - elOffset.left + 'px ' + (mousePosition.y - elOffset.top) + 'px');\n } else {\n setTransformOrigin(dialogNode, '');\n }\n }\n } else if (prevProps.visible) {\n this.inTransition = true;\n if (mask && this.lastOutSideFocusNode && focusTriggerAfterClose) {\n try {\n this.lastOutSideFocusNode.focus();\n } catch (e) {\n this.lastOutSideFocusNode = null;\n }\n this.lastOutSideFocusNode = null;\n }\n }\n };\n\n Dialog.prototype.componentWillUnmount = function componentWillUnmount() {\n var _props2 = this.props,\n visible = _props2.visible,\n getOpenCount = _props2.getOpenCount;\n\n if ((visible || this.inTransition) && !getOpenCount()) {\n this.switchScrollingEffect();\n }\n clearTimeout(this.timeoutId);\n };\n\n Dialog.prototype.tryFocus = function tryFocus() {\n if (!contains(this.wrap, document.activeElement)) {\n this.lastOutSideFocusNode = document.activeElement;\n this.sentinelStart.focus();\n }\n };\n\n Dialog.prototype.render = function render() {\n var props = this.props;\n var prefixCls = props.prefixCls,\n maskClosable = props.maskClosable;\n\n var style = this.getWrapStyle();\n // clear hide display\n // and only set display after async anim, not here for hide\n if (props.visible) {\n style.display = null;\n }\n return React.createElement(\"div\", { className: prefixCls + '-root' }, this.getMaskElement(), React.createElement(\"div\", _extends({ tabIndex: -1, onKeyDown: this.onKeyDown, className: prefixCls + '-wrap ' + (props.wrapClassName || ''), ref: this.saveRef('wrap'), onClick: maskClosable ? this.onMaskClick : null, onMouseUp: maskClosable ? this.onMaskMouseUp : null, role: \"dialog\", \"aria-labelledby\": props.title ? this.titleId : null, style: style }, props.wrapProps), this.getDialogElement()));\n };\n\n return Dialog;\n}(React.Component);\n\nexport default Dialog;\n\nDialog.defaultProps = {\n className: '',\n mask: true,\n visible: false,\n keyboard: true,\n closable: true,\n maskClosable: true,\n destroyOnClose: false,\n prefixCls: 'rc-dialog',\n focusTriggerAfterClose: true\n};","function _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function\"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }\n\nfunction _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) { return call; } return _assertThisInitialized(self); }\n\nfunction _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return self; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nfunction _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }\n\nimport React from 'react';\nimport ReactDOM from 'react-dom';\n\nvar ContainerRender = /*#__PURE__*/function (_React$Component) {\n _inherits(ContainerRender, _React$Component);\n\n var _super = _createSuper(ContainerRender);\n\n function ContainerRender() {\n var _this;\n\n _classCallCheck(this, ContainerRender);\n\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n _this = _super.call.apply(_super, [this].concat(args));\n\n _this.removeContainer = function () {\n if (_this.container) {\n ReactDOM.unmountComponentAtNode(_this.container);\n\n _this.container.parentNode.removeChild(_this.container);\n\n _this.container = null;\n }\n };\n\n _this.renderComponent = function (props, ready) {\n var _this$props = _this.props,\n visible = _this$props.visible,\n getComponent = _this$props.getComponent,\n forceRender = _this$props.forceRender,\n getContainer = _this$props.getContainer,\n parent = _this$props.parent;\n\n if (visible || parent._component || forceRender) {\n if (!_this.container) {\n _this.container = getContainer();\n }\n\n ReactDOM.unstable_renderSubtreeIntoContainer(parent, getComponent(props), _this.container, function callback() {\n if (ready) {\n ready.call(this);\n }\n });\n }\n };\n\n return _this;\n }\n\n _createClass(ContainerRender, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n if (this.props.autoMount) {\n this.renderComponent();\n }\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {\n if (this.props.autoMount) {\n this.renderComponent();\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n if (this.props.autoDestroy) {\n this.removeContainer();\n }\n }\n }, {\n key: \"render\",\n value: function render() {\n return this.props.children({\n renderComponent: this.renderComponent,\n removeContainer: this.removeContainer\n });\n }\n }]);\n\n return ContainerRender;\n}(React.Component);\n\nContainerRender.defaultProps = {\n autoMount: true,\n autoDestroy: true,\n forceRender: false\n};\nexport { ContainerRender as default };","/**\n * Easy to set element style, return previous style\n * IE browser compatible(IE browser doesn't merge overflow style, need to set it separately)\n * https://github.com/ant-design/ant-design/issues/19393\n *\n */\nfunction setStyle(style) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n var _options$element = options.element,\n element = _options$element === void 0 ? document.body : _options$element;\n var oldStyle = {};\n var styleKeys = Object.keys(style); // IE browser compatible\n\n styleKeys.forEach(function (key) {\n oldStyle[key] = element.style[key];\n });\n styleKeys.forEach(function (key) {\n element.style[key] = style[key];\n });\n return oldStyle;\n}\n\nexport default setStyle;","import getScrollBarSize from './getScrollBarSize';\nimport setStyle from './setStyle';\n\nfunction isBodyOverflowing() {\n return document.body.scrollHeight > (window.innerHeight || document.documentElement.clientHeight) && window.innerWidth > document.body.offsetWidth;\n}\n\nvar cacheStyle = {};\nexport default (function (close) {\n if (!isBodyOverflowing() && !close) {\n return;\n } // https://github.com/ant-design/ant-design/issues/19729\n\n\n var scrollingEffectClassName = 'ant-scrolling-effect';\n var scrollingEffectClassNameReg = new RegExp(\"\".concat(scrollingEffectClassName), 'g');\n var bodyClassName = document.body.className;\n\n if (close) {\n if (!scrollingEffectClassNameReg.test(bodyClassName)) return;\n setStyle(cacheStyle);\n cacheStyle = {};\n document.body.className = bodyClassName.replace(scrollingEffectClassNameReg, '').trim();\n return;\n }\n\n var scrollBarSize = getScrollBarSize();\n\n if (scrollBarSize) {\n cacheStyle = setStyle({\n position: 'relative',\n width: \"calc(100% - \".concat(scrollBarSize, \"px)\")\n });\n\n if (!scrollingEffectClassNameReg.test(bodyClassName)) {\n var addClassName = \"\".concat(bodyClassName, \" \").concat(scrollingEffectClassName);\n document.body.className = addClassName.trim();\n }\n }\n});","function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function\"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }\n\nfunction _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) { return call; } return _assertThisInitialized(self); }\n\nfunction _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return self; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nfunction _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }\n\nfunction _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\n/* eslint-disable no-underscore-dangle,react/require-default-props */\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport ContainerRender from './ContainerRender';\nimport Portal from './Portal';\nimport switchScrollingEffect from './switchScrollingEffect';\nimport setStyle from './setStyle';\nvar openCount = 0;\nvar windowIsUndefined = !(typeof window !== 'undefined' && window.document && window.document.createElement);\nvar IS_REACT_16 = ('createPortal' in ReactDOM); // https://github.com/ant-design/ant-design/issues/19340\n// https://github.com/ant-design/ant-design/issues/19332\n\nvar cacheOverflow = {};\n\nvar getParent = function getParent(getContainer) {\n if (windowIsUndefined) {\n return null;\n }\n\n if (getContainer) {\n if (typeof getContainer === 'string') {\n return document.querySelectorAll(getContainer)[0];\n }\n\n if (typeof getContainer === 'function') {\n return getContainer();\n }\n\n if (_typeof(getContainer) === 'object' && getContainer instanceof window.HTMLElement) {\n return getContainer;\n }\n }\n\n return document.body;\n};\n\nvar PortalWrapper = /*#__PURE__*/function (_React$Component) {\n _inherits(PortalWrapper, _React$Component);\n\n var _super = _createSuper(PortalWrapper);\n\n function PortalWrapper(props) {\n var _this;\n\n _classCallCheck(this, PortalWrapper);\n\n _this = _super.call(this, props);\n\n _this.getContainer = function () {\n if (windowIsUndefined) {\n return null;\n }\n\n if (!_this.container) {\n _this.container = document.createElement('div');\n var parent = getParent(_this.props.getContainer);\n\n if (parent) {\n parent.appendChild(_this.container);\n }\n }\n\n _this.setWrapperClassName();\n\n return _this.container;\n };\n\n _this.setWrapperClassName = function () {\n var wrapperClassName = _this.props.wrapperClassName;\n\n if (_this.container && wrapperClassName && wrapperClassName !== _this.container.className) {\n _this.container.className = wrapperClassName;\n }\n };\n\n _this.savePortal = function (c) {\n // Warning: don't rename _component\n // https://github.com/react-component/util/pull/65#discussion_r352407916\n _this._component = c;\n };\n\n _this.removeCurrentContainer = function (visible) {\n _this.container = null;\n _this._component = null;\n\n if (!IS_REACT_16) {\n if (visible) {\n _this.renderComponent({\n afterClose: _this.removeContainer,\n onClose: function onClose() {},\n visible: false\n });\n } else {\n _this.removeContainer();\n }\n }\n };\n\n _this.switchScrollingEffect = function () {\n if (openCount === 1 && !Object.keys(cacheOverflow).length) {\n switchScrollingEffect(); // Must be set after switchScrollingEffect\n\n cacheOverflow = setStyle({\n overflow: 'hidden',\n overflowX: 'hidden',\n overflowY: 'hidden'\n });\n } else if (!openCount) {\n setStyle(cacheOverflow);\n cacheOverflow = {};\n switchScrollingEffect(true);\n }\n };\n\n var _visible = props.visible,\n getContainer = props.getContainer;\n\n if (!windowIsUndefined && getParent(getContainer) === document.body) {\n openCount = _visible ? openCount + 1 : openCount;\n }\n\n _this.state = {\n _self: _assertThisInitialized(_this)\n };\n return _this;\n }\n\n _createClass(PortalWrapper, [{\n key: \"componentDidUpdate\",\n value: function componentDidUpdate() {\n this.setWrapperClassName();\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n var _this$props = this.props,\n visible = _this$props.visible,\n getContainer = _this$props.getContainer;\n\n if (!windowIsUndefined && getParent(getContainer) === document.body) {\n // 离开时不会 render, 导到离开时数值不变,改用 func 。。\n openCount = visible && openCount ? openCount - 1 : openCount;\n }\n\n this.removeCurrentContainer(visible);\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this2 = this;\n\n var _this$props2 = this.props,\n children = _this$props2.children,\n forceRender = _this$props2.forceRender,\n visible = _this$props2.visible;\n var portal = null;\n var childProps = {\n getOpenCount: function getOpenCount() {\n return openCount;\n },\n getContainer: this.getContainer,\n switchScrollingEffect: this.switchScrollingEffect\n }; // suppport react15\n\n if (!IS_REACT_16) {\n return /*#__PURE__*/React.createElement(ContainerRender, {\n parent: this,\n visible: visible,\n autoDestroy: false,\n getComponent: function getComponent() {\n var extra = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n return children(_objectSpread(_objectSpread(_objectSpread({}, extra), childProps), {}, {\n ref: _this2.savePortal\n }));\n },\n getContainer: this.getContainer,\n forceRender: forceRender\n }, function (_ref) {\n var renderComponent = _ref.renderComponent,\n removeContainer = _ref.removeContainer;\n _this2.renderComponent = renderComponent;\n _this2.removeContainer = removeContainer;\n return null;\n });\n }\n\n if (forceRender || visible || this._component) {\n portal = /*#__PURE__*/React.createElement(Portal, {\n getContainer: this.getContainer,\n ref: this.savePortal\n }, children(childProps));\n }\n\n return portal;\n }\n }], [{\n key: \"getDerivedStateFromProps\",\n value: function getDerivedStateFromProps(props, _ref2) {\n var prevProps = _ref2.prevProps,\n _self = _ref2._self;\n var visible = props.visible,\n getContainer = props.getContainer;\n\n if (prevProps) {\n var prevVisible = prevProps.visible,\n prevGetContainer = prevProps.getContainer;\n\n if (visible !== prevVisible && !windowIsUndefined && getParent(getContainer) === document.body) {\n openCount = visible && !prevVisible ? openCount + 1 : openCount - 1;\n }\n\n var getContainerIsFunc = typeof getContainer === 'function' && typeof prevGetContainer === 'function';\n\n if (getContainerIsFunc ? getContainer.toString() !== prevGetContainer.toString() : getContainer !== prevGetContainer) {\n _self.removeCurrentContainer(false);\n }\n }\n\n return {\n prevProps: props\n };\n }\n }]);\n\n return PortalWrapper;\n}(React.Component);\n\nexport default PortalWrapper;","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nimport * as React from 'react';\nimport Dialog from './Dialog';\nimport Portal from 'rc-util/es/PortalWrapper';\n// fix issue #10656\n/*\n* getContainer remarks\n* Custom container should not be return, because in the Portal component, it will remove the\n* return container element here, if the custom container is the only child of it's component,\n* like issue #10656, It will has a conflict with removeChild method in react-dom.\n* So here should add a child (div element) to custom container.\n* */\nexport default (function (props) {\n var visible = props.visible,\n getContainer = props.getContainer,\n forceRender = props.forceRender;\n // 渲染在当前 dom 里;\n\n if (getContainer === false) {\n return React.createElement(Dialog, _extends({}, props, { getOpenCount: function getOpenCount() {\n return 2;\n } }));\n }\n return React.createElement(Portal, { visible: visible, forceRender: forceRender, getContainer: getContainer }, function (childProps) {\n return React.createElement(Dialog, _extends({}, props, childProps));\n });\n});","import _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nimport Button from '../button';\nimport { convertLegacyProps } from '../button/button';\n\nvar ActionButton = function ActionButton(props) {\n var clickedRef = React.useRef(false);\n var ref = React.useRef();\n\n var _React$useState = React.useState(false),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n loading = _React$useState2[0],\n setLoading = _React$useState2[1];\n\n React.useEffect(function () {\n var timeoutId;\n\n if (props.autoFocus) {\n var $this = ref.current;\n timeoutId = setTimeout(function () {\n return $this.focus();\n });\n }\n\n return function () {\n if (timeoutId) {\n clearTimeout(timeoutId);\n }\n };\n }, []);\n\n var handlePromiseOnOk = function handlePromiseOnOk(returnValueOfOnOk) {\n var closeModal = props.closeModal;\n\n if (!returnValueOfOnOk || !returnValueOfOnOk.then) {\n return;\n }\n\n setLoading(true);\n returnValueOfOnOk.then(function () {\n // It's unnecessary to set loading=false, for the Modal will be unmounted after close.\n // setState({ loading: false });\n closeModal.apply(void 0, arguments);\n }, function (e) {\n // Emit error when catch promise reject\n // eslint-disable-next-line no-console\n console.error(e); // See: https://github.com/ant-design/ant-design/issues/6183\n\n setLoading(false);\n clickedRef.current = false;\n });\n };\n\n var onClick = function onClick() {\n var actionFn = props.actionFn,\n closeModal = props.closeModal;\n\n if (clickedRef.current) {\n return;\n }\n\n clickedRef.current = true;\n\n if (!actionFn) {\n closeModal();\n return;\n }\n\n var returnValueOfOnOk;\n\n if (actionFn.length) {\n returnValueOfOnOk = actionFn(closeModal); // https://github.com/ant-design/ant-design/issues/23358\n\n clickedRef.current = false;\n } else {\n returnValueOfOnOk = actionFn();\n\n if (!returnValueOfOnOk) {\n closeModal();\n return;\n }\n }\n\n handlePromiseOnOk(returnValueOfOnOk);\n };\n\n var type = props.type,\n children = props.children,\n prefixCls = props.prefixCls,\n buttonProps = props.buttonProps;\n return /*#__PURE__*/React.createElement(Button, _extends({}, convertLegacyProps(type), {\n onClick: onClick,\n loading: loading,\n prefixCls: prefixCls\n }, buttonProps, {\n ref: ref\n }), children);\n};\n\nexport default ActionButton;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport Dialog from './Modal';\nimport ActionButton from './ActionButton';\nimport devWarning from '../_util/devWarning';\n\nvar ConfirmDialog = function ConfirmDialog(props) {\n var icon = props.icon,\n onCancel = props.onCancel,\n onOk = props.onOk,\n close = props.close,\n zIndex = props.zIndex,\n afterClose = props.afterClose,\n visible = props.visible,\n keyboard = props.keyboard,\n centered = props.centered,\n getContainer = props.getContainer,\n maskStyle = props.maskStyle,\n okText = props.okText,\n okButtonProps = props.okButtonProps,\n cancelText = props.cancelText,\n cancelButtonProps = props.cancelButtonProps,\n direction = props.direction,\n prefixCls = props.prefixCls,\n rootPrefixCls = props.rootPrefixCls;\n devWarning(!(typeof icon === 'string' && icon.length > 2), 'Modal', \"`icon` is using ReactNode instead of string naming in v4. Please check `\".concat(icon, \"` at https://ant.design/components/icon\")); // 支持传入{ icon: null }来隐藏`Modal.confirm`默认的Icon\n\n var okType = props.okType || 'primary';\n var contentPrefixCls = \"\".concat(prefixCls, \"-confirm\"); // 默认为 true,保持向下兼容\n\n var okCancel = 'okCancel' in props ? props.okCancel : true;\n var width = props.width || 416;\n var style = props.style || {};\n var mask = props.mask === undefined ? true : props.mask; // 默认为 false,保持旧版默认行为\n\n var maskClosable = props.maskClosable === undefined ? false : props.maskClosable;\n var autoFocusButton = props.autoFocusButton === null ? false : props.autoFocusButton || 'ok';\n var transitionName = props.transitionName || 'zoom';\n var maskTransitionName = props.maskTransitionName || 'fade';\n var classString = classNames(contentPrefixCls, \"\".concat(contentPrefixCls, \"-\").concat(props.type), _defineProperty({}, \"\".concat(contentPrefixCls, \"-rtl\"), direction === 'rtl'), props.className);\n var cancelButton = okCancel && /*#__PURE__*/React.createElement(ActionButton, {\n actionFn: onCancel,\n closeModal: close,\n autoFocus: autoFocusButton === 'cancel',\n buttonProps: cancelButtonProps,\n prefixCls: \"\".concat(rootPrefixCls, \"-btn\")\n }, cancelText);\n return /*#__PURE__*/React.createElement(Dialog, {\n prefixCls: prefixCls,\n className: classString,\n wrapClassName: classNames(_defineProperty({}, \"\".concat(contentPrefixCls, \"-centered\"), !!props.centered)),\n onCancel: function onCancel() {\n return close({\n triggerCancel: true\n });\n },\n visible: visible,\n title: \"\",\n transitionName: transitionName,\n footer: \"\",\n maskTransitionName: maskTransitionName,\n mask: mask,\n maskClosable: maskClosable,\n maskStyle: maskStyle,\n style: style,\n width: width,\n zIndex: zIndex,\n afterClose: afterClose,\n keyboard: keyboard,\n centered: centered,\n getContainer: getContainer\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(contentPrefixCls, \"-body-wrapper\")\n }, /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(contentPrefixCls, \"-body\")\n }, icon, props.title === undefined ? null : /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(contentPrefixCls, \"-title\")\n }, props.title), /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(contentPrefixCls, \"-content\")\n }, props.content)), /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(contentPrefixCls, \"-btns\")\n }, cancelButton, /*#__PURE__*/React.createElement(ActionButton, {\n type: okType,\n actionFn: onOk,\n closeModal: close,\n autoFocus: autoFocusButton === 'ok',\n buttonProps: okButtonProps,\n prefixCls: \"\".concat(rootPrefixCls, \"-btn\")\n }, okText))));\n};\n\nexport default ConfirmDialog;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nimport ConfirmDialog from '../ConfirmDialog';\nimport defaultLocale from '../../locale/default';\nimport LocaleReceiver from '../../locale-provider/LocaleReceiver';\nimport { ConfigContext } from '../../config-provider';\n\nvar HookModal = function HookModal(_ref, ref) {\n var afterClose = _ref.afterClose,\n config = _ref.config;\n\n var _React$useState = React.useState(true),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n visible = _React$useState2[0],\n setVisible = _React$useState2[1];\n\n var _React$useState3 = React.useState(config),\n _React$useState4 = _slicedToArray(_React$useState3, 2),\n innerConfig = _React$useState4[0],\n setInnerConfig = _React$useState4[1];\n\n var _React$useContext = React.useContext(ConfigContext),\n direction = _React$useContext.direction,\n getPrefixCls = _React$useContext.getPrefixCls;\n\n var prefixCls = getPrefixCls('modal');\n var rootPrefixCls = getPrefixCls();\n\n function close() {\n setVisible(false);\n }\n\n React.useImperativeHandle(ref, function () {\n return {\n destroy: close,\n update: function update(newConfig) {\n setInnerConfig(function (originConfig) {\n return _extends(_extends({}, originConfig), newConfig);\n });\n }\n };\n });\n return /*#__PURE__*/React.createElement(LocaleReceiver, {\n componentName: \"Modal\",\n defaultLocale: defaultLocale.Modal\n }, function (modalLocale) {\n return /*#__PURE__*/React.createElement(ConfirmDialog, _extends({\n prefixCls: prefixCls,\n rootPrefixCls: rootPrefixCls\n }, innerConfig, {\n close: close,\n visible: visible,\n afterClose: afterClose,\n okText: innerConfig.okText || (innerConfig.okCancel ? modalLocale.okText : modalLocale.justOkText),\n direction: direction,\n cancelText: innerConfig.cancelText || modalLocale.cancelText\n }));\n });\n};\n\nexport default /*#__PURE__*/React.forwardRef(HookModal);","import _extends from \"@babel/runtime/helpers/extends\";\nimport defaultLocale from '../locale/default';\n\nvar runtimeLocale = _extends({}, defaultLocale.Modal);\n\nexport function changeConfirmLocale(newLocale) {\n if (newLocale) {\n runtimeLocale = _extends(_extends({}, runtimeLocale), newLocale);\n } else {\n runtimeLocale = _extends({}, defaultLocale.Modal);\n }\n}\nexport function getConfirmLocale() {\n return runtimeLocale;\n}","import _extends from \"@babel/runtime/helpers/extends\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport InfoCircleOutlined from '@ant-design/icons/InfoCircleOutlined';\nimport CheckCircleOutlined from '@ant-design/icons/CheckCircleOutlined';\nimport CloseCircleOutlined from '@ant-design/icons/CloseCircleOutlined';\nimport ExclamationCircleOutlined from '@ant-design/icons/ExclamationCircleOutlined';\nimport { getConfirmLocale } from './locale';\nimport { destroyFns } from './Modal';\nimport ConfirmDialog from './ConfirmDialog';\nvar defaultRootPrefixCls = 'ant';\n\nfunction getRootPrefixCls() {\n return defaultRootPrefixCls;\n}\n\nexport default function confirm(config) {\n var div = document.createElement('div');\n document.body.appendChild(div); // eslint-disable-next-line no-use-before-define\n\n var currentConfig = _extends(_extends({}, config), {\n close: close,\n visible: true\n });\n\n function destroy() {\n var unmountResult = ReactDOM.unmountComponentAtNode(div);\n\n if (unmountResult && div.parentNode) {\n div.parentNode.removeChild(div);\n }\n\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var triggerCancel = args.some(function (param) {\n return param && param.triggerCancel;\n });\n\n if (config.onCancel && triggerCancel) {\n config.onCancel.apply(config, args);\n }\n\n for (var i = 0; i < destroyFns.length; i++) {\n var fn = destroyFns[i]; // eslint-disable-next-line no-use-before-define\n\n if (fn === close) {\n destroyFns.splice(i, 1);\n break;\n }\n }\n }\n\n function render(_a) {\n var okText = _a.okText,\n cancelText = _a.cancelText,\n prefixCls = _a.prefixCls,\n props = __rest(_a, [\"okText\", \"cancelText\", \"prefixCls\"]);\n /**\n * https://github.com/ant-design/ant-design/issues/23623\n * Sync render blocks React event. Let's make this async.\n */\n\n\n setTimeout(function () {\n var runtimeLocale = getConfirmLocale();\n ReactDOM.render( /*#__PURE__*/React.createElement(ConfirmDialog, _extends({}, props, {\n prefixCls: prefixCls || \"\".concat(getRootPrefixCls(), \"-modal\"),\n rootPrefixCls: getRootPrefixCls(),\n okText: okText || (props.okCancel ? runtimeLocale.okText : runtimeLocale.justOkText),\n cancelText: cancelText || runtimeLocale.cancelText\n })), div);\n });\n }\n\n function close() {\n for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n args[_key2] = arguments[_key2];\n }\n\n currentConfig = _extends(_extends({}, currentConfig), {\n visible: false,\n afterClose: destroy.bind.apply(destroy, [this].concat(args))\n });\n render(currentConfig);\n }\n\n function update(newConfig) {\n currentConfig = _extends(_extends({}, currentConfig), newConfig);\n render(currentConfig);\n }\n\n render(currentConfig);\n destroyFns.push(close);\n return {\n destroy: close,\n update: update\n };\n}\nexport function withWarn(props) {\n return _extends({\n type: 'warning',\n icon: /*#__PURE__*/React.createElement(ExclamationCircleOutlined, null),\n okCancel: false\n }, props);\n}\nexport function withInfo(props) {\n return _extends({\n type: 'info',\n icon: /*#__PURE__*/React.createElement(InfoCircleOutlined, null),\n okCancel: false\n }, props);\n}\nexport function withSuccess(props) {\n return _extends({\n type: 'success',\n icon: /*#__PURE__*/React.createElement(CheckCircleOutlined, null),\n okCancel: false\n }, props);\n}\nexport function withError(props) {\n return _extends({\n type: 'error',\n icon: /*#__PURE__*/React.createElement(CloseCircleOutlined, null),\n okCancel: false\n }, props);\n}\nexport function withConfirm(props) {\n return _extends({\n type: 'confirm',\n icon: /*#__PURE__*/React.createElement(ExclamationCircleOutlined, null),\n okCancel: true\n }, props);\n}\nexport function globalConfig(_ref) {\n var rootPrefixCls = _ref.rootPrefixCls;\n\n if (rootPrefixCls) {\n defaultRootPrefixCls = rootPrefixCls;\n }\n}","import _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nimport usePatchElement from '../../_util/hooks/usePatchElement';\nimport HookModal from './HookModal';\nimport { withConfirm, withInfo, withSuccess, withError, withWarn } from '../confirm';\nvar uuid = 0;\nexport default function useModal() {\n var _usePatchElement = usePatchElement(),\n _usePatchElement2 = _slicedToArray(_usePatchElement, 2),\n elements = _usePatchElement2[0],\n patchElement = _usePatchElement2[1];\n\n function getConfirmFunc(withFunc) {\n return function hookConfirm(config) {\n uuid += 1;\n var modalRef = /*#__PURE__*/React.createRef();\n var closeFunc;\n var modal = /*#__PURE__*/React.createElement(HookModal, {\n key: \"modal-\".concat(uuid),\n config: withFunc(config),\n ref: modalRef,\n afterClose: function afterClose() {\n closeFunc();\n }\n });\n closeFunc = patchElement(modal);\n return {\n destroy: function destroy() {\n if (modalRef.current) {\n modalRef.current.destroy();\n }\n },\n update: function update(newConfig) {\n if (modalRef.current) {\n modalRef.current.update(newConfig);\n }\n }\n };\n };\n }\n\n return [{\n info: getConfirmFunc(withInfo),\n success: getConfirmFunc(withSuccess),\n error: getConfirmFunc(withError),\n warning: getConfirmFunc(withWarn),\n confirm: getConfirmFunc(withConfirm)\n }, /*#__PURE__*/React.createElement(React.Fragment, null, elements)];\n}","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport Dialog from 'rc-dialog';\nimport classNames from 'classnames';\nimport addEventListener from \"rc-util/es/Dom/addEventListener\";\nimport CloseOutlined from '@ant-design/icons/CloseOutlined';\nimport useModal from './useModal';\nimport { getConfirmLocale } from './locale';\nimport Button from '../button';\nimport { convertLegacyProps } from '../button/button';\nimport LocaleReceiver from '../locale-provider/LocaleReceiver';\nimport { ConfigContext } from '../config-provider';\nvar mousePosition;\nexport var destroyFns = []; // ref: https://github.com/ant-design/ant-design/issues/15795\n\nvar getClickPosition = function getClickPosition(e) {\n mousePosition = {\n x: e.pageX,\n y: e.pageY\n }; // 100ms 内发生过点击事件,则从点击位置动画展示\n // 否则直接 zoom 展示\n // 这样可以兼容非点击方式展开\n\n setTimeout(function () {\n mousePosition = null;\n }, 100);\n}; // 只有点击事件支持从鼠标位置动画展开\n\n\nif (typeof window !== 'undefined' && window.document && window.document.documentElement) {\n addEventListener(document.documentElement, 'click', getClickPosition);\n}\n\nvar Modal = function Modal(props) {\n var _classNames;\n\n var _React$useContext = React.useContext(ConfigContext),\n getContextPopupContainer = _React$useContext.getPopupContainer,\n getPrefixCls = _React$useContext.getPrefixCls,\n direction = _React$useContext.direction;\n\n var handleCancel = function handleCancel(e) {\n var onCancel = props.onCancel;\n\n if (onCancel) {\n onCancel(e);\n }\n };\n\n var handleOk = function handleOk(e) {\n var onOk = props.onOk;\n\n if (onOk) {\n onOk(e);\n }\n };\n\n var renderFooter = function renderFooter(locale) {\n var okText = props.okText,\n okType = props.okType,\n cancelText = props.cancelText,\n confirmLoading = props.confirmLoading;\n return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Button, _extends({\n onClick: handleCancel\n }, props.cancelButtonProps), cancelText || locale.cancelText), /*#__PURE__*/React.createElement(Button, _extends({}, convertLegacyProps(okType), {\n loading: confirmLoading,\n onClick: handleOk\n }, props.okButtonProps), okText || locale.okText));\n };\n\n var customizePrefixCls = props.prefixCls,\n footer = props.footer,\n visible = props.visible,\n wrapClassName = props.wrapClassName,\n centered = props.centered,\n getContainer = props.getContainer,\n closeIcon = props.closeIcon,\n restProps = __rest(props, [\"prefixCls\", \"footer\", \"visible\", \"wrapClassName\", \"centered\", \"getContainer\", \"closeIcon\"]);\n\n var prefixCls = getPrefixCls('modal', customizePrefixCls);\n var defaultFooter = /*#__PURE__*/React.createElement(LocaleReceiver, {\n componentName: \"Modal\",\n defaultLocale: getConfirmLocale()\n }, renderFooter);\n var closeIconToRender = /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-close-x\")\n }, closeIcon || /*#__PURE__*/React.createElement(CloseOutlined, {\n className: \"\".concat(prefixCls, \"-close-icon\")\n }));\n var wrapClassNameExtended = classNames(wrapClassName, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-centered\"), !!centered), _defineProperty(_classNames, \"\".concat(prefixCls, \"-wrap-rtl\"), direction === 'rtl'), _classNames));\n return /*#__PURE__*/React.createElement(Dialog, _extends({}, restProps, {\n getContainer: getContainer === undefined ? getContextPopupContainer : getContainer,\n prefixCls: prefixCls,\n wrapClassName: wrapClassNameExtended,\n footer: footer === undefined ? defaultFooter : footer,\n visible: visible,\n mousePosition: mousePosition,\n onClose: handleCancel,\n closeIcon: closeIconToRender\n }));\n};\n\nModal.useModal = useModal;\nModal.defaultProps = {\n width: 520,\n transitionName: 'zoom',\n maskTransitionName: 'fade',\n confirmLoading: false,\n visible: false,\n okType: 'primary'\n};\nexport default Modal;","import _toConsumableArray from \"@babel/runtime/helpers/toConsumableArray\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport * as React from 'react';\nexport default function usePatchElement() {\n var _React$useState = React.useState([]),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n elements = _React$useState2[0],\n setElements = _React$useState2[1];\n\n function patchElement(element) {\n // append a new element to elements (and create a new ref)\n setElements(function (originElements) {\n return [].concat(_toConsumableArray(originElements), [element]);\n }); // return a function that removes the new element out of elements (and create a new ref)\n // it works a little like useEffect\n\n return function () {\n setElements(function (originElements) {\n return originElements.filter(function (ele) {\n return ele !== element;\n });\n });\n };\n }\n\n return [elements, patchElement];\n}","import OriginModal, { destroyFns } from './Modal';\nimport confirm, { withWarn, withInfo, withSuccess, withError, withConfirm, globalConfig } from './confirm';\n\nfunction modalWarn(props) {\n return confirm(withWarn(props));\n}\n\nvar Modal = OriginModal;\n\nModal.info = function infoFn(props) {\n return confirm(withInfo(props));\n};\n\nModal.success = function successFn(props) {\n return confirm(withSuccess(props));\n};\n\nModal.error = function errorFn(props) {\n return confirm(withError(props));\n};\n\nModal.warning = modalWarn;\nModal.warn = modalWarn;\n\nModal.confirm = function confirmFn(props) {\n return confirm(withConfirm(props));\n};\n\nModal.destroyAll = function destroyAllFn() {\n while (destroyFns.length) {\n var close = destroyFns.pop();\n\n if (close) {\n close();\n }\n }\n};\n\nModal.config = globalConfig;\nexport default Modal;","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { ConfigContext } from '../config-provider';\n\nvar CheckableTag = function CheckableTag(props) {\n var _classNames;\n\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls;\n\n var handleClick = function handleClick(e) {\n var checked = props.checked,\n onChange = props.onChange,\n onClick = props.onClick;\n\n if (onChange) {\n onChange(!checked);\n }\n\n if (onClick) {\n onClick(e);\n }\n };\n\n var customizePrefixCls = props.prefixCls,\n className = props.className,\n checked = props.checked,\n restProps = __rest(props, [\"prefixCls\", \"className\", \"checked\"]);\n\n var prefixCls = getPrefixCls('tag', customizePrefixCls);\n var cls = classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-checkable\"), true), _defineProperty(_classNames, \"\".concat(prefixCls, \"-checkable-checked\"), checked), _classNames), className);\n delete restProps.onChange; // TypeScript cannot check delete now.\n\n return /*#__PURE__*/React.createElement(\"span\", _extends({}, restProps, {\n className: cls,\n onClick: handleClick\n }));\n};\n\nexport default CheckableTag;","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport CloseOutlined from '@ant-design/icons/CloseOutlined';\nimport CheckableTag from './CheckableTag';\nimport { ConfigContext } from '../config-provider';\nimport { PresetColorTypes, PresetStatusColorTypes } from '../_util/colors';\nimport Wave from '../_util/wave';\nvar PresetColorRegex = new RegExp(\"^(\".concat(PresetColorTypes.join('|'), \")(-inverse)?$\"));\nvar PresetStatusColorRegex = new RegExp(\"^(\".concat(PresetStatusColorTypes.join('|'), \")$\"));\n\nvar InternalTag = function InternalTag(_a, ref) {\n var _classNames;\n\n var customizePrefixCls = _a.prefixCls,\n className = _a.className,\n style = _a.style,\n children = _a.children,\n icon = _a.icon,\n color = _a.color,\n onClose = _a.onClose,\n closeIcon = _a.closeIcon,\n _a$closable = _a.closable,\n closable = _a$closable === void 0 ? false : _a$closable,\n props = __rest(_a, [\"prefixCls\", \"className\", \"style\", \"children\", \"icon\", \"color\", \"onClose\", \"closeIcon\", \"closable\"]);\n\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls,\n direction = _React$useContext.direction;\n\n var _React$useState = React.useState(true),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n visible = _React$useState2[0],\n setVisible = _React$useState2[1];\n\n React.useEffect(function () {\n if ('visible' in props) {\n setVisible(props.visible);\n }\n }, [props.visible]);\n\n var isPresetColor = function isPresetColor() {\n if (!color) {\n return false;\n }\n\n return PresetColorRegex.test(color) || PresetStatusColorRegex.test(color);\n };\n\n var tagStyle = _extends({\n backgroundColor: color && !isPresetColor() ? color : undefined\n }, style);\n\n var presetColor = isPresetColor();\n var prefixCls = getPrefixCls('tag', customizePrefixCls);\n var tagClassName = classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-\").concat(color), presetColor), _defineProperty(_classNames, \"\".concat(prefixCls, \"-has-color\"), color && !presetColor), _defineProperty(_classNames, \"\".concat(prefixCls, \"-hidden\"), !visible), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _classNames), className);\n\n var handleCloseClick = function handleCloseClick(e) {\n e.stopPropagation();\n\n if (onClose) {\n onClose(e);\n }\n\n if (e.defaultPrevented) {\n return;\n }\n\n if (!('visible' in props)) {\n setVisible(false);\n }\n };\n\n var renderCloseIcon = function renderCloseIcon() {\n if (closable) {\n return closeIcon ? /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-close-icon\"),\n onClick: handleCloseClick\n }, closeIcon) : /*#__PURE__*/React.createElement(CloseOutlined, {\n className: \"\".concat(prefixCls, \"-close-icon\"),\n onClick: handleCloseClick\n });\n }\n\n return null;\n };\n\n var isNeedWave = 'onClick' in props || children && children.type === 'a';\n var tagProps = omit(props, ['visible']);\n var iconNode = icon || null;\n var kids = iconNode ? /*#__PURE__*/React.createElement(React.Fragment, null, iconNode, /*#__PURE__*/React.createElement(\"span\", null, children)) : children;\n var tagNode = /*#__PURE__*/React.createElement(\"span\", _extends({}, tagProps, {\n ref: ref,\n className: tagClassName,\n style: tagStyle\n }), kids, renderCloseIcon());\n return isNeedWave ? /*#__PURE__*/React.createElement(Wave, null, tagNode) : tagNode;\n};\n\nvar Tag = /*#__PURE__*/React.forwardRef(InternalTag);\nTag.displayName = 'Tag';\nTag.CheckableTag = CheckableTag;\nexport default Tag;","import Layout from './layout';\nimport Sider from './Sider';\nLayout.Sider = Sider;\nexport default Layout;","var Symbol = require('./_Symbol'),\n getRawTag = require('./_getRawTag'),\n objectToString = require('./_objectToString');\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nmodule.exports = baseGetTag;\n","/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nmodule.exports = isObjectLike;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","export default function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}","'use strict';\n\nvar reactIs = require('react-is');\n\n/**\n * Copyright 2015, Yahoo! Inc.\n * Copyrights licensed under the New BSD License. See the accompanying LICENSE file for terms.\n */\nvar REACT_STATICS = {\n childContextTypes: true,\n contextType: true,\n contextTypes: true,\n defaultProps: true,\n displayName: true,\n getDefaultProps: true,\n getDerivedStateFromError: true,\n getDerivedStateFromProps: true,\n mixins: true,\n propTypes: true,\n type: true\n};\nvar KNOWN_STATICS = {\n name: true,\n length: true,\n prototype: true,\n caller: true,\n callee: true,\n arguments: true,\n arity: true\n};\nvar FORWARD_REF_STATICS = {\n '$$typeof': true,\n render: true,\n defaultProps: true,\n displayName: true,\n propTypes: true\n};\nvar MEMO_STATICS = {\n '$$typeof': true,\n compare: true,\n defaultProps: true,\n displayName: true,\n propTypes: true,\n type: true\n};\nvar TYPE_STATICS = {};\nTYPE_STATICS[reactIs.ForwardRef] = FORWARD_REF_STATICS;\nTYPE_STATICS[reactIs.Memo] = MEMO_STATICS;\n\nfunction getStatics(component) {\n // React v16.11 and below\n if (reactIs.isMemo(component)) {\n return MEMO_STATICS;\n } // React v16.12 and above\n\n\n return TYPE_STATICS[component['$$typeof']] || REACT_STATICS;\n}\n\nvar defineProperty = Object.defineProperty;\nvar getOwnPropertyNames = Object.getOwnPropertyNames;\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\nvar getPrototypeOf = Object.getPrototypeOf;\nvar objectPrototype = Object.prototype;\nfunction hoistNonReactStatics(targetComponent, sourceComponent, blacklist) {\n if (typeof sourceComponent !== 'string') {\n // don't hoist over string (html) components\n if (objectPrototype) {\n var inheritedComponent = getPrototypeOf(sourceComponent);\n\n if (inheritedComponent && inheritedComponent !== objectPrototype) {\n hoistNonReactStatics(targetComponent, inheritedComponent, blacklist);\n }\n }\n\n var keys = getOwnPropertyNames(sourceComponent);\n\n if (getOwnPropertySymbols) {\n keys = keys.concat(getOwnPropertySymbols(sourceComponent));\n }\n\n var targetStatics = getStatics(targetComponent);\n var sourceStatics = getStatics(sourceComponent);\n\n for (var i = 0; i < keys.length; ++i) {\n var key = keys[i];\n\n if (!KNOWN_STATICS[key] && !(blacklist && blacklist[key]) && !(sourceStatics && sourceStatics[key]) && !(targetStatics && targetStatics[key])) {\n var descriptor = getOwnPropertyDescriptor(sourceComponent, key);\n\n try {\n // Avoid failures from read-only properties\n defineProperty(targetComponent, key, descriptor);\n } catch (e) {}\n }\n }\n }\n\n return targetComponent;\n}\n\nmodule.exports = hoistNonReactStatics;\n","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _SearchOutlined = _interopRequireDefault(require('./lib/icons/SearchOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _SearchOutlined;\n exports.default = _default;\n module.exports = _default;","import { tuple } from './type';\nexport var PresetStatusColorTypes = tuple('success', 'processing', 'error', 'default', 'warning'); // eslint-disable-next-line import/prefer-default-export\n\nexport var PresetColorTypes = tuple('pink', 'red', 'yellow', 'orange', 'cyan', 'green', 'blue', 'purple', 'geekblue', 'magenta', 'volcano', 'gold', 'lime');","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _LeftOutlined = _interopRequireDefault(require('./lib/icons/LeftOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _LeftOutlined;\n exports.default = _default;\n module.exports = _default;","import _toConsumableArray from \"@babel/runtime/helpers/toConsumableArray\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { ConfigConsumer } from '../config-provider';\nexport var LayoutContext = /*#__PURE__*/React.createContext({\n siderHook: {\n addSider: function addSider() {\n return null;\n },\n removeSider: function removeSider() {\n return null;\n }\n }\n});\n\nfunction generator(_ref) {\n var suffixCls = _ref.suffixCls,\n tagName = _ref.tagName,\n displayName = _ref.displayName;\n return function (BasicComponent) {\n var _a;\n\n return _a = /*#__PURE__*/function (_React$Component) {\n _inherits(Adapter, _React$Component);\n\n var _super = _createSuper(Adapter);\n\n function Adapter() {\n var _this;\n\n _classCallCheck(this, Adapter);\n\n _this = _super.apply(this, arguments);\n\n _this.renderComponent = function (_ref2) {\n var getPrefixCls = _ref2.getPrefixCls;\n var customizePrefixCls = _this.props.prefixCls;\n var prefixCls = getPrefixCls(suffixCls, customizePrefixCls);\n return /*#__PURE__*/React.createElement(BasicComponent, _extends({\n prefixCls: prefixCls,\n tagName: tagName\n }, _this.props));\n };\n\n return _this;\n }\n\n _createClass(Adapter, [{\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderComponent);\n }\n }]);\n\n return Adapter;\n }(React.Component), _a.displayName = displayName, _a;\n };\n}\n\nvar Basic = function Basic(props) {\n var prefixCls = props.prefixCls,\n className = props.className,\n children = props.children,\n tagName = props.tagName,\n others = __rest(props, [\"prefixCls\", \"className\", \"children\", \"tagName\"]);\n\n var classString = classNames(prefixCls, className);\n return /*#__PURE__*/React.createElement(tagName, _extends({\n className: classString\n }, others), children);\n};\n\nvar BasicLayout = /*#__PURE__*/function (_React$Component2) {\n _inherits(BasicLayout, _React$Component2);\n\n var _super2 = _createSuper(BasicLayout);\n\n function BasicLayout() {\n var _this2;\n\n _classCallCheck(this, BasicLayout);\n\n _this2 = _super2.apply(this, arguments);\n _this2.state = {\n siders: []\n };\n\n _this2.renderComponent = function (_ref3) {\n var _classNames;\n\n var direction = _ref3.direction;\n\n var _a = _this2.props,\n prefixCls = _a.prefixCls,\n className = _a.className,\n children = _a.children,\n hasSider = _a.hasSider,\n Tag = _a.tagName,\n others = __rest(_a, [\"prefixCls\", \"className\", \"children\", \"hasSider\", \"tagName\"]);\n\n var classString = classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-has-sider\"), typeof hasSider === 'boolean' ? hasSider : _this2.state.siders.length > 0), _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _classNames), className);\n return /*#__PURE__*/React.createElement(LayoutContext.Provider, {\n value: {\n siderHook: _this2.getSiderHook()\n }\n }, /*#__PURE__*/React.createElement(Tag, _extends({\n className: classString\n }, others), children));\n };\n\n return _this2;\n }\n\n _createClass(BasicLayout, [{\n key: \"getSiderHook\",\n value: function getSiderHook() {\n var _this3 = this;\n\n return {\n addSider: function addSider(id) {\n _this3.setState(function (state) {\n return {\n siders: [].concat(_toConsumableArray(state.siders), [id])\n };\n });\n },\n removeSider: function removeSider(id) {\n _this3.setState(function (state) {\n return {\n siders: state.siders.filter(function (currentId) {\n return currentId !== id;\n })\n };\n });\n }\n };\n }\n }, {\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderComponent);\n }\n }]);\n\n return BasicLayout;\n}(React.Component);\n\nvar Layout = generator({\n suffixCls: 'layout',\n tagName: 'section',\n displayName: 'Layout'\n})(BasicLayout);\nvar Header = generator({\n suffixCls: 'layout-header',\n tagName: 'header',\n displayName: 'Header'\n})(Basic);\nvar Footer = generator({\n suffixCls: 'layout-footer',\n tagName: 'footer',\n displayName: 'Footer'\n})(Basic);\nvar Content = generator({\n suffixCls: 'layout-content',\n tagName: 'main',\n displayName: 'Content'\n})(Basic);\nLayout.Header = Header;\nLayout.Footer = Footer;\nLayout.Content = Content;\nexport default Layout;","import React from 'react';\n\nvar unsafeLifecyclesPolyfill = function unsafeLifecyclesPolyfill(Component) {\n var prototype = Component.prototype;\n\n if (!prototype || !prototype.isReactComponent) {\n throw new Error('Can only polyfill class components');\n } // only handle componentWillReceiveProps\n\n\n if (typeof prototype.componentWillReceiveProps !== 'function') {\n return Component;\n } // In React 16.9, React.Profiler was introduced together with UNSAFE_componentWillReceiveProps\n // https://reactjs.org/blog/2019/08/08/react-v16.9.0.html#performance-measurements-with-reactprofiler\n\n\n if (!React.Profiler) {\n return Component;\n } // Here polyfill get started\n\n\n prototype.UNSAFE_componentWillReceiveProps = prototype.componentWillReceiveProps;\n delete prototype.componentWillReceiveProps;\n return Component;\n};\n\nexport default unsafeLifecyclesPolyfill;","import React from 'react';\n\nexport function toArrayChildren(children) {\n var ret = [];\n React.Children.forEach(children, function (child) {\n ret.push(child);\n });\n return ret;\n}\n\nexport function findChildInChildrenByKey(children, key) {\n var ret = null;\n if (children) {\n children.forEach(function (child) {\n if (ret) {\n return;\n }\n if (child && child.key === key) {\n ret = child;\n }\n });\n }\n return ret;\n}\n\nexport function findShownChildInChildrenByKey(children, key, showProp) {\n var ret = null;\n if (children) {\n children.forEach(function (child) {\n if (child && child.key === key && child.props[showProp]) {\n if (ret) {\n throw new Error('two child with same key for children');\n }\n ret = child;\n }\n });\n }\n return ret;\n}\n\nexport function findHiddenChildInChildrenByKey(children, key, showProp) {\n var found = 0;\n if (children) {\n children.forEach(function (child) {\n if (found) {\n return;\n }\n found = child && child.key === key && !child.props[showProp];\n });\n }\n return found;\n}\n\nexport function isSameChildren(c1, c2, showProp) {\n var same = c1.length === c2.length;\n if (same) {\n c1.forEach(function (child, index) {\n var child2 = c2[index];\n if (child && child2) {\n if (child && !child2 || !child && child2) {\n same = false;\n } else if (child.key !== child2.key) {\n same = false;\n } else if (showProp && child.props[showProp] !== child2.props[showProp]) {\n same = false;\n }\n }\n });\n }\n return same;\n}\n\nexport function mergeChildren(prev, next) {\n var ret = [];\n\n // For each key of `next`, the list of keys to insert before that key in\n // the combined list\n var nextChildrenPending = {};\n var pendingChildren = [];\n prev.forEach(function (child) {\n if (child && findChildInChildrenByKey(next, child.key)) {\n if (pendingChildren.length) {\n nextChildrenPending[child.key] = pendingChildren;\n pendingChildren = [];\n }\n } else {\n pendingChildren.push(child);\n }\n });\n\n next.forEach(function (child) {\n if (child && Object.prototype.hasOwnProperty.call(nextChildrenPending, child.key)) {\n ret = ret.concat(nextChildrenPending[child.key]);\n }\n ret.push(child);\n });\n\n ret = ret.concat(pendingChildren);\n\n return ret;\n}","var _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; };\n\nimport Event from './Event';\n\nvar isCssAnimationSupported = Event.endEvents.length !== 0;\nvar capitalPrefixes = ['Webkit', 'Moz', 'O',\n// ms is special .... !\n'ms'];\nvar prefixes = ['-webkit-', '-moz-', '-o-', 'ms-', ''];\n\nfunction getStyleProperty(node, name) {\n // old ff need null, https://developer.mozilla.org/en-US/docs/Web/API/Window/getComputedStyle\n var style = window.getComputedStyle(node, null);\n var ret = '';\n for (var i = 0; i < prefixes.length; i++) {\n ret = style.getPropertyValue(prefixes[i] + name);\n if (ret) {\n break;\n }\n }\n return ret;\n}\n\nfunction fixBrowserByTimeout(node) {\n if (isCssAnimationSupported) {\n var transitionDelay = parseFloat(getStyleProperty(node, 'transition-delay')) || 0;\n var transitionDuration = parseFloat(getStyleProperty(node, 'transition-duration')) || 0;\n var animationDelay = parseFloat(getStyleProperty(node, 'animation-delay')) || 0;\n var animationDuration = parseFloat(getStyleProperty(node, 'animation-duration')) || 0;\n var time = Math.max(transitionDuration + transitionDelay, animationDuration + animationDelay);\n // sometimes, browser bug\n node.rcEndAnimTimeout = setTimeout(function () {\n node.rcEndAnimTimeout = null;\n if (node.rcEndListener) {\n node.rcEndListener();\n }\n }, time * 1000 + 200);\n }\n}\n\nfunction clearBrowserBugTimeout(node) {\n if (node.rcEndAnimTimeout) {\n clearTimeout(node.rcEndAnimTimeout);\n node.rcEndAnimTimeout = null;\n }\n}\n\nvar cssAnimation = function cssAnimation(node, transitionName, endCallback) {\n var nameIsObj = (typeof transitionName === 'undefined' ? 'undefined' : _typeof(transitionName)) === 'object';\n var className = nameIsObj ? transitionName.name : transitionName;\n var activeClassName = nameIsObj ? transitionName.active : transitionName + '-active';\n var end = endCallback;\n var start = void 0;\n var active = void 0;\n\n if (endCallback && Object.prototype.toString.call(endCallback) === '[object Object]') {\n end = endCallback.end;\n start = endCallback.start;\n active = endCallback.active;\n }\n\n if (node.rcEndListener) {\n node.rcEndListener();\n }\n\n node.rcEndListener = function (e) {\n if (e && e.target !== node) {\n return;\n }\n\n if (node.rcAnimTimeout) {\n clearTimeout(node.rcAnimTimeout);\n node.rcAnimTimeout = null;\n }\n\n clearBrowserBugTimeout(node);\n\n node.classList.remove(className);\n node.classList.remove(activeClassName);\n\n Event.removeEndEventListener(node, node.rcEndListener);\n node.rcEndListener = null;\n\n // Usually this optional end is used for informing an owner of\n // a leave animation and telling it to remove the child.\n if (end) {\n end();\n }\n };\n\n Event.addEndEventListener(node, node.rcEndListener);\n\n if (start) {\n start();\n }\n node.classList.add(className);\n\n node.rcAnimTimeout = setTimeout(function () {\n node.rcAnimTimeout = null;\n node.classList.add(activeClassName);\n if (active) {\n active();\n }\n fixBrowserByTimeout(node);\n }, 0);\n\n return {\n stop: function stop() {\n if (node.rcEndListener) {\n node.rcEndListener();\n }\n }\n };\n};\n\ncssAnimation.style = function (node, style, callback) {\n if (node.rcEndListener) {\n node.rcEndListener();\n }\n\n node.rcEndListener = function (e) {\n if (e && e.target !== node) {\n return;\n }\n\n if (node.rcAnimTimeout) {\n clearTimeout(node.rcAnimTimeout);\n node.rcAnimTimeout = null;\n }\n\n clearBrowserBugTimeout(node);\n\n Event.removeEndEventListener(node, node.rcEndListener);\n node.rcEndListener = null;\n\n // Usually this optional callback is used for informing an owner of\n // a leave animation and telling it to remove the child.\n if (callback) {\n callback();\n }\n };\n\n Event.addEndEventListener(node, node.rcEndListener);\n\n node.rcAnimTimeout = setTimeout(function () {\n for (var s in style) {\n if (style.hasOwnProperty(s)) {\n node.style[s] = style[s];\n }\n }\n node.rcAnimTimeout = null;\n fixBrowserByTimeout(node);\n }, 0);\n};\n\ncssAnimation.setTransition = function (node, p, value) {\n var property = p;\n var v = value;\n if (value === undefined) {\n v = property;\n property = '';\n }\n property = property || '';\n capitalPrefixes.forEach(function (prefix) {\n node.style[prefix + 'Transition' + property] = v;\n });\n};\n\ncssAnimation.isCssAnimationSupported = isCssAnimationSupported;\n\nexport { isCssAnimationSupported };\n\nexport default cssAnimation;","var util = {\n isAppearSupported: function isAppearSupported(props) {\n return props.transitionName && props.transitionAppear || props.animation.appear;\n },\n isEnterSupported: function isEnterSupported(props) {\n return props.transitionName && props.transitionEnter || props.animation.enter;\n },\n isLeaveSupported: function isLeaveSupported(props) {\n return props.transitionName && props.transitionLeave || props.animation.leave;\n },\n allowAppearCallback: function allowAppearCallback(props) {\n return props.transitionAppear || props.animation.appear;\n },\n allowEnterCallback: function allowEnterCallback(props) {\n return props.transitionEnter || props.animation.enter;\n },\n allowLeaveCallback: function allowLeaveCallback(props) {\n return props.transitionLeave || props.animation.leave;\n }\n};\nexport default util;","var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\n/* eslint react/prop-types: 0 */\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport cssAnimate, { isCssAnimationSupported } from '@ant-design/css-animation';\nimport animUtil from './util/animate';\n\nvar transitionMap = {\n enter: 'transitionEnter',\n appear: 'transitionAppear',\n leave: 'transitionLeave'\n};\n\nvar AnimateChild = function (_React$Component) {\n _inherits(AnimateChild, _React$Component);\n\n function AnimateChild() {\n _classCallCheck(this, AnimateChild);\n\n return _possibleConstructorReturn(this, (AnimateChild.__proto__ || Object.getPrototypeOf(AnimateChild)).apply(this, arguments));\n }\n\n _createClass(AnimateChild, [{\n key: 'componentWillUnmount',\n value: function componentWillUnmount() {\n this.stop();\n }\n }, {\n key: 'componentWillEnter',\n value: function componentWillEnter(done) {\n if (animUtil.isEnterSupported(this.props)) {\n this.transition('enter', done);\n } else {\n done();\n }\n }\n }, {\n key: 'componentWillAppear',\n value: function componentWillAppear(done) {\n if (animUtil.isAppearSupported(this.props)) {\n this.transition('appear', done);\n } else {\n done();\n }\n }\n }, {\n key: 'componentWillLeave',\n value: function componentWillLeave(done) {\n if (animUtil.isLeaveSupported(this.props)) {\n this.transition('leave', done);\n } else {\n // always sync, do not interupt with react component life cycle\n // update hidden -> animate hidden ->\n // didUpdate -> animate leave -> unmount (if animate is none)\n done();\n }\n }\n }, {\n key: 'transition',\n value: function transition(animationType, finishCallback) {\n var _this2 = this;\n\n var node = ReactDOM.findDOMNode(this);\n var props = this.props;\n var transitionName = props.transitionName;\n var nameIsObj = typeof transitionName === 'object';\n this.stop();\n var end = function end() {\n _this2.stopper = null;\n finishCallback();\n };\n if ((isCssAnimationSupported || !props.animation[animationType]) && transitionName && props[transitionMap[animationType]]) {\n var name = nameIsObj ? transitionName[animationType] : transitionName + '-' + animationType;\n var activeName = name + '-active';\n if (nameIsObj && transitionName[animationType + 'Active']) {\n activeName = transitionName[animationType + 'Active'];\n }\n this.stopper = cssAnimate(node, {\n name: name,\n active: activeName\n }, end);\n } else {\n this.stopper = props.animation[animationType](node, end);\n }\n }\n }, {\n key: 'stop',\n value: function stop() {\n var stopper = this.stopper;\n if (stopper) {\n this.stopper = null;\n stopper.stop();\n }\n }\n }, {\n key: 'render',\n value: function render() {\n return this.props.children;\n }\n }]);\n\n return AnimateChild;\n}(React.Component);\n\nexport default AnimateChild;","var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };\n\nvar _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return call && (typeof call === \"object\" || typeof call === \"function\") ? call : self; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function, not \" + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }\n\n/* eslint react/prop-types: 0 */\nimport React from 'react';\nimport unsafeLifecyclesPolyfill from 'rc-util/es/unsafeLifecyclesPolyfill';\nimport { toArrayChildren, mergeChildren, findShownChildInChildrenByKey, findChildInChildrenByKey, isSameChildren } from './ChildrenUtils';\nimport AnimateChild from './AnimateChild';\nimport animUtil from './util/animate';\n\nvar defaultKey = 'rc_animate_' + Date.now();\n\nfunction getChildrenFromProps(props) {\n var children = props.children;\n if (React.isValidElement(children)) {\n if (!children.key) {\n return React.cloneElement(children, {\n key: defaultKey\n });\n }\n }\n return children;\n}\n\nfunction noop() {}\n\nvar Animate = function (_React$Component) {\n _inherits(Animate, _React$Component);\n\n function Animate(props) {\n _classCallCheck(this, Animate);\n\n var _this = _possibleConstructorReturn(this, (Animate.__proto__ || Object.getPrototypeOf(Animate)).call(this, props));\n\n _initialiseProps.call(_this);\n\n _this.currentlyAnimatingKeys = {};\n _this.keysToEnter = [];\n _this.keysToLeave = [];\n\n _this.state = {\n children: toArrayChildren(getChildrenFromProps(props))\n };\n\n _this.childrenRefs = {};\n return _this;\n } // eslint-disable-line\n\n _createClass(Animate, [{\n key: 'componentDidMount',\n value: function componentDidMount() {\n var _this2 = this;\n\n var showProp = this.props.showProp;\n var children = this.state.children;\n if (showProp) {\n children = children.filter(function (child) {\n return !!child.props[showProp];\n });\n }\n children.forEach(function (child) {\n if (child) {\n _this2.performAppear(child.key);\n }\n });\n }\n }, {\n key: 'componentWillReceiveProps',\n value: function componentWillReceiveProps(nextProps) {\n var _this3 = this;\n\n this.nextProps = nextProps;\n var nextChildren = toArrayChildren(getChildrenFromProps(nextProps));\n var props = this.props;\n // exclusive needs immediate response\n if (props.exclusive) {\n Object.keys(this.currentlyAnimatingKeys).forEach(function (key) {\n _this3.stop(key);\n });\n }\n var showProp = props.showProp;\n var currentlyAnimatingKeys = this.currentlyAnimatingKeys;\n // last props children if exclusive\n var currentChildren = props.exclusive ? toArrayChildren(getChildrenFromProps(props)) : this.state.children;\n // in case destroy in showProp mode\n var newChildren = [];\n if (showProp) {\n currentChildren.forEach(function (currentChild) {\n var nextChild = currentChild && findChildInChildrenByKey(nextChildren, currentChild.key);\n var newChild = void 0;\n if ((!nextChild || !nextChild.props[showProp]) && currentChild.props[showProp]) {\n newChild = React.cloneElement(nextChild || currentChild, _defineProperty({}, showProp, true));\n } else {\n newChild = nextChild;\n }\n if (newChild) {\n newChildren.push(newChild);\n }\n });\n nextChildren.forEach(function (nextChild) {\n if (!nextChild || !findChildInChildrenByKey(currentChildren, nextChild.key)) {\n newChildren.push(nextChild);\n }\n });\n } else {\n newChildren = mergeChildren(currentChildren, nextChildren);\n }\n\n // need render to avoid update\n this.setState({\n children: newChildren\n });\n\n nextChildren.forEach(function (child) {\n var key = child && child.key;\n if (child && currentlyAnimatingKeys[key]) {\n return;\n }\n var hasPrev = child && findChildInChildrenByKey(currentChildren, key);\n if (showProp) {\n var showInNext = child.props[showProp];\n if (hasPrev) {\n var showInNow = findShownChildInChildrenByKey(currentChildren, key, showProp);\n if (!showInNow && showInNext) {\n _this3.keysToEnter.push(key);\n }\n } else if (showInNext) {\n _this3.keysToEnter.push(key);\n }\n } else if (!hasPrev) {\n _this3.keysToEnter.push(key);\n }\n });\n\n currentChildren.forEach(function (child) {\n var key = child && child.key;\n if (child && currentlyAnimatingKeys[key]) {\n return;\n }\n var hasNext = child && findChildInChildrenByKey(nextChildren, key);\n if (showProp) {\n var showInNow = child.props[showProp];\n if (hasNext) {\n var showInNext = findShownChildInChildrenByKey(nextChildren, key, showProp);\n if (!showInNext && showInNow) {\n _this3.keysToLeave.push(key);\n }\n } else if (showInNow) {\n _this3.keysToLeave.push(key);\n }\n } else if (!hasNext) {\n _this3.keysToLeave.push(key);\n }\n });\n }\n }, {\n key: 'componentDidUpdate',\n value: function componentDidUpdate() {\n var keysToEnter = this.keysToEnter;\n this.keysToEnter = [];\n keysToEnter.forEach(this.performEnter);\n var keysToLeave = this.keysToLeave;\n this.keysToLeave = [];\n keysToLeave.forEach(this.performLeave);\n }\n }, {\n key: 'isValidChildByKey',\n value: function isValidChildByKey(currentChildren, key) {\n var showProp = this.props.showProp;\n if (showProp) {\n return findShownChildInChildrenByKey(currentChildren, key, showProp);\n }\n return findChildInChildrenByKey(currentChildren, key);\n }\n }, {\n key: 'stop',\n value: function stop(key) {\n delete this.currentlyAnimatingKeys[key];\n var component = this.childrenRefs[key];\n if (component) {\n component.stop();\n }\n }\n }, {\n key: 'render',\n value: function render() {\n var _this4 = this;\n\n var props = this.props;\n this.nextProps = props;\n var stateChildren = this.state.children;\n var children = null;\n if (stateChildren) {\n children = stateChildren.map(function (child) {\n if (child === null || child === undefined) {\n return child;\n }\n if (!child.key) {\n throw new Error('must set key for children');\n }\n return React.createElement(\n AnimateChild,\n {\n key: child.key,\n ref: function ref(node) {\n _this4.childrenRefs[child.key] = node;\n },\n animation: props.animation,\n transitionName: props.transitionName,\n transitionEnter: props.transitionEnter,\n transitionAppear: props.transitionAppear,\n transitionLeave: props.transitionLeave\n },\n child\n );\n });\n }\n var Component = props.component;\n if (Component) {\n var passedProps = props;\n if (typeof Component === 'string') {\n passedProps = _extends({\n className: props.className,\n style: props.style\n }, props.componentProps);\n }\n return React.createElement(\n Component,\n passedProps,\n children\n );\n }\n return children[0] || null;\n }\n }]);\n\n return Animate;\n}(React.Component);\n\nAnimate.isAnimate = true;\nAnimate.defaultProps = {\n animation: {},\n component: 'span',\n componentProps: {},\n transitionEnter: true,\n transitionLeave: true,\n transitionAppear: false,\n onEnd: noop,\n onEnter: noop,\n onLeave: noop,\n onAppear: noop\n};\n\nvar _initialiseProps = function _initialiseProps() {\n var _this5 = this;\n\n this.performEnter = function (key) {\n // may already remove by exclusive\n if (_this5.childrenRefs[key]) {\n _this5.currentlyAnimatingKeys[key] = true;\n _this5.childrenRefs[key].componentWillEnter(_this5.handleDoneAdding.bind(_this5, key, 'enter'));\n }\n };\n\n this.performAppear = function (key) {\n if (_this5.childrenRefs[key]) {\n _this5.currentlyAnimatingKeys[key] = true;\n _this5.childrenRefs[key].componentWillAppear(_this5.handleDoneAdding.bind(_this5, key, 'appear'));\n }\n };\n\n this.handleDoneAdding = function (key, type) {\n var props = _this5.props;\n delete _this5.currentlyAnimatingKeys[key];\n // if update on exclusive mode, skip check\n if (props.exclusive && props !== _this5.nextProps) {\n return;\n }\n var currentChildren = toArrayChildren(getChildrenFromProps(props));\n if (!_this5.isValidChildByKey(currentChildren, key)) {\n // exclusive will not need this\n _this5.performLeave(key);\n } else if (type === 'appear') {\n if (animUtil.allowAppearCallback(props)) {\n props.onAppear(key);\n props.onEnd(key, true);\n }\n } else if (animUtil.allowEnterCallback(props)) {\n props.onEnter(key);\n props.onEnd(key, true);\n }\n };\n\n this.performLeave = function (key) {\n // may already remove by exclusive\n if (_this5.childrenRefs[key]) {\n _this5.currentlyAnimatingKeys[key] = true;\n _this5.childrenRefs[key].componentWillLeave(_this5.handleDoneLeaving.bind(_this5, key));\n }\n };\n\n this.handleDoneLeaving = function (key) {\n var props = _this5.props;\n delete _this5.currentlyAnimatingKeys[key];\n // if update on exclusive mode, skip check\n if (props.exclusive && props !== _this5.nextProps) {\n return;\n }\n var currentChildren = toArrayChildren(getChildrenFromProps(props));\n // in case state change is too fast\n if (_this5.isValidChildByKey(currentChildren, key)) {\n _this5.performEnter(key);\n } else {\n var end = function end() {\n if (animUtil.allowLeaveCallback(props)) {\n props.onLeave(key);\n props.onEnd(key, false);\n }\n };\n if (!isSameChildren(_this5.state.children, currentChildren, props.showProp)) {\n _this5.setState({\n children: currentChildren\n }, end);\n } else {\n end();\n }\n }\n };\n};\n\nexport default unsafeLifecyclesPolyfill(Animate);","var g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n","var listCacheClear = require('./_listCacheClear'),\n listCacheDelete = require('./_listCacheDelete'),\n listCacheGet = require('./_listCacheGet'),\n listCacheHas = require('./_listCacheHas'),\n listCacheSet = require('./_listCacheSet');\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nmodule.exports = ListCache;\n","var eq = require('./eq');\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nmodule.exports = assocIndexOf;\n","/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nmodule.exports = isObject;\n","var getNative = require('./_getNative');\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nmodule.exports = nativeCreate;\n","var isKeyable = require('./_isKeyable');\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nmodule.exports = getMapData;\n","import '../../style/index.less';\nimport './index.less'; // style dependencies\n// deps-lint-skip: tree\n\nimport '../../select/style';\nimport '../../empty/style';","/**\n * Safe chained function\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n *\n * @returns {function|null}\n */\nexport default function createChainedFunction() {\n var args = [].slice.call(arguments, 0);\n\n if (args.length === 1) {\n return args[0];\n }\n\n return function chainedFunction() {\n for (var i = 0; i < args.length; i++) {\n if (args[i] && args[i].apply) {\n args[i].apply(this, arguments);\n }\n }\n };\n}","export default function _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter);\n}","export default function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}","export default function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _CheckCircleFilled = _interopRequireDefault(require('./lib/icons/CheckCircleFilled'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _CheckCircleFilled;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _ExclamationCircleFilled = _interopRequireDefault(require('./lib/icons/ExclamationCircleFilled'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _ExclamationCircleFilled;\n exports.default = _default;\n module.exports = _default;","export default {\n // Options.jsx\n items_per_page: '/ page',\n jump_to: 'Go to',\n jump_to_confirm: 'confirm',\n page: '',\n // Pagination.jsx\n prev_page: 'Previous Page',\n next_page: 'Next Page',\n prev_5: 'Previous 5 Pages',\n next_5: 'Next 5 Pages',\n prev_3: 'Previous 3 Pages',\n next_3: 'Next 3 Pages'\n};","var baseIsEqual = require('./_baseIsEqual');\n\n/**\n * Performs a deep comparison between two values to determine if they are\n * equivalent.\n *\n * **Note:** This method supports comparing arrays, array buffers, booleans,\n * date objects, error objects, maps, numbers, `Object` objects, regexes,\n * sets, strings, symbols, and typed arrays. `Object` objects are compared\n * by their own, not inherited, enumerable properties. Functions and DOM\n * nodes are compared by strict equality, i.e. `===`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.isEqual(object, other);\n * // => true\n *\n * object === other;\n * // => false\n */\nfunction isEqual(value, other) {\n return baseIsEqual(value, other);\n}\n\nmodule.exports = isEqual;\n","import _extends from \"@babel/runtime/helpers/extends\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n\n for (var p in s) {\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n }\n\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { ConfigContext } from '../config-provider';\nvar spaceSize = {\n small: 8,\n middle: 16,\n large: 24\n};\n\nvar Space = function Space(props) {\n var _classNames;\n\n var _React$useContext = React.useContext(ConfigContext),\n getPrefixCls = _React$useContext.getPrefixCls,\n space = _React$useContext.space,\n directionConfig = _React$useContext.direction;\n\n var _props$size = props.size,\n size = _props$size === void 0 ? (space === null || space === void 0 ? void 0 : space.size) || 'small' : _props$size,\n align = props.align,\n className = props.className,\n children = props.children,\n _props$direction = props.direction,\n direction = _props$direction === void 0 ? 'horizontal' : _props$direction,\n customizePrefixCls = props.prefixCls,\n otherProps = __rest(props, [\"size\", \"align\", \"className\", \"children\", \"direction\", \"prefixCls\"]);\n\n var len = React.Children.count(children);\n\n if (len === 0) {\n return null;\n }\n\n var mergedAlign = align === undefined && direction === 'horizontal' ? 'center' : align;\n var prefixCls = getPrefixCls('space', customizePrefixCls);\n var cn = classNames(prefixCls, \"\".concat(prefixCls, \"-\").concat(direction), (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-rtl\"), directionConfig === 'rtl'), _defineProperty(_classNames, \"\".concat(prefixCls, \"-align-\").concat(mergedAlign), mergedAlign), _classNames), className);\n var itemClassName = \"\".concat(prefixCls, \"-item\");\n var marginDirection = directionConfig === 'rtl' ? 'marginLeft' : 'marginRight';\n return /*#__PURE__*/React.createElement(\"div\", _extends({\n className: cn\n }, otherProps), React.Children.map(children, function (child, i) {\n return /*#__PURE__*/React.createElement(\"div\", {\n className: itemClassName // eslint-disable-next-line react/no-array-index-key\n ,\n key: \"\".concat(itemClassName, \"-\").concat(i),\n style: i === len - 1 || child === null || child === undefined ? {} : _defineProperty({}, direction === 'vertical' ? 'marginBottom' : marginDirection, typeof size === 'string' ? spaceSize[size] : size)\n }, child);\n }));\n};\n\nexport default Space;","function _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function\"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }\n\nfunction _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) { return call; } return _assertThisInitialized(self); }\n\nfunction _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return self; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nfunction _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }\n\nimport React from 'react';\nimport ReactDOM from 'react-dom';\n\nvar Portal = /*#__PURE__*/function (_React$Component) {\n _inherits(Portal, _React$Component);\n\n var _super = _createSuper(Portal);\n\n function Portal() {\n _classCallCheck(this, Portal);\n\n return _super.apply(this, arguments);\n }\n\n _createClass(Portal, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.createContainer();\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate(prevProps) {\n var didUpdate = this.props.didUpdate;\n\n if (didUpdate) {\n didUpdate(prevProps);\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n this.removeContainer();\n }\n }, {\n key: \"createContainer\",\n value: function createContainer() {\n this._container = this.props.getContainer();\n this.forceUpdate();\n }\n }, {\n key: \"removeContainer\",\n value: function removeContainer() {\n if (this._container) {\n this._container.parentNode.removeChild(this._container);\n }\n }\n }, {\n key: \"render\",\n value: function render() {\n if (this._container) {\n return ReactDOM.createPortal(this.props.children, this._container);\n }\n\n return null;\n }\n }]);\n\n return Portal;\n}(React.Component);\n\nexport { Portal as default };","import _extends from \"@babel/runtime/helpers/extends\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\nimport * as React from 'react';\nimport { SubMenu as RcSubMenu } from 'rc-menu';\nimport classNames from 'classnames';\nimport omit from 'omit.js';\nimport MenuContext from './MenuContext';\nimport { isValidElement } from '../_util/reactNode';\n\nvar SubMenu = /*#__PURE__*/function (_React$Component) {\n _inherits(SubMenu, _React$Component);\n\n var _super = _createSuper(SubMenu);\n\n function SubMenu() {\n _classCallCheck(this, SubMenu);\n\n return _super.apply(this, arguments);\n }\n\n _createClass(SubMenu, [{\n key: \"renderTitle\",\n value: function renderTitle(inlineCollapsed) {\n var _this$props = this.props,\n icon = _this$props.icon,\n title = _this$props.title,\n level = _this$props.level,\n rootPrefixCls = _this$props.rootPrefixCls;\n\n if (!icon) {\n return inlineCollapsed && level === 1 && title && typeof title === 'string' ? /*#__PURE__*/React.createElement(\"div\", {\n className: \"\".concat(rootPrefixCls, \"-inline-collapsed-noicon\")\n }, title.charAt(0)) : title;\n } // inline-collapsed.md demo 依赖 span 来隐藏文字,有 icon 属性,则内部包裹一个 span\n // ref: https://github.com/ant-design/ant-design/pull/23456\n\n\n var titleIsSpan = isValidElement(title) && title.type === 'span';\n return /*#__PURE__*/React.createElement(React.Fragment, null, icon, titleIsSpan ? title : /*#__PURE__*/React.createElement(\"span\", null, title));\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this = this;\n\n var _this$props2 = this.props,\n rootPrefixCls = _this$props2.rootPrefixCls,\n popupClassName = _this$props2.popupClassName;\n return /*#__PURE__*/React.createElement(MenuContext.Consumer, null, function (_ref) {\n var inlineCollapsed = _ref.inlineCollapsed,\n antdMenuTheme = _ref.antdMenuTheme;\n return /*#__PURE__*/React.createElement(RcSubMenu, _extends({}, omit(_this.props, ['icon']), {\n title: _this.renderTitle(inlineCollapsed),\n popupClassName: classNames(rootPrefixCls, \"\".concat(rootPrefixCls, \"-\").concat(antdMenuTheme), popupClassName)\n }));\n });\n }\n }]);\n\n return SubMenu;\n}(React.Component);\n\nSubMenu.contextType = MenuContext; // fix issue:https://github.com/ant-design/ant-design/issues/8666\n\nSubMenu.isSubMenu = 1;\nexport default SubMenu;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _DownOutlined = _interopRequireDefault(require('./lib/icons/DownOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _DownOutlined;\n exports.default = _default;\n module.exports = _default;","export var INTERNAL_PROPS_MARK = 'RC_SELECT_INTERNAL_PROPS_MARK';","import * as React from 'react';\nimport DownOutlined from '@ant-design/icons/DownOutlined';\nimport LoadingOutlined from '@ant-design/icons/LoadingOutlined';\nimport CheckOutlined from '@ant-design/icons/CheckOutlined';\nimport CloseOutlined from '@ant-design/icons/CloseOutlined';\nimport CloseCircleFilled from '@ant-design/icons/CloseCircleFilled';\nimport SearchOutlined from '@ant-design/icons/SearchOutlined';\nexport default function getIcons(_ref) {\n var suffixIcon = _ref.suffixIcon,\n clearIcon = _ref.clearIcon,\n menuItemSelectedIcon = _ref.menuItemSelectedIcon,\n removeIcon = _ref.removeIcon,\n loading = _ref.loading,\n multiple = _ref.multiple,\n prefixCls = _ref.prefixCls;\n // Clear Icon\n var mergedClearIcon = clearIcon;\n\n if (!clearIcon) {\n mergedClearIcon = /*#__PURE__*/React.createElement(CloseCircleFilled, null);\n } // Arrow item icon\n\n\n var mergedSuffixIcon = null;\n\n if (suffixIcon !== undefined) {\n mergedSuffixIcon = suffixIcon;\n } else if (loading) {\n mergedSuffixIcon = /*#__PURE__*/React.createElement(LoadingOutlined, {\n spin: true\n });\n } else {\n var iconCls = \"\".concat(prefixCls, \"-suffix\");\n\n mergedSuffixIcon = function mergedSuffixIcon(_ref2) {\n var open = _ref2.open,\n showSearch = _ref2.showSearch;\n\n if (open && showSearch) {\n return /*#__PURE__*/React.createElement(SearchOutlined, {\n className: iconCls\n });\n }\n\n return /*#__PURE__*/React.createElement(DownOutlined, {\n className: iconCls\n });\n };\n } // Checked item icon\n\n\n var mergedItemIcon = null;\n\n if (menuItemSelectedIcon !== undefined) {\n mergedItemIcon = menuItemSelectedIcon;\n } else if (multiple) {\n mergedItemIcon = /*#__PURE__*/React.createElement(CheckOutlined, null);\n } else {\n mergedItemIcon = null;\n }\n\n var mergedRemoveIcon = null;\n\n if (removeIcon !== undefined) {\n mergedRemoveIcon = removeIcon;\n } else {\n mergedRemoveIcon = /*#__PURE__*/React.createElement(CloseOutlined, null);\n }\n\n return {\n clearIcon: mergedClearIcon,\n suffixIcon: mergedSuffixIcon,\n itemIcon: mergedItemIcon,\n removeIcon: mergedRemoveIcon\n };\n}","function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\nimport * as React from 'react';\nimport ResizeObserver from 'rc-resize-observer';\nimport classNames from 'classnames';\n/**\n * Fill component to provided the scroll content real height.\n */\n\nvar Filler = function Filler(_ref) {\n var height = _ref.height,\n offset = _ref.offset,\n children = _ref.children,\n prefixCls = _ref.prefixCls,\n onInnerResize = _ref.onInnerResize;\n var outerStyle = {};\n var innerStyle = {\n display: 'flex',\n flexDirection: 'column'\n };\n\n if (offset !== undefined) {\n outerStyle = {\n height: height,\n position: 'relative',\n overflow: 'hidden'\n };\n innerStyle = _objectSpread(_objectSpread({}, innerStyle), {}, {\n transform: \"translateY(\".concat(offset, \"px)\"),\n position: 'absolute',\n left: 0,\n right: 0,\n top: 0\n });\n }\n\n return React.createElement(\"div\", {\n style: outerStyle\n }, React.createElement(ResizeObserver, {\n onResize: function onResize(_ref2) {\n var offsetHeight = _ref2.offsetHeight;\n\n if (offsetHeight) {\n onInnerResize();\n }\n }\n }, React.createElement(\"div\", {\n style: innerStyle,\n className: classNames(_defineProperty({}, \"\".concat(prefixCls, \"-holder-inner\"), prefixCls))\n }, children)));\n};\n\nexport default Filler;","var raf = function raf(callback) {\n return +setTimeout(callback, 16);\n};\n\nvar caf = function caf(num) {\n return clearTimeout(num);\n};\n\nif (typeof window !== 'undefined' && 'requestAnimationFrame' in window) {\n raf = function raf(callback) {\n return window.requestAnimationFrame(callback);\n };\n\n caf = function caf(handle) {\n return window.cancelAnimationFrame(handle);\n };\n}\n\nexport default function wrapperRaf(callback) {\n return raf(callback);\n}\nwrapperRaf.cancel = caf;","function _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function\"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }\n\nfunction _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) { return call; } return _assertThisInitialized(self); }\n\nfunction _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return self; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nfunction _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport raf from \"rc-util/es/raf\";\nvar MIN_SIZE = 20;\n\nfunction getPageY(e) {\n return 'touches' in e ? e.touches[0].pageY : e.pageY;\n}\n\nvar ScrollBar = /*#__PURE__*/function (_React$Component) {\n _inherits(ScrollBar, _React$Component);\n\n var _super = _createSuper(ScrollBar);\n\n function ScrollBar() {\n var _this;\n\n _classCallCheck(this, ScrollBar);\n\n _this = _super.apply(this, arguments);\n _this.moveRaf = null;\n _this.scrollbarRef = React.createRef();\n _this.thumbRef = React.createRef();\n _this.visibleTimeout = null;\n _this.state = {\n dragging: false,\n pageY: null,\n startTop: null,\n visible: false\n };\n\n _this.delayHidden = function () {\n clearTimeout(_this.visibleTimeout);\n\n _this.setState({\n visible: true\n });\n\n _this.visibleTimeout = setTimeout(function () {\n _this.setState({\n visible: false\n });\n }, 2000);\n };\n\n _this.onScrollbarTouchStart = function (e) {\n e.preventDefault();\n };\n\n _this.onContainerMouseDown = function (e) {\n e.stopPropagation();\n e.preventDefault();\n }; // ======================= Clean =======================\n\n\n _this.patchEvents = function () {\n window.addEventListener('mousemove', _this.onMouseMove);\n window.addEventListener('mouseup', _this.onMouseUp);\n\n _this.thumbRef.current.addEventListener('touchmove', _this.onMouseMove);\n\n _this.thumbRef.current.addEventListener('touchend', _this.onMouseUp);\n };\n\n _this.removeEvents = function () {\n window.removeEventListener('mousemove', _this.onMouseMove);\n window.removeEventListener('mouseup', _this.onMouseUp);\n\n _this.scrollbarRef.current.removeEventListener('touchstart', _this.onScrollbarTouchStart);\n\n _this.thumbRef.current.removeEventListener('touchstart', _this.onMouseDown);\n\n _this.thumbRef.current.removeEventListener('touchmove', _this.onMouseMove);\n\n _this.thumbRef.current.removeEventListener('touchend', _this.onMouseUp);\n\n raf.cancel(_this.moveRaf);\n }; // ======================= Thumb =======================\n\n\n _this.onMouseDown = function (e) {\n var onStartMove = _this.props.onStartMove;\n\n _this.setState({\n dragging: true,\n pageY: getPageY(e),\n startTop: _this.getTop()\n });\n\n onStartMove();\n\n _this.patchEvents();\n\n e.stopPropagation();\n e.preventDefault();\n };\n\n _this.onMouseMove = function (e) {\n var _this$state = _this.state,\n dragging = _this$state.dragging,\n pageY = _this$state.pageY,\n startTop = _this$state.startTop;\n var onScroll = _this.props.onScroll;\n raf.cancel(_this.moveRaf);\n\n if (dragging) {\n var offsetY = getPageY(e) - pageY;\n var newTop = startTop + offsetY;\n\n var enableScrollRange = _this.getEnableScrollRange();\n\n var enableHeightRange = _this.getEnableHeightRange();\n\n var ptg = newTop / enableHeightRange;\n var newScrollTop = Math.ceil(ptg * enableScrollRange);\n _this.moveRaf = raf(function () {\n onScroll(newScrollTop);\n });\n }\n };\n\n _this.onMouseUp = function () {\n var onStopMove = _this.props.onStopMove;\n\n _this.setState({\n dragging: false\n });\n\n onStopMove();\n\n _this.removeEvents();\n }; // ===================== Calculate =====================\n\n\n _this.getSpinHeight = function () {\n var _this$props = _this.props,\n height = _this$props.height,\n count = _this$props.count;\n var baseHeight = height / count * 10;\n baseHeight = Math.max(baseHeight, MIN_SIZE);\n baseHeight = Math.min(baseHeight, height / 2);\n return Math.floor(baseHeight);\n };\n\n _this.getEnableScrollRange = function () {\n var _this$props2 = _this.props,\n scrollHeight = _this$props2.scrollHeight,\n height = _this$props2.height;\n return scrollHeight - height;\n };\n\n _this.getEnableHeightRange = function () {\n var height = _this.props.height;\n\n var spinHeight = _this.getSpinHeight();\n\n return height - spinHeight;\n };\n\n _this.getTop = function () {\n var scrollTop = _this.props.scrollTop;\n\n var enableScrollRange = _this.getEnableScrollRange();\n\n var enableHeightRange = _this.getEnableHeightRange();\n\n var ptg = scrollTop / enableScrollRange;\n return ptg * enableHeightRange;\n };\n\n return _this;\n }\n\n _createClass(ScrollBar, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n this.scrollbarRef.current.addEventListener('touchstart', this.onScrollbarTouchStart);\n this.thumbRef.current.addEventListener('touchstart', this.onMouseDown);\n }\n }, {\n key: \"componentDidUpdate\",\n value: function componentDidUpdate(prevProps) {\n if (prevProps.scrollTop !== this.props.scrollTop) {\n this.delayHidden();\n }\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n this.removeEvents();\n clearTimeout(this.visibleTimeout);\n }\n }, {\n key: \"render\",\n value: function render() {\n var _this$state2 = this.state,\n visible = _this$state2.visible,\n dragging = _this$state2.dragging;\n var prefixCls = this.props.prefixCls;\n var spinHeight = this.getSpinHeight();\n var top = this.getTop();\n return React.createElement(\"div\", {\n ref: this.scrollbarRef,\n className: \"\".concat(prefixCls, \"-scrollbar\"),\n style: {\n width: 8,\n top: 0,\n bottom: 0,\n right: 0,\n position: 'absolute',\n display: visible ? null : 'none'\n },\n onMouseDown: this.onContainerMouseDown,\n onMouseMove: this.delayHidden\n }, React.createElement(\"div\", {\n ref: this.thumbRef,\n className: classNames(\"\".concat(prefixCls, \"-scrollbar-thumb\"), _defineProperty({}, \"\".concat(prefixCls, \"-scrollbar-thumb-moving\"), dragging)),\n style: {\n width: '100%',\n height: spinHeight,\n top: top,\n left: 0,\n position: 'absolute',\n background: 'rgba(0, 0, 0, 0.5)',\n borderRadius: 99,\n cursor: 'pointer',\n userSelect: 'none'\n },\n onMouseDown: this.onMouseDown\n }));\n }\n }]);\n\n return ScrollBar;\n}(React.Component);\n\nexport { ScrollBar as default };","import * as React from 'react';\nexport function Item(_ref) {\n var children = _ref.children,\n setRef = _ref.setRef;\n var refFunc = React.useCallback(function (node) {\n setRef(node);\n }, []);\n return React.cloneElement(children, {\n ref: refFunc\n });\n}","function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n// Firefox has low performance of map.\nvar CacheMap = /*#__PURE__*/function () {\n function CacheMap() {\n _classCallCheck(this, CacheMap);\n\n this.maps = {};\n this.maps.prototype = null;\n }\n\n _createClass(CacheMap, [{\n key: \"set\",\n value: function set(key, value) {\n this.maps[key] = value;\n }\n }, {\n key: \"get\",\n value: function get(key) {\n return this.maps[key];\n }\n }]);\n\n return CacheMap;\n}();\n\nexport default CacheMap;","function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }\n\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\n\nfunction _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === \"string\") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === \"Object\" && o.constructor) n = o.constructor.name; if (n === \"Map\" || n === \"Set\") return Array.from(o); if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }\n\nfunction _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }\n\nfunction _iterableToArrayLimit(arr, i) { if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i[\"return\"] != null) _i[\"return\"](); } finally { if (_d) throw _e; } } return _arr; }\n\nfunction _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }\n\nimport * as React from 'react';\nimport { useRef } from 'react';\nimport findDOMNode from \"rc-util/es/Dom/findDOMNode\";\nimport CacheMap from '../utils/CacheMap';\nexport default function useHeights(getKey, onItemAdd, onItemRemove) {\n var _React$useState = React.useState(0),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n updatedMark = _React$useState2[0],\n setUpdatedMark = _React$useState2[1];\n\n var instanceRef = useRef(new Map());\n var heightsRef = useRef(new CacheMap());\n\n function setInstanceRef(item, instance) {\n var key = getKey(item);\n var origin = instanceRef.current.get(key);\n\n if (instance) {\n instanceRef.current.set(key, instance);\n } else {\n instanceRef.current.delete(key);\n } // Instance changed\n\n\n if (!origin !== !instance) {\n if (instance) {\n onItemAdd === null || onItemAdd === void 0 ? void 0 : onItemAdd(item);\n } else {\n onItemRemove === null || onItemRemove === void 0 ? void 0 : onItemRemove(item);\n }\n }\n }\n\n function collectHeight() {\n var changed = false;\n instanceRef.current.forEach(function (element, key) {\n if (element && element.offsetParent) {\n var htmlElement = findDOMNode(element);\n var offsetHeight = htmlElement.offsetHeight;\n\n if (heightsRef.current.get(key) !== offsetHeight) {\n changed = true;\n heightsRef.current.set(key, htmlElement.offsetHeight);\n }\n }\n });\n\n if (changed) {\n setUpdatedMark(function (c) {\n return c + 1;\n });\n }\n }\n\n return [setInstanceRef, collectHeight, heightsRef.current, updatedMark];\n}","function _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\n/* eslint-disable no-param-reassign */\nimport * as React from 'react';\nimport raf from \"rc-util/es/raf\";\nexport default function useScrollTo(containerRef, data, heights, itemHeight, getKey, collectHeight, syncScrollTop) {\n var scrollRef = React.useRef();\n return function (arg) {\n raf.cancel(scrollRef.current);\n\n if (typeof arg === 'number') {\n syncScrollTop(arg);\n } else if (arg && _typeof(arg) === 'object') {\n var index;\n var align = arg.align;\n\n if ('index' in arg) {\n index = arg.index;\n } else {\n index = data.findIndex(function (item) {\n return getKey(item) === arg.key;\n });\n } // We will retry 3 times in case dynamic height shaking\n\n\n var syncScroll = function syncScroll(times, targetAlign) {\n if (times < 0 || !containerRef.current) return;\n var height = containerRef.current.clientHeight;\n var needCollectHeight = false;\n var newTargetAlign = targetAlign; // Go to next frame if height not exist\n\n if (height) {\n var mergedAlign = targetAlign || align; // Get top & bottom\n\n var stackTop = 0;\n var itemTop = 0;\n var itemBottom = 0;\n\n for (var i = 0; i <= index; i += 1) {\n var key = getKey(data[i]);\n itemTop = stackTop;\n var cacheHeight = heights.get(key);\n itemBottom = itemTop + (cacheHeight === undefined ? itemHeight : cacheHeight);\n stackTop = itemBottom;\n\n if (i === index && cacheHeight === undefined) {\n needCollectHeight = true;\n }\n } // Scroll to\n\n\n var targetTop = null;\n\n switch (mergedAlign) {\n case 'top':\n targetTop = itemTop;\n break;\n\n case 'bottom':\n targetTop = itemBottom - height;\n break;\n\n default:\n {\n var scrollTop = containerRef.current.scrollTop;\n var scrollBottom = scrollTop + height;\n\n if (itemTop < scrollTop) {\n newTargetAlign = 'top';\n } else if (itemBottom > scrollBottom) {\n newTargetAlign = 'bottom';\n }\n }\n }\n\n if (targetTop !== null && targetTop !== containerRef.current.scrollTop) {\n syncScrollTop(targetTop);\n }\n } // We will retry since element may not sync height as it described\n\n\n scrollRef.current = raf(function () {\n if (needCollectHeight) {\n collectHeight();\n }\n\n syncScroll(times - 1, newTargetAlign);\n });\n };\n\n syncScroll(3);\n }\n };\n}","function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }\n\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\n\nfunction _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === \"string\") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === \"Object\" && o.constructor) n = o.constructor.name; if (n === \"Map\" || n === \"Set\") return Array.from(o); if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }\n\nfunction _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }\n\nfunction _iterableToArrayLimit(arr, i) { if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i[\"return\"] != null) _i[\"return\"](); } finally { if (_d) throw _e; } } return _arr; }\n\nfunction _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }\n\nimport * as React from 'react';\nimport { findListDiffIndex } from '../utils/algorithmUtil';\nexport default function useDiffItem(data, getKey, onDiff) {\n var _React$useState = React.useState(data),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n prevData = _React$useState2[0],\n setPrevData = _React$useState2[1];\n\n var _React$useState3 = React.useState(null),\n _React$useState4 = _slicedToArray(_React$useState3, 2),\n diffItem = _React$useState4[0],\n setDiffItem = _React$useState4[1];\n\n React.useEffect(function () {\n var diff = findListDiffIndex(prevData || [], data || [], getKey);\n\n if ((diff === null || diff === void 0 ? void 0 : diff.index) !== undefined) {\n onDiff === null || onDiff === void 0 ? void 0 : onDiff(diff.index);\n setDiffItem(data[diff.index]);\n }\n\n setPrevData(data);\n }, [data]);\n return [diffItem];\n}","/**\n * Get index with specific start index one by one. e.g.\n * min: 3, max: 9, start: 6\n *\n * Return index is:\n * [0]: 6\n * [1]: 7\n * [2]: 5\n * [3]: 8\n * [4]: 4\n * [5]: 9\n * [6]: 3\n */\nexport function getIndexByStartLoc(min, max, start, index) {\n var beforeCount = start - min;\n var afterCount = max - start;\n var balanceCount = Math.min(beforeCount, afterCount) * 2; // Balance\n\n if (index <= balanceCount) {\n var stepIndex = Math.floor(index / 2);\n\n if (index % 2) {\n return start + stepIndex + 1;\n }\n\n return start - stepIndex;\n } // One is out of range\n\n\n if (beforeCount > afterCount) {\n return start - (index - afterCount);\n }\n\n return start + (index - beforeCount);\n}\n/**\n * We assume that 2 list has only 1 item diff and others keeping the order.\n * So we can use dichotomy algorithm to find changed one.\n */\n\nexport function findListDiffIndex(originList, targetList, getKey) {\n var originLen = originList.length;\n var targetLen = targetList.length;\n var shortList;\n var longList;\n\n if (originLen === 0 && targetLen === 0) {\n return null;\n }\n\n if (originLen < targetLen) {\n shortList = originList;\n longList = targetList;\n } else {\n shortList = targetList;\n longList = originList;\n }\n\n var notExistKey = {\n __EMPTY_ITEM__: true\n };\n\n function getItemKey(item) {\n if (item !== undefined) {\n return getKey(item);\n }\n\n return notExistKey;\n } // Loop to find diff one\n\n\n var diffIndex = null;\n var multiple = Math.abs(originLen - targetLen) !== 1;\n\n for (var i = 0; i < longList.length; i += 1) {\n var shortKey = getItemKey(shortList[i]);\n var longKey = getItemKey(longList[i]);\n\n if (shortKey !== longKey) {\n diffIndex = i;\n multiple = multiple || shortKey !== getItemKey(longList[i + 1]);\n break;\n }\n }\n\n return diffIndex === null ? null : {\n index: diffIndex,\n multiple: multiple\n };\n}","function _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nvar isFF = (typeof navigator === \"undefined\" ? \"undefined\" : _typeof(navigator)) === 'object' && /Firefox/i.test(navigator.userAgent);\nexport default isFF;","function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\nfunction _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }\n\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\n\nfunction _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === \"string\") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === \"Object\" && o.constructor) n = o.constructor.name; if (n === \"Map\" || n === \"Set\") return Array.from(o); if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }\n\nfunction _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }\n\nfunction _iterableToArrayLimit(arr, i) { if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i[\"return\"] != null) _i[\"return\"](); } finally { if (_d) throw _e; } } return _arr; }\n\nfunction _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport * as React from 'react';\nimport { useRef, useState } from 'react';\nimport classNames from 'classnames';\nimport Filler from './Filler';\nimport ScrollBar from './ScrollBar';\nimport useChildren from './hooks/useChildren';\nimport useHeights from './hooks/useHeights';\nimport useInRange from './hooks/useInRange';\nimport useScrollTo from './hooks/useScrollTo';\nimport useDiffItem from './hooks/useDiffItem';\nimport useFrameWheel from './hooks/useFrameWheel';\nimport useMobileTouchMove from './hooks/useMobileTouchMove';\nvar EMPTY_DATA = [];\nvar ScrollStyle = {\n overflowY: 'auto',\n overflowAnchor: 'none'\n};\nexport function RawList(props, ref) {\n var _props$prefixCls = props.prefixCls,\n prefixCls = _props$prefixCls === void 0 ? 'rc-virtual-list' : _props$prefixCls,\n className = props.className,\n height = props.height,\n itemHeight = props.itemHeight,\n _props$fullHeight = props.fullHeight,\n fullHeight = _props$fullHeight === void 0 ? true : _props$fullHeight,\n style = props.style,\n data = props.data,\n children = props.children,\n itemKey = props.itemKey,\n virtual = props.virtual,\n _props$component = props.component,\n Component = _props$component === void 0 ? 'div' : _props$component,\n onScroll = props.onScroll,\n restProps = _objectWithoutProperties(props, [\"prefixCls\", \"className\", \"height\", \"itemHeight\", \"fullHeight\", \"style\", \"data\", \"children\", \"itemKey\", \"virtual\", \"component\", \"onScroll\"]); // ================================= MISC =================================\n\n\n var inVirtual = virtual !== false && height && itemHeight && data && itemHeight * data.length > height;\n\n var _useState = useState(0),\n _useState2 = _slicedToArray(_useState, 2),\n scrollTop = _useState2[0],\n setScrollTop = _useState2[1];\n\n var _useState3 = useState(false),\n _useState4 = _slicedToArray(_useState3, 2),\n scrollMoving = _useState4[0],\n setScrollMoving = _useState4[1];\n\n var mergedClassName = classNames(prefixCls, className);\n var mergedData = data || EMPTY_DATA;\n var componentRef = useRef(); // =============================== Item Key ===============================\n\n var getKey = React.useCallback(function (item) {\n if (typeof itemKey === 'function') {\n return itemKey(item);\n }\n\n return item[itemKey];\n }, [itemKey]);\n var sharedConfig = {\n getKey: getKey\n }; // ================================ Scroll ================================\n\n function syncScrollTop(newTop) {\n setScrollTop(function (origin) {\n var value;\n\n if (typeof newTop === 'function') {\n value = newTop(origin);\n } else {\n value = newTop;\n }\n\n componentRef.current.scrollTop = value;\n return value;\n });\n } // ================================ Legacy ================================\n // Put ref here since the range is generate by follow\n\n\n var rangeRef = useRef({\n start: 0,\n end: mergedData.length\n });\n var diffItemRef = useRef();\n\n var _useDiffItem = useDiffItem(mergedData, getKey),\n _useDiffItem2 = _slicedToArray(_useDiffItem, 1),\n diffItem = _useDiffItem2[0];\n\n diffItemRef.current = diffItem; // ================================ Height ================================\n\n var _useHeights = useHeights(getKey, null, null),\n _useHeights2 = _slicedToArray(_useHeights, 4),\n setInstanceRef = _useHeights2[0],\n collectHeight = _useHeights2[1],\n heights = _useHeights2[2],\n heightUpdatedMark = _useHeights2[3]; // ========================== Visible Calculation =========================\n\n\n var _React$useMemo = React.useMemo(function () {\n if (!inVirtual) {\n return {\n scrollHeight: undefined,\n start: 0,\n end: mergedData.length - 1,\n offset: undefined\n };\n }\n\n var itemTop = 0;\n var startIndex;\n var startOffset;\n var endIndex;\n var dataLen = mergedData.length;\n\n for (var i = 0; i < dataLen; i += 1) {\n var item = mergedData[i];\n var key = getKey(item);\n var cacheHeight = heights.get(key);\n var currentItemBottom = itemTop + (cacheHeight === undefined ? itemHeight : cacheHeight); // Check item top in the range\n\n if (currentItemBottom >= scrollTop && startIndex === undefined) {\n startIndex = i;\n startOffset = itemTop;\n } // Check item bottom in the range. We will render additional one item for motion usage\n\n\n if (currentItemBottom > scrollTop + height && endIndex === undefined) {\n endIndex = i;\n }\n\n itemTop = currentItemBottom;\n } // Fallback to normal if not match. This code should never reach\n\n /* istanbul ignore next */\n\n\n if (startIndex === undefined) {\n startIndex = 0;\n startOffset = 0;\n }\n\n if (endIndex === undefined) {\n endIndex = mergedData.length - 1;\n } // Give cache to improve scroll experience\n\n\n endIndex = Math.min(endIndex + 1, mergedData.length);\n return {\n scrollHeight: itemTop,\n start: startIndex,\n end: endIndex,\n offset: startOffset\n };\n }, [inVirtual, scrollTop, mergedData, heightUpdatedMark, height]),\n scrollHeight = _React$useMemo.scrollHeight,\n start = _React$useMemo.start,\n end = _React$useMemo.end,\n offset = _React$useMemo.offset;\n\n rangeRef.current.start = start;\n rangeRef.current.end = end; // =============================== In Range ===============================\n\n var keepInRange = useInRange(scrollHeight, height); // ================================ Scroll ================================\n\n function onScrollBar(newScrollTop) {\n var newTop = keepInRange(newScrollTop);\n\n if (newTop !== scrollTop) {\n syncScrollTop(newTop);\n }\n } // This code may only trigger in test case.\n // But we still need a sync if some special escape\n\n\n function onFallbackScroll(e) {\n var newScrollTop = e.currentTarget.scrollTop;\n\n if (newScrollTop !== scrollTop) {\n syncScrollTop(newScrollTop);\n } // Trigger origin onScroll\n\n\n onScroll === null || onScroll === void 0 ? void 0 : onScroll(e);\n } // Since this added in global,should use ref to keep update\n\n\n var _useFrameWheel = useFrameWheel(inVirtual, function (offsetY) {\n syncScrollTop(function (top) {\n var newTop = keepInRange(top + offsetY);\n return newTop;\n });\n }),\n _useFrameWheel2 = _slicedToArray(_useFrameWheel, 2),\n onRawWheel = _useFrameWheel2[0],\n onFireFoxScroll = _useFrameWheel2[1]; // Mobile touch move\n\n\n useMobileTouchMove(componentRef, function (deltaY) {\n onRawWheel({\n preventDefault: function preventDefault() {},\n deltaY: deltaY\n });\n });\n React.useEffect(function () {\n componentRef.current.addEventListener('wheel', onRawWheel);\n componentRef.current.addEventListener('DOMMouseScroll', onFireFoxScroll);\n return function () {\n componentRef.current.removeEventListener('wheel', onRawWheel);\n componentRef.current.removeEventListener('DOMMouseScroll', onFireFoxScroll);\n };\n }, [inVirtual]); // ================================= Ref ==================================\n\n var scrollTo = useScrollTo(componentRef, mergedData, heights, itemHeight, getKey, collectHeight, syncScrollTop);\n React.useImperativeHandle(ref, function () {\n return {\n scrollTo: scrollTo\n };\n }); // ================================ Render ================================\n\n var listChildren = useChildren(mergedData, start, end, setInstanceRef, children, sharedConfig);\n var componentStyle = null;\n\n if (height) {\n componentStyle = _objectSpread(_defineProperty({}, fullHeight ? 'height' : 'maxHeight', height), ScrollStyle);\n\n if (inVirtual) {\n componentStyle.overflowY = 'hidden';\n\n if (scrollMoving) {\n componentStyle.pointerEvents = 'none';\n }\n }\n }\n\n return React.createElement(\"div\", Object.assign({\n style: _objectSpread(_objectSpread({}, style), {}, {\n position: 'relative'\n }),\n className: mergedClassName\n }, restProps), React.createElement(Component, {\n className: \"\".concat(prefixCls, \"-holder\"),\n style: componentStyle,\n ref: componentRef,\n onScroll: onFallbackScroll\n }, React.createElement(Filler, {\n prefixCls: prefixCls,\n height: scrollHeight,\n offset: offset,\n onInnerResize: collectHeight\n }, listChildren)), inVirtual && React.createElement(ScrollBar, {\n prefixCls: prefixCls,\n scrollTop: scrollTop,\n height: height,\n scrollHeight: scrollHeight,\n count: mergedData.length,\n onScroll: onScrollBar,\n onStartMove: function onStartMove() {\n setScrollMoving(true);\n },\n onStopMove: function onStopMove() {\n setScrollMoving(false);\n }\n }));\n}\nvar List = React.forwardRef(RawList);\nList.displayName = 'List';\nexport default List;","import { useRef } from 'react';\nexport default function useInRange(scrollHeight, containerHeight) {\n var scrollHeightRef = useRef();\n var containerHeightRef = useRef();\n scrollHeightRef.current = scrollHeight;\n containerHeightRef.current = containerHeight;\n return function (scrollTop) {\n var newTop = Math.max(scrollTop, 0);\n var min = scrollHeightRef.current - containerHeightRef.current;\n\n if (!Number.isNaN(min)) {\n newTop = Math.min(newTop, min);\n }\n\n return newTop;\n };\n}","import { useRef } from 'react';\nimport raf from \"rc-util/es/raf\";\nimport isFF from '../utils/isFirefox';\nexport default function useFrameWheel(inVirtual, onWheelDelta) {\n var offsetRef = useRef(0);\n var nextFrameRef = useRef(null); // Firefox patch\n\n var wheelValueRef = useRef(null);\n var isMouseScrollRef = useRef(false);\n\n function onWheel(event) {\n if (!inVirtual) return; // Proxy of scroll events\n\n if (!isFF) {\n event.preventDefault();\n }\n\n raf.cancel(nextFrameRef.current);\n offsetRef.current += event.deltaY;\n wheelValueRef.current = event.deltaY;\n nextFrameRef.current = raf(function () {\n // Patch a multiple for Firefox to fix wheel number too small\n // ref: https://github.com/ant-design/ant-design/issues/26372#issuecomment-679460266\n var patchMultiple = isMouseScrollRef.current ? 10 : 1;\n onWheelDelta(offsetRef.current * patchMultiple);\n offsetRef.current = 0;\n });\n } // A patch for firefox\n\n\n function onFireFoxScroll(event) {\n if (!inVirtual) return; // Firefox level stop\n\n event.preventDefault();\n isMouseScrollRef.current = event.detail === wheelValueRef.current;\n }\n\n return [onWheel, onFireFoxScroll];\n}","import * as React from 'react';\nimport { useRef } from 'react';\nvar SMOOTH_PTG = 14 / 15;\nexport default function useMobileTouchMove(listRef, callback) {\n var touchedRef = useRef(false);\n var touchYRef = useRef(0);\n var elementRef = useRef(null); // Smooth scroll\n\n var intervalRef = useRef(null);\n var cleanUpEvents;\n\n var onTouchMove = function onTouchMove(e) {\n if (touchedRef.current) {\n var currentY = Math.ceil(e.touches[0].pageY);\n var offsetY = touchYRef.current - currentY;\n console.log('>>>', offsetY);\n touchYRef.current = currentY;\n callback(offsetY); // Smooth interval\n\n clearInterval(intervalRef.current);\n intervalRef.current = setInterval(function () {\n offsetY *= SMOOTH_PTG;\n callback(offsetY);\n\n if (Math.abs(offsetY) <= 0.1) {\n clearInterval(intervalRef.current);\n }\n }, 16);\n }\n };\n\n var onTouchEnd = function onTouchEnd() {\n touchedRef.current = false;\n cleanUpEvents();\n };\n\n var onTouchStart = function onTouchStart(e) {\n cleanUpEvents();\n\n if (e.touches.length === 1 && !touchedRef.current) {\n touchedRef.current = true;\n touchYRef.current = Math.ceil(e.touches[0].pageY);\n e.preventDefault();\n elementRef.current = e.target;\n elementRef.current.addEventListener('touchmove', onTouchMove);\n elementRef.current.addEventListener('touchend', onTouchEnd);\n }\n };\n\n cleanUpEvents = function cleanUpEvents() {\n if (elementRef.current) {\n elementRef.current.removeEventListener('touchmove', onTouchMove);\n elementRef.current.removeEventListener('touchend', onTouchEnd);\n }\n };\n\n React.useEffect(function () {\n listRef.current.addEventListener('touchstart', onTouchStart);\n return function () {\n listRef.current.removeEventListener('touchstart', onTouchStart);\n cleanUpEvents();\n clearInterval(intervalRef.current);\n };\n }, []);\n}","import * as React from 'react';\nimport { Item } from '../Item';\nexport default function useChildren(list, startIndex, endIndex, setNodeRef, renderFunc, _ref) {\n var getKey = _ref.getKey;\n return list.slice(startIndex, endIndex + 1).map(function (item, index) {\n var eleIndex = startIndex + index;\n var node = renderFunc(item, eleIndex, {// style: status === 'MEASURE_START' ? { visibility: 'hidden' } : {},\n });\n var key = getKey(item);\n return React.createElement(Item, {\n key: key,\n setRef: function setRef(ele) {\n return setNodeRef(item, ele);\n }\n }, node);\n });\n}","import List from './List';\nexport default List;","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport * as React from 'react';\nimport { composeRef } from \"rc-util/es/ref\";\n\nvar Input = function Input(_ref, ref) {\n var prefixCls = _ref.prefixCls,\n id = _ref.id,\n inputElement = _ref.inputElement,\n disabled = _ref.disabled,\n tabIndex = _ref.tabIndex,\n autoFocus = _ref.autoFocus,\n autoComplete = _ref.autoComplete,\n editable = _ref.editable,\n accessibilityIndex = _ref.accessibilityIndex,\n value = _ref.value,\n _onKeyDown = _ref.onKeyDown,\n _onMouseDown = _ref.onMouseDown,\n _onChange = _ref.onChange,\n onPaste = _ref.onPaste,\n _onCompositionStart = _ref.onCompositionStart,\n _onCompositionEnd = _ref.onCompositionEnd,\n open = _ref.open,\n attrs = _ref.attrs;\n var inputNode = inputElement || React.createElement(\"input\", null);\n var _inputNode = inputNode,\n originRef = _inputNode.ref,\n _inputNode$props = _inputNode.props,\n onOriginKeyDown = _inputNode$props.onKeyDown,\n onOriginChange = _inputNode$props.onChange,\n onOriginMouseDown = _inputNode$props.onMouseDown,\n onOriginCompositionStart = _inputNode$props.onCompositionStart,\n onOriginCompositionEnd = _inputNode$props.onCompositionEnd,\n style = _inputNode$props.style;\n inputNode = React.cloneElement(inputNode, _objectSpread(_objectSpread({\n id: id,\n ref: composeRef(ref, originRef),\n disabled: disabled,\n tabIndex: tabIndex,\n autoComplete: autoComplete || 'off',\n autoFocus: autoFocus,\n className: \"\".concat(prefixCls, \"-selection-search-input\"),\n style: _objectSpread(_objectSpread({}, style), {}, {\n opacity: editable ? null : 0\n }),\n role: 'combobox',\n 'aria-expanded': open,\n 'aria-haspopup': 'listbox',\n 'aria-owns': \"\".concat(id, \"_list\"),\n 'aria-autocomplete': 'list',\n 'aria-controls': \"\".concat(id, \"_list\"),\n 'aria-activedescendant': \"\".concat(id, \"_list_\").concat(accessibilityIndex)\n }, attrs), {}, {\n value: editable ? value : '',\n readOnly: !editable,\n unselectable: !editable ? 'on' : null,\n onKeyDown: function onKeyDown(event) {\n _onKeyDown(event);\n\n if (onOriginKeyDown) {\n onOriginKeyDown(event);\n }\n },\n onMouseDown: function onMouseDown(event) {\n _onMouseDown(event);\n\n if (onOriginMouseDown) {\n onOriginMouseDown(event);\n }\n },\n onChange: function onChange(event) {\n _onChange(event);\n\n if (onOriginChange) {\n onOriginChange(event);\n }\n },\n onCompositionStart: function onCompositionStart(event) {\n _onCompositionStart(event);\n\n if (onOriginCompositionStart) {\n onOriginCompositionStart(event);\n }\n },\n onCompositionEnd: function onCompositionEnd(event) {\n _onCompositionEnd(event);\n\n if (onOriginCompositionEnd) {\n onOriginCompositionEnd(event);\n }\n },\n onPaste: onPaste\n }));\n return inputNode;\n};\n\nvar RefInput = React.forwardRef(Input);\nRefInput.displayName = 'Input';\nexport default RefInput;","/* eslint-disable react-hooks/rules-of-hooks */\nimport * as React from 'react';\nimport { isBrowserClient } from '../utils/commonUtil';\n/**\n * Wrap `React.useLayoutEffect` which will not throw warning message in test env\n */\n\nexport default function useLayoutEffect(effect, deps) {\n // Never happen in test env\n if (isBrowserClient) {\n /* istanbul ignore next */\n React.useLayoutEffect(effect, deps);\n } else {\n React.useEffect(effect, deps);\n }\n}\n/* eslint-enable */","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport pickAttrs from \"rc-util/es/pickAttrs\";\nimport { CSSMotionList } from 'rc-motion';\nimport TransBtn from '../TransBtn';\nimport Input from './Input';\nimport useLayoutEffect from '../hooks/useLayoutEffect';\nvar REST_TAG_KEY = '__RC_SELECT_MAX_REST_COUNT__';\n\nvar SelectSelector = function SelectSelector(props) {\n var id = props.id,\n prefixCls = props.prefixCls,\n values = props.values,\n open = props.open,\n searchValue = props.searchValue,\n inputRef = props.inputRef,\n placeholder = props.placeholder,\n disabled = props.disabled,\n mode = props.mode,\n showSearch = props.showSearch,\n autoFocus = props.autoFocus,\n autoComplete = props.autoComplete,\n accessibilityIndex = props.accessibilityIndex,\n tabIndex = props.tabIndex,\n removeIcon = props.removeIcon,\n choiceTransitionName = props.choiceTransitionName,\n maxTagCount = props.maxTagCount,\n maxTagTextLength = props.maxTagTextLength,\n _props$maxTagPlacehol = props.maxTagPlaceholder,\n maxTagPlaceholder = _props$maxTagPlacehol === void 0 ? function (omittedValues) {\n return \"+ \".concat(omittedValues.length, \" ...\");\n } : _props$maxTagPlacehol,\n tagRender = props.tagRender,\n onSelect = props.onSelect,\n onInputChange = props.onInputChange,\n onInputPaste = props.onInputPaste,\n onInputKeyDown = props.onInputKeyDown,\n onInputMouseDown = props.onInputMouseDown,\n onInputCompositionStart = props.onInputCompositionStart,\n onInputCompositionEnd = props.onInputCompositionEnd;\n\n var _React$useState = React.useState(false),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n motionAppear = _React$useState2[0],\n setMotionAppear = _React$useState2[1];\n\n var measureRef = React.useRef(null);\n\n var _React$useState3 = React.useState(0),\n _React$useState4 = _slicedToArray(_React$useState3, 2),\n inputWidth = _React$useState4[0],\n setInputWidth = _React$useState4[1]; // ===================== Motion ======================\n\n\n React.useEffect(function () {\n setMotionAppear(true);\n }, []); // ===================== Search ======================\n\n var inputValue = open || mode === 'tags' ? searchValue : '';\n var inputEditable = mode === 'tags' || open && showSearch; // We measure width and set to the input immediately\n\n useLayoutEffect(function () {\n setInputWidth(measureRef.current.scrollWidth);\n }, [inputValue]); // ==================== Selection ====================\n\n var displayValues = values; // Cut by `maxTagCount`\n\n var restCount;\n\n if (typeof maxTagCount === 'number') {\n restCount = values.length - maxTagCount;\n displayValues = values.slice(0, maxTagCount);\n } // Update by `maxTagTextLength`\n\n\n if (typeof maxTagTextLength === 'number') {\n displayValues = displayValues.map(function (_ref) {\n var label = _ref.label,\n rest = _objectWithoutProperties(_ref, [\"label\"]);\n\n var displayLabel = label;\n\n if (typeof label === 'string' || typeof label === 'number') {\n var strLabel = String(displayLabel);\n\n if (strLabel.length > maxTagTextLength) {\n displayLabel = \"\".concat(strLabel.slice(0, maxTagTextLength), \"...\");\n }\n }\n\n return _objectSpread(_objectSpread({}, rest), {}, {\n label: displayLabel\n });\n });\n } // Fill rest\n\n\n if (restCount > 0) {\n displayValues.push({\n key: REST_TAG_KEY,\n label: typeof maxTagPlaceholder === 'function' ? maxTagPlaceholder(values.slice(maxTagCount)) : maxTagPlaceholder\n });\n }\n\n var selectionNode = React.createElement(CSSMotionList, {\n component: false,\n keys: displayValues,\n motionName: choiceTransitionName,\n motionAppear: motionAppear\n }, function (_ref2) {\n var key = _ref2.key,\n label = _ref2.label,\n value = _ref2.value,\n itemDisabled = _ref2.disabled,\n className = _ref2.className,\n style = _ref2.style;\n var mergedKey = key || value;\n var closable = key !== REST_TAG_KEY && !itemDisabled;\n\n var onMouseDown = function onMouseDown(event) {\n event.preventDefault();\n event.stopPropagation();\n };\n\n var onClose = function onClose(event) {\n if (event) event.stopPropagation();\n onSelect(value, {\n selected: false\n });\n };\n\n return typeof tagRender === 'function' ? React.createElement(\"span\", {\n key: mergedKey,\n onMouseDown: onMouseDown,\n className: className,\n style: style\n }, tagRender({\n label: label,\n value: value,\n disabled: itemDisabled,\n closable: closable,\n onClose: onClose\n })) : React.createElement(\"span\", {\n key: mergedKey,\n className: classNames(className, \"\".concat(prefixCls, \"-selection-item\"), _defineProperty({}, \"\".concat(prefixCls, \"-selection-item-disabled\"), itemDisabled)),\n style: style\n }, React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-selection-item-content\")\n }, label), closable && React.createElement(TransBtn, {\n className: \"\".concat(prefixCls, \"-selection-item-remove\"),\n onMouseDown: onMouseDown,\n onClick: onClose,\n customizeIcon: removeIcon\n }, \"\\xD7\"));\n });\n return React.createElement(React.Fragment, null, selectionNode, React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-selection-search\"),\n style: {\n width: inputWidth\n }\n }, React.createElement(Input, {\n ref: inputRef,\n open: open,\n prefixCls: prefixCls,\n id: id,\n inputElement: null,\n disabled: disabled,\n autoFocus: autoFocus,\n autoComplete: autoComplete,\n editable: inputEditable,\n accessibilityIndex: accessibilityIndex,\n value: inputValue,\n onKeyDown: onInputKeyDown,\n onMouseDown: onInputMouseDown,\n onChange: onInputChange,\n onPaste: onInputPaste,\n onCompositionStart: onInputCompositionStart,\n onCompositionEnd: onInputCompositionEnd,\n tabIndex: tabIndex,\n attrs: pickAttrs(props, true)\n }), React.createElement(\"span\", {\n ref: measureRef,\n className: \"\".concat(prefixCls, \"-selection-search-mirror\"),\n \"aria-hidden\": true\n }, inputValue, \"\\xA0\")), !values.length && !inputValue && React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-selection-placeholder\")\n }, placeholder));\n};\n\nexport default SelectSelector;","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport * as React from 'react';\nimport pickAttrs from \"rc-util/es/pickAttrs\";\nimport Input from './Input';\n\nvar SingleSelector = function SingleSelector(props) {\n var inputElement = props.inputElement,\n prefixCls = props.prefixCls,\n id = props.id,\n inputRef = props.inputRef,\n disabled = props.disabled,\n autoFocus = props.autoFocus,\n autoComplete = props.autoComplete,\n accessibilityIndex = props.accessibilityIndex,\n mode = props.mode,\n open = props.open,\n values = props.values,\n placeholder = props.placeholder,\n tabIndex = props.tabIndex,\n showSearch = props.showSearch,\n searchValue = props.searchValue,\n activeValue = props.activeValue,\n onInputKeyDown = props.onInputKeyDown,\n onInputMouseDown = props.onInputMouseDown,\n onInputChange = props.onInputChange,\n onInputPaste = props.onInputPaste,\n onInputCompositionStart = props.onInputCompositionStart,\n onInputCompositionEnd = props.onInputCompositionEnd;\n\n var _React$useState = React.useState(false),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n inputChanged = _React$useState2[0],\n setInputChanged = _React$useState2[1];\n\n var combobox = mode === 'combobox';\n var inputEditable = combobox || showSearch && open;\n var item = values[0];\n var inputValue = searchValue || '';\n\n if (combobox && activeValue && !inputChanged) {\n inputValue = activeValue;\n }\n\n React.useEffect(function () {\n if (combobox) {\n setInputChanged(false);\n }\n }, [combobox, activeValue]); // Not show text when closed expect combobox mode\n\n var hasTextInput = mode !== 'combobox' && !open ? false : !!inputValue;\n var title = item && (typeof item.label === 'string' || typeof item.label === 'number') ? item.label.toString() : undefined;\n return React.createElement(React.Fragment, null, React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-selection-search\")\n }, React.createElement(Input, {\n ref: inputRef,\n prefixCls: prefixCls,\n id: id,\n open: open,\n inputElement: inputElement,\n disabled: disabled,\n autoFocus: autoFocus,\n autoComplete: autoComplete,\n editable: inputEditable,\n accessibilityIndex: accessibilityIndex,\n value: inputValue,\n onKeyDown: onInputKeyDown,\n onMouseDown: onInputMouseDown,\n onChange: function onChange(e) {\n setInputChanged(true);\n onInputChange(e);\n },\n onPaste: onInputPaste,\n onCompositionStart: onInputCompositionStart,\n onCompositionEnd: onInputCompositionEnd,\n tabIndex: tabIndex,\n attrs: pickAttrs(props, true)\n })), !combobox && item && !hasTextInput && React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-selection-item\"),\n title: title\n }, item.label), !item && !hasTextInput && React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-selection-placeholder\")\n }, placeholder));\n};\n\nexport default SingleSelector;","import * as React from 'react';\n/**\n * Locker return cached mark.\n * If set to `true`, will return `true` in a short time even if set `false`.\n * If set to `false` and then set to `true`, will change to `true`.\n * And after time duration, it will back to `null` automatically.\n */\n\nexport default function useLock() {\n var duration = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 250;\n var lockRef = React.useRef(null);\n var timeoutRef = React.useRef(null); // Clean up\n\n React.useEffect(function () {\n return function () {\n window.clearTimeout(timeoutRef.current);\n };\n }, []);\n\n function doLock(locked) {\n if (locked || lockRef.current === null) {\n lockRef.current = locked;\n }\n\n window.clearTimeout(timeoutRef.current);\n timeoutRef.current = window.setTimeout(function () {\n lockRef.current = null;\n }, duration);\n }\n\n return [function () {\n return lockRef.current;\n }, doLock];\n}","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\n\n/**\n * Cursor rule:\n * 1. Only `showSearch` enabled\n * 2. Only `open` is `true`\n * 3. When typing, set `open` to `true` which hit rule of 2\n *\n * Accessibility:\n * - https://www.w3.org/TR/wai-aria-practices/examples/combobox/aria1.1pattern/listbox-combo.html\n */\nimport * as React from 'react';\nimport { useRef } from 'react';\nimport KeyCode from \"rc-util/es/KeyCode\";\nimport MultipleSelector from './MultipleSelector';\nimport SingleSelector from './SingleSelector';\nimport useLock from '../hooks/useLock';\n\nvar Selector = function Selector(props, ref) {\n var inputRef = useRef(null);\n var compositionStatusRef = useRef(false);\n var prefixCls = props.prefixCls,\n multiple = props.multiple,\n open = props.open,\n mode = props.mode,\n showSearch = props.showSearch,\n tokenWithEnter = props.tokenWithEnter,\n onSearch = props.onSearch,\n onSearchSubmit = props.onSearchSubmit,\n onToggleOpen = props.onToggleOpen,\n onInputKeyDown = props.onInputKeyDown,\n domRef = props.domRef; // ======================= Ref =======================\n\n React.useImperativeHandle(ref, function () {\n return {\n focus: function focus() {\n inputRef.current.focus();\n },\n blur: function blur() {\n inputRef.current.blur();\n }\n };\n }); // ====================== Input ======================\n\n var _useLock = useLock(0),\n _useLock2 = _slicedToArray(_useLock, 2),\n getInputMouseDown = _useLock2[0],\n setInputMouseDown = _useLock2[1];\n\n var onInternalInputKeyDown = function onInternalInputKeyDown(event) {\n var which = event.which;\n\n if (which === KeyCode.UP || which === KeyCode.DOWN) {\n event.preventDefault();\n }\n\n if (onInputKeyDown) {\n onInputKeyDown(event);\n }\n\n if (which === KeyCode.ENTER && mode === 'tags' && !compositionStatusRef.current && !open) {\n // When menu isn't open, OptionList won't trigger a value change\n // So when enter is pressed, the tag's input value should be emitted here to let selector know\n onSearchSubmit(event.target.value);\n }\n\n if (![KeyCode.SHIFT, KeyCode.TAB, KeyCode.BACKSPACE, KeyCode.ESC].includes(which)) {\n onToggleOpen(true);\n }\n };\n /**\n * We can not use `findDOMNode` sine it will get warning,\n * have to use timer to check if is input element.\n */\n\n\n var onInternalInputMouseDown = function onInternalInputMouseDown() {\n setInputMouseDown(true);\n }; // When paste come, ignore next onChange\n\n\n var pastedTextRef = useRef(null);\n\n var triggerOnSearch = function triggerOnSearch(value) {\n if (onSearch(value, true, compositionStatusRef.current) !== false) {\n onToggleOpen(true);\n }\n };\n\n var onInputCompositionStart = function onInputCompositionStart() {\n compositionStatusRef.current = true;\n };\n\n var onInputCompositionEnd = function onInputCompositionEnd() {\n compositionStatusRef.current = false;\n };\n\n var onInputChange = function onInputChange(event) {\n var value = event.target.value; // Pasted text should replace back to origin content\n\n if (tokenWithEnter && pastedTextRef.current && /[\\r\\n]/.test(pastedTextRef.current)) {\n // CRLF will be treated as a single space for input element\n var replacedText = pastedTextRef.current.replace(/\\r\\n/g, ' ').replace(/[\\r\\n]/g, ' ');\n value = value.replace(replacedText, pastedTextRef.current);\n }\n\n pastedTextRef.current = null;\n triggerOnSearch(value);\n };\n\n var onInputPaste = function onInputPaste(e) {\n var clipboardData = e.clipboardData;\n var value = clipboardData.getData('text');\n pastedTextRef.current = value;\n };\n\n var onMouseDown = function onMouseDown(event) {\n var inputMouseDown = getInputMouseDown();\n\n if (event.target !== inputRef.current) {\n if (!inputMouseDown) {\n event.preventDefault();\n } // Should focus input if click the selector\n\n\n var isIE = document.body.style.msTouchAction !== undefined;\n\n if (isIE) {\n setTimeout(function () {\n inputRef.current.focus();\n });\n } else {\n inputRef.current.focus();\n }\n }\n\n if (mode !== 'combobox' && (!showSearch || !inputMouseDown) || !open) {\n if (open) {\n onSearch('', true, false);\n }\n\n onToggleOpen();\n }\n }; // ================= Inner Selector ==================\n\n\n var sharedProps = {\n inputRef: inputRef,\n onInputKeyDown: onInternalInputKeyDown,\n onInputMouseDown: onInternalInputMouseDown,\n onInputChange: onInputChange,\n onInputPaste: onInputPaste,\n onInputCompositionStart: onInputCompositionStart,\n onInputCompositionEnd: onInputCompositionEnd\n };\n var selectNode = multiple ? React.createElement(MultipleSelector, Object.assign({}, props, sharedProps)) : React.createElement(SingleSelector, Object.assign({}, props, sharedProps));\n return React.createElement(\"div\", {\n ref: domRef,\n className: \"\".concat(prefixCls, \"-selector\"),\n onMouseDown: onMouseDown\n }, selectNode);\n};\n\nvar ForwardSelector = React.forwardRef(Selector);\nForwardSelector.displayName = 'Selector';\nexport default ForwardSelector;","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport Trigger from 'rc-trigger';\nimport classNames from 'classnames';\n\nvar getBuiltInPlacements = function getBuiltInPlacements(dropdownMatchSelectWidth) {\n // Enable horizontal overflow auto-adjustment when a custom dropdown width is provided\n var adjustX = typeof dropdownMatchSelectWidth !== 'number' ? 0 : 1;\n return {\n bottomLeft: {\n points: ['tl', 'bl'],\n offset: [0, 4],\n overflow: {\n adjustX: adjustX,\n adjustY: 1\n }\n },\n bottomRight: {\n points: ['tr', 'br'],\n offset: [0, 4],\n overflow: {\n adjustX: adjustX,\n adjustY: 1\n }\n },\n topLeft: {\n points: ['bl', 'tl'],\n offset: [0, -4],\n overflow: {\n adjustX: adjustX,\n adjustY: 1\n }\n },\n topRight: {\n points: ['br', 'tr'],\n offset: [0, -4],\n overflow: {\n adjustX: adjustX,\n adjustY: 1\n }\n }\n };\n};\n\nvar SelectTrigger = function SelectTrigger(props, ref) {\n var prefixCls = props.prefixCls,\n disabled = props.disabled,\n visible = props.visible,\n children = props.children,\n popupElement = props.popupElement,\n containerWidth = props.containerWidth,\n animation = props.animation,\n transitionName = props.transitionName,\n dropdownStyle = props.dropdownStyle,\n dropdownClassName = props.dropdownClassName,\n _props$direction = props.direction,\n direction = _props$direction === void 0 ? 'ltr' : _props$direction,\n _props$dropdownMatchS = props.dropdownMatchSelectWidth,\n dropdownMatchSelectWidth = _props$dropdownMatchS === void 0 ? true : _props$dropdownMatchS,\n dropdownRender = props.dropdownRender,\n dropdownAlign = props.dropdownAlign,\n getPopupContainer = props.getPopupContainer,\n empty = props.empty,\n getTriggerDOMNode = props.getTriggerDOMNode,\n restProps = _objectWithoutProperties(props, [\"prefixCls\", \"disabled\", \"visible\", \"children\", \"popupElement\", \"containerWidth\", \"animation\", \"transitionName\", \"dropdownStyle\", \"dropdownClassName\", \"direction\", \"dropdownMatchSelectWidth\", \"dropdownRender\", \"dropdownAlign\", \"getPopupContainer\", \"empty\", \"getTriggerDOMNode\"]);\n\n var dropdownPrefixCls = \"\".concat(prefixCls, \"-dropdown\");\n var popupNode = popupElement;\n\n if (dropdownRender) {\n popupNode = dropdownRender(popupElement);\n }\n\n var builtInPlacements = React.useMemo(function () {\n return getBuiltInPlacements(dropdownMatchSelectWidth);\n }, [dropdownMatchSelectWidth]); // ===================== Motion ======================\n\n var mergedTransitionName = animation ? \"\".concat(dropdownPrefixCls, \"-\").concat(animation) : transitionName; // ======================= Ref =======================\n\n var popupRef = React.useRef(null);\n React.useImperativeHandle(ref, function () {\n return {\n getPopupElement: function getPopupElement() {\n return popupRef.current;\n }\n };\n });\n\n var popupStyle = _objectSpread({\n minWidth: containerWidth\n }, dropdownStyle);\n\n if (typeof dropdownMatchSelectWidth === 'number') {\n popupStyle.width = dropdownMatchSelectWidth;\n } else if (dropdownMatchSelectWidth) {\n popupStyle.width = containerWidth;\n }\n\n return React.createElement(Trigger, Object.assign({}, restProps, {\n showAction: [],\n hideAction: [],\n popupPlacement: direction === 'rtl' ? 'bottomRight' : 'bottomLeft',\n builtinPlacements: builtInPlacements,\n prefixCls: dropdownPrefixCls,\n popupTransitionName: mergedTransitionName,\n popup: React.createElement(\"div\", {\n ref: popupRef\n }, popupNode),\n popupAlign: dropdownAlign,\n popupVisible: visible,\n getPopupContainer: getPopupContainer,\n popupClassName: classNames(dropdownClassName, _defineProperty({}, \"\".concat(dropdownPrefixCls, \"-empty\"), empty)),\n popupStyle: popupStyle,\n getTriggerDOMNode: getTriggerDOMNode\n }), children);\n};\n\nvar RefSelectTrigger = React.forwardRef(SelectTrigger);\nRefSelectTrigger.displayName = 'SelectTrigger';\nexport default RefSelectTrigger;","import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\n\n/**\n * To match accessibility requirement, we always provide an input in the component.\n * Other element will not set `tabIndex` to avoid `onBlur` sequence problem.\n * For focused select, we set `aria-live=\"polite\"` to update the accessibility content.\n *\n * ref:\n * - keyboard: https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/listbox_role#Keyboard_interactions\n */\nimport * as React from 'react';\nimport { useState, useRef, useEffect, useMemo } from 'react';\nimport KeyCode from \"rc-util/es/KeyCode\";\nimport classNames from 'classnames';\nimport useMergedState from \"rc-util/es/hooks/useMergedState\";\nimport Selector from './Selector';\nimport SelectTrigger from './SelectTrigger';\nimport { INTERNAL_PROPS_MARK } from './interface/generator';\nimport { toInnerValue, toOuterValues, removeLastEnabledValue, getUUID } from './utils/commonUtil';\nimport TransBtn from './TransBtn';\nimport useLock from './hooks/useLock';\nimport useDelayReset from './hooks/useDelayReset';\nimport useLayoutEffect from './hooks/useLayoutEffect';\nimport { getSeparatedContent } from './utils/valueUtil';\nimport useSelectTriggerControl from './hooks/useSelectTriggerControl';\nimport useCacheDisplayValue from './hooks/useCacheDisplayValue';\nimport useCacheOptions from './hooks/useCacheOptions';\nvar DEFAULT_OMIT_PROPS = ['removeIcon', 'placeholder', 'autoFocus', 'maxTagCount', 'maxTagTextLength', 'maxTagPlaceholder', 'choiceTransitionName', 'onInputKeyDown'];\n/**\n * This function is in internal usage.\n * Do not use it in your prod env since we may refactor this.\n */\n\nexport default function generateSelector(config) {\n var defaultPrefixCls = config.prefixCls,\n OptionList = config.components.optionList,\n convertChildrenToData = config.convertChildrenToData,\n flattenOptions = config.flattenOptions,\n getLabeledValue = config.getLabeledValue,\n filterOptions = config.filterOptions,\n isValueDisabled = config.isValueDisabled,\n findValueOption = config.findValueOption,\n warningProps = config.warningProps,\n fillOptionsWithMissingValue = config.fillOptionsWithMissingValue,\n omitDOMProps = config.omitDOMProps; // Use raw define since `React.FC` not support generic\n\n function Select(props, ref) {\n var _classNames2;\n\n var _props$prefixCls = props.prefixCls,\n prefixCls = _props$prefixCls === void 0 ? defaultPrefixCls : _props$prefixCls,\n className = props.className,\n id = props.id,\n open = props.open,\n defaultOpen = props.defaultOpen,\n options = props.options,\n children = props.children,\n mode = props.mode,\n value = props.value,\n defaultValue = props.defaultValue,\n labelInValue = props.labelInValue,\n showSearch = props.showSearch,\n inputValue = props.inputValue,\n searchValue = props.searchValue,\n filterOption = props.filterOption,\n _props$optionFilterPr = props.optionFilterProp,\n optionFilterProp = _props$optionFilterPr === void 0 ? 'value' : _props$optionFilterPr,\n _props$autoClearSearc = props.autoClearSearchValue,\n autoClearSearchValue = _props$autoClearSearc === void 0 ? true : _props$autoClearSearc,\n onSearch = props.onSearch,\n allowClear = props.allowClear,\n clearIcon = props.clearIcon,\n showArrow = props.showArrow,\n inputIcon = props.inputIcon,\n menuItemSelectedIcon = props.menuItemSelectedIcon,\n disabled = props.disabled,\n loading = props.loading,\n defaultActiveFirstOption = props.defaultActiveFirstOption,\n _props$notFoundConten = props.notFoundContent,\n notFoundContent = _props$notFoundConten === void 0 ? 'Not Found' : _props$notFoundConten,\n optionLabelProp = props.optionLabelProp,\n backfill = props.backfill,\n getInputElement = props.getInputElement,\n getPopupContainer = props.getPopupContainer,\n _props$listHeight = props.listHeight,\n listHeight = _props$listHeight === void 0 ? 200 : _props$listHeight,\n _props$listItemHeight = props.listItemHeight,\n listItemHeight = _props$listItemHeight === void 0 ? 20 : _props$listItemHeight,\n animation = props.animation,\n transitionName = props.transitionName,\n virtual = props.virtual,\n dropdownStyle = props.dropdownStyle,\n dropdownClassName = props.dropdownClassName,\n dropdownMatchSelectWidth = props.dropdownMatchSelectWidth,\n dropdownRender = props.dropdownRender,\n dropdownAlign = props.dropdownAlign,\n _props$showAction = props.showAction,\n showAction = _props$showAction === void 0 ? [] : _props$showAction,\n direction = props.direction,\n tokenSeparators = props.tokenSeparators,\n tagRender = props.tagRender,\n onPopupScroll = props.onPopupScroll,\n onDropdownVisibleChange = props.onDropdownVisibleChange,\n onFocus = props.onFocus,\n onBlur = props.onBlur,\n onKeyUp = props.onKeyUp,\n onKeyDown = props.onKeyDown,\n onMouseDown = props.onMouseDown,\n onChange = props.onChange,\n onSelect = props.onSelect,\n onDeselect = props.onDeselect,\n onClear = props.onClear,\n _props$internalProps = props.internalProps,\n internalProps = _props$internalProps === void 0 ? {} : _props$internalProps,\n restProps = _objectWithoutProperties(props, [\"prefixCls\", \"className\", \"id\", \"open\", \"defaultOpen\", \"options\", \"children\", \"mode\", \"value\", \"defaultValue\", \"labelInValue\", \"showSearch\", \"inputValue\", \"searchValue\", \"filterOption\", \"optionFilterProp\", \"autoClearSearchValue\", \"onSearch\", \"allowClear\", \"clearIcon\", \"showArrow\", \"inputIcon\", \"menuItemSelectedIcon\", \"disabled\", \"loading\", \"defaultActiveFirstOption\", \"notFoundContent\", \"optionLabelProp\", \"backfill\", \"getInputElement\", \"getPopupContainer\", \"listHeight\", \"listItemHeight\", \"animation\", \"transitionName\", \"virtual\", \"dropdownStyle\", \"dropdownClassName\", \"dropdownMatchSelectWidth\", \"dropdownRender\", \"dropdownAlign\", \"showAction\", \"direction\", \"tokenSeparators\", \"tagRender\", \"onPopupScroll\", \"onDropdownVisibleChange\", \"onFocus\", \"onBlur\", \"onKeyUp\", \"onKeyDown\", \"onMouseDown\", \"onChange\", \"onSelect\", \"onDeselect\", \"onClear\", \"internalProps\"]);\n\n var useInternalProps = internalProps.mark === INTERNAL_PROPS_MARK;\n var domProps = omitDOMProps ? omitDOMProps(restProps) : restProps;\n DEFAULT_OMIT_PROPS.forEach(function (prop) {\n delete domProps[prop];\n });\n var containerRef = useRef(null);\n var triggerRef = useRef(null);\n var selectorRef = useRef(null);\n var listRef = useRef(null);\n var tokenWithEnter = useMemo(function () {\n return (tokenSeparators || []).some(function (tokenSeparator) {\n return ['\\n', '\\r\\n'].includes(tokenSeparator);\n });\n }, [tokenSeparators]);\n /** Used for component focused management */\n\n var _useDelayReset = useDelayReset(),\n _useDelayReset2 = _slicedToArray(_useDelayReset, 3),\n mockFocused = _useDelayReset2[0],\n setMockFocused = _useDelayReset2[1],\n cancelSetMockFocused = _useDelayReset2[2]; // Inner id for accessibility usage. Only work in client side\n\n\n var _useState = useState(),\n _useState2 = _slicedToArray(_useState, 2),\n innerId = _useState2[0],\n setInnerId = _useState2[1];\n\n useEffect(function () {\n setInnerId(\"rc_select_\".concat(getUUID()));\n }, []);\n var mergedId = id || innerId; // optionLabelProp\n\n var mergedOptionLabelProp = optionLabelProp;\n\n if (mergedOptionLabelProp === undefined) {\n mergedOptionLabelProp = options ? 'label' : 'children';\n } // labelInValue\n\n\n var mergedLabelInValue = mode === 'combobox' ? false : labelInValue;\n var isMultiple = mode === 'tags' || mode === 'multiple';\n var mergedShowSearch = showSearch !== undefined ? showSearch : isMultiple || mode === 'combobox'; // ============================== Ref ===============================\n\n var selectorDomRef = useRef(null);\n React.useImperativeHandle(ref, function () {\n return {\n focus: selectorRef.current.focus,\n blur: selectorRef.current.blur\n };\n }); // ============================= Value ==============================\n\n var _useMergedState = useMergedState(defaultValue, {\n value: value\n }),\n _useMergedState2 = _slicedToArray(_useMergedState, 2),\n mergedValue = _useMergedState2[0],\n setMergedValue = _useMergedState2[1];\n /** Unique raw values */\n\n\n var mergedRawValue = useMemo(function () {\n return toInnerValue(mergedValue, {\n labelInValue: mergedLabelInValue,\n combobox: mode === 'combobox'\n });\n }, [mergedValue, mergedLabelInValue]);\n /** We cache a set of raw values to speed up check */\n\n var rawValues = useMemo(function () {\n return new Set(mergedRawValue);\n }, [mergedRawValue]); // ============================= Option =============================\n // Set by option list active, it will merge into search input when mode is `combobox`\n\n var _useState3 = useState(null),\n _useState4 = _slicedToArray(_useState3, 2),\n activeValue = _useState4[0],\n setActiveValue = _useState4[1];\n\n var _useState5 = useState(''),\n _useState6 = _slicedToArray(_useState5, 2),\n innerSearchValue = _useState6[0],\n setInnerSearchValue = _useState6[1];\n\n var mergedSearchValue = innerSearchValue;\n\n if (mode === 'combobox' && mergedValue !== undefined) {\n mergedSearchValue = mergedValue;\n } else if (searchValue !== undefined) {\n mergedSearchValue = searchValue;\n } else if (inputValue) {\n mergedSearchValue = inputValue;\n }\n\n var mergedOptions = useMemo(function () {\n var newOptions = options;\n\n if (newOptions === undefined) {\n newOptions = convertChildrenToData(children);\n }\n /**\n * `tags` should fill un-list item.\n * This is not cool here since TreeSelect do not need this\n */\n\n\n if (mode === 'tags' && fillOptionsWithMissingValue) {\n newOptions = fillOptionsWithMissingValue(newOptions, mergedValue, mergedOptionLabelProp, labelInValue);\n }\n\n return newOptions || [];\n }, [options, children, mode, mergedValue]);\n var mergedFlattenOptions = useMemo(function () {\n return flattenOptions(mergedOptions, props);\n }, [mergedOptions]);\n var getValueOption = useCacheOptions(mergedRawValue, mergedFlattenOptions); // Display options for OptionList\n\n var displayOptions = useMemo(function () {\n if (!mergedSearchValue || !mergedShowSearch) {\n return _toConsumableArray(mergedOptions);\n }\n\n var filteredOptions = filterOptions(mergedSearchValue, mergedOptions, {\n optionFilterProp: optionFilterProp,\n filterOption: mode === 'combobox' && filterOption === undefined ? function () {\n return true;\n } : filterOption\n });\n\n if (mode === 'tags' && filteredOptions.every(function (opt) {\n return opt[optionFilterProp] !== mergedSearchValue;\n })) {\n filteredOptions.unshift({\n value: mergedSearchValue,\n label: mergedSearchValue,\n key: '__RC_SELECT_TAG_PLACEHOLDER__'\n });\n }\n\n return filteredOptions;\n }, [mergedOptions, mergedSearchValue, mode, mergedShowSearch]);\n var displayFlattenOptions = useMemo(function () {\n return flattenOptions(displayOptions, props);\n }, [displayOptions]);\n useEffect(function () {\n if (listRef.current && listRef.current.scrollTo) {\n listRef.current.scrollTo(0);\n }\n }, [mergedSearchValue]); // ============================ Selector ============================\n\n var displayValues = useMemo(function () {\n var tmpValues = mergedRawValue.map(function (val) {\n var valueOptions = getValueOption([val]);\n var displayValue = getLabeledValue(val, {\n options: valueOptions,\n prevValue: mergedValue,\n labelInValue: mergedLabelInValue,\n optionLabelProp: mergedOptionLabelProp\n });\n return _objectSpread(_objectSpread({}, displayValue), {}, {\n disabled: isValueDisabled(val, valueOptions)\n });\n });\n\n if (!mode && tmpValues.length === 1 && tmpValues[0].value === null && tmpValues[0].label === null) {\n return [];\n }\n\n return tmpValues;\n }, [mergedValue, mergedOptions, mode]); // Polyfill with cache label\n\n displayValues = useCacheDisplayValue(displayValues);\n\n var triggerSelect = function triggerSelect(newValue, isSelect, source) {\n var newValueOption = getValueOption([newValue]);\n var outOption = findValueOption([newValue], newValueOption)[0];\n\n if (!internalProps.skipTriggerSelect) {\n // Skip trigger `onSelect` or `onDeselect` if configured\n var selectValue = mergedLabelInValue ? getLabeledValue(newValue, {\n options: newValueOption,\n prevValue: mergedValue,\n labelInValue: mergedLabelInValue,\n optionLabelProp: mergedOptionLabelProp\n }) : newValue;\n\n if (isSelect && onSelect) {\n onSelect(selectValue, outOption);\n } else if (!isSelect && onDeselect) {\n onDeselect(selectValue, outOption);\n }\n } // Trigger internal event\n\n\n if (useInternalProps) {\n if (isSelect && internalProps.onRawSelect) {\n internalProps.onRawSelect(newValue, outOption, source);\n } else if (!isSelect && internalProps.onRawDeselect) {\n internalProps.onRawDeselect(newValue, outOption, source);\n }\n }\n }; // We need cache options here in case user update the option list\n\n\n var _useState7 = useState([]),\n _useState8 = _slicedToArray(_useState7, 2),\n prevValueOptions = _useState8[0],\n setPrevValueOptions = _useState8[1];\n\n var triggerChange = function triggerChange(newRawValues) {\n if (useInternalProps && internalProps.skipTriggerChange) {\n return;\n }\n\n var newRawValuesOptions = getValueOption(newRawValues);\n var outValues = toOuterValues(Array.from(newRawValues), {\n labelInValue: mergedLabelInValue,\n options: newRawValuesOptions,\n getLabeledValue: getLabeledValue,\n prevValue: mergedValue,\n optionLabelProp: mergedOptionLabelProp\n });\n var outValue = isMultiple ? outValues : outValues[0]; // Skip trigger if prev & current value is both empty\n\n if (onChange && (mergedRawValue.length !== 0 || outValues.length !== 0)) {\n var outOptions = findValueOption(newRawValues, newRawValuesOptions, {\n prevValueOptions: prevValueOptions\n }); // We will cache option in case it removed by ajax\n\n setPrevValueOptions(outOptions.map(function (option, index) {\n var clone = _objectSpread({}, option);\n\n Object.defineProperty(clone, '_INTERNAL_OPTION_VALUE_', {\n get: function get() {\n return newRawValues[index];\n }\n });\n return clone;\n }));\n onChange(outValue, isMultiple ? outOptions : outOptions[0]);\n }\n\n setMergedValue(outValue);\n };\n\n var onInternalSelect = function onInternalSelect(newValue, _ref) {\n var selected = _ref.selected,\n source = _ref.source;\n\n if (disabled) {\n return;\n }\n\n var newRawValue;\n\n if (isMultiple) {\n newRawValue = new Set(mergedRawValue);\n\n if (selected) {\n newRawValue.add(newValue);\n } else {\n newRawValue.delete(newValue);\n }\n } else {\n newRawValue = new Set();\n newRawValue.add(newValue);\n } // Multiple always trigger change and single should change if value changed\n\n\n if (isMultiple || !isMultiple && Array.from(mergedRawValue)[0] !== newValue) {\n triggerChange(Array.from(newRawValue));\n } // Trigger `onSelect`. Single mode always trigger select\n\n\n triggerSelect(newValue, !isMultiple || selected, source); // Clean search value if single or configured\n\n if (mode === 'combobox') {\n setInnerSearchValue(String(newValue));\n setActiveValue('');\n } else if (!isMultiple || autoClearSearchValue) {\n setInnerSearchValue('');\n setActiveValue('');\n }\n };\n\n var onInternalOptionSelect = function onInternalOptionSelect(newValue, info) {\n onInternalSelect(newValue, _objectSpread(_objectSpread({}, info), {}, {\n source: 'option'\n }));\n };\n\n var onInternalSelectionSelect = function onInternalSelectionSelect(newValue, info) {\n onInternalSelect(newValue, _objectSpread(_objectSpread({}, info), {}, {\n source: 'selection'\n }));\n }; // ============================= Input ==============================\n // Only works in `combobox`\n\n\n var customizeInputElement = mode === 'combobox' && getInputElement && getInputElement() || null; // ============================== Open ==============================\n\n var _useMergedState3 = useMergedState(undefined, {\n defaultValue: defaultOpen,\n value: open\n }),\n _useMergedState4 = _slicedToArray(_useMergedState3, 2),\n innerOpen = _useMergedState4[0],\n setInnerOpen = _useMergedState4[1];\n\n var mergedOpen = innerOpen; // Not trigger `open` in `combobox` when `notFoundContent` is empty\n\n var emptyListContent = !notFoundContent && !displayOptions.length;\n\n if (disabled || emptyListContent && mergedOpen && mode === 'combobox') {\n mergedOpen = false;\n }\n\n var triggerOpen = emptyListContent ? false : mergedOpen;\n\n var onToggleOpen = function onToggleOpen(newOpen) {\n var nextOpen = newOpen !== undefined ? newOpen : !mergedOpen;\n\n if (innerOpen !== nextOpen && !disabled) {\n setInnerOpen(nextOpen);\n\n if (onDropdownVisibleChange) {\n onDropdownVisibleChange(nextOpen);\n }\n }\n };\n\n useSelectTriggerControl([containerRef.current, triggerRef.current && triggerRef.current.getPopupElement()], triggerOpen, onToggleOpen); // ============================= Search =============================\n\n var triggerSearch = function triggerSearch(searchText, fromTyping, isCompositing) {\n var ret = true;\n var newSearchText = searchText;\n setActiveValue(null); // Check if match the `tokenSeparators`\n\n var patchLabels = isCompositing ? null : getSeparatedContent(searchText, tokenSeparators);\n var patchRawValues = patchLabels;\n\n if (mode === 'combobox') {\n // Only typing will trigger onChange\n if (fromTyping) {\n triggerChange([newSearchText]);\n }\n } else if (patchLabels) {\n newSearchText = '';\n\n if (mode !== 'tags') {\n patchRawValues = patchLabels.map(function (label) {\n var item = mergedFlattenOptions.find(function (_ref2) {\n var data = _ref2.data;\n return data[mergedOptionLabelProp] === label;\n });\n return item ? item.data.value : null;\n }).filter(function (val) {\n return val !== null;\n });\n }\n\n var newRawValues = Array.from(new Set([].concat(_toConsumableArray(mergedRawValue), _toConsumableArray(patchRawValues))));\n triggerChange(newRawValues);\n newRawValues.forEach(function (newRawValue) {\n triggerSelect(newRawValue, true, 'input');\n }); // Should close when paste finish\n\n onToggleOpen(false); // Tell Selector that break next actions\n\n ret = false;\n }\n\n setInnerSearchValue(newSearchText);\n\n if (onSearch && mergedSearchValue !== newSearchText) {\n onSearch(newSearchText);\n }\n\n return ret;\n }; // Only triggered when menu is closed & mode is tags\n // If menu is open, OptionList will take charge\n // If mode isn't tags, press enter is not meaningful when you can't see any option\n\n\n var onSearchSubmit = function onSearchSubmit(searchText) {\n var newRawValues = Array.from(new Set([].concat(_toConsumableArray(mergedRawValue), [searchText])));\n triggerChange(newRawValues);\n newRawValues.forEach(function (newRawValue) {\n triggerSelect(newRawValue, true, 'input');\n });\n setInnerSearchValue('');\n }; // Close dropdown when disabled change\n\n\n useEffect(function () {\n if (innerOpen && !!disabled) {\n setInnerOpen(false);\n }\n }, [disabled]); // Close will clean up single mode search text\n\n useEffect(function () {\n if (!mergedOpen && !isMultiple && mode !== 'combobox') {\n triggerSearch('', false, false);\n }\n }, [mergedOpen]); // ============================ Keyboard ============================\n\n /**\n * We record input value here to check if can press to clean up by backspace\n * - null: Key is not down, this is reset by key up\n * - true: Search text is empty when first time backspace down\n * - false: Search text is not empty when first time backspace down\n */\n\n var _useLock = useLock(),\n _useLock2 = _slicedToArray(_useLock, 2),\n getClearLock = _useLock2[0],\n setClearLock = _useLock2[1]; // KeyDown\n\n\n var onInternalKeyDown = function onInternalKeyDown(event) {\n var clearLock = getClearLock();\n var which = event.which; // We only manage open state here, close logic should handle by list component\n\n if (!mergedOpen && which === KeyCode.ENTER) {\n onToggleOpen(true);\n }\n\n setClearLock(!!mergedSearchValue); // Remove value by `backspace`\n\n if (which === KeyCode.BACKSPACE && !clearLock && isMultiple && !mergedSearchValue && mergedRawValue.length) {\n var removeInfo = removeLastEnabledValue(displayValues, mergedRawValue);\n\n if (removeInfo.removedValue !== null) {\n triggerChange(removeInfo.values);\n triggerSelect(removeInfo.removedValue, false, 'input');\n }\n }\n\n for (var _len = arguments.length, rest = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n rest[_key - 1] = arguments[_key];\n }\n\n if (mergedOpen && listRef.current) {\n var _listRef$current;\n\n (_listRef$current = listRef.current).onKeyDown.apply(_listRef$current, [event].concat(rest));\n }\n\n if (onKeyDown) {\n onKeyDown.apply(void 0, [event].concat(rest));\n }\n }; // KeyUp\n\n\n var onInternalKeyUp = function onInternalKeyUp(event) {\n for (var _len2 = arguments.length, rest = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {\n rest[_key2 - 1] = arguments[_key2];\n }\n\n if (mergedOpen && listRef.current) {\n var _listRef$current2;\n\n (_listRef$current2 = listRef.current).onKeyUp.apply(_listRef$current2, [event].concat(rest));\n }\n\n if (onKeyUp) {\n onKeyUp.apply(void 0, [event].concat(rest));\n }\n }; // ========================== Focus / Blur ==========================\n\n /** Record real focus status */\n\n\n var focusRef = useRef(false);\n\n var onContainerFocus = function onContainerFocus() {\n setMockFocused(true);\n\n if (!disabled) {\n if (onFocus && !focusRef.current) {\n onFocus.apply(void 0, arguments);\n } // `showAction` should handle `focus` if set\n\n\n if (showAction.includes('focus')) {\n onToggleOpen(true);\n }\n }\n\n focusRef.current = true;\n };\n\n var onContainerBlur = function onContainerBlur() {\n setMockFocused(false, function () {\n focusRef.current = false;\n onToggleOpen(false);\n });\n\n if (disabled) {\n return;\n }\n\n if (mergedSearchValue) {\n // `tags` mode should move `searchValue` into values\n if (mode === 'tags') {\n triggerSearch('', false, false);\n triggerChange(Array.from(new Set([].concat(_toConsumableArray(mergedRawValue), [mergedSearchValue]))));\n } else if (mode === 'multiple') {\n // `multiple` mode only clean the search value but not trigger event\n setInnerSearchValue('');\n }\n }\n\n if (onBlur) {\n onBlur.apply(void 0, arguments);\n }\n };\n\n var activeTimeoutIds = [];\n useEffect(function () {\n return function () {\n activeTimeoutIds.forEach(function (timeoutId) {\n return clearTimeout(timeoutId);\n });\n activeTimeoutIds.splice(0, activeTimeoutIds.length);\n };\n }, []);\n\n var onInternalMouseDown = function onInternalMouseDown(event) {\n var target = event.target;\n var popupElement = triggerRef.current && triggerRef.current.getPopupElement(); // We should give focus back to selector if clicked item is not focusable\n\n if (popupElement && popupElement.contains(target)) {\n var timeoutId = setTimeout(function () {\n var index = activeTimeoutIds.indexOf(timeoutId);\n\n if (index !== -1) {\n activeTimeoutIds.splice(index, 1);\n }\n\n cancelSetMockFocused();\n\n if (!popupElement.contains(document.activeElement)) {\n selectorRef.current.focus();\n }\n });\n activeTimeoutIds.push(timeoutId);\n }\n\n if (onMouseDown) {\n for (var _len3 = arguments.length, restArgs = new Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {\n restArgs[_key3 - 1] = arguments[_key3];\n }\n\n onMouseDown.apply(void 0, [event].concat(restArgs));\n }\n }; // ========================= Accessibility ==========================\n\n\n var _useState9 = useState(0),\n _useState10 = _slicedToArray(_useState9, 2),\n accessibilityIndex = _useState10[0],\n setAccessibilityIndex = _useState10[1];\n\n var mergedDefaultActiveFirstOption = defaultActiveFirstOption !== undefined ? defaultActiveFirstOption : mode !== 'combobox';\n\n var onActiveValue = function onActiveValue(active, index) {\n setAccessibilityIndex(index);\n\n if (backfill && mode === 'combobox' && active !== null) {\n setActiveValue(String(active));\n }\n }; // ============================= Popup ==============================\n\n\n var _useState11 = useState(null),\n _useState12 = _slicedToArray(_useState11, 2),\n containerWidth = _useState12[0],\n setContainerWidth = _useState12[1];\n\n var _useState13 = useState({}),\n _useState14 = _slicedToArray(_useState13, 2),\n forceUpdate = _useState14[1]; // We need force update here since popup dom is render async\n\n\n function onPopupMouseEnter() {\n forceUpdate({});\n }\n\n useLayoutEffect(function () {\n if (triggerOpen) {\n var newWidth = Math.ceil(containerRef.current.offsetWidth);\n\n if (containerWidth !== newWidth) {\n setContainerWidth(newWidth);\n }\n }\n }, [triggerOpen]);\n var popupNode = React.createElement(OptionList, {\n ref: listRef,\n prefixCls: prefixCls,\n id: mergedId,\n open: mergedOpen,\n childrenAsData: !options,\n options: displayOptions,\n flattenOptions: displayFlattenOptions,\n multiple: isMultiple,\n values: rawValues,\n height: listHeight,\n itemHeight: listItemHeight,\n onSelect: onInternalOptionSelect,\n onToggleOpen: onToggleOpen,\n onActiveValue: onActiveValue,\n defaultActiveFirstOption: mergedDefaultActiveFirstOption,\n notFoundContent: notFoundContent,\n onScroll: onPopupScroll,\n searchValue: mergedSearchValue,\n menuItemSelectedIcon: menuItemSelectedIcon,\n virtual: virtual !== false && dropdownMatchSelectWidth !== false,\n onMouseEnter: onPopupMouseEnter\n }); // ============================= Clear ==============================\n\n var clearNode;\n\n var onClearMouseDown = function onClearMouseDown() {\n // Trigger internal `onClear` event\n if (useInternalProps && internalProps.onClear) {\n internalProps.onClear();\n }\n\n if (onClear) {\n onClear();\n }\n\n triggerChange([]);\n triggerSearch('', false, false);\n };\n\n if (!disabled && allowClear && (mergedRawValue.length || mergedSearchValue)) {\n clearNode = React.createElement(TransBtn, {\n className: \"\".concat(prefixCls, \"-clear\"),\n onMouseDown: onClearMouseDown,\n customizeIcon: clearIcon\n }, \"\\xD7\");\n } // ============================= Arrow ==============================\n\n\n var mergedShowArrow = showArrow !== undefined ? showArrow : loading || !isMultiple && mode !== 'combobox';\n var arrowNode;\n\n if (mergedShowArrow) {\n arrowNode = React.createElement(TransBtn, {\n className: classNames(\"\".concat(prefixCls, \"-arrow\"), _defineProperty({}, \"\".concat(prefixCls, \"-arrow-loading\"), loading)),\n customizeIcon: inputIcon,\n customizeIconProps: {\n loading: loading,\n searchValue: mergedSearchValue,\n open: mergedOpen,\n focused: mockFocused,\n showSearch: mergedShowSearch\n }\n });\n } // ============================ Warning =============================\n\n\n if (process.env.NODE_ENV !== 'production' && warningProps) {\n warningProps(props);\n } // ============================= Render =============================\n\n\n var mergedClassName = classNames(prefixCls, className, (_classNames2 = {}, _defineProperty(_classNames2, \"\".concat(prefixCls, \"-focused\"), mockFocused), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-multiple\"), isMultiple), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-single\"), !isMultiple), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-allow-clear\"), allowClear), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-show-arrow\"), mergedShowArrow), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-disabled\"), disabled), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-loading\"), loading), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-open\"), mergedOpen), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-customize-input\"), customizeInputElement), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-show-search\"), mergedShowSearch), _classNames2));\n return React.createElement(\"div\", Object.assign({\n className: mergedClassName\n }, domProps, {\n ref: containerRef,\n onMouseDown: onInternalMouseDown,\n onKeyDown: onInternalKeyDown,\n onKeyUp: onInternalKeyUp,\n onFocus: onContainerFocus,\n onBlur: onContainerBlur\n }), mockFocused && !mergedOpen && React.createElement(\"span\", {\n style: {\n width: 0,\n height: 0,\n display: 'flex',\n overflow: 'hidden',\n opacity: 0\n },\n \"aria-live\": \"polite\"\n }, \"\".concat(mergedRawValue.join(', '))), React.createElement(SelectTrigger, {\n ref: triggerRef,\n disabled: disabled,\n prefixCls: prefixCls,\n visible: triggerOpen,\n popupElement: popupNode,\n containerWidth: containerWidth,\n animation: animation,\n transitionName: transitionName,\n dropdownStyle: dropdownStyle,\n dropdownClassName: dropdownClassName,\n direction: direction,\n dropdownMatchSelectWidth: dropdownMatchSelectWidth,\n dropdownRender: dropdownRender,\n dropdownAlign: dropdownAlign,\n getPopupContainer: getPopupContainer,\n empty: !mergedOptions.length,\n getTriggerDOMNode: function getTriggerDOMNode() {\n return selectorDomRef.current;\n }\n }, React.createElement(Selector, Object.assign({}, props, {\n domRef: selectorDomRef,\n prefixCls: prefixCls,\n inputElement: customizeInputElement,\n ref: selectorRef,\n id: mergedId,\n showSearch: mergedShowSearch,\n mode: mode,\n accessibilityIndex: accessibilityIndex,\n multiple: isMultiple,\n tagRender: tagRender,\n values: displayValues,\n open: mergedOpen,\n onToggleOpen: onToggleOpen,\n searchValue: mergedSearchValue,\n activeValue: activeValue,\n onSearch: triggerSearch,\n onSearchSubmit: onSearchSubmit,\n onSelect: onInternalSelectionSelect,\n tokenWithEnter: tokenWithEnter\n }))), arrowNode, clearNode);\n }\n\n var RefSelect = React.forwardRef(Select);\n return RefSelect;\n}","import _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport * as React from 'react';\n/**\n * Similar with `useLock`, but this hook will always execute last value.\n * When set to `true`, it will keep `true` for a short time even if `false` is set.\n */\n\nexport default function useDelayReset() {\n var timeout = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 10;\n\n var _React$useState = React.useState(false),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n bool = _React$useState2[0],\n setBool = _React$useState2[1];\n\n var delayRef = React.useRef(null);\n\n var cancelLatest = function cancelLatest() {\n window.clearTimeout(delayRef.current);\n };\n\n React.useEffect(function () {\n return cancelLatest;\n }, []);\n\n var delaySetBool = function delaySetBool(value, callback) {\n cancelLatest();\n delayRef.current = window.setTimeout(function () {\n setBool(value);\n\n if (callback) {\n callback();\n }\n }, timeout);\n };\n\n return [bool, delaySetBool, cancelLatest];\n}","import * as React from 'react';\nexport default function useCacheOptions(values, options) {\n var prevOptionMapRef = React.useRef(null);\n var optionMap = React.useMemo(function () {\n var map = new Map();\n options.forEach(function (item) {\n var value = item.data.value;\n map.set(value, item);\n });\n return map;\n }, [values, options]);\n prevOptionMapRef.current = optionMap;\n\n var getValueOption = function getValueOption(vals) {\n return vals.map(function (value) {\n return prevOptionMapRef.current.get(value);\n }).filter(Boolean);\n };\n\n return getValueOption;\n}","import _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport * as React from 'react';\nexport default function useCacheDisplayValue(values) {\n var prevValuesRef = React.useRef(values);\n var mergedValues = React.useMemo(function () {\n // Create value - label map\n var valueLabels = new Map();\n prevValuesRef.current.forEach(function (_ref) {\n var value = _ref.value,\n label = _ref.label;\n\n if (value !== label) {\n valueLabels.set(value, label);\n }\n });\n var resultValues = values.map(function (item) {\n var cacheLabel = valueLabels.get(item.value);\n\n if (item.value === item.label && cacheLabel) {\n return _objectSpread(_objectSpread({}, item), {}, {\n label: cacheLabel\n });\n }\n\n return item;\n });\n prevValuesRef.current = resultValues;\n return resultValues;\n }, [values]);\n return mergedValues;\n}","import * as React from 'react';\nexport default function useSelectTriggerControl(elements, open, triggerOpen) {\n var propsRef = React.useRef(null);\n propsRef.current = {\n elements: elements.filter(function (e) {\n return e;\n }),\n open: open,\n triggerOpen: triggerOpen\n };\n React.useEffect(function () {\n function onGlobalMouseDown(event) {\n var target = event.target;\n\n if (propsRef.current.open && propsRef.current.elements.every(function (element) {\n return !element.contains(target) && element !== target;\n })) {\n // Should trigger close\n propsRef.current.triggerOpen(false);\n }\n }\n\n window.addEventListener('mousedown', onGlobalMouseDown);\n return function () {\n return window.removeEventListener('mousedown', onGlobalMouseDown);\n };\n }, []);\n}","export default function _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}","export default function _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n\n try {\n Date.prototype.toString.call(Reflect.construct(Date, [], function () {}));\n return true;\n } catch (e) {\n return false;\n }\n}","export default function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}","import _typeof from \"../../helpers/esm/typeof\";\nimport assertThisInitialized from \"./assertThisInitialized\";\nexport default function _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n }\n\n return assertThisInitialized(self);\n}","export default function _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n}","import getPrototypeOf from \"./getPrototypeOf\";\nimport isNativeReflectConstruct from \"./isNativeReflectConstruct\";\nimport possibleConstructorReturn from \"./possibleConstructorReturn\";\nexport default function _createSuper(Derived) {\n return function () {\n var Super = getPrototypeOf(Derived),\n result;\n\n if (isNativeReflectConstruct()) {\n var NewTarget = getPrototypeOf(this).constructor;\n result = Reflect.construct(Super, arguments, NewTarget);\n } else {\n result = Super.apply(this, arguments);\n }\n\n return possibleConstructorReturn(this, result);\n };\n}","var autoAdjustOverflow = {\n adjustX: 1,\n adjustY: 1\n};\nvar targetOffset = [0, 0];\nexport var placements = {\n left: {\n points: ['cr', 'cl'],\n overflow: autoAdjustOverflow,\n offset: [-4, 0],\n targetOffset: targetOffset\n },\n right: {\n points: ['cl', 'cr'],\n overflow: autoAdjustOverflow,\n offset: [4, 0],\n targetOffset: targetOffset\n },\n top: {\n points: ['bc', 'tc'],\n overflow: autoAdjustOverflow,\n offset: [0, -4],\n targetOffset: targetOffset\n },\n bottom: {\n points: ['tc', 'bc'],\n overflow: autoAdjustOverflow,\n offset: [0, 4],\n targetOffset: targetOffset\n },\n topLeft: {\n points: ['bl', 'tl'],\n overflow: autoAdjustOverflow,\n offset: [0, -4],\n targetOffset: targetOffset\n },\n leftTop: {\n points: ['tr', 'tl'],\n overflow: autoAdjustOverflow,\n offset: [-4, 0],\n targetOffset: targetOffset\n },\n topRight: {\n points: ['br', 'tr'],\n overflow: autoAdjustOverflow,\n offset: [0, -4],\n targetOffset: targetOffset\n },\n rightTop: {\n points: ['tl', 'tr'],\n overflow: autoAdjustOverflow,\n offset: [4, 0],\n targetOffset: targetOffset\n },\n bottomRight: {\n points: ['tr', 'br'],\n overflow: autoAdjustOverflow,\n offset: [0, 4],\n targetOffset: targetOffset\n },\n rightBottom: {\n points: ['bl', 'br'],\n overflow: autoAdjustOverflow,\n offset: [4, 0],\n targetOffset: targetOffset\n },\n bottomLeft: {\n points: ['tl', 'bl'],\n overflow: autoAdjustOverflow,\n offset: [0, 4],\n targetOffset: targetOffset\n },\n leftBottom: {\n points: ['br', 'bl'],\n overflow: autoAdjustOverflow,\n offset: [-4, 0],\n targetOffset: targetOffset\n }\n};\nexport default placements;","import React from 'react';\n\nvar Content = function Content(props) {\n var overlay = props.overlay,\n prefixCls = props.prefixCls,\n id = props.id,\n overlayInnerStyle = props.overlayInnerStyle;\n return React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-inner\"),\n id: id,\n role: \"tooltip\",\n style: overlayInnerStyle\n }, typeof overlay === 'function' ? overlay() : overlay);\n};\n\nexport default Content;","function _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport React, { useRef, useImperativeHandle, forwardRef } from 'react';\nimport Trigger from 'rc-trigger';\nimport { placements } from './placements';\nimport Content from './Content';\n\nvar Tooltip = function Tooltip(props, ref) {\n var overlayClassName = props.overlayClassName,\n _props$trigger = props.trigger,\n trigger = _props$trigger === void 0 ? ['hover'] : _props$trigger,\n _props$mouseEnterDela = props.mouseEnterDelay,\n mouseEnterDelay = _props$mouseEnterDela === void 0 ? 0 : _props$mouseEnterDela,\n _props$mouseLeaveDela = props.mouseLeaveDelay,\n mouseLeaveDelay = _props$mouseLeaveDela === void 0 ? 0.1 : _props$mouseLeaveDela,\n overlayStyle = props.overlayStyle,\n _props$prefixCls = props.prefixCls,\n prefixCls = _props$prefixCls === void 0 ? 'rc-tooltip' : _props$prefixCls,\n children = props.children,\n onVisibleChange = props.onVisibleChange,\n afterVisibleChange = props.afterVisibleChange,\n transitionName = props.transitionName,\n animation = props.animation,\n _props$placement = props.placement,\n placement = _props$placement === void 0 ? 'right' : _props$placement,\n _props$align = props.align,\n align = _props$align === void 0 ? {} : _props$align,\n _props$destroyTooltip = props.destroyTooltipOnHide,\n destroyTooltipOnHide = _props$destroyTooltip === void 0 ? false : _props$destroyTooltip,\n defaultVisible = props.defaultVisible,\n getTooltipContainer = props.getTooltipContainer,\n overlayInnerStyle = props.overlayInnerStyle,\n restProps = _objectWithoutProperties(props, [\"overlayClassName\", \"trigger\", \"mouseEnterDelay\", \"mouseLeaveDelay\", \"overlayStyle\", \"prefixCls\", \"children\", \"onVisibleChange\", \"afterVisibleChange\", \"transitionName\", \"animation\", \"placement\", \"align\", \"destroyTooltipOnHide\", \"defaultVisible\", \"getTooltipContainer\", \"overlayInnerStyle\"]);\n\n var domRef = useRef(null);\n useImperativeHandle(ref, function () {\n return domRef.current;\n });\n\n var extraProps = _objectSpread({}, restProps);\n\n if ('visible' in props) {\n extraProps.popupVisible = props.visible;\n }\n\n var getPopupElement = function getPopupElement() {\n var _props$arrowContent = props.arrowContent,\n arrowContent = _props$arrowContent === void 0 ? null : _props$arrowContent,\n overlay = props.overlay,\n id = props.id;\n return [React.createElement(\"div\", {\n className: \"\".concat(prefixCls, \"-arrow\"),\n key: \"arrow\"\n }, arrowContent), React.createElement(Content, {\n key: \"content\",\n prefixCls: prefixCls,\n id: id,\n overlay: overlay,\n overlayInnerStyle: overlayInnerStyle\n })];\n };\n\n var destroyTooltip = false;\n var autoDestroy = false;\n\n if (typeof destroyTooltipOnHide === 'boolean') {\n destroyTooltip = destroyTooltipOnHide;\n } else if (destroyTooltipOnHide && _typeof(destroyTooltipOnHide) === 'object') {\n var keepParent = destroyTooltipOnHide.keepParent;\n destroyTooltip = keepParent === true;\n autoDestroy = keepParent === false;\n }\n\n return React.createElement(Trigger, Object.assign({\n popupClassName: overlayClassName,\n prefixCls: prefixCls,\n popup: getPopupElement,\n action: trigger,\n builtinPlacements: placements,\n popupPlacement: placement,\n ref: domRef,\n popupAlign: align,\n getPopupContainer: getTooltipContainer,\n onPopupVisibleChange: onVisibleChange,\n afterPopupVisibleChange: afterVisibleChange,\n popupTransitionName: transitionName,\n popupAnimation: animation,\n defaultPopupVisible: defaultVisible,\n destroyPopupOnHide: destroyTooltip,\n autoDestroy: autoDestroy,\n mouseLeaveDelay: mouseLeaveDelay,\n popupStyle: overlayStyle,\n mouseEnterDelay: mouseEnterDelay\n }, extraProps), children);\n};\n\nexport default forwardRef(Tooltip);","import Tooltip from './Tooltip';\nexport default Tooltip;","import _extends from \"@babel/runtime/helpers/extends\";\nimport { placements } from \"rc-tooltip/es/placements\";\nvar autoAdjustOverflowEnabled = {\n adjustX: 1,\n adjustY: 1\n};\nvar autoAdjustOverflowDisabled = {\n adjustX: 0,\n adjustY: 0\n};\nvar targetOffset = [0, 0];\nexport function getOverflowOptions(autoAdjustOverflow) {\n if (typeof autoAdjustOverflow === 'boolean') {\n return autoAdjustOverflow ? autoAdjustOverflowEnabled : autoAdjustOverflowDisabled;\n }\n\n return _extends(_extends({}, autoAdjustOverflowDisabled), autoAdjustOverflow);\n}\nexport default function getPlacements(config) {\n var _config$arrowWidth = config.arrowWidth,\n arrowWidth = _config$arrowWidth === void 0 ? 5 : _config$arrowWidth,\n _config$horizontalArr = config.horizontalArrowShift,\n horizontalArrowShift = _config$horizontalArr === void 0 ? 16 : _config$horizontalArr,\n _config$verticalArrow = config.verticalArrowShift,\n verticalArrowShift = _config$verticalArrow === void 0 ? 8 : _config$verticalArrow,\n autoAdjustOverflow = config.autoAdjustOverflow;\n var placementMap = {\n left: {\n points: ['cr', 'cl'],\n offset: [-4, 0]\n },\n right: {\n points: ['cl', 'cr'],\n offset: [4, 0]\n },\n top: {\n points: ['bc', 'tc'],\n offset: [0, -4]\n },\n bottom: {\n points: ['tc', 'bc'],\n offset: [0, 4]\n },\n topLeft: {\n points: ['bl', 'tc'],\n offset: [-(horizontalArrowShift + arrowWidth), -4]\n },\n leftTop: {\n points: ['tr', 'cl'],\n offset: [-4, -(verticalArrowShift + arrowWidth)]\n },\n topRight: {\n points: ['br', 'tc'],\n offset: [horizontalArrowShift + arrowWidth, -4]\n },\n rightTop: {\n points: ['tl', 'cr'],\n offset: [4, -(verticalArrowShift + arrowWidth)]\n },\n bottomRight: {\n points: ['tr', 'bc'],\n offset: [horizontalArrowShift + arrowWidth, 4]\n },\n rightBottom: {\n points: ['bl', 'cr'],\n offset: [4, verticalArrowShift + arrowWidth]\n },\n bottomLeft: {\n points: ['tl', 'bc'],\n offset: [-(horizontalArrowShift + arrowWidth), 4]\n },\n leftBottom: {\n points: ['br', 'cl'],\n offset: [-4, verticalArrowShift + arrowWidth]\n }\n };\n Object.keys(placementMap).forEach(function (key) {\n placementMap[key] = config.arrowPointAtCenter ? _extends(_extends({}, placementMap[key]), {\n overflow: getOverflowOptions(autoAdjustOverflow),\n targetOffset: targetOffset\n }) : _extends(_extends({}, placements[key]), {\n overflow: getOverflowOptions(autoAdjustOverflow)\n });\n placementMap[key].ignoreShake = true;\n });\n return placementMap;\n}","import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport _extends from \"@babel/runtime/helpers/extends\";\nimport * as React from 'react';\nimport RcTooltip from 'rc-tooltip';\nimport classNames from 'classnames';\nimport getPlacements from './placements';\nimport { cloneElement, isValidElement } from '../_util/reactNode';\nimport { ConfigContext } from '../config-provider';\nimport { PresetColorTypes } from '../_util/colors';\n\nvar splitObject = function splitObject(obj, keys) {\n var picked = {};\n\n var omitted = _extends({}, obj);\n\n keys.forEach(function (key) {\n if (obj && key in obj) {\n picked[key] = obj[key];\n delete omitted[key];\n }\n });\n return {\n picked: picked,\n omitted: omitted\n };\n};\n\nvar PresetColorRegex = new RegExp(\"^(\".concat(PresetColorTypes.join('|'), \")(-inverse)?$\")); // Fix Tooltip won't hide at disabled button\n// mouse events don't trigger at disabled button in Chrome\n// https://github.com/react-component/tooltip/issues/18\n\nfunction getDisabledCompatibleChildren(element, prefixCls) {\n var elementType = element.type;\n\n if ((elementType.__ANT_BUTTON === true || elementType.__ANT_SWITCH === true || elementType.__ANT_CHECKBOX === true || element.type === 'button') && element.props.disabled) {\n // Pick some layout related style properties up to span\n // Prevent layout bugs like https://github.com/ant-design/ant-design/issues/5254\n var _splitObject = splitObject(element.props.style, ['position', 'left', 'right', 'top', 'bottom', 'float', 'display', 'zIndex']),\n picked = _splitObject.picked,\n omitted = _splitObject.omitted;\n\n var spanStyle = _extends(_extends({\n display: 'inline-block'\n }, picked), {\n cursor: 'not-allowed',\n width: element.props.block ? '100%' : null\n });\n\n var buttonStyle = _extends(_extends({}, omitted), {\n pointerEvents: 'none'\n });\n\n var child = cloneElement(element, {\n style: buttonStyle,\n className: null\n });\n return /*#__PURE__*/React.createElement(\"span\", {\n style: spanStyle,\n className: classNames(element.props.className, \"\".concat(prefixCls, \"-disabled-compatible-wrapper\"))\n }, child);\n }\n\n return element;\n}\n\nvar Tooltip = /*#__PURE__*/React.forwardRef(function (props, ref) {\n var _classNames2;\n\n var _React$useContext = React.useContext(ConfigContext),\n getContextPopupContainer = _React$useContext.getPopupContainer,\n getPrefixCls = _React$useContext.getPrefixCls,\n direction = _React$useContext.direction;\n\n var _React$useState = React.useState(!!props.visible || !!props.defaultVisible),\n _React$useState2 = _slicedToArray(_React$useState, 2),\n visible = _React$useState2[0],\n setVisible = _React$useState2[1];\n\n React.useEffect(function () {\n if ('visible' in props) {\n setVisible(props.visible);\n }\n }, [props.visible]);\n\n var isNoTitle = function isNoTitle() {\n var title = props.title,\n overlay = props.overlay;\n return !title && !overlay && title !== 0; // overlay for old version compatibility\n };\n\n var onVisibleChange = function onVisibleChange(vis) {\n if (!('visible' in props)) {\n setVisible(isNoTitle() ? false : vis);\n }\n\n if (props.onVisibleChange && !isNoTitle()) {\n props.onVisibleChange(vis);\n }\n };\n\n var getTooltipPlacements = function getTooltipPlacements() {\n var builtinPlacements = props.builtinPlacements,\n arrowPointAtCenter = props.arrowPointAtCenter,\n autoAdjustOverflow = props.autoAdjustOverflow;\n return builtinPlacements || getPlacements({\n arrowPointAtCenter: arrowPointAtCenter,\n autoAdjustOverflow: autoAdjustOverflow\n });\n }; // 动态设置动画点\n\n\n var onPopupAlign = function onPopupAlign(domNode, align) {\n var placements = getTooltipPlacements(); // 当前返回的位置\n\n var placement = Object.keys(placements).filter(function (key) {\n return placements[key].points[0] === align.points[0] && placements[key].points[1] === align.points[1];\n })[0];\n\n if (!placement) {\n return;\n } // 根据当前坐标设置动画点\n\n\n var rect = domNode.getBoundingClientRect();\n var transformOrigin = {\n top: '50%',\n left: '50%'\n };\n\n if (placement.indexOf('top') >= 0 || placement.indexOf('Bottom') >= 0) {\n transformOrigin.top = \"\".concat(rect.height - align.offset[1], \"px\");\n } else if (placement.indexOf('Top') >= 0 || placement.indexOf('bottom') >= 0) {\n transformOrigin.top = \"\".concat(-align.offset[1], \"px\");\n }\n\n if (placement.indexOf('left') >= 0 || placement.indexOf('Right') >= 0) {\n transformOrigin.left = \"\".concat(rect.width - align.offset[0], \"px\");\n } else if (placement.indexOf('right') >= 0 || placement.indexOf('Left') >= 0) {\n transformOrigin.left = \"\".concat(-align.offset[0], \"px\");\n }\n\n domNode.style.transformOrigin = \"\".concat(transformOrigin.left, \" \").concat(transformOrigin.top);\n };\n\n var getOverlay = function getOverlay() {\n var title = props.title,\n overlay = props.overlay;\n\n if (title === 0) {\n return title;\n }\n\n return overlay || title || '';\n };\n\n var customizePrefixCls = props.prefixCls,\n openClassName = props.openClassName,\n getPopupContainer = props.getPopupContainer,\n getTooltipContainer = props.getTooltipContainer,\n overlayClassName = props.overlayClassName,\n color = props.color,\n overlayInnerStyle = props.overlayInnerStyle;\n var children = props.children;\n var prefixCls = getPrefixCls('tooltip', customizePrefixCls);\n var tempVisible = visible; // Hide tooltip when there is no title\n\n if (!('visible' in props) && isNoTitle()) {\n tempVisible = false;\n }\n\n var child = getDisabledCompatibleChildren(isValidElement(children) ? children : /*#__PURE__*/React.createElement(\"span\", null, children), prefixCls);\n var childProps = child.props;\n var childCls = classNames(childProps.className, _defineProperty({}, openClassName || \"\".concat(prefixCls, \"-open\"), true));\n var customOverlayClassName = classNames(overlayClassName, (_classNames2 = {}, _defineProperty(_classNames2, \"\".concat(prefixCls, \"-rtl\"), direction === 'rtl'), _defineProperty(_classNames2, \"\".concat(prefixCls, \"-\").concat(color), color && PresetColorRegex.test(color)), _classNames2));\n var formattedOverlayInnerStyle;\n var arrowContentStyle;\n\n if (color && !PresetColorRegex.test(color)) {\n formattedOverlayInnerStyle = _extends(_extends({}, overlayInnerStyle), {\n background: color\n });\n arrowContentStyle = {\n background: color\n };\n }\n\n return /*#__PURE__*/React.createElement(RcTooltip, _extends({}, props, {\n prefixCls: prefixCls,\n overlayClassName: customOverlayClassName,\n getTooltipContainer: getPopupContainer || getTooltipContainer || getContextPopupContainer,\n ref: ref,\n builtinPlacements: getTooltipPlacements(),\n overlay: getOverlay(),\n visible: tempVisible,\n onVisibleChange: onVisibleChange,\n onPopupAlign: onPopupAlign,\n overlayInnerStyle: formattedOverlayInnerStyle,\n arrowContent: /*#__PURE__*/React.createElement(\"span\", {\n className: \"\".concat(prefixCls, \"-arrow-content\"),\n style: arrowContentStyle\n })\n }), tempVisible ? cloneElement(child, {\n className: childCls\n }) : child);\n});\nTooltip.displayName = 'Tooltip';\nTooltip.defaultProps = {\n placement: 'top',\n transitionName: 'zoom-big-fast',\n mouseEnterDelay: 0.1,\n mouseLeaveDelay: 0.1,\n arrowPointAtCenter: false,\n autoAdjustOverflow: true\n};\nexport default Tooltip;","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf\";\nexport default function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n if (superClass) setPrototypeOf(subClass, superClass);\n}","import raf from 'raf';\nvar id = 0;\nvar ids = {}; // Support call raf with delay specified frame\n\nexport default function wrapperRaf(callback) {\n var delayFrames = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;\n var myId = id++;\n var restFrames = delayFrames;\n\n function internalCallback() {\n restFrames -= 1;\n\n if (restFrames <= 0) {\n callback();\n delete ids[myId];\n } else {\n ids[myId] = raf(internalCallback);\n }\n }\n\n ids[myId] = raf(internalCallback);\n return myId;\n}\n\nwrapperRaf.cancel = function cancel(pid) {\n if (pid === undefined) return;\n raf.cancel(ids[pid]);\n delete ids[pid];\n};\n\nwrapperRaf.ids = ids; // export this for test usage","import _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\nimport _assertThisInitialized from \"@babel/runtime/helpers/assertThisInitialized\";\nimport _inherits from \"@babel/runtime/helpers/inherits\";\nimport _createSuper from \"@babel/runtime/helpers/createSuper\";\nimport * as React from 'react';\nimport { findDOMNode } from 'react-dom';\nimport TransitionEvents from \"@ant-design/css-animation/es/Event\";\nimport raf from './raf';\nimport { ConfigConsumer, ConfigContext } from '../config-provider';\nvar styleForPesudo; // Where el is the DOM element you'd like to test for visibility\n\nfunction isHidden(element) {\n if (process.env.NODE_ENV === 'test') {\n return false;\n }\n\n return !element || element.offsetParent === null;\n}\n\nfunction isNotGrey(color) {\n // eslint-disable-next-line no-useless-escape\n var match = (color || '').match(/rgba?\\((\\d*), (\\d*), (\\d*)(, [\\d.]*)?\\)/);\n\n if (match && match[1] && match[2] && match[3]) {\n return !(match[1] === match[2] && match[2] === match[3]);\n }\n\n return true;\n}\n\nvar Wave = /*#__PURE__*/function (_React$Component) {\n _inherits(Wave, _React$Component);\n\n var _super = _createSuper(Wave);\n\n function Wave() {\n var _this;\n\n _classCallCheck(this, Wave);\n\n _this = _super.apply(this, arguments);\n _this.animationStart = false;\n _this.destroyed = false;\n\n _this.onClick = function (node, waveColor) {\n if (!node || isHidden(node) || node.className.indexOf('-leave') >= 0) {\n return;\n }\n\n var insertExtraNode = _this.props.insertExtraNode;\n _this.extraNode = document.createElement('div');\n\n var _assertThisInitialize = _assertThisInitialized(_this),\n extraNode = _assertThisInitialize.extraNode;\n\n var getPrefixCls = _this.context.getPrefixCls;\n extraNode.className = \"\".concat(getPrefixCls(''), \"-click-animating-node\");\n\n var attributeName = _this.getAttributeName();\n\n node.setAttribute(attributeName, 'true'); // Not white or transparnt or grey\n\n styleForPesudo = styleForPesudo || document.createElement('style');\n\n if (waveColor && waveColor !== '#ffffff' && waveColor !== 'rgb(255, 255, 255)' && isNotGrey(waveColor) && !/rgba\\((?:\\d*, ){3}0\\)/.test(waveColor) && // any transparent rgba color\n waveColor !== 'transparent') {\n // Add nonce if CSP exist\n if (_this.csp && _this.csp.nonce) {\n styleForPesudo.nonce = _this.csp.nonce;\n }\n\n extraNode.style.borderColor = waveColor;\n styleForPesudo.innerHTML = \"\\n [\".concat(getPrefixCls(''), \"-click-animating-without-extra-node='true']::after, .\").concat(getPrefixCls(''), \"-click-animating-node {\\n --antd-wave-shadow-color: \").concat(waveColor, \";\\n }\");\n\n if (!document.body.contains(styleForPesudo)) {\n document.body.appendChild(styleForPesudo);\n }\n }\n\n if (insertExtraNode) {\n node.appendChild(extraNode);\n }\n\n TransitionEvents.addStartEventListener(node, _this.onTransitionStart);\n TransitionEvents.addEndEventListener(node, _this.onTransitionEnd);\n };\n\n _this.onTransitionStart = function (e) {\n if (_this.destroyed) {\n return;\n }\n\n var node = findDOMNode(_assertThisInitialized(_this));\n\n if (!e || e.target !== node || _this.animationStart) {\n return;\n }\n\n _this.resetEffect(node);\n };\n\n _this.onTransitionEnd = function (e) {\n if (!e || e.animationName !== 'fadeEffect') {\n return;\n }\n\n _this.resetEffect(e.target);\n };\n\n _this.bindAnimationEvent = function (node) {\n if (!node || !node.getAttribute || node.getAttribute('disabled') || node.className.indexOf('disabled') >= 0) {\n return;\n }\n\n var onClick = function onClick(e) {\n // Fix radio button click twice\n if (e.target.tagName === 'INPUT' || isHidden(e.target)) {\n return;\n }\n\n _this.resetEffect(node); // Get wave color from target\n\n\n var waveColor = getComputedStyle(node).getPropertyValue('border-top-color') || // Firefox Compatible\n getComputedStyle(node).getPropertyValue('border-color') || getComputedStyle(node).getPropertyValue('background-color');\n _this.clickWaveTimeoutId = window.setTimeout(function () {\n return _this.onClick(node, waveColor);\n }, 0);\n raf.cancel(_this.animationStartId);\n _this.animationStart = true; // Render to trigger transition event cost 3 frames. Let's delay 10 frames to reset this.\n\n _this.animationStartId = raf(function () {\n _this.animationStart = false;\n }, 10);\n };\n\n node.addEventListener('click', onClick, true);\n return {\n cancel: function cancel() {\n node.removeEventListener('click', onClick, true);\n }\n };\n };\n\n _this.renderWave = function (_ref) {\n var csp = _ref.csp;\n var children = _this.props.children;\n _this.csp = csp;\n return children;\n };\n\n return _this;\n }\n\n _createClass(Wave, [{\n key: \"componentDidMount\",\n value: function componentDidMount() {\n var node = findDOMNode(this);\n\n if (!node || node.nodeType !== 1) {\n return;\n }\n\n this.instance = this.bindAnimationEvent(node);\n }\n }, {\n key: \"componentWillUnmount\",\n value: function componentWillUnmount() {\n if (this.instance) {\n this.instance.cancel();\n }\n\n if (this.clickWaveTimeoutId) {\n clearTimeout(this.clickWaveTimeoutId);\n }\n\n this.destroyed = true;\n }\n }, {\n key: \"getAttributeName\",\n value: function getAttributeName() {\n var getPrefixCls = this.context.getPrefixCls;\n var insertExtraNode = this.props.insertExtraNode;\n return insertExtraNode ? \"\".concat(getPrefixCls(''), \"-click-animating\") : \"\".concat(getPrefixCls(''), \"-click-animating-without-extra-node\");\n }\n }, {\n key: \"resetEffect\",\n value: function resetEffect(node) {\n if (!node || node === this.extraNode || !(node instanceof Element)) {\n return;\n }\n\n var insertExtraNode = this.props.insertExtraNode;\n var attributeName = this.getAttributeName();\n node.setAttribute(attributeName, 'false'); // edge has bug on `removeAttribute` #14466\n\n if (styleForPesudo) {\n styleForPesudo.innerHTML = '';\n }\n\n if (insertExtraNode && this.extraNode && node.contains(this.extraNode)) {\n node.removeChild(this.extraNode);\n }\n\n TransitionEvents.removeStartEventListener(node, this.onTransitionStart);\n TransitionEvents.removeEndEventListener(node, this.onTransitionEnd);\n }\n }, {\n key: \"render\",\n value: function render() {\n return /*#__PURE__*/React.createElement(ConfigConsumer, null, this.renderWave);\n }\n }]);\n\n return Wave;\n}(React.Component);\n\nexport { Wave as default };\nWave.contextType = ConfigContext;","import '../../style/index.less';\nimport './index.less'; // style dependencies\n\nimport '../../button/style';","// shim for using process in browser\nvar process = module.exports = {};\n\n// cached from whatever global is present so that test runners that stub it\n// don't break things. But we need to wrap it in a try catch in case it is\n// wrapped in strict mode code which doesn't define any globals. It's inside a\n// function because try/catches deoptimize in certain engines.\n\nvar cachedSetTimeout;\nvar cachedClearTimeout;\n\nfunction defaultSetTimout() {\n throw new Error('setTimeout has not been defined');\n}\nfunction defaultClearTimeout () {\n throw new Error('clearTimeout has not been defined');\n}\n(function () {\n try {\n if (typeof setTimeout === 'function') {\n cachedSetTimeout = setTimeout;\n } else {\n cachedSetTimeout = defaultSetTimout;\n }\n } catch (e) {\n cachedSetTimeout = defaultSetTimout;\n }\n try {\n if (typeof clearTimeout === 'function') {\n cachedClearTimeout = clearTimeout;\n } else {\n cachedClearTimeout = defaultClearTimeout;\n }\n } catch (e) {\n cachedClearTimeout = defaultClearTimeout;\n }\n} ())\nfunction runTimeout(fun) {\n if (cachedSetTimeout === setTimeout) {\n //normal enviroments in sane situations\n return setTimeout(fun, 0);\n }\n // if setTimeout wasn't available but was latter defined\n if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {\n cachedSetTimeout = setTimeout;\n return setTimeout(fun, 0);\n }\n try {\n // when when somebody has screwed with setTimeout but no I.E. maddness\n return cachedSetTimeout(fun, 0);\n } catch(e){\n try {\n // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n return cachedSetTimeout.call(null, fun, 0);\n } catch(e){\n // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error\n return cachedSetTimeout.call(this, fun, 0);\n }\n }\n\n\n}\nfunction runClearTimeout(marker) {\n if (cachedClearTimeout === clearTimeout) {\n //normal enviroments in sane situations\n return clearTimeout(marker);\n }\n // if clearTimeout wasn't available but was latter defined\n if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {\n cachedClearTimeout = clearTimeout;\n return clearTimeout(marker);\n }\n try {\n // when when somebody has screwed with setTimeout but no I.E. maddness\n return cachedClearTimeout(marker);\n } catch (e){\n try {\n // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n return cachedClearTimeout.call(null, marker);\n } catch (e){\n // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.\n // Some versions of I.E. have different rules for clearTimeout vs setTimeout\n return cachedClearTimeout.call(this, marker);\n }\n }\n\n\n\n}\nvar queue = [];\nvar draining = false;\nvar currentQueue;\nvar queueIndex = -1;\n\nfunction cleanUpNextTick() {\n if (!draining || !currentQueue) {\n return;\n }\n draining = false;\n if (currentQueue.length) {\n queue = currentQueue.concat(queue);\n } else {\n queueIndex = -1;\n }\n if (queue.length) {\n drainQueue();\n }\n}\n\nfunction drainQueue() {\n if (draining) {\n return;\n }\n var timeout = runTimeout(cleanUpNextTick);\n draining = true;\n\n var len = queue.length;\n while(len) {\n currentQueue = queue;\n queue = [];\n while (++queueIndex < len) {\n if (currentQueue) {\n currentQueue[queueIndex].run();\n }\n }\n queueIndex = -1;\n len = queue.length;\n }\n currentQueue = null;\n draining = false;\n runClearTimeout(timeout);\n}\n\nprocess.nextTick = function (fun) {\n var args = new Array(arguments.length - 1);\n if (arguments.length > 1) {\n for (var i = 1; i < arguments.length; i++) {\n args[i - 1] = arguments[i];\n }\n }\n queue.push(new Item(fun, args));\n if (queue.length === 1 && !draining) {\n runTimeout(drainQueue);\n }\n};\n\n// v8 likes predictible objects\nfunction Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}\nItem.prototype.run = function () {\n this.fun.apply(null, this.array);\n};\nprocess.title = 'browser';\nprocess.browser = true;\nprocess.env = {};\nprocess.argv = [];\nprocess.version = ''; // empty string to avoid regexp issues\nprocess.versions = {};\n\nfunction noop() {}\n\nprocess.on = noop;\nprocess.addListener = noop;\nprocess.once = noop;\nprocess.off = noop;\nprocess.removeListener = noop;\nprocess.removeAllListeners = noop;\nprocess.emit = noop;\nprocess.prependListener = noop;\nprocess.prependOnceListener = noop;\n\nprocess.listeners = function (name) { return [] }\n\nprocess.binding = function (name) {\n throw new Error('process.binding is not supported');\n};\n\nprocess.cwd = function () { return '/' };\nprocess.chdir = function (dir) {\n throw new Error('process.chdir is not supported');\n};\nprocess.umask = function() { return 0; };\n","var arrayLikeToArray = require(\"./arrayLikeToArray\");\n\nfunction _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);\n}\n\nmodule.exports = _unsupportedIterableToArray;","\"use strict\";\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.warning = warning;\nexports.isIconDefinition = isIconDefinition;\nexports.normalizeAttrs = normalizeAttrs;\nexports.generate = generate;\nexports.getSecondaryColor = getSecondaryColor;\nexports.normalizeTwoToneColors = normalizeTwoToneColors;\nexports.useInsertStyles = exports.iconStyles = exports.svgBaseProps = void 0;\n\nvar _objectSpread2 = _interopRequireDefault(require(\"@babel/runtime/helpers/objectSpread2\"));\n\nvar _typeof2 = _interopRequireDefault(require(\"@babel/runtime/helpers/typeof\"));\n\nvar _colors = require(\"@ant-design/colors\");\n\nvar _react = _interopRequireWildcard(require(\"react\"));\n\nvar _warning = _interopRequireDefault(require(\"rc-util/lib/warning\"));\n\nvar _insertCss = require(\"insert-css\");\n\nfunction warning(valid, message) {\n (0, _warning.default)(valid, \"[@ant-design/icons] \".concat(message));\n}\n\nfunction isIconDefinition(target) {\n return (0, _typeof2.default)(target) === 'object' && typeof target.name === 'string' && typeof target.theme === 'string' && ((0, _typeof2.default)(target.icon) === 'object' || typeof target.icon === 'function');\n}\n\nfunction normalizeAttrs() {\n var attrs = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n return Object.keys(attrs).reduce(function (acc, key) {\n var val = attrs[key];\n\n switch (key) {\n case 'class':\n acc.className = val;\n delete acc.class;\n break;\n\n default:\n acc[key] = val;\n }\n\n return acc;\n }, {});\n}\n\nfunction generate(node, key, rootProps) {\n if (!rootProps) {\n return _react.default.createElement(node.tag, (0, _objectSpread2.default)({\n key: key\n }, normalizeAttrs(node.attrs)), (node.children || []).map(function (child, index) {\n return generate(child, \"\".concat(key, \"-\").concat(node.tag, \"-\").concat(index));\n }));\n }\n\n return _react.default.createElement(node.tag, (0, _objectSpread2.default)((0, _objectSpread2.default)({\n key: key\n }, normalizeAttrs(node.attrs)), rootProps), (node.children || []).map(function (child, index) {\n return generate(child, \"\".concat(key, \"-\").concat(node.tag, \"-\").concat(index));\n }));\n}\n\nfunction getSecondaryColor(primaryColor) {\n // choose the second color\n return (0, _colors.generate)(primaryColor)[0];\n}\n\nfunction normalizeTwoToneColors(twoToneColor) {\n if (!twoToneColor) {\n return [];\n }\n\n return Array.isArray(twoToneColor) ? twoToneColor : [twoToneColor];\n} // These props make sure that the SVG behaviours like general text.\n// Reference: https://blog.prototypr.io/align-svg-icons-to-text-and-say-goodbye-to-font-icons-d44b3d7b26b4\n\n\nvar svgBaseProps = {\n width: '1em',\n height: '1em',\n fill: 'currentColor',\n 'aria-hidden': 'true',\n focusable: 'false'\n};\nexports.svgBaseProps = svgBaseProps;\nvar iconStyles = \"\\n.anticon {\\n display: inline-block;\\n color: inherit;\\n font-style: normal;\\n line-height: 0;\\n text-align: center;\\n text-transform: none;\\n vertical-align: -0.125em;\\n text-rendering: optimizeLegibility;\\n -webkit-font-smoothing: antialiased;\\n -moz-osx-font-smoothing: grayscale;\\n}\\n\\n.anticon > * {\\n line-height: 1;\\n}\\n\\n.anticon svg {\\n display: inline-block;\\n}\\n\\n.anticon::before {\\n display: none;\\n}\\n\\n.anticon .anticon-icon {\\n display: block;\\n}\\n\\n.anticon[tabindex] {\\n cursor: pointer;\\n}\\n\\n.anticon-spin::before,\\n.anticon-spin {\\n display: inline-block;\\n -webkit-animation: loadingCircle 1s infinite linear;\\n animation: loadingCircle 1s infinite linear;\\n}\\n\\n@-webkit-keyframes loadingCircle {\\n 100% {\\n -webkit-transform: rotate(360deg);\\n transform: rotate(360deg);\\n }\\n}\\n\\n@keyframes loadingCircle {\\n 100% {\\n -webkit-transform: rotate(360deg);\\n transform: rotate(360deg);\\n }\\n}\\n\";\nexports.iconStyles = iconStyles;\nvar cssInjectedFlag = false;\n\nvar useInsertStyles = function useInsertStyles() {\n var styleStr = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : iconStyles;\n (0, _react.useEffect)(function () {\n if (!cssInjectedFlag) {\n (0, _insertCss.insertCss)(styleStr, {\n prepend: true\n });\n cssInjectedFlag = true;\n }\n }, []);\n};\n\nexports.useInsertStyles = useInsertStyles;","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nmodule.exports = Map;\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nmodule.exports = Symbol;\n","/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nmodule.exports = isArray;\n","import '../../style/index.less';\nimport './index.less';","\"use strict\";\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar generate_1 = __importDefault(require(\"./generate\"));\nexports.generate = generate_1.default;\nvar presetPrimaryColors = {\n red: '#F5222D',\n volcano: '#FA541C',\n orange: '#FA8C16',\n gold: '#FAAD14',\n yellow: '#FADB14',\n lime: '#A0D911',\n green: '#52C41A',\n cyan: '#13C2C2',\n blue: '#1890FF',\n geekblue: '#2F54EB',\n purple: '#722ED1',\n magenta: '#EB2F96',\n grey: '#666666',\n};\nexports.presetPrimaryColors = presetPrimaryColors;\nvar presetPalettes = {};\nexports.presetPalettes = presetPalettes;\nObject.keys(presetPrimaryColors).forEach(function (key) {\n presetPalettes[key] = generate_1.default(presetPrimaryColors[key]);\n presetPalettes[key].primary = presetPalettes[key][5];\n});\nvar red = presetPalettes.red;\nexports.red = red;\nvar volcano = presetPalettes.volcano;\nexports.volcano = volcano;\nvar gold = presetPalettes.gold;\nexports.gold = gold;\nvar orange = presetPalettes.orange;\nexports.orange = orange;\nvar yellow = presetPalettes.yellow;\nexports.yellow = yellow;\nvar lime = presetPalettes.lime;\nexports.lime = lime;\nvar green = presetPalettes.green;\nexports.green = green;\nvar cyan = presetPalettes.cyan;\nexports.cyan = cyan;\nvar blue = presetPalettes.blue;\nexports.blue = blue;\nvar geekblue = presetPalettes.geekblue;\nexports.geekblue = geekblue;\nvar purple = presetPalettes.purple;\nexports.purple = purple;\nvar magenta = presetPalettes.magenta;\nexports.magenta = magenta;\nvar grey = presetPalettes.grey;\nexports.grey = grey;\n","var containers = []; // will store container HTMLElement references\nvar styleElements = []; // will store {prepend: HTMLElement, append: HTMLElement}\n\nvar usage = 'insert-css: You need to provide a CSS string. Usage: insertCss(cssString[, options]).';\n\nfunction insertCss(css, options) {\n options = options || {};\n\n if (css === undefined) {\n throw new Error(usage);\n }\n\n var position = options.prepend === true ? 'prepend' : 'append';\n var container = options.container !== undefined ? options.container : document.querySelector('head');\n var containerId = containers.indexOf(container);\n\n // first time we see this container, create the necessary entries\n if (containerId === -1) {\n containerId = containers.push(container) - 1;\n styleElements[containerId] = {};\n }\n\n // try to get the correponding container + position styleElement, create it otherwise\n var styleElement;\n\n if (styleElements[containerId] !== undefined && styleElements[containerId][position] !== undefined) {\n styleElement = styleElements[containerId][position];\n } else {\n styleElement = styleElements[containerId][position] = createStyleElement();\n\n if (position === 'prepend') {\n container.insertBefore(styleElement, container.childNodes[0]);\n } else {\n container.appendChild(styleElement);\n }\n }\n\n // strip potential UTF-8 BOM if css was read from a file\n if (css.charCodeAt(0) === 0xFEFF) { css = css.substr(1, css.length); }\n\n // actually add the stylesheet\n if (styleElement.styleSheet) {\n styleElement.styleSheet.cssText += css\n } else {\n styleElement.textContent += css;\n }\n\n return styleElement;\n};\n\nfunction createStyleElement() {\n var styleElement = document.createElement('style');\n styleElement.setAttribute('type', 'text/css');\n return styleElement;\n}\n\nmodule.exports = insertCss;\nmodule.exports.insertCss = insertCss;\n","module.exports = require(\"regenerator-runtime\");\n","import React, { Component } from 'react';\nimport _inheritsLoose from '@babel/runtime/helpers/esm/inheritsLoose';\nimport PropTypes from 'prop-types';\nimport warning from 'tiny-warning';\n\nvar MAX_SIGNED_31_BIT_INT = 1073741823;\nvar commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : {};\n\nfunction getUniqueId() {\n var key = '__global_unique_id__';\n return commonjsGlobal[key] = (commonjsGlobal[key] || 0) + 1;\n}\n\nfunction objectIs(x, y) {\n if (x === y) {\n return x !== 0 || 1 / x === 1 / y;\n } else {\n return x !== x && y !== y;\n }\n}\n\nfunction createEventEmitter(value) {\n var handlers = [];\n return {\n on: function on(handler) {\n handlers.push(handler);\n },\n off: function off(handler) {\n handlers = handlers.filter(function (h) {\n return h !== handler;\n });\n },\n get: function get() {\n return value;\n },\n set: function set(newValue, changedBits) {\n value = newValue;\n handlers.forEach(function (handler) {\n return handler(value, changedBits);\n });\n }\n };\n}\n\nfunction onlyChild(children) {\n return Array.isArray(children) ? children[0] : children;\n}\n\nfunction createReactContext(defaultValue, calculateChangedBits) {\n var _Provider$childContex, _Consumer$contextType;\n\n var contextProp = '__create-react-context-' + getUniqueId() + '__';\n\n var Provider = /*#__PURE__*/function (_Component) {\n _inheritsLoose(Provider, _Component);\n\n function Provider() {\n var _this;\n\n _this = _Component.apply(this, arguments) || this;\n _this.emitter = createEventEmitter(_this.props.value);\n return _this;\n }\n\n var _proto = Provider.prototype;\n\n _proto.getChildContext = function getChildContext() {\n var _ref;\n\n return _ref = {}, _ref[contextProp] = this.emitter, _ref;\n };\n\n _proto.componentWillReceiveProps = function componentWillReceiveProps(nextProps) {\n if (this.props.value !== nextProps.value) {\n var oldValue = this.props.value;\n var newValue = nextProps.value;\n var changedBits;\n\n if (objectIs(oldValue, newValue)) {\n changedBits = 0;\n } else {\n changedBits = typeof calculateChangedBits === 'function' ? calculateChangedBits(oldValue, newValue) : MAX_SIGNED_31_BIT_INT;\n\n if (process.env.NODE_ENV !== 'production') {\n warning((changedBits & MAX_SIGNED_31_BIT_INT) === changedBits, 'calculateChangedBits: Expected the return value to be a ' + '31-bit integer. Instead received: ' + changedBits);\n }\n\n changedBits |= 0;\n\n if (changedBits !== 0) {\n this.emitter.set(nextProps.value, changedBits);\n }\n }\n }\n };\n\n _proto.render = function render() {\n return this.props.children;\n };\n\n return Provider;\n }(Component);\n\n Provider.childContextTypes = (_Provider$childContex = {}, _Provider$childContex[contextProp] = PropTypes.object.isRequired, _Provider$childContex);\n\n var Consumer = /*#__PURE__*/function (_Component2) {\n _inheritsLoose(Consumer, _Component2);\n\n function Consumer() {\n var _this2;\n\n _this2 = _Component2.apply(this, arguments) || this;\n _this2.state = {\n value: _this2.getValue()\n };\n\n _this2.onUpdate = function (newValue, changedBits) {\n var observedBits = _this2.observedBits | 0;\n\n if ((observedBits & changedBits) !== 0) {\n _this2.setState({\n value: _this2.getValue()\n });\n }\n };\n\n return _this2;\n }\n\n var _proto2 = Consumer.prototype;\n\n _proto2.componentWillReceiveProps = function componentWillReceiveProps(nextProps) {\n var observedBits = nextProps.observedBits;\n this.observedBits = observedBits === undefined || observedBits === null ? MAX_SIGNED_31_BIT_INT : observedBits;\n };\n\n _proto2.componentDidMount = function componentDidMount() {\n if (this.context[contextProp]) {\n this.context[contextProp].on(this.onUpdate);\n }\n\n var observedBits = this.props.observedBits;\n this.observedBits = observedBits === undefined || observedBits === null ? MAX_SIGNED_31_BIT_INT : observedBits;\n };\n\n _proto2.componentWillUnmount = function componentWillUnmount() {\n if (this.context[contextProp]) {\n this.context[contextProp].off(this.onUpdate);\n }\n };\n\n _proto2.getValue = function getValue() {\n if (this.context[contextProp]) {\n return this.context[contextProp].get();\n } else {\n return defaultValue;\n }\n };\n\n _proto2.render = function render() {\n return onlyChild(this.props.children)(this.state.value);\n };\n\n return Consumer;\n }(Component);\n\n Consumer.contextTypes = (_Consumer$contextType = {}, _Consumer$contextType[contextProp] = PropTypes.object, _Consumer$contextType);\n return {\n Provider: Provider,\n Consumer: Consumer\n };\n}\n\nvar index = React.createContext || createReactContext;\n\nexport default index;\n","var isarray = require('isarray')\n\n/**\n * Expose `pathToRegexp`.\n */\nmodule.exports = pathToRegexp\nmodule.exports.parse = parse\nmodule.exports.compile = compile\nmodule.exports.tokensToFunction = tokensToFunction\nmodule.exports.tokensToRegExp = tokensToRegExp\n\n/**\n * The main path matching regexp utility.\n *\n * @type {RegExp}\n */\nvar PATH_REGEXP = new RegExp([\n // Match escaped characters that would otherwise appear in future matches.\n // This allows the user to escape special characters that won't transform.\n '(\\\\\\\\.)',\n // Match Express-style parameters and un-named parameters with a prefix\n // and optional suffixes. Matches appear as:\n //\n // \"/:test(\\\\d+)?\" => [\"/\", \"test\", \"\\d+\", undefined, \"?\", undefined]\n // \"/route(\\\\d+)\" => [undefined, undefined, undefined, \"\\d+\", undefined, undefined]\n // \"/*\" => [\"/\", undefined, undefined, undefined, undefined, \"*\"]\n '([\\\\/.])?(?:(?:\\\\:(\\\\w+)(?:\\\\(((?:\\\\\\\\.|[^\\\\\\\\()])+)\\\\))?|\\\\(((?:\\\\\\\\.|[^\\\\\\\\()])+)\\\\))([+*?])?|(\\\\*))'\n].join('|'), 'g')\n\n/**\n * Parse a string for the raw tokens.\n *\n * @param {string} str\n * @param {Object=} options\n * @return {!Array}\n */\nfunction parse (str, options) {\n var tokens = []\n var key = 0\n var index = 0\n var path = ''\n var defaultDelimiter = options && options.delimiter || '/'\n var res\n\n while ((res = PATH_REGEXP.exec(str)) != null) {\n var m = res[0]\n var escaped = res[1]\n var offset = res.index\n path += str.slice(index, offset)\n index = offset + m.length\n\n // Ignore already escaped sequences.\n if (escaped) {\n path += escaped[1]\n continue\n }\n\n var next = str[index]\n var prefix = res[2]\n var name = res[3]\n var capture = res[4]\n var group = res[5]\n var modifier = res[6]\n var asterisk = res[7]\n\n // Push the current path onto the tokens.\n if (path) {\n tokens.push(path)\n path = ''\n }\n\n var partial = prefix != null && next != null && next !== prefix\n var repeat = modifier === '+' || modifier === '*'\n var optional = modifier === '?' || modifier === '*'\n var delimiter = res[2] || defaultDelimiter\n var pattern = capture || group\n\n tokens.push({\n name: name || key++,\n prefix: prefix || '',\n delimiter: delimiter,\n optional: optional,\n repeat: repeat,\n partial: partial,\n asterisk: !!asterisk,\n pattern: pattern ? escapeGroup(pattern) : (asterisk ? '.*' : '[^' + escapeString(delimiter) + ']+?')\n })\n }\n\n // Match any characters still remaining.\n if (index < str.length) {\n path += str.substr(index)\n }\n\n // If the path exists, push it onto the end.\n if (path) {\n tokens.push(path)\n }\n\n return tokens\n}\n\n/**\n * Compile a string to a template function for the path.\n *\n * @param {string} str\n * @param {Object=} options\n * @return {!function(Object=, Object=)}\n */\nfunction compile (str, options) {\n return tokensToFunction(parse(str, options), options)\n}\n\n/**\n * Prettier encoding of URI path segments.\n *\n * @param {string}\n * @return {string}\n */\nfunction encodeURIComponentPretty (str) {\n return encodeURI(str).replace(/[\\/?#]/g, function (c) {\n return '%' + c.charCodeAt(0).toString(16).toUpperCase()\n })\n}\n\n/**\n * Encode the asterisk parameter. Similar to `pretty`, but allows slashes.\n *\n * @param {string}\n * @return {string}\n */\nfunction encodeAsterisk (str) {\n return encodeURI(str).replace(/[?#]/g, function (c) {\n return '%' + c.charCodeAt(0).toString(16).toUpperCase()\n })\n}\n\n/**\n * Expose a method for transforming tokens into the path function.\n */\nfunction tokensToFunction (tokens, options) {\n // Compile all the tokens into regexps.\n var matches = new Array(tokens.length)\n\n // Compile all the patterns before compilation.\n for (var i = 0; i < tokens.length; i++) {\n if (typeof tokens[i] === 'object') {\n matches[i] = new RegExp('^(?:' + tokens[i].pattern + ')$', flags(options))\n }\n }\n\n return function (obj, opts) {\n var path = ''\n var data = obj || {}\n var options = opts || {}\n var encode = options.pretty ? encodeURIComponentPretty : encodeURIComponent\n\n for (var i = 0; i < tokens.length; i++) {\n var token = tokens[i]\n\n if (typeof token === 'string') {\n path += token\n\n continue\n }\n\n var value = data[token.name]\n var segment\n\n if (value == null) {\n if (token.optional) {\n // Prepend partial segment prefixes.\n if (token.partial) {\n path += token.prefix\n }\n\n continue\n } else {\n throw new TypeError('Expected \"' + token.name + '\" to be defined')\n }\n }\n\n if (isarray(value)) {\n if (!token.repeat) {\n throw new TypeError('Expected \"' + token.name + '\" to not repeat, but received `' + JSON.stringify(value) + '`')\n }\n\n if (value.length === 0) {\n if (token.optional) {\n continue\n } else {\n throw new TypeError('Expected \"' + token.name + '\" to not be empty')\n }\n }\n\n for (var j = 0; j < value.length; j++) {\n segment = encode(value[j])\n\n if (!matches[i].test(segment)) {\n throw new TypeError('Expected all \"' + token.name + '\" to match \"' + token.pattern + '\", but received `' + JSON.stringify(segment) + '`')\n }\n\n path += (j === 0 ? token.prefix : token.delimiter) + segment\n }\n\n continue\n }\n\n segment = token.asterisk ? encodeAsterisk(value) : encode(value)\n\n if (!matches[i].test(segment)) {\n throw new TypeError('Expected \"' + token.name + '\" to match \"' + token.pattern + '\", but received \"' + segment + '\"')\n }\n\n path += token.prefix + segment\n }\n\n return path\n }\n}\n\n/**\n * Escape a regular expression string.\n *\n * @param {string} str\n * @return {string}\n */\nfunction escapeString (str) {\n return str.replace(/([.+*?=^!:${}()[\\]|\\/\\\\])/g, '\\\\$1')\n}\n\n/**\n * Escape the capturing group by escaping special characters and meaning.\n *\n * @param {string} group\n * @return {string}\n */\nfunction escapeGroup (group) {\n return group.replace(/([=!:$\\/()])/g, '\\\\$1')\n}\n\n/**\n * Attach the keys as a property of the regexp.\n *\n * @param {!RegExp} re\n * @param {Array} keys\n * @return {!RegExp}\n */\nfunction attachKeys (re, keys) {\n re.keys = keys\n return re\n}\n\n/**\n * Get the flags for a regexp from the options.\n *\n * @param {Object} options\n * @return {string}\n */\nfunction flags (options) {\n return options && options.sensitive ? '' : 'i'\n}\n\n/**\n * Pull out keys from a regexp.\n *\n * @param {!RegExp} path\n * @param {!Array} keys\n * @return {!RegExp}\n */\nfunction regexpToRegexp (path, keys) {\n // Use a negative lookahead to match only capturing groups.\n var groups = path.source.match(/\\((?!\\?)/g)\n\n if (groups) {\n for (var i = 0; i < groups.length; i++) {\n keys.push({\n name: i,\n prefix: null,\n delimiter: null,\n optional: false,\n repeat: false,\n partial: false,\n asterisk: false,\n pattern: null\n })\n }\n }\n\n return attachKeys(path, keys)\n}\n\n/**\n * Transform an array into a regexp.\n *\n * @param {!Array} path\n * @param {Array} keys\n * @param {!Object} options\n * @return {!RegExp}\n */\nfunction arrayToRegexp (path, keys, options) {\n var parts = []\n\n for (var i = 0; i < path.length; i++) {\n parts.push(pathToRegexp(path[i], keys, options).source)\n }\n\n var regexp = new RegExp('(?:' + parts.join('|') + ')', flags(options))\n\n return attachKeys(regexp, keys)\n}\n\n/**\n * Create a path regexp from string input.\n *\n * @param {string} path\n * @param {!Array} keys\n * @param {!Object} options\n * @return {!RegExp}\n */\nfunction stringToRegexp (path, keys, options) {\n return tokensToRegExp(parse(path, options), keys, options)\n}\n\n/**\n * Expose a function for taking tokens and returning a RegExp.\n *\n * @param {!Array} tokens\n * @param {(Array|Object)=} keys\n * @param {Object=} options\n * @return {!RegExp}\n */\nfunction tokensToRegExp (tokens, keys, options) {\n if (!isarray(keys)) {\n options = /** @type {!Object} */ (keys || options)\n keys = []\n }\n\n options = options || {}\n\n var strict = options.strict\n var end = options.end !== false\n var route = ''\n\n // Iterate over the tokens and create our regexp string.\n for (var i = 0; i < tokens.length; i++) {\n var token = tokens[i]\n\n if (typeof token === 'string') {\n route += escapeString(token)\n } else {\n var prefix = escapeString(token.prefix)\n var capture = '(?:' + token.pattern + ')'\n\n keys.push(token)\n\n if (token.repeat) {\n capture += '(?:' + prefix + capture + ')*'\n }\n\n if (token.optional) {\n if (!token.partial) {\n capture = '(?:' + prefix + '(' + capture + '))?'\n } else {\n capture = prefix + '(' + capture + ')?'\n }\n } else {\n capture = prefix + '(' + capture + ')'\n }\n\n route += capture\n }\n }\n\n var delimiter = escapeString(options.delimiter || '/')\n var endsWithDelimiter = route.slice(-delimiter.length) === delimiter\n\n // In non-strict mode we allow a slash at the end of match. If the path to\n // match already ends with a slash, we remove it for consistency. The slash\n // is valid at the end of a path match, not in the middle. This is important\n // in non-ending mode, where \"/test/\" shouldn't match \"/test//route\".\n if (!strict) {\n route = (endsWithDelimiter ? route.slice(0, -delimiter.length) : route) + '(?:' + delimiter + '(?=$))?'\n }\n\n if (end) {\n route += '$'\n } else {\n // In non-ending mode, we need the capturing groups to match as much as\n // possible by using a positive lookahead to the end or next path segment.\n route += strict && endsWithDelimiter ? '' : '(?=' + delimiter + '|$)'\n }\n\n return attachKeys(new RegExp('^' + route, flags(options)), keys)\n}\n\n/**\n * Normalize the given path string, returning a regular expression.\n *\n * An empty array can be passed in for the keys, which will hold the\n * placeholder key descriptions. For example, using `/user/:id`, `keys` will\n * contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.\n *\n * @param {(string|RegExp|Array)} path\n * @param {(Array|Object)=} keys\n * @param {Object=} options\n * @return {!RegExp}\n */\nfunction pathToRegexp (path, keys, options) {\n if (!isarray(keys)) {\n options = /** @type {!Object} */ (keys || options)\n keys = []\n }\n\n options = options || {}\n\n if (path instanceof RegExp) {\n return regexpToRegexp(path, /** @type {!Array} */ (keys))\n }\n\n if (isarray(path)) {\n return arrayToRegexp(/** @type {!Array} */ (path), /** @type {!Array} */ (keys), options)\n }\n\n return stringToRegexp(/** @type {string} */ (path), /** @type {!Array} */ (keys), options)\n}\n","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _ExclamationCircleOutlined = _interopRequireDefault(require('./lib/icons/ExclamationCircleOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _ExclamationCircleOutlined;\n exports.default = _default;\n module.exports = _default;","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2014-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nvar runtime = (function (exports) {\n \"use strict\";\n\n var Op = Object.prototype;\n var hasOwn = Op.hasOwnProperty;\n var undefined; // More compressible than void 0.\n var $Symbol = typeof Symbol === \"function\" ? Symbol : {};\n var iteratorSymbol = $Symbol.iterator || \"@@iterator\";\n var asyncIteratorSymbol = $Symbol.asyncIterator || \"@@asyncIterator\";\n var toStringTagSymbol = $Symbol.toStringTag || \"@@toStringTag\";\n\n function define(obj, key, value) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n return obj[key];\n }\n try {\n // IE 8 has a broken Object.defineProperty that only works on DOM objects.\n define({}, \"\");\n } catch (err) {\n define = function(obj, key, value) {\n return obj[key] = value;\n };\n }\n\n function wrap(innerFn, outerFn, self, tryLocsList) {\n // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.\n var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;\n var generator = Object.create(protoGenerator.prototype);\n var context = new Context(tryLocsList || []);\n\n // The ._invoke method unifies the implementations of the .next,\n // .throw, and .return methods.\n generator._invoke = makeInvokeMethod(innerFn, self, context);\n\n return generator;\n }\n exports.wrap = wrap;\n\n // Try/catch helper to minimize deoptimizations. Returns a completion\n // record like context.tryEntries[i].completion. This interface could\n // have been (and was previously) designed to take a closure to be\n // invoked without arguments, but in all the cases we care about we\n // already have an existing method we want to call, so there's no need\n // to create a new function object. We can even get away with assuming\n // the method takes exactly one argument, since that happens to be true\n // in every case, so we don't have to touch the arguments object. The\n // only additional allocation required is the completion record, which\n // has a stable shape and so hopefully should be cheap to allocate.\n function tryCatch(fn, obj, arg) {\n try {\n return { type: \"normal\", arg: fn.call(obj, arg) };\n } catch (err) {\n return { type: \"throw\", arg: err };\n }\n }\n\n var GenStateSuspendedStart = \"suspendedStart\";\n var GenStateSuspendedYield = \"suspendedYield\";\n var GenStateExecuting = \"executing\";\n var GenStateCompleted = \"completed\";\n\n // Returning this object from the innerFn has the same effect as\n // breaking out of the dispatch switch statement.\n var ContinueSentinel = {};\n\n // Dummy constructor functions that we use as the .constructor and\n // .constructor.prototype properties for functions that return Generator\n // objects. For full spec compliance, you may wish to configure your\n // minifier not to mangle the names of these two functions.\n function Generator() {}\n function GeneratorFunction() {}\n function GeneratorFunctionPrototype() {}\n\n // This is a polyfill for %IteratorPrototype% for environments that\n // don't natively support it.\n var IteratorPrototype = {};\n IteratorPrototype[iteratorSymbol] = function () {\n return this;\n };\n\n var getProto = Object.getPrototypeOf;\n var NativeIteratorPrototype = getProto && getProto(getProto(values([])));\n if (NativeIteratorPrototype &&\n NativeIteratorPrototype !== Op &&\n hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {\n // This environment has a native %IteratorPrototype%; use it instead\n // of the polyfill.\n IteratorPrototype = NativeIteratorPrototype;\n }\n\n var Gp = GeneratorFunctionPrototype.prototype =\n Generator.prototype = Object.create(IteratorPrototype);\n GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;\n GeneratorFunctionPrototype.constructor = GeneratorFunction;\n GeneratorFunction.displayName = define(\n GeneratorFunctionPrototype,\n toStringTagSymbol,\n \"GeneratorFunction\"\n );\n\n // Helper for defining the .next, .throw, and .return methods of the\n // Iterator interface in terms of a single ._invoke method.\n function defineIteratorMethods(prototype) {\n [\"next\", \"throw\", \"return\"].forEach(function(method) {\n define(prototype, method, function(arg) {\n return this._invoke(method, arg);\n });\n });\n }\n\n exports.isGeneratorFunction = function(genFun) {\n var ctor = typeof genFun === \"function\" && genFun.constructor;\n return ctor\n ? ctor === GeneratorFunction ||\n // For the native GeneratorFunction constructor, the best we can\n // do is to check its .name property.\n (ctor.displayName || ctor.name) === \"GeneratorFunction\"\n : false;\n };\n\n exports.mark = function(genFun) {\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);\n } else {\n genFun.__proto__ = GeneratorFunctionPrototype;\n define(genFun, toStringTagSymbol, \"GeneratorFunction\");\n }\n genFun.prototype = Object.create(Gp);\n return genFun;\n };\n\n // Within the body of any async function, `await x` is transformed to\n // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test\n // `hasOwn.call(value, \"__await\")` to determine if the yielded value is\n // meant to be awaited.\n exports.awrap = function(arg) {\n return { __await: arg };\n };\n\n function AsyncIterator(generator, PromiseImpl) {\n function invoke(method, arg, resolve, reject) {\n var record = tryCatch(generator[method], generator, arg);\n if (record.type === \"throw\") {\n reject(record.arg);\n } else {\n var result = record.arg;\n var value = result.value;\n if (value &&\n typeof value === \"object\" &&\n hasOwn.call(value, \"__await\")) {\n return PromiseImpl.resolve(value.__await).then(function(value) {\n invoke(\"next\", value, resolve, reject);\n }, function(err) {\n invoke(\"throw\", err, resolve, reject);\n });\n }\n\n return PromiseImpl.resolve(value).then(function(unwrapped) {\n // When a yielded Promise is resolved, its final value becomes\n // the .value of the Promise<{value,done}> result for the\n // current iteration.\n result.value = unwrapped;\n resolve(result);\n }, function(error) {\n // If a rejected Promise was yielded, throw the rejection back\n // into the async generator function so it can be handled there.\n return invoke(\"throw\", error, resolve, reject);\n });\n }\n }\n\n var previousPromise;\n\n function enqueue(method, arg) {\n function callInvokeWithMethodAndArg() {\n return new PromiseImpl(function(resolve, reject) {\n invoke(method, arg, resolve, reject);\n });\n }\n\n return previousPromise =\n // If enqueue has been called before, then we want to wait until\n // all previous Promises have been resolved before calling invoke,\n // so that results are always delivered in the correct order. If\n // enqueue has not been called before, then it is important to\n // call invoke immediately, without waiting on a callback to fire,\n // so that the async generator function has the opportunity to do\n // any necessary setup in a predictable way. This predictability\n // is why the Promise constructor synchronously invokes its\n // executor callback, and why async functions synchronously\n // execute code before the first await. Since we implement simple\n // async functions in terms of async generators, it is especially\n // important to get this right, even though it requires care.\n previousPromise ? previousPromise.then(\n callInvokeWithMethodAndArg,\n // Avoid propagating failures to Promises returned by later\n // invocations of the iterator.\n callInvokeWithMethodAndArg\n ) : callInvokeWithMethodAndArg();\n }\n\n // Define the unified helper method that is used to implement .next,\n // .throw, and .return (see defineIteratorMethods).\n this._invoke = enqueue;\n }\n\n defineIteratorMethods(AsyncIterator.prototype);\n AsyncIterator.prototype[asyncIteratorSymbol] = function () {\n return this;\n };\n exports.AsyncIterator = AsyncIterator;\n\n // Note that simple async functions are implemented on top of\n // AsyncIterator objects; they just return a Promise for the value of\n // the final result produced by the iterator.\n exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {\n if (PromiseImpl === void 0) PromiseImpl = Promise;\n\n var iter = new AsyncIterator(\n wrap(innerFn, outerFn, self, tryLocsList),\n PromiseImpl\n );\n\n return exports.isGeneratorFunction(outerFn)\n ? iter // If outerFn is a generator, return the full iterator.\n : iter.next().then(function(result) {\n return result.done ? result.value : iter.next();\n });\n };\n\n function makeInvokeMethod(innerFn, self, context) {\n var state = GenStateSuspendedStart;\n\n return function invoke(method, arg) {\n if (state === GenStateExecuting) {\n throw new Error(\"Generator is already running\");\n }\n\n if (state === GenStateCompleted) {\n if (method === \"throw\") {\n throw arg;\n }\n\n // Be forgiving, per 25.3.3.3.3 of the spec:\n // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume\n return doneResult();\n }\n\n context.method = method;\n context.arg = arg;\n\n while (true) {\n var delegate = context.delegate;\n if (delegate) {\n var delegateResult = maybeInvokeDelegate(delegate, context);\n if (delegateResult) {\n if (delegateResult === ContinueSentinel) continue;\n return delegateResult;\n }\n }\n\n if (context.method === \"next\") {\n // Setting context._sent for legacy support of Babel's\n // function.sent implementation.\n context.sent = context._sent = context.arg;\n\n } else if (context.method === \"throw\") {\n if (state === GenStateSuspendedStart) {\n state = GenStateCompleted;\n throw context.arg;\n }\n\n context.dispatchException(context.arg);\n\n } else if (context.method === \"return\") {\n context.abrupt(\"return\", context.arg);\n }\n\n state = GenStateExecuting;\n\n var record = tryCatch(innerFn, self, context);\n if (record.type === \"normal\") {\n // If an exception is thrown from innerFn, we leave state ===\n // GenStateExecuting and loop back for another invocation.\n state = context.done\n ? GenStateCompleted\n : GenStateSuspendedYield;\n\n if (record.arg === ContinueSentinel) {\n continue;\n }\n\n return {\n value: record.arg,\n done: context.done\n };\n\n } else if (record.type === \"throw\") {\n state = GenStateCompleted;\n // Dispatch the exception by looping back around to the\n // context.dispatchException(context.arg) call above.\n context.method = \"throw\";\n context.arg = record.arg;\n }\n }\n };\n }\n\n // Call delegate.iterator[context.method](context.arg) and handle the\n // result, either by returning a { value, done } result from the\n // delegate iterator, or by modifying context.method and context.arg,\n // setting context.delegate to null, and returning the ContinueSentinel.\n function maybeInvokeDelegate(delegate, context) {\n var method = delegate.iterator[context.method];\n if (method === undefined) {\n // A .throw or .return when the delegate iterator has no .throw\n // method always terminates the yield* loop.\n context.delegate = null;\n\n if (context.method === \"throw\") {\n // Note: [\"return\"] must be used for ES3 parsing compatibility.\n if (delegate.iterator[\"return\"]) {\n // If the delegate iterator has a return method, give it a\n // chance to clean up.\n context.method = \"return\";\n context.arg = undefined;\n maybeInvokeDelegate(delegate, context);\n\n if (context.method === \"throw\") {\n // If maybeInvokeDelegate(context) changed context.method from\n // \"return\" to \"throw\", let that override the TypeError below.\n return ContinueSentinel;\n }\n }\n\n context.method = \"throw\";\n context.arg = new TypeError(\n \"The iterator does not provide a 'throw' method\");\n }\n\n return ContinueSentinel;\n }\n\n var record = tryCatch(method, delegate.iterator, context.arg);\n\n if (record.type === \"throw\") {\n context.method = \"throw\";\n context.arg = record.arg;\n context.delegate = null;\n return ContinueSentinel;\n }\n\n var info = record.arg;\n\n if (! info) {\n context.method = \"throw\";\n context.arg = new TypeError(\"iterator result is not an object\");\n context.delegate = null;\n return ContinueSentinel;\n }\n\n if (info.done) {\n // Assign the result of the finished delegate to the temporary\n // variable specified by delegate.resultName (see delegateYield).\n context[delegate.resultName] = info.value;\n\n // Resume execution at the desired location (see delegateYield).\n context.next = delegate.nextLoc;\n\n // If context.method was \"throw\" but the delegate handled the\n // exception, let the outer generator proceed normally. If\n // context.method was \"next\", forget context.arg since it has been\n // \"consumed\" by the delegate iterator. If context.method was\n // \"return\", allow the original .return call to continue in the\n // outer generator.\n if (context.method !== \"return\") {\n context.method = \"next\";\n context.arg = undefined;\n }\n\n } else {\n // Re-yield the result returned by the delegate method.\n return info;\n }\n\n // The delegate iterator is finished, so forget it and continue with\n // the outer generator.\n context.delegate = null;\n return ContinueSentinel;\n }\n\n // Define Generator.prototype.{next,throw,return} in terms of the\n // unified ._invoke helper method.\n defineIteratorMethods(Gp);\n\n define(Gp, toStringTagSymbol, \"Generator\");\n\n // A Generator should always return itself as the iterator object when the\n // @@iterator function is called on it. Some browsers' implementations of the\n // iterator prototype chain incorrectly implement this, causing the Generator\n // object to not be returned from this call. This ensures that doesn't happen.\n // See https://github.com/facebook/regenerator/issues/274 for more details.\n Gp[iteratorSymbol] = function() {\n return this;\n };\n\n Gp.toString = function() {\n return \"[object Generator]\";\n };\n\n function pushTryEntry(locs) {\n var entry = { tryLoc: locs[0] };\n\n if (1 in locs) {\n entry.catchLoc = locs[1];\n }\n\n if (2 in locs) {\n entry.finallyLoc = locs[2];\n entry.afterLoc = locs[3];\n }\n\n this.tryEntries.push(entry);\n }\n\n function resetTryEntry(entry) {\n var record = entry.completion || {};\n record.type = \"normal\";\n delete record.arg;\n entry.completion = record;\n }\n\n function Context(tryLocsList) {\n // The root entry object (effectively a try statement without a catch\n // or a finally block) gives us a place to store values thrown from\n // locations where there is no enclosing try statement.\n this.tryEntries = [{ tryLoc: \"root\" }];\n tryLocsList.forEach(pushTryEntry, this);\n this.reset(true);\n }\n\n exports.keys = function(object) {\n var keys = [];\n for (var key in object) {\n keys.push(key);\n }\n keys.reverse();\n\n // Rather than returning an object with a next method, we keep\n // things simple and return the next function itself.\n return function next() {\n while (keys.length) {\n var key = keys.pop();\n if (key in object) {\n next.value = key;\n next.done = false;\n return next;\n }\n }\n\n // To avoid creating an additional object, we just hang the .value\n // and .done properties off the next function object itself. This\n // also ensures that the minifier will not anonymize the function.\n next.done = true;\n return next;\n };\n };\n\n function values(iterable) {\n if (iterable) {\n var iteratorMethod = iterable[iteratorSymbol];\n if (iteratorMethod) {\n return iteratorMethod.call(iterable);\n }\n\n if (typeof iterable.next === \"function\") {\n return iterable;\n }\n\n if (!isNaN(iterable.length)) {\n var i = -1, next = function next() {\n while (++i < iterable.length) {\n if (hasOwn.call(iterable, i)) {\n next.value = iterable[i];\n next.done = false;\n return next;\n }\n }\n\n next.value = undefined;\n next.done = true;\n\n return next;\n };\n\n return next.next = next;\n }\n }\n\n // Return an iterator with no values.\n return { next: doneResult };\n }\n exports.values = values;\n\n function doneResult() {\n return { value: undefined, done: true };\n }\n\n Context.prototype = {\n constructor: Context,\n\n reset: function(skipTempReset) {\n this.prev = 0;\n this.next = 0;\n // Resetting context._sent for legacy support of Babel's\n // function.sent implementation.\n this.sent = this._sent = undefined;\n this.done = false;\n this.delegate = null;\n\n this.method = \"next\";\n this.arg = undefined;\n\n this.tryEntries.forEach(resetTryEntry);\n\n if (!skipTempReset) {\n for (var name in this) {\n // Not sure about the optimal order of these conditions:\n if (name.charAt(0) === \"t\" &&\n hasOwn.call(this, name) &&\n !isNaN(+name.slice(1))) {\n this[name] = undefined;\n }\n }\n }\n },\n\n stop: function() {\n this.done = true;\n\n var rootEntry = this.tryEntries[0];\n var rootRecord = rootEntry.completion;\n if (rootRecord.type === \"throw\") {\n throw rootRecord.arg;\n }\n\n return this.rval;\n },\n\n dispatchException: function(exception) {\n if (this.done) {\n throw exception;\n }\n\n var context = this;\n function handle(loc, caught) {\n record.type = \"throw\";\n record.arg = exception;\n context.next = loc;\n\n if (caught) {\n // If the dispatched exception was caught by a catch block,\n // then let that catch block handle the exception normally.\n context.method = \"next\";\n context.arg = undefined;\n }\n\n return !! caught;\n }\n\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n var record = entry.completion;\n\n if (entry.tryLoc === \"root\") {\n // Exception thrown outside of any try block that could handle\n // it, so set the completion value of the entire function to\n // throw the exception.\n return handle(\"end\");\n }\n\n if (entry.tryLoc <= this.prev) {\n var hasCatch = hasOwn.call(entry, \"catchLoc\");\n var hasFinally = hasOwn.call(entry, \"finallyLoc\");\n\n if (hasCatch && hasFinally) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n } else if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else if (hasCatch) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n }\n\n } else if (hasFinally) {\n if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else {\n throw new Error(\"try statement without catch or finally\");\n }\n }\n }\n },\n\n abrupt: function(type, arg) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc <= this.prev &&\n hasOwn.call(entry, \"finallyLoc\") &&\n this.prev < entry.finallyLoc) {\n var finallyEntry = entry;\n break;\n }\n }\n\n if (finallyEntry &&\n (type === \"break\" ||\n type === \"continue\") &&\n finallyEntry.tryLoc <= arg &&\n arg <= finallyEntry.finallyLoc) {\n // Ignore the finally entry if control is not jumping to a\n // location outside the try/catch block.\n finallyEntry = null;\n }\n\n var record = finallyEntry ? finallyEntry.completion : {};\n record.type = type;\n record.arg = arg;\n\n if (finallyEntry) {\n this.method = \"next\";\n this.next = finallyEntry.finallyLoc;\n return ContinueSentinel;\n }\n\n return this.complete(record);\n },\n\n complete: function(record, afterLoc) {\n if (record.type === \"throw\") {\n throw record.arg;\n }\n\n if (record.type === \"break\" ||\n record.type === \"continue\") {\n this.next = record.arg;\n } else if (record.type === \"return\") {\n this.rval = this.arg = record.arg;\n this.method = \"return\";\n this.next = \"end\";\n } else if (record.type === \"normal\" && afterLoc) {\n this.next = afterLoc;\n }\n\n return ContinueSentinel;\n },\n\n finish: function(finallyLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.finallyLoc === finallyLoc) {\n this.complete(entry.completion, entry.afterLoc);\n resetTryEntry(entry);\n return ContinueSentinel;\n }\n }\n },\n\n \"catch\": function(tryLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc === tryLoc) {\n var record = entry.completion;\n if (record.type === \"throw\") {\n var thrown = record.arg;\n resetTryEntry(entry);\n }\n return thrown;\n }\n }\n\n // The context.catch method must only be called with a location\n // argument that corresponds to a known catch block.\n throw new Error(\"illegal catch attempt\");\n },\n\n delegateYield: function(iterable, resultName, nextLoc) {\n this.delegate = {\n iterator: values(iterable),\n resultName: resultName,\n nextLoc: nextLoc\n };\n\n if (this.method === \"next\") {\n // Deliberately forget the last sent value so that we don't\n // accidentally pass it on to the delegate.\n this.arg = undefined;\n }\n\n return ContinueSentinel;\n }\n };\n\n // Regardless of whether this script is executing as a CommonJS module\n // or not, return the runtime object so that we can declare the variable\n // regeneratorRuntime in the outer scope, which allows this module to be\n // injected easily by `bin/regenerator --include-runtime script.js`.\n return exports;\n\n}(\n // If this script is executing as a CommonJS module, use module.exports\n // as the regeneratorRuntime namespace. Otherwise create a new empty\n // object. Either way, the resulting object will be used to initialize\n // the regeneratorRuntime variable at the top of this file.\n typeof module === \"object\" ? module.exports : {}\n));\n\ntry {\n regeneratorRuntime = runtime;\n} catch (accidentalStrictMode) {\n // This module should not be running in strict mode, so the above\n // assignment should always work unless something is misconfigured. Just\n // in case runtime.js accidentally runs in strict mode, we can escape\n // strict mode using a global Function call. This could conceivably fail\n // if a Content Security Policy forbids using Function, but in that case\n // the proper solution is to fix the accidental strict mode problem. If\n // you've misconfigured your bundler to force strict mode and applied a\n // CSP to forbid Function, and you're not willing to fix either of those\n // problems, please detail your unique predicament in a GitHub issue.\n Function(\"r\", \"regeneratorRuntime = r\")(runtime);\n}\n","'use strict';\n\nmodule.exports = function bind(fn, thisArg) {\n return function wrap() {\n var args = new Array(arguments.length);\n for (var i = 0; i < args.length; i++) {\n args[i] = arguments[i];\n }\n return fn.apply(thisArg, args);\n };\n};\n","'use strict';\n\nvar utils = require('./../utils');\n\nfunction encode(val) {\n return encodeURIComponent(val).\n replace(/%40/gi, '@').\n replace(/%3A/gi, ':').\n replace(/%24/g, '$').\n replace(/%2C/gi, ',').\n replace(/%20/g, '+').\n replace(/%5B/gi, '[').\n replace(/%5D/gi, ']');\n}\n\n/**\n * Build a URL by appending params to the end\n *\n * @param {string} url The base of the url (e.g., http://www.google.com)\n * @param {object} [params] The params to be appended\n * @returns {string} The formatted url\n */\nmodule.exports = function buildURL(url, params, paramsSerializer) {\n /*eslint no-param-reassign:0*/\n if (!params) {\n return url;\n }\n\n var serializedParams;\n if (paramsSerializer) {\n serializedParams = paramsSerializer(params);\n } else if (utils.isURLSearchParams(params)) {\n serializedParams = params.toString();\n } else {\n var parts = [];\n\n utils.forEach(params, function serialize(val, key) {\n if (val === null || typeof val === 'undefined') {\n return;\n }\n\n if (utils.isArray(val)) {\n key = key + '[]';\n } else {\n val = [val];\n }\n\n utils.forEach(val, function parseValue(v) {\n if (utils.isDate(v)) {\n v = v.toISOString();\n } else if (utils.isObject(v)) {\n v = JSON.stringify(v);\n }\n parts.push(encode(key) + '=' + encode(v));\n });\n });\n\n serializedParams = parts.join('&');\n }\n\n if (serializedParams) {\n var hashmarkIndex = url.indexOf('#');\n if (hashmarkIndex !== -1) {\n url = url.slice(0, hashmarkIndex);\n }\n\n url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams;\n }\n\n return url;\n};\n","'use strict';\n\nmodule.exports = function isCancel(value) {\n return !!(value && value.__CANCEL__);\n};\n","'use strict';\n\nvar utils = require('./utils');\nvar normalizeHeaderName = require('./helpers/normalizeHeaderName');\n\nvar DEFAULT_CONTENT_TYPE = {\n 'Content-Type': 'application/x-www-form-urlencoded'\n};\n\nfunction setContentTypeIfUnset(headers, value) {\n if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) {\n headers['Content-Type'] = value;\n }\n}\n\nfunction getDefaultAdapter() {\n var adapter;\n if (typeof XMLHttpRequest !== 'undefined') {\n // For browsers use XHR adapter\n adapter = require('./adapters/xhr');\n } else if (typeof process !== 'undefined' && Object.prototype.toString.call(process) === '[object process]') {\n // For node use HTTP adapter\n adapter = require('./adapters/http');\n }\n return adapter;\n}\n\nvar defaults = {\n adapter: getDefaultAdapter(),\n\n transformRequest: [function transformRequest(data, headers) {\n normalizeHeaderName(headers, 'Accept');\n normalizeHeaderName(headers, 'Content-Type');\n if (utils.isFormData(data) ||\n utils.isArrayBuffer(data) ||\n utils.isBuffer(data) ||\n utils.isStream(data) ||\n utils.isFile(data) ||\n utils.isBlob(data)\n ) {\n return data;\n }\n if (utils.isArrayBufferView(data)) {\n return data.buffer;\n }\n if (utils.isURLSearchParams(data)) {\n setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8');\n return data.toString();\n }\n if (utils.isObject(data)) {\n setContentTypeIfUnset(headers, 'application/json;charset=utf-8');\n return JSON.stringify(data);\n }\n return data;\n }],\n\n transformResponse: [function transformResponse(data) {\n /*eslint no-param-reassign:0*/\n if (typeof data === 'string') {\n try {\n data = JSON.parse(data);\n } catch (e) { /* Ignore */ }\n }\n return data;\n }],\n\n /**\n * A timeout in milliseconds to abort a request. If set to 0 (default) a\n * timeout is not created.\n */\n timeout: 0,\n\n xsrfCookieName: 'XSRF-TOKEN',\n xsrfHeaderName: 'X-XSRF-TOKEN',\n\n maxContentLength: -1,\n\n validateStatus: function validateStatus(status) {\n return status >= 200 && status < 300;\n }\n};\n\ndefaults.headers = {\n common: {\n 'Accept': 'application/json, text/plain, */*'\n }\n};\n\nutils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) {\n defaults.headers[method] = {};\n});\n\nutils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {\n defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE);\n});\n\nmodule.exports = defaults;\n","'use strict';\n\nvar utils = require('./../utils');\nvar settle = require('./../core/settle');\nvar buildURL = require('./../helpers/buildURL');\nvar buildFullPath = require('../core/buildFullPath');\nvar parseHeaders = require('./../helpers/parseHeaders');\nvar isURLSameOrigin = require('./../helpers/isURLSameOrigin');\nvar createError = require('../core/createError');\n\nmodule.exports = function xhrAdapter(config) {\n return new Promise(function dispatchXhrRequest(resolve, reject) {\n var requestData = config.data;\n var requestHeaders = config.headers;\n\n if (utils.isFormData(requestData)) {\n delete requestHeaders['Content-Type']; // Let the browser set it\n }\n\n var request = new XMLHttpRequest();\n\n // HTTP basic authentication\n if (config.auth) {\n var username = config.auth.username || '';\n var password = config.auth.password || '';\n requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password);\n }\n\n var fullPath = buildFullPath(config.baseURL, config.url);\n request.open(config.method.toUpperCase(), buildURL(fullPath, config.params, config.paramsSerializer), true);\n\n // Set the request timeout in MS\n request.timeout = config.timeout;\n\n // Listen for ready state\n request.onreadystatechange = function handleLoad() {\n if (!request || request.readyState !== 4) {\n return;\n }\n\n // The request errored out and we didn't get a response, this will be\n // handled by onerror instead\n // With one exception: request that using file: protocol, most browsers\n // will return status as 0 even though it's a successful request\n if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) {\n return;\n }\n\n // Prepare the response\n var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null;\n var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response;\n var response = {\n data: responseData,\n status: request.status,\n statusText: request.statusText,\n headers: responseHeaders,\n config: config,\n request: request\n };\n\n settle(resolve, reject, response);\n\n // Clean up request\n request = null;\n };\n\n // Handle browser request cancellation (as opposed to a manual cancellation)\n request.onabort = function handleAbort() {\n if (!request) {\n return;\n }\n\n reject(createError('Request aborted', config, 'ECONNABORTED', request));\n\n // Clean up request\n request = null;\n };\n\n // Handle low level network errors\n request.onerror = function handleError() {\n // Real errors are hidden from us by the browser\n // onerror should only fire if it's a network error\n reject(createError('Network Error', config, null, request));\n\n // Clean up request\n request = null;\n };\n\n // Handle timeout\n request.ontimeout = function handleTimeout() {\n var timeoutErrorMessage = 'timeout of ' + config.timeout + 'ms exceeded';\n if (config.timeoutErrorMessage) {\n timeoutErrorMessage = config.timeoutErrorMessage;\n }\n reject(createError(timeoutErrorMessage, config, 'ECONNABORTED',\n request));\n\n // Clean up request\n request = null;\n };\n\n // Add xsrf header\n // This is only done if running in a standard browser environment.\n // Specifically not if we're in a web worker, or react-native.\n if (utils.isStandardBrowserEnv()) {\n var cookies = require('./../helpers/cookies');\n\n // Add xsrf header\n var xsrfValue = (config.withCredentials || isURLSameOrigin(fullPath)) && config.xsrfCookieName ?\n cookies.read(config.xsrfCookieName) :\n undefined;\n\n if (xsrfValue) {\n requestHeaders[config.xsrfHeaderName] = xsrfValue;\n }\n }\n\n // Add headers to the request\n if ('setRequestHeader' in request) {\n utils.forEach(requestHeaders, function setRequestHeader(val, key) {\n if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') {\n // Remove Content-Type if data is undefined\n delete requestHeaders[key];\n } else {\n // Otherwise add header to the request\n request.setRequestHeader(key, val);\n }\n });\n }\n\n // Add withCredentials to request if needed\n if (!utils.isUndefined(config.withCredentials)) {\n request.withCredentials = !!config.withCredentials;\n }\n\n // Add responseType to request if needed\n if (config.responseType) {\n try {\n request.responseType = config.responseType;\n } catch (e) {\n // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2.\n // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function.\n if (config.responseType !== 'json') {\n throw e;\n }\n }\n }\n\n // Handle progress if needed\n if (typeof config.onDownloadProgress === 'function') {\n request.addEventListener('progress', config.onDownloadProgress);\n }\n\n // Not all browsers support upload events\n if (typeof config.onUploadProgress === 'function' && request.upload) {\n request.upload.addEventListener('progress', config.onUploadProgress);\n }\n\n if (config.cancelToken) {\n // Handle cancellation\n config.cancelToken.promise.then(function onCanceled(cancel) {\n if (!request) {\n return;\n }\n\n request.abort();\n reject(cancel);\n // Clean up request\n request = null;\n });\n }\n\n if (requestData === undefined) {\n requestData = null;\n }\n\n // Send the request\n request.send(requestData);\n });\n};\n","'use strict';\n\nvar enhanceError = require('./enhanceError');\n\n/**\n * Create an Error with the specified message, config, error code, request and response.\n *\n * @param {string} message The error message.\n * @param {Object} config The config.\n * @param {string} [code] The error code (for example, 'ECONNABORTED').\n * @param {Object} [request] The request.\n * @param {Object} [response] The response.\n * @returns {Error} The created error.\n */\nmodule.exports = function createError(message, config, code, request, response) {\n var error = new Error(message);\n return enhanceError(error, config, code, request, response);\n};\n","'use strict';\n\nvar utils = require('../utils');\n\n/**\n * Config-specific merge-function which creates a new config-object\n * by merging two configuration objects together.\n *\n * @param {Object} config1\n * @param {Object} config2\n * @returns {Object} New object resulting from merging config2 to config1\n */\nmodule.exports = function mergeConfig(config1, config2) {\n // eslint-disable-next-line no-param-reassign\n config2 = config2 || {};\n var config = {};\n\n var valueFromConfig2Keys = ['url', 'method', 'params', 'data'];\n var mergeDeepPropertiesKeys = ['headers', 'auth', 'proxy'];\n var defaultToConfig2Keys = [\n 'baseURL', 'url', 'transformRequest', 'transformResponse', 'paramsSerializer',\n 'timeout', 'withCredentials', 'adapter', 'responseType', 'xsrfCookieName',\n 'xsrfHeaderName', 'onUploadProgress', 'onDownloadProgress',\n 'maxContentLength', 'validateStatus', 'maxRedirects', 'httpAgent',\n 'httpsAgent', 'cancelToken', 'socketPath'\n ];\n\n utils.forEach(valueFromConfig2Keys, function valueFromConfig2(prop) {\n if (typeof config2[prop] !== 'undefined') {\n config[prop] = config2[prop];\n }\n });\n\n utils.forEach(mergeDeepPropertiesKeys, function mergeDeepProperties(prop) {\n if (utils.isObject(config2[prop])) {\n config[prop] = utils.deepMerge(config1[prop], config2[prop]);\n } else if (typeof config2[prop] !== 'undefined') {\n config[prop] = config2[prop];\n } else if (utils.isObject(config1[prop])) {\n config[prop] = utils.deepMerge(config1[prop]);\n } else if (typeof config1[prop] !== 'undefined') {\n config[prop] = config1[prop];\n }\n });\n\n utils.forEach(defaultToConfig2Keys, function defaultToConfig2(prop) {\n if (typeof config2[prop] !== 'undefined') {\n config[prop] = config2[prop];\n } else if (typeof config1[prop] !== 'undefined') {\n config[prop] = config1[prop];\n }\n });\n\n var axiosKeys = valueFromConfig2Keys\n .concat(mergeDeepPropertiesKeys)\n .concat(defaultToConfig2Keys);\n\n var otherKeys = Object\n .keys(config2)\n .filter(function filterAxiosKeys(key) {\n return axiosKeys.indexOf(key) === -1;\n });\n\n utils.forEach(otherKeys, function otherKeysDefaultToConfig2(prop) {\n if (typeof config2[prop] !== 'undefined') {\n config[prop] = config2[prop];\n } else if (typeof config1[prop] !== 'undefined') {\n config[prop] = config1[prop];\n }\n });\n\n return config;\n};\n","'use strict';\n\n/**\n * A `Cancel` is an object that is thrown when an operation is canceled.\n *\n * @class\n * @param {string=} message The message.\n */\nfunction Cancel(message) {\n this.message = message;\n}\n\nCancel.prototype.toString = function toString() {\n return 'Cancel' + (this.message ? ': ' + this.message : '');\n};\n\nCancel.prototype.__CANCEL__ = true;\n\nmodule.exports = Cancel;\n","function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}\n\nmodule.exports = _arrayWithHoles;","function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}\n\nmodule.exports = _arrayLikeToArray;","function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n\nmodule.exports = _nonIterableRest;","var objectWithoutPropertiesLoose = require(\"./objectWithoutPropertiesLoose\");\n\nfunction _objectWithoutProperties(source, excluded) {\n if (source == null) return {};\n var target = objectWithoutPropertiesLoose(source, excluded);\n var key, i;\n\n if (Object.getOwnPropertySymbols) {\n var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n\n for (i = 0; i < sourceSymbolKeys.length; i++) {\n key = sourceSymbolKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n target[key] = source[key];\n }\n }\n\n return target;\n}\n\nmodule.exports = _objectWithoutProperties;","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _objectWithoutProperties2 = _interopRequireDefault(require(\"@babel/runtime/helpers/objectWithoutProperties\"));\n\nvar _objectSpread2 = _interopRequireDefault(require(\"@babel/runtime/helpers/objectSpread2\"));\n\nvar _utils = require(\"../utils\");\n\nvar twoToneColorPalette = {\n primaryColor: '#333',\n secondaryColor: '#E6E6E6',\n calculated: false\n};\n\nfunction setTwoToneColors(_ref) {\n var primaryColor = _ref.primaryColor,\n secondaryColor = _ref.secondaryColor;\n twoToneColorPalette.primaryColor = primaryColor;\n twoToneColorPalette.secondaryColor = secondaryColor || (0, _utils.getSecondaryColor)(primaryColor);\n twoToneColorPalette.calculated = !!secondaryColor;\n}\n\nfunction getTwoToneColors() {\n return (0, _objectSpread2.default)({}, twoToneColorPalette);\n}\n\nvar IconBase = function IconBase(props) {\n var icon = props.icon,\n className = props.className,\n onClick = props.onClick,\n style = props.style,\n primaryColor = props.primaryColor,\n secondaryColor = props.secondaryColor,\n restProps = (0, _objectWithoutProperties2.default)(props, [\"icon\", \"className\", \"onClick\", \"style\", \"primaryColor\", \"secondaryColor\"]);\n var colors = twoToneColorPalette;\n\n if (primaryColor) {\n colors = {\n primaryColor: primaryColor,\n secondaryColor: secondaryColor || (0, _utils.getSecondaryColor)(primaryColor)\n };\n }\n\n (0, _utils.useInsertStyles)();\n (0, _utils.warning)((0, _utils.isIconDefinition)(icon), \"icon should be icon definiton, but got \".concat(icon));\n\n if (!(0, _utils.isIconDefinition)(icon)) {\n return null;\n }\n\n var target = icon;\n\n if (target && typeof target.icon === 'function') {\n target = (0, _objectSpread2.default)((0, _objectSpread2.default)({}, target), {}, {\n icon: target.icon(colors.primaryColor, colors.secondaryColor)\n });\n }\n\n return (0, _utils.generate)(target.icon, \"svg-\".concat(target.name), (0, _objectSpread2.default)({\n className: className,\n onClick: onClick,\n style: style,\n 'data-icon': target.name,\n width: '1em',\n height: '1em',\n fill: 'currentColor',\n 'aria-hidden': 'true'\n }, restProps));\n};\n\nIconBase.displayName = 'IconReact';\nIconBase.getTwoToneColors = getTwoToneColors;\nIconBase.setTwoToneColors = setTwoToneColors;\nvar _default = IconBase;\nexports.default = _default;","var defineProperty = require(\"./defineProperty\");\n\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n if (enumerableOnly) symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nfunction _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n}\n\nmodule.exports = _objectSpread2;","function _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter);\n}\n\nmodule.exports = _iterableToArray;","/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nmodule.exports = eq;\n","var baseGetTag = require('./_baseGetTag'),\n isObject = require('./isObject');\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nmodule.exports = isFunction;\n","/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nmodule.exports = freeGlobal;\n","/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nmodule.exports = toSource;\n","var mapCacheClear = require('./_mapCacheClear'),\n mapCacheDelete = require('./_mapCacheDelete'),\n mapCacheGet = require('./_mapCacheGet'),\n mapCacheHas = require('./_mapCacheHas'),\n mapCacheSet = require('./_mapCacheSet');\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nmodule.exports = MapCache;\n","var SetCache = require('./_SetCache'),\n arraySome = require('./_arraySome'),\n cacheHas = require('./_cacheHas');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalArrays;\n","var root = require('./_root'),\n stubFalse = require('./stubFalse');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nmodule.exports = isBuffer;\n","module.exports = function(module) {\n\tif (!module.webpackPolyfill) {\n\t\tmodule.deprecate = function() {};\n\t\tmodule.paths = [];\n\t\t// module.parent = undefined by default\n\t\tif (!module.children) module.children = [];\n\t\tObject.defineProperty(module, \"loaded\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.l;\n\t\t\t}\n\t\t});\n\t\tObject.defineProperty(module, \"id\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.i;\n\t\t\t}\n\t\t});\n\t\tmodule.webpackPolyfill = 1;\n\t}\n\treturn module;\n};\n","var baseIsTypedArray = require('./_baseIsTypedArray'),\n baseUnary = require('./_baseUnary'),\n nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nmodule.exports = isTypedArray;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nmodule.exports = isLength;\n","import '../../style/index.less';\nimport './index.less'; // style dependencies\n// deps-lint-skip: layout\n\nimport '../../tooltip/style';","import '../../style/index.less';\nimport './index.less';","import '../../style/index.less';\nimport './index.less'; // style dependencies\n\nimport '../../button/style';","import '../../style/index.less';\nimport './index.less'; // style dependencies\n\nimport '../../empty/style';","import '../../style/index.less';\nimport './index.less'; // style dependencies\n\nimport '../../button/style';","import '../../style/index.less';\nimport './index.less';","import '../../style/index.less';\nimport './index.less';","function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {\n try {\n var info = gen[key](arg);\n var value = info.value;\n } catch (error) {\n reject(error);\n return;\n }\n\n if (info.done) {\n resolve(value);\n } else {\n Promise.resolve(value).then(_next, _throw);\n }\n}\n\nexport default function _asyncToGenerator(fn) {\n return function () {\n var self = this,\n args = arguments;\n return new Promise(function (resolve, reject) {\n var gen = fn.apply(self, args);\n\n function _next(value) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"next\", value);\n }\n\n function _throw(err) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"throw\", err);\n }\n\n _next(undefined);\n });\n };\n}","module.exports = require('./lib/axios');","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _InfoCircleFilled = _interopRequireDefault(require('./lib/icons/InfoCircleFilled'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _InfoCircleFilled;\n exports.default = _default;\n module.exports = _default;","/* eslint no-console:0 */\n\nconst formatRegExp = /%[sdj%]/g;\n\nexport let warning = () => {};\n\n// don't print warning message when in production env or node runtime\nif (\n typeof process !== 'undefined' &&\n process.env &&\n process.env.NODE_ENV !== 'production' &&\n typeof window !== 'undefined' &&\n typeof document !== 'undefined'\n) {\n warning = (type, errors) => {\n if (typeof console !== 'undefined' && console.warn) {\n if (errors.every(e => typeof e === 'string')) {\n console.warn(type, errors);\n }\n }\n };\n}\n\nexport function convertFieldsError(errors) {\n if (!errors || !errors.length) return null;\n const fields = {};\n errors.forEach(error => {\n const field = error.field;\n fields[field] = fields[field] || [];\n fields[field].push(error);\n });\n return fields;\n}\n\nexport function format(...args) {\n let i = 1;\n const f = args[0];\n const len = args.length;\n if (typeof f === 'function') {\n return f.apply(null, args.slice(1));\n }\n if (typeof f === 'string') {\n let str = String(f).replace(formatRegExp, x => {\n if (x === '%%') {\n return '%';\n }\n if (i >= len) {\n return x;\n }\n switch (x) {\n case '%s':\n return String(args[i++]);\n case '%d':\n return Number(args[i++]);\n case '%j':\n try {\n return JSON.stringify(args[i++]);\n } catch (_) {\n return '[Circular]';\n }\n break;\n default:\n return x;\n }\n });\n return str;\n }\n return f;\n}\n\nfunction isNativeStringType(type) {\n return (\n type === 'string' ||\n type === 'url' ||\n type === 'hex' ||\n type === 'email' ||\n type === 'date' ||\n type === 'pattern'\n );\n}\n\nexport function isEmptyValue(value, type) {\n if (value === undefined || value === null) {\n return true;\n }\n if (type === 'array' && Array.isArray(value) && !value.length) {\n return true;\n }\n if (isNativeStringType(type) && typeof value === 'string' && !value) {\n return true;\n }\n return false;\n}\n\nexport function isEmptyObject(obj) {\n return Object.keys(obj).length === 0;\n}\n\nfunction asyncParallelArray(arr, func, callback) {\n const results = [];\n let total = 0;\n const arrLength = arr.length;\n\n function count(errors) {\n results.push.apply(results, errors);\n total++;\n if (total === arrLength) {\n callback(results);\n }\n }\n\n arr.forEach(a => {\n func(a, count);\n });\n}\n\nfunction asyncSerialArray(arr, func, callback) {\n let index = 0;\n const arrLength = arr.length;\n\n function next(errors) {\n if (errors && errors.length) {\n callback(errors);\n return;\n }\n const original = index;\n index = index + 1;\n if (original < arrLength) {\n func(arr[original], next);\n } else {\n callback([]);\n }\n }\n\n next([]);\n}\n\nfunction flattenObjArr(objArr) {\n const ret = [];\n Object.keys(objArr).forEach(k => {\n ret.push.apply(ret, objArr[k]);\n });\n return ret;\n}\n\nexport class AsyncValidationError extends Error {\n constructor(errors, fields) {\n super('Async Validation Error');\n this.errors = errors;\n this.fields = fields;\n }\n}\n\nexport function asyncMap(objArr, option, func, callback) {\n if (option.first) {\n const pending = new Promise((resolve, reject) => {\n const next = errors => {\n callback(errors);\n return errors.length\n ? reject(new AsyncValidationError(errors, convertFieldsError(errors)))\n : resolve();\n };\n const flattenArr = flattenObjArr(objArr);\n asyncSerialArray(flattenArr, func, next);\n });\n pending.catch(e => e);\n return pending;\n }\n let firstFields = option.firstFields || [];\n if (firstFields === true) {\n firstFields = Object.keys(objArr);\n }\n const objArrKeys = Object.keys(objArr);\n const objArrLength = objArrKeys.length;\n let total = 0;\n const results = [];\n const pending = new Promise((resolve, reject) => {\n const next = errors => {\n results.push.apply(results, errors);\n total++;\n if (total === objArrLength) {\n callback(results);\n return results.length\n ? reject(\n new AsyncValidationError(results, convertFieldsError(results)),\n )\n : resolve();\n }\n };\n if (!objArrKeys.length) {\n callback(results);\n resolve();\n }\n objArrKeys.forEach(key => {\n const arr = objArr[key];\n if (firstFields.indexOf(key) !== -1) {\n asyncSerialArray(arr, func, next);\n } else {\n asyncParallelArray(arr, func, next);\n }\n });\n });\n pending.catch(e => e);\n return pending;\n}\n\nexport function complementError(rule) {\n return oe => {\n if (oe && oe.message) {\n oe.field = oe.field || rule.fullField;\n return oe;\n }\n return {\n message: typeof oe === 'function' ? oe() : oe,\n field: oe.field || rule.fullField,\n };\n };\n}\n\nexport function deepMerge(target, source) {\n if (source) {\n for (const s in source) {\n if (source.hasOwnProperty(s)) {\n const value = source[s];\n if (typeof value === 'object' && typeof target[s] === 'object') {\n target[s] = {\n ...target[s],\n ...value,\n };\n } else {\n target[s] = value;\n }\n }\n }\n }\n return target;\n}\n","import * as util from '../util';\n\n/**\n * Rule for validating required fields.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param source The source object being validated.\n * @param errors An array of errors that this rule may add\n * validation errors to.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction required(rule, value, source, errors, options, type) {\n if (\n rule.required &&\n (!source.hasOwnProperty(rule.field) ||\n util.isEmptyValue(value, type || rule.type))\n ) {\n errors.push(util.format(options.messages.required, rule.fullField));\n }\n}\n\nexport default required;\n","import * as util from '../util';\nimport required from './required';\n\n/* eslint max-len:0 */\n\nconst pattern = {\n // http://emailregex.com/\n email: /^(([^<>()\\[\\]\\\\.,;:\\s@\"]+(\\.[^<>()\\[\\]\\\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$/,\n url: new RegExp(\n '^(?!mailto:)(?:(?:http|https|ftp)://|//)(?:\\\\S+(?::\\\\S*)?@)?(?:(?:(?:[1-9]\\\\d?|1\\\\d\\\\d|2[01]\\\\d|22[0-3])(?:\\\\.(?:1?\\\\d{1,2}|2[0-4]\\\\d|25[0-5])){2}(?:\\\\.(?:[0-9]\\\\d?|1\\\\d\\\\d|2[0-4]\\\\d|25[0-4]))|(?:(?:[a-z\\\\u00a1-\\\\uffff0-9]+-*)*[a-z\\\\u00a1-\\\\uffff0-9]+)(?:\\\\.(?:[a-z\\\\u00a1-\\\\uffff0-9]+-*)*[a-z\\\\u00a1-\\\\uffff0-9]+)*(?:\\\\.(?:[a-z\\\\u00a1-\\\\uffff]{2,})))|localhost)(?::\\\\d{2,5})?(?:(/|\\\\?|#)[^\\\\s]*)?$',\n 'i',\n ),\n hex: /^#?([a-f0-9]{6}|[a-f0-9]{3})$/i,\n};\n\nconst types = {\n integer(value) {\n return types.number(value) && parseInt(value, 10) === value;\n },\n float(value) {\n return types.number(value) && !types.integer(value);\n },\n array(value) {\n return Array.isArray(value);\n },\n regexp(value) {\n if (value instanceof RegExp) {\n return true;\n }\n try {\n return !!new RegExp(value);\n } catch (e) {\n return false;\n }\n },\n date(value) {\n return (\n typeof value.getTime === 'function' &&\n typeof value.getMonth === 'function' &&\n typeof value.getYear === 'function' &&\n !isNaN(value.getTime())\n );\n },\n number(value) {\n if (isNaN(value)) {\n return false;\n }\n return typeof value === 'number';\n },\n object(value) {\n return typeof value === 'object' && !types.array(value);\n },\n method(value) {\n return typeof value === 'function';\n },\n email(value) {\n return (\n typeof value === 'string' &&\n !!value.match(pattern.email) &&\n value.length < 255\n );\n },\n url(value) {\n return typeof value === 'string' && !!value.match(pattern.url);\n },\n hex(value) {\n return typeof value === 'string' && !!value.match(pattern.hex);\n },\n};\n\n/**\n * Rule for validating the type of a value.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param source The source object being validated.\n * @param errors An array of errors that this rule may add\n * validation errors to.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction type(rule, value, source, errors, options) {\n if (rule.required && value === undefined) {\n required(rule, value, source, errors, options);\n return;\n }\n const custom = [\n 'integer',\n 'float',\n 'array',\n 'regexp',\n 'object',\n 'method',\n 'email',\n 'number',\n 'date',\n 'url',\n 'hex',\n ];\n const ruleType = rule.type;\n if (custom.indexOf(ruleType) > -1) {\n if (!types[ruleType](value)) {\n errors.push(\n util.format(\n options.messages.types[ruleType],\n rule.fullField,\n rule.type,\n ),\n );\n }\n // straight typeof check\n } else if (ruleType && typeof value !== rule.type) {\n errors.push(\n util.format(options.messages.types[ruleType], rule.fullField, rule.type),\n );\n }\n}\n\nexport default type;\n","import required from './required';\nimport whitespace from './whitespace';\nimport type from './type';\nimport range from './range';\nimport enumRule from './enum';\nimport pattern from './pattern';\n\nexport default {\n required,\n whitespace,\n type,\n range,\n enum: enumRule,\n pattern,\n};\n","import * as util from '../util';\n\n/**\n * Rule for validating whitespace.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param source The source object being validated.\n * @param errors An array of errors that this rule may add\n * validation errors to.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction whitespace(rule, value, source, errors, options) {\n if (/^\\s+$/.test(value) || value === '') {\n errors.push(util.format(options.messages.whitespace, rule.fullField));\n }\n}\n\nexport default whitespace;\n","import * as util from '../util';\n\n/**\n * Rule for validating minimum and maximum allowed values.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param source The source object being validated.\n * @param errors An array of errors that this rule may add\n * validation errors to.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction range(rule, value, source, errors, options) {\n const len = typeof rule.len === 'number';\n const min = typeof rule.min === 'number';\n const max = typeof rule.max === 'number';\n // 正则匹配码点范围从U+010000一直到U+10FFFF的文字(补充平面Supplementary Plane)\n const spRegexp = /[\\uD800-\\uDBFF][\\uDC00-\\uDFFF]/g;\n let val = value;\n let key = null;\n const num = typeof value === 'number';\n const str = typeof value === 'string';\n const arr = Array.isArray(value);\n if (num) {\n key = 'number';\n } else if (str) {\n key = 'string';\n } else if (arr) {\n key = 'array';\n }\n // if the value is not of a supported type for range validation\n // the validation rule rule should use the\n // type property to also test for a particular type\n if (!key) {\n return false;\n }\n if (arr) {\n val = value.length;\n }\n if (str) {\n // 处理码点大于U+010000的文字length属性不准确的bug,如\"𠮷𠮷𠮷\".lenght !== 3\n val = value.replace(spRegexp, '_').length;\n }\n if (len) {\n if (val !== rule.len) {\n errors.push(\n util.format(options.messages[key].len, rule.fullField, rule.len),\n );\n }\n } else if (min && !max && val < rule.min) {\n errors.push(\n util.format(options.messages[key].min, rule.fullField, rule.min),\n );\n } else if (max && !min && val > rule.max) {\n errors.push(\n util.format(options.messages[key].max, rule.fullField, rule.max),\n );\n } else if (min && max && (val < rule.min || val > rule.max)) {\n errors.push(\n util.format(\n options.messages[key].range,\n rule.fullField,\n rule.min,\n rule.max,\n ),\n );\n }\n}\n\nexport default range;\n","import * as util from '../util';\n\nconst ENUM = 'enum';\n\n/**\n * Rule for validating a value exists in an enumerable list.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param source The source object being validated.\n * @param errors An array of errors that this rule may add\n * validation errors to.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction enumerable(rule, value, source, errors, options) {\n rule[ENUM] = Array.isArray(rule[ENUM]) ? rule[ENUM] : [];\n if (rule[ENUM].indexOf(value) === -1) {\n errors.push(\n util.format(\n options.messages[ENUM],\n rule.fullField,\n rule[ENUM].join(', '),\n ),\n );\n }\n}\n\nexport default enumerable;\n","import * as util from '../util';\n\n/**\n * Rule for validating a regular expression pattern.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param source The source object being validated.\n * @param errors An array of errors that this rule may add\n * validation errors to.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction pattern(rule, value, source, errors, options) {\n if (rule.pattern) {\n if (rule.pattern instanceof RegExp) {\n // if a RegExp instance is passed, reset `lastIndex` in case its `global`\n // flag is accidentally set to `true`, which in a validation scenario\n // is not necessary and the result might be misleading\n rule.pattern.lastIndex = 0;\n if (!rule.pattern.test(value)) {\n errors.push(\n util.format(\n options.messages.pattern.mismatch,\n rule.fullField,\n value,\n rule.pattern,\n ),\n );\n }\n } else if (typeof rule.pattern === 'string') {\n const _pattern = new RegExp(rule.pattern);\n if (!_pattern.test(value)) {\n errors.push(\n util.format(\n options.messages.pattern.mismatch,\n rule.fullField,\n value,\n rule.pattern,\n ),\n );\n }\n }\n }\n}\n\nexport default pattern;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\nfunction type(rule, value, callback, source, options) {\n const ruleType = rule.type;\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value, ruleType) && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options, ruleType);\n if (!isEmptyValue(value, ruleType)) {\n rules.type(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default type;\n","import string from './string';\nimport method from './method';\nimport number from './number';\nimport boolean from './boolean';\nimport regexp from './regexp';\nimport integer from './integer';\nimport float from './float';\nimport array from './array';\nimport object from './object';\nimport enumValidator from './enum';\nimport pattern from './pattern';\nimport date from './date';\nimport required from './required';\nimport type from './type';\nimport any from './any';\n\nexport default {\n string,\n method,\n number,\n boolean,\n regexp,\n integer,\n float,\n array,\n object,\n enum: enumValidator,\n pattern,\n date,\n url: type,\n hex: type,\n email: type,\n required,\n any,\n};\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\n/**\n * Performs validation for string types.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction string(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value, 'string') && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options, 'string');\n if (!isEmptyValue(value, 'string')) {\n rules.type(rule, value, source, errors, options);\n rules.range(rule, value, source, errors, options);\n rules.pattern(rule, value, source, errors, options);\n if (rule.whitespace === true) {\n rules.whitespace(rule, value, source, errors, options);\n }\n }\n }\n callback(errors);\n}\n\nexport default string;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\n/**\n * Validates a function.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction method(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n if (value !== undefined) {\n rules.type(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default method;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\n/**\n * Validates a number.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction number(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (value === '') {\n value = undefined;\n }\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n if (value !== undefined) {\n rules.type(rule, value, source, errors, options);\n rules.range(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default number;\n","import { isEmptyValue } from '../util';\nimport rules from '../rule/index.js';\n\n/**\n * Validates a boolean.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction boolean(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n if (value !== undefined) {\n rules.type(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default boolean;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\n/**\n * Validates the regular expression type.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction regexp(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n if (!isEmptyValue(value)) {\n rules.type(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default regexp;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\n/**\n * Validates a number is an integer.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction integer(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n if (value !== undefined) {\n rules.type(rule, value, source, errors, options);\n rules.range(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default integer;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\n/**\n * Validates a number is a floating point number.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction floatFn(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n if (value !== undefined) {\n rules.type(rule, value, source, errors, options);\n rules.range(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default floatFn;\n","import rules from '../rule/index';\nimport { isEmptyValue } from '../util';\n/**\n * Validates an array.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction array(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value, 'array') && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options, 'array');\n if (!isEmptyValue(value, 'array')) {\n rules.type(rule, value, source, errors, options);\n rules.range(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default array;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\n/**\n * Validates an object.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction object(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n if (value !== undefined) {\n rules.type(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default object;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\nconst ENUM = 'enum';\n\n/**\n * Validates an enumerable list.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction enumerable(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n if (value !== undefined) {\n rules[ENUM](rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default enumerable;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\n/**\n * Validates a regular expression pattern.\n *\n * Performs validation when a rule only contains\n * a pattern property but is not declared as a string type.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction pattern(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value, 'string') && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n if (!isEmptyValue(value, 'string')) {\n rules.pattern(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}\n\nexport default pattern;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\nfunction date(rule, value, callback, source, options) {\n // console.log('integer rule called %j', rule);\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n // console.log('validate on %s value', value);\n if (validate) {\n if (isEmptyValue(value, 'date') && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n if (!isEmptyValue(value, 'date')) {\n let dateObject;\n\n if (value instanceof Date) {\n dateObject = value;\n } else {\n dateObject = new Date(value);\n }\n\n rules.type(rule, dateObject, source, errors, options);\n if (dateObject) {\n rules.range(rule, dateObject.getTime(), source, errors, options);\n }\n }\n }\n callback(errors);\n}\n\nexport default date;\n","import rules from '../rule/index.js';\n\nfunction required(rule, value, callback, source, options) {\n const errors = [];\n const type = Array.isArray(value) ? 'array' : typeof value;\n rules.required(rule, value, source, errors, options, type);\n callback(errors);\n}\n\nexport default required;\n","import rules from '../rule/index.js';\nimport { isEmptyValue } from '../util';\n\n/**\n * Performs validation for any type.\n *\n * @param rule The validation rule.\n * @param value The value of the field on the source object.\n * @param callback The callback function.\n * @param source The source object being validated.\n * @param options The validation options.\n * @param options.messages The validation messages.\n */\nfunction any(rule, value, callback, source, options) {\n const errors = [];\n const validate =\n rule.required || (!rule.required && source.hasOwnProperty(rule.field));\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n rules.required(rule, value, source, errors, options);\n }\n callback(errors);\n}\n\nexport default any;\n","export function newMessages() {\n return {\n default: 'Validation error on field %s',\n required: '%s is required',\n enum: '%s must be one of %s',\n whitespace: '%s cannot be empty',\n date: {\n format: '%s date %s is invalid for format %s',\n parse: '%s date could not be parsed, %s is invalid ',\n invalid: '%s date %s is invalid',\n },\n types: {\n string: '%s is not a %s',\n method: '%s is not a %s (function)',\n array: '%s is not an %s',\n object: '%s is not an %s',\n number: '%s is not a %s',\n date: '%s is not a %s',\n boolean: '%s is not a %s',\n integer: '%s is not an %s',\n float: '%s is not a %s',\n regexp: '%s is not a valid %s',\n email: '%s is not a valid %s',\n url: '%s is not a valid %s',\n hex: '%s is not a valid %s',\n },\n string: {\n len: '%s must be exactly %s characters',\n min: '%s must be at least %s characters',\n max: '%s cannot be longer than %s characters',\n range: '%s must be between %s and %s characters',\n },\n number: {\n len: '%s must equal %s',\n min: '%s cannot be less than %s',\n max: '%s cannot be greater than %s',\n range: '%s must be between %s and %s',\n },\n array: {\n len: '%s must be exactly %s in length',\n min: '%s cannot be less than %s in length',\n max: '%s cannot be greater than %s in length',\n range: '%s must be between %s and %s in length',\n },\n pattern: {\n mismatch: '%s value %s does not match pattern %s',\n },\n clone() {\n const cloned = JSON.parse(JSON.stringify(this));\n cloned.clone = this.clone;\n return cloned;\n },\n };\n}\n\nexport const messages = newMessages();\n","import {\n format,\n complementError,\n asyncMap,\n warning,\n deepMerge,\n convertFieldsError,\n} from './util';\nimport validators from './validator/index';\nimport { messages as defaultMessages, newMessages } from './messages';\n\n/**\n * Encapsulates a validation schema.\n *\n * @param descriptor An object declaring validation rules\n * for this schema.\n */\nfunction Schema(descriptor) {\n this.rules = null;\n this._messages = defaultMessages;\n this.define(descriptor);\n}\n\nSchema.prototype = {\n messages(messages) {\n if (messages) {\n this._messages = deepMerge(newMessages(), messages);\n }\n return this._messages;\n },\n define(rules) {\n if (!rules) {\n throw new Error('Cannot configure a schema with no rules');\n }\n if (typeof rules !== 'object' || Array.isArray(rules)) {\n throw new Error('Rules must be an object');\n }\n this.rules = {};\n let z;\n let item;\n for (z in rules) {\n if (rules.hasOwnProperty(z)) {\n item = rules[z];\n this.rules[z] = Array.isArray(item) ? item : [item];\n }\n }\n },\n validate(source_, o = {}, oc = () => {}) {\n let source = source_;\n let options = o;\n let callback = oc;\n if (typeof options === 'function') {\n callback = options;\n options = {};\n }\n if (!this.rules || Object.keys(this.rules).length === 0) {\n if (callback) {\n callback();\n }\n return Promise.resolve();\n }\n\n function complete(results) {\n let i;\n let errors = [];\n let fields = {};\n\n function add(e) {\n if (Array.isArray(e)) {\n errors = errors.concat(...e);\n } else {\n errors.push(e);\n }\n }\n\n for (i = 0; i < results.length; i++) {\n add(results[i]);\n }\n if (!errors.length) {\n errors = null;\n fields = null;\n } else {\n fields = convertFieldsError(errors);\n }\n callback(errors, fields);\n }\n\n if (options.messages) {\n let messages = this.messages();\n if (messages === defaultMessages) {\n messages = newMessages();\n }\n deepMerge(messages, options.messages);\n options.messages = messages;\n } else {\n options.messages = this.messages();\n }\n let arr;\n let value;\n const series = {};\n const keys = options.keys || Object.keys(this.rules);\n keys.forEach(z => {\n arr = this.rules[z];\n value = source[z];\n arr.forEach(r => {\n let rule = r;\n if (typeof rule.transform === 'function') {\n if (source === source_) {\n source = { ...source };\n }\n value = source[z] = rule.transform(value);\n }\n if (typeof rule === 'function') {\n rule = {\n validator: rule,\n };\n } else {\n rule = { ...rule };\n }\n rule.validator = this.getValidationMethod(rule);\n rule.field = z;\n rule.fullField = rule.fullField || z;\n rule.type = this.getType(rule);\n if (!rule.validator) {\n return;\n }\n series[z] = series[z] || [];\n series[z].push({\n rule,\n value,\n source,\n field: z,\n });\n });\n });\n const errorFields = {};\n return asyncMap(\n series,\n options,\n (data, doIt) => {\n const rule = data.rule;\n let deep =\n (rule.type === 'object' || rule.type === 'array') &&\n (typeof rule.fields === 'object' ||\n typeof rule.defaultField === 'object');\n deep = deep && (rule.required || (!rule.required && data.value));\n rule.field = data.field;\n\n function addFullfield(key, schema) {\n return {\n ...schema,\n fullField: `${rule.fullField}.${key}`,\n };\n }\n\n function cb(e = []) {\n let errors = e;\n if (!Array.isArray(errors)) {\n errors = [errors];\n }\n if (!options.suppressWarning && errors.length) {\n Schema.warning('async-validator:', errors);\n }\n if (errors.length && rule.message) {\n errors = [].concat(rule.message);\n }\n\n errors = errors.map(complementError(rule));\n\n if (options.first && errors.length) {\n errorFields[rule.field] = 1;\n return doIt(errors);\n }\n if (!deep) {\n doIt(errors);\n } else {\n // if rule is required but the target object\n // does not exist fail at the rule level and don't\n // go deeper\n if (rule.required && !data.value) {\n if (rule.message) {\n errors = [].concat(rule.message).map(complementError(rule));\n } else if (options.error) {\n errors = [\n options.error(\n rule,\n format(options.messages.required, rule.field),\n ),\n ];\n }\n return doIt(errors);\n }\n\n let fieldsSchema = {};\n if (rule.defaultField) {\n for (const k in data.value) {\n if (data.value.hasOwnProperty(k)) {\n fieldsSchema[k] = rule.defaultField;\n }\n }\n }\n fieldsSchema = {\n ...fieldsSchema,\n ...data.rule.fields,\n };\n for (const f in fieldsSchema) {\n if (fieldsSchema.hasOwnProperty(f)) {\n const fieldSchema = Array.isArray(fieldsSchema[f])\n ? fieldsSchema[f]\n : [fieldsSchema[f]];\n fieldsSchema[f] = fieldSchema.map(addFullfield.bind(null, f));\n }\n }\n const schema = new Schema(fieldsSchema);\n schema.messages(options.messages);\n if (data.rule.options) {\n data.rule.options.messages = options.messages;\n data.rule.options.error = options.error;\n }\n schema.validate(data.value, data.rule.options || options, errs => {\n const finalErrors = [];\n if (errors && errors.length) {\n finalErrors.push(...errors);\n }\n if (errs && errs.length) {\n finalErrors.push(...errs);\n }\n doIt(finalErrors.length ? finalErrors : null);\n });\n }\n }\n\n let res;\n if (rule.asyncValidator) {\n res = rule.asyncValidator(rule, data.value, cb, data.source, options);\n } else if (rule.validator) {\n res = rule.validator(rule, data.value, cb, data.source, options);\n if (res === true) {\n cb();\n } else if (res === false) {\n cb(rule.message || `${rule.field} fails`);\n } else if (res instanceof Array) {\n cb(res);\n } else if (res instanceof Error) {\n cb(res.message);\n }\n }\n if (res && res.then) {\n res.then(\n () => cb(),\n e => cb(e),\n );\n }\n },\n results => {\n complete(results);\n },\n );\n },\n getType(rule) {\n if (rule.type === undefined && rule.pattern instanceof RegExp) {\n rule.type = 'pattern';\n }\n if (\n typeof rule.validator !== 'function' &&\n rule.type && !validators.hasOwnProperty(rule.type)\n ) {\n throw new Error(format('Unknown rule type %s', rule.type));\n }\n return rule.type || 'string';\n },\n getValidationMethod(rule) {\n if (typeof rule.validator === 'function') {\n return rule.validator;\n }\n const keys = Object.keys(rule);\n const messageIndex = keys.indexOf('message');\n if (messageIndex !== -1) {\n keys.splice(messageIndex, 1);\n }\n if (keys.length === 1 && keys[0] === 'required') {\n return validators.required;\n }\n return validators[this.getType(rule)] || false;\n },\n};\n\nSchema.register = function register(type, validator) {\n if (typeof validator !== 'function') {\n throw new Error(\n 'Cannot register a validator by type, validator is not a function',\n );\n }\n validators[type] = validator;\n};\n\nSchema.warning = warning;\n\nSchema.messages = defaultMessages;\n\nSchema.validators = validators;\n\n\nexport default Schema;\n","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _EyeOutlined = _interopRequireDefault(require('./lib/icons/EyeOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _EyeOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _EyeInvisibleOutlined = _interopRequireDefault(require('./lib/icons/EyeInvisibleOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _EyeInvisibleOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _BarsOutlined = _interopRequireDefault(require('./lib/icons/BarsOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _BarsOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _FilterFilled = _interopRequireDefault(require('./lib/icons/FilterFilled'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _FilterFilled;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _EllipsisOutlined = _interopRequireDefault(require('./lib/icons/EllipsisOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _EllipsisOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _CaretUpOutlined = _interopRequireDefault(require('./lib/icons/CaretUpOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _CaretUpOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _CaretDownOutlined = _interopRequireDefault(require('./lib/icons/CaretDownOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _CaretDownOutlined;\n exports.default = _default;\n module.exports = _default;","var arrayWithHoles = require(\"./arrayWithHoles\");\n\nvar iterableToArray = require(\"./iterableToArray\");\n\nvar unsupportedIterableToArray = require(\"./unsupportedIterableToArray\");\n\nvar nonIterableRest = require(\"./nonIterableRest\");\n\nfunction _toArray(arr) {\n return arrayWithHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableRest();\n}\n\nmodule.exports = _toArray;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _DoubleLeftOutlined = _interopRequireDefault(require('./lib/icons/DoubleLeftOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _DoubleLeftOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _DoubleRightOutlined = _interopRequireDefault(require('./lib/icons/DoubleRightOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _DoubleRightOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _CheckOutlined = _interopRequireDefault(require('./lib/icons/CheckOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _CheckOutlined;\n exports.default = _default;\n module.exports = _default;","var isObject = require('./isObject'),\n now = require('./now'),\n toNumber = require('./toNumber');\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeMax = Math.max,\n nativeMin = Math.min;\n\n/**\n * Creates a debounced function that delays invoking `func` until after `wait`\n * milliseconds have elapsed since the last time the debounced function was\n * invoked. The debounced function comes with a `cancel` method to cancel\n * delayed `func` invocations and a `flush` method to immediately invoke them.\n * Provide `options` to indicate whether `func` should be invoked on the\n * leading and/or trailing edge of the `wait` timeout. The `func` is invoked\n * with the last arguments provided to the debounced function. Subsequent\n * calls to the debounced function return the result of the last `func`\n * invocation.\n *\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\n * invoked on the trailing edge of the timeout only if the debounced function\n * is invoked more than once during the `wait` timeout.\n *\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\n *\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\n * for details over the differences between `_.debounce` and `_.throttle`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to debounce.\n * @param {number} [wait=0] The number of milliseconds to delay.\n * @param {Object} [options={}] The options object.\n * @param {boolean} [options.leading=false]\n * Specify invoking on the leading edge of the timeout.\n * @param {number} [options.maxWait]\n * The maximum time `func` is allowed to be delayed before it's invoked.\n * @param {boolean} [options.trailing=true]\n * Specify invoking on the trailing edge of the timeout.\n * @returns {Function} Returns the new debounced function.\n * @example\n *\n * // Avoid costly calculations while the window size is in flux.\n * jQuery(window).on('resize', _.debounce(calculateLayout, 150));\n *\n * // Invoke `sendMail` when clicked, debouncing subsequent calls.\n * jQuery(element).on('click', _.debounce(sendMail, 300, {\n * 'leading': true,\n * 'trailing': false\n * }));\n *\n * // Ensure `batchLog` is invoked once after 1 second of debounced calls.\n * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 });\n * var source = new EventSource('/stream');\n * jQuery(source).on('message', debounced);\n *\n * // Cancel the trailing debounced invocation.\n * jQuery(window).on('popstate', debounced.cancel);\n */\nfunction debounce(func, wait, options) {\n var lastArgs,\n lastThis,\n maxWait,\n result,\n timerId,\n lastCallTime,\n lastInvokeTime = 0,\n leading = false,\n maxing = false,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n wait = toNumber(wait) || 0;\n if (isObject(options)) {\n leading = !!options.leading;\n maxing = 'maxWait' in options;\n maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n\n function invokeFunc(time) {\n var args = lastArgs,\n thisArg = lastThis;\n\n lastArgs = lastThis = undefined;\n lastInvokeTime = time;\n result = func.apply(thisArg, args);\n return result;\n }\n\n function leadingEdge(time) {\n // Reset any `maxWait` timer.\n lastInvokeTime = time;\n // Start the timer for the trailing edge.\n timerId = setTimeout(timerExpired, wait);\n // Invoke the leading edge.\n return leading ? invokeFunc(time) : result;\n }\n\n function remainingWait(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime,\n timeWaiting = wait - timeSinceLastCall;\n\n return maxing\n ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke)\n : timeWaiting;\n }\n\n function shouldInvoke(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime;\n\n // Either this is the first call, activity has stopped and we're at the\n // trailing edge, the system time has gone backwards and we're treating\n // it as the trailing edge, or we've hit the `maxWait` limit.\n return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||\n (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));\n }\n\n function timerExpired() {\n var time = now();\n if (shouldInvoke(time)) {\n return trailingEdge(time);\n }\n // Restart the timer.\n timerId = setTimeout(timerExpired, remainingWait(time));\n }\n\n function trailingEdge(time) {\n timerId = undefined;\n\n // Only invoke if we have `lastArgs` which means `func` has been\n // debounced at least once.\n if (trailing && lastArgs) {\n return invokeFunc(time);\n }\n lastArgs = lastThis = undefined;\n return result;\n }\n\n function cancel() {\n if (timerId !== undefined) {\n clearTimeout(timerId);\n }\n lastInvokeTime = 0;\n lastArgs = lastCallTime = lastThis = timerId = undefined;\n }\n\n function flush() {\n return timerId === undefined ? result : trailingEdge(now());\n }\n\n function debounced() {\n var time = now(),\n isInvoking = shouldInvoke(time);\n\n lastArgs = arguments;\n lastThis = this;\n lastCallTime = time;\n\n if (isInvoking) {\n if (timerId === undefined) {\n return leadingEdge(lastCallTime);\n }\n if (maxing) {\n // Handle invocations in a tight loop.\n clearTimeout(timerId);\n timerId = setTimeout(timerExpired, wait);\n return invokeFunc(lastCallTime);\n }\n }\n if (timerId === undefined) {\n timerId = setTimeout(timerExpired, wait);\n }\n return result;\n }\n debounced.cancel = cancel;\n debounced.flush = flush;\n return debounced;\n}\n\nmodule.exports = debounce;\n","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _InfoCircleOutlined = _interopRequireDefault(require('./lib/icons/InfoCircleOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _InfoCircleOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _CheckCircleOutlined = _interopRequireDefault(require('./lib/icons/CheckCircleOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _CheckCircleOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _CloseCircleOutlined = _interopRequireDefault(require('./lib/icons/CloseCircleOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _CloseCircleOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _FileOutlined = _interopRequireDefault(require('./lib/icons/FileOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _FileOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _MinusSquareOutlined = _interopRequireDefault(require('./lib/icons/MinusSquareOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _MinusSquareOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _PlusSquareOutlined = _interopRequireDefault(require('./lib/icons/PlusSquareOutlined'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _PlusSquareOutlined;\n exports.default = _default;\n module.exports = _default;","'use strict';\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.default = void 0;\n \n var _CaretDownFilled = _interopRequireDefault(require('./lib/icons/CaretDownFilled'));\n \n function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }\n \n var _default = _CaretDownFilled;\n exports.default = _default;\n module.exports = _default;","/** @license React v16.13.1\n * react.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var l=require(\"object-assign\"),n=\"function\"===typeof Symbol&&Symbol.for,p=n?Symbol.for(\"react.element\"):60103,q=n?Symbol.for(\"react.portal\"):60106,r=n?Symbol.for(\"react.fragment\"):60107,t=n?Symbol.for(\"react.strict_mode\"):60108,u=n?Symbol.for(\"react.profiler\"):60114,v=n?Symbol.for(\"react.provider\"):60109,w=n?Symbol.for(\"react.context\"):60110,x=n?Symbol.for(\"react.forward_ref\"):60112,y=n?Symbol.for(\"react.suspense\"):60113,z=n?Symbol.for(\"react.memo\"):60115,A=n?Symbol.for(\"react.lazy\"):\n60116,B=\"function\"===typeof Symbol&&Symbol.iterator;function C(a){for(var b=\"https://reactjs.org/docs/error-decoder.html?invariant=\"+a,c=1;cQ.length&&Q.push(a)}\nfunction T(a,b,c,e){var d=typeof a;if(\"undefined\"===d||\"boolean\"===d)a=null;var g=!1;if(null===a)g=!0;else switch(d){case \"string\":case \"number\":g=!0;break;case \"object\":switch(a.$$typeof){case p:case q:g=!0}}if(g)return c(e,a,\"\"===b?\".\"+U(a,0):b),1;g=0;b=\"\"===b?\".\":b+\":\";if(Array.isArray(a))for(var k=0;kb}return!1}function v(a,b,c,d,e,f){this.acceptsBooleans=2===b||3===b||4===b;this.attributeName=d;this.attributeNamespace=e;this.mustUseProperty=c;this.propertyName=a;this.type=b;this.sanitizeURL=f}var C={};\n\"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style\".split(\" \").forEach(function(a){C[a]=new v(a,0,!1,a,null,!1)});[[\"acceptCharset\",\"accept-charset\"],[\"className\",\"class\"],[\"htmlFor\",\"for\"],[\"httpEquiv\",\"http-equiv\"]].forEach(function(a){var b=a[0];C[b]=new v(b,1,!1,a[1],null,!1)});[\"contentEditable\",\"draggable\",\"spellCheck\",\"value\"].forEach(function(a){C[a]=new v(a,2,!1,a.toLowerCase(),null,!1)});\n[\"autoReverse\",\"externalResourcesRequired\",\"focusable\",\"preserveAlpha\"].forEach(function(a){C[a]=new v(a,2,!1,a,null,!1)});\"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope\".split(\" \").forEach(function(a){C[a]=new v(a,3,!1,a.toLowerCase(),null,!1)});\n[\"checked\",\"multiple\",\"muted\",\"selected\"].forEach(function(a){C[a]=new v(a,3,!0,a,null,!1)});[\"capture\",\"download\"].forEach(function(a){C[a]=new v(a,4,!1,a,null,!1)});[\"cols\",\"rows\",\"size\",\"span\"].forEach(function(a){C[a]=new v(a,6,!1,a,null,!1)});[\"rowSpan\",\"start\"].forEach(function(a){C[a]=new v(a,5,!1,a.toLowerCase(),null,!1)});var Ua=/[\\-:]([a-z])/g;function Va(a){return a[1].toUpperCase()}\n\"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height\".split(\" \").forEach(function(a){var b=a.replace(Ua,\nVa);C[b]=new v(b,1,!1,a,null,!1)});\"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type\".split(\" \").forEach(function(a){var b=a.replace(Ua,Va);C[b]=new v(b,1,!1,a,\"http://www.w3.org/1999/xlink\",!1)});[\"xml:base\",\"xml:lang\",\"xml:space\"].forEach(function(a){var b=a.replace(Ua,Va);C[b]=new v(b,1,!1,a,\"http://www.w3.org/XML/1998/namespace\",!1)});[\"tabIndex\",\"crossOrigin\"].forEach(function(a){C[a]=new v(a,1,!1,a.toLowerCase(),null,!1)});\nC.xlinkHref=new v(\"xlinkHref\",1,!1,\"xlink:href\",\"http://www.w3.org/1999/xlink\",!0);[\"src\",\"href\",\"action\",\"formAction\"].forEach(function(a){C[a]=new v(a,1,!1,a.toLowerCase(),null,!0)});var Wa=aa.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;Wa.hasOwnProperty(\"ReactCurrentDispatcher\")||(Wa.ReactCurrentDispatcher={current:null});Wa.hasOwnProperty(\"ReactCurrentBatchConfig\")||(Wa.ReactCurrentBatchConfig={suspense:null});\nfunction Xa(a,b,c,d){var e=C.hasOwnProperty(b)?C[b]:null;var f=null!==e?0===e.type:d?!1:!(2=c.length))throw Error(u(93));c=c[0]}b=c}null==b&&(b=\"\");c=b}a._wrapperState={initialValue:rb(c)}}\nfunction Kb(a,b){var c=rb(b.value),d=rb(b.defaultValue);null!=c&&(c=\"\"+c,c!==a.value&&(a.value=c),null==b.defaultValue&&a.defaultValue!==c&&(a.defaultValue=c));null!=d&&(a.defaultValue=\"\"+d)}function Lb(a){var b=a.textContent;b===a._wrapperState.initialValue&&\"\"!==b&&null!==b&&(a.value=b)}var Mb={html:\"http://www.w3.org/1999/xhtml\",mathml:\"http://www.w3.org/1998/Math/MathML\",svg:\"http://www.w3.org/2000/svg\"};\nfunction Nb(a){switch(a){case \"svg\":return\"http://www.w3.org/2000/svg\";case \"math\":return\"http://www.w3.org/1998/Math/MathML\";default:return\"http://www.w3.org/1999/xhtml\"}}function Ob(a,b){return null==a||\"http://www.w3.org/1999/xhtml\"===a?Nb(b):\"http://www.w3.org/2000/svg\"===a&&\"foreignObject\"===b?\"http://www.w3.org/1999/xhtml\":a}\nvar Pb,Qb=function(a){return\"undefined\"!==typeof MSApp&&MSApp.execUnsafeLocalFunction?function(b,c,d,e){MSApp.execUnsafeLocalFunction(function(){return a(b,c,d,e)})}:a}(function(a,b){if(a.namespaceURI!==Mb.svg||\"innerHTML\"in a)a.innerHTML=b;else{Pb=Pb||document.createElement(\"div\");Pb.innerHTML=\"\"+b.valueOf().toString()+\" \";for(b=Pb.firstChild;a.firstChild;)a.removeChild(a.firstChild);for(;b.firstChild;)a.appendChild(b.firstChild)}});\nfunction Rb(a,b){if(b){var c=a.firstChild;if(c&&c===a.lastChild&&3===c.nodeType){c.nodeValue=b;return}}a.textContent=b}function Sb(a,b){var c={};c[a.toLowerCase()]=b.toLowerCase();c[\"Webkit\"+a]=\"webkit\"+b;c[\"Moz\"+a]=\"moz\"+b;return c}var Tb={animationend:Sb(\"Animation\",\"AnimationEnd\"),animationiteration:Sb(\"Animation\",\"AnimationIteration\"),animationstart:Sb(\"Animation\",\"AnimationStart\"),transitionend:Sb(\"Transition\",\"TransitionEnd\")},Ub={},Vb={};\nya&&(Vb=document.createElement(\"div\").style,\"AnimationEvent\"in window||(delete Tb.animationend.animation,delete Tb.animationiteration.animation,delete Tb.animationstart.animation),\"TransitionEvent\"in window||delete Tb.transitionend.transition);function Wb(a){if(Ub[a])return Ub[a];if(!Tb[a])return a;var b=Tb[a],c;for(c in b)if(b.hasOwnProperty(c)&&c in Vb)return Ub[a]=b[c];return a}\nvar Xb=Wb(\"animationend\"),Yb=Wb(\"animationiteration\"),Zb=Wb(\"animationstart\"),$b=Wb(\"transitionend\"),ac=\"abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting\".split(\" \"),bc=new (\"function\"===typeof WeakMap?WeakMap:Map);function cc(a){var b=bc.get(a);void 0===b&&(b=new Map,bc.set(a,b));return b}\nfunction dc(a){var b=a,c=a;if(a.alternate)for(;b.return;)b=b.return;else{a=b;do b=a,0!==(b.effectTag&1026)&&(c=b.return),a=b.return;while(a)}return 3===b.tag?c:null}function ec(a){if(13===a.tag){var b=a.memoizedState;null===b&&(a=a.alternate,null!==a&&(b=a.memoizedState));if(null!==b)return b.dehydrated}return null}function fc(a){if(dc(a)!==a)throw Error(u(188));}\nfunction gc(a){var b=a.alternate;if(!b){b=dc(a);if(null===b)throw Error(u(188));return b!==a?null:a}for(var c=a,d=b;;){var e=c.return;if(null===e)break;var f=e.alternate;if(null===f){d=e.return;if(null!==d){c=d;continue}break}if(e.child===f.child){for(f=e.child;f;){if(f===c)return fc(e),a;if(f===d)return fc(e),b;f=f.sibling}throw Error(u(188));}if(c.return!==d.return)c=e,d=f;else{for(var g=!1,h=e.child;h;){if(h===c){g=!0;c=e;d=f;break}if(h===d){g=!0;d=e;c=f;break}h=h.sibling}if(!g){for(h=f.child;h;){if(h===\nc){g=!0;c=f;d=e;break}if(h===d){g=!0;d=f;c=e;break}h=h.sibling}if(!g)throw Error(u(189));}}if(c.alternate!==d)throw Error(u(190));}if(3!==c.tag)throw Error(u(188));return c.stateNode.current===c?a:b}function hc(a){a=gc(a);if(!a)return null;for(var b=a;;){if(5===b.tag||6===b.tag)return b;if(b.child)b.child.return=b,b=b.child;else{if(b===a)break;for(;!b.sibling;){if(!b.return||b.return===a)return null;b=b.return}b.sibling.return=b.return;b=b.sibling}}return null}\nfunction ic(a,b){if(null==b)throw Error(u(30));if(null==a)return b;if(Array.isArray(a)){if(Array.isArray(b))return a.push.apply(a,b),a;a.push(b);return a}return Array.isArray(b)?[a].concat(b):[a,b]}function jc(a,b,c){Array.isArray(a)?a.forEach(b,c):a&&b.call(c,a)}var kc=null;\nfunction lc(a){if(a){var b=a._dispatchListeners,c=a._dispatchInstances;if(Array.isArray(b))for(var d=0;dpc.length&&pc.push(a)}\nfunction rc(a,b,c,d){if(pc.length){var e=pc.pop();e.topLevelType=a;e.eventSystemFlags=d;e.nativeEvent=b;e.targetInst=c;return e}return{topLevelType:a,eventSystemFlags:d,nativeEvent:b,targetInst:c,ancestors:[]}}\nfunction sc(a){var b=a.targetInst,c=b;do{if(!c){a.ancestors.push(c);break}var d=c;if(3===d.tag)d=d.stateNode.containerInfo;else{for(;d.return;)d=d.return;d=3!==d.tag?null:d.stateNode.containerInfo}if(!d)break;b=c.tag;5!==b&&6!==b||a.ancestors.push(c);c=tc(d)}while(c);for(c=0;c=b)return{node:c,offset:b-a};a=d}a:{for(;c;){if(c.nextSibling){c=c.nextSibling;break a}c=c.parentNode}c=void 0}c=ud(c)}}\nfunction wd(a,b){return a&&b?a===b?!0:a&&3===a.nodeType?!1:b&&3===b.nodeType?wd(a,b.parentNode):\"contains\"in a?a.contains(b):a.compareDocumentPosition?!!(a.compareDocumentPosition(b)&16):!1:!1}function xd(){for(var a=window,b=td();b instanceof a.HTMLIFrameElement;){try{var c=\"string\"===typeof b.contentWindow.location.href}catch(d){c=!1}if(c)a=b.contentWindow;else break;b=td(a.document)}return b}\nfunction yd(a){var b=a&&a.nodeName&&a.nodeName.toLowerCase();return b&&(\"input\"===b&&(\"text\"===a.type||\"search\"===a.type||\"tel\"===a.type||\"url\"===a.type||\"password\"===a.type)||\"textarea\"===b||\"true\"===a.contentEditable)}var zd=\"$\",Ad=\"/$\",Bd=\"$?\",Cd=\"$!\",Dd=null,Ed=null;function Fd(a,b){switch(a){case \"button\":case \"input\":case \"select\":case \"textarea\":return!!b.autoFocus}return!1}\nfunction Gd(a,b){return\"textarea\"===a||\"option\"===a||\"noscript\"===a||\"string\"===typeof b.children||\"number\"===typeof b.children||\"object\"===typeof b.dangerouslySetInnerHTML&&null!==b.dangerouslySetInnerHTML&&null!=b.dangerouslySetInnerHTML.__html}var Hd=\"function\"===typeof setTimeout?setTimeout:void 0,Id=\"function\"===typeof clearTimeout?clearTimeout:void 0;function Jd(a){for(;null!=a;a=a.nextSibling){var b=a.nodeType;if(1===b||3===b)break}return a}\nfunction Kd(a){a=a.previousSibling;for(var b=0;a;){if(8===a.nodeType){var c=a.data;if(c===zd||c===Cd||c===Bd){if(0===b)return a;b--}else c===Ad&&b++}a=a.previousSibling}return null}var Ld=Math.random().toString(36).slice(2),Md=\"__reactInternalInstance$\"+Ld,Nd=\"__reactEventHandlers$\"+Ld,Od=\"__reactContainere$\"+Ld;\nfunction tc(a){var b=a[Md];if(b)return b;for(var c=a.parentNode;c;){if(b=c[Od]||c[Md]){c=b.alternate;if(null!==b.child||null!==c&&null!==c.child)for(a=Kd(a);null!==a;){if(c=a[Md])return c;a=Kd(a)}return b}a=c;c=a.parentNode}return null}function Nc(a){a=a[Md]||a[Od];return!a||5!==a.tag&&6!==a.tag&&13!==a.tag&&3!==a.tag?null:a}function Pd(a){if(5===a.tag||6===a.tag)return a.stateNode;throw Error(u(33));}function Qd(a){return a[Nd]||null}\nfunction Rd(a){do a=a.return;while(a&&5!==a.tag);return a?a:null}\nfunction Sd(a,b){var c=a.stateNode;if(!c)return null;var d=la(c);if(!d)return null;c=d[b];a:switch(b){case \"onClick\":case \"onClickCapture\":case \"onDoubleClick\":case \"onDoubleClickCapture\":case \"onMouseDown\":case \"onMouseDownCapture\":case \"onMouseMove\":case \"onMouseMoveCapture\":case \"onMouseUp\":case \"onMouseUpCapture\":case \"onMouseEnter\":(d=!d.disabled)||(a=a.type,d=!(\"button\"===a||\"input\"===a||\"select\"===a||\"textarea\"===a));a=!d;break a;default:a=!1}if(a)return null;if(c&&\"function\"!==typeof c)throw Error(u(231,\nb,typeof c));return c}function Td(a,b,c){if(b=Sd(a,c.dispatchConfig.phasedRegistrationNames[b]))c._dispatchListeners=ic(c._dispatchListeners,b),c._dispatchInstances=ic(c._dispatchInstances,a)}function Ud(a){if(a&&a.dispatchConfig.phasedRegistrationNames){for(var b=a._targetInst,c=[];b;)c.push(b),b=Rd(b);for(b=c.length;0this.eventPool.length&&this.eventPool.push(a)}function de(a){a.eventPool=[];a.getPooled=ee;a.release=fe}var ge=G.extend({data:null}),he=G.extend({data:null}),ie=[9,13,27,32],je=ya&&\"CompositionEvent\"in window,ke=null;ya&&\"documentMode\"in document&&(ke=document.documentMode);\nvar le=ya&&\"TextEvent\"in window&&!ke,me=ya&&(!je||ke&&8=ke),ne=String.fromCharCode(32),oe={beforeInput:{phasedRegistrationNames:{bubbled:\"onBeforeInput\",captured:\"onBeforeInputCapture\"},dependencies:[\"compositionend\",\"keypress\",\"textInput\",\"paste\"]},compositionEnd:{phasedRegistrationNames:{bubbled:\"onCompositionEnd\",captured:\"onCompositionEndCapture\"},dependencies:\"blur compositionend keydown keypress keyup mousedown\".split(\" \")},compositionStart:{phasedRegistrationNames:{bubbled:\"onCompositionStart\",\ncaptured:\"onCompositionStartCapture\"},dependencies:\"blur compositionstart keydown keypress keyup mousedown\".split(\" \")},compositionUpdate:{phasedRegistrationNames:{bubbled:\"onCompositionUpdate\",captured:\"onCompositionUpdateCapture\"},dependencies:\"blur compositionupdate keydown keypress keyup mousedown\".split(\" \")}},pe=!1;\nfunction qe(a,b){switch(a){case \"keyup\":return-1!==ie.indexOf(b.keyCode);case \"keydown\":return 229!==b.keyCode;case \"keypress\":case \"mousedown\":case \"blur\":return!0;default:return!1}}function re(a){a=a.detail;return\"object\"===typeof a&&\"data\"in a?a.data:null}var se=!1;function te(a,b){switch(a){case \"compositionend\":return re(b);case \"keypress\":if(32!==b.which)return null;pe=!0;return ne;case \"textInput\":return a=b.data,a===ne&&pe?null:a;default:return null}}\nfunction ue(a,b){if(se)return\"compositionend\"===a||!je&&qe(a,b)?(a=ae(),$d=Zd=Yd=null,se=!1,a):null;switch(a){case \"paste\":return null;case \"keypress\":if(!(b.ctrlKey||b.altKey||b.metaKey)||b.ctrlKey&&b.altKey){if(b.char&&1=document.documentMode,df={select:{phasedRegistrationNames:{bubbled:\"onSelect\",captured:\"onSelectCapture\"},dependencies:\"blur contextmenu dragend focus keydown keyup mousedown mouseup selectionchange\".split(\" \")}},ef=null,ff=null,gf=null,hf=!1;\nfunction jf(a,b){var c=b.window===b?b.document:9===b.nodeType?b:b.ownerDocument;if(hf||null==ef||ef!==td(c))return null;c=ef;\"selectionStart\"in c&&yd(c)?c={start:c.selectionStart,end:c.selectionEnd}:(c=(c.ownerDocument&&c.ownerDocument.defaultView||window).getSelection(),c={anchorNode:c.anchorNode,anchorOffset:c.anchorOffset,focusNode:c.focusNode,focusOffset:c.focusOffset});return gf&&bf(gf,c)?null:(gf=c,a=G.getPooled(df.select,ff,a,b),a.type=\"select\",a.target=ef,Xd(a),a)}\nvar kf={eventTypes:df,extractEvents:function(a,b,c,d,e,f){e=f||(d.window===d?d.document:9===d.nodeType?d:d.ownerDocument);if(!(f=!e)){a:{e=cc(e);f=wa.onSelect;for(var g=0;gzf||(a.current=yf[zf],yf[zf]=null,zf--)}\nfunction I(a,b){zf++;yf[zf]=a.current;a.current=b}var Af={},J={current:Af},K={current:!1},Bf=Af;function Cf(a,b){var c=a.type.contextTypes;if(!c)return Af;var d=a.stateNode;if(d&&d.__reactInternalMemoizedUnmaskedChildContext===b)return d.__reactInternalMemoizedMaskedChildContext;var e={},f;for(f in c)e[f]=b[f];d&&(a=a.stateNode,a.__reactInternalMemoizedUnmaskedChildContext=b,a.__reactInternalMemoizedMaskedChildContext=e);return e}function L(a){a=a.childContextTypes;return null!==a&&void 0!==a}\nfunction Df(){H(K);H(J)}function Ef(a,b,c){if(J.current!==Af)throw Error(u(168));I(J,b);I(K,c)}function Ff(a,b,c){var d=a.stateNode;a=b.childContextTypes;if(\"function\"!==typeof d.getChildContext)return c;d=d.getChildContext();for(var e in d)if(!(e in a))throw Error(u(108,pb(b)||\"Unknown\",e));return n({},c,{},d)}function Gf(a){a=(a=a.stateNode)&&a.__reactInternalMemoizedMergedChildContext||Af;Bf=J.current;I(J,a);I(K,K.current);return!0}\nfunction Hf(a,b,c){var d=a.stateNode;if(!d)throw Error(u(169));c?(a=Ff(a,b,Bf),d.__reactInternalMemoizedMergedChildContext=a,H(K),H(J),I(J,a)):H(K);I(K,c)}\nvar If=r.unstable_runWithPriority,Jf=r.unstable_scheduleCallback,Kf=r.unstable_cancelCallback,Lf=r.unstable_requestPaint,Mf=r.unstable_now,Nf=r.unstable_getCurrentPriorityLevel,Of=r.unstable_ImmediatePriority,Pf=r.unstable_UserBlockingPriority,Qf=r.unstable_NormalPriority,Rf=r.unstable_LowPriority,Sf=r.unstable_IdlePriority,Tf={},Uf=r.unstable_shouldYield,Vf=void 0!==Lf?Lf:function(){},Wf=null,Xf=null,Yf=!1,Zf=Mf(),$f=1E4>Zf?Mf:function(){return Mf()-Zf};\nfunction ag(){switch(Nf()){case Of:return 99;case Pf:return 98;case Qf:return 97;case Rf:return 96;case Sf:return 95;default:throw Error(u(332));}}function bg(a){switch(a){case 99:return Of;case 98:return Pf;case 97:return Qf;case 96:return Rf;case 95:return Sf;default:throw Error(u(332));}}function cg(a,b){a=bg(a);return If(a,b)}function dg(a,b,c){a=bg(a);return Jf(a,b,c)}function eg(a){null===Wf?(Wf=[a],Xf=Jf(Of,fg)):Wf.push(a);return Tf}function gg(){if(null!==Xf){var a=Xf;Xf=null;Kf(a)}fg()}\nfunction fg(){if(!Yf&&null!==Wf){Yf=!0;var a=0;try{var b=Wf;cg(99,function(){for(;a=b&&(rg=!0),a.firstContext=null)}\nfunction sg(a,b){if(mg!==a&&!1!==b&&0!==b){if(\"number\"!==typeof b||1073741823===b)mg=a,b=1073741823;b={context:a,observedBits:b,next:null};if(null===lg){if(null===kg)throw Error(u(308));lg=b;kg.dependencies={expirationTime:0,firstContext:b,responders:null}}else lg=lg.next=b}return a._currentValue}var tg=!1;function ug(a){a.updateQueue={baseState:a.memoizedState,baseQueue:null,shared:{pending:null},effects:null}}\nfunction vg(a,b){a=a.updateQueue;b.updateQueue===a&&(b.updateQueue={baseState:a.baseState,baseQueue:a.baseQueue,shared:a.shared,effects:a.effects})}function wg(a,b){a={expirationTime:a,suspenseConfig:b,tag:0,payload:null,callback:null,next:null};return a.next=a}function xg(a,b){a=a.updateQueue;if(null!==a){a=a.shared;var c=a.pending;null===c?b.next=b:(b.next=c.next,c.next=b);a.pending=b}}\nfunction yg(a,b){var c=a.alternate;null!==c&&vg(c,a);a=a.updateQueue;c=a.baseQueue;null===c?(a.baseQueue=b.next=b,b.next=b):(b.next=c.next,c.next=b)}\nfunction zg(a,b,c,d){var e=a.updateQueue;tg=!1;var f=e.baseQueue,g=e.shared.pending;if(null!==g){if(null!==f){var h=f.next;f.next=g.next;g.next=h}f=g;e.shared.pending=null;h=a.alternate;null!==h&&(h=h.updateQueue,null!==h&&(h.baseQueue=g))}if(null!==f){h=f.next;var k=e.baseState,l=0,m=null,p=null,x=null;if(null!==h){var z=h;do{g=z.expirationTime;if(gl&&(l=g)}else{null!==x&&(x=x.next={expirationTime:1073741823,suspenseConfig:z.suspenseConfig,tag:z.tag,payload:z.payload,callback:z.callback,next:null});Ag(g,z.suspenseConfig);a:{var D=a,t=z;g=b;ca=c;switch(t.tag){case 1:D=t.payload;if(\"function\"===typeof D){k=D.call(ca,k,g);break a}k=D;break a;case 3:D.effectTag=D.effectTag&-4097|64;case 0:D=t.payload;g=\"function\"===typeof D?D.call(ca,k,g):D;if(null===g||void 0===g)break a;k=n({},k,g);break a;case 2:tg=!0}}null!==z.callback&&\n(a.effectTag|=32,g=e.effects,null===g?e.effects=[z]:g.push(z))}z=z.next;if(null===z||z===h)if(g=e.shared.pending,null===g)break;else z=f.next=g.next,g.next=h,e.baseQueue=f=g,e.shared.pending=null}while(1)}null===x?m=k:x.next=p;e.baseState=m;e.baseQueue=x;Bg(l);a.expirationTime=l;a.memoizedState=k}}\nfunction Cg(a,b,c){a=b.effects;b.effects=null;if(null!==a)for(b=0;by?(A=m,m=null):A=m.sibling;var q=x(e,m,h[y],k);if(null===q){null===m&&(m=A);break}a&&\nm&&null===q.alternate&&b(e,m);g=f(q,g,y);null===t?l=q:t.sibling=q;t=q;m=A}if(y===h.length)return c(e,m),l;if(null===m){for(;yy?(A=t,t=null):A=t.sibling;var D=x(e,t,q.value,l);if(null===D){null===t&&(t=A);break}a&&t&&null===D.alternate&&b(e,t);g=f(D,g,y);null===m?k=D:m.sibling=D;m=D;t=A}if(q.done)return c(e,t),k;if(null===t){for(;!q.done;y++,q=h.next())q=p(e,q.value,l),null!==q&&(g=f(q,g,y),null===m?k=q:m.sibling=q,m=q);return k}for(t=d(e,t);!q.done;y++,q=h.next())q=z(t,e,y,q.value,l),null!==q&&(a&&null!==\nq.alternate&&t.delete(null===q.key?y:q.key),g=f(q,g,y),null===m?k=q:m.sibling=q,m=q);a&&t.forEach(function(a){return b(e,a)});return k}return function(a,d,f,h){var k=\"object\"===typeof f&&null!==f&&f.type===ab&&null===f.key;k&&(f=f.props.children);var l=\"object\"===typeof f&&null!==f;if(l)switch(f.$$typeof){case Za:a:{l=f.key;for(k=d;null!==k;){if(k.key===l){switch(k.tag){case 7:if(f.type===ab){c(a,k.sibling);d=e(k,f.props.children);d.return=a;a=d;break a}break;default:if(k.elementType===f.type){c(a,\nk.sibling);d=e(k,f.props);d.ref=Pg(a,k,f);d.return=a;a=d;break a}}c(a,k);break}else b(a,k);k=k.sibling}f.type===ab?(d=Wg(f.props.children,a.mode,h,f.key),d.return=a,a=d):(h=Ug(f.type,f.key,f.props,null,a.mode,h),h.ref=Pg(a,d,f),h.return=a,a=h)}return g(a);case $a:a:{for(k=f.key;null!==d;){if(d.key===k)if(4===d.tag&&d.stateNode.containerInfo===f.containerInfo&&d.stateNode.implementation===f.implementation){c(a,d.sibling);d=e(d,f.children||[]);d.return=a;a=d;break a}else{c(a,d);break}else b(a,d);d=\nd.sibling}d=Vg(f,a.mode,h);d.return=a;a=d}return g(a)}if(\"string\"===typeof f||\"number\"===typeof f)return f=\"\"+f,null!==d&&6===d.tag?(c(a,d.sibling),d=e(d,f),d.return=a,a=d):(c(a,d),d=Tg(f,a.mode,h),d.return=a,a=d),g(a);if(Og(f))return ca(a,d,f,h);if(nb(f))return D(a,d,f,h);l&&Qg(a,f);if(\"undefined\"===typeof f&&!k)switch(a.tag){case 1:case 0:throw a=a.type,Error(u(152,a.displayName||a.name||\"Component\"));}return c(a,d)}}var Xg=Rg(!0),Yg=Rg(!1),Zg={},$g={current:Zg},ah={current:Zg},bh={current:Zg};\nfunction ch(a){if(a===Zg)throw Error(u(174));return a}function dh(a,b){I(bh,b);I(ah,a);I($g,Zg);a=b.nodeType;switch(a){case 9:case 11:b=(b=b.documentElement)?b.namespaceURI:Ob(null,\"\");break;default:a=8===a?b.parentNode:b,b=a.namespaceURI||null,a=a.tagName,b=Ob(b,a)}H($g);I($g,b)}function eh(){H($g);H(ah);H(bh)}function fh(a){ch(bh.current);var b=ch($g.current);var c=Ob(b,a.type);b!==c&&(I(ah,a),I($g,c))}function gh(a){ah.current===a&&(H($g),H(ah))}var M={current:0};\nfunction hh(a){for(var b=a;null!==b;){if(13===b.tag){var c=b.memoizedState;if(null!==c&&(c=c.dehydrated,null===c||c.data===Bd||c.data===Cd))return b}else if(19===b.tag&&void 0!==b.memoizedProps.revealOrder){if(0!==(b.effectTag&64))return b}else if(null!==b.child){b.child.return=b;b=b.child;continue}if(b===a)break;for(;null===b.sibling;){if(null===b.return||b.return===a)return null;b=b.return}b.sibling.return=b.return;b=b.sibling}return null}function ih(a,b){return{responder:a,props:b}}\nvar jh=Wa.ReactCurrentDispatcher,kh=Wa.ReactCurrentBatchConfig,lh=0,N=null,O=null,P=null,mh=!1;function Q(){throw Error(u(321));}function nh(a,b){if(null===b)return!1;for(var c=0;cf))throw Error(u(301));f+=1;P=O=null;b.updateQueue=null;jh.current=rh;a=c(d,e)}while(b.expirationTime===lh)}jh.current=sh;b=null!==O&&null!==O.next;lh=0;P=O=N=null;mh=!1;if(b)throw Error(u(300));return a}\nfunction th(){var a={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};null===P?N.memoizedState=P=a:P=P.next=a;return P}function uh(){if(null===O){var a=N.alternate;a=null!==a?a.memoizedState:null}else a=O.next;var b=null===P?N.memoizedState:P.next;if(null!==b)P=b,O=a;else{if(null===a)throw Error(u(310));O=a;a={memoizedState:O.memoizedState,baseState:O.baseState,baseQueue:O.baseQueue,queue:O.queue,next:null};null===P?N.memoizedState=P=a:P=P.next=a}return P}\nfunction vh(a,b){return\"function\"===typeof b?b(a):b}\nfunction wh(a){var b=uh(),c=b.queue;if(null===c)throw Error(u(311));c.lastRenderedReducer=a;var d=O,e=d.baseQueue,f=c.pending;if(null!==f){if(null!==e){var g=e.next;e.next=f.next;f.next=g}d.baseQueue=e=f;c.pending=null}if(null!==e){e=e.next;d=d.baseState;var h=g=f=null,k=e;do{var l=k.expirationTime;if(lN.expirationTime&&\n(N.expirationTime=l,Bg(l))}else null!==h&&(h=h.next={expirationTime:1073741823,suspenseConfig:k.suspenseConfig,action:k.action,eagerReducer:k.eagerReducer,eagerState:k.eagerState,next:null}),Ag(l,k.suspenseConfig),d=k.eagerReducer===a?k.eagerState:a(d,k.action);k=k.next}while(null!==k&&k!==e);null===h?f=d:h.next=g;$e(d,b.memoizedState)||(rg=!0);b.memoizedState=d;b.baseState=f;b.baseQueue=h;c.lastRenderedState=d}return[b.memoizedState,c.dispatch]}\nfunction xh(a){var b=uh(),c=b.queue;if(null===c)throw Error(u(311));c.lastRenderedReducer=a;var d=c.dispatch,e=c.pending,f=b.memoizedState;if(null!==e){c.pending=null;var g=e=e.next;do f=a(f,g.action),g=g.next;while(g!==e);$e(f,b.memoizedState)||(rg=!0);b.memoizedState=f;null===b.baseQueue&&(b.baseState=f);c.lastRenderedState=f}return[f,d]}\nfunction yh(a){var b=th();\"function\"===typeof a&&(a=a());b.memoizedState=b.baseState=a;a=b.queue={pending:null,dispatch:null,lastRenderedReducer:vh,lastRenderedState:a};a=a.dispatch=zh.bind(null,N,a);return[b.memoizedState,a]}function Ah(a,b,c,d){a={tag:a,create:b,destroy:c,deps:d,next:null};b=N.updateQueue;null===b?(b={lastEffect:null},N.updateQueue=b,b.lastEffect=a.next=a):(c=b.lastEffect,null===c?b.lastEffect=a.next=a:(d=c.next,c.next=a,a.next=d,b.lastEffect=a));return a}\nfunction Bh(){return uh().memoizedState}function Ch(a,b,c,d){var e=th();N.effectTag|=a;e.memoizedState=Ah(1|b,c,void 0,void 0===d?null:d)}function Dh(a,b,c,d){var e=uh();d=void 0===d?null:d;var f=void 0;if(null!==O){var g=O.memoizedState;f=g.destroy;if(null!==d&&nh(d,g.deps)){Ah(b,c,f,d);return}}N.effectTag|=a;e.memoizedState=Ah(1|b,c,f,d)}function Eh(a,b){return Ch(516,4,a,b)}function Fh(a,b){return Dh(516,4,a,b)}function Gh(a,b){return Dh(4,2,a,b)}\nfunction Hh(a,b){if(\"function\"===typeof b)return a=a(),b(a),function(){b(null)};if(null!==b&&void 0!==b)return a=a(),b.current=a,function(){b.current=null}}function Ih(a,b,c){c=null!==c&&void 0!==c?c.concat([a]):null;return Dh(4,2,Hh.bind(null,b,a),c)}function Jh(){}function Kh(a,b){th().memoizedState=[a,void 0===b?null:b];return a}function Lh(a,b){var c=uh();b=void 0===b?null:b;var d=c.memoizedState;if(null!==d&&null!==b&&nh(b,d[1]))return d[0];c.memoizedState=[a,b];return a}\nfunction Mh(a,b){var c=uh();b=void 0===b?null:b;var d=c.memoizedState;if(null!==d&&null!==b&&nh(b,d[1]))return d[0];a=a();c.memoizedState=[a,b];return a}function Nh(a,b,c){var d=ag();cg(98>d?98:d,function(){a(!0)});cg(97\\x3c/script>\",a=a.removeChild(a.firstChild)):\"string\"===typeof d.is?a=g.createElement(e,{is:d.is}):(a=g.createElement(e),\"select\"===e&&(g=a,d.multiple?g.multiple=!0:d.size&&(g.size=d.size))):a=g.createElementNS(a,e);a[Md]=b;a[Nd]=d;ni(a,b,!1,!1);b.stateNode=a;g=pd(e,d);switch(e){case \"iframe\":case \"object\":case \"embed\":F(\"load\",\na);h=d;break;case \"video\":case \"audio\":for(h=0;hd.tailExpiration&&1b)&&tj.set(a,b)))}}\nfunction xj(a,b){a.expirationTimea?c:a;return 2>=a&&b!==a?0:a}\nfunction Z(a){if(0!==a.lastExpiredTime)a.callbackExpirationTime=1073741823,a.callbackPriority=99,a.callbackNode=eg(yj.bind(null,a));else{var b=zj(a),c=a.callbackNode;if(0===b)null!==c&&(a.callbackNode=null,a.callbackExpirationTime=0,a.callbackPriority=90);else{var d=Gg();1073741823===b?d=99:1===b||2===b?d=95:(d=10*(1073741821-b)-10*(1073741821-d),d=0>=d?99:250>=d?98:5250>=d?97:95);if(null!==c){var e=a.callbackPriority;if(a.callbackExpirationTime===b&&e>=d)return;c!==Tf&&Kf(c)}a.callbackExpirationTime=\nb;a.callbackPriority=d;b=1073741823===b?eg(yj.bind(null,a)):dg(d,Bj.bind(null,a),{timeout:10*(1073741821-b)-$f()});a.callbackNode=b}}}\nfunction Bj(a,b){wj=0;if(b)return b=Gg(),Cj(a,b),Z(a),null;var c=zj(a);if(0!==c){b=a.callbackNode;if((W&(fj|gj))!==V)throw Error(u(327));Dj();a===T&&c===U||Ej(a,c);if(null!==X){var d=W;W|=fj;var e=Fj();do try{Gj();break}catch(h){Hj(a,h)}while(1);ng();W=d;cj.current=e;if(S===hj)throw b=kj,Ej(a,c),xi(a,c),Z(a),b;if(null===X)switch(e=a.finishedWork=a.current.alternate,a.finishedExpirationTime=c,d=S,T=null,d){case ti:case hj:throw Error(u(345));case ij:Cj(a,2=c){a.lastPingedTime=c;Ej(a,c);break}}f=zj(a);if(0!==f&&f!==c)break;if(0!==d&&d!==c){a.lastPingedTime=d;break}a.timeoutHandle=Hd(Jj.bind(null,a),e);break}Jj(a);break;case vi:xi(a,c);d=a.lastSuspendedTime;c===d&&(a.nextKnownPendingLevel=Ij(e));if(oj&&(e=a.lastPingedTime,0===e||e>=c)){a.lastPingedTime=c;Ej(a,c);break}e=zj(a);if(0!==e&&e!==c)break;if(0!==d&&d!==c){a.lastPingedTime=\nd;break}1073741823!==mj?d=10*(1073741821-mj)-$f():1073741823===lj?d=0:(d=10*(1073741821-lj)-5E3,e=$f(),c=10*(1073741821-c)-e,d=e-d,0>d&&(d=0),d=(120>d?120:480>d?480:1080>d?1080:1920>d?1920:3E3>d?3E3:4320>d?4320:1960*bj(d/1960))-d,c=d?d=0:(e=g.busyDelayMs|0,f=$f()-(10*(1073741821-f)-(g.timeoutMs|0||5E3)),d=f<=e?0:e+d-f);if(10 component higher in the tree to provide a loading indicator or placeholder to display.\"+qb(g))}S!==\njj&&(S=ij);h=Ai(h,g);p=f;do{switch(p.tag){case 3:k=h;p.effectTag|=4096;p.expirationTime=b;var B=Xi(p,k,b);yg(p,B);break a;case 1:k=h;var w=p.type,ub=p.stateNode;if(0===(p.effectTag&64)&&(\"function\"===typeof w.getDerivedStateFromError||null!==ub&&\"function\"===typeof ub.componentDidCatch&&(null===aj||!aj.has(ub)))){p.effectTag|=4096;p.expirationTime=b;var vb=$i(p,k,b);yg(p,vb);break a}}p=p.return}while(null!==p)}X=Pj(X)}catch(Xc){b=Xc;continue}break}while(1)}\nfunction Fj(){var a=cj.current;cj.current=sh;return null===a?sh:a}function Ag(a,b){awi&&(wi=a)}function Kj(){for(;null!==X;)X=Qj(X)}function Gj(){for(;null!==X&&!Uf();)X=Qj(X)}function Qj(a){var b=Rj(a.alternate,a,U);a.memoizedProps=a.pendingProps;null===b&&(b=Pj(a));dj.current=null;return b}\nfunction Pj(a){X=a;do{var b=X.alternate;a=X.return;if(0===(X.effectTag&2048)){b=si(b,X,U);if(1===U||1!==X.childExpirationTime){for(var c=0,d=X.child;null!==d;){var e=d.expirationTime,f=d.childExpirationTime;e>c&&(c=e);f>c&&(c=f);d=d.sibling}X.childExpirationTime=c}if(null!==b)return b;null!==a&&0===(a.effectTag&2048)&&(null===a.firstEffect&&(a.firstEffect=X.firstEffect),null!==X.lastEffect&&(null!==a.lastEffect&&(a.lastEffect.nextEffect=X.firstEffect),a.lastEffect=X.lastEffect),1a?b:a}function Jj(a){var b=ag();cg(99,Sj.bind(null,a,b));return null}\nfunction Sj(a,b){do Dj();while(null!==rj);if((W&(fj|gj))!==V)throw Error(u(327));var c=a.finishedWork,d=a.finishedExpirationTime;if(null===c)return null;a.finishedWork=null;a.finishedExpirationTime=0;if(c===a.current)throw Error(u(177));a.callbackNode=null;a.callbackExpirationTime=0;a.callbackPriority=90;a.nextKnownPendingLevel=0;var e=Ij(c);a.firstPendingTime=e;d<=a.lastSuspendedTime?a.firstSuspendedTime=a.lastSuspendedTime=a.nextKnownPendingLevel=0:d<=a.firstSuspendedTime&&(a.firstSuspendedTime=\nd-1);d<=a.lastPingedTime&&(a.lastPingedTime=0);d<=a.lastExpiredTime&&(a.lastExpiredTime=0);a===T&&(X=T=null,U=0);1h&&(l=h,h=g,g=l),l=vd(q,g),m=vd(q,h),l&&m&&(1!==w.rangeCount||w.anchorNode!==l.node||w.anchorOffset!==l.offset||w.focusNode!==m.node||w.focusOffset!==m.offset)&&(B=B.createRange(),B.setStart(l.node,l.offset),w.removeAllRanges(),g>h?(w.addRange(B),w.extend(m.node,m.offset)):(B.setEnd(m.node,m.offset),w.addRange(B))))));B=[];for(w=q;w=w.parentNode;)1===w.nodeType&&B.push({element:w,left:w.scrollLeft,\ntop:w.scrollTop});\"function\"===typeof q.focus&&q.focus();for(q=0;q=c)return ji(a,b,c);I(M,M.current&1);b=$h(a,b,c);return null!==b?b.sibling:null}I(M,M.current&1);break;case 19:d=b.childExpirationTime>=c;if(0!==(a.effectTag&64)){if(d)return mi(a,b,c);b.effectTag|=64}e=b.memoizedState;null!==e&&(e.rendering=null,e.tail=null);I(M,M.current);if(!d)return null}return $h(a,b,c)}rg=!1}}else rg=!1;b.expirationTime=0;switch(b.tag){case 2:d=b.type;null!==a&&(a.alternate=null,b.alternate=null,b.effectTag|=2);a=b.pendingProps;e=Cf(b,J.current);qg(b,c);e=oh(null,\nb,d,a,e,c);b.effectTag|=1;if(\"object\"===typeof e&&null!==e&&\"function\"===typeof e.render&&void 0===e.$$typeof){b.tag=1;b.memoizedState=null;b.updateQueue=null;if(L(d)){var f=!0;Gf(b)}else f=!1;b.memoizedState=null!==e.state&&void 0!==e.state?e.state:null;ug(b);var g=d.getDerivedStateFromProps;\"function\"===typeof g&&Fg(b,d,g,a);e.updater=Jg;b.stateNode=e;e._reactInternalFiber=b;Ng(b,d,a,c);b=gi(null,b,d,!0,f,c)}else b.tag=0,R(null,b,e,c),b=b.child;return b;case 16:a:{e=b.elementType;null!==a&&(a.alternate=\nnull,b.alternate=null,b.effectTag|=2);a=b.pendingProps;ob(e);if(1!==e._status)throw e._result;e=e._result;b.type=e;f=b.tag=Xj(e);a=ig(e,a);switch(f){case 0:b=di(null,b,e,a,c);break a;case 1:b=fi(null,b,e,a,c);break a;case 11:b=Zh(null,b,e,a,c);break a;case 14:b=ai(null,b,e,ig(e.type,a),d,c);break a}throw Error(u(306,e,\"\"));}return b;case 0:return d=b.type,e=b.pendingProps,e=b.elementType===d?e:ig(d,e),di(a,b,d,e,c);case 1:return d=b.type,e=b.pendingProps,e=b.elementType===d?e:ig(d,e),fi(a,b,d,e,c);\ncase 3:hi(b);d=b.updateQueue;if(null===a||null===d)throw Error(u(282));d=b.pendingProps;e=b.memoizedState;e=null!==e?e.element:null;vg(a,b);zg(b,d,null,c);d=b.memoizedState.element;if(d===e)Xh(),b=$h(a,b,c);else{if(e=b.stateNode.hydrate)Ph=Jd(b.stateNode.containerInfo.firstChild),Oh=b,e=Qh=!0;if(e)for(c=Yg(b,null,d,c),b.child=c;c;)c.effectTag=c.effectTag&-3|1024,c=c.sibling;else R(a,b,d,c),Xh();b=b.child}return b;case 5:return fh(b),null===a&&Uh(b),d=b.type,e=b.pendingProps,f=null!==a?a.memoizedProps:\nnull,g=e.children,Gd(d,e)?g=null:null!==f&&Gd(d,f)&&(b.effectTag|=16),ei(a,b),b.mode&4&&1!==c&&e.hidden?(b.expirationTime=b.childExpirationTime=1,b=null):(R(a,b,g,c),b=b.child),b;case 6:return null===a&&Uh(b),null;case 13:return ji(a,b,c);case 4:return dh(b,b.stateNode.containerInfo),d=b.pendingProps,null===a?b.child=Xg(b,null,d,c):R(a,b,d,c),b.child;case 11:return d=b.type,e=b.pendingProps,e=b.elementType===d?e:ig(d,e),Zh(a,b,d,e,c);case 7:return R(a,b,b.pendingProps,c),b.child;case 8:return R(a,\nb,b.pendingProps.children,c),b.child;case 12:return R(a,b,b.pendingProps.children,c),b.child;case 10:a:{d=b.type._context;e=b.pendingProps;g=b.memoizedProps;f=e.value;var h=b.type._context;I(jg,h._currentValue);h._currentValue=f;if(null!==g)if(h=g.value,f=$e(h,f)?0:(\"function\"===typeof d._calculateChangedBits?d._calculateChangedBits(h,f):1073741823)|0,0===f){if(g.children===e.children&&!K.current){b=$h(a,b,c);break a}}else for(h=b.child,null!==h&&(h.return=b);null!==h;){var k=h.dependencies;if(null!==\nk){g=h.child;for(var l=k.firstContext;null!==l;){if(l.context===d&&0!==(l.observedBits&f)){1===h.tag&&(l=wg(c,null),l.tag=2,xg(h,l));h.expirationTime=b&&a<=b}function xi(a,b){var c=a.firstSuspendedTime,d=a.lastSuspendedTime;cb||0===c)a.lastSuspendedTime=b;b<=a.lastPingedTime&&(a.lastPingedTime=0);b<=a.lastExpiredTime&&(a.lastExpiredTime=0)}\nfunction yi(a,b){b>a.firstPendingTime&&(a.firstPendingTime=b);var c=a.firstSuspendedTime;0!==c&&(b>=c?a.firstSuspendedTime=a.lastSuspendedTime=a.nextKnownPendingLevel=0:b>=a.lastSuspendedTime&&(a.lastSuspendedTime=b+1),b>a.nextKnownPendingLevel&&(a.nextKnownPendingLevel=b))}function Cj(a,b){var c=a.lastExpiredTime;if(0===c||c>b)a.lastExpiredTime=b}\nfunction bk(a,b,c,d){var e=b.current,f=Gg(),g=Dg.suspense;f=Hg(f,e,g);a:if(c){c=c._reactInternalFiber;b:{if(dc(c)!==c||1!==c.tag)throw Error(u(170));var h=c;do{switch(h.tag){case 3:h=h.stateNode.context;break b;case 1:if(L(h.type)){h=h.stateNode.__reactInternalMemoizedMergedChildContext;break b}}h=h.return}while(null!==h);throw Error(u(171));}if(1===c.tag){var k=c.type;if(L(k)){c=Ff(c,k,h);break a}}c=h}else c=Af;null===b.context?b.context=c:b.pendingContext=c;b=wg(f,g);b.payload={element:a};d=void 0===\nd?null:d;null!==d&&(b.callback=d);xg(e,b);Ig(e,f);return f}function ck(a){a=a.current;if(!a.child)return null;switch(a.child.tag){case 5:return a.child.stateNode;default:return a.child.stateNode}}function dk(a,b){a=a.memoizedState;null!==a&&null!==a.dehydrated&&a.retryTime=G};l=function(){};exports.unstable_forceFrameRate=function(a){0>a||125>>1,e=a[d];if(void 0!==e&&0K(n,c))void 0!==r&&0>K(r,n)?(a[d]=r,a[v]=c,d=v):(a[d]=n,a[m]=c,d=m);else if(void 0!==r&&0>K(r,c))a[d]=r,a[v]=c,d=v;else break a}}return b}return null}function K(a,b){var c=a.sortIndex-b.sortIndex;return 0!==c?c:a.id-b.id}var N=[],O=[],P=1,Q=null,R=3,S=!1,T=!1,U=!1;\nfunction V(a){for(var b=L(O);null!==b;){if(null===b.callback)M(O);else if(b.startTime<=a)M(O),b.sortIndex=b.expirationTime,J(N,b);else break;b=L(O)}}function W(a){U=!1;V(a);if(!T)if(null!==L(N))T=!0,f(X);else{var b=L(O);null!==b&&g(W,b.startTime-a)}}\nfunction X(a,b){T=!1;U&&(U=!1,h());S=!0;var c=R;try{V(b);for(Q=L(N);null!==Q&&(!(Q.expirationTime>b)||a&&!k());){var d=Q.callback;if(null!==d){Q.callback=null;R=Q.priorityLevel;var e=d(Q.expirationTime<=b);b=exports.unstable_now();\"function\"===typeof e?Q.callback=e:Q===L(N)&&M(N);V(b)}else M(N);Q=L(N)}if(null!==Q)var m=!0;else{var n=L(O);null!==n&&g(W,n.startTime-b);m=!1}return m}finally{Q=null,R=c,S=!1}}\nfunction Y(a){switch(a){case 1:return-1;case 2:return 250;case 5:return 1073741823;case 4:return 1E4;default:return 5E3}}var Z=l;exports.unstable_IdlePriority=5;exports.unstable_ImmediatePriority=1;exports.unstable_LowPriority=4;exports.unstable_NormalPriority=3;exports.unstable_Profiling=null;exports.unstable_UserBlockingPriority=2;exports.unstable_cancelCallback=function(a){a.callback=null};exports.unstable_continueExecution=function(){T||S||(T=!0,f(X))};\nexports.unstable_getCurrentPriorityLevel=function(){return R};exports.unstable_getFirstCallbackNode=function(){return L(N)};exports.unstable_next=function(a){switch(R){case 1:case 2:case 3:var b=3;break;default:b=R}var c=R;R=b;try{return a()}finally{R=c}};exports.unstable_pauseExecution=function(){};exports.unstable_requestPaint=Z;exports.unstable_runWithPriority=function(a,b){switch(a){case 1:case 2:case 3:case 4:case 5:break;default:a=3}var c=R;R=a;try{return b()}finally{R=c}};\nexports.unstable_scheduleCallback=function(a,b,c){var d=exports.unstable_now();if(\"object\"===typeof c&&null!==c){var e=c.delay;e=\"number\"===typeof e&&0d?(a.sortIndex=e,J(O,a),null===L(N)&&a===L(O)&&(U?h():U=!0,g(W,e-d))):(a.sortIndex=c,J(N,a),T||S||(T=!0,f(X)));return a};\nexports.unstable_shouldYield=function(){var a=exports.unstable_now();V(a);var b=L(N);return b!==Q&&null!==Q&&null!==b&&null!==b.callback&&b.startTime<=a&&b.expirationTime://\" or \"//\" (protocol-relative URL).\n // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed\n // by any combination of letters, digits, plus, period, or hyphen.\n return /^([a-z][a-z\\d\\+\\-\\.]*:)?\\/\\//i.test(url);\n};\n","'use strict';\n\n/**\n * Creates a new URL by combining the specified URLs\n *\n * @param {string} baseURL The base URL\n * @param {string} relativeURL The relative URL\n * @returns {string} The combined URL\n */\nmodule.exports = function combineURLs(baseURL, relativeURL) {\n return relativeURL\n ? baseURL.replace(/\\/+$/, '') + '/' + relativeURL.replace(/^\\/+/, '')\n : baseURL;\n};\n","'use strict';\n\nvar utils = require('./../utils');\n\n// Headers whose duplicates are ignored by node\n// c.f. https://nodejs.org/api/http.html#http_message_headers\nvar ignoreDuplicateOf = [\n 'age', 'authorization', 'content-length', 'content-type', 'etag',\n 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since',\n 'last-modified', 'location', 'max-forwards', 'proxy-authorization',\n 'referer', 'retry-after', 'user-agent'\n];\n\n/**\n * Parse headers into an object\n *\n * ```\n * Date: Wed, 27 Aug 2014 08:58:49 GMT\n * Content-Type: application/json\n * Connection: keep-alive\n * Transfer-Encoding: chunked\n * ```\n *\n * @param {String} headers Headers needing to be parsed\n * @returns {Object} Headers parsed into an object\n */\nmodule.exports = function parseHeaders(headers) {\n var parsed = {};\n var key;\n var val;\n var i;\n\n if (!headers) { return parsed; }\n\n utils.forEach(headers.split('\\n'), function parser(line) {\n i = line.indexOf(':');\n key = utils.trim(line.substr(0, i)).toLowerCase();\n val = utils.trim(line.substr(i + 1));\n\n if (key) {\n if (parsed[key] && ignoreDuplicateOf.indexOf(key) >= 0) {\n return;\n }\n if (key === 'set-cookie') {\n parsed[key] = (parsed[key] ? parsed[key] : []).concat([val]);\n } else {\n parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;\n }\n }\n });\n\n return parsed;\n};\n","'use strict';\n\nvar utils = require('./../utils');\n\nmodule.exports = (\n utils.isStandardBrowserEnv() ?\n\n // Standard browser envs have full support of the APIs needed to test\n // whether the request URL is of the same origin as current location.\n (function standardBrowserEnv() {\n var msie = /(msie|trident)/i.test(navigator.userAgent);\n var urlParsingNode = document.createElement('a');\n var originURL;\n\n /**\n * Parse a URL to discover it's components\n *\n * @param {String} url The URL to be parsed\n * @returns {Object}\n */\n function resolveURL(url) {\n var href = url;\n\n if (msie) {\n // IE needs attribute set twice to normalize properties\n urlParsingNode.setAttribute('href', href);\n href = urlParsingNode.href;\n }\n\n urlParsingNode.setAttribute('href', href);\n\n // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils\n return {\n href: urlParsingNode.href,\n protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '',\n host: urlParsingNode.host,\n search: urlParsingNode.search ? urlParsingNode.search.replace(/^\\?/, '') : '',\n hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '',\n hostname: urlParsingNode.hostname,\n port: urlParsingNode.port,\n pathname: (urlParsingNode.pathname.charAt(0) === '/') ?\n urlParsingNode.pathname :\n '/' + urlParsingNode.pathname\n };\n }\n\n originURL = resolveURL(window.location.href);\n\n /**\n * Determine if a URL shares the same origin as the current location\n *\n * @param {String} requestURL The URL to test\n * @returns {boolean} True if URL shares the same origin, otherwise false\n */\n return function isURLSameOrigin(requestURL) {\n var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL;\n return (parsed.protocol === originURL.protocol &&\n parsed.host === originURL.host);\n };\n })() :\n\n // Non standard browser envs (web workers, react-native) lack needed support.\n (function nonStandardBrowserEnv() {\n return function isURLSameOrigin() {\n return true;\n };\n })()\n);\n","'use strict';\n\nvar utils = require('./../utils');\n\nmodule.exports = (\n utils.isStandardBrowserEnv() ?\n\n // Standard browser envs support document.cookie\n (function standardBrowserEnv() {\n return {\n write: function write(name, value, expires, path, domain, secure) {\n var cookie = [];\n cookie.push(name + '=' + encodeURIComponent(value));\n\n if (utils.isNumber(expires)) {\n cookie.push('expires=' + new Date(expires).toGMTString());\n }\n\n if (utils.isString(path)) {\n cookie.push('path=' + path);\n }\n\n if (utils.isString(domain)) {\n cookie.push('domain=' + domain);\n }\n\n if (secure === true) {\n cookie.push('secure');\n }\n\n document.cookie = cookie.join('; ');\n },\n\n read: function read(name) {\n var match = document.cookie.match(new RegExp('(^|;\\\\s*)(' + name + ')=([^;]*)'));\n return (match ? decodeURIComponent(match[3]) : null);\n },\n\n remove: function remove(name) {\n this.write(name, '', Date.now() - 86400000);\n }\n };\n })() :\n\n // Non standard browser env (web workers, react-native) lack needed support.\n (function nonStandardBrowserEnv() {\n return {\n write: function write() {},\n read: function read() { return null; },\n remove: function remove() {}\n };\n })()\n);\n","'use strict';\n\nvar Cancel = require('./Cancel');\n\n/**\n * A `CancelToken` is an object that can be used to request cancellation of an operation.\n *\n * @class\n * @param {Function} executor The executor function.\n */\nfunction CancelToken(executor) {\n if (typeof executor !== 'function') {\n throw new TypeError('executor must be a function.');\n }\n\n var resolvePromise;\n this.promise = new Promise(function promiseExecutor(resolve) {\n resolvePromise = resolve;\n });\n\n var token = this;\n executor(function cancel(message) {\n if (token.reason) {\n // Cancellation has already been requested\n return;\n }\n\n token.reason = new Cancel(message);\n resolvePromise(token.reason);\n });\n}\n\n/**\n * Throws a `Cancel` if cancellation has been requested.\n */\nCancelToken.prototype.throwIfRequested = function throwIfRequested() {\n if (this.reason) {\n throw this.reason;\n }\n};\n\n/**\n * Returns an object that contains a new `CancelToken` and a function that, when called,\n * cancels the `CancelToken`.\n */\nCancelToken.source = function source() {\n var cancel;\n var token = new CancelToken(function executor(c) {\n cancel = c;\n });\n return {\n token: token,\n cancel: cancel\n };\n};\n\nmodule.exports = CancelToken;\n","'use strict';\n\n/**\n * Syntactic sugar for invoking a function and expanding an array for arguments.\n *\n * Common use case would be to use `Function.prototype.apply`.\n *\n * ```js\n * function f(x, y, z) {}\n * var args = [1, 2, 3];\n * f.apply(null, args);\n * ```\n *\n * With `spread` this example can be re-written.\n *\n * ```js\n * spread(function(x, y, z) {})([1, 2, 3]);\n * ```\n *\n * @param {Function} callback\n * @returns {Function}\n */\nmodule.exports = function spread(callback) {\n return function wrap(arr) {\n return callback.apply(null, arr);\n };\n};\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _InfoCircleFilled = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/InfoCircleFilled\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar InfoCircleFilled = function InfoCircleFilled(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _InfoCircleFilled.default\n }));\n};\n\nInfoCircleFilled.displayName = 'InfoCircleFilled';\n\nvar _default = React.forwardRef(InfoCircleFilled);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar InfoCircleFilled = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z\" } }] }, \"name\": \"info-circle\", \"theme\": \"filled\" };\nexports.default = InfoCircleFilled;\n","function _iterableToArrayLimit(arr, i) {\n if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n var _e = undefined;\n\n try {\n for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n}\n\nmodule.exports = _iterableToArrayLimit;","function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n\n return target;\n}\n\nmodule.exports = _objectWithoutPropertiesLoose;","\"use strict\";\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar tinycolor2_1 = __importDefault(require(\"tinycolor2\"));\nvar hueStep = 2; // 色相阶梯\nvar saturationStep = 16; // 饱和度阶梯,浅色部分\nvar saturationStep2 = 5; // 饱和度阶梯,深色部分\nvar brightnessStep1 = 5; // 亮度阶梯,浅色部分\nvar brightnessStep2 = 15; // 亮度阶梯,深色部分\nvar lightColorCount = 5; // 浅色数量,主色上\nvar darkColorCount = 4; // 深色数量,主色下\nfunction getHue(hsv, i, light) {\n var hue;\n // 根据色相不同,色相转向不同\n if (Math.round(hsv.h) >= 60 && Math.round(hsv.h) <= 240) {\n hue = light ? Math.round(hsv.h) - hueStep * i : Math.round(hsv.h) + hueStep * i;\n }\n else {\n hue = light ? Math.round(hsv.h) + hueStep * i : Math.round(hsv.h) - hueStep * i;\n }\n if (hue < 0) {\n hue += 360;\n }\n else if (hue >= 360) {\n hue -= 360;\n }\n return hue;\n}\nfunction getSaturation(hsv, i, light) {\n // grey color don't change saturation\n if (hsv.h === 0 && hsv.s === 0) {\n return hsv.s;\n }\n var saturation;\n if (light) {\n saturation = Math.round(hsv.s * 100) - saturationStep * i;\n }\n else if (i === darkColorCount) {\n saturation = Math.round(hsv.s * 100) + saturationStep;\n }\n else {\n saturation = Math.round(hsv.s * 100) + saturationStep2 * i;\n }\n // 边界值修正\n if (saturation > 100) {\n saturation = 100;\n }\n // 第一格的 s 限制在 6-10 之间\n if (light && i === lightColorCount && saturation > 10) {\n saturation = 10;\n }\n if (saturation < 6) {\n saturation = 6;\n }\n return saturation;\n}\nfunction getValue(hsv, i, light) {\n if (light) {\n return Math.round(hsv.v * 100) + brightnessStep1 * i;\n }\n return Math.round(hsv.v * 100) - brightnessStep2 * i;\n}\nfunction generate(color) {\n var patterns = [];\n var pColor = tinycolor2_1.default(color);\n for (var i = lightColorCount; i > 0; i -= 1) {\n var hsv = pColor.toHsv();\n var colorString = tinycolor2_1.default({\n h: getHue(hsv, i, true),\n s: getSaturation(hsv, i, true),\n v: getValue(hsv, i, true),\n }).toHexString();\n patterns.push(colorString);\n }\n patterns.push(pColor.toHexString());\n for (var i = 1; i <= darkColorCount; i += 1) {\n var hsv = pColor.toHsv();\n var colorString = tinycolor2_1.default({\n h: getHue(hsv, i),\n s: getSaturation(hsv, i),\n v: getValue(hsv, i),\n }).toHexString();\n patterns.push(colorString);\n }\n return patterns;\n}\nexports.default = generate;\n","// TinyColor v1.4.1\n// https://github.com/bgrins/TinyColor\n// Brian Grinstead, MIT License\n\n(function(Math) {\n\nvar trimLeft = /^\\s+/,\n trimRight = /\\s+$/,\n tinyCounter = 0,\n mathRound = Math.round,\n mathMin = Math.min,\n mathMax = Math.max,\n mathRandom = Math.random;\n\nfunction tinycolor (color, opts) {\n\n color = (color) ? color : '';\n opts = opts || { };\n\n // If input is already a tinycolor, return itself\n if (color instanceof tinycolor) {\n return color;\n }\n // If we are called as a function, call using new instead\n if (!(this instanceof tinycolor)) {\n return new tinycolor(color, opts);\n }\n\n var rgb = inputToRGB(color);\n this._originalInput = color,\n this._r = rgb.r,\n this._g = rgb.g,\n this._b = rgb.b,\n this._a = rgb.a,\n this._roundA = mathRound(100*this._a) / 100,\n this._format = opts.format || rgb.format;\n this._gradientType = opts.gradientType;\n\n // Don't let the range of [0,255] come back in [0,1].\n // Potentially lose a little bit of precision here, but will fix issues where\n // .5 gets interpreted as half of the total, instead of half of 1\n // If it was supposed to be 128, this was already taken care of by `inputToRgb`\n if (this._r < 1) { this._r = mathRound(this._r); }\n if (this._g < 1) { this._g = mathRound(this._g); }\n if (this._b < 1) { this._b = mathRound(this._b); }\n\n this._ok = rgb.ok;\n this._tc_id = tinyCounter++;\n}\n\ntinycolor.prototype = {\n isDark: function() {\n return this.getBrightness() < 128;\n },\n isLight: function() {\n return !this.isDark();\n },\n isValid: function() {\n return this._ok;\n },\n getOriginalInput: function() {\n return this._originalInput;\n },\n getFormat: function() {\n return this._format;\n },\n getAlpha: function() {\n return this._a;\n },\n getBrightness: function() {\n //http://www.w3.org/TR/AERT#color-contrast\n var rgb = this.toRgb();\n return (rgb.r * 299 + rgb.g * 587 + rgb.b * 114) / 1000;\n },\n getLuminance: function() {\n //http://www.w3.org/TR/2008/REC-WCAG20-20081211/#relativeluminancedef\n var rgb = this.toRgb();\n var RsRGB, GsRGB, BsRGB, R, G, B;\n RsRGB = rgb.r/255;\n GsRGB = rgb.g/255;\n BsRGB = rgb.b/255;\n\n if (RsRGB <= 0.03928) {R = RsRGB / 12.92;} else {R = Math.pow(((RsRGB + 0.055) / 1.055), 2.4);}\n if (GsRGB <= 0.03928) {G = GsRGB / 12.92;} else {G = Math.pow(((GsRGB + 0.055) / 1.055), 2.4);}\n if (BsRGB <= 0.03928) {B = BsRGB / 12.92;} else {B = Math.pow(((BsRGB + 0.055) / 1.055), 2.4);}\n return (0.2126 * R) + (0.7152 * G) + (0.0722 * B);\n },\n setAlpha: function(value) {\n this._a = boundAlpha(value);\n this._roundA = mathRound(100*this._a) / 100;\n return this;\n },\n toHsv: function() {\n var hsv = rgbToHsv(this._r, this._g, this._b);\n return { h: hsv.h * 360, s: hsv.s, v: hsv.v, a: this._a };\n },\n toHsvString: function() {\n var hsv = rgbToHsv(this._r, this._g, this._b);\n var h = mathRound(hsv.h * 360), s = mathRound(hsv.s * 100), v = mathRound(hsv.v * 100);\n return (this._a == 1) ?\n \"hsv(\" + h + \", \" + s + \"%, \" + v + \"%)\" :\n \"hsva(\" + h + \", \" + s + \"%, \" + v + \"%, \"+ this._roundA + \")\";\n },\n toHsl: function() {\n var hsl = rgbToHsl(this._r, this._g, this._b);\n return { h: hsl.h * 360, s: hsl.s, l: hsl.l, a: this._a };\n },\n toHslString: function() {\n var hsl = rgbToHsl(this._r, this._g, this._b);\n var h = mathRound(hsl.h * 360), s = mathRound(hsl.s * 100), l = mathRound(hsl.l * 100);\n return (this._a == 1) ?\n \"hsl(\" + h + \", \" + s + \"%, \" + l + \"%)\" :\n \"hsla(\" + h + \", \" + s + \"%, \" + l + \"%, \"+ this._roundA + \")\";\n },\n toHex: function(allow3Char) {\n return rgbToHex(this._r, this._g, this._b, allow3Char);\n },\n toHexString: function(allow3Char) {\n return '#' + this.toHex(allow3Char);\n },\n toHex8: function(allow4Char) {\n return rgbaToHex(this._r, this._g, this._b, this._a, allow4Char);\n },\n toHex8String: function(allow4Char) {\n return '#' + this.toHex8(allow4Char);\n },\n toRgb: function() {\n return { r: mathRound(this._r), g: mathRound(this._g), b: mathRound(this._b), a: this._a };\n },\n toRgbString: function() {\n return (this._a == 1) ?\n \"rgb(\" + mathRound(this._r) + \", \" + mathRound(this._g) + \", \" + mathRound(this._b) + \")\" :\n \"rgba(\" + mathRound(this._r) + \", \" + mathRound(this._g) + \", \" + mathRound(this._b) + \", \" + this._roundA + \")\";\n },\n toPercentageRgb: function() {\n return { r: mathRound(bound01(this._r, 255) * 100) + \"%\", g: mathRound(bound01(this._g, 255) * 100) + \"%\", b: mathRound(bound01(this._b, 255) * 100) + \"%\", a: this._a };\n },\n toPercentageRgbString: function() {\n return (this._a == 1) ?\n \"rgb(\" + mathRound(bound01(this._r, 255) * 100) + \"%, \" + mathRound(bound01(this._g, 255) * 100) + \"%, \" + mathRound(bound01(this._b, 255) * 100) + \"%)\" :\n \"rgba(\" + mathRound(bound01(this._r, 255) * 100) + \"%, \" + mathRound(bound01(this._g, 255) * 100) + \"%, \" + mathRound(bound01(this._b, 255) * 100) + \"%, \" + this._roundA + \")\";\n },\n toName: function() {\n if (this._a === 0) {\n return \"transparent\";\n }\n\n if (this._a < 1) {\n return false;\n }\n\n return hexNames[rgbToHex(this._r, this._g, this._b, true)] || false;\n },\n toFilter: function(secondColor) {\n var hex8String = '#' + rgbaToArgbHex(this._r, this._g, this._b, this._a);\n var secondHex8String = hex8String;\n var gradientType = this._gradientType ? \"GradientType = 1, \" : \"\";\n\n if (secondColor) {\n var s = tinycolor(secondColor);\n secondHex8String = '#' + rgbaToArgbHex(s._r, s._g, s._b, s._a);\n }\n\n return \"progid:DXImageTransform.Microsoft.gradient(\"+gradientType+\"startColorstr=\"+hex8String+\",endColorstr=\"+secondHex8String+\")\";\n },\n toString: function(format) {\n var formatSet = !!format;\n format = format || this._format;\n\n var formattedString = false;\n var hasAlpha = this._a < 1 && this._a >= 0;\n var needsAlphaFormat = !formatSet && hasAlpha && (format === \"hex\" || format === \"hex6\" || format === \"hex3\" || format === \"hex4\" || format === \"hex8\" || format === \"name\");\n\n if (needsAlphaFormat) {\n // Special case for \"transparent\", all other non-alpha formats\n // will return rgba when there is transparency.\n if (format === \"name\" && this._a === 0) {\n return this.toName();\n }\n return this.toRgbString();\n }\n if (format === \"rgb\") {\n formattedString = this.toRgbString();\n }\n if (format === \"prgb\") {\n formattedString = this.toPercentageRgbString();\n }\n if (format === \"hex\" || format === \"hex6\") {\n formattedString = this.toHexString();\n }\n if (format === \"hex3\") {\n formattedString = this.toHexString(true);\n }\n if (format === \"hex4\") {\n formattedString = this.toHex8String(true);\n }\n if (format === \"hex8\") {\n formattedString = this.toHex8String();\n }\n if (format === \"name\") {\n formattedString = this.toName();\n }\n if (format === \"hsl\") {\n formattedString = this.toHslString();\n }\n if (format === \"hsv\") {\n formattedString = this.toHsvString();\n }\n\n return formattedString || this.toHexString();\n },\n clone: function() {\n return tinycolor(this.toString());\n },\n\n _applyModification: function(fn, args) {\n var color = fn.apply(null, [this].concat([].slice.call(args)));\n this._r = color._r;\n this._g = color._g;\n this._b = color._b;\n this.setAlpha(color._a);\n return this;\n },\n lighten: function() {\n return this._applyModification(lighten, arguments);\n },\n brighten: function() {\n return this._applyModification(brighten, arguments);\n },\n darken: function() {\n return this._applyModification(darken, arguments);\n },\n desaturate: function() {\n return this._applyModification(desaturate, arguments);\n },\n saturate: function() {\n return this._applyModification(saturate, arguments);\n },\n greyscale: function() {\n return this._applyModification(greyscale, arguments);\n },\n spin: function() {\n return this._applyModification(spin, arguments);\n },\n\n _applyCombination: function(fn, args) {\n return fn.apply(null, [this].concat([].slice.call(args)));\n },\n analogous: function() {\n return this._applyCombination(analogous, arguments);\n },\n complement: function() {\n return this._applyCombination(complement, arguments);\n },\n monochromatic: function() {\n return this._applyCombination(monochromatic, arguments);\n },\n splitcomplement: function() {\n return this._applyCombination(splitcomplement, arguments);\n },\n triad: function() {\n return this._applyCombination(triad, arguments);\n },\n tetrad: function() {\n return this._applyCombination(tetrad, arguments);\n }\n};\n\n// If input is an object, force 1 into \"1.0\" to handle ratios properly\n// String input requires \"1.0\" as input, so 1 will be treated as 1\ntinycolor.fromRatio = function(color, opts) {\n if (typeof color == \"object\") {\n var newColor = {};\n for (var i in color) {\n if (color.hasOwnProperty(i)) {\n if (i === \"a\") {\n newColor[i] = color[i];\n }\n else {\n newColor[i] = convertToPercentage(color[i]);\n }\n }\n }\n color = newColor;\n }\n\n return tinycolor(color, opts);\n};\n\n// Given a string or object, convert that input to RGB\n// Possible string inputs:\n//\n// \"red\"\n// \"#f00\" or \"f00\"\n// \"#ff0000\" or \"ff0000\"\n// \"#ff000000\" or \"ff000000\"\n// \"rgb 255 0 0\" or \"rgb (255, 0, 0)\"\n// \"rgb 1.0 0 0\" or \"rgb (1, 0, 0)\"\n// \"rgba (255, 0, 0, 1)\" or \"rgba 255, 0, 0, 1\"\n// \"rgba (1.0, 0, 0, 1)\" or \"rgba 1.0, 0, 0, 1\"\n// \"hsl(0, 100%, 50%)\" or \"hsl 0 100% 50%\"\n// \"hsla(0, 100%, 50%, 1)\" or \"hsla 0 100% 50%, 1\"\n// \"hsv(0, 100%, 100%)\" or \"hsv 0 100% 100%\"\n//\nfunction inputToRGB(color) {\n\n var rgb = { r: 0, g: 0, b: 0 };\n var a = 1;\n var s = null;\n var v = null;\n var l = null;\n var ok = false;\n var format = false;\n\n if (typeof color == \"string\") {\n color = stringInputToObject(color);\n }\n\n if (typeof color == \"object\") {\n if (isValidCSSUnit(color.r) && isValidCSSUnit(color.g) && isValidCSSUnit(color.b)) {\n rgb = rgbToRgb(color.r, color.g, color.b);\n ok = true;\n format = String(color.r).substr(-1) === \"%\" ? \"prgb\" : \"rgb\";\n }\n else if (isValidCSSUnit(color.h) && isValidCSSUnit(color.s) && isValidCSSUnit(color.v)) {\n s = convertToPercentage(color.s);\n v = convertToPercentage(color.v);\n rgb = hsvToRgb(color.h, s, v);\n ok = true;\n format = \"hsv\";\n }\n else if (isValidCSSUnit(color.h) && isValidCSSUnit(color.s) && isValidCSSUnit(color.l)) {\n s = convertToPercentage(color.s);\n l = convertToPercentage(color.l);\n rgb = hslToRgb(color.h, s, l);\n ok = true;\n format = \"hsl\";\n }\n\n if (color.hasOwnProperty(\"a\")) {\n a = color.a;\n }\n }\n\n a = boundAlpha(a);\n\n return {\n ok: ok,\n format: color.format || format,\n r: mathMin(255, mathMax(rgb.r, 0)),\n g: mathMin(255, mathMax(rgb.g, 0)),\n b: mathMin(255, mathMax(rgb.b, 0)),\n a: a\n };\n}\n\n\n// Conversion Functions\n// --------------------\n\n// `rgbToHsl`, `rgbToHsv`, `hslToRgb`, `hsvToRgb` modified from:\n// \n\n// `rgbToRgb`\n// Handle bounds / percentage checking to conform to CSS color spec\n// \n// *Assumes:* r, g, b in [0, 255] or [0, 1]\n// *Returns:* { r, g, b } in [0, 255]\nfunction rgbToRgb(r, g, b){\n return {\n r: bound01(r, 255) * 255,\n g: bound01(g, 255) * 255,\n b: bound01(b, 255) * 255\n };\n}\n\n// `rgbToHsl`\n// Converts an RGB color value to HSL.\n// *Assumes:* r, g, and b are contained in [0, 255] or [0, 1]\n// *Returns:* { h, s, l } in [0,1]\nfunction rgbToHsl(r, g, b) {\n\n r = bound01(r, 255);\n g = bound01(g, 255);\n b = bound01(b, 255);\n\n var max = mathMax(r, g, b), min = mathMin(r, g, b);\n var h, s, l = (max + min) / 2;\n\n if(max == min) {\n h = s = 0; // achromatic\n }\n else {\n var d = max - min;\n s = l > 0.5 ? d / (2 - max - min) : d / (max + min);\n switch(max) {\n case r: h = (g - b) / d + (g < b ? 6 : 0); break;\n case g: h = (b - r) / d + 2; break;\n case b: h = (r - g) / d + 4; break;\n }\n\n h /= 6;\n }\n\n return { h: h, s: s, l: l };\n}\n\n// `hslToRgb`\n// Converts an HSL color value to RGB.\n// *Assumes:* h is contained in [0, 1] or [0, 360] and s and l are contained [0, 1] or [0, 100]\n// *Returns:* { r, g, b } in the set [0, 255]\nfunction hslToRgb(h, s, l) {\n var r, g, b;\n\n h = bound01(h, 360);\n s = bound01(s, 100);\n l = bound01(l, 100);\n\n function hue2rgb(p, q, t) {\n if(t < 0) t += 1;\n if(t > 1) t -= 1;\n if(t < 1/6) return p + (q - p) * 6 * t;\n if(t < 1/2) return q;\n if(t < 2/3) return p + (q - p) * (2/3 - t) * 6;\n return p;\n }\n\n if(s === 0) {\n r = g = b = l; // achromatic\n }\n else {\n var q = l < 0.5 ? l * (1 + s) : l + s - l * s;\n var p = 2 * l - q;\n r = hue2rgb(p, q, h + 1/3);\n g = hue2rgb(p, q, h);\n b = hue2rgb(p, q, h - 1/3);\n }\n\n return { r: r * 255, g: g * 255, b: b * 255 };\n}\n\n// `rgbToHsv`\n// Converts an RGB color value to HSV\n// *Assumes:* r, g, and b are contained in the set [0, 255] or [0, 1]\n// *Returns:* { h, s, v } in [0,1]\nfunction rgbToHsv(r, g, b) {\n\n r = bound01(r, 255);\n g = bound01(g, 255);\n b = bound01(b, 255);\n\n var max = mathMax(r, g, b), min = mathMin(r, g, b);\n var h, s, v = max;\n\n var d = max - min;\n s = max === 0 ? 0 : d / max;\n\n if(max == min) {\n h = 0; // achromatic\n }\n else {\n switch(max) {\n case r: h = (g - b) / d + (g < b ? 6 : 0); break;\n case g: h = (b - r) / d + 2; break;\n case b: h = (r - g) / d + 4; break;\n }\n h /= 6;\n }\n return { h: h, s: s, v: v };\n}\n\n// `hsvToRgb`\n// Converts an HSV color value to RGB.\n// *Assumes:* h is contained in [0, 1] or [0, 360] and s and v are contained in [0, 1] or [0, 100]\n// *Returns:* { r, g, b } in the set [0, 255]\n function hsvToRgb(h, s, v) {\n\n h = bound01(h, 360) * 6;\n s = bound01(s, 100);\n v = bound01(v, 100);\n\n var i = Math.floor(h),\n f = h - i,\n p = v * (1 - s),\n q = v * (1 - f * s),\n t = v * (1 - (1 - f) * s),\n mod = i % 6,\n r = [v, q, p, p, t, v][mod],\n g = [t, v, v, q, p, p][mod],\n b = [p, p, t, v, v, q][mod];\n\n return { r: r * 255, g: g * 255, b: b * 255 };\n}\n\n// `rgbToHex`\n// Converts an RGB color to hex\n// Assumes r, g, and b are contained in the set [0, 255]\n// Returns a 3 or 6 character hex\nfunction rgbToHex(r, g, b, allow3Char) {\n\n var hex = [\n pad2(mathRound(r).toString(16)),\n pad2(mathRound(g).toString(16)),\n pad2(mathRound(b).toString(16))\n ];\n\n // Return a 3 character hex if possible\n if (allow3Char && hex[0].charAt(0) == hex[0].charAt(1) && hex[1].charAt(0) == hex[1].charAt(1) && hex[2].charAt(0) == hex[2].charAt(1)) {\n return hex[0].charAt(0) + hex[1].charAt(0) + hex[2].charAt(0);\n }\n\n return hex.join(\"\");\n}\n\n// `rgbaToHex`\n// Converts an RGBA color plus alpha transparency to hex\n// Assumes r, g, b are contained in the set [0, 255] and\n// a in [0, 1]. Returns a 4 or 8 character rgba hex\nfunction rgbaToHex(r, g, b, a, allow4Char) {\n\n var hex = [\n pad2(mathRound(r).toString(16)),\n pad2(mathRound(g).toString(16)),\n pad2(mathRound(b).toString(16)),\n pad2(convertDecimalToHex(a))\n ];\n\n // Return a 4 character hex if possible\n if (allow4Char && hex[0].charAt(0) == hex[0].charAt(1) && hex[1].charAt(0) == hex[1].charAt(1) && hex[2].charAt(0) == hex[2].charAt(1) && hex[3].charAt(0) == hex[3].charAt(1)) {\n return hex[0].charAt(0) + hex[1].charAt(0) + hex[2].charAt(0) + hex[3].charAt(0);\n }\n\n return hex.join(\"\");\n}\n\n// `rgbaToArgbHex`\n// Converts an RGBA color to an ARGB Hex8 string\n// Rarely used, but required for \"toFilter()\"\nfunction rgbaToArgbHex(r, g, b, a) {\n\n var hex = [\n pad2(convertDecimalToHex(a)),\n pad2(mathRound(r).toString(16)),\n pad2(mathRound(g).toString(16)),\n pad2(mathRound(b).toString(16))\n ];\n\n return hex.join(\"\");\n}\n\n// `equals`\n// Can be called with any tinycolor input\ntinycolor.equals = function (color1, color2) {\n if (!color1 || !color2) { return false; }\n return tinycolor(color1).toRgbString() == tinycolor(color2).toRgbString();\n};\n\ntinycolor.random = function() {\n return tinycolor.fromRatio({\n r: mathRandom(),\n g: mathRandom(),\n b: mathRandom()\n });\n};\n\n\n// Modification Functions\n// ----------------------\n// Thanks to less.js for some of the basics here\n// \n\nfunction desaturate(color, amount) {\n amount = (amount === 0) ? 0 : (amount || 10);\n var hsl = tinycolor(color).toHsl();\n hsl.s -= amount / 100;\n hsl.s = clamp01(hsl.s);\n return tinycolor(hsl);\n}\n\nfunction saturate(color, amount) {\n amount = (amount === 0) ? 0 : (amount || 10);\n var hsl = tinycolor(color).toHsl();\n hsl.s += amount / 100;\n hsl.s = clamp01(hsl.s);\n return tinycolor(hsl);\n}\n\nfunction greyscale(color) {\n return tinycolor(color).desaturate(100);\n}\n\nfunction lighten (color, amount) {\n amount = (amount === 0) ? 0 : (amount || 10);\n var hsl = tinycolor(color).toHsl();\n hsl.l += amount / 100;\n hsl.l = clamp01(hsl.l);\n return tinycolor(hsl);\n}\n\nfunction brighten(color, amount) {\n amount = (amount === 0) ? 0 : (amount || 10);\n var rgb = tinycolor(color).toRgb();\n rgb.r = mathMax(0, mathMin(255, rgb.r - mathRound(255 * - (amount / 100))));\n rgb.g = mathMax(0, mathMin(255, rgb.g - mathRound(255 * - (amount / 100))));\n rgb.b = mathMax(0, mathMin(255, rgb.b - mathRound(255 * - (amount / 100))));\n return tinycolor(rgb);\n}\n\nfunction darken (color, amount) {\n amount = (amount === 0) ? 0 : (amount || 10);\n var hsl = tinycolor(color).toHsl();\n hsl.l -= amount / 100;\n hsl.l = clamp01(hsl.l);\n return tinycolor(hsl);\n}\n\n// Spin takes a positive or negative amount within [-360, 360] indicating the change of hue.\n// Values outside of this range will be wrapped into this range.\nfunction spin(color, amount) {\n var hsl = tinycolor(color).toHsl();\n var hue = (hsl.h + amount) % 360;\n hsl.h = hue < 0 ? 360 + hue : hue;\n return tinycolor(hsl);\n}\n\n// Combination Functions\n// ---------------------\n// Thanks to jQuery xColor for some of the ideas behind these\n// \n\nfunction complement(color) {\n var hsl = tinycolor(color).toHsl();\n hsl.h = (hsl.h + 180) % 360;\n return tinycolor(hsl);\n}\n\nfunction triad(color) {\n var hsl = tinycolor(color).toHsl();\n var h = hsl.h;\n return [\n tinycolor(color),\n tinycolor({ h: (h + 120) % 360, s: hsl.s, l: hsl.l }),\n tinycolor({ h: (h + 240) % 360, s: hsl.s, l: hsl.l })\n ];\n}\n\nfunction tetrad(color) {\n var hsl = tinycolor(color).toHsl();\n var h = hsl.h;\n return [\n tinycolor(color),\n tinycolor({ h: (h + 90) % 360, s: hsl.s, l: hsl.l }),\n tinycolor({ h: (h + 180) % 360, s: hsl.s, l: hsl.l }),\n tinycolor({ h: (h + 270) % 360, s: hsl.s, l: hsl.l })\n ];\n}\n\nfunction splitcomplement(color) {\n var hsl = tinycolor(color).toHsl();\n var h = hsl.h;\n return [\n tinycolor(color),\n tinycolor({ h: (h + 72) % 360, s: hsl.s, l: hsl.l}),\n tinycolor({ h: (h + 216) % 360, s: hsl.s, l: hsl.l})\n ];\n}\n\nfunction analogous(color, results, slices) {\n results = results || 6;\n slices = slices || 30;\n\n var hsl = tinycolor(color).toHsl();\n var part = 360 / slices;\n var ret = [tinycolor(color)];\n\n for (hsl.h = ((hsl.h - (part * results >> 1)) + 720) % 360; --results; ) {\n hsl.h = (hsl.h + part) % 360;\n ret.push(tinycolor(hsl));\n }\n return ret;\n}\n\nfunction monochromatic(color, results) {\n results = results || 6;\n var hsv = tinycolor(color).toHsv();\n var h = hsv.h, s = hsv.s, v = hsv.v;\n var ret = [];\n var modification = 1 / results;\n\n while (results--) {\n ret.push(tinycolor({ h: h, s: s, v: v}));\n v = (v + modification) % 1;\n }\n\n return ret;\n}\n\n// Utility Functions\n// ---------------------\n\ntinycolor.mix = function(color1, color2, amount) {\n amount = (amount === 0) ? 0 : (amount || 50);\n\n var rgb1 = tinycolor(color1).toRgb();\n var rgb2 = tinycolor(color2).toRgb();\n\n var p = amount / 100;\n\n var rgba = {\n r: ((rgb2.r - rgb1.r) * p) + rgb1.r,\n g: ((rgb2.g - rgb1.g) * p) + rgb1.g,\n b: ((rgb2.b - rgb1.b) * p) + rgb1.b,\n a: ((rgb2.a - rgb1.a) * p) + rgb1.a\n };\n\n return tinycolor(rgba);\n};\n\n\n// Readability Functions\n// ---------------------\n// false\n// tinycolor.isReadable(\"#000\", \"#111\",{level:\"AA\",size:\"large\"}) => false\ntinycolor.isReadable = function(color1, color2, wcag2) {\n var readability = tinycolor.readability(color1, color2);\n var wcag2Parms, out;\n\n out = false;\n\n wcag2Parms = validateWCAG2Parms(wcag2);\n switch (wcag2Parms.level + wcag2Parms.size) {\n case \"AAsmall\":\n case \"AAAlarge\":\n out = readability >= 4.5;\n break;\n case \"AAlarge\":\n out = readability >= 3;\n break;\n case \"AAAsmall\":\n out = readability >= 7;\n break;\n }\n return out;\n\n};\n\n// `mostReadable`\n// Given a base color and a list of possible foreground or background\n// colors for that base, returns the most readable color.\n// Optionally returns Black or White if the most readable color is unreadable.\n// *Example*\n// tinycolor.mostReadable(tinycolor.mostReadable(\"#123\", [\"#124\", \"#125\"],{includeFallbackColors:false}).toHexString(); // \"#112255\"\n// tinycolor.mostReadable(tinycolor.mostReadable(\"#123\", [\"#124\", \"#125\"],{includeFallbackColors:true}).toHexString(); // \"#ffffff\"\n// tinycolor.mostReadable(\"#a8015a\", [\"#faf3f3\"],{includeFallbackColors:true,level:\"AAA\",size:\"large\"}).toHexString(); // \"#faf3f3\"\n// tinycolor.mostReadable(\"#a8015a\", [\"#faf3f3\"],{includeFallbackColors:true,level:\"AAA\",size:\"small\"}).toHexString(); // \"#ffffff\"\ntinycolor.mostReadable = function(baseColor, colorList, args) {\n var bestColor = null;\n var bestScore = 0;\n var readability;\n var includeFallbackColors, level, size ;\n args = args || {};\n includeFallbackColors = args.includeFallbackColors ;\n level = args.level;\n size = args.size;\n\n for (var i= 0; i < colorList.length ; i++) {\n readability = tinycolor.readability(baseColor, colorList[i]);\n if (readability > bestScore) {\n bestScore = readability;\n bestColor = tinycolor(colorList[i]);\n }\n }\n\n if (tinycolor.isReadable(baseColor, bestColor, {\"level\":level,\"size\":size}) || !includeFallbackColors) {\n return bestColor;\n }\n else {\n args.includeFallbackColors=false;\n return tinycolor.mostReadable(baseColor,[\"#fff\", \"#000\"],args);\n }\n};\n\n\n// Big List of Colors\n// ------------------\n// \nvar names = tinycolor.names = {\n aliceblue: \"f0f8ff\",\n antiquewhite: \"faebd7\",\n aqua: \"0ff\",\n aquamarine: \"7fffd4\",\n azure: \"f0ffff\",\n beige: \"f5f5dc\",\n bisque: \"ffe4c4\",\n black: \"000\",\n blanchedalmond: \"ffebcd\",\n blue: \"00f\",\n blueviolet: \"8a2be2\",\n brown: \"a52a2a\",\n burlywood: \"deb887\",\n burntsienna: \"ea7e5d\",\n cadetblue: \"5f9ea0\",\n chartreuse: \"7fff00\",\n chocolate: \"d2691e\",\n coral: \"ff7f50\",\n cornflowerblue: \"6495ed\",\n cornsilk: \"fff8dc\",\n crimson: \"dc143c\",\n cyan: \"0ff\",\n darkblue: \"00008b\",\n darkcyan: \"008b8b\",\n darkgoldenrod: \"b8860b\",\n darkgray: \"a9a9a9\",\n darkgreen: \"006400\",\n darkgrey: \"a9a9a9\",\n darkkhaki: \"bdb76b\",\n darkmagenta: \"8b008b\",\n darkolivegreen: \"556b2f\",\n darkorange: \"ff8c00\",\n darkorchid: \"9932cc\",\n darkred: \"8b0000\",\n darksalmon: \"e9967a\",\n darkseagreen: \"8fbc8f\",\n darkslateblue: \"483d8b\",\n darkslategray: \"2f4f4f\",\n darkslategrey: \"2f4f4f\",\n darkturquoise: \"00ced1\",\n darkviolet: \"9400d3\",\n deeppink: \"ff1493\",\n deepskyblue: \"00bfff\",\n dimgray: \"696969\",\n dimgrey: \"696969\",\n dodgerblue: \"1e90ff\",\n firebrick: \"b22222\",\n floralwhite: \"fffaf0\",\n forestgreen: \"228b22\",\n fuchsia: \"f0f\",\n gainsboro: \"dcdcdc\",\n ghostwhite: \"f8f8ff\",\n gold: \"ffd700\",\n goldenrod: \"daa520\",\n gray: \"808080\",\n green: \"008000\",\n greenyellow: \"adff2f\",\n grey: \"808080\",\n honeydew: \"f0fff0\",\n hotpink: \"ff69b4\",\n indianred: \"cd5c5c\",\n indigo: \"4b0082\",\n ivory: \"fffff0\",\n khaki: \"f0e68c\",\n lavender: \"e6e6fa\",\n lavenderblush: \"fff0f5\",\n lawngreen: \"7cfc00\",\n lemonchiffon: \"fffacd\",\n lightblue: \"add8e6\",\n lightcoral: \"f08080\",\n lightcyan: \"e0ffff\",\n lightgoldenrodyellow: \"fafad2\",\n lightgray: \"d3d3d3\",\n lightgreen: \"90ee90\",\n lightgrey: \"d3d3d3\",\n lightpink: \"ffb6c1\",\n lightsalmon: \"ffa07a\",\n lightseagreen: \"20b2aa\",\n lightskyblue: \"87cefa\",\n lightslategray: \"789\",\n lightslategrey: \"789\",\n lightsteelblue: \"b0c4de\",\n lightyellow: \"ffffe0\",\n lime: \"0f0\",\n limegreen: \"32cd32\",\n linen: \"faf0e6\",\n magenta: \"f0f\",\n maroon: \"800000\",\n mediumaquamarine: \"66cdaa\",\n mediumblue: \"0000cd\",\n mediumorchid: \"ba55d3\",\n mediumpurple: \"9370db\",\n mediumseagreen: \"3cb371\",\n mediumslateblue: \"7b68ee\",\n mediumspringgreen: \"00fa9a\",\n mediumturquoise: \"48d1cc\",\n mediumvioletred: \"c71585\",\n midnightblue: \"191970\",\n mintcream: \"f5fffa\",\n mistyrose: \"ffe4e1\",\n moccasin: \"ffe4b5\",\n navajowhite: \"ffdead\",\n navy: \"000080\",\n oldlace: \"fdf5e6\",\n olive: \"808000\",\n olivedrab: \"6b8e23\",\n orange: \"ffa500\",\n orangered: \"ff4500\",\n orchid: \"da70d6\",\n palegoldenrod: \"eee8aa\",\n palegreen: \"98fb98\",\n paleturquoise: \"afeeee\",\n palevioletred: \"db7093\",\n papayawhip: \"ffefd5\",\n peachpuff: \"ffdab9\",\n peru: \"cd853f\",\n pink: \"ffc0cb\",\n plum: \"dda0dd\",\n powderblue: \"b0e0e6\",\n purple: \"800080\",\n rebeccapurple: \"663399\",\n red: \"f00\",\n rosybrown: \"bc8f8f\",\n royalblue: \"4169e1\",\n saddlebrown: \"8b4513\",\n salmon: \"fa8072\",\n sandybrown: \"f4a460\",\n seagreen: \"2e8b57\",\n seashell: \"fff5ee\",\n sienna: \"a0522d\",\n silver: \"c0c0c0\",\n skyblue: \"87ceeb\",\n slateblue: \"6a5acd\",\n slategray: \"708090\",\n slategrey: \"708090\",\n snow: \"fffafa\",\n springgreen: \"00ff7f\",\n steelblue: \"4682b4\",\n tan: \"d2b48c\",\n teal: \"008080\",\n thistle: \"d8bfd8\",\n tomato: \"ff6347\",\n turquoise: \"40e0d0\",\n violet: \"ee82ee\",\n wheat: \"f5deb3\",\n white: \"fff\",\n whitesmoke: \"f5f5f5\",\n yellow: \"ff0\",\n yellowgreen: \"9acd32\"\n};\n\n// Make it easy to access colors via `hexNames[hex]`\nvar hexNames = tinycolor.hexNames = flip(names);\n\n\n// Utilities\n// ---------\n\n// `{ 'name1': 'val1' }` becomes `{ 'val1': 'name1' }`\nfunction flip(o) {\n var flipped = { };\n for (var i in o) {\n if (o.hasOwnProperty(i)) {\n flipped[o[i]] = i;\n }\n }\n return flipped;\n}\n\n// Return a valid alpha value [0,1] with all invalid values being set to 1\nfunction boundAlpha(a) {\n a = parseFloat(a);\n\n if (isNaN(a) || a < 0 || a > 1) {\n a = 1;\n }\n\n return a;\n}\n\n// Take input from [0, n] and return it as [0, 1]\nfunction bound01(n, max) {\n if (isOnePointZero(n)) { n = \"100%\"; }\n\n var processPercent = isPercentage(n);\n n = mathMin(max, mathMax(0, parseFloat(n)));\n\n // Automatically convert percentage into number\n if (processPercent) {\n n = parseInt(n * max, 10) / 100;\n }\n\n // Handle floating point rounding errors\n if ((Math.abs(n - max) < 0.000001)) {\n return 1;\n }\n\n // Convert into [0, 1] range if it isn't already\n return (n % max) / parseFloat(max);\n}\n\n// Force a number between 0 and 1\nfunction clamp01(val) {\n return mathMin(1, mathMax(0, val));\n}\n\n// Parse a base-16 hex value into a base-10 integer\nfunction parseIntFromHex(val) {\n return parseInt(val, 16);\n}\n\n// Need to handle 1.0 as 100%, since once it is a number, there is no difference between it and 1\n// \nfunction isOnePointZero(n) {\n return typeof n == \"string\" && n.indexOf('.') != -1 && parseFloat(n) === 1;\n}\n\n// Check to see if string passed in is a percentage\nfunction isPercentage(n) {\n return typeof n === \"string\" && n.indexOf('%') != -1;\n}\n\n// Force a hex value to have 2 characters\nfunction pad2(c) {\n return c.length == 1 ? '0' + c : '' + c;\n}\n\n// Replace a decimal with it's percentage value\nfunction convertToPercentage(n) {\n if (n <= 1) {\n n = (n * 100) + \"%\";\n }\n\n return n;\n}\n\n// Converts a decimal to a hex value\nfunction convertDecimalToHex(d) {\n return Math.round(parseFloat(d) * 255).toString(16);\n}\n// Converts a hex value to a decimal\nfunction convertHexToDecimal(h) {\n return (parseIntFromHex(h) / 255);\n}\n\nvar matchers = (function() {\n\n // \n var CSS_INTEGER = \"[-\\\\+]?\\\\d+%?\";\n\n // \n var CSS_NUMBER = \"[-\\\\+]?\\\\d*\\\\.\\\\d+%?\";\n\n // Allow positive/negative integer/number. Don't capture the either/or, just the entire outcome.\n var CSS_UNIT = \"(?:\" + CSS_NUMBER + \")|(?:\" + CSS_INTEGER + \")\";\n\n // Actual matching.\n // Parentheses and commas are optional, but not required.\n // Whitespace can take the place of commas or opening paren\n var PERMISSIVE_MATCH3 = \"[\\\\s|\\\\(]+(\" + CSS_UNIT + \")[,|\\\\s]+(\" + CSS_UNIT + \")[,|\\\\s]+(\" + CSS_UNIT + \")\\\\s*\\\\)?\";\n var PERMISSIVE_MATCH4 = \"[\\\\s|\\\\(]+(\" + CSS_UNIT + \")[,|\\\\s]+(\" + CSS_UNIT + \")[,|\\\\s]+(\" + CSS_UNIT + \")[,|\\\\s]+(\" + CSS_UNIT + \")\\\\s*\\\\)?\";\n\n return {\n CSS_UNIT: new RegExp(CSS_UNIT),\n rgb: new RegExp(\"rgb\" + PERMISSIVE_MATCH3),\n rgba: new RegExp(\"rgba\" + PERMISSIVE_MATCH4),\n hsl: new RegExp(\"hsl\" + PERMISSIVE_MATCH3),\n hsla: new RegExp(\"hsla\" + PERMISSIVE_MATCH4),\n hsv: new RegExp(\"hsv\" + PERMISSIVE_MATCH3),\n hsva: new RegExp(\"hsva\" + PERMISSIVE_MATCH4),\n hex3: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,\n hex6: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,\n hex4: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,\n hex8: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/\n };\n})();\n\n// `isValidCSSUnit`\n// Take in a single string / number and check to see if it looks like a CSS unit\n// (see `matchers` above for definition).\nfunction isValidCSSUnit(color) {\n return !!matchers.CSS_UNIT.exec(color);\n}\n\n// `stringInputToObject`\n// Permissive string parsing. Take in a number of formats, and output an object\n// based on detected format. Returns `{ r, g, b }` or `{ h, s, l }` or `{ h, s, v}`\nfunction stringInputToObject(color) {\n\n color = color.replace(trimLeft,'').replace(trimRight, '').toLowerCase();\n var named = false;\n if (names[color]) {\n color = names[color];\n named = true;\n }\n else if (color == 'transparent') {\n return { r: 0, g: 0, b: 0, a: 0, format: \"name\" };\n }\n\n // Try to match string input using regular expressions.\n // Keep most of the number bounding out of this function - don't worry about [0,1] or [0,100] or [0,360]\n // Just return an object and let the conversion functions handle that.\n // This way the result will be the same whether the tinycolor is initialized with string or object.\n var match;\n if ((match = matchers.rgb.exec(color))) {\n return { r: match[1], g: match[2], b: match[3] };\n }\n if ((match = matchers.rgba.exec(color))) {\n return { r: match[1], g: match[2], b: match[3], a: match[4] };\n }\n if ((match = matchers.hsl.exec(color))) {\n return { h: match[1], s: match[2], l: match[3] };\n }\n if ((match = matchers.hsla.exec(color))) {\n return { h: match[1], s: match[2], l: match[3], a: match[4] };\n }\n if ((match = matchers.hsv.exec(color))) {\n return { h: match[1], s: match[2], v: match[3] };\n }\n if ((match = matchers.hsva.exec(color))) {\n return { h: match[1], s: match[2], v: match[3], a: match[4] };\n }\n if ((match = matchers.hex8.exec(color))) {\n return {\n r: parseIntFromHex(match[1]),\n g: parseIntFromHex(match[2]),\n b: parseIntFromHex(match[3]),\n a: convertHexToDecimal(match[4]),\n format: named ? \"name\" : \"hex8\"\n };\n }\n if ((match = matchers.hex6.exec(color))) {\n return {\n r: parseIntFromHex(match[1]),\n g: parseIntFromHex(match[2]),\n b: parseIntFromHex(match[3]),\n format: named ? \"name\" : \"hex\"\n };\n }\n if ((match = matchers.hex4.exec(color))) {\n return {\n r: parseIntFromHex(match[1] + '' + match[1]),\n g: parseIntFromHex(match[2] + '' + match[2]),\n b: parseIntFromHex(match[3] + '' + match[3]),\n a: convertHexToDecimal(match[4] + '' + match[4]),\n format: named ? \"name\" : \"hex8\"\n };\n }\n if ((match = matchers.hex3.exec(color))) {\n return {\n r: parseIntFromHex(match[1] + '' + match[1]),\n g: parseIntFromHex(match[2] + '' + match[2]),\n b: parseIntFromHex(match[3] + '' + match[3]),\n format: named ? \"name\" : \"hex\"\n };\n }\n\n return false;\n}\n\nfunction validateWCAG2Parms(parms) {\n // return valid WCAG2 parms for isReadable.\n // If input parms are invalid, return {\"level\":\"AA\", \"size\":\"small\"}\n var level, size;\n parms = parms || {\"level\":\"AA\", \"size\":\"small\"};\n level = (parms.level || \"AA\").toUpperCase();\n size = (parms.size || \"small\").toLowerCase();\n if (level !== \"AA\" && level !== \"AAA\") {\n level = \"AA\";\n }\n if (size !== \"small\" && size !== \"large\") {\n size = \"small\";\n }\n return {\"level\":level, \"size\":size};\n}\n\n// Node: Export function\nif (typeof module !== \"undefined\" && module.exports) {\n module.exports = tinycolor;\n}\n// AMD/requirejs: Define the module\nelse if (typeof define === 'function' && define.amd) {\n define(function () {return tinycolor;});\n}\n// Browser: Expose to window\nelse {\n window.tinycolor = tinycolor;\n}\n\n})(Math);\n","\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.warning = warning;\nexports.note = note;\nexports.resetWarned = resetWarned;\nexports.call = call;\nexports.warningOnce = warningOnce;\nexports.noteOnce = noteOnce;\nexports.default = void 0;\n\n/* eslint-disable no-console */\nvar warned = {};\n\nfunction warning(valid, message) {\n // Support uglify\n if (process.env.NODE_ENV !== 'production' && !valid && console !== undefined) {\n console.error(\"Warning: \".concat(message));\n }\n}\n\nfunction note(valid, message) {\n // Support uglify\n if (process.env.NODE_ENV !== 'production' && !valid && console !== undefined) {\n console.warn(\"Note: \".concat(message));\n }\n}\n\nfunction resetWarned() {\n warned = {};\n}\n\nfunction call(method, valid, message) {\n if (!valid && !warned[message]) {\n method(false, message);\n warned[message] = true;\n }\n}\n\nfunction warningOnce(valid, message) {\n call(warning, valid, message);\n}\n\nfunction noteOnce(valid, message) {\n call(note, valid, message);\n}\n\nvar _default = warningOnce;\n/* eslint-enable */\n\nexports.default = _default;","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.setTwoToneColor = setTwoToneColor;\nexports.getTwoToneColor = getTwoToneColor;\n\nvar _slicedToArray2 = _interopRequireDefault(require(\"@babel/runtime/helpers/slicedToArray\"));\n\nvar _IconBase = _interopRequireDefault(require(\"./IconBase\"));\n\nvar _utils = require(\"../utils\");\n\nfunction setTwoToneColor(twoToneColor) {\n var _normalizeTwoToneColo = (0, _utils.normalizeTwoToneColors)(twoToneColor),\n _normalizeTwoToneColo2 = (0, _slicedToArray2.default)(_normalizeTwoToneColo, 2),\n primaryColor = _normalizeTwoToneColo2[0],\n secondaryColor = _normalizeTwoToneColo2[1];\n\n return _IconBase.default.setTwoToneColors({\n primaryColor: primaryColor,\n secondaryColor: secondaryColor\n });\n}\n\nfunction getTwoToneColor() {\n var colors = _IconBase.default.getTwoToneColors();\n\n if (!colors.calculated) {\n return colors.primaryColor;\n }\n\n return [colors.primaryColor, colors.secondaryColor];\n}","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _CheckCircleFilled = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/CheckCircleFilled\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar CheckCircleFilled = function CheckCircleFilled(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _CheckCircleFilled.default\n }));\n};\n\nCheckCircleFilled.displayName = 'CheckCircleFilled';\n\nvar _default = React.forwardRef(CheckCircleFilled);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar CheckCircleFilled = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z\" } }] }, \"name\": \"check-circle\", \"theme\": \"filled\" };\nexports.default = CheckCircleFilled;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _CloseCircleFilled = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/CloseCircleFilled\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar CloseCircleFilled = function CloseCircleFilled(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _CloseCircleFilled.default\n }));\n};\n\nCloseCircleFilled.displayName = 'CloseCircleFilled';\n\nvar _default = React.forwardRef(CloseCircleFilled);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar CloseCircleFilled = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm165.4 618.2l-66-.3L512 563.4l-99.3 118.4-66.1.3c-4.4 0-8-3.5-8-8 0-1.9.7-3.7 1.9-5.2l130.1-155L340.5 359a8.32 8.32 0 01-1.9-5.2c0-4.4 3.6-8 8-8l66.1.3L512 464.6l99.3-118.4 66-.3c4.4 0 8 3.5 8 8 0 1.9-.7 3.7-1.9 5.2L553.5 514l130 155c1.2 1.5 1.9 3.3 1.9 5.2 0 4.4-3.6 8-8 8z\" } }] }, \"name\": \"close-circle\", \"theme\": \"filled\" };\nexports.default = CloseCircleFilled;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _ExclamationCircleFilled = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/ExclamationCircleFilled\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar ExclamationCircleFilled = function ExclamationCircleFilled(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _ExclamationCircleFilled.default\n }));\n};\n\nExclamationCircleFilled.displayName = 'ExclamationCircleFilled';\n\nvar _default = React.forwardRef(ExclamationCircleFilled);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar ExclamationCircleFilled = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z\" } }] }, \"name\": \"exclamation-circle\", \"theme\": \"filled\" };\nexports.default = ExclamationCircleFilled;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _LoadingOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/LoadingOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar LoadingOutlined = function LoadingOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _LoadingOutlined.default\n }));\n};\n\nLoadingOutlined.displayName = 'LoadingOutlined';\n\nvar _default = React.forwardRef(LoadingOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar LoadingOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"0 0 1024 1024\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z\" } }] }, \"name\": \"loading\", \"theme\": \"outlined\" };\nexports.default = LoadingOutlined;\n","function _setPrototypeOf(o, p) {\n module.exports = _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n}\n\nmodule.exports = _setPrototypeOf;","function _getPrototypeOf(o) {\n module.exports = _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}\n\nmodule.exports = _getPrototypeOf;","function _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n\n try {\n Date.prototype.toString.call(Reflect.construct(Date, [], function () {}));\n return true;\n } catch (e) {\n return false;\n }\n}\n\nmodule.exports = _isNativeReflectConstruct;","var _typeof = require(\"../helpers/typeof\");\n\nvar assertThisInitialized = require(\"./assertThisInitialized\");\n\nfunction _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n }\n\n return assertThisInitialized(self);\n}\n\nmodule.exports = _possibleConstructorReturn;","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Array.isArray || function (arr) {\n return Object.prototype.toString.call(arr) == '[object Array]';\n};\n","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","var arrayLikeToArray = require(\"./arrayLikeToArray\");\n\nfunction _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return arrayLikeToArray(arr);\n}\n\nmodule.exports = _arrayWithoutHoles;","function _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n\nmodule.exports = _nonIterableSpread;","var baseIsEqualDeep = require('./_baseIsEqualDeep'),\n isObjectLike = require('./isObjectLike');\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nmodule.exports = baseIsEqual;\n","var Stack = require('./_Stack'),\n equalArrays = require('./_equalArrays'),\n equalByTag = require('./_equalByTag'),\n equalObjects = require('./_equalObjects'),\n getTag = require('./_getTag'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isTypedArray = require('./isTypedArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nmodule.exports = baseIsEqualDeep;\n","var ListCache = require('./_ListCache'),\n stackClear = require('./_stackClear'),\n stackDelete = require('./_stackDelete'),\n stackGet = require('./_stackGet'),\n stackHas = require('./_stackHas'),\n stackSet = require('./_stackSet');\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nmodule.exports = Stack;\n","/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nmodule.exports = listCacheClear;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nmodule.exports = listCacheDelete;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nmodule.exports = listCacheGet;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nmodule.exports = listCacheHas;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nmodule.exports = listCacheSet;\n","var ListCache = require('./_ListCache');\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nmodule.exports = stackClear;\n","/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nmodule.exports = stackDelete;\n","/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nmodule.exports = stackGet;\n","/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nmodule.exports = stackHas;\n","var ListCache = require('./_ListCache'),\n Map = require('./_Map'),\n MapCache = require('./_MapCache');\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nmodule.exports = stackSet;\n","var isFunction = require('./isFunction'),\n isMasked = require('./_isMasked'),\n isObject = require('./isObject'),\n toSource = require('./_toSource');\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nmodule.exports = baseIsNative;\n","var Symbol = require('./_Symbol');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nmodule.exports = getRawTag;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nmodule.exports = objectToString;\n","var coreJsData = require('./_coreJsData');\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nmodule.exports = isMasked;\n","var root = require('./_root');\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nmodule.exports = coreJsData;\n","/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nmodule.exports = getValue;\n","var Hash = require('./_Hash'),\n ListCache = require('./_ListCache'),\n Map = require('./_Map');\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nmodule.exports = mapCacheClear;\n","var hashClear = require('./_hashClear'),\n hashDelete = require('./_hashDelete'),\n hashGet = require('./_hashGet'),\n hashHas = require('./_hashHas'),\n hashSet = require('./_hashSet');\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nmodule.exports = Hash;\n","var nativeCreate = require('./_nativeCreate');\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nmodule.exports = hashClear;\n","/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = hashDelete;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nmodule.exports = hashGet;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nmodule.exports = hashHas;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nmodule.exports = hashSet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = mapCacheDelete;\n","/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nmodule.exports = isKeyable;\n","var getMapData = require('./_getMapData');\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nmodule.exports = mapCacheGet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nmodule.exports = mapCacheHas;\n","var getMapData = require('./_getMapData');\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nmodule.exports = mapCacheSet;\n","var MapCache = require('./_MapCache'),\n setCacheAdd = require('./_setCacheAdd'),\n setCacheHas = require('./_setCacheHas');\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nmodule.exports = SetCache;\n","/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\nmodule.exports = setCacheAdd;\n","/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\nmodule.exports = setCacheHas;\n","/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\nmodule.exports = arraySome;\n","/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\nmodule.exports = cacheHas;\n","var Symbol = require('./_Symbol'),\n Uint8Array = require('./_Uint8Array'),\n eq = require('./eq'),\n equalArrays = require('./_equalArrays'),\n mapToArray = require('./_mapToArray'),\n setToArray = require('./_setToArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\nmodule.exports = equalByTag;\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nmodule.exports = Uint8Array;\n","/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\nmodule.exports = mapToArray;\n","/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\nmodule.exports = setToArray;\n","var getAllKeys = require('./_getAllKeys');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalObjects;\n","var baseGetAllKeys = require('./_baseGetAllKeys'),\n getSymbols = require('./_getSymbols'),\n keys = require('./keys');\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\nmodule.exports = getAllKeys;\n","var arrayPush = require('./_arrayPush'),\n isArray = require('./isArray');\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nmodule.exports = baseGetAllKeys;\n","/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n}\n\nmodule.exports = arrayPush;\n","var arrayFilter = require('./_arrayFilter'),\n stubArray = require('./stubArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\nmodule.exports = getSymbols;\n","/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\nmodule.exports = arrayFilter;\n","/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nmodule.exports = stubArray;\n","var arrayLikeKeys = require('./_arrayLikeKeys'),\n baseKeys = require('./_baseKeys'),\n isArrayLike = require('./isArrayLike');\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nmodule.exports = keys;\n","var baseTimes = require('./_baseTimes'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isIndex = require('./_isIndex'),\n isTypedArray = require('./isTypedArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = arrayLikeKeys;\n","/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nmodule.exports = baseTimes;\n","var baseIsArguments = require('./_baseIsArguments'),\n isObjectLike = require('./isObjectLike');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nmodule.exports = isArguments;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nmodule.exports = baseIsArguments;\n","/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nmodule.exports = stubFalse;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\nmodule.exports = isIndex;\n","var baseGetTag = require('./_baseGetTag'),\n isLength = require('./isLength'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nmodule.exports = baseIsTypedArray;\n","/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nmodule.exports = baseUnary;\n","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nmodule.exports = nodeUtil;\n","var isPrototype = require('./_isPrototype'),\n nativeKeys = require('./_nativeKeys');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = baseKeys;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nmodule.exports = isPrototype;\n","var overArg = require('./_overArg');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nmodule.exports = nativeKeys;\n","/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nmodule.exports = overArg;\n","var isFunction = require('./isFunction'),\n isLength = require('./isLength');\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nmodule.exports = isArrayLike;\n","var DataView = require('./_DataView'),\n Map = require('./_Map'),\n Promise = require('./_Promise'),\n Set = require('./_Set'),\n WeakMap = require('./_WeakMap'),\n baseGetTag = require('./_baseGetTag'),\n toSource = require('./_toSource');\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nmodule.exports = getTag;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nmodule.exports = DataView;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nmodule.exports = Promise;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nmodule.exports = Set;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nmodule.exports = WeakMap;\n","// Generated by CoffeeScript 1.12.2\n(function() {\n var getNanoSeconds, hrtime, loadTime, moduleLoadTime, nodeLoadTime, upTime;\n\n if ((typeof performance !== \"undefined\" && performance !== null) && performance.now) {\n module.exports = function() {\n return performance.now();\n };\n } else if ((typeof process !== \"undefined\" && process !== null) && process.hrtime) {\n module.exports = function() {\n return (getNanoSeconds() - nodeLoadTime) / 1e6;\n };\n hrtime = process.hrtime;\n getNanoSeconds = function() {\n var hr;\n hr = hrtime();\n return hr[0] * 1e9 + hr[1];\n };\n moduleLoadTime = getNanoSeconds();\n upTime = process.uptime() * 1e9;\n nodeLoadTime = moduleLoadTime - upTime;\n } else if (Date.now) {\n module.exports = function() {\n return Date.now() - loadTime;\n };\n loadTime = Date.now();\n } else {\n module.exports = function() {\n return new Date().getTime() - loadTime;\n };\n loadTime = new Date().getTime();\n }\n\n}).call(this);\n\n//# sourceMappingURL=performance-now.js.map\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _SearchOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/SearchOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar SearchOutlined = function SearchOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _SearchOutlined.default\n }));\n};\n\nSearchOutlined.displayName = 'SearchOutlined';\n\nvar _default = React.forwardRef(SearchOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar SearchOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z\" } }] }, \"name\": \"search\", \"theme\": \"outlined\" };\nexports.default = SearchOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _EyeOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/EyeOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar EyeOutlined = function EyeOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _EyeOutlined.default\n }));\n};\n\nEyeOutlined.displayName = 'EyeOutlined';\n\nvar _default = React.forwardRef(EyeOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar EyeOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z\" } }] }, \"name\": \"eye\", \"theme\": \"outlined\" };\nexports.default = EyeOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _EyeInvisibleOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/EyeInvisibleOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar EyeInvisibleOutlined = function EyeInvisibleOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _EyeInvisibleOutlined.default\n }));\n};\n\nEyeInvisibleOutlined.displayName = 'EyeInvisibleOutlined';\n\nvar _default = React.forwardRef(EyeInvisibleOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar EyeInvisibleOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z\" } }, { \"tag\": \"path\", \"attrs\": { \"d\": \"M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z\" } }] }, \"name\": \"eye-invisible\", \"theme\": \"outlined\" };\nexports.default = EyeInvisibleOutlined;\n","import '../../style/index.less';\nimport './index.less';","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _CloseOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/CloseOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar CloseOutlined = function CloseOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _CloseOutlined.default\n }));\n};\n\nCloseOutlined.displayName = 'CloseOutlined';\n\nvar _default = React.forwardRef(CloseOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar CloseOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M563.8 512l262.5-312.9c4.4-5.2.7-13.1-6.1-13.1h-79.8c-4.7 0-9.2 2.1-12.3 5.7L511.6 449.8 295.1 191.7c-3-3.6-7.5-5.7-12.3-5.7H203c-6.8 0-10.5 7.9-6.1 13.1L459.4 512 196.9 824.9A7.95 7.95 0 00203 838h79.8c4.7 0 9.2-2.1 12.3-5.7l216.5-258.1 216.5 258.1c3 3.6 7.5 5.7 12.3 5.7h79.8c6.8 0 10.5-7.9 6.1-13.1L563.8 512z\" } }] }, \"name\": \"close\", \"theme\": \"outlined\" };\nexports.default = CloseOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _BarsOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/BarsOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar BarsOutlined = function BarsOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _BarsOutlined.default\n }));\n};\n\nBarsOutlined.displayName = 'BarsOutlined';\n\nvar _default = React.forwardRef(BarsOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar BarsOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"0 0 1024 1024\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M912 192H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM104 228a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0z\" } }] }, \"name\": \"bars\", \"theme\": \"outlined\" };\nexports.default = BarsOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _RightOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/RightOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar RightOutlined = function RightOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _RightOutlined.default\n }));\n};\n\nRightOutlined.displayName = 'RightOutlined';\n\nvar _default = React.forwardRef(RightOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar RightOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M765.7 486.8L314.9 134.7A7.97 7.97 0 00302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 000-50.4z\" } }] }, \"name\": \"right\", \"theme\": \"outlined\" };\nexports.default = RightOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _LeftOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/LeftOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar LeftOutlined = function LeftOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _LeftOutlined.default\n }));\n};\n\nLeftOutlined.displayName = 'LeftOutlined';\n\nvar _default = React.forwardRef(LeftOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar LeftOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 000 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z\" } }] }, \"name\": \"left\", \"theme\": \"outlined\" };\nexports.default = LeftOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _FilterFilled = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/FilterFilled\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar FilterFilled = function FilterFilled(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _FilterFilled.default\n }));\n};\n\nFilterFilled.displayName = 'FilterFilled';\n\nvar _default = React.forwardRef(FilterFilled);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar FilterFilled = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M349 838c0 17.7 14.2 32 31.8 32h262.4c17.6 0 31.8-14.3 31.8-32V642H349v196zm531.1-684H143.9c-24.5 0-39.8 26.7-27.5 48l221.3 376h348.8l221.3-376c12.1-21.3-3.2-48-27.7-48z\" } }] }, \"name\": \"filter\", \"theme\": \"filled\" };\nexports.default = FilterFilled;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _EllipsisOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/EllipsisOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar EllipsisOutlined = function EllipsisOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _EllipsisOutlined.default\n }));\n};\n\nEllipsisOutlined.displayName = 'EllipsisOutlined';\n\nvar _default = React.forwardRef(EllipsisOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar EllipsisOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M176 511a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0z\" } }] }, \"name\": \"ellipsis\", \"theme\": \"outlined\" };\nexports.default = EllipsisOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _CaretUpOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/CaretUpOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar CaretUpOutlined = function CaretUpOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _CaretUpOutlined.default\n }));\n};\n\nCaretUpOutlined.displayName = 'CaretUpOutlined';\n\nvar _default = React.forwardRef(CaretUpOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar CaretUpOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"0 0 1024 1024\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M858.9 689L530.5 308.2c-9.4-10.9-27.5-10.9-37 0L165.1 689c-12.2 14.2-1.2 35 18.5 35h656.8c19.7 0 30.7-20.8 18.5-35z\" } }] }, \"name\": \"caret-up\", \"theme\": \"outlined\" };\nexports.default = CaretUpOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _CaretDownOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/CaretDownOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar CaretDownOutlined = function CaretDownOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _CaretDownOutlined.default\n }));\n};\n\nCaretDownOutlined.displayName = 'CaretDownOutlined';\n\nvar _default = React.forwardRef(CaretDownOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar CaretDownOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"0 0 1024 1024\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z\" } }] }, \"name\": \"caret-down\", \"theme\": \"outlined\" };\nexports.default = CaretDownOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _DownOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/DownOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar DownOutlined = function DownOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _DownOutlined.default\n }));\n};\n\nDownOutlined.displayName = 'DownOutlined';\n\nvar _default = React.forwardRef(DownOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar DownOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z\" } }] }, \"name\": \"down\", \"theme\": \"outlined\" };\nexports.default = DownOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _DoubleLeftOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/DoubleLeftOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar DoubleLeftOutlined = function DoubleLeftOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _DoubleLeftOutlined.default\n }));\n};\n\nDoubleLeftOutlined.displayName = 'DoubleLeftOutlined';\n\nvar _default = React.forwardRef(DoubleLeftOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar DoubleLeftOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M272.9 512l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L186.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H532c6.7 0 10.4-7.7 6.3-12.9L272.9 512zm304 0l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L490.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H836c6.7 0 10.4-7.7 6.3-12.9L576.9 512z\" } }] }, \"name\": \"double-left\", \"theme\": \"outlined\" };\nexports.default = DoubleLeftOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _DoubleRightOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/DoubleRightOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar DoubleRightOutlined = function DoubleRightOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _DoubleRightOutlined.default\n }));\n};\n\nDoubleRightOutlined.displayName = 'DoubleRightOutlined';\n\nvar _default = React.forwardRef(DoubleRightOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar DoubleRightOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M533.2 492.3L277.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H188c-6.7 0-10.4 7.7-6.3 12.9L447.1 512 181.7 851.1A7.98 7.98 0 00188 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5zm304 0L581.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H492c-6.7 0-10.4 7.7-6.3 12.9L751.1 512 485.7 851.1A7.98 7.98 0 00492 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5z\" } }] }, \"name\": \"double-right\", \"theme\": \"outlined\" };\nexports.default = DoubleRightOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _CheckOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/CheckOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar CheckOutlined = function CheckOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _CheckOutlined.default\n }));\n};\n\nCheckOutlined.displayName = 'CheckOutlined';\n\nvar _default = React.forwardRef(CheckOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar CheckOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z\" } }] }, \"name\": \"check\", \"theme\": \"outlined\" };\nexports.default = CheckOutlined;\n","var root = require('./_root');\n\n/**\n * Gets the timestamp of the number of milliseconds that have elapsed since\n * the Unix epoch (1 January 1970 00:00:00 UTC).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Date\n * @returns {number} Returns the timestamp.\n * @example\n *\n * _.defer(function(stamp) {\n * console.log(_.now() - stamp);\n * }, _.now());\n * // => Logs the number of milliseconds it took for the deferred invocation.\n */\nvar now = function() {\n return root.Date.now();\n};\n\nmodule.exports = now;\n","var isObject = require('./isObject'),\n isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar NAN = 0 / 0;\n\n/** Used to match leading and trailing whitespace. */\nvar reTrim = /^\\s+|\\s+$/g;\n\n/** Used to detect bad signed hexadecimal string values. */\nvar reIsBadHex = /^[-+]0x[0-9a-f]+$/i;\n\n/** Used to detect binary string values. */\nvar reIsBinary = /^0b[01]+$/i;\n\n/** Used to detect octal string values. */\nvar reIsOctal = /^0o[0-7]+$/i;\n\n/** Built-in method references without a dependency on `root`. */\nvar freeParseInt = parseInt;\n\n/**\n * Converts `value` to a number.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {number} Returns the number.\n * @example\n *\n * _.toNumber(3.2);\n * // => 3.2\n *\n * _.toNumber(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toNumber(Infinity);\n * // => Infinity\n *\n * _.toNumber('3.2');\n * // => 3.2\n */\nfunction toNumber(value) {\n if (typeof value == 'number') {\n return value;\n }\n if (isSymbol(value)) {\n return NAN;\n }\n if (isObject(value)) {\n var other = typeof value.valueOf == 'function' ? value.valueOf() : value;\n value = isObject(other) ? (other + '') : other;\n }\n if (typeof value != 'string') {\n return value === 0 ? value : +value;\n }\n value = value.replace(reTrim, '');\n var isBinary = reIsBinary.test(value);\n return (isBinary || reIsOctal.test(value))\n ? freeParseInt(value.slice(2), isBinary ? 2 : 8)\n : (reIsBadHex.test(value) ? NAN : +value);\n}\n\nmodule.exports = toNumber;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n}\n\nmodule.exports = isSymbol;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _ExclamationCircleOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/ExclamationCircleOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar ExclamationCircleOutlined = function ExclamationCircleOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _ExclamationCircleOutlined.default\n }));\n};\n\nExclamationCircleOutlined.displayName = 'ExclamationCircleOutlined';\n\nvar _default = React.forwardRef(ExclamationCircleOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar ExclamationCircleOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z\" } }, { \"tag\": \"path\", \"attrs\": { \"d\": \"M464 688a48 48 0 1096 0 48 48 0 10-96 0zm24-112h48c4.4 0 8-3.6 8-8V296c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8z\" } }] }, \"name\": \"exclamation-circle\", \"theme\": \"outlined\" };\nexports.default = ExclamationCircleOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _InfoCircleOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/InfoCircleOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar InfoCircleOutlined = function InfoCircleOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _InfoCircleOutlined.default\n }));\n};\n\nInfoCircleOutlined.displayName = 'InfoCircleOutlined';\n\nvar _default = React.forwardRef(InfoCircleOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar InfoCircleOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z\" } }, { \"tag\": \"path\", \"attrs\": { \"d\": \"M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z\" } }] }, \"name\": \"info-circle\", \"theme\": \"outlined\" };\nexports.default = InfoCircleOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _CheckCircleOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/CheckCircleOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar CheckCircleOutlined = function CheckCircleOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _CheckCircleOutlined.default\n }));\n};\n\nCheckCircleOutlined.displayName = 'CheckCircleOutlined';\n\nvar _default = React.forwardRef(CheckCircleOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar CheckCircleOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M699 353h-46.9c-10.2 0-19.9 4.9-25.9 13.3L469 584.3l-71.2-98.8c-6-8.3-15.6-13.3-25.9-13.3H325c-6.5 0-10.3 7.4-6.5 12.7l124.6 172.8a31.8 31.8 0 0051.7 0l210.6-292c3.9-5.3.1-12.7-6.4-12.7z\" } }, { \"tag\": \"path\", \"attrs\": { \"d\": \"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z\" } }] }, \"name\": \"check-circle\", \"theme\": \"outlined\" };\nexports.default = CheckCircleOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _CloseCircleOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/CloseCircleOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar CloseCircleOutlined = function CloseCircleOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _CloseCircleOutlined.default\n }));\n};\n\nCloseCircleOutlined.displayName = 'CloseCircleOutlined';\n\nvar _default = React.forwardRef(CloseCircleOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar CloseCircleOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M685.4 354.8c0-4.4-3.6-8-8-8l-66 .3L512 465.6l-99.3-118.4-66.1-.3c-4.4 0-8 3.5-8 8 0 1.9.7 3.7 1.9 5.2l130.1 155L340.5 670a8.32 8.32 0 00-1.9 5.2c0 4.4 3.6 8 8 8l66.1-.3L512 564.4l99.3 118.4 66 .3c4.4 0 8-3.5 8-8 0-1.9-.7-3.7-1.9-5.2L553.5 515l130.1-155c1.2-1.4 1.8-3.3 1.8-5.2z\" } }, { \"tag\": \"path\", \"attrs\": { \"d\": \"M512 65C264.6 65 64 265.6 64 513s200.6 448 448 448 448-200.6 448-448S759.4 65 512 65zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z\" } }] }, \"name\": \"close-circle\", \"theme\": \"outlined\" };\nexports.default = CloseCircleOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _FileOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/FileOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar FileOutlined = function FileOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _FileOutlined.default\n }));\n};\n\nFileOutlined.displayName = 'FileOutlined';\n\nvar _default = React.forwardRef(FileOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar FileOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M854.6 288.6L639.4 73.4c-6-6-14.1-9.4-22.6-9.4H192c-17.7 0-32 14.3-32 32v832c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V311.3c0-8.5-3.4-16.7-9.4-22.7zM790.2 326H602V137.8L790.2 326zm1.8 562H232V136h302v216a42 42 0 0042 42h216v494z\" } }] }, \"name\": \"file\", \"theme\": \"outlined\" };\nexports.default = FileOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _MinusSquareOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/MinusSquareOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar MinusSquareOutlined = function MinusSquareOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _MinusSquareOutlined.default\n }));\n};\n\nMinusSquareOutlined.displayName = 'MinusSquareOutlined';\n\nvar _default = React.forwardRef(MinusSquareOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar MinusSquareOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M328 544h368c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8z\" } }, { \"tag\": \"path\", \"attrs\": { \"d\": \"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z\" } }] }, \"name\": \"minus-square\", \"theme\": \"outlined\" };\nexports.default = MinusSquareOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _PlusSquareOutlined = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/PlusSquareOutlined\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar PlusSquareOutlined = function PlusSquareOutlined(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _PlusSquareOutlined.default\n }));\n};\n\nPlusSquareOutlined.displayName = 'PlusSquareOutlined';\n\nvar _default = React.forwardRef(PlusSquareOutlined);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar PlusSquareOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M328 544h152v152c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V544h152c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H544V328c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v152H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8z\" } }, { \"tag\": \"path\", \"attrs\": { \"d\": \"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z\" } }] }, \"name\": \"plus-square\", \"theme\": \"outlined\" };\nexports.default = PlusSquareOutlined;\n","\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _CaretDownFilled = _interopRequireDefault(require(\"@ant-design/icons-svg/lib/asn/CaretDownFilled\"));\n\nvar _AntdIcon = _interopRequireDefault(require(\"../components/AntdIcon\"));\n\n// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nvar CaretDownFilled = function CaretDownFilled(props, ref) {\n return React.createElement(_AntdIcon.default, Object.assign({}, props, {\n ref: ref,\n icon: _CaretDownFilled.default\n }));\n};\n\nCaretDownFilled.displayName = 'CaretDownFilled';\n\nvar _default = React.forwardRef(CaretDownFilled);\n\nexports.default = _default;","\"use strict\";\n// This icon file is generated automatically.\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar CaretDownFilled = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"0 0 1024 1024\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z\" } }] }, \"name\": \"caret-down\", \"theme\": \"filled\" };\nexports.default = CaretDownFilled;\n","// This icon file is generated automatically.\nvar UserOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M858.5 763.6a374 374 0 00-80.6-119.5 375.63 375.63 0 00-119.5-80.6c-.4-.2-.8-.3-1.2-.5C719.5 518 760 444.7 760 362c0-137-111-248-248-248S264 225 264 362c0 82.7 40.5 156 102.8 201.1-.4.2-.8.3-1.2.5-44.8 18.9-85 46-119.5 80.6a375.63 375.63 0 00-80.6 119.5A371.7 371.7 0 00136 901.8a8 8 0 008 8.2h60c4.4 0 7.9-3.5 8-7.8 2-77.2 33-149.5 87.8-204.3 56.7-56.7 132-87.9 212.2-87.9s155.5 31.2 212.2 87.9C779 752.7 810 825 812 902.2c.1 4.4 3.6 7.8 8 7.8h60a8 8 0 008-8.2c-1-47.8-10.9-94.3-29.5-138.2zM512 534c-45.9 0-89.1-17.9-121.6-50.4S340 407.9 340 362c0-45.9 17.9-89.1 50.4-121.6S466.1 190 512 190s89.1 17.9 121.6 50.4S684 316.1 684 362c0 45.9-17.9 89.1-50.4 121.6S557.9 534 512 534z\" } }] }, \"name\": \"user\", \"theme\": \"outlined\" };\nexport default UserOutlined;\n","// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nimport * as React from 'react';\nimport UserOutlinedSvg from \"@ant-design/icons-svg/es/asn/UserOutlined\";\nimport AntdIcon from '../components/AntdIcon';\n\nvar UserOutlined = function UserOutlined(props, ref) {\n return React.createElement(AntdIcon, Object.assign({}, props, {\n ref: ref,\n icon: UserOutlinedSvg\n }));\n};\n\nUserOutlined.displayName = 'UserOutlined';\nexport default React.forwardRef(UserOutlined);","// This icon file is generated automatically.\nvar LockOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M832 464h-68V240c0-70.7-57.3-128-128-128H388c-70.7 0-128 57.3-128 128v224h-68c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V496c0-17.7-14.3-32-32-32zM332 240c0-30.9 25.1-56 56-56h248c30.9 0 56 25.1 56 56v224H332V240zm460 600H232V536h560v304zM484 701v53c0 4.4 3.6 8 8 8h40c4.4 0 8-3.6 8-8v-53a48.01 48.01 0 10-56 0z\" } }] }, \"name\": \"lock\", \"theme\": \"outlined\" };\nexport default LockOutlined;\n","// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nimport * as React from 'react';\nimport LockOutlinedSvg from \"@ant-design/icons-svg/es/asn/LockOutlined\";\nimport AntdIcon from '../components/AntdIcon';\n\nvar LockOutlined = function LockOutlined(props, ref) {\n return React.createElement(AntdIcon, Object.assign({}, props, {\n ref: ref,\n icon: LockOutlinedSvg\n }));\n};\n\nLockOutlined.displayName = 'LockOutlined';\nexport default React.forwardRef(LockOutlined);","// This icon file is generated automatically.\nvar DesktopOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M928 140H96c-17.7 0-32 14.3-32 32v496c0 17.7 14.3 32 32 32h380v112H304c-8.8 0-16 7.2-16 16v48c0 4.4 3.6 8 8 8h432c4.4 0 8-3.6 8-8v-48c0-8.8-7.2-16-16-16H548V700h380c17.7 0 32-14.3 32-32V172c0-17.7-14.3-32-32-32zm-40 488H136V212h752v416z\" } }] }, \"name\": \"desktop\", \"theme\": \"outlined\" };\nexport default DesktopOutlined;\n","// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nimport * as React from 'react';\nimport DesktopOutlinedSvg from \"@ant-design/icons-svg/es/asn/DesktopOutlined\";\nimport AntdIcon from '../components/AntdIcon';\n\nvar DesktopOutlined = function DesktopOutlined(props, ref) {\n return React.createElement(AntdIcon, Object.assign({}, props, {\n ref: ref,\n icon: DesktopOutlinedSvg\n }));\n};\n\nDesktopOutlined.displayName = 'DesktopOutlined';\nexport default React.forwardRef(DesktopOutlined);","// This icon file is generated automatically.\nvar TeamOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M824.2 699.9a301.55 301.55 0 00-86.4-60.4C783.1 602.8 812 546.8 812 484c0-110.8-92.4-201.7-203.2-200-109.1 1.7-197 90.6-197 200 0 62.8 29 118.8 74.2 155.5a300.95 300.95 0 00-86.4 60.4C345 754.6 314 826.8 312 903.8a8 8 0 008 8.2h56c4.3 0 7.9-3.4 8-7.7 1.9-58 25.4-112.3 66.7-153.5A226.62 226.62 0 01612 684c60.9 0 118.2 23.7 161.3 66.8C814.5 792 838 846.3 840 904.3c.1 4.3 3.7 7.7 8 7.7h56a8 8 0 008-8.2c-2-77-33-149.2-87.8-203.9zM612 612c-34.2 0-66.4-13.3-90.5-37.5a126.86 126.86 0 01-37.5-91.8c.3-32.8 13.4-64.5 36.3-88 24-24.6 56.1-38.3 90.4-38.7 33.9-.3 66.8 12.9 91 36.6 24.8 24.3 38.4 56.8 38.4 91.4 0 34.2-13.3 66.3-37.5 90.5A127.3 127.3 0 01612 612zM361.5 510.4c-.9-8.7-1.4-17.5-1.4-26.4 0-15.9 1.5-31.4 4.3-46.5.7-3.6-1.2-7.3-4.5-8.8-13.6-6.1-26.1-14.5-36.9-25.1a127.54 127.54 0 01-38.7-95.4c.9-32.1 13.8-62.6 36.3-85.6 24.7-25.3 57.9-39.1 93.2-38.7 31.9.3 62.7 12.6 86 34.4 7.9 7.4 14.7 15.6 20.4 24.4 2 3.1 5.9 4.4 9.3 3.2 17.6-6.1 36.2-10.4 55.3-12.4 5.6-.6 8.8-6.6 6.3-11.6-32.5-64.3-98.9-108.7-175.7-109.9-110.9-1.7-203.3 89.2-203.3 199.9 0 62.8 28.9 118.8 74.2 155.5-31.8 14.7-61.1 35-86.5 60.4-54.8 54.7-85.8 126.9-87.8 204a8 8 0 008 8.2h56.1c4.3 0 7.9-3.4 8-7.7 1.9-58 25.4-112.3 66.7-153.5 29.4-29.4 65.4-49.8 104.7-59.7 3.9-1 6.5-4.7 6-8.7z\" } }] }, \"name\": \"team\", \"theme\": \"outlined\" };\nexport default TeamOutlined;\n","// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nimport * as React from 'react';\nimport TeamOutlinedSvg from \"@ant-design/icons-svg/es/asn/TeamOutlined\";\nimport AntdIcon from '../components/AntdIcon';\n\nvar TeamOutlined = function TeamOutlined(props, ref) {\n return React.createElement(AntdIcon, Object.assign({}, props, {\n ref: ref,\n icon: TeamOutlinedSvg\n }));\n};\n\nTeamOutlined.displayName = 'TeamOutlined';\nexport default React.forwardRef(TeamOutlined);","// This icon file is generated automatically.\nvar BlockOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M856 376H648V168c0-8.8-7.2-16-16-16H168c-8.8 0-16 7.2-16 16v464c0 8.8 7.2 16 16 16h208v208c0 8.8 7.2 16 16 16h464c8.8 0 16-7.2 16-16V392c0-8.8-7.2-16-16-16zm-480 16v188H220V220h360v156H392c-8.8 0-16 7.2-16 16zm204 52v136H444V444h136zm224 360H444V648h188c8.8 0 16-7.2 16-16V444h156v360z\" } }] }, \"name\": \"block\", \"theme\": \"outlined\" };\nexport default BlockOutlined;\n","// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nimport * as React from 'react';\nimport BlockOutlinedSvg from \"@ant-design/icons-svg/es/asn/BlockOutlined\";\nimport AntdIcon from '../components/AntdIcon';\n\nvar BlockOutlined = function BlockOutlined(props, ref) {\n return React.createElement(AntdIcon, Object.assign({}, props, {\n ref: ref,\n icon: BlockOutlinedSvg\n }));\n};\n\nBlockOutlined.displayName = 'BlockOutlined';\nexport default React.forwardRef(BlockOutlined);","// This icon file is generated automatically.\nvar BarChartOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M888 792H200V168c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v688c0 4.4 3.6 8 8 8h752c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm-600-80h56c4.4 0 8-3.6 8-8V560c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v144c0 4.4 3.6 8 8 8zm152 0h56c4.4 0 8-3.6 8-8V384c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v320c0 4.4 3.6 8 8 8zm152 0h56c4.4 0 8-3.6 8-8V462c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v242c0 4.4 3.6 8 8 8zm152 0h56c4.4 0 8-3.6 8-8V304c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v400c0 4.4 3.6 8 8 8z\" } }] }, \"name\": \"bar-chart\", \"theme\": \"outlined\" };\nexport default BarChartOutlined;\n","// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nimport * as React from 'react';\nimport BarChartOutlinedSvg from \"@ant-design/icons-svg/es/asn/BarChartOutlined\";\nimport AntdIcon from '../components/AntdIcon';\n\nvar BarChartOutlined = function BarChartOutlined(props, ref) {\n return React.createElement(AntdIcon, Object.assign({}, props, {\n ref: ref,\n icon: BarChartOutlinedSvg\n }));\n};\n\nBarChartOutlined.displayName = 'BarChartOutlined';\nexport default React.forwardRef(BarChartOutlined);","// This icon file is generated automatically.\nvar CodepenOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M911.7 385.3l-.3-1.5c-.2-1-.3-1.9-.6-2.9-.2-.6-.4-1.1-.5-1.7-.3-.8-.5-1.7-.9-2.5-.2-.6-.5-1.1-.8-1.7-.4-.8-.8-1.5-1.2-2.3-.3-.5-.6-1.1-1-1.6-.8-1.2-1.7-2.4-2.6-3.6-.5-.6-1.1-1.3-1.7-1.9-.4-.5-.9-.9-1.4-1.3-.6-.6-1.3-1.1-1.9-1.6-.5-.4-1-.8-1.6-1.2-.2-.1-.4-.3-.6-.4L531.1 117.8a34.3 34.3 0 00-38.1 0L127.3 361.3c-.2.1-.4.3-.6.4-.5.4-1 .8-1.6 1.2-.7.5-1.3 1.1-1.9 1.6-.5.4-.9.9-1.4 1.3-.6.6-1.2 1.2-1.7 1.9-1 1.1-1.8 2.3-2.6 3.6-.3.5-.7 1-1 1.6-.4.7-.8 1.5-1.2 2.3-.3.5-.5 1.1-.8 1.7-.3.8-.6 1.7-.9 2.5-.2.6-.4 1.1-.5 1.7-.2.9-.4 1.9-.6 2.9l-.3 1.5c-.2 1.5-.3 3-.3 4.5v243.5c0 1.5.1 3 .3 4.5l.3 1.5.6 2.9c.2.6.3 1.1.5 1.7.3.9.6 1.7.9 2.5.2.6.5 1.1.8 1.7.4.8.7 1.5 1.2 2.3.3.5.6 1.1 1 1.6.5.7.9 1.4 1.5 2.1l1.2 1.5c.5.6 1.1 1.3 1.7 1.9.4.5.9.9 1.4 1.3.6.6 1.3 1.1 1.9 1.6.5.4 1 .8 1.6 1.2.2.1.4.3.6.4L493 905.7c5.6 3.8 12.3 5.8 19.1 5.8 6.6 0 13.3-1.9 19.1-5.8l365.6-243.5c.2-.1.4-.3.6-.4.5-.4 1-.8 1.6-1.2.7-.5 1.3-1.1 1.9-1.6.5-.4.9-.9 1.4-1.3.6-.6 1.2-1.2 1.7-1.9l1.2-1.5 1.5-2.1c.3-.5.7-1 1-1.6.4-.8.8-1.5 1.2-2.3.3-.5.5-1.1.8-1.7.3-.8.6-1.7.9-2.5.2-.5.4-1.1.5-1.7.3-.9.4-1.9.6-2.9l.3-1.5c.2-1.5.3-3 .3-4.5V389.8c-.3-1.5-.4-3-.6-4.5zM546.4 210.5l269.4 179.4-120.3 80.4-149-99.6V210.5zm-68.8 0v160.2l-149 99.6-120.3-80.4 269.3-179.4zM180.7 454.1l86 57.5-86 57.5v-115zm296.9 358.5L208.3 633.2l120.3-80.4 149 99.6v160.2zM512 592.8l-121.6-81.2L512 430.3l121.6 81.2L512 592.8zm34.4 219.8V652.4l149-99.6 120.3 80.4-269.3 179.4zM843.3 569l-86-57.5 86-57.5v115z\" } }] }, \"name\": \"codepen\", \"theme\": \"outlined\" };\nexport default CodepenOutlined;\n","// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nimport * as React from 'react';\nimport CodepenOutlinedSvg from \"@ant-design/icons-svg/es/asn/CodepenOutlined\";\nimport AntdIcon from '../components/AntdIcon';\n\nvar CodepenOutlined = function CodepenOutlined(props, ref) {\n return React.createElement(AntdIcon, Object.assign({}, props, {\n ref: ref,\n icon: CodepenOutlinedSvg\n }));\n};\n\nCodepenOutlined.displayName = 'CodepenOutlined';\nexport default React.forwardRef(CodepenOutlined);","// This icon file is generated automatically.\nvar DownOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z\" } }] }, \"name\": \"down\", \"theme\": \"outlined\" };\nexport default DownOutlined;\n","// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nimport * as React from 'react';\nimport DownOutlinedSvg from \"@ant-design/icons-svg/es/asn/DownOutlined\";\nimport AntdIcon from '../components/AntdIcon';\n\nvar DownOutlined = function DownOutlined(props, ref) {\n return React.createElement(AntdIcon, Object.assign({}, props, {\n ref: ref,\n icon: DownOutlinedSvg\n }));\n};\n\nDownOutlined.displayName = 'DownOutlined';\nexport default React.forwardRef(DownOutlined);","// This icon file is generated automatically.\nvar MenuUnfoldOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M408 442h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8zm-8 204c0 4.4 3.6 8 8 8h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56zm504-486H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 632H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM142.4 642.1L298.7 519a8.84 8.84 0 000-13.9L142.4 381.9c-5.8-4.6-14.4-.5-14.4 6.9v246.3a8.9 8.9 0 0014.4 7z\" } }] }, \"name\": \"menu-unfold\", \"theme\": \"outlined\" };\nexport default MenuUnfoldOutlined;\n","// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nimport * as React from 'react';\nimport MenuUnfoldOutlinedSvg from \"@ant-design/icons-svg/es/asn/MenuUnfoldOutlined\";\nimport AntdIcon from '../components/AntdIcon';\n\nvar MenuUnfoldOutlined = function MenuUnfoldOutlined(props, ref) {\n return React.createElement(AntdIcon, Object.assign({}, props, {\n ref: ref,\n icon: MenuUnfoldOutlinedSvg\n }));\n};\n\nMenuUnfoldOutlined.displayName = 'MenuUnfoldOutlined';\nexport default React.forwardRef(MenuUnfoldOutlined);","// This icon file is generated automatically.\nvar MenuFoldOutlined = { \"icon\": { \"tag\": \"svg\", \"attrs\": { \"viewBox\": \"64 64 896 896\", \"focusable\": \"false\" }, \"children\": [{ \"tag\": \"path\", \"attrs\": { \"d\": \"M408 442h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8zm-8 204c0 4.4 3.6 8 8 8h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56zm504-486H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 632H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM115.4 518.9L271.7 642c5.8 4.6 14.4.5 14.4-6.9V388.9c0-7.4-8.5-11.5-14.4-6.9L115.4 505.1a8.74 8.74 0 000 13.8z\" } }] }, \"name\": \"menu-fold\", \"theme\": \"outlined\" };\nexport default MenuFoldOutlined;\n","// GENERATE BY ./scripts/generate.ts\n// DON NOT EDIT IT MANUALLY\nimport * as React from 'react';\nimport MenuFoldOutlinedSvg from \"@ant-design/icons-svg/es/asn/MenuFoldOutlined\";\nimport AntdIcon from '../components/AntdIcon';\n\nvar MenuFoldOutlined = function MenuFoldOutlined(props, ref) {\n return React.createElement(AntdIcon, Object.assign({}, props, {\n ref: ref,\n icon: MenuFoldOutlinedSvg\n }));\n};\n\nMenuFoldOutlined.displayName = 'MenuFoldOutlined';\nexport default React.forwardRef(MenuFoldOutlined);"],"sourceRoot":""}
\ No newline at end of file
diff --git a/src/main/resources/static/static/js/main.45138d6f.chunk.js b/src/main/resources/static/static/js/main.45138d6f.chunk.js
deleted file mode 100644
index 296ad3a..0000000
--- a/src/main/resources/static/static/js/main.45138d6f.chunk.js
+++ /dev/null
@@ -1,2 +0,0 @@
-(this["webpackJsonpr-demo"]=this["webpackJsonpr-demo"]||[]).push([[0],{219:function(e,t){e.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAXwAAAC0CAYAAACXK5enAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA2RpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDpCODVDNUU3OTVFQ0RFMDExOUUxNThFN0U4MzkzMDczQyIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDoxQTlBNkI5RENENjMxMUUwOEM0QUNGMDNENDRDRTU0QyIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDoxQTlBNkI5Q0NENjMxMUUwOEM0QUNGMDNENDRDRTU0QyIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgQ1M1IFdpbmRvd3MiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDpCODVDNUU3OTVFQ0RFMDExOUUxNThFN0U4MzkzMDczQyIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDpCODVDNUU3OTVFQ0RFMDExOUUxNThFN0U4MzkzMDczQyIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PivWX8wAACBRSURBVHja7J17UFXXvcdRkQPnEIGggMQkIAyCJGpjGgIGNWpich0SO+IrBXkZRPFBMu2YzL3NtJPemc7kj+rN7W1vm2gliTfeqJNbkw7UiW3qo72N1dimITW+LrGKGBXSoBw4Se/vR/fPbo8HOAfOY629v9+ZNeegPPZZ6/f77O/+7bXXGvG3v/0tCoIgCLK+RqILIAiCAHwIgiAIwIcgCIIAfAiCIAjAhyAIgiKnaPMXbrd7WL+srKwMPQpFQmkjRozgNo3ex9NrNjX+92xqLuN9vzJmql2g1sbvqb1P7z+n1xPc+D26GFJdr7766g1fOxyOgYEPQRqIgT6N28iRIxnsUxno3OjrKHlvbv6IwJ5qNH4/9csvv4wy3kfR+y4D/u9LwzBA2jt8O8iAwFqCwyL5WlUZwOki4CyjV9u6TMOxP0Bjxi2Lwe6rjRo16jr0veHvRz8L3H01F7WpX3zxBZ8IKox/O2jA/wC1NqAEea1DXkfbLSgICmnR0dGLqPVBQWUxWDIyMn77zDPPdJeXl0fZ6SE5o0RTypCnMUsVoPO48au5eUNexjVAh39T8wa/x+OJIuhLm2G0evq/k9Sa6Gea7HxiRl6rn9e2Aj4HQlxcXM3o0aP76lsMC1WdgAEc94IFC3bW1NR4+DitDnwD0I/QOJXS2GQJ0DmJzU0gL83byXu/BtLn3vCXBJUTgACf4S+Nvs6i13qGP7WD9H07UfZBXquY17YBPncswSKNgmEeBUdUbGxsX2CoKoZKamrqgbvvvvuEypenQRqbeIa8AXoXJy6DXV7Nrr4/yAcrRvo7UZhdP7/y+Ijrl9bb28tNnP8Faj81XD+ojLxWIq9tA3wOAgqGGnYA3GJiYpS99GNAUDC4H3zwwZ319fUegYxVQU9jU0pJ62Kw87gw6AX2viAfwauP6zHDx8bjwscpzt8E/aienp5U+nojtUqAH3mtSl5HB/sDqeoCKAi4JjyPE1QcgKrHKy4gLy/vBIGjDyTmEoMVXBmNxyM0DmsZ9DwmnKgCezPovSGvUh/IiYiPSUpPfPw8XvxZeOwY/HQCYPCX0rj+u3GjF6RGXkckr6PtEBTiAgQoqtf4SO7i4uKda9as8XBQWMXhG/DOpv5/huCYJZBnZ+YL9LrFmPmeg5zEDOjzMy5ZBP7v03gepMT/XtTf5/mD2shrlHRCcNmXRhCZx4HByagyTDgIxAVwaYBdgRWS0xiHSur/Crm5JpfguoJ+INfvDX9u/GAjwX8GtdcZ+jTWBwB95DWAb2MXQMfXUVtb22gVd2929TQGfa6eb6yJu7cK6H19bvPNZjP0uYxFr89T4sPtI68BfDu7gMzMzOaGhoZWK7h7qdVT36+jpHSyoxfYCwxtMAMpSuaGczNPL+3u7p5B4/wytX+mbz0B6COvQ34FChegjgugAO4oKyvbzTVfDgxd3b3caOWbsgT5jTQGTpfLFcWNp87pkKShKPXILCSn0xkl/UF9k0J9tJlPjHbqD+R1ZPLa0g5fJxfAZ/2JEyc2b9iwoZ0DQ1d3b8A+nks4BLIZ7Oi5sbu3i6sfDFbey0FQc9L/baRxT+MpnAIKCHkNhx9AYlFArNepxicuQNdpmAJ76u/NBPkZ7GS52dXVDxaffBLkvpF+oq8rqI+eke+BkNdw+P67gGmUPIW6uQCp8ekKe+rvzQSuifLUI0A/MLzkYS7TOkDz+cYuweF7cPrIazh8PxOJgLNSpv3p6AJ0hr24einjAPYDJKBR2+eTo6nf5rPTj+STxchra+Z1tBUDg5KF10rPhwsIG+w5Af/VDHvVL7dVg755HR/j/XxqbRQTP7XDwnnIaw2BH+kPJJfH5JZWypObEhQqJoz5Dv7Bgwe1m5kjfctulJJwipRxuO9lPROUJAIqV/Q5V9MibRW81j65Q1uvw4O8hsMf6LLvBheg8trYfNbPyspqXr9+fd8dfN2mYRquq5RLEAx7uTlrxQepwlm2EOgbbaNstWhX6COvg3g1abVk4Rqf3MFXOSjMNT52APL0nW5JSLCvF9hLnwP2wz6JXp/BY0xp3Ux9HW/HfkVeA/iDugC57FPdBWRkZGjp7o2+jicQPSvz7FGzDx30CXT8lPKzdjyZIq8BfEu4ADrWM+Y7+Lq4e6mnMoCor1Mw9TI80KeYLuLymZ36GHkN4FvGBeTk5PyMXYCON2qpfx9gAGHqZYiT05iyKWsQ0WsVP2Vql75GXgP42rsADgJK3jMLFy7cp6O751IOHf96Wd5Yh02jdYe+LCdtlHbW26G0g7wG8C3hAjgI2AWsW7euU9bW0MHdSymHkm8x9fE4wD684JNlpSnGC3k+uk2Aj7wG8PV3AV/72tf26QR7U1+nUR+X6vCko9XgJyttcqN432Dlvkdeh07RugeGsaxsvnklRpX3tGQXsHbt2k4dgc9L0vK69mbY48Gq8Emcfm9vb4YR900W3dweeQ2H79sFmNfF1s0FaFa7v2FJWpRyIlfaMco7NVZ0+chrAH+gwHiE4DNWBwhxEEyaNKnPBcgdfF3E/UqX10sFNpiVE7lxEOhz3NP7BywKfOQ1gH+zC3A4HDfsegMXELK+5g1N5gP2kZfsj2vsnLVM5bhHXgP4QXUBFBBjdbh5aAF3P5NAH4enadWBIo8F17hpfNKsUl5DXgP4/Qa8cQPx+rZ5cAGh6WujjLAEsFfrJMxxz2PCpTYrAB95DeAP6AKkxgcXEPK+ziag3Gn3/WhVAz6PBY8JtWIrjAvyGsC3hAuIj49v0dHdC1hcLleJARbMzFFIprJOMo3LAzqPDfI6fNJqAxRxAdTGqr7JBh8TB0JxcfH2+vr6Tt12szLttfoVM+x1nfdNJ64z/OpwOK54PJ5YGos4arHd3d1pupd2EhIS7v/0008P6Do+yGtNgR8OFyB38FV3ARwAiYmJRwsKCt576aWXtNurVube0zHfrqO7p2PuSEtLOzJ58uQWGoPz9E+dxn+5jbgfZby63nnnncyWlpZ7Ojo6JtPndeh0QuaxoZPW/bo6fOQ1gN9vYFAw9NX4VL+BKC6AguKNNWvWuHV193TZei/3s06LdTHos7Oz9y1evPg39GU7tUvf/OY3u/iS23zZLXvH8md74YUXPpg7d+7/trW13fbzn/+8+Ny5czN0AL/U8knJxoNxbRxnugEfeQ3gW8IFFBUVHdmyZUuUbkkoMKF+n6UL8LnPU1NTD5WUlDSlp6f/+Rvf+Ea77DgkNVbZNtC8YTh/Nr40J9h0btq06XR1dfWpP/3pT4ebmpqWdHV1Zaj8uSUvOB9cLtfsnp6e13Va7gJ5DeD7DArDBVTq5ALuv//+N1avXu0W4OhWzjEgP1GArzrsc3Nzdy9ZsuRt+rJ13bp1Hoa9ODAz7M2fUU5s4pTr6uo8BJ/WzZs3X8jPz//kxRdfrL5y5cpXVI0107RZfj+Z3+sCIeR1hIycDgdpbKe3WDcXIMDRTab6/a2qA9+YHsew39HQ0HCKoU3OPOrq1atRbrc7StYmlwSVJv/GY8Tf193dHXXt2rUo/lm+XH/66ac/oBPHD5OSko6qnNTikukzTdZtnXzkNYDv08FwUPAqjTJlCy4g9M4rISEhT3XYc7+OGzfu0NKlS3fwLkMMeYa2QF76fqD+l//nEwcnshn8dAL5mKFPQGpTdQwlR+j4knXZ6Bx5DeAP6AJ4L09d9rS0hAv4e5kgV8odKiYi9zUdW8e8efO2M+wZ0gzroW4tZwY/nzAE/Az9goKCV1WdZ20u67hcrkm6OHzkdWSk7Dx8cZoUDLzDklP1ueB8THzmFxdgrh/rVs7hRsedLZfYKvY3921ubu6bOTk5fxbYB6O/5aYuj5/owQcf/NWHH35YdPHixSJVwcTHTPDMo9ffqzpmyGs4fL9dgOpzwTkwuN7LLkC3zU18JST1/S0qu3s6vo4lS5a8tWrVKk+wn3YUt8+Jzr97zZo1XXfdddebqo6pqUSSpIPDR14D+D4DmPdPlRqfbnfwVdyxPpCSDgX3BIG/iu7+zjvvbF67du0lqdcHu6/NdX3+G7NmzfqDqjdwJV/cbneGyjdukdcAvmVcQEpKyiEruAAT5ONUdffcv/n5+c0C+1AloRn6nPCJiYm/UXFsTQ+R3aLqSRp5DeBbxgWQ3PPnz99uBRdgACNNnKJq/c59y7Nm7r333k+GeoN2KCcY/luTJk36rcrAp2NLhrtHXmvn8HVyARwE5AIO8M1DK7h7VlJS0u2qOkXub5fLdZzn23svlxCqxOe/weM6Y8aM86pO0TSAf6vKDh95DeBbwgXMmjVrJwPICi7AmIMfoyI4BL4UHyfCOVNCXD6PMcXjp6rN0JCxMjfkNfLal5RbWoECg/dPLTUHhaodzRBIS0s7kJ+ff8JcT7aKBntoKRKuixvFxCfmJRPCdaLhv+lwOP6vu7v7LuM4VAYW8hp5rbbDN6aWrSMn4FR91xuzC6itrfXotpuVruI+/vzzz3vD7bgE+gT7XpUfwlISMshrAN9XsPL6LdQeFhegeo1PXICVLvnMK0mqWNIxVsVsD/fVhwDf6XR+qtqVj+rxhLwG8H26gLi4uBpyAlFyUwcuAPIF/Orq6tZIJSHF5l8wEshrAD8ILoBe56m+kJIdXIDq0F+1apU7Ei6b/15XV1cvHD7yGsAfhvgyj12ALKSEGh/kxxhE5OoCsEde66yIL55mTNnijaTnSVBEKqn9Ed/BHz9+fJ8LMG9xZhUIyOdQEW4ySydSx+YNfZX6xvt4In1syGs4/P4u+aJiY2O1dAEo50AQ8hrAD+yyr6/Gp/p0LXGY3i4AgiDkNYBvQRfAS/KuWbOmEe4egpDXAL7FXUBmZmZzfX19q6ytAUEQ8hrAt6AL4O30Kioqdod6SV4IgrtHXlvO4evkAviszy6ALvvaUbuHIOS1rgr7tEzTynnPysMYqu9pyS6gsrJy94EDB6LCsQZ7pD+v6lMPMS1TvWNDXsPhD3TZN43aFB1dAEo5EIS8BvD9Dwp++m6lTnfwq6qqdltx+WMIQl7bK68jAfxpdCmVr8OuN3D3EIS8BvCD5AJU38AY7h6CkNcA/jBcAL3m67AuNtw9BCGvraawbXHIQRAbG7vSvEyqqh1tdgHmO/h2kcozUczHh76JfN8gr+HwfQaFji5g9erVcPcQhLwG8AMNDJ1qfC6X64y5xgfYQxDyGsC3qAvIzc39WV1dHdw9BCGvAXyrugBjk+ozixYt2gd3D0HIawDfwi6AA4NdwKpVqzrh7iEIeW01hWwtHb5bz83hcGzQ4Q4+BwE5ljOlpaX73n77bduuiKnyFofexxSJtXTs3jfIazj8fgODguEROvtnyNoacAEQpLeQ1wC+z6DgQKCAqPFeOU/VoOAa3+LFi/fJJgiAPQQhrwF8/wPjEQqIsXABEGQp4COvAfybXYDD4bhh1xu4AAjS390jrwH8fl2ATNdSfU9LuAAIQl7bQUFfS4cDgV2Aucan+h18dgF8B59dgN0DQ4ddnbzfo29C2zeymxXyGg7/Jtgbd/C1cQF5eXk/q62t7eTpWrjsgyDkNYAfoLuXTRBUr/GNGTOmBTU+CPLP3SOvAfwbpIsL4ADgwJg9e/b2J598Ei4Agizg7pHXYQa+Li6AAyApKeloUVHRe3xDB0EBQfq7e+R1GIFfXl6ujQvgQKCgeGPlypVuBAYEWcPdI6/DBPzly5fH6+QCbr311qPFxcVHEBQQNKC7R15bTEGZlkkBsZiCY6wspCQDoGJQcF2PXUBNTQ1cwAD9pPoCYdjiMLTHxXmMvIbD9+nu6cxfqosLSE5OhguAoEFgT3mMvIbDv1l0ybd49OjRTllbQ4caH7sAWSY10ESgtkneq/K5SE302oQgh4IFfOS1NfN6WMBnd+90Oq+7ANX3tBQX8JOf/CRgFyAzFuhzTuVXFT6rTENLSEj4+OLFi3A1UEjcPfLaOnk9LOCLC9DpDv5wXAAHf2xsrDILR/Fn4M8VFxcXzcejWl0Z0tvdI6+tl9dDBr64ex3WxR6uCzAHBrseDg5+r0Jg8NOE5sQE8KFguHvktTXzesifju/gU+c4dbiDz4FQWFj4RnV19ZDv4MvWbnzG5c+sSmBwMwfFcMdA5W38zMcViXizct9IfCOvrZnXoiGdvpctW6aVC0hNTT00c+bMI7JM6nBdkGoNgoICg5EjkdcWz+shjahONT6Se8GCBdvZBWBtDQjyDTtjCQXktdVP6lZ293zWHz9+/IHc3Nw/yyUfBEF6u3vkdRiBr5MLoGNzz5kzZ2dVVZVH7uDDBUCQ3u4eeR0m4Ovo7u++++4TcAEQZC13j7wemgK6JR0TE7NOlzv4pD4XUFlZ6QlGjU/F7e18zcoIxiwdXdaLwRaHwzs208wc5LXF8zpgh0/uPo1cwMO6uQAJCgiCbgY+5TTy2k5Xc/5+Y1xcXN8yqTqsrcE1vrlz5153AajxQdDNsGe4I68B/Ju0fPnyNOrsefLoseobGMMFQJB/7h55DeDfpNjY2BoOCtUDAy4Agvx398hrAL9fdy8r58EFQJB13D3y2l4adJYOb3EmGyDocAefXUBFRYVHHrcO1rGquI5KKGYYqLxeTCTX0bFS3xgrYiKvbZTXfjl8npmjswvAJR8EWc/dI69DBHyp8cl0LZVrfHSMHU899VQjuwAODAQFBPlIeFPtHnkN4Gvr7idOnNj85JNPtsIFQJB13D3yOkzA18kFUBB3UFDs5k0D4AIgyBruHnkdJuDr5O75rJ+VldW8cuXKduxYD0HWcPfI69DI5ywdCohnvefmqnoHX1zA/v37o4J9B9/7b6m65kaoZ+qoNN6RHgMd+0bm3SOv7Z3X/QKfgmOKXPap7AK4E9xud2Jtbe0OI0hCd2Y0LoFVW2uEx+fSpUsL6fgWytZofgbUU9Teh2uyTzkHeW3tvC4tLe3L6127dr0fEPB1qPF5uxdZxztUADMcklJPJMpqh7IJsz+fX/YCnTBhguvkyZPKujwouLHLcYu8tkdeB+zwVT3r+eoYHiiHw9F3zMPd19KfpFFtRUH5/Pzqz2Uvfw9fIksi4alF60vgiby2R14HDHwJEF0CWZxLuP6eSk5AjocDwx8XxICXpAfw7QV95LU98jpg4Ot2uYpEHhHQ90twqH5ZDwU3TpDX9sjrAfsVqQBBEGQP+XT4Ki4OBQVHg0350mUbP/k60n2nS9+oetxQaMYfDh+CIMjmAvAhHRUfqT/c09PjQvdDAD4EhUF8c8rpdE6KxN9lXbt2LQujAAH4EBQmjRs3LjbQWQzBksPhiMHsJgjAh6AwuGxuV69eTYnU3+/t7R1rdvwQpJP6nYePu/nW1GCzNVSfiWK8pkfqGAj4KQx7hfum3xk6yGt75DUcPhSQ0tPT21WFAsO2u7v7rkiUdIy/nROpctJgcjgcHYheCMCHAnIKq1evblUV9tx6enpyR44cGR/uv01/8wFVn1DmcRs9evRlRDAE4EMBlQXKy8vdBDa3ai5f1hgxFpaaGU7w8t91uVxz+W8rvCzF5yjXQAA+FDD0nU7nX1R0+AJ8agvCBV7j78Z7PJ4CFWEvtdv4+PhPUKOHAHwoIBnLsSrpFmUFQTrGyfQ6LRzwNdZMX0yvcSqtm+4N/S+++KIDwIcAfMgybtG8mYfD4VgZ6lUVxd3Ta6mqm4fIOCUnJ58G7KGBhMXTbAr0/qbp8Xt2+HFxcSdCtY9osFw+KZ8AXEpf7wzFJhlyk5hOLs8S7J3mrQFV6hfZAi8nJ6fl4MGDWi2IB4Umr+HwoYACJy0t7SNV4SCbY/D2b/RaT/B/INiu27TN3FpqRbL5t6rrtNPxdTz66KPtADoE4EMBA3/FihWnCXQdqgKf4cvA523g6PXZYEJffg/9zkoC6SL+O6rte+o9ZrfccsuJsrIyD2APAfhQwCUCnpoZGxv7F1UBInu0MvCpOQnMzzOgh/tQlPHz8fS7v0uQr6A+uL63qqqw5/Gi4zyFkg0E4ENDhkhKSsrvVa/jGzdv+Z4Du/AKAvNL9H9Dmr1j3KB9hH7H6/Q7ZwjsZcN3VYHPLT8//xBvcQfYQwA+FDBAGB633Xbb71QGiLh8LrcwnBn6BOgs+vr7dDJ43bihmz0QqA1HP42+n2v1b9HPbqTf5eLfZZxElC3lyHhx6W3hwoUfqXpyhtRRNLoA6s/hL1269MThw4fbPB5PmjErRlnoy0NZ/L6np4cXOUulk1a9uF5qxwwYtlHjaZbxxmsW/5z8rOlmcN/XKsNexio5OfmPK1ascKOcAwH40JBdPtfxs7Ozj1+5ciVN6ctUo9wiN3MZ1HSSut6MaYtTDRhONTn766Uh/hlzk5OA6rDnzzZmzJhjfGILxdRUyAbAx80f68N8sHFmgDAsCwsL39qzZ89M1eHnDX6GtkBQXL4ZiAJ7AbucLLxBr3IO8OehY+7YsGHDr+hq7Pp8/MHGHnlt7byGw4eGFDwMj4cffvgPe/fu7Svr6LDphzh2AfhADxyZXb656TRORjnnEur3kF+mCF0A9ece2RlzWScjI+OXupULvEs8Up/3blKn1+EKxhv2PCYFBQV7pGwF4EMAPjQs6DNM7rnnnr0EQ7fOQNHZyfcHfJfLdYavwKR0BeBDAD40LAfJMCksLPxk3Lhxh3FTUK2TcWZm5l6+AsP8ewjAh4ICfYbJ17/+dc999933P3CR6sCeb9bW1tY2o5wDAfhQUOHCUHnooYf+MHbs2KMAixon4pycnOaKiopLAD4E4ENBA4u4/LKyMvfMmTPfoH92Ay6RHROHw9FWV1e3u7e3F7CHAhLm4dsU4vLeH4fPwGe4zJ49+8jhw4cPnD17dq6qywRbXTwWBQUFu1asWNHOY+JP/R7r4dsrr+HwoWFJyjrs8h966KGdXD8GNCIzDgkJCS1Lly7d6y/sIWhQh5+VlbVPFo2C/iGeynfq1Kk5qk3pi4+PPzN27NhT/kKD15pxuVztH330kd/ugX+OITN16tQTU6ZMefPIkSOViI/wOjieGksn3O3k7jsDBT5/H/LaHnkdMPA3bty4DWHgWw0NDXMkSFRxfTTILevXr389wB+98M477wTs8p944gnP9u3b3zp58mTBZ599lofSTviAT8DeW1xc/N4PfvCDgGr3csJGXtsjrwc8uZmDxu12D+sgKysrLRsQpqV4fymLa6kAAXZ5dJn/5vnz5zf74/ikJs9ugAHO7wPpA346lZcNfu6556b/6Ec/+hf6+UTdH2LSAfZjxoxp+c53vvPdsrKyc93d3X1XW/4C37yMtCqxi7wOfl43Njbe8G+8l4NfDn+ounr1qmUDQ7bUk8f1VQGBOG9/IWCeeRPog1Tyc3yyyM7OPlZYWPj6/v376wD80I4xe7Hy8vKXKyoqzsmJOpDaPX+v/AzHCMbLmnntj4IKfA5Gq0rO/qrNchAIc1DIND1/AyPQz2H+W/ww1muvvdZ04cKFO44fP/5PcI2hG9/HHnvsP/kEOxTYm8eZf1alsgXyOjR5HTbgW/nRe6mZqjYrwjzVbrDlcYMZiAwfcp2dr7zyymvPP//8+MuXL38FIAl+zE2ZMmX3nDlzfsEn2OHMzBnOid7qfWynvIYtg4YUjOwWGfpcZvjWt771Q17ICyAJbh9nZGTsq66u3kEn1q6hunsICpnDt3Iwqvjwiq9jCsdxyd+REl5lZeXHzz333H/8+Mc/frq7uzsNTn/4/ZucnHy0oaFhGz9gxZMp8FQt8hoOH4poUEqNkYE0ceLEo3V1df8WGxvbBigNH/Z81URXT62APRRMAfjQsCT1fJ6fn5GR8R6gHxzY81WTwB5P1EIAPqTMpSfXlhlOZugnJia2AFKB9SXX7AX2PB1P6vYQBOBDSkP/29/+9ovjx48/BOgPLl4ygWfjcM3eDHt5KA59CAVL2MQcCgr0WeJGGfoOh6Nl69atL1Nr++CDDxZ8+eWXDvSUjwSMju549NFHG+fMmXOwoqKi7watwB4rW0IAPqQF9PkmIwHs1LZt23bs27fv7N69e5fwDB701D/6KykpqaW6uvq/br/99iMrVqzokpq99CFgDwH4kBbQF3fK0wobGxt/QQ729KZNm0rOnDkzx+7TNkeOHOn+6le/unPZsmUH6cuPy8rKPAx789pGgD0E4EPaQZ+dPgGtKyYm5v0tW7Zcfvfdd1uampoW2dHti6uvqan57wkTJvyxqqrqkpRwsFUhBOBDWkPfXIfm9zyvfNu2bZdmzZp1YuvWrcV2qu3zVNWioqK3S0pKfs+unq58rrt68xURBAH4kLbgl41TZFlmk9s/d/bs2T/u2rWruLW1dYZVwT969OiOvLy8feTm99OXp+m101yrRwkHAvAVBpiKj2CrDAzvBaAYcAy68vLy9ldeeeXyhg0bThH49+/cudNS4GfQT548mUH/G/qylV779qA170Ng5cUGkddq5jWAD4VNAjlZ63v58uUeAmNrY2PjuYaGBt7K7Rdbt2697/jx40XXrl3TssbPD5xNnz79UElJCe8f2VpdXd0uS9zKU7Oo1UNw+JBt3JTcoBS3L+Dn9vLLL5+mb9t/7NixCc3NzYUXL16cTKBMVPkzxcXFtd1xxx1HHn/88SPp6enn6J/OEeg7BfLi6LFEAgTgQ7aUOH1x+7LcMpd6oqOj28npt0ydOvVD+tZb33333YyjR4/mXbhwYbIqzp9n26SkpJwuKiri4zxL/8SbR7dXVlZ65POYSzco30AAPgTwm8DPOw+xI+ZdiJ544gk3vZ7itmXLlpZZs2b9juF/7ty55F//+teZra2tmX/961/TqWWE+hhHjRrldjqd55OTk09lZWWdLikp4auQy9Q6qV2qqqpyy9WKN+QBekglBXUTc0oEy3YU73fJmwLv2LFjhoKH98miRYtaA9nYWtmAHDGiD/yyx6h3I+fPJiXBaE5+PXbsWBKdABJPnjyZSVcJsXwi4N919erV8QRfv24Cx8TEdND4dvB7Bju9754wYcL56dOnn09PT/+c/rmL2mcM+Zqamk65MpFSjTRVd1CCrJ/Xe/bsueFrX5uY/78AAwBEFWDqdJOv5QAAAABJRU5ErkJggg=="},220:function(e,t,n){e.exports=n(413)},225:function(e,t,n){},226:function(e,t,n){},232:function(e,t,n){},351:function(e,t,n){},366:function(e,t,n){},410:function(e,t,n){e.exports=n.p+"static/media/RudeCrab.bc5edf9f.png"},411:function(e,t,n){},412:function(e,t,n){},413:function(e,t,n){"use strict";n.r(t);var a=n(0),r=n.n(a),c=n(16),l=n.n(c),o=(n(225),n(226),n(72)),u=n(73),i=n(143),s=n(141),d=n(83),m=n(39),f=(n(66),n(32)),p=(n(155),n(50)),g=(n(146),n(89)),h=n(158),b=n.n(h),A=(n(90),n(49)),y=n(196),v=(n(232),n(414)),E=n(415),O=n(197),w=n.n(O),D=window.localStorage,j=function(){function e(){Object(o.a)(this,e)}return Object(u.a)(e,null,[{key:"put",value:function(e,t){if(D){var n=t;"object"===typeof t&&(n=JSON.stringify(t)),D.setItem(e,n)}}},{key:"get",value:function(e){if(D){var t=D.getItem(e);try{return JSON.parse(t)}catch(n){}return t}}},{key:"remove",value:function(e){D&&D.removeItem(e)}}]),e}(),I=function(e){j.put("login-jwt",e.token),j.put("id",e.id),j.put("username",e.username),j.put("resourceIds",e.resourceIds)},k=function(){return!!j.get("login-jwt")},x=function(){j.remove("login-jwt"),j.remove("id"),j.remove("username"),j.remove("resourceIds")},N=function(){return j.get("login-jwt")},P=function(){return j.get("id")},C=function(){return j.get("username")},H=function(){return j.get("resourceIds")},L=function(e){j.put("resourceIds",e)},z=w.a.create({baseURL:"http://localhost:8091/API"});z.interceptors.request.use((function(e){return k()&&(e.headers.Authorization=N()),e}),(function(e){return Promise.reject(e)})),z.interceptors.response.use((function(e){var t=e.data;return 1001===t.code&&(A.b.warn(t.data),x(),window.location.href="/"),0!==t.code?(A.b.warn(t.data),Promise.reject(e)):Promise.resolve(e)}),(function(e){return A.b.error("\u7cfb\u7edf\u9519\u8bef"),Promise.reject(e)}));var X=function(){function e(){Object(o.a)(this,e)}return Object(u.a)(e,null,[{key:"get",value:function(e,t){return z.get(e,{params:t}).then((function(e){return e.data}))}},{key:"put",value:function(e,t){return z.put(e,t).then((function(e){return e.data}))}},{key:"post",value:function(e,t){return z.post(e,t).then((function(e){return e.data}))}},{key:"delete",value:function(e,t){return z.delete(e,{params:t}).then((function(e){return e.data}))}}]),e}(),B=function(){var e=Object(y.a)(b.a.mark((function e(t){var n;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,X.post("/login",t);case 3:0===(n=e.sent).code&&(A.b.success("\u767b\u5f55\u6210\u529f"),console.log(n.data),I(n.data),window.location.href="/"),e.next=10;break;case 7:e.prev=7,e.t0=e.catch(0),console.log("\u51fa\u73b0\u9519\u8bef\uff1a",e.t0);case 10:case"end":return e.stop()}}),e,null,[[0,7]])})));return function(t){return e.apply(this,arguments)}}(),T=function(e){return k()?r.a.createElement(m.a,{to:"/"}):r.a.createElement("div",{className:"login"},r.a.createElement("div",{className:"login-content"},r.a.createElement("h2",null,"\u6b22\u8fce\u767b\u5f55"),r.a.createElement(p.a,{name:"normal_login",className:"login-form",initialValues:{remember:!0},onFinish:B},r.a.createElement(p.a.Item,{name:"username",rules:[{required:!0,message:"\u8bf7\u8f93\u5165\u7528\u6237\u540d"},{min:4,message:"\u6700\u5c11\u8f93\u51654\u4e2a\u5b57\u7b26"},{max:12,message:"\u6700\u591a\u8f93\u516512\u4e2a\u5b57\u7b26"}]},r.a.createElement(g.a,{prefix:r.a.createElement(v.a,{className:"site-form-item-icon"}),placeholder:"\u7528\u6237\u540d"})),r.a.createElement(p.a.Item,{name:"password",rules:[{required:!0,message:"\u8bf7\u8f93\u5165\u5bc6\u7801"},{min:4,message:"\u6700\u5c11\u8f93\u5165\u56db\u4e2a\u5b57\u7b26"},{max:12,message:"\u6700\u591a\u8f93\u516512\u4e2a\u5b57\u7b26"}]},r.a.createElement(g.a,{prefix:r.a.createElement(E.a,{className:"site-form-item-icon"}),type:"password",placeholder:"\u5bc6\u7801"})),r.a.createElement(p.a.Item,null,r.a.createElement(f.a,{type:"primary",htmlType:"submit",className:"login-form-button"},"\u767b\u5f55")))))},G=n(37),S=(n(349),n(106)),F=(n(351),n(422)),R=n(423),U=(n(189),n(56)),Z=n(135),M=n(416),Q=n(417),J=n(418),W=n(419),q=(n(191),n(104)),Y=(n(124),n(46)),V=(n(154),n(100)),K=n(42),_=(n(194),n(133)),$=(n(195),n(105)),ee=(n(366),function(){return j.get("role").map((function(e){var t={title:null,value:null};return t.title=e.name,t.value=e.id,t}))}),te=function(e){return j.get("resource").filter((function(t){return t.type===e})).map((function(e){var t={title:null,value:null};return t.title=e.name,t.value=e.id,t}))},ne=function(e){var t=e.resourceId,n=e.children;return!j.get("resource").map((function(e){return e.id})).includes(t)||H().includes(t)?r.a.createElement(r.a.Fragment,null,n):null},ae=function(e){var t=Object(a.useState)([]),n=Object(G.a)(t,2),c=n[0],l=n[1],o=Object(a.useState)(!1),u=Object(G.a)(o,2),i=u[0],s=u[1],d=Object(a.useState)(!1),m=Object(G.a)(d,2),p=m[0],g=m[1],h=Object(a.useState)({current:1,total:100,showSizeChanger:!1}),b=Object(G.a)(h,2),y=b[0],v=b[1],E=Object(a.useState)(!1),O=Object(G.a)(E,2),w=O[0],D=O[1],I=Object(a.useState)(!1),k=Object(G.a)(I,2),x=k[0],N=k[1],P=Object(a.useState)(null),C=Object(G.a)(P,2),H=C[0],L=C[1],z=[{title:"\u5e8f\u53f7",dataIndex:"order",key:"order",align:"center"},{title:"\u8d26\u6237\u540d",dataIndex:"username",key:"username",align:"center"},{title:"\u89d2\u8272",key:"roleIds",dataIndex:"roleIds",align:"center",ellipsis:{showTitle:!1},render:function(e){return r.a.createElement(r.a.Fragment,null,e.map((function(e){return r.a.createElement($.a,{color:"geekblue",key:e},function(e){var t=j.get("role"),n="";return t.forEach((function(t){if(t.id===e)return n=t.name})),n}(e))})))}},{title:"\u516c\u53f8",key:"companyIds",dataIndex:"companyIds",align:"center",ellipsis:{showTitle:!1},render:function(e){return r.a.createElement(r.a.Fragment,null,e.map((function(e){return r.a.createElement($.a,{color:"green",key:e},function(e){var t=j.get("company"),n="";return t.forEach((function(t){if(t.id===e)return n=t.name})),n}(e))})))}},{title:"\u64cd\u4f5c",key:"action",dataIndex:"action",align:"center",render:function(e,t){return r.a.createElement(_.a,{size:"small"},r.a.createElement(ne,{resourceId:1003},r.a.createElement(f.a,{size:"small",type:"link",onClick:function(e){L(t),D(!0)}},"\u7f16\u8f91")),r.a.createElement(ne,{resourceId:1002},r.a.createElement(f.a,{size:"small",type:"link",danger:!0,onClick:function(e){L(t),N(!0)}},"\u5220\u9664")))}}],B=function(e){g(!0),X.get("/user/page/"+e.current).then((function(t){var n=t.data.records;n.forEach((function(e,t){e.key=t,e.order=t+1})),l(n),v(Object(K.a)(Object(K.a)({},e),{},{total:t.data.total})),g(!1)}))};return Object(a.useEffect)((function(){B(y)}),[]),r.a.createElement("div",null,r.a.createElement("h1",null,"\u8d26\u6237\u7ba1\u7406"),r.a.createElement("div",{className:"tableTopButtons"},r.a.createElement(ne,{resourceId:1001},r.a.createElement(f.a,{type:"primary",href:"/#/user/username/add"},"\u65b0\u589e\u8d26\u6237"))),r.a.createElement(V.a,{dataSource:c,columns:z,loading:p,pagination:y,onChange:function(e){v(Object(K.a)({},e)),B(e)}}),r.a.createElement(q.a,{title:"\u6743\u9650\u7f16\u8f91",visible:w,confirmLoading:i,cancelText:"\u53d6\u6d88",okText:"\u786e\u8ba4",onOk:function(){s(!0),X.put("/user",H).then((function(e){A.b.success(e.msg),D(!1),B(y)})).finally((function(){s(!1)}))},onCancel:function(){D(!1)}},"\u89d2\u8272",r.a.createElement(Y.a,{treeData:ee(),value:null===H?[]:H.roleIds,style:{width:"100%"},showCheckedStrategy:Y.a.SHOW_CHILD,treeCheckable:!0,onChange:function(e){var t=Object(K.a)({},H);t.roleIds=e,L(t)},treeDefaultExpandAll:!0,placeholder:"\u8bf7\u9009\u62e9\u89d2\u8272"}),"\u516c\u53f8",r.a.createElement(Y.a,{treeData:j.get("company").map((function(e){var t={title:null,value:null};return t.title=e.name,t.value=e.id,t})),value:null===H?[]:H.companyIds,style:{width:"100%"},showCheckedStrategy:Y.a.SHOW_ALL,treeCheckable:!0,onChange:function(e){var t=Object(K.a)({},H);t.companyIds=e,L(t)},treeDefaultExpandAll:!0,placeholder:"\u8bf7\u9009\u62e9\u516c\u53f8"})),r.a.createElement(q.a,{title:"\u5220\u9664",visible:x,confirmLoading:i,cancelText:"\u53d6\u6d88",okText:"\u786e\u8ba4",onOk:function(){s(!0);var e={ids:[H.id]+""};X.delete("/user",e).then((function(e){A.b.success(e.msg),N(!1),B(Object(K.a)(Object(K.a)({},y),{},{current:1}))})).finally((function(){s(!1)}))},onCancel:function(){N(!1)}},"\u786e\u5b9a\u8981\u5220\u9664\u3010",H&&H.username,"\u3011\u5417"))},re=function(e){var t=j.get("resource"),n="";return t.forEach((function(t){if(t.id===e)return n=t.name})),n},ce=function(e,t){var n=j.get("resource"),a=!1;return n.forEach((function(n){if(n.type===t&&n.id===e)return a=!0})),a},le=function(e){var t=Object(a.useState)([]),n=Object(G.a)(t,2),c=n[0],l=n[1],o=Object(a.useState)(!1),u=Object(G.a)(o,2),i=u[0],s=u[1],d=Object(a.useState)(!1),m=Object(G.a)(d,2),p=m[0],g=m[1],h=Object(a.useState)({current:1,total:100,showSizeChanger:!1}),b=Object(G.a)(h,2),y=b[0],v=b[1],E=Object(a.useState)(!1),O=Object(G.a)(E,2),w=O[0],D=O[1],j=Object(a.useState)(!1),I=Object(G.a)(j,2),k=I[0],x=I[1],N=Object(a.useState)(null),P=Object(G.a)(N,2),C=P[0],H=P[1],L=[{title:"\u5e8f\u53f7",dataIndex:"order",key:"order",align:"center"},{title:"\u89d2\u8272\u540d",dataIndex:"name",key:"name",align:"center"},{title:"\u9875\u9762\u6743\u9650",key:"menu",dataIndex:"resourceIds",align:"center",ellipsis:{showTitle:!1},render:function(e){return r.a.createElement(r.a.Fragment,null,e.filter((function(e){return ce(e,0)})).map((function(e){return r.a.createElement($.a,{color:"geekblue",key:e},re(e))})))}},{title:"\u64cd\u4f5c\u6743\u9650",key:"operate",dataIndex:"resourceIds",align:"center",ellipsis:{showTitle:!1},render:function(e){return r.a.createElement(r.a.Fragment,null,e.filter((function(e){return ce(e,1)})).map((function(e){return r.a.createElement($.a,{color:"green",key:e},re(e))})))}},{title:"\u64cd\u4f5c",key:"action",dataIndex:"action",align:"center",render:function(e,t){return r.a.createElement(_.a,{size:"small"},r.a.createElement(ne,{resourceId:2003},r.a.createElement(f.a,{size:"small",type:"link",onClick:function(e){t.menusIds=t.resourceIds.filter((function(e){return ce(e,0)})),t.operateIds=t.resourceIds.filter((function(e){return ce(e,1)})),H(t),D(!0)}},"\u7f16\u8f91")),r.a.createElement(ne,{resourceId:2002},r.a.createElement(f.a,{size:"small",type:"link",danger:!0,onClick:function(e){H(t),x(!0)}},"\u5220\u9664")))}}],z=function(e){s(!0),X.get("/role/page/"+e.current).then((function(t){var n=t.data.records;n.forEach((function(e,t){e.key=t,e.order=t+1})),l(n),v(Object(K.a)(Object(K.a)({},e),{},{total:t.data.total})),s(!1)}))};Object(a.useEffect)((function(){z(y)}),[]);return r.a.createElement("div",null,r.a.createElement("h1",null,"\u89d2\u8272\u7ba1\u7406"),r.a.createElement("div",{className:"tableTopButtons"},r.a.createElement(ne,{resourceId:2001},r.a.createElement(f.a,{type:"primary",href:"/#/user/role/add"},"\u65b0\u589e\u89d2\u8272"))),r.a.createElement(V.a,{dataSource:c,columns:L,loading:i,pagination:y,onChange:function(e){v(Object(K.a)({},e)),z(e)}}),r.a.createElement(q.a,{title:"\u6743\u9650\u7f16\u8f91",visible:w,confirmLoading:p,cancelText:"\u53d6\u6d88",okText:"\u786e\u8ba4",onOk:function(){g(!0),X.put("/role",C).then((function(e){A.b.success(e.msg),D(!1),z(y)})).finally((function(){g(!1)}))},onCancel:function(){D(!1)}},"\u9875\u9762\u6743\u9650",r.a.createElement(Y.a,{treeData:te(0),value:null===C?[]:C.menusIds,style:{width:"100%"},showCheckedStrategy:Y.a.SHOW_CHILD,treeCheckable:!0,onChange:function(e){var t=Object(K.a)({},C);t.menusIds=e,t.resourceIds=t.operateIds.concat(e),H(t)},treeDefaultExpandAll:!0,placeholder:"\u8bf7\u9009\u62e9\u9875\u9762\u6743\u9650"}),"\u64cd\u4f5c\u6743\u9650",r.a.createElement(Y.a,{treeData:te(1),value:null===C?[]:C.operateIds,style:{width:"100%"},showCheckedStrategy:Y.a.SHOW_CHILD,treeCheckable:!0,onChange:function(e){var t=Object(K.a)({},C);t.operateIds=e,t.resourceIds=t.menusIds.concat(e),H(t)},treeDefaultExpandAll:!0,placeholder:"\u8bf7\u9009\u62e9\u64cd\u4f5c\u6743\u9650"})),r.a.createElement(q.a,{title:"\u5220\u9664",visible:k,confirmLoading:p,cancelText:"\u53d6\u6d88",okText:"\u786e\u8ba4",onOk:function(){g(!0);var e={ids:[C.id]+""};X.delete("/role",e).then((function(e){A.b.success(e.msg),x(!1),z(Object(K.a)(Object(K.a)({},y),{},{current:1}))})).finally((function(){g(!1)}))},onCancel:function(){x(!1)}},"\u786e\u5b9a\u8981\u5220\u9664\u3010",C&&C.name,"\u3011\u5417"))},oe=function(e){return Object(a.useEffect)((function(){X.get("/role/list").then((function(e){j.put("role",e.data)})),X.get("/resource/list").then((function(e){j.put("resource",e.data)})),X.get("/company/list").then((function(e){j.put("company",e.data)})),X.get("/user/resources/"+P()).then((function(e){L(e.data)}))}),[]),r.a.createElement("div",null,r.a.createElement("h1",null,"\u9996\u9875"),r.a.createElement("div",null,r.a.createElement("div",null,"\u535a\u5ba2\u3001Github\u3001\u516c\u4f17\u53f7\u8bf7\u8ba4\u51c6",r.a.createElement("strong",null,"RudeCrab"),"\uff0c\u6b22\u8fce\u5fae\u4fe1\u626b\u7801\u5173\u6ce8\uff1a"),r.a.createElement("img",{src:n(410),alt:"\u5fae\u4fe1\u4e8c\u7ef4\u7801"})))},ue=function(e,t){var n={"M+":e.getMonth()+1,"d+":e.getDate(),"h+":e.getHours(),"m+":e.getMinutes(),"s+":e.getSeconds(),"q+":Math.floor((e.getMonth()+3)/3),S:e.getMilliseconds()};for(var a in/(y+)/.test(t)&&(t=t.replace(RegExp.$1,(e.getFullYear()+"").substr(4-RegExp.$1.length))),n)new RegExp("("+a+")").test(t)&&(t=t.replace(RegExp.$1,1===RegExp.$1.length?n[a]:("00"+n[a]).substr((""+n[a]).length)));return t},ie=[{title:"\u5e8f\u53f7",dataIndex:"order",key:"order",align:"center"},{title:"\u5ba2\u6237\u540d",dataIndex:"customerName",key:"customerName",align:"center"},{title:"\u5ba2\u6237\u624b\u673a",key:"customerPhone",dataIndex:"customerPhone",align:"center"},{title:"\u8ba2\u5355\u4ef7\u683c",key:"price",dataIndex:"price",align:"center"},{title:"\u8ba2\u5355\u65f6\u95f4",key:"createTime",dataIndex:"createTime",align:"center",render:function(e){return ue(new Date(e),"yyyy-MM-dd hh:mm:ss")}},{title:"\u6240\u5c5e\u516c\u53f8",key:"companyName",dataIndex:"companyName",align:"center"}],se=function(e){var t=Object(a.useState)([]),n=Object(G.a)(t,2),c=n[0],l=n[1],o=Object(a.useState)(!1),u=Object(G.a)(o,2),i=u[0],s=u[1],d=Object(a.useState)({current:1,total:100,showSizeChanger:!1}),m=Object(G.a)(d,2),f=m[0],p=m[1];Object(a.useEffect)((function(){g(f)}),[]);var g=function(e){s(!0),X.get("/data/page/"+e.current).then((function(t){var n=t.data.records;n.forEach((function(e,t){e.key=t,e.order=t+1})),l(n),p(Object(K.a)(Object(K.a)({},e),{},{total:t.data.total})),s(!1)}))};return r.a.createElement("div",null,r.a.createElement("h1",null,"\u6570\u636e\u7ba1\u7406"),r.a.createElement(V.a,{dataSource:c,columns:ie,loading:i,pagination:f,onChange:function(e){p(Object(K.a)({},e)),g(e)}}))},de=[{path:"/",name:"\u9996\u9875",icon:r.a.createElement(M.a,null),component:oe},{path:"/user",name:"\u7528\u6237\u7ba1\u7406",icon:r.a.createElement(Q.a,null),routes:[{component:ae,icon:r.a.createElement(v.a,null),resId:1,name:"\u8d26\u6237\u7ba1\u7406",path:"/user/username"},{component:le,icon:r.a.createElement(J.a,null),resId:2,name:"\u89d2\u8272\u7ba1\u7406",path:"/user/role"}]},{resId:3,path:"/data",name:"\u6570\u636e\u7ba1\u7406",icon:r.a.createElement(W.a,null),component:se}],me=n(420),fe=Object(m.g)((function(e){var t=e.location.pathname;de.forEach((function(n){n.routes&&n.routes.forEach((function(n){e.location.pathname.includes(n.path)&&(t=n.path)}))}));var n=Object(a.useState)([]),c=Object(G.a)(n,2),l=c[0],o=c[1];Object(a.useEffect)((function(){de.forEach((function(t){t.routes&&t.routes.find((function(t){return e.location.pathname.includes(t.path)}))&&o([t.path])}))}),[]);return r.a.createElement("div",{className:"sidebar"},r.a.createElement("div",{className:"logo"},r.a.createElement(me.a,{className:"logo-icon"}),r.a.createElement("span",{className:"logo-title"},"RudeCrab")),r.a.createElement(U.a,{theme:e.theme,mode:"inline",defaultSelectedKeys:["/index"],selectedKeys:[t],openKeys:l,onOpenChange:function(e){o(e)}},function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return t.map((function(t){if(t.routes){var n=e(t.routes).filter((function(e){return e}));return n.length>0&&r.a.createElement(Z.a,{key:t.path,icon:t.icon,title:t.name},n)}return(H().includes(t.resId)||"/"===t.path)&&r.a.createElement(U.a.Item,{key:t.path,icon:t.icon},r.a.createElement(d.b,{to:t.path},t.name))}))}(de)))})),pe=(n(193),n(101)),ge=(n(411),n(421)),he=r.a.createElement(U.a,null,r.a.createElement(U.a.Item,{onClick:function(){x(),window.location.href="/"}},"\u9000\u51fa\u767b\u5f55")),be=function(e){return r.a.createElement(pe.a,{overlay:he},r.a.createElement("span",null,C()," ",r.a.createElement(ge.a,null)))},Ae=function(e){X.post("/user",e).then((function(e){0===e.code&&(A.b.success(e.data),window.location.href="/#/user/username")}))},ye=function(e){var t={name:e.name,resourceIds:[]};t.resourceIds=[].concat(e.menuIds||[],e.operateIds||[]),X.post("/role",t).then((function(e){0===e.code&&(X.get("/role/list").then((function(e){j.put("role",e.data)})),A.b.success(e.data),window.location.href="/#/user/role")}))},ve=[{component:function(e){return r.a.createElement("div",null,r.a.createElement("h1",null,"\u8d26\u6237\u65b0\u589e"),r.a.createElement(p.a,{labelCol:{span:2},wrapperCol:{span:6},onFinish:Ae},r.a.createElement(p.a.Item,{label:"\u7528\u6237\u540d",name:"username",rules:[{required:!0,message:"\u8bf7\u8f93\u5165\u7528\u6237\u540d"},{min:4,message:"\u6700\u5c11\u8f93\u51654\u4e2a\u5b57\u7b26"},{max:12,message:"\u6700\u591a\u8f93\u516512\u4e2a\u5b57\u7b26"}]},r.a.createElement(g.a,{placeholder:"\u9ed8\u8ba4\u5bc6\u780112345"})),r.a.createElement(p.a.Item,{label:"\u89d2\u8272",name:"roleIds"},r.a.createElement(Y.a,{treeData:ee(),style:{width:"100%"},showCheckedStrategy:Y.a.SHOW_CHILD,treeCheckable:!0,treeDefaultExpandAll:!0,placeholder:"\u70b9\u51fb\u9009\u62e9\u89d2\u8272"})),r.a.createElement(p.a.Item,{wrapperCol:{span:6,offset:2}},r.a.createElement(f.a,{style:{width:"50%"},href:"/#/user/username"},"\u8fd4\u56de"),r.a.createElement(f.a,{type:"primary",htmlType:"submit",style:{width:"50%"}},"\u786e\u5b9a"))))},name:"\u6dfb\u52a0\u8d26\u6237",path:"/user/username/add"},{component:function(e){return r.a.createElement("div",null,r.a.createElement("h1",null,"\u89d2\u8272\u6dfb\u52a0"),r.a.createElement(p.a,{labelCol:{span:2},wrapperCol:{span:6},onFinish:ye},r.a.createElement(p.a.Item,{label:"\u89d2\u8272\u540d",name:"name",rules:[{required:!0,message:"\u8bf7\u8f93\u5165\u89d2\u8272\u540d"},{max:12,message:"\u6700\u591a\u8f93\u516512\u4e2a\u5b57\u7b26"}]},r.a.createElement(g.a,{placeholder:"\u8bf7\u8f93\u5165\u89d2\u8272\u540d"})),r.a.createElement(p.a.Item,{label:"\u9875\u9762\u6743\u9650",name:"menuIds"},r.a.createElement(Y.a,{treeData:te(0),style:{width:"100%"},showCheckedStrategy:Y.a.SHOW_CHILD,treeCheckable:!0,treeDefaultExpandAll:!0,placeholder:"\u70b9\u51fb\u9009\u62e9\u9875\u9762\u6743\u9650"})),r.a.createElement(p.a.Item,{label:"\u64cd\u4f5c\u6743\u9650",name:"operateIds"},r.a.createElement(Y.a,{treeData:te(1),style:{width:"100%"},showCheckedStrategy:Y.a.SHOW_CHILD,treeCheckable:!0,treeDefaultExpandAll:!0,placeholder:"\u70b9\u51fb\u9009\u62e9\u64cd\u4f5c\u6743\u9650"})),r.a.createElement(p.a.Item,{wrapperCol:{span:6,offset:2}},r.a.createElement(f.a,{style:{width:"50%"},href:"/#/user/username"},"\u8fd4\u56de"),r.a.createElement(f.a,{type:"primary",htmlType:"submit",style:{width:"50%"}},"\u786e\u5b9a"))))},name:"\u6dfb\u52a0\u89d2\u8272",path:"/user/role/add"}],Ee=S.a.Header,Oe=S.a.Sider,we=S.a.Content,De=function(e){var t=Object(a.useState)(!1),n=Object(G.a)(t,2),c=n[0],l=n[1];return k()?r.a.createElement(S.a,null,r.a.createElement(Oe,{trigger:null,collapsible:!0,collapsed:c},r.a.createElement(fe,{theme:"dark"})),r.a.createElement(S.a,{className:"site-layout"},r.a.createElement(Ee,{className:"site-layout-background",style:{padding:0}},r.a.createElement(c?F.a:R.a,{className:"trigger",onClick:function(){l(!c)}}),r.a.createElement("div",{className:"box2"},r.a.createElement(be,null))),r.a.createElement(we,{className:"site-layout-background",style:{margin:"16px",padding:24,minHeight:"auto"}},r.a.createElement(m.d,null,function e(t){return t.map((function(t){return t.routes?e(t.routes):t.component?(H().includes(t.resId)||"/"===t.path)&&r.a.createElement(m.b,{exact:!0,path:t.path,component:t.component,key:t.path}):void 0}))}(de),ve.map((function(e){return r.a.createElement(m.b,{exact:!0,path:e.path,component:e.component,key:e.path})})),r.a.createElement(m.a,{to:"/404"}))))):r.a.createElement(m.a,{to:"/login"})},je=n(219),Ie=n.n(je),ke=(n(412),function(e){Object(i.a)(n,e);var t=Object(s.a)(n);function n(){var e;Object(o.a)(this,n);for(var a=arguments.length,r=new Array(a),c=0;c {\r\n if (LoginUtil.getLoginState()) {\r\n config.headers.Authorization = LoginUtil.getToken();\r\n }\r\n return config;\r\n}, error => Promise.reject(error));\r\n\r\n// 响应拦截器\r\naxiosInstance.interceptors.response.use(response => {\r\n const {data} = response;\r\n // 没有登录\r\n if (data.code === 1001) {\r\n message.warn(data.data);\r\n LoginUtil.removeLoginState();\r\n window.location.href = '/';\r\n }\r\n // 接口异常\r\n if (data.code !== 0) {\r\n message.warn(data.data);\r\n return Promise.reject(response);\r\n }\r\n return Promise.resolve(response);\r\n}, error => {\r\n message.error('系统错误');\r\n return Promise.reject(error)\r\n});\r\n\r\nexport default class Ajax {\r\n\r\n /**\r\n * get请求\r\n * @param url 请求地址\r\n * @param params 请求配置\r\n */\r\n public static get(url: string, params?: any) {\r\n return axiosInstance\r\n .get(url, {params})\r\n .then(response => response.data);\r\n }\r\n\r\n /**\r\n * put请求\r\n * @param url 请求地址\r\n * @param data 请求数据\r\n */\r\n public static put(url: string, data?: any) {\r\n return axiosInstance\r\n .put(url, data)\r\n .then(response => response.data);\r\n }\r\n\r\n /**\r\n * post请求\r\n * @param url 请求地址\r\n * @param data 请求数据\r\n */\r\n public static post(url: string, data?: any) {\r\n return axiosInstance\r\n .post(url, data)\r\n .then(response => response.data);\r\n }\r\n\r\n /**\r\n * delete请求\r\n * @param url 请求地址\r\n * @param params 请求数据\r\n */\r\n public static delete(url: string, params? :any) {\r\n return axiosInstance\r\n .delete(url, {params})\r\n .then(response => response.data);\r\n }\r\n\r\n\r\n}\r\n",
- "import React from 'react';\r\nimport './index.less';\r\nimport {Form, Input, Button, message} from 'antd';\r\nimport {UserOutlined, LockOutlined} from '@ant-design/icons';\r\nimport Ajax from \"../../api/Ajax\";\r\nimport LoginUtil from \"../../utils/LoginUtil\";\r\nimport { Redirect } from 'react-router-dom';\r\n\r\n// 表单验证完成执行登录逻辑\r\nconst onFinish = async values => {\r\n try {\r\n const body = await Ajax.post('/login', values);\r\n if (body.code === 0) {\r\n message.success('登录成功');\r\n console.log(body.data);\r\n LoginUtil.saveLoginUser(body.data);\r\n window.location.href = '/';\r\n }\r\n } catch (error) {\r\n console.log('出现错误:', error);\r\n }\r\n\r\n};\r\n\r\nconst Login = props => {\r\n // 如果已经登录了直接跳转到首页\r\n if (LoginUtil.getLoginState()) return ( );\r\n // 没有登录才能进入到登录页面\r\n return (\r\n \r\n );\r\n\r\n}\r\n\r\nexport default Login;\r\n",
- "/**\r\n * 权限菜单,用于权限树选择\r\n */\r\nimport LocalStore from \"../utils/LocalStore\";\r\n\r\nconst menuTree = [\r\n {\r\n title: '用户管理',\r\n value: '',\r\n path: '/user',\r\n children: [\r\n {title: '账户管理', path: '/user/username', value: 1,},\r\n {title: '角色管理', path: '/user/role', value: 2}\r\n ]\r\n },\r\n {\r\n title: '数据管理',\r\n path: '/data',\r\n value: 3\r\n }\r\n];\r\n\r\nconst getRoleTree = () => {\r\n const roleList = LocalStore.get('role');\r\n // 将角色字段转为树状图数据\r\n return roleList.map(role => {\r\n let roleNode = {title: null, value: null};\r\n roleNode.title = role.name;\r\n roleNode.value = role.id;\r\n return roleNode;\r\n });\r\n}\r\n\r\nconst getCompanyTree = () => {\r\n const companyList = LocalStore.get('company');\r\n // 将角色字段转为树状图数据\r\n return companyList.map(role => {\r\n let companyNode = {title: null, value: null};\r\n companyNode.title = role.name;\r\n companyNode.value = role.id;\r\n return companyNode;\r\n });\r\n}\r\n\r\nconst getResourceTree = (type: number) => {\r\n const resourceList = LocalStore.get('resource');\r\n // 将权限字段转为树状图数据\r\n return resourceList\r\n .filter(resource => resource.type === type)\r\n .map(resource => {\r\n let resourceNode = {title: null, value: null};\r\n resourceNode.title = resource.name;\r\n resourceNode.value = resource.id;\r\n return resourceNode;\r\n });\r\n}\r\n\r\n\r\nexport {menuTree, getRoleTree, getResourceTree, getCompanyTree};\r\n",
- "import React, {ReactNode} from 'react';\r\nimport LoginUtil from \"../utils/LoginUtil\";\r\nimport LocalStore from \"../utils/LocalStore\";\r\n\r\ninterface AuthProps {\r\n resourceId: number,\r\n children: ReactNode\r\n}\r\n\r\nconst Auth: React.FunctionComponent = props => {\r\n const {resourceId, children} = props;\r\n const resourceList = LocalStore.get('resource').map(i => i.id);\r\n // 如果资源字典里没有这个id,就代表此id已无需权限处理,直接返回组件\r\n if (!resourceList.includes(resourceId) || LoginUtil.getResourceIds().includes(resourceId)) {\r\n return (\r\n <>{children}>\r\n );\r\n } else {\r\n return null;\r\n }\r\n};\r\n\r\nexport default Auth;\r\n",
- "import React, {useEffect, useState} from 'react';\r\nimport Ajax from \"../../../api/Ajax\";\r\nimport {Button, Modal, Space, Table, Tag, TreeSelect} from \"antd\";\r\nimport {ColumnsType, TablePaginationConfig} from \"antd/es/table\";\r\nimport {message} from \"antd\";\r\nimport \"./index.less\";\r\nimport {getRoleTree, getCompanyTree} from \"../../../common/array\";\r\nimport LocalStore from \"../../../utils/LocalStore\";\r\nimport Auth from \"../../../common/Auth\";\r\n\r\n\r\n/**\r\n * 从后端接受的用户数据\r\n */\r\nexport interface User {\r\n id: number,\r\n username: string,\r\n roleIds: number[],\r\n companyIds: number[]\r\n}\r\n\r\n/**\r\n * 根据角色id获取对应的角色名称\r\n * @param roleId 角色id\r\n */\r\nconst getRoleTreeName = (roleId: number): string => {\r\n const role = LocalStore.get('role');\r\n let title = '';\r\n role.forEach(e => {\r\n if (e.id === roleId) {\r\n title = e.name;\r\n return title;\r\n }\r\n })\r\n return title;\r\n}\r\n/**\r\n * 根据公司id获取对应的角公司名称\r\n * @param companyId 公司id\r\n */\r\nconst getCompanyTreeName = (companyId: number): string => {\r\n const role = LocalStore.get('company');\r\n let title = '';\r\n role.forEach(e => {\r\n if (e.id === companyId) {\r\n title = e.name;\r\n return title;\r\n }\r\n })\r\n return title;\r\n}\r\n\r\nconst username = props => {\r\n const [users, setUsers] = useState([]);\r\n const [confirmLoading, setConfirmLoading] = useState(false);\r\n const [loading, setLoading] = useState(false);\r\n const [pagination, setPagination] = useState({\r\n current: 1,\r\n total: 100,\r\n showSizeChanger: false\r\n });\r\n\r\n const [modalVisible, setModalVisible] = useState(false);\r\n const [deleteVisible, setDeleteVisible] = useState(false);\r\n const [selectedUser, setSelectedUser] = useState(null);\r\n\r\n // 表设置\r\n const columns: ColumnsType = [\r\n {\r\n title: '序号',\r\n dataIndex: 'order',\r\n key: 'order',\r\n align: 'center',\r\n },\r\n {\r\n title: '账户名',\r\n dataIndex: 'username',\r\n key: 'username',\r\n align: 'center',\r\n },\r\n {\r\n title: '角色',\r\n key: 'roleIds',\r\n dataIndex: 'roleIds',\r\n align: 'center',\r\n ellipsis: {\r\n showTitle: false,\r\n },\r\n render: roleIds => (\r\n <>\r\n {roleIds.map(roleId => {\r\n return (\r\n