vdi/web-fe/serve/dist/644.async.js

5 lines
63 KiB
JavaScript

"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[644],{24969:function(Bt,Pt,v){v.d(Pt,{Z:function(){return rt}});var n=v(87462),St=v(67294),_e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M482 152h60q8 0 8 8v704q0 8-8 8h-60q-8 0-8-8V160q0-8 8-8z"}},{tag:"path",attrs:{d:"M192 474h672q8 0 8 8v60q0 8-8 8H160q-8 0-8-8v-60q0-8 8-8z"}}]},name:"plus",theme:"outlined"},Xe=_e,be=v(72298),N=function(ye,gt){return St.createElement(be.Z,(0,n.Z)({},ye,{ref:gt,icon:Xe}))},B=St.forwardRef(N),rt=B},87740:function(Bt,Pt,v){v.d(Pt,{Z:function(){return rt}});var n=v(87462),St=v(67294),_e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M758.2 839.1C851.8 765.9 912 651.9 912 523.9 912 303 733.5 124.3 512.6 124 291.4 123.7 112 302.8 112 523.9c0 125.2 57.5 236.9 147.6 310.2 3.5 2.8 8.6 2.2 11.4-1.3l39.4-50.5c2.7-3.4 2.1-8.3-1.2-11.1-8.1-6.6-15.9-13.7-23.4-21.2a318.64 318.64 0 01-68.6-101.7C200.4 609 192 567.1 192 523.9s8.4-85.1 25.1-124.5c16.1-38.1 39.2-72.3 68.6-101.7 29.4-29.4 63.6-52.5 101.7-68.6C426.9 212.4 468.8 204 512 204s85.1 8.4 124.5 25.1c38.1 16.1 72.3 39.2 101.7 68.6 29.4 29.4 52.5 63.6 68.6 101.7 16.7 39.4 25.1 81.3 25.1 124.5s-8.4 85.1-25.1 124.5a318.64 318.64 0 01-68.6 101.7c-9.3 9.3-19.1 18-29.3 26L668.2 724a8 8 0 00-14.1 3l-39.6 162.2c-1.2 5 2.6 9.9 7.7 9.9l167 .8c6.7 0 10.5-7.7 6.3-12.9l-37.3-47.9z"}}]},name:"redo",theme:"outlined"},Xe=_e,be=v(72298),N=function(ye,gt){return St.createElement(be.Z,(0,n.Z)({},ye,{ref:gt,icon:Xe}))},B=St.forwardRef(N),rt=B},55355:function(Bt,Pt,v){v.d(Pt,{Z:function(){return rt}});var n=v(87462),St=v(67294),_e={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"},Xe=_e,be=v(72298),N=function(ye,gt){return St.createElement(be.Z,(0,n.Z)({},ye,{ref:gt,icon:Xe}))},B=St.forwardRef(N),rt=B},56558:function(Bt,Pt,v){v.d(Pt,{Z:function(){return Ua}});var n=v(67294),St=v(93967),_e=v.n(St),Xe=v(87462),be=v(74902),N=v(1413),B=v(97685),rt=v(91),It=v(71002),ye=v(4942),gt=v(21770),Lt=v(80334),$n=v(8410),Bn=v(31131),an=v(42550),zn=function(t){var a=t.className,r=t.customizeIcon,o=t.customizeIconProps,u=t.children,l=t.onMouseDown,i=t.onClick,c=typeof r=="function"?r(o):r;return n.createElement("span",{className:a,onMouseDown:function(f){f.preventDefault(),l==null||l(f)},style:{userSelect:"none",WebkitUserSelect:"none"},unselectable:"on",onClick:i,"aria-hidden":!0},c!==void 0?c:n.createElement("span",{className:_e()(a.split(/\s+/).map(function(s){return"".concat(s,"-icon")}))},u))},Ft=zn,Un=function(t,a,r,o,u){var l=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,i=arguments.length>6?arguments[6]:void 0,c=arguments.length>7?arguments[7]:void 0,s=n.useMemo(function(){if((0,It.Z)(o)==="object")return o.clearIcon;if(u)return u},[o,u]),f=n.useMemo(function(){return!!(!l&&o&&(r.length||i)&&!(c==="combobox"&&i===""))},[o,l,r.length,i,c]);return{allowClear:f,clearIcon:n.createElement(Ft,{className:"".concat(t,"-clear"),onMouseDown:a,customizeIcon:s},"\xD7")}},on=n.createContext(null);function ln(){return n.useContext(on)}function jn(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:10,t=n.useState(!1),a=(0,B.Z)(t,2),r=a[0],o=a[1],u=n.useRef(null),l=function(){window.clearTimeout(u.current)};n.useEffect(function(){return l},[]);var i=function(s,f){l(),u.current=window.setTimeout(function(){o(s),f&&f()},e)};return[r,i,l]}function un(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:250,t=n.useRef(null),a=n.useRef(null);n.useEffect(function(){return function(){window.clearTimeout(a.current)}},[]);function r(o){(o||t.current===null)&&(t.current=o),window.clearTimeout(a.current),a.current=window.setTimeout(function(){t.current=null},e)}return[function(){return t.current},r]}function Gn(e,t,a,r){var o=n.useRef(null);o.current={open:t,triggerOpen:a,customizedTrigger:r},n.useEffect(function(){function u(l){var i;if(!((i=o.current)!==null&&i!==void 0&&i.customizedTrigger)){var c=l.target;c.shadowRoot&&l.composed&&(c=l.composedPath()[0]||c),o.current.open&&e().filter(function(s){return s}).every(function(s){return!s.contains(c)&&s!==c})&&o.current.triggerOpen(!1)}}return window.addEventListener("mousedown",u),function(){return window.removeEventListener("mousedown",u)}},[])}var P=v(15105);function Xn(e){return e&&![P.Z.ESC,P.Z.SHIFT,P.Z.BACKSPACE,P.Z.TAB,P.Z.WIN_KEY,P.Z.ALT,P.Z.META,P.Z.WIN_KEY_RIGHT,P.Z.CTRL,P.Z.SEMICOLON,P.Z.EQUALS,P.Z.CAPS_LOCK,P.Z.CONTEXT_MENU,P.Z.F1,P.Z.F2,P.Z.F3,P.Z.F4,P.Z.F5,P.Z.F6,P.Z.F7,P.Z.F8,P.Z.F9,P.Z.F10,P.Z.F11,P.Z.F12].includes(e)}var Kt=v(64217),Yn=v(39983),Jn=v(29972),Qn=["prefixCls","id","inputElement","autoFocus","autoComplete","editable","activeDescendantId","value","open","attrs"],qn=function(t,a){var r=t.prefixCls,o=t.id,u=t.inputElement,l=t.autoFocus,i=t.autoComplete,c=t.editable,s=t.activeDescendantId,f=t.value,h=t.open,I=t.attrs,d=(0,rt.Z)(t,Qn),p=u||n.createElement("input",null),C=p,m=C.ref,E=C.props;return(0,Lt.Kp)(!("maxLength"in p.props),"Passing 'maxLength' to input element directly may not work because input in BaseSelect is controlled."),p=n.cloneElement(p,(0,N.Z)((0,N.Z)((0,N.Z)({type:"search"},(0,Jn.Z)(d,E,!0)),{},{id:o,ref:(0,an.sQ)(a,m),autoComplete:i||"off",autoFocus:l,className:_e()("".concat(r,"-selection-search-input"),E==null?void 0:E.className),role:"combobox","aria-expanded":h||!1,"aria-haspopup":"listbox","aria-owns":"".concat(o,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(o,"_list"),"aria-activedescendant":h?s:void 0},I),{},{value:c?f:"",readOnly:!c,unselectable:c?null:"on",style:(0,N.Z)((0,N.Z)({},E.style),{},{opacity:c?null:0})})),p},_n=n.forwardRef(qn),cn=_n;function sn(e){return Array.isArray(e)?e:e!==void 0?[e]:[]}var er=typeof window!="undefined"&&window.document&&window.document.documentElement,tr=er;function nr(e){return e!=null}function rr(e){return!e&&e!==0}function dn(e){return["string","number"].includes((0,It.Z)(e))}function fn(e){var t=void 0;return e&&(dn(e.title)?t=e.title.toString():dn(e.label)&&(t=e.label.toString())),t}function ar(e,t){tr?n.useLayoutEffect(e,t):n.useEffect(e,t)}function or(e){var t;return(t=e.key)!==null&&t!==void 0?t:e.value}var vn=function(t){t.preventDefault(),t.stopPropagation()},lr=function(t){var a=t.id,r=t.prefixCls,o=t.values,u=t.open,l=t.searchValue,i=t.autoClearSearchValue,c=t.inputRef,s=t.placeholder,f=t.disabled,h=t.mode,I=t.showSearch,d=t.autoFocus,p=t.autoComplete,C=t.activeDescendantId,m=t.tabIndex,E=t.removeIcon,q=t.maxTagCount,j=t.maxTagTextLength,V=t.maxTagPlaceholder,F=V===void 0?function(L){return"+ ".concat(L.length," ...")}:V,b=t.tagRender,se=t.onToggleOpen,he=t.onRemove,R=t.onInputChange,ee=t.onInputPaste,z=t.onInputKeyDown,de=t.onInputMouseDown,te=t.onInputCompositionStart,Ie=t.onInputCompositionEnd,ae=t.onInputBlur,fe=n.useRef(null),xe=(0,n.useState)(0),Se=(0,B.Z)(xe,2),ve=Se[0],W=Se[1],A=(0,n.useState)(!1),Pe=(0,B.Z)(A,2),Ve=Pe[0],Le=Pe[1],oe="".concat(r,"-selection"),He=u||h==="multiple"&&i===!1||h==="tags"?l:"",ne=h==="tags"||h==="multiple"&&i===!1||I&&(u||Ve);ar(function(){W(fe.current.scrollWidth)},[He]);var Me=function(y,M,G,re,K){return n.createElement("span",{title:fn(y),className:_e()("".concat(oe,"-item"),(0,ye.Z)({},"".concat(oe,"-item-disabled"),G))},n.createElement("span",{className:"".concat(oe,"-item-content")},M),re&&n.createElement(Ft,{className:"".concat(oe,"-item-remove"),onMouseDown:vn,onClick:K,customizeIcon:E},"\xD7"))},Ee=function(y,M,G,re,K,le){var Ae=function(J){vn(J),se(!u)};return n.createElement("span",{onMouseDown:Ae},b({label:M,value:y,disabled:G,closable:re,onClose:K,isMaxTag:!!le}))},Ze=function(y){var M=y.disabled,G=y.label,re=y.value,K=!f&&!M,le=G;if(typeof j=="number"&&(typeof G=="string"||typeof G=="number")){var Ae=String(le);Ae.length>j&&(le="".concat(Ae.slice(0,j),"..."))}var Be=function(Ce){Ce&&Ce.stopPropagation(),he(y)};return typeof b=="function"?Ee(re,le,M,K,Be):Me(y,le,M,K,Be)},O=function(y){if(!o.length)return null;var M=typeof F=="function"?F(y):F;return typeof b=="function"?Ee(void 0,M,!1,!1,void 0,!0):Me({title:M},M,!1)},g=n.createElement("div",{className:"".concat(oe,"-search"),style:{width:ve},onFocus:function(){Le(!0)},onBlur:function(){Le(!1)}},n.createElement(cn,{ref:c,open:u,prefixCls:r,id:a,inputElement:null,disabled:f,autoFocus:d,autoComplete:p,editable:ne,activeDescendantId:C,value:He,onKeyDown:z,onMouseDown:de,onChange:R,onPaste:ee,onCompositionStart:te,onCompositionEnd:Ie,onBlur:ae,tabIndex:m,attrs:(0,Kt.Z)(t,!0)}),n.createElement("span",{ref:fe,className:"".concat(oe,"-search-mirror"),"aria-hidden":!0},He,"\xA0")),D=n.createElement(Yn.Z,{prefixCls:"".concat(oe,"-overflow"),data:o,renderItem:Ze,renderRest:O,suffix:g,itemKey:or,maxCount:q});return n.createElement("span",{className:"".concat(oe,"-wrap")},D,!o.length&&!He&&n.createElement("span",{className:"".concat(oe,"-placeholder")},s))},ir=lr,ur=function(t){var a=t.inputElement,r=t.prefixCls,o=t.id,u=t.inputRef,l=t.disabled,i=t.autoFocus,c=t.autoComplete,s=t.activeDescendantId,f=t.mode,h=t.open,I=t.values,d=t.placeholder,p=t.tabIndex,C=t.showSearch,m=t.searchValue,E=t.activeValue,q=t.maxLength,j=t.onInputKeyDown,V=t.onInputMouseDown,F=t.onInputChange,b=t.onInputPaste,se=t.onInputCompositionStart,he=t.onInputCompositionEnd,R=t.onInputBlur,ee=t.title,z=n.useState(!1),de=(0,B.Z)(z,2),te=de[0],Ie=de[1],ae=f==="combobox",fe=ae||C,xe=I[0],Se=m||"";ae&&E&&!te&&(Se=E),n.useEffect(function(){ae&&Ie(!1)},[ae,E]);var ve=f!=="combobox"&&!h&&!C?!1:!!Se,W=ee===void 0?fn(xe):ee,A=n.useMemo(function(){return xe?null:n.createElement("span",{className:"".concat(r,"-selection-placeholder"),style:ve?{visibility:"hidden"}:void 0},d)},[xe,ve,d,r]);return n.createElement("span",{className:"".concat(r,"-selection-wrap")},n.createElement("span",{className:"".concat(r,"-selection-search")},n.createElement(cn,{ref:u,prefixCls:r,id:o,open:h,inputElement:a,disabled:l,autoFocus:i,autoComplete:c,editable:fe,activeDescendantId:s,value:Se,onKeyDown:j,onMouseDown:V,onChange:function(Ve){Ie(!0),F(Ve)},onPaste:b,onCompositionStart:se,onCompositionEnd:he,onBlur:R,tabIndex:p,attrs:(0,Kt.Z)(t,!0),maxLength:ae?q:void 0})),!ae&&xe?n.createElement("span",{className:"".concat(r,"-selection-item"),title:W,style:ve?{visibility:"hidden"}:void 0},xe.label):null,A)},cr=ur,sr=function(t,a){var r=(0,n.useRef)(null),o=(0,n.useRef)(!1),u=t.prefixCls,l=t.open,i=t.mode,c=t.showSearch,s=t.tokenWithEnter,f=t.disabled,h=t.prefix,I=t.autoClearSearchValue,d=t.onSearch,p=t.onSearchSubmit,C=t.onToggleOpen,m=t.onInputKeyDown,E=t.onInputBlur,q=t.domRef;n.useImperativeHandle(a,function(){return{focus:function(W){r.current.focus(W)},blur:function(){r.current.blur()}}});var j=un(0),V=(0,B.Z)(j,2),F=V[0],b=V[1],se=function(W){var A=W.which,Pe=r.current instanceof HTMLTextAreaElement;!Pe&&l&&(A===P.Z.UP||A===P.Z.DOWN)&&W.preventDefault(),m&&m(W),A===P.Z.ENTER&&i==="tags"&&!o.current&&!l&&(p==null||p(W.target.value)),!(Pe&&!l&&~[P.Z.UP,P.Z.DOWN,P.Z.LEFT,P.Z.RIGHT].indexOf(A))&&Xn(A)&&C(!0)},he=function(){b(!0)},R=(0,n.useRef)(null),ee=function(W){d(W,!0,o.current)!==!1&&C(!0)},z=function(){o.current=!0},de=function(W){o.current=!1,i!=="combobox"&&ee(W.target.value)},te=function(W){var A=W.target.value;if(s&&R.current&&/[\r\n]/.test(R.current)){var Pe=R.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");A=A.replace(Pe,R.current)}R.current=null,ee(A)},Ie=function(W){var A=W.clipboardData,Pe=A==null?void 0:A.getData("text");R.current=Pe||""},ae=function(W){var A=W.target;if(A!==r.current){var Pe=document.body.style.msTouchAction!==void 0;Pe?setTimeout(function(){r.current.focus()}):r.current.focus()}},fe=function(W){var A=F();W.target!==r.current&&!A&&!(i==="combobox"&&f)&&W.preventDefault(),(i!=="combobox"&&(!c||!A)||!l)&&(l&&I!==!1&&d("",!0,!1),C())},xe={inputRef:r,onInputKeyDown:se,onInputMouseDown:he,onInputChange:te,onInputPaste:Ie,onInputCompositionStart:z,onInputCompositionEnd:de,onInputBlur:E},Se=i==="multiple"||i==="tags"?n.createElement(ir,(0,Xe.Z)({},t,xe)):n.createElement(cr,(0,Xe.Z)({},t,xe));return n.createElement("div",{ref:q,className:"".concat(u,"-selector"),onClick:ae,onMouseDown:fe},h&&n.createElement("div",{className:"".concat(u,"-prefix")},h),Se)},dr=n.forwardRef(sr),fr=dr,vr=v(40228),mr=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],hr=function(t){var a=t===!0?0:1;return{bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:a,adjustY:1},htmlRegion:"scroll"},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:a,adjustY:1},htmlRegion:"scroll"},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:a,adjustY:1},htmlRegion:"scroll"},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:a,adjustY:1},htmlRegion:"scroll"}}},gr=function(t,a){var r=t.prefixCls,o=t.disabled,u=t.visible,l=t.children,i=t.popupElement,c=t.animation,s=t.transitionName,f=t.dropdownStyle,h=t.dropdownClassName,I=t.direction,d=I===void 0?"ltr":I,p=t.placement,C=t.builtinPlacements,m=t.dropdownMatchSelectWidth,E=t.dropdownRender,q=t.dropdownAlign,j=t.getPopupContainer,V=t.empty,F=t.getTriggerDOMNode,b=t.onPopupVisibleChange,se=t.onPopupMouseEnter,he=(0,rt.Z)(t,mr),R="".concat(r,"-dropdown"),ee=i;E&&(ee=E(i));var z=n.useMemo(function(){return C||hr(m)},[C,m]),de=c?"".concat(R,"-").concat(c):s,te=typeof m=="number",Ie=n.useMemo(function(){return te?null:m===!1?"minWidth":"width"},[m,te]),ae=f;te&&(ae=(0,N.Z)((0,N.Z)({},ae),{},{width:m}));var fe=n.useRef(null);return n.useImperativeHandle(a,function(){return{getPopupElement:function(){var Se;return(Se=fe.current)===null||Se===void 0?void 0:Se.popupElement}}}),n.createElement(vr.Z,(0,Xe.Z)({},he,{showAction:b?["click"]:[],hideAction:b?["click"]:[],popupPlacement:p||(d==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:z,prefixCls:R,popupTransitionName:de,popup:n.createElement("div",{onMouseEnter:se},ee),ref:fe,stretch:Ie,popupAlign:q,popupVisible:u,getPopupContainer:j,popupClassName:_e()(h,(0,ye.Z)({},"".concat(R,"-empty"),V)),popupStyle:ae,getTriggerDOMNode:F,onPopupVisibleChange:b}),l)},pr=n.forwardRef(gr),Sr=pr,Cr=v(84506);function mn(e,t){var a=e.key,r;return"value"in e&&(r=e.value),a!=null?a:r!==void 0?r:"rc-index-key-".concat(t)}function zt(e){return typeof e!="undefined"&&!Number.isNaN(e)}function hn(e,t){var a=e||{},r=a.label,o=a.value,u=a.options,l=a.groupLabel,i=r||(t?"children":"label");return{label:i,value:o||"value",options:u||"options",groupLabel:l||i}}function br(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=t.fieldNames,r=t.childrenAsData,o=[],u=hn(a,!1),l=u.label,i=u.value,c=u.options,s=u.groupLabel;function f(h,I){Array.isArray(h)&&h.forEach(function(d){if(I||!(c in d)){var p=d[i];o.push({key:mn(d,o.length),groupOption:I,data:d,label:d[l],value:p})}else{var C=d[s];C===void 0&&r&&(C=d.label),o.push({key:mn(d,o.length),group:!0,data:d,label:C}),f(d[c],!0)}})}return f(e,!1),o}function Ut(e){var t=(0,N.Z)({},e);return"props"in t||Object.defineProperty(t,"props",{get:function(){return(0,Lt.ZP)(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),t}}),t}var yr=function(t,a,r){if(!a||!a.length)return null;var o=!1,u=function i(c,s){var f=(0,Cr.Z)(s),h=f[0],I=f.slice(1);if(!h)return[c];var d=c.split(h);return o=o||d.length>1,d.reduce(function(p,C){return[].concat((0,be.Z)(p),(0,be.Z)(i(C,I)))},[]).filter(Boolean)},l=u(t,a);return o?typeof r!="undefined"?l.slice(0,r):l:null},wr=n.createContext(null),jt=wr;function Ir(e){var t=e.visible,a=e.values;if(!t)return null;var r=50;return n.createElement("span",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},"".concat(a.slice(0,r).map(function(o){var u=o.label,l=o.value;return["number","string"].includes((0,It.Z)(u))?u:l}).join(", ")),a.length>r?", ...":null)}var xr=["id","prefixCls","className","showSearch","tagRender","direction","omitDomProps","displayValues","onDisplayValuesChange","emptyOptions","notFoundContent","onClear","mode","disabled","loading","getInputElement","getRawInputElement","open","defaultOpen","onDropdownVisibleChange","activeValue","onActiveValueChange","activeDescendantId","searchValue","autoClearSearchValue","onSearch","onSearchSplit","tokenSeparators","allowClear","prefix","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],Er=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"],Gt=function(t){return t==="tags"||t==="multiple"},Zr=n.forwardRef(function(e,t){var a,r=e.id,o=e.prefixCls,u=e.className,l=e.showSearch,i=e.tagRender,c=e.direction,s=e.omitDomProps,f=e.displayValues,h=e.onDisplayValuesChange,I=e.emptyOptions,d=e.notFoundContent,p=d===void 0?"Not Found":d,C=e.onClear,m=e.mode,E=e.disabled,q=e.loading,j=e.getInputElement,V=e.getRawInputElement,F=e.open,b=e.defaultOpen,se=e.onDropdownVisibleChange,he=e.activeValue,R=e.onActiveValueChange,ee=e.activeDescendantId,z=e.searchValue,de=e.autoClearSearchValue,te=e.onSearch,Ie=e.onSearchSplit,ae=e.tokenSeparators,fe=e.allowClear,xe=e.prefix,Se=e.suffixIcon,ve=e.clearIcon,W=e.OptionList,A=e.animation,Pe=e.transitionName,Ve=e.dropdownStyle,Le=e.dropdownClassName,oe=e.dropdownMatchSelectWidth,He=e.dropdownRender,ne=e.dropdownAlign,Me=e.placement,Ee=e.builtinPlacements,Ze=e.getPopupContainer,O=e.showAction,g=O===void 0?[]:O,D=e.onFocus,L=e.onBlur,y=e.onKeyUp,M=e.onKeyDown,G=e.onMouseDown,re=(0,rt.Z)(e,xr),K=Gt(m),le=(l!==void 0?l:K)||m==="combobox",Ae=(0,N.Z)({},re);Er.forEach(function(Q){delete Ae[Q]}),s==null||s.forEach(function(Q){delete Ae[Q]});var Be=n.useState(!1),J=(0,B.Z)(Be,2),Ce=J[0],je=J[1];n.useEffect(function(){je((0,Bn.Z)())},[]);var We=n.useRef(null),Ye=n.useRef(null),ge=n.useRef(null),X=n.useRef(null),Te=n.useRef(null),Je=n.useRef(!1),et=jn(),Qe=(0,B.Z)(et,3),Ge=Qe[0],we=Qe[1],vt=Qe[2];n.useImperativeHandle(t,function(){var Q,k;return{focus:(Q=X.current)===null||Q===void 0?void 0:Q.focus,blur:(k=X.current)===null||k===void 0?void 0:k.blur,scrollTo:function(ct){var Ue;return(Ue=Te.current)===null||Ue===void 0?void 0:Ue.scrollTo(ct)},nativeElement:We.current||Ye.current}});var ie=n.useMemo(function(){var Q;if(m!=="combobox")return z;var k=(Q=f[0])===null||Q===void 0?void 0:Q.value;return typeof k=="string"||typeof k=="number"?String(k):""},[z,m,f]),$e=m==="combobox"&&typeof j=="function"&&j()||null,T=typeof V=="function"&&V(),$=(0,an.x1)(Ye,T==null||(a=T.props)===null||a===void 0?void 0:a.ref),Re=n.useState(!1),me=(0,B.Z)(Re,2),De=me[0],ze=me[1];(0,$n.Z)(function(){ze(!0)},[]);var ke=(0,gt.Z)(!1,{defaultValue:b,value:F}),ot=(0,B.Z)(ke,2),tt=ot[0],mt=ot[1],Ne=De?tt:!1,Zt=!p&&I;(E||Zt&&Ne&&m==="combobox")&&(Ne=!1);var pt=Zt?!1:Ne,S=n.useCallback(function(Q){var k=Q!==void 0?Q:!Ne;E||(mt(k),Ne!==k&&(se==null||se(k)))},[E,Ne,mt,se]),x=n.useMemo(function(){return(ae||[]).some(function(Q){return[`
`,`\r
`].includes(Q)})},[ae]),w=n.useContext(jt)||{},Z=w.maxCount,Y=w.rawValues,ue=function(k,ut,ct){if(!(K&&zt(Z)&&(Y==null?void 0:Y.size)>=Z)){var Ue=!0,nt=k;R==null||R(null);var Et=yr(k,ae,zt(Z)?Z-Y.size:void 0),wt=ct?null:Et;return m!=="combobox"&&wt&&(nt="",Ie==null||Ie(wt),S(!1),Ue=!1),te&&ie!==nt&&te(nt,{source:ut?"typing":"effect"}),Ue}},lt=function(k){!k||!k.trim()||te(k,{source:"submit"})};n.useEffect(function(){!Ne&&!K&&m!=="combobox"&&ue("",!1,!1)},[Ne]),n.useEffect(function(){tt&&E&&mt(!1),E&&!Je.current&&we(!1)},[E]);var qe=un(),it=(0,B.Z)(qe,2),Fe=it[0],ht=it[1],st=n.useRef(!1),xt=function(k){var ut=Fe(),ct=k.key,Ue=ct==="Enter";if(Ue&&(m!=="combobox"&&k.preventDefault(),Ne||S(!0)),ht(!!ie),ct==="Backspace"&&!ut&&K&&!ie&&f.length){for(var nt=(0,be.Z)(f),Et=null,wt=nt.length-1;wt>=0;wt-=1){var Nt=nt[wt];if(!Nt.disabled){nt.splice(wt,1),Et=Nt;break}}Et&&h(nt,{type:"remove",values:[Et]})}for(var At=arguments.length,Vt=new Array(At>1?At-1:0),Wt=1;Wt<At;Wt++)Vt[Wt-1]=arguments[Wt];if(Ne&&(!Ue||!st.current)){var $t;Ue&&(st.current=!0),($t=Te.current)===null||$t===void 0||$t.onKeyDown.apply($t,[k].concat(Vt))}M==null||M.apply(void 0,[k].concat(Vt))},_=function(k){for(var ut=arguments.length,ct=new Array(ut>1?ut-1:0),Ue=1;Ue<ut;Ue++)ct[Ue-1]=arguments[Ue];if(Ne){var nt;(nt=Te.current)===null||nt===void 0||nt.onKeyUp.apply(nt,[k].concat(ct))}k.key==="Enter"&&(st.current=!1),y==null||y.apply(void 0,[k].concat(ct))},U=function(k){var ut=f.filter(function(ct){return ct!==k});h(ut,{type:"remove",values:[k]})},H=function(){st.current=!1},pe=n.useRef(!1),dt=function(){we(!0),E||(D&&!pe.current&&D.apply(void 0,arguments),g.includes("focus")&&S(!0)),pe.current=!0},Ke=function(){Je.current=!0,we(!1,function(){pe.current=!1,Je.current=!1,S(!1)}),!E&&(ie&&(m==="tags"?te(ie,{source:"submit"}):m==="multiple"&&te("",{source:"blur"})),L&&L.apply(void 0,arguments))},ce=[];n.useEffect(function(){return function(){ce.forEach(function(Q){return clearTimeout(Q)}),ce.splice(0,ce.length)}},[]);var Oe=function(k){var ut,ct=k.target,Ue=(ut=ge.current)===null||ut===void 0?void 0:ut.getPopupElement();if(Ue&&Ue.contains(ct)){var nt=setTimeout(function(){var At=ce.indexOf(nt);if(At!==-1&&ce.splice(At,1),vt(),!Ce&&!Ue.contains(document.activeElement)){var Vt;(Vt=X.current)===null||Vt===void 0||Vt.focus()}});ce.push(nt)}for(var Et=arguments.length,wt=new Array(Et>1?Et-1:0),Nt=1;Nt<Et;Nt++)wt[Nt-1]=arguments[Nt];G==null||G.apply(void 0,[k].concat(wt))},at=n.useState({}),Ct=(0,B.Z)(at,2),Dt=Ct[1];function Mt(){Dt({})}var bt;T&&(bt=function(k){S(k)}),Gn(function(){var Q;return[We.current,(Q=ge.current)===null||Q===void 0?void 0:Q.getPopupElement()]},pt,S,!!T);var Ot=n.useMemo(function(){return(0,N.Z)((0,N.Z)({},e),{},{notFoundContent:p,open:Ne,triggerOpen:pt,id:r,showSearch:le,multiple:K,toggleOpen:S})},[e,p,pt,Ne,r,le,K,S]),Tt=!!Se||q,ft;Tt&&(ft=n.createElement(Ft,{className:_e()("".concat(o,"-arrow"),(0,ye.Z)({},"".concat(o,"-arrow-loading"),q)),customizeIcon:Se,customizeIconProps:{loading:q,searchValue:ie,open:Ne,focused:Ge,showSearch:le}}));var yt=function(){var k;C==null||C(),(k=X.current)===null||k===void 0||k.focus(),h([],{type:"clear",values:f}),ue("",!1,!1)},Hn=Un(o,yt,f,fe,ve,E,ie,m),ja=Hn.allowClear,Ga=Hn.clearIcon,Xa=n.createElement(W,{ref:Te}),Ya=_e()(o,u,(0,ye.Z)((0,ye.Z)((0,ye.Z)((0,ye.Z)((0,ye.Z)((0,ye.Z)((0,ye.Z)((0,ye.Z)((0,ye.Z)((0,ye.Z)({},"".concat(o,"-focused"),Ge),"".concat(o,"-multiple"),K),"".concat(o,"-single"),!K),"".concat(o,"-allow-clear"),fe),"".concat(o,"-show-arrow"),Tt),"".concat(o,"-disabled"),E),"".concat(o,"-loading"),q),"".concat(o,"-open"),Ne),"".concat(o,"-customize-input"),$e),"".concat(o,"-show-search"),le)),Wn=n.createElement(Sr,{ref:ge,disabled:E,prefixCls:o,visible:pt,popupElement:Xa,animation:A,transitionName:Pe,dropdownStyle:Ve,dropdownClassName:Le,direction:c,dropdownMatchSelectWidth:oe,dropdownRender:He,dropdownAlign:ne,placement:Me,builtinPlacements:Ee,getPopupContainer:Ze,empty:I,getTriggerDOMNode:function(k){return Ye.current||k},onPopupVisibleChange:bt,onPopupMouseEnter:Mt},T?n.cloneElement(T,{ref:$}):n.createElement(fr,(0,Xe.Z)({},e,{domRef:Ye,prefixCls:o,inputElement:$e,ref:X,id:r,prefix:xe,showSearch:le,autoClearSearchValue:de,mode:m,activeDescendantId:ee,tagRender:i,values:f,open:Ne,onToggleOpen:S,activeValue:he,searchValue:ie,onSearch:ue,onSearchSubmit:lt,onRemove:U,tokenWithEnter:x,onInputBlur:H}))),rn;return T?rn=Wn:rn=n.createElement("div",(0,Xe.Z)({className:Ya},Ae,{ref:We,onMouseDown:Oe,onKeyDown:xt,onKeyUp:_,onFocus:dt,onBlur:Ke}),n.createElement(Ir,{visible:Ge&&!Ne,values:f}),Wn,ft,ja&&Ga),n.createElement(on.Provider,{value:Ot},rn)}),gn=Zr,pn=function(){return null};pn.isSelectOptGroup=!0;var Or=pn,Sn=function(){return null};Sn.isSelectOption=!0;var Pr=Sn,Xt=v(56982),Yt=v(98423),Rr=v(87718);function Dr(){return/(mac\sos|macintosh)/i.test(navigator.appVersion)}var Mr=["disabled","title","children","style","className"];function Cn(e){return typeof e=="string"||typeof e=="number"}var Tr=function(t,a){var r=ln(),o=r.prefixCls,u=r.id,l=r.open,i=r.multiple,c=r.mode,s=r.searchValue,f=r.toggleOpen,h=r.notFoundContent,I=r.onPopupScroll,d=n.useContext(jt),p=d.maxCount,C=d.flattenOptions,m=d.onActiveValue,E=d.defaultActiveFirstOption,q=d.onSelect,j=d.menuItemSelectedIcon,V=d.rawValues,F=d.fieldNames,b=d.virtual,se=d.direction,he=d.listHeight,R=d.listItemHeight,ee=d.optionRender,z="".concat(o,"-item"),de=(0,Xt.Z)(function(){return C},[l,C],function(O,g){return g[0]&&O[1]!==g[1]}),te=n.useRef(null),Ie=n.useMemo(function(){return i&&zt(p)&&(V==null?void 0:V.size)>=p},[i,p,V==null?void 0:V.size]),ae=function(g){g.preventDefault()},fe=function(g){var D;(D=te.current)===null||D===void 0||D.scrollTo(typeof g=="number"?{index:g}:g)},xe=n.useCallback(function(O){return c==="combobox"?!1:V.has(O)},[c,(0,be.Z)(V).toString(),V.size]),Se=function(g){for(var D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,L=de.length,y=0;y<L;y+=1){var M=(g+y*D+L)%L,G=de[M]||{},re=G.group,K=G.data;if(!re&&!(K!=null&&K.disabled)&&(xe(K.value)||!Ie))return M}return-1},ve=n.useState(function(){return Se(0)}),W=(0,B.Z)(ve,2),A=W[0],Pe=W[1],Ve=function(g){var D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;Pe(g);var L={source:D?"keyboard":"mouse"},y=de[g];if(!y){m(null,-1,L);return}m(y.value,g,L)};(0,n.useEffect)(function(){Ve(E!==!1?Se(0):-1)},[de.length,s]);var Le=n.useCallback(function(O){return c==="combobox"?String(O).toLowerCase()===s.toLowerCase():V.has(O)},[c,s,(0,be.Z)(V).toString(),V.size]);(0,n.useEffect)(function(){var O=setTimeout(function(){if(!i&&l&&V.size===1){var D=Array.from(V)[0],L=de.findIndex(function(y){var M=y.data;return s?String(M.value).startsWith(s):M.value===D});L!==-1&&(Ve(L),fe(L))}});if(l){var g;(g=te.current)===null||g===void 0||g.scrollTo(void 0)}return function(){return clearTimeout(O)}},[l,s]);var oe=function(g){g!==void 0&&q(g,{selected:!V.has(g)}),i||f(!1)};if(n.useImperativeHandle(a,function(){return{onKeyDown:function(g){var D=g.which,L=g.ctrlKey;switch(D){case P.Z.N:case P.Z.P:case P.Z.UP:case P.Z.DOWN:{var y=0;if(D===P.Z.UP?y=-1:D===P.Z.DOWN?y=1:Dr()&&L&&(D===P.Z.N?y=1:D===P.Z.P&&(y=-1)),y!==0){var M=Se(A+y,y);fe(M),Ve(M,!0)}break}case P.Z.TAB:case P.Z.ENTER:{var G,re=de[A];re&&!(re!=null&&(G=re.data)!==null&&G!==void 0&&G.disabled)&&!Ie?oe(re.value):oe(void 0),l&&g.preventDefault();break}case P.Z.ESC:f(!1),l&&g.stopPropagation()}},onKeyUp:function(){},scrollTo:function(g){fe(g)}}}),de.length===0)return n.createElement("div",{role:"listbox",id:"".concat(u,"_list"),className:"".concat(z,"-empty"),onMouseDown:ae},h);var He=Object.keys(F).map(function(O){return F[O]}),ne=function(g){return g.label};function Me(O,g){var D=O.group;return{role:D?"presentation":"option",id:"".concat(u,"_list_").concat(g)}}var Ee=function(g){var D=de[g];if(!D)return null;var L=D.data||{},y=L.value,M=D.group,G=(0,Kt.Z)(L,!0),re=ne(D);return D?n.createElement("div",(0,Xe.Z)({"aria-label":typeof re=="string"&&!M?re:null},G,{key:g},Me(D,g),{"aria-selected":Le(y)}),y):null},Ze={role:"listbox",id:"".concat(u,"_list")};return n.createElement(n.Fragment,null,b&&n.createElement("div",(0,Xe.Z)({},Ze,{style:{height:0,width:0,overflow:"hidden"}}),Ee(A-1),Ee(A),Ee(A+1)),n.createElement(Rr.Z,{itemKey:"key",ref:te,data:de,height:he,itemHeight:R,fullHeight:!1,onMouseDown:ae,onScroll:I,virtual:b,direction:se,innerProps:b?null:Ze},function(O,g){var D=O.group,L=O.groupOption,y=O.data,M=O.label,G=O.value,re=y.key;if(D){var K,le=(K=y.title)!==null&&K!==void 0?K:Cn(M)?M.toString():void 0;return n.createElement("div",{className:_e()(z,"".concat(z,"-group"),y.className),title:le},M!==void 0?M:re)}var Ae=y.disabled,Be=y.title,J=y.children,Ce=y.style,je=y.className,We=(0,rt.Z)(y,Mr),Ye=(0,Yt.Z)(We,He),ge=xe(G),X=Ae||!ge&&Ie,Te="".concat(z,"-option"),Je=_e()(z,Te,je,(0,ye.Z)((0,ye.Z)((0,ye.Z)((0,ye.Z)({},"".concat(Te,"-grouped"),L),"".concat(Te,"-active"),A===g&&!X),"".concat(Te,"-disabled"),X),"".concat(Te,"-selected"),ge)),et=ne(O),Qe=!j||typeof j=="function"||ge,Ge=typeof et=="number"?et:et||G,we=Cn(Ge)?Ge.toString():void 0;return Be!==void 0&&(we=Be),n.createElement("div",(0,Xe.Z)({},(0,Kt.Z)(Ye),b?{}:Me(O,g),{"aria-selected":Le(G),className:Je,title:we,onMouseMove:function(){A===g||X||Ve(g)},onClick:function(){X||oe(G)},style:Ce}),n.createElement("div",{className:"".concat(Te,"-content")},typeof ee=="function"?ee(O,{index:g}):Ge),n.isValidElement(j)||ge,Qe&&n.createElement(Ft,{className:"".concat(z,"-option-state"),customizeIcon:j,customizeIconProps:{value:G,disabled:X,isSelected:ge}},ge?"\u2713":null))}))},Nr=n.forwardRef(Tr),Vr=Nr,Lr=function(e,t){var a=n.useRef({values:new Map,options:new Map}),r=n.useMemo(function(){var u=a.current,l=u.values,i=u.options,c=e.map(function(h){if(h.label===void 0){var I;return(0,N.Z)((0,N.Z)({},h),{},{label:(I=l.get(h.value))===null||I===void 0?void 0:I.label})}return h}),s=new Map,f=new Map;return c.forEach(function(h){s.set(h.value,h),f.set(h.value,t.get(h.value)||i.get(h.value))}),a.current.values=s,a.current.options=f,c},[e,t]),o=n.useCallback(function(u){return t.get(u)||a.current.options.get(u)},[t]);return[r,o]};function Jt(e,t){return sn(e).join("").toUpperCase().includes(t)}var Ar=function(e,t,a,r,o){return n.useMemo(function(){if(!a||r===!1)return e;var u=t.options,l=t.label,i=t.value,c=[],s=typeof r=="function",f=a.toUpperCase(),h=s?r:function(d,p){return o?Jt(p[o],f):p[u]?Jt(p[l!=="children"?l:"label"],f):Jt(p[i],f)},I=s?function(d){return Ut(d)}:function(d){return d};return e.forEach(function(d){if(d[u]){var p=h(a,I(d));if(p)c.push(d);else{var C=d[u].filter(function(m){return h(a,I(m))});C.length&&c.push((0,N.Z)((0,N.Z)({},d),{},(0,ye.Z)({},u,C)))}return}h(a,I(d))&&c.push(d)}),c},[e,r,o,a,t])},kr=v(98924),bn=0,Fr=(0,kr.Z)();function Kr(){var e;return Fr?(e=bn,bn+=1):e="TEST_OR_SSR",e}function yn(e){var t=n.useState(),a=(0,B.Z)(t,2),r=a[0],o=a[1];return n.useEffect(function(){o("rc_select_".concat(Kr()))},[]),e||r}var wn=v(50344),Hr=["children","value"],Wr=["children"];function $r(e){var t=e,a=t.key,r=t.props,o=r.children,u=r.value,l=(0,rt.Z)(r,Hr);return(0,N.Z)({key:a,value:u!==void 0?u:a,children:o},l)}function In(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return(0,wn.Z)(e).map(function(a,r){if(!n.isValidElement(a)||!a.type)return null;var o=a,u=o.type.isSelectOptGroup,l=o.key,i=o.props,c=i.children,s=(0,rt.Z)(i,Wr);return t||!u?$r(a):(0,N.Z)((0,N.Z)({key:"__RC_SELECT_GRP__".concat(l===null?r:l,"__"),label:l},s),{},{options:In(c)})}).filter(function(a){return a})}var Br=function(t,a,r,o,u){return n.useMemo(function(){var l=t,i=!t;i&&(l=In(a));var c=new Map,s=new Map,f=function(d,p,C){C&&typeof C=="string"&&d.set(p[C],p)},h=function I(d){for(var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,C=0;C<d.length;C+=1){var m=d[C];!m[r.options]||p?(c.set(m[r.value],m),f(s,m,r.label),f(s,m,o),f(s,m,u)):I(m[r.options],!0)}};return h(l),{options:l,valueOptions:c,labelOptions:s}},[t,a,r,o,u])},zr=Br;function xn(e){var t=n.useRef();t.current=e;var a=n.useCallback(function(){return t.current.apply(t,arguments)},[]);return a}function Ja(e){var t=e.mode,a=e.options,r=e.children,o=e.backfill,u=e.allowClear,l=e.placeholder,i=e.getInputElement,c=e.showSearch,s=e.onSearch,f=e.defaultOpen,h=e.autoFocus,I=e.labelInValue,d=e.value,p=e.inputValue,C=e.optionLabelProp,m=isMultiple(t),E=c!==void 0?c:m||t==="combobox",q=a||convertChildrenToData(r);if(warning(t!=="tags"||q.every(function(b){return!b.disabled}),"Please avoid setting option to disabled in tags mode since user can always type text as tag."),t==="tags"||t==="combobox"){var j=q.some(function(b){return b.options?b.options.some(function(se){return typeof("value"in se?se.value:se.key)=="number"}):typeof("value"in b?b.value:b.key)=="number"});warning(!j,"`value` of Option should not use number type when `mode` is `tags` or `combobox`.")}if(warning(t!=="combobox"||!C,"`combobox` mode not support `optionLabelProp`. Please set `value` on Option directly."),warning(t==="combobox"||!o,"`backfill` only works with `combobox` mode."),warning(t==="combobox"||!i,"`getInputElement` only work with `combobox` mode."),noteOnce(t!=="combobox"||!i||!u||!l,"Customize `getInputElement` should customize clear and placeholder logic instead of configuring `allowClear` and `placeholder`."),s&&!E&&t!=="combobox"&&t!=="tags"&&warning(!1,"`onSearch` should work with `showSearch` instead of use alone."),noteOnce(!f||h,"`defaultOpen` makes Select open without focus which means it will not close by click outside. You can set `autoFocus` if needed."),d!=null){var V=toArray(d);warning(!I||V.every(function(b){return _typeof(b)==="object"&&("key"in b||"value"in b)}),"`value` should in shape of `{ value: string | number, label?: ReactNode }` when you set `labelInValue` to `true`"),warning(!m||Array.isArray(d),"`value` should be array when `mode` is `multiple` or `tags`")}if(r){var F=null;toNodeArray(r).some(function(b){if(!React.isValidElement(b)||!b.type)return!1;var se=b,he=se.type;if(he.isSelectOption)return!1;if(he.isSelectOptGroup){var R=toNodeArray(b.props.children).every(function(ee){return!React.isValidElement(ee)||!b.type||ee.type.isSelectOption?!0:(F=ee.type,!1)});return!R}return F=he,!0}),F&&warning(!1,"`children` should be `Select.Option` or `Select.OptGroup` instead of `".concat(F.displayName||F.name||F,"`.")),warning(p===void 0,"`inputValue` is deprecated, please use `searchValue` instead.")}}function Qa(e,t){if(e){var a=function r(o){for(var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,l=0;l<o.length;l++){var i=o[l];if(i[t==null?void 0:t.value]===null)return warning(!1,"`value` in Select options should not be `null`."),!0;if(!u&&Array.isArray(i[t==null?void 0:t.options])&&r(i[t==null?void 0:t.options],!0))break}};a(e)}}var qa=null,Ur=["id","mode","prefixCls","backfill","fieldNames","inputValue","searchValue","onSearch","autoClearSearchValue","onSelect","onDeselect","dropdownMatchSelectWidth","filterOption","filterSort","optionFilterProp","optionLabelProp","options","optionRender","children","defaultActiveFirstOption","menuItemSelectedIcon","virtual","direction","listHeight","listItemHeight","labelRender","value","defaultValue","labelInValue","onChange","maxCount"],jr=["inputValue"];function Gr(e){return!e||(0,It.Z)(e)!=="object"}var Xr=n.forwardRef(function(e,t){var a=e.id,r=e.mode,o=e.prefixCls,u=o===void 0?"rc-select":o,l=e.backfill,i=e.fieldNames,c=e.inputValue,s=e.searchValue,f=e.onSearch,h=e.autoClearSearchValue,I=h===void 0?!0:h,d=e.onSelect,p=e.onDeselect,C=e.dropdownMatchSelectWidth,m=C===void 0?!0:C,E=e.filterOption,q=e.filterSort,j=e.optionFilterProp,V=e.optionLabelProp,F=e.options,b=e.optionRender,se=e.children,he=e.defaultActiveFirstOption,R=e.menuItemSelectedIcon,ee=e.virtual,z=e.direction,de=e.listHeight,te=de===void 0?200:de,Ie=e.listItemHeight,ae=Ie===void 0?20:Ie,fe=e.labelRender,xe=e.value,Se=e.defaultValue,ve=e.labelInValue,W=e.onChange,A=e.maxCount,Pe=(0,rt.Z)(e,Ur),Ve=yn(a),Le=Gt(r),oe=!!(!F&&se),He=n.useMemo(function(){return E===void 0&&r==="combobox"?!1:E},[E,r]),ne=n.useMemo(function(){return hn(i,oe)},[JSON.stringify(i),oe]),Me=(0,gt.Z)("",{value:s!==void 0?s:c,postState:function(x){return x||""}}),Ee=(0,B.Z)(Me,2),Ze=Ee[0],O=Ee[1],g=zr(F,se,ne,j,V),D=g.valueOptions,L=g.labelOptions,y=g.options,M=n.useCallback(function(S){var x=sn(S);return x.map(function(w){var Z,Y,ue,lt,qe;if(Gr(w))Z=w;else{var it;ue=w.key,Y=w.label,Z=(it=w.value)!==null&&it!==void 0?it:ue}var Fe=D.get(Z);if(Fe){var ht;if(Y===void 0&&(Y=Fe==null?void 0:Fe[V||ne.label]),ue===void 0&&(ue=(ht=Fe==null?void 0:Fe.key)!==null&&ht!==void 0?ht:Z),lt=Fe==null?void 0:Fe.disabled,qe=Fe==null?void 0:Fe.title,0)var st}return{label:Y,value:Z,key:ue,disabled:lt,title:qe}})},[ne,V,D]),G=(0,gt.Z)(Se,{value:xe}),re=(0,B.Z)(G,2),K=re[0],le=re[1],Ae=n.useMemo(function(){var S,x=Le&&K===null?[]:K,w=M(x);return r==="combobox"&&rr((S=w[0])===null||S===void 0?void 0:S.value)?[]:w},[K,M,r,Le]),Be=Lr(Ae,D),J=(0,B.Z)(Be,2),Ce=J[0],je=J[1],We=n.useMemo(function(){if(!r&&Ce.length===1){var S=Ce[0];if(S.value===null&&(S.label===null||S.label===void 0))return[]}return Ce.map(function(x){var w;return(0,N.Z)((0,N.Z)({},x),{},{label:(w=typeof fe=="function"?fe(x):x.label)!==null&&w!==void 0?w:x.value})})},[r,Ce,fe]),Ye=n.useMemo(function(){return new Set(Ce.map(function(S){return S.value}))},[Ce]);n.useEffect(function(){if(r==="combobox"){var S,x=(S=Ce[0])===null||S===void 0?void 0:S.value;O(nr(x)?String(x):"")}},[Ce]);var ge=xn(function(S,x){var w=x!=null?x:S;return(0,ye.Z)((0,ye.Z)({},ne.value,S),ne.label,w)}),X=n.useMemo(function(){if(r!=="tags")return y;var S=(0,be.Z)(y),x=function(Z){return D.has(Z)};return(0,be.Z)(Ce).sort(function(w,Z){return w.value<Z.value?-1:1}).forEach(function(w){var Z=w.value;x(Z)||S.push(ge(Z,w.label))}),S},[ge,y,D,Ce,r]),Te=Ar(X,ne,Ze,He,j),Je=n.useMemo(function(){return r!=="tags"||!Ze||Te.some(function(S){return S[j||"value"]===Ze})||Te.some(function(S){return S[ne.value]===Ze})?Te:[ge(Ze)].concat((0,be.Z)(Te))},[ge,j,r,Te,Ze,ne]),et=function S(x){var w=(0,be.Z)(x).sort(function(Z,Y){return q(Z,Y,{searchValue:Ze})});return w.map(function(Z){return Array.isArray(Z.options)?(0,N.Z)((0,N.Z)({},Z),{},{options:Z.options.length>0?S(Z.options):Z.options}):Z})},Qe=n.useMemo(function(){return q?et(Je):Je},[Je,q,Ze]),Ge=n.useMemo(function(){return br(Qe,{fieldNames:ne,childrenAsData:oe})},[Qe,ne,oe]),we=function(x){var w=M(x);if(le(w),W&&(w.length!==Ce.length||w.some(function(ue,lt){var qe;return((qe=Ce[lt])===null||qe===void 0?void 0:qe.value)!==(ue==null?void 0:ue.value)}))){var Z=ve?w:w.map(function(ue){return ue.value}),Y=w.map(function(ue){return Ut(je(ue.value))});W(Le?Z:Z[0],Le?Y:Y[0])}},vt=n.useState(null),ie=(0,B.Z)(vt,2),$e=ie[0],T=ie[1],$=n.useState(0),Re=(0,B.Z)($,2),me=Re[0],De=Re[1],ze=he!==void 0?he:r!=="combobox",ke=n.useCallback(function(S,x){var w=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},Z=w.source,Y=Z===void 0?"keyboard":Z;De(x),l&&r==="combobox"&&S!==null&&Y==="keyboard"&&T(String(S))},[l,r]),ot=function(x,w,Z){var Y=function(){var U,H=je(x);return[ve?{label:H==null?void 0:H[ne.label],value:x,key:(U=H==null?void 0:H.key)!==null&&U!==void 0?U:x}:x,Ut(H)]};if(w&&d){var ue=Y(),lt=(0,B.Z)(ue,2),qe=lt[0],it=lt[1];d(qe,it)}else if(!w&&p&&Z!=="clear"){var Fe=Y(),ht=(0,B.Z)(Fe,2),st=ht[0],xt=ht[1];p(st,xt)}},tt=xn(function(S,x){var w,Z=Le?x.selected:!0;Z?w=Le?[].concat((0,be.Z)(Ce),[S]):[S]:w=Ce.filter(function(Y){return Y.value!==S}),we(w),ot(S,Z),r==="combobox"?T(""):(!Gt||I)&&(O(""),T(""))}),mt=function(x,w){we(x);var Z=w.type,Y=w.values;(Z==="remove"||Z==="clear")&&Y.forEach(function(ue){ot(ue.value,!1,Z)})},Ne=function(x,w){if(O(x),T(null),w.source==="submit"){var Z=(x||"").trim();if(Z){var Y=Array.from(new Set([].concat((0,be.Z)(Ye),[Z])));we(Y),ot(Z,!0),O("")}return}w.source!=="blur"&&(r==="combobox"&&we(x),f==null||f(x))},Zt=function(x){var w=x;r!=="tags"&&(w=x.map(function(Y){var ue=L.get(Y);return ue==null?void 0:ue.value}).filter(function(Y){return Y!==void 0}));var Z=Array.from(new Set([].concat((0,be.Z)(Ye),(0,be.Z)(w))));we(Z),Z.forEach(function(Y){ot(Y,!0)})},pt=n.useMemo(function(){var S=ee!==!1&&m!==!1;return(0,N.Z)((0,N.Z)({},g),{},{flattenOptions:Ge,onActiveValue:ke,defaultActiveFirstOption:ze,onSelect:tt,menuItemSelectedIcon:R,rawValues:Ye,fieldNames:ne,virtual:S,direction:z,listHeight:te,listItemHeight:ae,childrenAsData:oe,maxCount:A,optionRender:b})},[A,g,Ge,ke,ze,tt,R,Ye,ne,ee,m,z,te,ae,oe,b]);return n.createElement(jt.Provider,{value:pt},n.createElement(gn,(0,Xe.Z)({},Pe,{id:Ve,prefixCls:u,ref:t,omitDomProps:jr,mode:r,displayValues:We,onDisplayValuesChange:mt,direction:z,searchValue:Ze,onSearch:Ne,autoClearSearchValue:I,onSearchSplit:Zt,dropdownMatchSelectWidth:m,OptionList:Vr,emptyOptions:!Ge.length,activeValue:$e,activeDescendantId:"".concat(Ve,"_list_").concat(me)})))}),En=Xr;En.Option=Pr,En.OptGroup=Or;var _a=null,eo=null,Qt=v(17341),Yr=function(e){var t=n.useRef({valueLabels:new Map});return n.useMemo(function(){var a=t.current.valueLabels,r=new Map,o=e.map(function(u){var l=u.value,i=u.label,c=i!=null?i:a.get(l);return r.set(l,c),(0,N.Z)((0,N.Z)({},u),{},{label:c})});return t.current.valueLabels=r,[o]},[e])},Jr=function(t,a,r,o){return n.useMemo(function(){var u=function(d){return d.map(function(p){var C=p.value;return C})},l=u(t),i=u(a),c=l.filter(function(I){return!o[I]}),s=l,f=i;if(r){var h=(0,Qt.S)(l,!0,o);s=h.checkedKeys,f=h.halfCheckedKeys}return[Array.from(new Set([].concat((0,be.Z)(c),(0,be.Z)(s)))),f]},[t,a,r,o])},Qr=Jr,qr=v(1089),_r=function(e,t){return n.useMemo(function(){var a=(0,qr.I8)(e,{fieldNames:t,initWrapper:function(o){return(0,N.Z)((0,N.Z)({},o),{},{valueEntities:new Map})},processEntity:function(o,u){var l=o.node[t.value];if(0)var i;u.valueEntities.set(l,o)}});return a},[e,t])},ea=function(){return null},qt=ea,ta=["children","value"];function Zn(e){return(0,wn.Z)(e).map(function(t){if(!n.isValidElement(t)||!t.type)return null;var a=t,r=a.key,o=a.props,u=o.children,l=o.value,i=(0,rt.Z)(o,ta),c=(0,N.Z)({key:r,value:l},i),s=Zn(u);return s.length&&(c.children=s),c}).filter(function(t){return t})}function _t(e){if(!e)return e;var t=(0,N.Z)({},e);return"props"in t||Object.defineProperty(t,"props",{get:function(){return(0,Lt.ZP)(!1,"New `rc-tree-select` not support return node instance as argument anymore. Please consider to remove `props` access."),t}}),t}function na(e,t,a,r,o,u){var l=null,i=null;function c(){function s(f){var h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"0",I=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return f.map(function(d,p){var C="".concat(h,"-").concat(p),m=d[u.value],E=a.includes(m),q=s(d[u.children]||[],C,E),j=n.createElement(qt,d,q.map(function(F){return F.node}));if(t===m&&(l=j),E){var V={pos:C,node:j,children:q};return I||i.push(V),V}return null}).filter(function(d){return d})}i||(i=[],s(r),i.sort(function(f,h){var I=f.node.props.value,d=h.node.props.value,p=a.indexOf(I),C=a.indexOf(d);return p-C}))}Object.defineProperty(e,"triggerNode",{get:function(){return(0,Lt.ZP)(!1,"`triggerNode` is deprecated. Please consider decoupling data with node."),c(),l}}),Object.defineProperty(e,"allCheckedNodes",{get:function(){return(0,Lt.ZP)(!1,"`allCheckedNodes` is deprecated. Please consider decoupling data with node."),c(),o?i:i.map(function(f){var h=f.node;return h})}})}var ra=function(t,a,r){var o=r.fieldNames,u=r.treeNodeFilterProp,l=r.filterTreeNode,i=o.children;return n.useMemo(function(){if(!a||l===!1)return t;var c=typeof l=="function"?l:function(f,h){return String(h[u]).toUpperCase().includes(a.toUpperCase())},s=function f(h){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return h.reduce(function(d,p){var C=p[i],m=I||c(a,_t(p)),E=f(C||[],m);return(m||E.length)&&d.push((0,N.Z)((0,N.Z)({},p),{},(0,ye.Z)({isLeaf:void 0},i,E))),d},[])};return s(t)},[t,a,i,u,l])},aa=ra;function On(e){var t=n.useRef();t.current=e;var a=n.useCallback(function(){return t.current.apply(t,arguments)},[]);return a}function oa(e,t){var a=t.id,r=t.pId,o=t.rootPId,u=new Map,l=[];return e.forEach(function(i){var c=i[a],s=(0,N.Z)((0,N.Z)({},i),{},{key:i.key||c});u.set(c,s)}),u.forEach(function(i){var c=i[r],s=u.get(c);s?(s.children=s.children||[],s.children.push(i)):(c===o||o===null)&&l.push(i)}),l}function la(e,t,a){return n.useMemo(function(){if(e){if(a){var r=(0,N.Z)({id:"id",pId:"pId",rootPId:null},(0,It.Z)(a)==="object"?a:{});return oa(e,r)}return e}return Zn(t)},[t,a,e])}var ia=n.createContext(null),Pn=ia,ua=v(40181);function ca(e,t){var a=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!a){if(Array.isArray(e)||(a=(0,ua.Z)(e))||t&&e&&typeof e.length=="number"){a&&(e=a);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(s){throw s},f:o}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var u,l=!0,i=!1;return{s:function(){a=a.call(e)},n:function(){var s=a.next();return l=s.done,s},e:function(s){i=!0,u=s},f:function(){try{l||a.return==null||a.return()}finally{if(i)throw u}}}}var Rn=v(70593),sa=n.createContext(null),Dn=sa,da=function(t){return Array.isArray(t)?t:t!==void 0?[t]:[]},fa=function(t){var a=t||{},r=a.label,o=a.value,u=a.children;return{_title:r?[r]:["title","label"],value:o||"value",key:o||"value",children:u||"children"}},en=function(t){return!t||t.disabled||t.disableCheckbox||t.checkable===!1},va=function(t,a){var r=[],o=function u(l){l.forEach(function(i){var c=i[a.children];c&&(r.push(i[a.value]),u(c))})};return o(t),r},Mn=function(t){return t==null},ma=v(56790),ha={width:0,height:0,display:"flex",overflow:"hidden",opacity:0,border:0,padding:0,margin:0},ga=function(t,a){var r=ln(),o=r.prefixCls,u=r.multiple,l=r.searchValue,i=r.toggleOpen,c=r.open,s=r.notFoundContent,f=n.useContext(Dn),h=f.virtual,I=f.listHeight,d=f.listItemHeight,p=f.listItemScrollOffset,C=f.treeData,m=f.fieldNames,E=f.onSelect,q=f.dropdownMatchSelectWidth,j=f.treeExpandAction,V=f.treeTitleRender,F=f.onPopupScroll,b=f.leftMaxCount,se=f.leafCountOnly,he=f.valueEntities,R=n.useContext(Pn),ee=R.checkable,z=R.checkedKeys,de=R.halfCheckedKeys,te=R.treeExpandedKeys,Ie=R.treeDefaultExpandAll,ae=R.treeDefaultExpandedKeys,fe=R.onTreeExpand,xe=R.treeIcon,Se=R.showTreeIcon,ve=R.switcherIcon,W=R.treeLine,A=R.treeNodeFilterProp,Pe=R.loadData,Ve=R.treeLoadedKeys,Le=R.treeMotion,oe=R.onTreeLoad,He=R.keyEntities,ne=n.useRef(),Me=(0,Xt.Z)(function(){return C},[c,C],function(T,$){return $[0]&&T[1]!==$[1]}),Ee=n.useMemo(function(){return ee?{checked:z,halfChecked:de}:null},[ee,z,de]);n.useEffect(function(){if(c&&!u&&z.length){var T;(T=ne.current)===null||T===void 0||T.scrollTo({key:z[0]})}},[c]);var Ze=function($){$.preventDefault()},O=function($,Re){var me=Re.node;ee&&en(me)||(E(me.key,{selected:!z.includes(me.key)}),u||i(!1))},g=n.useState(ae),D=(0,B.Z)(g,2),L=D[0],y=D[1],M=n.useState(null),G=(0,B.Z)(M,2),re=G[0],K=G[1],le=n.useMemo(function(){return te?(0,be.Z)(te):l?re:L},[L,re,te,l]),Ae=function($){y($),K($),fe&&fe($)},Be=String(l).toLowerCase(),J=function($){return Be?String($[A]).toLowerCase().includes(Be):!1};n.useEffect(function(){l&&K(va(C,m))},[l]);var Ce=n.useState(function(){return new Map}),je=(0,B.Z)(Ce,2),We=je[0],Ye=je[1];n.useEffect(function(){b&&Ye(new Map)},[b]);function ge(T){var $=T[m.value];if(!We.has($)){var Re=he.get($),me=(Re.children||[]).length===0;if(me)We.set($,!1);else{var De=Re.children.filter(function(ke){return!ke.node.disabled&&!ke.node.disableCheckbox&&!z.includes(ke.node[m.value])}),ze=De.length;We.set($,ze>b)}}return We.get($)}var X=(0,ma.zX)(function(T){var $=T[m.value];return z.includes($)||b===null?!1:b<=0?!0:se&&b?ge(T):!1}),Te=function T($){var Re=ca($),me;try{for(Re.s();!(me=Re.n()).done;){var De=me.value;if(!(De.disabled||De.selectable===!1)){if(l){if(J(De))return De}else return De;if(De[m.children]){var ze=T(De[m.children]);if(ze)return ze}}}}catch(ke){Re.e(ke)}finally{Re.f()}return null},Je=n.useState(null),et=(0,B.Z)(Je,2),Qe=et[0],Ge=et[1],we=He[Qe];n.useEffect(function(){if(c){var T=null,$=function(){var me=Te(Me);return me?me[m.value]:null};!u&&z.length&&!l?T=z[0]:T=$(),Ge(T)}},[c,l]),n.useImperativeHandle(a,function(){var T;return{scrollTo:(T=ne.current)===null||T===void 0?void 0:T.scrollTo,onKeyDown:function(Re){var me,De=Re.which;switch(De){case P.Z.UP:case P.Z.DOWN:case P.Z.LEFT:case P.Z.RIGHT:(me=ne.current)===null||me===void 0||me.onKeyDown(Re);break;case P.Z.ENTER:{if(we){var ze=X(we.node),ke=(we==null?void 0:we.node)||{},ot=ke.selectable,tt=ke.value,mt=ke.disabled;ot!==!1&&!mt&&!ze&&O(null,{node:{key:Qe},selected:!z.includes(tt)})}break}case P.Z.ESC:i(!1)}},onKeyUp:function(){}}});var vt=(0,Xt.Z)(function(){return!l},[l,te||L],function(T,$){var Re=(0,B.Z)(T,1),me=Re[0],De=(0,B.Z)($,2),ze=De[0],ke=De[1];return me!==ze&&!!(ze||ke)}),ie=vt?Pe:null;if(Me.length===0)return n.createElement("div",{role:"listbox",className:"".concat(o,"-empty"),onMouseDown:Ze},s);var $e={fieldNames:m};return Ve&&($e.loadedKeys=Ve),le&&($e.expandedKeys=le),n.createElement("div",{onMouseDown:Ze},we&&c&&n.createElement("span",{style:ha,"aria-live":"assertive"},we.node.value),n.createElement(Rn.y6.Provider,{value:{nodeDisabled:X}},n.createElement(Rn.ZP,(0,Xe.Z)({ref:ne,focusable:!1,prefixCls:"".concat(o,"-tree"),treeData:Me,height:I,itemHeight:d,itemScrollOffset:p,virtual:h!==!1&&q!==!1,multiple:u,icon:xe,showIcon:Se,switcherIcon:ve,showLine:W,loadData:ie,motion:Le,activeKey:Qe,checkable:ee,checkStrictly:!0,checkedKeys:Ee,selectedKeys:ee?[]:z,defaultExpandAll:Ie,titleRender:V},$e,{onActiveChange:Ge,onSelect:O,onCheck:O,onExpand:Ae,onLoad:oe,filterTreeNode:J,expandAction:j,onScroll:F}))))},pa=n.forwardRef(ga),Sa=pa,tn="SHOW_ALL",nn="SHOW_PARENT",Ht="SHOW_CHILD";function Tn(e,t,a,r){var o=new Set(e);return t===Ht?e.filter(function(u){var l=a[u];return!l||!l.children||!l.children.some(function(i){var c=i.node;return o.has(c[r.value])})||!l.children.every(function(i){var c=i.node;return en(c)||o.has(c[r.value])})}):t===nn?e.filter(function(u){var l=a[u],i=l?l.parent:null;return!i||en(i.node)||!o.has(i.key)}):e}function to(e){var t=e.searchPlaceholder,a=e.treeCheckStrictly,r=e.treeCheckable,o=e.labelInValue,u=e.value,l=e.multiple,i=e.showCheckedStrategy,c=e.maxCount;warning(!t,"`searchPlaceholder` has been removed."),a&&o===!1&&warning(!1,"`treeCheckStrictly` will force set `labelInValue` to `true`."),(o||a)&&warning(toArray(u).every(function(s){return s&&_typeof(s)==="object"&&"value"in s}),"Invalid prop `value` supplied to `TreeSelect`. You should use { label: string, value: string | number } or [{ label: string, value: string | number }] instead."),a||l||r?warning(!u||Array.isArray(u),"`value` should be an array when `TreeSelect` is checkable or multiple."):warning(!Array.isArray(u),"`value` should not be array when `TreeSelect` is single mode."),c&&(i==="SHOW_ALL"&&!a||i==="SHOW_PARENT")&&warning(!1,"`maxCount` not work with `showCheckedStrategy=SHOW_ALL` (when `treeCheckStrictly=false`) or `showCheckedStrategy=SHOW_PARENT`.")}var no=null,Ca=["id","prefixCls","value","defaultValue","onChange","onSelect","onDeselect","searchValue","inputValue","onSearch","autoClearSearchValue","filterTreeNode","treeNodeFilterProp","showCheckedStrategy","treeNodeLabelProp","multiple","treeCheckable","treeCheckStrictly","labelInValue","maxCount","fieldNames","treeDataSimpleMode","treeData","children","loadData","treeLoadedKeys","onTreeLoad","treeDefaultExpandAll","treeExpandedKeys","treeDefaultExpandedKeys","onTreeExpand","treeExpandAction","virtual","listHeight","listItemHeight","listItemScrollOffset","onDropdownVisibleChange","dropdownMatchSelectWidth","treeLine","treeIcon","showTreeIcon","switcherIcon","treeMotion","treeTitleRender","onPopupScroll"];function ba(e){return!e||(0,It.Z)(e)!=="object"}var ya=n.forwardRef(function(e,t){var a=e.id,r=e.prefixCls,o=r===void 0?"rc-tree-select":r,u=e.value,l=e.defaultValue,i=e.onChange,c=e.onSelect,s=e.onDeselect,f=e.searchValue,h=e.inputValue,I=e.onSearch,d=e.autoClearSearchValue,p=d===void 0?!0:d,C=e.filterTreeNode,m=e.treeNodeFilterProp,E=m===void 0?"value":m,q=e.showCheckedStrategy,j=e.treeNodeLabelProp,V=e.multiple,F=e.treeCheckable,b=e.treeCheckStrictly,se=e.labelInValue,he=e.maxCount,R=e.fieldNames,ee=e.treeDataSimpleMode,z=e.treeData,de=e.children,te=e.loadData,Ie=e.treeLoadedKeys,ae=e.onTreeLoad,fe=e.treeDefaultExpandAll,xe=e.treeExpandedKeys,Se=e.treeDefaultExpandedKeys,ve=e.onTreeExpand,W=e.treeExpandAction,A=e.virtual,Pe=e.listHeight,Ve=Pe===void 0?200:Pe,Le=e.listItemHeight,oe=Le===void 0?20:Le,He=e.listItemScrollOffset,ne=He===void 0?0:He,Me=e.onDropdownVisibleChange,Ee=e.dropdownMatchSelectWidth,Ze=Ee===void 0?!0:Ee,O=e.treeLine,g=e.treeIcon,D=e.showTreeIcon,L=e.switcherIcon,y=e.treeMotion,M=e.treeTitleRender,G=e.onPopupScroll,re=(0,rt.Z)(e,Ca),K=yn(a),le=F&&!b,Ae=F||b,Be=b||se,J=Ae||V,Ce=(0,gt.Z)(l,{value:u}),je=(0,B.Z)(Ce,2),We=je[0],Ye=je[1],ge=n.useMemo(function(){return F?q||Ht:tn},[q,F]),X=n.useMemo(function(){return fa(R)},[JSON.stringify(R)]),Te=(0,gt.Z)("",{value:f!==void 0?f:h,postState:function(U){return U||""}}),Je=(0,B.Z)(Te,2),et=Je[0],Qe=Je[1],Ge=function(U){Qe(U),I==null||I(U)},we=la(z,de,ee),vt=_r(we,X),ie=vt.keyEntities,$e=vt.valueEntities,T=n.useCallback(function(_){var U=[],H=[];return _.forEach(function(pe){$e.has(pe)?H.push(pe):U.push(pe)}),{missingRawValues:U,existRawValues:H}},[$e]),$=aa(we,et,{fieldNames:X,treeNodeFilterProp:E,filterTreeNode:C}),Re=n.useCallback(function(_){if(_){if(j)return _[j];for(var U=X._title,H=0;H<U.length;H+=1){var pe=_[U[H]];if(pe!==void 0)return pe}}},[X,j]),me=n.useCallback(function(_){var U=da(_);return U.map(function(H){return ba(H)?{value:H}:H})},[]),De=n.useCallback(function(_){var U=me(_);return U.map(function(H){var pe=H.label,dt=H.value,Ke=H.halfChecked,ce,Oe=$e.get(dt);if(Oe){var at;pe=M?M(Oe.node):(at=pe)!==null&&at!==void 0?at:Re(Oe.node),ce=Oe.node.disabled}else if(pe===void 0){var Ct=me(We).find(function(Dt){return Dt.value===dt});pe=Ct.label}return{label:pe,value:dt,halfChecked:Ke,disabled:ce}})},[$e,Re,me,We]),ze=n.useMemo(function(){return me(We===null?[]:We)},[me,We]),ke=n.useMemo(function(){var _=[],U=[];return ze.forEach(function(H){H.halfChecked?U.push(H):_.push(H)}),[_,U]},[ze]),ot=(0,B.Z)(ke,2),tt=ot[0],mt=ot[1],Ne=n.useMemo(function(){return tt.map(function(_){return _.value})},[tt]),Zt=Qr(tt,mt,le,ie),pt=(0,B.Z)(Zt,2),S=pt[0],x=pt[1],w=n.useMemo(function(){var _=Tn(S,ge,ie,X),U=_.map(function(Ke){var ce,Oe;return(ce=(Oe=ie[Ke])===null||Oe===void 0||(Oe=Oe.node)===null||Oe===void 0?void 0:Oe[X.value])!==null&&ce!==void 0?ce:Ke}),H=U.map(function(Ke){var ce=tt.find(function(at){return at.value===Ke}),Oe=se?ce==null?void 0:ce.label:M==null?void 0:M(ce);return{value:Ke,label:Oe}}),pe=De(H),dt=pe[0];return!J&&dt&&Mn(dt.value)&&Mn(dt.label)?[]:pe.map(function(Ke){var ce;return(0,N.Z)((0,N.Z)({},Ke),{},{label:(ce=Ke.label)!==null&&ce!==void 0?ce:Ke.value})})},[X,J,S,tt,De,ge,ie]),Z=Yr(w),Y=(0,B.Z)(Z,1),ue=Y[0],lt=n.useMemo(function(){return J&&(ge==="SHOW_CHILD"||b||!F)?he:null},[he,J,b,ge,F]),qe=On(function(_,U,H){var pe=Tn(_,ge,ie,X);if(!(lt&&pe.length>lt)){var dt=De(_);if(Ye(dt),p&&Qe(""),i){var Ke=_;le&&(Ke=pe.map(function(ft){var yt=$e.get(ft);return yt?yt.node[X.value]:ft}));var ce=U||{triggerValue:void 0,selected:void 0},Oe=ce.triggerValue,at=ce.selected,Ct=Ke;if(b){var Dt=mt.filter(function(ft){return!Ke.includes(ft.value)});Ct=[].concat((0,be.Z)(Ct),(0,be.Z)(Dt))}var Mt=De(Ct),bt={preValue:tt,triggerValue:Oe},Ot=!0;(b||H==="selection"&&!at)&&(Ot=!1),na(bt,Oe,_,we,Ot,X),Ae?bt.checked=at:bt.selected=at;var Tt=Be?Mt:Mt.map(function(ft){return ft.value});i(J?Tt:Tt[0],Be?null:Mt.map(function(ft){return ft.label}),bt)}}}),it=n.useCallback(function(_,U){var H,pe=U.selected,dt=U.source,Ke=ie[_],ce=Ke==null?void 0:Ke.node,Oe=(H=ce==null?void 0:ce[X.value])!==null&&H!==void 0?H:_;if(!J)qe([Oe],{selected:!0,triggerValue:Oe},"option");else{var at=pe?[].concat((0,be.Z)(Ne),[Oe]):S.filter(function(yt){return yt!==Oe});if(le){var Ct=T(at),Dt=Ct.missingRawValues,Mt=Ct.existRawValues,bt=Mt.map(function(yt){return $e.get(yt).key}),Ot;if(pe){var Tt=(0,Qt.S)(bt,!0,ie);Ot=Tt.checkedKeys}else{var ft=(0,Qt.S)(bt,{checked:!1,halfCheckedKeys:x},ie);Ot=ft.checkedKeys}at=[].concat((0,be.Z)(Dt),(0,be.Z)(Ot.map(function(yt){return ie[yt].node[X.value]})))}qe(at,{selected:pe,triggerValue:Oe},dt||"option")}pe||!J?c==null||c(Oe,_t(ce)):s==null||s(Oe,_t(ce))},[T,$e,ie,X,J,Ne,qe,le,c,s,S,x,he]),Fe=n.useCallback(function(_){if(Me){var U={};Object.defineProperty(U,"documentClickClose",{get:function(){return(0,Lt.ZP)(!1,"Second param of `onDropdownVisibleChange` has been removed."),!1}}),Me(_,U)}},[Me]),ht=On(function(_,U){var H=_.map(function(pe){return pe.value});if(U.type==="clear"){qe(H,{},"selection");return}U.values.length&&it(U.values[0].value,{selected:!1,source:"selection"})}),st=n.useMemo(function(){return{virtual:A,dropdownMatchSelectWidth:Ze,listHeight:Ve,listItemHeight:oe,listItemScrollOffset:ne,treeData:$,fieldNames:X,onSelect:it,treeExpandAction:W,treeTitleRender:M,onPopupScroll:G,leftMaxCount:he===void 0?null:he-ue.length,leafCountOnly:ge==="SHOW_CHILD"&&!b&&!!F,valueEntities:$e}},[A,Ze,Ve,oe,ne,$,X,it,W,M,G,he,ue.length,ge,b,F,$e]),xt=n.useMemo(function(){return{checkable:Ae,loadData:te,treeLoadedKeys:Ie,onTreeLoad:ae,checkedKeys:S,halfCheckedKeys:x,treeDefaultExpandAll:fe,treeExpandedKeys:xe,treeDefaultExpandedKeys:Se,onTreeExpand:ve,treeIcon:g,treeMotion:y,showTreeIcon:D,switcherIcon:L,treeLine:O,treeNodeFilterProp:E,keyEntities:ie}},[Ae,te,Ie,ae,S,x,fe,xe,Se,ve,g,y,D,L,O,E,ie]);return n.createElement(Dn.Provider,{value:st},n.createElement(Pn.Provider,{value:xt},n.createElement(gn,(0,Xe.Z)({ref:t},re,{id:K,prefixCls:o,mode:J?"multiple":void 0,displayValues:ue,onDisplayValuesChange:ht,searchValue:et,onSearch:Ge,OptionList:Sa,emptyOptions:!we.length,onDropdownVisibleChange:Fe,dropdownMatchSelectWidth:Ze}))))}),kt=ya;kt.TreeNode=qt,kt.SHOW_ALL=tn,kt.SHOW_PARENT=nn,kt.SHOW_CHILD=Ht;var wa=kt,Ia=wa,xa=v(87263),Nn=v(33603),Ea=v(8745),Vn=v(9708),Ln=v(53124),Za=v(88258),Oa=v(98866),An=v(35792),Pa=v(98675),Ra=v(65223),Da=v(27833),Ma=v(30307),Ta=v(15030),Na=v(43277),Va=v(78642),La=v(4173),Aa=v(15729),ka=v(23797),kn=v(11568),Fa=v(63185),Fn=v(83262),Ka=v(83559),Kn=v(40561);const Ha=e=>{const{componentCls:t,treePrefixCls:a,colorBgElevated:r}=e,o=`.${a}`;return[{[`${t}-dropdown`]:[{padding:`${(0,kn.bf)(e.paddingXS)} ${(0,kn.bf)(e.calc(e.paddingXS).div(2).equal())}`},(0,Kn.Yk)(a,(0,Fn.IX)(e,{colorBgContainer:r}),!1),{[o]:{borderRadius:0,[`${o}-list-holder-inner`]:{alignItems:"stretch",[`${o}-treenode`]:{[`${o}-node-content-wrapper`]:{flex:"auto"}}}}},(0,Fa.C2)(`${a}-checkbox`,e),{"&-rtl":{direction:"rtl",[`${o}-switcher${o}-switcher_close`]:{[`${o}-switcher-icon svg`]:{transform:"rotate(90deg)"}}}}]}]},ro=null;function Wa(e,t,a){return(0,Ka.I$)("TreeSelect",r=>{const o=(0,Fn.IX)(r,{treePrefixCls:t});return[Ha(o)]},Kn.TM)(e,a)}var $a=function(e,t){var a={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(a[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(a[r[o]]=e[r[o]]);return a};const Ba=(e,t)=>{var a,r,o,u,l;const{prefixCls:i,size:c,disabled:s,bordered:f=!0,style:h,className:I,rootClassName:d,treeCheckable:p,multiple:C,listHeight:m=256,listItemHeight:E,placement:q,notFoundContent:j,switcherIcon:V,treeLine:F,getPopupContainer:b,popupClassName:se,dropdownClassName:he,treeIcon:R=!1,transitionName:ee,choiceTransitionName:z="",status:de,treeExpandAction:te,builtinPlacements:Ie,dropdownMatchSelectWidth:ae,popupMatchSelectWidth:fe,allowClear:xe,variant:Se,dropdownStyle:ve,dropdownRender:W,popupRender:A,onDropdownVisibleChange:Pe,onOpenChange:Ve,tagRender:Le,maxCount:oe,showCheckedStrategy:He,treeCheckStrictly:ne,styles:Me,classNames:Ee}=e,Ze=$a(e,["prefixCls","size","disabled","bordered","style","className","rootClassName","treeCheckable","multiple","listHeight","listItemHeight","placement","notFoundContent","switcherIcon","treeLine","getPopupContainer","popupClassName","dropdownClassName","treeIcon","transitionName","choiceTransitionName","status","treeExpandAction","builtinPlacements","dropdownMatchSelectWidth","popupMatchSelectWidth","allowClear","variant","dropdownStyle","dropdownRender","popupRender","onDropdownVisibleChange","onOpenChange","tagRender","maxCount","showCheckedStrategy","treeCheckStrictly","styles","classNames"]),{getPopupContainer:O,getPrefixCls:g,renderEmpty:D,direction:L,virtual:y,popupMatchSelectWidth:M,popupOverflow:G}=n.useContext(Ln.E_),{styles:re,classNames:K}=(0,Ln.dj)("treeSelect"),[,le]=(0,Aa.ZP)(),Ae=E!=null?E:(le==null?void 0:le.controlHeightSM)+(le==null?void 0:le.paddingXXS),Be=g(),J=g("select",i),Ce=g("select-tree",i),je=g("tree-select",i),{compactSize:We,compactItemClassnames:Ye}=(0,La.ri)(J,L),ge=(0,An.Z)(J),X=(0,An.Z)(je),[Te,Je,et]=(0,Ta.Z)(J,ge),[Qe]=Wa(je,Ce,X),[Ge,we]=(0,Da.Z)("treeSelect",Se,f),vt=_e()(((a=Ee==null?void 0:Ee.popup)===null||a===void 0?void 0:a.root)||((r=K==null?void 0:K.popup)===null||r===void 0?void 0:r.root)||se||he,`${je}-dropdown`,{[`${je}-dropdown-rtl`]:L==="rtl"},d,K.root,Ee==null?void 0:Ee.root,et,ge,X,Je),ie=((o=Me==null?void 0:Me.popup)===null||o===void 0?void 0:o.root)||((u=re==null?void 0:re.popup)===null||u===void 0?void 0:u.root)||ve,$e=A||W,T=Ve||Pe,$=!!(p||C),Re=n.useMemo(()=>{if(!(oe&&(He==="SHOW_ALL"&&!ne||He==="SHOW_PARENT")))return oe},[oe,He,ne]),me=(0,Va.Z)(e.suffixIcon,e.showArrow),De=(l=fe!=null?fe:ae)!==null&&l!==void 0?l:M,{status:ze,hasFeedback:ke,isFormItemInput:ot,feedbackIcon:tt}=n.useContext(Ra.aM),mt=(0,Vn.F)(ze,de),{suffixIcon:Ne,removeIcon:Zt,clearIcon:pt}=(0,Na.Z)(Object.assign(Object.assign({},Ze),{multiple:$,showSuffixIcon:me,hasFeedback:ke,feedbackIcon:tt,prefixCls:J,componentName:"TreeSelect"})),S=xe===!0?{clearIcon:pt}:xe;let x;j!==void 0?x=j:x=(D==null?void 0:D("Select"))||n.createElement(Za.Z,{componentName:"Select"});const w=(0,Yt.Z)(Ze,["suffixIcon","removeIcon","clearIcon","itemIcon","switcherIcon","style"]),Z=n.useMemo(()=>q!==void 0?q:L==="rtl"?"bottomRight":"bottomLeft",[q,L]),Y=(0,Pa.Z)(st=>{var xt;return(xt=c!=null?c:We)!==null&&xt!==void 0?xt:st}),ue=n.useContext(Oa.Z),lt=s!=null?s:ue,qe=_e()(!i&&je,{[`${J}-lg`]:Y==="large",[`${J}-sm`]:Y==="small",[`${J}-rtl`]:L==="rtl",[`${J}-${Ge}`]:we,[`${J}-in-form-item`]:ot},(0,Vn.Z)(J,mt,ke),Ye,I,d,K.root,Ee==null?void 0:Ee.root,et,ge,X,Je),it=st=>n.createElement(ka.Z,{prefixCls:Ce,switcherIcon:V,treeNodeProps:st,showLine:F}),[Fe]=(0,xa.Cn)("SelectLike",ie==null?void 0:ie.zIndex),ht=n.createElement(Ia,Object.assign({virtual:y,disabled:lt},w,{dropdownMatchSelectWidth:De,builtinPlacements:(0,Ma.Z)(Ie,G),ref:t,prefixCls:J,className:qe,style:Object.assign(Object.assign({},Me==null?void 0:Me.root),h),listHeight:m,listItemHeight:Ae,treeCheckable:p&&n.createElement("span",{className:`${J}-tree-checkbox-inner`}),treeLine:!!F,suffixIcon:Ne,multiple:$,placement:Z,removeIcon:Zt,allowClear:S,switcherIcon:it,showTreeIcon:R,notFoundContent:x,getPopupContainer:b||O,treeMotion:null,dropdownClassName:vt,dropdownStyle:Object.assign(Object.assign({},ie),{zIndex:Fe}),dropdownRender:$e,onDropdownVisibleChange:T,choiceTransitionName:(0,Nn.m)(Be,"",z),transitionName:(0,Nn.m)(Be,"slide-up",ee),treeExpandAction:te,tagRender:$?Le:void 0,maxCount:Re,showCheckedStrategy:He,treeCheckStrictly:ne}));return Te(Qe(ht))},Rt=n.forwardRef(Ba),za=(0,Ea.Z)(Rt,"dropdownAlign",e=>(0,Yt.Z)(e,["visible"]));Rt.TreeNode=qt,Rt.SHOW_ALL=tn,Rt.SHOW_PARENT=nn,Rt.SHOW_CHILD=Ht,Rt._InternalPanelDoNotUseOrYouWillBeFired=za;var Ua=Rt}}]);