(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9770],{53449:function(e,t,n){"use strict";function r(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}n.d(t,{Kb:function(){return j},M$:function(){return $}});var i=n(17610),o=n(63074),u=n.n(o),c=n(7653);function s(e){return"object"==typeof e&&null!=e&&1===e.nodeType}function a(e,t){return(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e}function l(e,t){if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){var n,r=getComputedStyle(e,null);return a(r.overflowY,t)||a(r.overflowX,t)||!!(n=function(e){if(!e.ownerDocument||!e.ownerDocument.defaultView)return null;try{return e.ownerDocument.defaultView.frameElement}catch(e){return null}}(e))&&(n.clientHeight<e.scrollHeight||n.clientWidth<e.scrollWidth)}return!1}function d(e,t,n,r,i,o,u,c){return o<e&&u>t||o>e&&u<t?0:o<=e&&c<=n||u>=t&&c>=n?o-e-r:u>t&&c<n||o<e&&c>n?u-t+i:0}n(74753);var f=function(e,t){var n=window,r=t.scrollMode,i=t.block,o=t.inline,u=t.boundary,c=t.skipOverflowHiddenElements,a="function"==typeof u?u:function(e){return e!==u};if(!s(e))throw TypeError("Invalid target");for(var f,h,g=document.scrollingElement||document.documentElement,p=[],v=e;s(v)&&a(v);){if((v=null==(h=(f=v).parentElement)?f.getRootNode().host||null:h)===g){p.push(v);break}null!=v&&v===document.body&&l(v)&&!l(document.documentElement)||null!=v&&l(v,c)&&p.push(v)}for(var m=n.visualViewport?n.visualViewport.width:innerWidth,I=n.visualViewport?n.visualViewport.height:innerHeight,y=window.scrollX||pageXOffset,b=window.scrollY||pageYOffset,x=e.getBoundingClientRect(),w=x.height,k=x.width,C=x.top,E=x.right,M=x.bottom,O=x.left,R="start"===i||"nearest"===i?C:"end"===i?M:C+w/2,S="center"===o?O+k/2:"end"===o?E:O,D=[],K=0;K<p.length;K++){var T=p[K],V=T.getBoundingClientRect(),A=V.height,N=V.width,P=V.top,Z=V.right,L=V.bottom,F=V.left;if("if-needed"===r&&C>=0&&O>=0&&M<=I&&E<=m&&C>=P&&M<=L&&O>=F&&E<=Z)break;var B=getComputedStyle(T),H=parseInt(B.borderLeftWidth,10),W=parseInt(B.borderTopWidth,10),_=parseInt(B.borderRightWidth,10),j=parseInt(B.borderBottomWidth,10),U=0,X=0,Y="offsetWidth"in T?T.offsetWidth-T.clientWidth-H-_:0,q="offsetHeight"in T?T.offsetHeight-T.clientHeight-W-j:0,z="offsetWidth"in T?0===T.offsetWidth?0:N/T.offsetWidth:0,$="offsetHeight"in T?0===T.offsetHeight?0:A/T.offsetHeight:0;if(g===T)U="start"===i?R:"end"===i?R-I:"nearest"===i?d(b,b+I,I,W,j,b+R,b+R+w,w):R-I/2,X="start"===o?S:"center"===o?S-m/2:"end"===o?S-m:d(y,y+m,m,H,_,y+S,y+S+k,k),U=Math.max(0,U+b),X=Math.max(0,X+y);else{U="start"===i?R-P-W:"end"===i?R-L+j+q:"nearest"===i?d(P,L,A,W,j+q,R,R+w,w):R-(P+A/2)+q/2,X="start"===o?S-F-H:"center"===o?S-(F+N/2)+Y/2:"end"===o?S-Z+_+Y:d(F,Z,N,H,_+Y,S,S+k,k);var G=T.scrollLeft,J=T.scrollTop;R+=J-(U=Math.max(0,Math.min(J+U/$,T.scrollHeight-A/$+q))),S+=G-(X=Math.max(0,Math.min(G+X/z,T.scrollWidth-N/z+Y)))}D.push({el:T,top:U,left:X})}return D},h=0;function g(e,t){return e===t||e.contains&&e.contains(t)}function p(e,t){var n;function r(){n&&clearTimeout(n)}function i(){for(var i=arguments.length,o=Array(i),u=0;u<i;u++)o[u]=arguments[u];r(),n=setTimeout(function(){n=null,e.apply(void 0,o)},t)}return i.cancel=r,i}function v(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){for(var n=arguments.length,r=Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return t.some(function(t){return t&&t.apply(void 0,[e].concat(r)),e.preventDownshiftDefault||e.hasOwnProperty("nativeEvent")&&e.nativeEvent.preventDownshiftDefault})}}function m(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){t.forEach(function(t){"function"==typeof t?t(e):t&&(t.current=e)})}}function I(){return String(h++)}function y(e,t){return Object.keys(e).reduce(function(n,r){return n[r]=void 0!==t[r]?t[r]:e[r],n},{})}function b(e){var t=e.key,n=e.keyCode;return n>=37&&n<=40&&0!==t.indexOf("Arrow")?"Arrow"+t:t}function x(e,t,n,r,i){if(void 0===i&&(i=!0),0===n)return -1;var o=n-1;("number"!=typeof t||t<0||t>=n)&&(t=e>0?-1:o+1);var u=t+e;u<0?u=i?o:0:u>o&&(u=i?0:o);var c=w(e,u,n,r,i);return -1===c?t>=n?-1:t:c}function w(e,t,n,r,i){var o=r(t);if(!o||!o.hasAttribute("disabled"))return t;if(e>0){for(var u=t+1;u<n;u++)if(!r(u).hasAttribute("disabled"))return u}else for(var c=t-1;c>=0;c--)if(!r(c).hasAttribute("disabled"))return c;return i?e>0?w(1,0,n,r,!1):w(-1,n-1,n,r,!1):-1}function k(e,t,n,r){return void 0===r&&(r=!0),t.some(function(t){return t&&(g(t,e)||r&&g(t,n.activeElement))})}var C=p(function(){M().textContent=""},500);function E(e,t){var n=M(t);e&&(n.textContent=e,C())}function M(e){void 0===e&&(e=document);var t=e.getElementById("a11y-status-message");return t||((t=e.createElement("div")).setAttribute("id","a11y-status-message"),t.setAttribute("role","status"),t.setAttribute("aria-live","polite"),t.setAttribute("aria-relevant","additions text"),Object.assign(t.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(t)),t}var O={highlightedIndex:-1,isOpen:!1,selectedItem:null,inputValue:""},R=p(function(e,t){E(e(),t)},200);function S(e,t,n){return void 0!==e?e:0===n.length?-1:n.indexOf(t)}function D(e){return""+e.slice(0,1).toUpperCase()+e.slice(1)}function K(e){var t=(0,c.useRef)(e);return t.current=e,t}function T(e,t,n){var r=(0,c.useRef)(),o=(0,c.useRef)(),u=(0,c.useCallback)(function(t,n){o.current=n;var r=e(t=y(t,n.props),n);return n.props.stateReducer(t,(0,i.Z)({},n,{changes:r}))},[e]),s=(0,c.useReducer)(u,t),a=s[0],l=s[1],d=K(n),f=(0,c.useCallback)(function(e){return l((0,i.Z)({props:d.current},e))},[d]),h=o.current;return(0,c.useEffect)(function(){if(h&&r.current&&r.current!==a){var e,t,n,o;e=y(r.current,h.props),t=h.props,n=h.type,o={},Object.keys(e).forEach(function(t){var n,r,u;n=h.props,r=h.type,n[u="on"+D(t)+"Change"]&&void 0!==a[t]&&a[t]!==e[t]&&n[u]((0,i.Z)({type:r},a)),a[t]!==e[t]&&(o[t]=a[t])}),t.onStateChange&&Object.keys(o).length&&t.onStateChange((0,i.Z)({type:n},o))}r.current=a},[a,n,h]),[a,f]}var V={itemToString:function(e){return e?String(e):""},stateReducer:function(e,t){return t.changes},getA11ySelectionMessage:function(e){var t=e.selectedItem,n=e.itemToString;return t?n(t)+" has been selected.":""},scrollIntoView:function(e,t){e&&f(e,{boundary:t,block:"nearest",scrollMode:"if-needed"}).forEach(function(e){var t=e.el,n=e.top,r=e.left;t.scrollTop=n,t.scrollLeft=r})},circularNavigation:!1,environment:"undefined"==typeof window?{}:window};function A(e,t,n){void 0===n&&(n=O);var r="default"+D(t);return r in e?e[r]:n[t]}function N(e,t,n){if(void 0===n&&(n=O),t in e)return e[t];var r="initial"+D(t);return r in e?e[r]:A(e,t,n)}function P(e,t,n,r){var i=e.items,o=e.initialHighlightedIndex,u=e.defaultHighlightedIndex,c=t.selectedItem,s=t.highlightedIndex;return 0===i.length?-1:void 0!==o&&s===o?o:void 0!==u?u:c?0===n?i.indexOf(c):x(n,i.indexOf(c),i.length,r,!1):0===n?-1:n<0?i.length-1:0}function Z(){(0,c.useRef)(!0);for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,c.useRef)(t.reduce(function(e,t){return e[t]={},e},{})),(0,c.useEffect)(function(){}),(0,c.useCallback)(function(e,t,n,r){},[])}function L(e,t,n){var o=n.isInitialMount,u=n.previousResultCount,s=n.highlightedIndex,a=n.items,l=n.environment,d=r(n,["isInitialMount","previousResultCount","highlightedIndex","items","environment"]);(0,c.useEffect)(function(){o||R(function(){return e((0,i.Z)({highlightedIndex:s,highlightedItem:a[s],resultCount:a.length,previousResultCount:u},d))},l.document)},t)}function F(e){var t=e.isInitialMount,n=e.props,r=e.state,i=(0,c.useRef)(n);(0,c.useEffect)(function(){t||(i.current,i.current=n)},[r,n,t])}function B(e,t,n,r,i){for(var o=n.map(function(e){return r(e).toLowerCase()}),u=e.toLowerCase(),c=function(e,t){var n=i(t);return e.startsWith(u)&&!(n&&n.hasAttribute("disabled"))},s=t+1;s<o.length;s++)if(c(o[s],s))return s;for(var a=0;a<t;a++)if(c(o[a],a))return a;return t}u().array.isRequired,u().func,u().func,u().func,u().bool,u().number,u().number,u().number,u().bool,u().bool,u().bool,u().any,u().any,u().any,u().string,u().string,u().string,u().func,u().string,u().func,u().func,u().func,u().func,u().func,u().shape({addEventListener:u().func,removeEventListener:u().func,document:u().shape({getElementById:u().func,activeElement:u().any,body:u().any})}),(0,i.Z)({},V,{getA11yStatusMessage:function(e){var t=e.isOpen,n=e.resultCount,r=e.previousResultCount;return t?n?n!==r?n+" result"+(1===n?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter or Space Bar keys to select.":"":"No results are available.":""}});var H=Object.freeze({__proto__:null,InputKeyDownArrowDown:0,InputKeyDownArrowUp:1,InputKeyDownEscape:2,InputKeyDownHome:3,InputKeyDownEnd:4,InputKeyDownEnter:5,InputChange:6,InputBlur:7,MenuMouseLeave:8,ItemMouseMove:9,ItemClick:10,ToggleButtonClick:11,FunctionToggleMenu:12,FunctionOpenMenu:13,FunctionCloseMenu:14,FunctionSetHighlightedIndex:15,FunctionSelectItem:16,FunctionSetInputValue:17,FunctionReset:18,ControlledPropUpdatedSelectedItem:19});u().array.isRequired,u().func,u().func,u().func,u().bool,u().number,u().number,u().number,u().bool,u().bool,u().bool,u().any,u().any,u().any,u().string,u().string,u().string,u().string,u().string,u().string,u().func,u().string,u().string,u().func,u().func,u().func,u().func,u().func,u().func,u().shape({addEventListener:u().func,removeEventListener:u().func,document:u().shape({getElementById:u().func,activeElement:u().any,body:u().any})});var W=(0,i.Z)({},V,{getA11yStatusMessage:function(e){var t=e.isOpen,n=e.resultCount,r=e.previousResultCount;return t?n?n!==r?n+" result"+(1===n?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter key to select.":"":"No results are available.":""},circularNavigation:!0});function _(e,t){var n,r=t.type,o=t.props,u=t.shiftKey;switch(r){case 9:n={highlightedIndex:t.index};break;case 10:n={isOpen:A(o,"isOpen"),highlightedIndex:A(o,"highlightedIndex"),selectedItem:o.items[t.index],inputValue:o.itemToString(o.items[t.index])};break;case 0:n=e.isOpen?{highlightedIndex:x(u?5:1,e.highlightedIndex,o.items.length,t.getItemNodeFromIndex,o.circularNavigation)}:{highlightedIndex:P(o,e,1,t.getItemNodeFromIndex),isOpen:!0};break;case 1:n=e.isOpen?{highlightedIndex:x(u?-5:-1,e.highlightedIndex,o.items.length,t.getItemNodeFromIndex,o.circularNavigation)}:{highlightedIndex:P(o,e,-1,t.getItemNodeFromIndex),isOpen:!0};break;case 5:n=(0,i.Z)({},e.isOpen&&e.highlightedIndex>=0&&{selectedItem:o.items[e.highlightedIndex],isOpen:A(o,"isOpen"),highlightedIndex:A(o,"highlightedIndex"),inputValue:o.itemToString(o.items[e.highlightedIndex])});break;case 2:n=(0,i.Z)({isOpen:!1,highlightedIndex:-1},!e.isOpen&&{selectedItem:null,inputValue:""});break;case 3:n=(0,i.Z)({},e.isOpen&&{highlightedIndex:w(1,0,o.items.length,t.getItemNodeFromIndex,!1)});break;case 4:n=(0,i.Z)({},e.isOpen&&{highlightedIndex:w(-1,o.items.length-1,o.items.length,t.getItemNodeFromIndex,!1)});break;case 7:e.isOpen&&(n=(0,i.Z)({isOpen:!1,highlightedIndex:-1},e.highlightedIndex>=0&&t.selectItem&&{selectedItem:o.items[e.highlightedIndex],inputValue:o.itemToString(o.items[e.highlightedIndex])}));break;case 6:n={isOpen:!0,highlightedIndex:A(o,"highlightedIndex"),inputValue:t.inputValue};break;case 8:n={highlightedIndex:-1};break;case 11:case 12:n={isOpen:!e.isOpen,highlightedIndex:e.isOpen?-1:P(o,e,0)};break;case 13:n={isOpen:!0,highlightedIndex:P(o,e,0)};break;case 14:n={isOpen:!1};break;case 15:n={highlightedIndex:t.highlightedIndex};break;case 16:n={selectedItem:t.selectedItem,inputValue:o.itemToString(t.selectedItem)};break;case 19:case 17:n={inputValue:t.inputValue};break;case 18:n={highlightedIndex:A(o,"highlightedIndex"),isOpen:A(o,"isOpen"),selectedItem:A(o,"selectedItem"),inputValue:A(o,"inputValue")};break;default:throw Error("Reducer called without proper action type.")}return(0,i.Z)({},e,n)}function j(e){void 0===e&&(e={});var t,n,o,u,s,a,l,d,f,h,g,p,x,w,C,E,M,O,R,D,V,A,P,B,H,j,U,X,Y,q,z,$,G,J,Q,ee,et=(0,i.Z)({},W,e),en=et.initialIsOpen,er=et.defaultIsOpen,ei=et.items,eo=et.scrollIntoView,eu=et.environment,ec=et.getA11yStatusMessage,es=et.getA11ySelectionMessage,ea=et.itemToString,el=(U=(A=N(V=et,"selectedItem"),P=N(V,"isOpen"),B=N(V,"highlightedIndex"),H=N(V,"inputValue"),j={highlightedIndex:B<0&&A&&P?V.items.indexOf(A):B,isOpen:P,selectedItem:A,inputValue:H}).selectedItem,""===(X=j.inputValue)&&U&&void 0===et.defaultInputValue&&void 0===et.initialInputValue&&void 0===et.inputValue&&(X=et.itemToString(U)),(0,i.Z)({},j,{inputValue:X})),ed=(Y=(0,c.useRef)(),z=(q=T(_,el,et))[0],$=q[1],(0,c.useEffect)(function(){void 0!==et.selectedItem&&(Y.current!==et.selectedItem&&$({type:19,inputValue:et.itemToString(et.selectedItem)}),Y.current=z.selectedItem===Y.current?et.selectedItem:z.selectedItem)}),[y(z,et),$]),ef=ed[0],eh=ed[1],eg=ef.isOpen,ep=ef.highlightedIndex,ev=ef.selectedItem,em=ef.inputValue,eI=(0,c.useRef)(null),ey=(0,c.useRef)(),eb=(0,c.useRef)(null),ex=(0,c.useRef)(null),ew=(0,c.useRef)(null);ey.current={};var ek=(0,c.useRef)(!0),eC=(0,c.useRef)((G=et.id,J=et.inputId,Q=r(et,["id","inputId"]),ee=void 0===G?"downshift-"+I():G,(0,i.Z)({inputId:J||ee+"-input"},(n=(t=(0,i.Z)({id:G},Q)).id,o=t.labelId,u=t.menuId,s=t.getItemId,a=t.toggleButtonId,l=void 0===n?"downshift-"+I():n,{labelId:o||l+"-label",menuId:u||l+"-menu",getItemId:s||function(e){return l+"-item-"+e},toggleButtonId:a||l+"-toggle-button"})))),eE=(0,c.useRef)(),eM=K({state:ef,props:et}),eO=function(e){return ey.current[eC.current.getItemId(e)]};L(ec,[eg,ep,em,ei],(0,i.Z)({isInitialMount:ek.current,previousResultCount:eE.current,items:ei,environment:eu,itemToString:ea},ef)),L(es,[ev],(0,i.Z)({isInitialMount:ek.current,previousResultCount:eE.current,items:ei,environment:eu,itemToString:ea},ef));var eR=(f=(d={menuElement:eI.current,highlightedIndex:ep,isOpen:eg,itemRefs:ey,scrollIntoView:eo,getItemNodeFromIndex:eO}).highlightedIndex,h=d.isOpen,g=d.itemRefs,p=d.getItemNodeFromIndex,x=d.menuElement,w=d.scrollIntoView,C=(0,c.useRef)(!0),(0,c.useEffect)(function(){!(f<0)&&h&&Object.keys(g.current).length&&(!1===C.current?C.current=!0:w(p(f),x))},[f]),C);F({isInitialMount:ek.current,props:et,state:ef}),(0,c.useEffect)(function(){ek.current&&(en||er||eg)&&eb.current&&eb.current.focus()},[eg]),(0,c.useEffect)(function(){ek.current||(eE.current=ei.length)});var eS=(E=eg,M=[ew,eI,ex],O=eu,R=function(){eh({type:7,selectItem:!1})},D=(0,c.useRef)({isMouseDown:!1,isTouchMove:!1}),(0,c.useEffect)(function(){var e=function(){D.current.isMouseDown=!0},t=function(e){D.current.isMouseDown=!1,E&&!k(e.target,M.map(function(e){return e.current}),O.document)&&R()},n=function(){D.current.isTouchMove=!1},r=function(){D.current.isTouchMove=!0},i=function(e){!E||D.current.isTouchMove||k(e.target,M.map(function(e){return e.current}),O.document,!1)||R()};return O.addEventListener("mousedown",e),O.addEventListener("mouseup",t),O.addEventListener("touchstart",n),O.addEventListener("touchmove",r),O.addEventListener("touchend",i),function(){O.removeEventListener("mousedown",e),O.removeEventListener("mouseup",t),O.removeEventListener("touchstart",n),O.removeEventListener("touchmove",r),O.removeEventListener("touchend",i)}},[E,O]),D),eD=Z("getInputProps","getComboboxProps","getMenuProps");(0,c.useEffect)(function(){ek.current=!1},[]);var eK=(0,c.useMemo)(function(){return{ArrowDown:function(e){e.preventDefault(),eh({type:0,shiftKey:e.shiftKey,getItemNodeFromIndex:eO})},ArrowUp:function(e){e.preventDefault(),eh({type:1,shiftKey:e.shiftKey,getItemNodeFromIndex:eO})},Home:function(e){e.preventDefault(),eh({type:3,getItemNodeFromIndex:eO})},End:function(e){e.preventDefault(),eh({type:4,getItemNodeFromIndex:eO})},Escape:function(){eh({type:2})},Enter:function(e){229!==e.which&&(eM.current.state.isOpen&&e.preventDefault(),eh({type:5,getItemNodeFromIndex:eO}))}}},[eh,eM]),eT=(0,c.useCallback)(function(e){return(0,i.Z)({id:eC.current.labelId,htmlFor:eC.current.inputId},e)},[]),eV=(0,c.useCallback)(function(e,t){var n,o=void 0===e?{}:e,u=o.onMouseLeave,c=o.refKey,s=void 0===c?"ref":c,a=o.ref,l=r(o,["onMouseLeave","refKey","ref"]),d=(void 0===t?{}:t).suppressRefError;return eD("getMenuProps",void 0!==d&&d,s,eI),(0,i.Z)(((n={})[s]=m(a,function(e){eI.current=e}),n.id=eC.current.menuId,n.role="listbox",n["aria-labelledby"]=eC.current.labelId,n.onMouseLeave=v(u,function(){eh({type:8})}),n),l)},[eh,eD]),eA=(0,c.useCallback)(function(e){var t,n,o=void 0===e?{}:e,u=o.item,c=o.index,s=o.refKey,a=o.ref,l=o.onMouseMove,d=o.onClick,f=(o.onPress,r(o,["item","index","refKey","ref","onMouseMove","onClick","onPress"])),h=eM.current,g=h.props,p=h.state,I=S(c,u,g.items);if(I<0)throw Error("Pass either item or item index in getItemProps!");return(0,i.Z)(((t={})[void 0===s?"ref":s]=m(a,function(e){e&&(ey.current[eC.current.getItemId(I)]=e)}),t.role="option",t["aria-selected"]=""+(I===p.highlightedIndex),t.id=eC.current.getItemId(I),t),!f.disabled&&((n={onMouseMove:v(l,function(){c!==p.highlightedIndex&&(eR.current=!1,eh({type:9,index:c}))})}).onClick=v(d,function(){eh({type:10,index:c}),eb.current&&eb.current.focus()}),n),f)},[eh,eM,eR]),eN=(0,c.useCallback)(function(e){var t,n=void 0===e?{}:e,o=n.onClick,u=(n.onPress,n.refKey),c=n.ref,s=r(n,["onClick","onPress","refKey","ref"]);return(0,i.Z)(((t={})[void 0===u?"ref":u]=m(c,function(e){ex.current=e}),t.id=eC.current.toggleButtonId,t.tabIndex=-1,t),!s.disabled&&(0,i.Z)({},{onClick:v(o,function(){eh({type:11}),!eM.current.state.isOpen&&eb.current&&eb.current.focus()})}),s)},[eh,eM]),eP=(0,c.useCallback)(function(e,t){var n,o,u=void 0===e?{}:e,c=u.onKeyDown,s=u.onChange,a=u.onInput,l=u.onBlur,d=(u.onChangeText,u.refKey),f=void 0===d?"ref":d,h=u.ref,g=r(u,["onKeyDown","onChange","onInput","onBlur","onChangeText","refKey","ref"]),p=(void 0===t?{}:t).suppressRefError;eD("getInputProps",void 0!==p&&p,f,eb);var I=eM.current.state,y={};return g.disabled||((o={}).onChange=v(s,a,function(e){eh({type:6,inputValue:e.target.value})}),o.onKeyDown=v(c,function(e){var t=b(e);t&&eK[t]&&eK[t](e)}),o.onBlur=v(l,function(){eS.current.isMouseDown||eh({type:7,selectItem:!0})}),y=o),(0,i.Z)(((n={})[f]=m(h,function(e){eb.current=e}),n.id=eC.current.inputId,n["aria-autocomplete"]="list",n["aria-controls"]=eC.current.menuId,n),I.isOpen&&I.highlightedIndex>-1&&{"aria-activedescendant":eC.current.getItemId(I.highlightedIndex)},{"aria-labelledby":eC.current.labelId,autoComplete:"off",value:I.inputValue},y,g)},[eh,eK,eM,eS,eD]),eZ=(0,c.useCallback)(function(e,t){var n,o=void 0===e?{}:e,u=o.refKey,c=void 0===u?"ref":u,s=o.ref,a=r(o,["refKey","ref"]),l=(void 0===t?{}:t).suppressRefError;return eD("getComboboxProps",void 0!==l&&l,c,ew),(0,i.Z)(((n={})[c]=m(s,function(e){ew.current=e}),n.role="combobox",n["aria-haspopup"]="listbox",n["aria-owns"]=eC.current.menuId,n["aria-expanded"]=eM.current.state.isOpen,n),a)},[eM,eD]),eL=(0,c.useCallback)(function(){eh({type:12})},[eh]),eF=(0,c.useCallback)(function(){eh({type:14})},[eh]),eB=(0,c.useCallback)(function(){eh({type:13})},[eh]),eH=(0,c.useCallback)(function(e){eh({type:15,highlightedIndex:e})},[eh]),eW=(0,c.useCallback)(function(e){eh({type:16,selectedItem:e})},[eh]);return{getItemProps:eA,getLabelProps:eT,getMenuProps:eV,getInputProps:eP,getComboboxProps:eZ,getToggleButtonProps:eN,toggleMenu:eL,openMenu:eB,closeMenu:eF,setHighlightedIndex:eH,setInputValue:(0,c.useCallback)(function(e){eh({type:17,inputValue:e})},[eh]),selectItem:eW,reset:(0,c.useCallback)(function(){eh({type:18})},[eh]),highlightedIndex:ep,isOpen:eg,selectedItem:ev,inputValue:em}}j.stateChangeTypes=H;var U={activeIndex:-1,selectedItems:[]};function X(e){if(e.shiftKey||e.metaKey||e.ctrlKey||e.altKey)return!1;var t=e.target;return!(t instanceof HTMLInputElement)||""===t.value||0===t.selectionStart&&0===t.selectionEnd}u().array,u().array,u().array,u().func,u().func,u().func,u().number,u().number,u().number,u().func,u().func,u().string,u().string,u().shape({addEventListener:u().func,removeEventListener:u().func,document:u().shape({getElementById:u().func,activeElement:u().any,body:u().any})});var Y={itemToString:V.itemToString,stateReducer:V.stateReducer,environment:V.environment,getA11yRemovalMessage:function(e){var t=e.removedSelectedItem;return(0,e.itemToString)(t)+" has been removed."},keyNavigationNext:"ArrowRight",keyNavigationPrevious:"ArrowLeft"},q=Object.freeze({__proto__:null,SelectedItemClick:0,SelectedItemKeyDownDelete:1,SelectedItemKeyDownBackspace:2,SelectedItemKeyDownNavigationNext:3,SelectedItemKeyDownNavigationPrevious:4,DropdownKeyDownNavigationPrevious:5,DropdownKeyDownBackspace:6,DropdownClick:7,FunctionAddSelectedItem:8,FunctionRemoveSelectedItem:9,FunctionSetSelectedItems:10,FunctionSetActiveIndex:11,FunctionReset:12});function z(e,t){var n,r=t.type,o=t.index,u=t.props,c=t.selectedItem,s=e.activeIndex,a=e.selectedItems;switch(r){case 0:n={activeIndex:o};break;case 4:n={activeIndex:s-1<0?0:s-1};break;case 3:n={activeIndex:s+1>=a.length?-1:s+1};break;case 2:case 1:var l=s;1===a.length?l=-1:s===a.length-1&&(l=a.length-2),n=(0,i.Z)({selectedItems:[].concat(a.slice(0,s),a.slice(s+1))},{activeIndex:l});break;case 5:n={activeIndex:a.length-1};break;case 6:n={selectedItems:a.slice(0,a.length-1)};break;case 8:n={selectedItems:[].concat(a,[c])};break;case 7:n={activeIndex:-1};break;case 9:var d=s,f=a.indexOf(c);1===a.length?d=-1:f===a.length-1&&(d=a.length-2),n=(0,i.Z)({selectedItems:[].concat(a.slice(0,f),a.slice(f+1))},{activeIndex:d});break;case 10:n={selectedItems:t.selectedItems};break;case 11:n={activeIndex:t.activeIndex};break;case 12:n={activeIndex:A(u,"activeIndex",U),selectedItems:A(u,"selectedItems",U)};break;default:throw Error("Reducer called without proper action type.")}return(0,i.Z)({},e,n)}function $(e){void 0===e&&(e={});var t,n,o,u,s,a,l=(0,i.Z)({},Y,e),d=l.getA11yRemovalMessage,f=l.itemToString,h=l.environment,g=l.keyNavigationNext,p=l.keyNavigationPrevious,I=(t=z,n={activeIndex:N(l,"activeIndex",U),selectedItems:N(l,"selectedItems",U)},s=(u=T(t,n,o=l))[0],a=u[1],[y(s,o),a]),x=I[0],w=I[1],k=x.activeIndex,C=x.selectedItems,M=(0,c.useRef)(!0),O=(0,c.useRef)(null),R=(0,c.useRef)(C),D=(0,c.useRef)();D.current=[];var V=K({state:x,props:l});(0,c.useEffect)(function(){if(!M.current){if(C.length<R.current.length){var e=R.current.find(function(e){return 0>C.indexOf(e)});E(d({itemToString:f,resultCount:C.length,removedSelectedItem:e,activeIndex:k,activeSelectedItem:C[k]}),h.document)}R.current=C}},[C.length]),(0,c.useEffect)(function(){!M.current&&(-1===k&&O.current?O.current.focus():D.current[k]&&D.current[k].focus())},[k]),F({isInitialMount:M.current,props:l,state:x});var A=Z("getDropdownProps");(0,c.useEffect)(function(){M.current=!1},[]);var P=(0,c.useMemo)(function(){var e;return(e={})[p]=function(){w({type:4})},e[g]=function(){w({type:3})},e.Delete=function(){w({type:1})},e.Backspace=function(){w({type:2})},e},[w,g,p]),L=(0,c.useMemo)(function(){var e;return(e={})[p]=function(e){X(e)&&w({type:5})},e.Backspace=function(e){X(e)&&w({type:6})},e},[w,p]);return{getSelectedItemProps:(0,c.useCallback)(function(e){var t,n=void 0===e?{}:e,o=n.refKey,u=n.ref,c=n.onClick,s=n.onKeyDown,a=n.selectedItem,l=n.index,d=r(n,["refKey","ref","onClick","onKeyDown","selectedItem","index"]),f=V.current.state;if(0>S(l,a,f.selectedItems))throw Error("Pass either selectedItem or index in getSelectedItemProps!");return(0,i.Z)(((t={})[void 0===o?"ref":o]=m(u,function(e){e&&D.current.push(e)}),t.tabIndex=l===f.activeIndex?0:-1,t.onClick=v(c,function(){w({type:0,index:l})}),t.onKeyDown=v(s,function(e){var t=b(e);t&&P[t]&&P[t](e)}),t),d)},[w,V,P]),getDropdownProps:(0,c.useCallback)(function(e,t){var n,o=void 0===e?{}:e,u=o.refKey,c=void 0===u?"ref":u,s=o.ref,a=o.onKeyDown,l=o.onClick,d=o.preventKeyAction,f=r(o,["refKey","ref","onKeyDown","onClick","preventKeyAction"]),h=(void 0===t?{}:t).suppressRefError;return A("getDropdownProps",void 0!==h&&h,c,O),(0,i.Z)(((n={})[c]=m(s,function(e){e&&(O.current=e)}),n),!(void 0!==d&&d)&&{onKeyDown:v(a,function(e){var t=b(e);t&&L[t]&&L[t](e)}),onClick:v(l,function(){w({type:7})})},f)},[w,L,A]),addSelectedItem:(0,c.useCallback)(function(e){w({type:8,selectedItem:e})},[w]),removeSelectedItem:(0,c.useCallback)(function(e){w({type:9,selectedItem:e})},[w]),setSelectedItems:(0,c.useCallback)(function(e){w({type:10,selectedItems:e})},[w]),setActiveIndex:(0,c.useCallback)(function(e){w({type:11,activeIndex:e})},[w]),reset:(0,c.useCallback)(function(){w({type:12})},[w]),selectedItems:C,activeIndex:k}}$.stateChangeTypes=q},29860:function(e,t,n){var r=n(88873),i=n(54987),o=n(97172),u=Math.max,c=Math.min;e.exports=function(e,t,n){var s,a,l,d,f,h,g=0,p=!1,v=!1,m=!0;if("function"!=typeof e)throw TypeError("Expected a function");function I(t){var n=s,r=a;return s=a=void 0,g=t,d=e.apply(r,n)}function y(e){var n=e-h,r=e-g;return void 0===h||n>=t||n<0||v&&r>=l}function b(){var e,n,r,o=i();if(y(o))return x(o);f=setTimeout(b,(e=o-h,n=o-g,r=t-e,v?c(r,l-n):r))}function x(e){return(f=void 0,m&&s)?I(e):(s=a=void 0,d)}function w(){var e,n=i(),r=y(n);if(s=arguments,a=this,h=n,r){if(void 0===f)return g=e=h,f=setTimeout(b,t),p?I(e):d;if(v)return clearTimeout(f),f=setTimeout(b,t),I(h)}return void 0===f&&(f=setTimeout(b,t)),d}return t=o(t)||0,r(n)&&(p=!!n.leading,l=(v="maxWait"in n)?u(o(n.maxWait)||0,t):l,m="trailing"in n?!!n.trailing:m),w.cancel=function(){void 0!==f&&clearTimeout(f),g=0,s=h=a=f=void 0},w.flush=function(){return void 0===f?d:x(i())},w}},54987:function(e,t,n){var r=n(3642);e.exports=function(){return r.Date.now()}}}]);
//# sourceMappingURL=9770-7034ec4b9ad8b82f.js.map