From bb6cd159f1fc0cafc6b16ded2670f399920c9e11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mose=20M=C3=BCller?= Date: Tue, 17 Sep 2024 16:48:40 +0200 Subject: [PATCH 1/2] frontend: refactoring minus sign handling in NumberComponent --- frontend/src/components/NumberComponent.tsx | 38 ++++++++++++++------- 1 file changed, 25 insertions(+), 13 deletions(-) diff --git a/frontend/src/components/NumberComponent.tsx b/frontend/src/components/NumberComponent.tsx index dfae382..2a64206 100644 --- a/frontend/src/components/NumberComponent.tsx +++ b/frontend/src/components/NumberComponent.tsx @@ -132,6 +132,8 @@ const handleNumericKey = ( selectionStart: number, selectionEnd: number, ) => { + let newValue = value; + // Check if a number key or a decimal point key is pressed if (key === "." && value.includes(".")) { // Check if value already contains a decimal. If so, ignore input. @@ -139,14 +141,34 @@ const handleNumericKey = ( return { value, selectionStart }; } - let newValue = value; + // Handle minus sign input + if (key === "-") { + if (selectionStart === 0 && selectionEnd > selectionStart) { + // Replace selection with minus if selection starts at 0 + newValue = "-" + value.slice(selectionEnd); + selectionStart = 1; + } else if (selectionStart === 0 && !value.startsWith("-")) { + // Add minus at the beginning if it doesn't exist + newValue = "-" + value; + selectionStart = 1; + } else if ( + (selectionStart === 0 || selectionStart === 1) && + value.startsWith("-") + ) { + // Remove minus if it exists + newValue = value.slice(1); + selectionStart = 0; + } + + return { value: newValue, selectionStart }; + } // Add the new key at the cursor's position if (selectionEnd > selectionStart) { // If there is a selection, replace it with the key newValue = value.slice(0, selectionStart) + key + value.slice(selectionEnd); } else { - // otherwise, append the key after the selection start + // Otherwise, insert the key at the cursor position newValue = value.slice(0, selectionStart) + key + value.slice(selectionStart); } @@ -201,17 +223,7 @@ export const NumberComponent = React.memo((props: NumberComponentProps) => { // Select everything when pressing Ctrl + a inputTarget.setSelectionRange(0, value.length); return; - } else if (key === "-") { - if (selectionStart === 0 && !value.startsWith("-")) { - newValue = "-" + value; - selectionStart++; - } else if (value.startsWith("-") && selectionStart === 1) { - newValue = value.substring(1); // remove minus sign - selectionStart--; - } else { - return; // Ignore "-" pressed in other positions - } - } else if (key >= "0" && key <= "9") { + } else if ((key >= "0" && key <= "9") || key === "-") { // Check if a number key or a decimal point key is pressed ({ value: newValue, selectionStart } = handleNumericKey( key, From e74b5c773a72f8a71b27ec9566a2a0123cce4b31 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mose=20M=C3=BCller?= Date: Tue, 17 Sep 2024 16:51:00 +0200 Subject: [PATCH 2/2] npm run build --- .../frontend/assets/{index-DI9re3au.js => index-BjsjosWf.js} | 2 +- src/pydase/frontend/index.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) rename src/pydase/frontend/assets/{index-DI9re3au.js => index-BjsjosWf.js} (95%) diff --git a/src/pydase/frontend/assets/index-DI9re3au.js b/src/pydase/frontend/assets/index-BjsjosWf.js similarity index 95% rename from src/pydase/frontend/assets/index-DI9re3au.js rename to src/pydase/frontend/assets/index-BjsjosWf.js index daf0cd7..5757e78 100644 --- a/src/pydase/frontend/assets/index-DI9re3au.js +++ b/src/pydase/frontend/assets/index-BjsjosWf.js @@ -41,7 +41,7 @@ function wk(e,t){for(var n=0;n")&&(l=l.replace("",e.displayName)),l}while(1<=s&&0<=a);break}}}finally{Ec=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Li(e):""}function db(e){switch(e.tag){case 5:return Li(e.type);case 16:return Li("Lazy");case 13:return Li("Suspense");case 19:return Li("SuspenseList");case 0:case 2:case 15:return e=kc(e.type,!1),e;case 11:return e=kc(e.type.render,!1),e;case 1:return e=kc(e.type,!0),e;default:return""}}function Nf(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case xo:return"Fragment";case So:return"Portal";case _f:return"Profiler";case Ep:return"StrictMode";case Tf:return"Suspense";case Rf:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case L0:return(e.displayName||"Context")+".Consumer";case j0:return(e._context.displayName||"Context")+".Provider";case kp:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case bp:return t=e.displayName||null,t!==null?t:Nf(e.type)||"Memo";case nr:t=e._payload,e=e._init;try{return Nf(e(t))}catch{}}return null}function pb(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Nf(t);case 8:return t===Ep?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function xr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function M0(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function hb(e){var t=M0(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var o=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(s){r=""+s,i.call(this,s)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(s){r=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function ta(e){e._valueTracker||(e._valueTracker=hb(e))}function B0(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=M0(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function fl(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Af(e,t){var n=t.checked;return be({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Pm(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=xr(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function D0(e,t){t=t.checked,t!=null&&xp(e,"checked",t,!1)}function Pf(e,t){D0(e,t);var n=xr(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?jf(e,t.type,n):t.hasOwnProperty("defaultValue")&&jf(e,t.type,xr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function jm(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function jf(e,t,n){(t!=="number"||fl(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Ii=Array.isArray;function Po(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o"+t.valueOf().toString()+"",t=na.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function us(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Hi={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},mb=["Webkit","ms","Moz","O"];Object.keys(Hi).forEach(function(e){mb.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Hi[t]=Hi[e]})});function W0(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Hi.hasOwnProperty(e)&&Hi[e]?(""+t).trim():t+"px"}function H0(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,o=W0(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,o):e[n]=o}}var yb=be({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Mf(e,t){if(t){if(yb[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(R(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(R(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(R(61))}if(t.style!=null&&typeof t.style!="object")throw Error(R(62))}}function Bf(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Df=null;function Cp(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Ff=null,jo=null,Lo=null;function Mm(e){if(e=Ds(e)){if(typeof Ff!="function")throw Error(R(280));var t=e.stateNode;t&&(t=du(t),Ff(e.stateNode,e.type,t))}}function V0(e){jo?Lo?Lo.push(e):Lo=[e]:jo=e}function K0(){if(jo){var e=jo,t=Lo;if(Lo=jo=null,Mm(e),t)for(e=0;e>>=0,e===0?32:31-($b(e)/_b|0)|0}var ra=64,oa=4194304;function Mi(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function ml(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,o=e.suspendedLanes,i=e.pingedLanes,s=n&268435455;if(s!==0){var a=s&~o;a!==0?r=Mi(a):(i&=s,i!==0&&(r=Mi(i)))}else s=n&~o,s!==0?r=Mi(s):i!==0&&(r=Mi(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&o)&&(o=r&-r,i=t&-t,o>=i||o===16&&(i&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function Ms(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-nn(t),e[t]=n}function Ab(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=Ki),Km=" ",Gm=!1;function d1(e,t){switch(e){case"keyup":return sC.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function p1(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Eo=!1;function lC(e,t){switch(e){case"compositionend":return p1(t);case"keypress":return t.which!==32?null:(Gm=!0,Km);case"textInput":return e=t.data,e===Km&&Gm?null:e;default:return null}}function uC(e,t){if(Eo)return e==="compositionend"||!Pp&&d1(e,t)?(e=c1(),ja=Rp=ur=null,Eo=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Xm(n)}}function v1(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?v1(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function g1(){for(var e=window,t=fl();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=fl(e.document)}return t}function jp(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function gC(e){var t=g1(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&v1(n.ownerDocument.documentElement,n)){if(r!==null&&jp(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var o=n.textContent.length,i=Math.min(r.start,o);r=r.end===void 0?i:Math.min(r.end,o),!e.extend&&i>r&&(o=r,r=i,i=o),o=Jm(n,i);var s=Jm(n,r);o&&s&&(e.rangeCount!==1||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==s.node||e.focusOffset!==s.offset)&&(t=t.createRange(),t.setStart(o.node,o.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(s.node,s.offset)):(t.setEnd(s.node,s.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,ko=null,Kf=null,qi=null,Gf=!1;function Zm(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Gf||ko==null||ko!==fl(r)||(r=ko,"selectionStart"in r&&jp(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),qi&&ms(qi,r)||(qi=r,r=gl(Kf,"onSelect"),0Oo||(e.current=Zf[Oo],Zf[Oo]=null,Oo--)}function he(e,t){Oo++,Zf[Oo]=e.current,e.current=t}var Er={},et=Cr(Er),ft=Cr(!1),Ur=Er;function Ho(e,t){var n=e.type.contextTypes;if(!n)return Er;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o={},i;for(i in n)o[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function dt(e){return e=e.childContextTypes,e!=null}function Sl(){ye(ft),ye(et)}function sy(e,t,n){if(et.current!==Er)throw Error(R(168));he(et,t),he(ft,n)}function $1(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var o in r)if(!(o in t))throw Error(R(108,pb(e)||"Unknown",o));return be({},n,r)}function xl(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Er,Ur=et.current,he(et,e),he(ft,ft.current),!0}function ay(e,t,n){var r=e.stateNode;if(!r)throw Error(R(169));n?(e=$1(e,t,Ur),r.__reactInternalMemoizedMergedChildContext=e,ye(ft),ye(et),he(et,e)):ye(ft),he(ft,n)}var jn=null,pu=!1,Mc=!1;function _1(e){jn===null?jn=[e]:jn.push(e)}function RC(e){pu=!0,_1(e)}function Or(){if(!Mc&&jn!==null){Mc=!0;var e=0,t=ue;try{var n=jn;for(ue=1;e>=s,o-=s,Mn=1<<32-nn(t)+o|n<O?(T=b,b=null):T=b.sibling;var $=f(m,b,y[O],E);if($===null){b===null&&(b=T);break}e&&b&&$.alternate===null&&t(m,b),p=i($,p,O),x===null?C=$:x.sibling=$,x=$,b=T}if(O===y.length)return n(m,b),xe&&Nr(m,O),C;if(b===null){for(;OO?(T=b,b=null):T=b.sibling;var A=f(m,b,$.value,E);if(A===null){b===null&&(b=T);break}e&&b&&A.alternate===null&&t(m,b),p=i(A,p,O),x===null?C=A:x.sibling=A,x=A,b=T}if($.done)return n(m,b),xe&&Nr(m,O),C;if(b===null){for(;!$.done;O++,$=y.next())$=d(m,$.value,E),$!==null&&(p=i($,p,O),x===null?C=$:x.sibling=$,x=$);return xe&&Nr(m,O),C}for(b=r(m,b);!$.done;O++,$=y.next())$=v(b,m,O,$.value,E),$!==null&&(e&&$.alternate!==null&&b.delete($.key===null?O:$.key),p=i($,p,O),x===null?C=$:x.sibling=$,x=$);return e&&b.forEach(function(U){return t(m,U)}),xe&&Nr(m,O),C}function k(m,p,y,E){if(typeof y=="object"&&y!==null&&y.type===xo&&y.key===null&&(y=y.props.children),typeof y=="object"&&y!==null){switch(y.$$typeof){case ea:e:{for(var C=y.key,x=p;x!==null;){if(x.key===C){if(C=y.type,C===xo){if(x.tag===7){n(m,x.sibling),p=o(x,y.props.children),p.return=m,m=p;break e}}else if(x.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===nr&&cy(C)===x.type){n(m,x.sibling),p=o(x,y.props),p.ref=bi(m,x,y),p.return=m,m=p;break e}n(m,x);break}else t(m,x);x=x.sibling}y.type===xo?(p=Br(y.props.children,m.mode,E,y.key),p.return=m,m=p):(E=Ua(y.type,y.key,y.props,null,m.mode,E),E.ref=bi(m,p,y),E.return=m,m=E)}return s(m);case So:e:{for(x=y.key;p!==null;){if(p.key===x)if(p.tag===4&&p.stateNode.containerInfo===y.containerInfo&&p.stateNode.implementation===y.implementation){n(m,p.sibling),p=o(p,y.children||[]),p.return=m,m=p;break e}else{n(m,p);break}else t(m,p);p=p.sibling}p=Vc(y,m.mode,E),p.return=m,m=p}return s(m);case nr:return x=y._init,k(m,p,x(y._payload),E)}if(Ii(y))return g(m,p,y,E);if(wi(y))return S(m,p,y,E);fa(m,y)}return typeof y=="string"&&y!==""||typeof y=="number"?(y=""+y,p!==null&&p.tag===6?(n(m,p.sibling),p=o(p,y),p.return=m,m=p):(n(m,p),p=Hc(y,m.mode,E),p.return=m,m=p),s(m)):n(m,p)}return k}var Ko=A1(!0),P1=A1(!1),bl=Cr(null),Cl=null,To=null,Bp=null;function Dp(){Bp=To=Cl=null}function Fp(e){var t=bl.current;ye(bl),e._currentValue=t}function nd(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Mo(e,t){Cl=e,Bp=To=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(ct=!0),e.firstContext=null)}function Dt(e){var t=e._currentValue;if(Bp!==e)if(e={context:e,memoizedValue:t,next:null},To===null){if(Cl===null)throw Error(R(308));To=e,Cl.dependencies={lanes:0,firstContext:e}}else To=To.next=e;return t}var jr=null;function zp(e){jr===null?jr=[e]:jr.push(e)}function j1(e,t,n,r){var o=t.interleaved;return o===null?(n.next=n,zp(t)):(n.next=o.next,o.next=n),t.interleaved=n,Vn(e,r)}function Vn(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var rr=!1;function Up(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function L1(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function zn(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function yr(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,te&2){var o=r.pending;return o===null?t.next=t:(t.next=o.next,o.next=t),r.pending=t,Vn(e,n)}return o=r.interleaved,o===null?(t.next=t,zp(r)):(t.next=o.next,o.next=t),r.interleaved=t,Vn(e,n)}function Ia(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,$p(e,n)}}function fy(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var o=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var s={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};i===null?o=i=s:i=i.next=s,n=n.next}while(n!==null);i===null?o=i=t:i=i.next=t}else o=i=t;n={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:i,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Ol(e,t,n,r){var o=e.updateQueue;rr=!1;var i=o.firstBaseUpdate,s=o.lastBaseUpdate,a=o.shared.pending;if(a!==null){o.shared.pending=null;var l=a,u=l.next;l.next=null,s===null?i=u:s.next=u,s=l;var c=e.alternate;c!==null&&(c=c.updateQueue,a=c.lastBaseUpdate,a!==s&&(a===null?c.firstBaseUpdate=u:a.next=u,c.lastBaseUpdate=l))}if(i!==null){var d=o.baseState;s=0,c=u=l=null,a=i;do{var f=a.lane,v=a.eventTime;if((r&f)===f){c!==null&&(c=c.next={eventTime:v,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var g=e,S=a;switch(f=t,v=n,S.tag){case 1:if(g=S.payload,typeof g=="function"){d=g.call(v,d,f);break e}d=g;break e;case 3:g.flags=g.flags&-65537|128;case 0:if(g=S.payload,f=typeof g=="function"?g.call(v,d,f):g,f==null)break e;d=be({},d,f);break e;case 2:rr=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,f=o.effects,f===null?o.effects=[a]:f.push(a))}else v={eventTime:v,lane:f,tag:a.tag,payload:a.payload,callback:a.callback,next:null},c===null?(u=c=v,l=d):c=c.next=v,s|=f;if(a=a.next,a===null){if(a=o.shared.pending,a===null)break;f=a,a=f.next,f.next=null,o.lastBaseUpdate=f,o.shared.pending=null}}while(!0);if(c===null&&(l=d),o.baseState=l,o.firstBaseUpdate=u,o.lastBaseUpdate=c,t=o.shared.interleaved,t!==null){o=t;do s|=o.lane,o=o.next;while(o!==t)}else i===null&&(o.shared.lanes=0);Vr|=s,e.lanes=s,e.memoizedState=d}}function dy(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=Dc.transition;Dc.transition={};try{e(!1),t()}finally{ue=n,Dc.transition=r}}function J1(){return Ft().memoizedState}function jC(e,t,n){var r=gr(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Z1(e))ew(t,n);else if(n=j1(e,t,n,r),n!==null){var o=st();rn(n,e,r,o),tw(n,t,r)}}function LC(e,t,n){var r=gr(e),o={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Z1(e))ew(t,o);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var s=t.lastRenderedState,a=i(s,n);if(o.hasEagerState=!0,o.eagerState=a,sn(a,s)){var l=t.interleaved;l===null?(o.next=o,zp(t)):(o.next=l.next,l.next=o),t.interleaved=o;return}}catch{}finally{}n=j1(e,t,o,r),n!==null&&(o=st(),rn(n,e,r,o),tw(n,t,r))}}function Z1(e){var t=e.alternate;return e===ke||t!==null&&t===ke}function ew(e,t){Qi=_l=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function tw(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,$p(e,n)}}var Tl={readContext:Dt,useCallback:Ye,useContext:Ye,useEffect:Ye,useImperativeHandle:Ye,useInsertionEffect:Ye,useLayoutEffect:Ye,useMemo:Ye,useReducer:Ye,useRef:Ye,useState:Ye,useDebugValue:Ye,useDeferredValue:Ye,useTransition:Ye,useMutableSource:Ye,useSyncExternalStore:Ye,useId:Ye,unstable_isNewReconciler:!1},IC={readContext:Dt,useCallback:function(e,t){return fn().memoizedState=[e,t===void 0?null:t],e},useContext:Dt,useEffect:hy,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Ba(4194308,4,G1.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Ba(4194308,4,e,t)},useInsertionEffect:function(e,t){return Ba(4,2,e,t)},useMemo:function(e,t){var n=fn();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=fn();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=jC.bind(null,ke,e),[r.memoizedState,e]},useRef:function(e){var t=fn();return e={current:e},t.memoizedState=e},useState:py,useDebugValue:Yp,useDeferredValue:function(e){return fn().memoizedState=e},useTransition:function(){var e=py(!1),t=e[0];return e=PC.bind(null,e[1]),fn().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=ke,o=fn();if(xe){if(n===void 0)throw Error(R(407));n=n()}else{if(n=t(),Fe===null)throw Error(R(349));Hr&30||D1(r,t,n)}o.memoizedState=n;var i={value:n,getSnapshot:t};return o.queue=i,hy(z1.bind(null,r,i,e),[e]),r.flags|=2048,ks(9,F1.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=fn(),t=Fe.identifierPrefix;if(xe){var n=Bn,r=Mn;n=(r&~(1<<32-nn(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=xs++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=s.createElement(n,{is:r.is}):(e=s.createElement(n),n==="select"&&(s=e,r.multiple?s.multiple=!0:r.size&&(s.size=r.size))):e=s.createElementNS(e,n),e[yn]=t,e[gs]=r,fw(e,t,!1,!1),t.stateNode=e;e:{switch(s=Bf(n,r),n){case"dialog":me("cancel",e),me("close",e),o=r;break;case"iframe":case"object":case"embed":me("load",e),o=r;break;case"video":case"audio":for(o=0;oQo&&(t.flags|=128,r=!0,Ci(i,!1),t.lanes=4194304)}else{if(!r)if(e=$l(s),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Ci(i,!0),i.tail===null&&i.tailMode==="hidden"&&!s.alternate&&!xe)return Xe(t),null}else 2*_e()-i.renderingStartTime>Qo&&n!==1073741824&&(t.flags|=128,r=!0,Ci(i,!1),t.lanes=4194304);i.isBackwards?(s.sibling=t.child,t.child=s):(n=i.last,n!==null?n.sibling=s:t.child=s,i.last=s)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=_e(),t.sibling=null,n=Ee.current,he(Ee,r?n&1|2:n&1),t):(Xe(t),null);case 22:case 23:return nh(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?gt&1073741824&&(Xe(t),t.subtreeFlags&6&&(t.flags|=8192)):Xe(t),null;case 24:return null;case 25:return null}throw Error(R(156,t.tag))}function HC(e,t){switch(Ip(t),t.tag){case 1:return dt(t.type)&&Sl(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Go(),ye(ft),ye(et),Vp(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Hp(t),null;case 13:if(ye(Ee),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(R(340));Vo()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ye(Ee),null;case 4:return Go(),null;case 10:return Fp(t.type._context),null;case 22:case 23:return nh(),null;case 24:return null;default:return null}}var pa=!1,Ze=!1,VC=typeof WeakSet=="function"?WeakSet:Set,L=null;function Ro(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){$e(e,t,r)}else n.current=null}function fd(e,t,n){try{n()}catch(r){$e(e,t,r)}}var Cy=!1;function KC(e,t){if(qf=yl,e=g1(),jp(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var o=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var s=0,a=-1,l=-1,u=0,c=0,d=e,f=null;t:for(;;){for(var v;d!==n||o!==0&&d.nodeType!==3||(a=s+o),d!==i||r!==0&&d.nodeType!==3||(l=s+r),d.nodeType===3&&(s+=d.nodeValue.length),(v=d.firstChild)!==null;)f=d,d=v;for(;;){if(d===e)break t;if(f===n&&++u===o&&(a=s),f===i&&++c===r&&(l=s),(v=d.nextSibling)!==null)break;d=f,f=d.parentNode}d=v}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Qf={focusedElem:e,selectionRange:n},yl=!1,L=t;L!==null;)if(t=L,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,L=e;else for(;L!==null;){t=L;try{var g=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(g!==null){var S=g.memoizedProps,k=g.memoizedState,m=t.stateNode,p=m.getSnapshotBeforeUpdate(t.elementType===t.type?S:Xt(t.type,S),k);m.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var y=t.stateNode.containerInfo;y.nodeType===1?y.textContent="":y.nodeType===9&&y.documentElement&&y.removeChild(y.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(R(163))}}catch(E){$e(t,t.return,E)}if(e=t.sibling,e!==null){e.return=t.return,L=e;break}L=t.return}return g=Cy,Cy=!1,g}function Yi(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var o=r=r.next;do{if((o.tag&e)===e){var i=o.destroy;o.destroy=void 0,i!==void 0&&fd(t,n,i)}o=o.next}while(o!==r)}}function yu(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function dd(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function hw(e){var t=e.alternate;t!==null&&(e.alternate=null,hw(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[yn],delete t[gs],delete t[Jf],delete t[_C],delete t[TC])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function mw(e){return e.tag===5||e.tag===3||e.tag===4}function Oy(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||mw(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function pd(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=wl));else if(r!==4&&(e=e.child,e!==null))for(pd(e,t,n),e=e.sibling;e!==null;)pd(e,t,n),e=e.sibling}function hd(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(hd(e,t,n),e=e.sibling;e!==null;)hd(e,t,n),e=e.sibling}var He=null,Jt=!1;function er(e,t,n){for(n=n.child;n!==null;)yw(e,t,n),n=n.sibling}function yw(e,t,n){if(vn&&typeof vn.onCommitFiberUnmount=="function")try{vn.onCommitFiberUnmount(lu,n)}catch{}switch(n.tag){case 5:Ze||Ro(n,t);case 6:var r=He,o=Jt;He=null,er(e,t,n),He=r,Jt=o,He!==null&&(Jt?(e=He,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):He.removeChild(n.stateNode));break;case 18:He!==null&&(Jt?(e=He,n=n.stateNode,e.nodeType===8?Ic(e.parentNode,n):e.nodeType===1&&Ic(e,n),ps(e)):Ic(He,n.stateNode));break;case 4:r=He,o=Jt,He=n.stateNode.containerInfo,Jt=!0,er(e,t,n),He=r,Jt=o;break;case 0:case 11:case 14:case 15:if(!Ze&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){o=r=r.next;do{var i=o,s=i.destroy;i=i.tag,s!==void 0&&(i&2||i&4)&&fd(n,t,s),o=o.next}while(o!==r)}er(e,t,n);break;case 1:if(!Ze&&(Ro(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){$e(n,t,a)}er(e,t,n);break;case 21:er(e,t,n);break;case 22:n.mode&1?(Ze=(r=Ze)||n.memoizedState!==null,er(e,t,n),Ze=r):er(e,t,n);break;default:er(e,t,n)}}function $y(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new VC),t.forEach(function(r){var o=tO.bind(null,e,r);n.has(r)||(n.add(r),r.then(o,o))})}}function Qt(e,t){var n=t.deletions;if(n!==null)for(var r=0;ro&&(o=s),r&=~i}if(r=o,r=_e()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*qC(r/1960))-r,10e?16:e,cr===null)var r=!1;else{if(e=cr,cr=null,Al=0,te&6)throw Error(R(331));var o=te;for(te|=4,L=e.current;L!==null;){var i=L,s=i.child;if(L.flags&16){var a=i.deletions;if(a!==null){for(var l=0;l_e()-eh?Mr(e,0):Zp|=n),pt(e,t)}function bw(e,t){t===0&&(e.mode&1?(t=oa,oa<<=1,!(oa&130023424)&&(oa=4194304)):t=1);var n=st();e=Vn(e,t),e!==null&&(Ms(e,t,n),pt(e,n))}function eO(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),bw(e,n)}function tO(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,o=e.memoizedState;o!==null&&(n=o.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(R(314))}r!==null&&r.delete(t),bw(e,n)}var Cw;Cw=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||ft.current)ct=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return ct=!1,UC(e,t,n);ct=!!(e.flags&131072)}else ct=!1,xe&&t.flags&1048576&&T1(t,kl,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Da(e,t),e=t.pendingProps;var o=Ho(t,et.current);Mo(t,n),o=Gp(null,t,r,e,o,n);var i=qp();return t.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,dt(r)?(i=!0,xl(t)):i=!1,t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,Up(t),o.updater=mu,t.stateNode=o,o._reactInternals=t,od(t,r,e,n),t=ad(null,t,r,!0,i,n)):(t.tag=0,xe&&i&&Lp(t),rt(null,t,o,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Da(e,t),e=t.pendingProps,o=r._init,r=o(r._payload),t.type=r,o=t.tag=rO(r),e=Xt(r,e),o){case 0:t=sd(null,t,r,e,n);break e;case 1:t=Ey(null,t,r,e,n);break e;case 11:t=Sy(null,t,r,e,n);break e;case 14:t=xy(null,t,r,Xt(r.type,e),n);break e}throw Error(R(306,r,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Xt(r,o),sd(e,t,r,o,n);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Xt(r,o),Ey(e,t,r,o,n);case 3:e:{if(lw(t),e===null)throw Error(R(387));r=t.pendingProps,i=t.memoizedState,o=i.element,L1(e,t),Ol(t,r,null,n);var s=t.memoizedState;if(r=s.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){o=qo(Error(R(423)),t),t=ky(e,t,r,n,o);break e}else if(r!==o){o=qo(Error(R(424)),t),t=ky(e,t,r,n,o);break e}else for(St=mr(t.stateNode.containerInfo.firstChild),xt=t,xe=!0,en=null,n=P1(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Vo(),r===o){t=Kn(e,t,n);break e}rt(e,t,r,n)}t=t.child}return t;case 5:return I1(t),e===null&&td(t),r=t.type,o=t.pendingProps,i=e!==null?e.memoizedProps:null,s=o.children,Yf(r,o)?s=null:i!==null&&Yf(r,i)&&(t.flags|=32),aw(e,t),rt(e,t,s,n),t.child;case 6:return e===null&&td(t),null;case 13:return uw(e,t,n);case 4:return Wp(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ko(t,null,r,n):rt(e,t,r,n),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Xt(r,o),Sy(e,t,r,o,n);case 7:return rt(e,t,t.pendingProps,n),t.child;case 8:return rt(e,t,t.pendingProps.children,n),t.child;case 12:return rt(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,o=t.pendingProps,i=t.memoizedProps,s=o.value,he(bl,r._currentValue),r._currentValue=s,i!==null)if(sn(i.value,s)){if(i.children===o.children&&!ft.current){t=Kn(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){s=i.child;for(var l=a.firstContext;l!==null;){if(l.context===r){if(i.tag===1){l=zn(-1,n&-n),l.tag=2;var u=i.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}i.lanes|=n,l=i.alternate,l!==null&&(l.lanes|=n),nd(i.return,n,t),a.lanes|=n;break}l=l.next}}else if(i.tag===10)s=i.type===t.type?null:i.child;else if(i.tag===18){if(s=i.return,s===null)throw Error(R(341));s.lanes|=n,a=s.alternate,a!==null&&(a.lanes|=n),nd(s,n,t),s=i.sibling}else s=i.child;if(s!==null)s.return=i;else for(s=i;s!==null;){if(s===t){s=null;break}if(i=s.sibling,i!==null){i.return=s.return,s=i;break}s=s.return}i=s}rt(e,t,o.children,n),t=t.child}return t;case 9:return o=t.type,r=t.pendingProps.children,Mo(t,n),o=Dt(o),r=r(o),t.flags|=1,rt(e,t,r,n),t.child;case 14:return r=t.type,o=Xt(r,t.pendingProps),o=Xt(r.type,o),xy(e,t,r,o,n);case 15:return iw(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Xt(r,o),Da(e,t),t.tag=1,dt(r)?(e=!0,xl(t)):e=!1,Mo(t,n),nw(t,r,o),od(t,r,o,n),ad(null,t,r,!0,e,n);case 19:return cw(e,t,n);case 22:return sw(e,t,n)}throw Error(R(156,t.tag))};function Ow(e,t){return Z0(e,t)}function nO(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function It(e,t,n,r){return new nO(e,t,n,r)}function oh(e){return e=e.prototype,!(!e||!e.isReactComponent)}function rO(e){if(typeof e=="function")return oh(e)?1:0;if(e!=null){if(e=e.$$typeof,e===kp)return 11;if(e===bp)return 14}return 2}function wr(e,t){var n=e.alternate;return n===null?(n=It(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Ua(e,t,n,r,o,i){var s=2;if(r=e,typeof e=="function")oh(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case xo:return Br(n.children,o,i,t);case Ep:s=8,o|=8;break;case _f:return e=It(12,n,t,o|2),e.elementType=_f,e.lanes=i,e;case Tf:return e=It(13,n,t,o),e.elementType=Tf,e.lanes=i,e;case Rf:return e=It(19,n,t,o),e.elementType=Rf,e.lanes=i,e;case I0:return gu(n,o,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case j0:s=10;break e;case L0:s=9;break e;case kp:s=11;break e;case bp:s=14;break e;case nr:s=16,r=null;break e}throw Error(R(130,e==null?e:typeof e,""))}return t=It(s,n,t,o),t.elementType=e,t.type=r,t.lanes=i,t}function Br(e,t,n,r){return e=It(7,e,r,t),e.lanes=n,e}function gu(e,t,n,r){return e=It(22,e,r,t),e.elementType=I0,e.lanes=n,e.stateNode={isHidden:!1},e}function Hc(e,t,n){return e=It(6,e,null,t),e.lanes=n,e}function Vc(e,t,n){return t=It(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function oO(e,t,n,r,o){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Cc(0),this.expirationTimes=Cc(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Cc(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function ih(e,t,n,r,o,i,s,a,l){return e=new oO(e,t,n,a,l),t===1?(t=1,i===!0&&(t|=8)):t=0,i=It(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Up(i),e}function iO(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Rw)}catch{}}Rw(),R0.exports=Ct;var Nw=R0.exports;const Ir=si(Nw),Ly={disabled:!1},Aw=ne.createContext(null);var cO=function(t){return t.scrollTop},Di="unmounted",or="exited",Pt="entering",In="entered",Yo="exiting",Jn=function(e){Vk(t,e);function t(r,o){var i;i=e.call(this,r,o)||this;var s=o,a=s&&!s.isMounting?r.enter:r.appear,l;return i.appearStatus=null,r.in?a?(l=or,i.appearStatus=Pt):l=In:r.unmountOnExit||r.mountOnEnter?l=Di:l=or,i.state={status:l},i.nextCallback=null,i}t.getDerivedStateFromProps=function(o,i){var s=o.in;return s&&i.status===Di?{status:or}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var i=null;if(o!==this.props){var s=this.state.status;this.props.in?s!==Pt&&s!==In&&(i=Pt):(s===Pt||s===In)&&(i=Yo)}this.updateStatus(!1,i)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,i,s,a;return i=s=a=o,o!=null&&typeof o!="number"&&(i=o.exit,s=o.enter,a=o.appear!==void 0?o.appear:s),{exit:i,enter:s,appear:a}},n.updateStatus=function(o,i){if(o===void 0&&(o=!1),i!==null)if(this.cancelNextCallback(),i===Pt){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:Ir.findDOMNode(this);s&&cO(s)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===or&&this.setState({status:Di})},n.performEnter=function(o){var i=this,s=this.props.enter,a=this.context?this.context.isMounting:o,l=this.props.nodeRef?[a]:[Ir.findDOMNode(this),a],u=l[0],c=l[1],d=this.getTimeouts(),f=a?d.appear:d.enter;if(!o&&!s||Ly.disabled){this.safeSetState({status:In},function(){i.props.onEntered(u)});return}this.props.onEnter(u,c),this.safeSetState({status:Pt},function(){i.props.onEntering(u,c),i.onTransitionEnd(f,function(){i.safeSetState({status:In},function(){i.props.onEntered(u,c)})})})},n.performExit=function(){var o=this,i=this.props.exit,s=this.getTimeouts(),a=this.props.nodeRef?void 0:Ir.findDOMNode(this);if(!i||Ly.disabled){this.safeSetState({status:or},function(){o.props.onExited(a)});return}this.props.onExit(a),this.safeSetState({status:Yo},function(){o.props.onExiting(a),o.onTransitionEnd(s.exit,function(){o.safeSetState({status:or},function(){o.props.onExited(a)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,i){i=this.setNextCallback(i),this.setState(o,i)},n.setNextCallback=function(o){var i=this,s=!0;return this.nextCallback=function(a){s&&(s=!1,i.nextCallback=null,o(a))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},n.onTransitionEnd=function(o,i){this.setNextCallback(i);var s=this.props.nodeRef?this.props.nodeRef.current:Ir.findDOMNode(this),a=o==null&&!this.props.addEndListener;if(!s||a){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var l=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],u=l[0],c=l[1];this.props.addEndListener(u,c)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===Di)return null;var i=this.props,s=i.children;i.in,i.mountOnEnter,i.unmountOnExit,i.appear,i.enter,i.exit,i.timeout,i.addEndListener,i.onEnter,i.onEntering,i.onEntered,i.onExit,i.onExiting,i.onExited,i.nodeRef;var a=an(i,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return ne.createElement(Aw.Provider,{value:null},typeof s=="function"?s(o,a):ne.cloneElement(ne.Children.only(s),a))},t}(ne.Component);Jn.contextType=Aw;Jn.propTypes={};function io(){}Jn.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:io,onEntering:io,onEntered:io,onExit:io,onExiting:io,onExited:io};Jn.UNMOUNTED=Di;Jn.EXITED=or;Jn.ENTERING=Pt;Jn.ENTERED=In;Jn.EXITING=Yo;const ku=!!(typeof window<"u"&&window.document&&window.document.createElement);var wd=!1,Sd=!1;try{var Kc={get passive(){return wd=!0},get once(){return Sd=wd=!0}};ku&&(window.addEventListener("test",Kc,Kc),window.removeEventListener("test",Kc,!0))}catch{}function fO(e,t,n,r){if(r&&typeof r!="boolean"&&!Sd){var o=r.once,i=r.capture,s=n;!Sd&&o&&(s=n.__once||function a(l){this.removeEventListener(t,a,i),n.call(this,l)},n.__once=s),e.addEventListener(t,s,wd?r:i)}e.addEventListener(t,n,r)}function dO(e,t,n,r){var o=r&&typeof r!="boolean"?r.capture:r;e.removeEventListener(t,n,o),n.__once&&e.removeEventListener(t,n.__once,o)}function Dn(e,t,n,r){return fO(e,t,n,r),function(){dO(e,t,n,r)}}function pO(e,t,n,r){if(r===void 0&&(r=!0),e){var o=document.createEvent("HTMLEvents");o.initEvent(t,n,r),e.dispatchEvent(o)}}function hO(e){var t=Fn(e,"transitionDuration")||"",n=t.indexOf("ms")===-1?1e3:1;return parseFloat(t)*n}function mO(e,t,n){n===void 0&&(n=5);var r=!1,o=setTimeout(function(){r||pO(e,"transitionend",!0)},t+n),i=Dn(e,"transitionend",function(){r=!0},{once:!0});return function(){clearTimeout(o),i()}}function yO(e,t,n,r){n==null&&(n=hO(e)||0);var o=mO(e,n,r),i=Dn(e,"transitionend",t);return function(){o(),i()}}function Iy(e,t){const n=Fn(e,t)||"",r=n.indexOf("ms")===-1?1e3:1;return parseFloat(n)*r}function uh(e,t){const n=Iy(e,"transitionDuration"),r=Iy(e,"transitionDelay"),o=yO(e,i=>{i.target===e&&(o(),t(i))},n+r)}function $i(...e){return e.filter(t=>t!=null).reduce((t,n)=>{if(typeof n!="function")throw new Error("Invalid Argument Type, must only provide functions, undefined, or null.");return t===null?n:function(...o){t.apply(this,o),n.apply(this,o)}},null)}function Pw(e){e.offsetHeight}const My=e=>!e||typeof e=="function"?e:t=>{e.current=t};function vO(e,t){const n=My(e),r=My(t);return o=>{n&&n(o),r&&r(o)}}function Yr(e,t){return h.useMemo(()=>vO(e,t),[e,t])}function Ll(e){return e&&"setState"in e?Ir.findDOMNode(e):e??null}const ch=ne.forwardRef(({onEnter:e,onEntering:t,onEntered:n,onExit:r,onExiting:o,onExited:i,addEndListener:s,children:a,childRef:l,...u},c)=>{const d=h.useRef(null),f=Yr(d,l),v=x=>{f(Ll(x))},g=x=>b=>{x&&d.current&&x(d.current,b)},S=h.useCallback(g(e),[e]),k=h.useCallback(g(t),[t]),m=h.useCallback(g(n),[n]),p=h.useCallback(g(r),[r]),y=h.useCallback(g(o),[o]),E=h.useCallback(g(i),[i]),C=h.useCallback(g(s),[s]);return w.jsx(Jn,{ref:c,...u,onEnter:S,onEntered:m,onEntering:k,onExit:p,onExited:E,onExiting:y,addEndListener:C,nodeRef:d,children:typeof a=="function"?(x,b)=>a(x,{...b,ref:v}):ne.cloneElement(a,{ref:v})})}),gO={height:["marginTop","marginBottom"],width:["marginLeft","marginRight"]};function wO(e,t){const n=`offset${e[0].toUpperCase()}${e.slice(1)}`,r=t[n],o=gO[e];return r+parseInt(Fn(t,o[0]),10)+parseInt(Fn(t,o[1]),10)}const SO={[or]:"collapse",[Yo]:"collapsing",[Pt]:"collapsing",[In]:"collapse show"},bu=ne.forwardRef(({onEnter:e,onEntering:t,onEntered:n,onExit:r,onExiting:o,className:i,children:s,dimension:a="height",in:l=!1,timeout:u=300,mountOnEnter:c=!1,unmountOnExit:d=!1,appear:f=!1,getDimensionValue:v=wO,...g},S)=>{const k=typeof a=="function"?a():a,m=h.useMemo(()=>$i(x=>{x.style[k]="0"},e),[k,e]),p=h.useMemo(()=>$i(x=>{const b=`scroll${k[0].toUpperCase()}${k.slice(1)}`;x.style[k]=`${x[b]}px`},t),[k,t]),y=h.useMemo(()=>$i(x=>{x.style[k]=null},n),[k,n]),E=h.useMemo(()=>$i(x=>{x.style[k]=`${v(k,x)}px`,Pw(x)},r),[r,v,k]),C=h.useMemo(()=>$i(x=>{x.style[k]=null},o),[k,o]);return w.jsx(ch,{ref:S,addEndListener:uh,...g,"aria-expanded":g.role?l:null,onEnter:m,onEntering:p,onEntered:y,onExit:E,onExiting:C,childRef:s.ref,in:l,timeout:u,mountOnEnter:c,unmountOnExit:d,appear:f,children:(x,b)=>ne.cloneElement(s,{...b,className:M(i,s.props.className,SO[x],k==="width"&&"collapse-horizontal")})})});function xO(e){const t=h.useRef(e);return h.useEffect(()=>{t.current=e},[e]),t}function it(e){const t=xO(e);return h.useCallback(function(...n){return t.current&&t.current(...n)},[t])}const fh=e=>h.forwardRef((t,n)=>w.jsx("div",{...t,ref:n,className:M(t.className,e)}));function By(){return h.useState(null)}function dh(){const e=h.useRef(!0),t=h.useRef(()=>e.current);return h.useEffect(()=>(e.current=!0,()=>{e.current=!1}),[]),t.current}function EO(e){const t=h.useRef(null);return h.useEffect(()=>{t.current=e}),t.current}const kO=typeof global<"u"&&global.navigator&&global.navigator.product==="ReactNative",bO=typeof document<"u",Il=bO||kO?h.useLayoutEffect:h.useEffect,CO=["as","disabled"];function OO(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i=0)&&(n[o]=e[o]);return n}function $O(e){return!e||e.trim()==="#"}function jw({tagName:e,disabled:t,href:n,target:r,rel:o,role:i,onClick:s,tabIndex:a=0,type:l}){e||(n!=null||r!=null||o!=null?e="a":e="button");const u={tagName:e};if(e==="button")return[{type:l||"button",disabled:t},u];const c=f=>{if((t||e==="a"&&$O(n))&&f.preventDefault(),t){f.stopPropagation();return}s==null||s(f)},d=f=>{f.key===" "&&(f.preventDefault(),c(f))};return e==="a"&&(n||(n="#"),t&&(n=void 0)),[{role:i??"button",disabled:void 0,tabIndex:t?void 0:a,href:n,target:e==="a"?r:void 0,"aria-disabled":t||void 0,rel:e==="a"?o:void 0,onClick:c,onKeyDown:d},u]}const _O=h.forwardRef((e,t)=>{let{as:n,disabled:r}=e,o=OO(e,CO);const[i,{tagName:s}]=jw(Object.assign({tagName:n,disabled:r},o));return w.jsx(s,Object.assign({},o,i,{ref:t}))});_O.displayName="Button";const TO={[Pt]:"show",[In]:"show"},Cs=h.forwardRef(({className:e,children:t,transitionClasses:n={},onEnter:r,...o},i)=>{const s={in:!1,timeout:300,mountOnEnter:!1,unmountOnExit:!1,appear:!1,...o},a=h.useCallback((l,u)=>{Pw(l),r==null||r(l,u)},[r]);return w.jsx(ch,{ref:i,addEndListener:uh,...s,onEnter:a,childRef:t.ref,children:(l,u)=>h.cloneElement(t,{...u,className:M("fade",e,t.props.className,TO[l],n[l])})})});Cs.displayName="Fade";const RO={"aria-label":pe.string,onClick:pe.func,variant:pe.oneOf(["white"])},Cu=h.forwardRef(({className:e,variant:t,"aria-label":n="Close",...r},o)=>w.jsx("button",{ref:o,type:"button",className:M("btn-close",t&&`btn-close-${t}`,e),"aria-label":n,...r}));Cu.displayName="CloseButton";Cu.propTypes=RO;const Lw=h.forwardRef(({bsPrefix:e,bg:t="primary",pill:n=!1,text:r,className:o,as:i="span",...s},a)=>{const l=z(e,"badge");return w.jsx(i,{ref:a,...s,className:M(o,l,n&&"rounded-pill",r&&`text-${r}`,t&&`bg-${t}`)})});Lw.displayName="Badge";const zs=h.forwardRef(({as:e,bsPrefix:t,variant:n="primary",size:r,active:o=!1,disabled:i=!1,className:s,...a},l)=>{const u=z(t,"btn"),[c,{tagName:d}]=jw({tagName:e,disabled:i,...a}),f=d;return w.jsx(f,{...c,...a,ref:l,disabled:i,className:M(s,u,o&&"active",n&&`${u}-${n}`,r&&`${u}-${r}`,a.href&&i&&"disabled")})});zs.displayName="Button";const ph=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"card-body"),w.jsx(n,{ref:o,className:M(e,t),...r})));ph.displayName="CardBody";const Iw=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"card-footer"),w.jsx(n,{ref:o,className:M(e,t),...r})));Iw.displayName="CardFooter";const Mw=h.createContext(null);Mw.displayName="CardHeaderContext";const Bw=h.forwardRef(({bsPrefix:e,className:t,as:n="div",...r},o)=>{const i=z(e,"card-header"),s=h.useMemo(()=>({cardHeaderBsPrefix:i}),[i]);return w.jsx(Mw.Provider,{value:s,children:w.jsx(n,{ref:o,...r,className:M(t,i)})})});Bw.displayName="CardHeader";const Dw=h.forwardRef(({bsPrefix:e,className:t,variant:n,as:r="img",...o},i)=>{const s=z(e,"card-img");return w.jsx(r,{ref:i,className:M(n?`${s}-${n}`:s,t),...o})});Dw.displayName="CardImg";const Fw=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"card-img-overlay"),w.jsx(n,{ref:o,className:M(e,t),...r})));Fw.displayName="CardImgOverlay";const zw=h.forwardRef(({className:e,bsPrefix:t,as:n="a",...r},o)=>(t=z(t,"card-link"),w.jsx(n,{ref:o,className:M(e,t),...r})));zw.displayName="CardLink";const NO=fh("h6"),Uw=h.forwardRef(({className:e,bsPrefix:t,as:n=NO,...r},o)=>(t=z(t,"card-subtitle"),w.jsx(n,{ref:o,className:M(e,t),...r})));Uw.displayName="CardSubtitle";const Ww=h.forwardRef(({className:e,bsPrefix:t,as:n="p",...r},o)=>(t=z(t,"card-text"),w.jsx(n,{ref:o,className:M(e,t),...r})));Ww.displayName="CardText";const AO=fh("h5"),Hw=h.forwardRef(({className:e,bsPrefix:t,as:n=AO,...r},o)=>(t=z(t,"card-title"),w.jsx(n,{ref:o,className:M(e,t),...r})));Hw.displayName="CardTitle";const Vw=h.forwardRef(({bsPrefix:e,className:t,bg:n,text:r,border:o,body:i=!1,children:s,as:a="div",...l},u)=>{const c=z(e,"card");return w.jsx(a,{ref:u,...l,className:M(t,c,n&&`bg-${n}`,r&&`text-${r}`,o&&`border-${o}`),children:i?w.jsx(ph,{children:s}):s})});Vw.displayName="Card";const Do=Object.assign(Vw,{Img:Dw,Title:Hw,Subtitle:Uw,Body:ph,Link:zw,Text:Ww,Header:Bw,Footer:Iw,ImgOverlay:Fw});function PO(e){const t=h.useRef(e);return t.current=e,t}function Kw(e){const t=PO(e);h.useEffect(()=>()=>t.current(),[])}const xd=2**31-1;function Gw(e,t,n){const r=n-Date.now();e.current=r<=xd?setTimeout(t,r):setTimeout(()=>Gw(e,t,n),xd)}function qw(){const e=dh(),t=h.useRef();return Kw(()=>clearTimeout(t.current)),h.useMemo(()=>{const n=()=>clearTimeout(t.current);function r(o,i=0){e()&&(n(),i<=xd?t.current=setTimeout(o,i):Gw(t,o,Date.now()+i))}return{set:r,clear:n,handleRef:t}},[])}function jO(e,t){return h.Children.toArray(e).some(n=>h.isValidElement(n)&&n.type===t)}function LO({as:e,bsPrefix:t,className:n,...r}){t=z(t,"col");const o=b0(),i=C0(),s=[],a=[];return o.forEach(l=>{const u=r[l];delete r[l];let c,d,f;typeof u=="object"&&u!=null?{span:c,offset:d,order:f}=u:c=u;const v=l!==i?`-${l}`:"";c&&s.push(c===!0?`${t}${v}`:`${t}${v}-${c}`),f!=null&&a.push(`order${v}-${f}`),d!=null&&a.push(`offset${v}-${d}`)}),[{...r,className:M(n,...s,...a)},{as:e,bsPrefix:t,spans:s}]}const dn=h.forwardRef((e,t)=>{const[{className:n,...r},{as:o="div",bsPrefix:i,spans:s}]=LO(e);return w.jsx(o,{...r,ref:t,className:M(n,!s.length&&i)})});dn.displayName="Col";const Qw=h.forwardRef(({bsPrefix:e,fluid:t=!1,as:n="div",className:r,...o},i)=>{const s=z(e,"container"),a=typeof t=="string"?`-${t}`:"-fluid";return w.jsx(n,{ref:i,...o,className:M(r,t?`${s}${a}`:s)})});Qw.displayName="Container";var IO=Function.prototype.bind.call(Function.prototype.call,[].slice);function so(e,t){return IO(e.querySelectorAll(t))}var Dy=Object.prototype.hasOwnProperty;function Fy(e,t,n){for(n of e.keys())if(Zi(n,t))return n}function Zi(e,t){var n,r,o;if(e===t)return!0;if(e&&t&&(n=e.constructor)===t.constructor){if(n===Date)return e.getTime()===t.getTime();if(n===RegExp)return e.toString()===t.toString();if(n===Array){if((r=e.length)===t.length)for(;r--&&Zi(e[r],t[r]););return r===-1}if(n===Set){if(e.size!==t.size)return!1;for(r of e)if(o=r,o&&typeof o=="object"&&(o=Fy(t,o),!o)||!t.has(o))return!1;return!0}if(n===Map){if(e.size!==t.size)return!1;for(r of e)if(o=r[0],o&&typeof o=="object"&&(o=Fy(t,o),!o)||!Zi(r[1],t.get(o)))return!1;return!0}if(n===ArrayBuffer)e=new Uint8Array(e),t=new Uint8Array(t);else if(n===DataView){if((r=e.byteLength)===t.byteLength)for(;r--&&e.getInt8(r)===t.getInt8(r););return r===-1}if(ArrayBuffer.isView(e)){if((r=e.byteLength)===t.byteLength)for(;r--&&e[r]===t[r];);return r===-1}if(!n||typeof e=="object"){r=0;for(n in e)if(Dy.call(e,n)&&++r&&!Dy.call(t,n)||!(n in t)||!Zi(e[n],t[n]))return!1;return Object.keys(t).length===r}}return e!==e&&t!==t}function MO(e){const t=dh();return[e[0],h.useCallback(n=>{if(t())return e[1](n)},[t,e[1]])]}var ht="top",zt="bottom",Ut="right",mt="left",hh="auto",Us=[ht,zt,Ut,mt],Xo="start",Os="end",BO="clippingParents",Yw="viewport",_i="popper",DO="reference",zy=Us.reduce(function(e,t){return e.concat([t+"-"+Xo,t+"-"+Os])},[]),Xw=[].concat(Us,[hh]).reduce(function(e,t){return e.concat([t,t+"-"+Xo,t+"-"+Os])},[]),FO="beforeRead",zO="read",UO="afterRead",WO="beforeMain",HO="main",VO="afterMain",KO="beforeWrite",GO="write",qO="afterWrite",QO=[FO,zO,UO,WO,HO,VO,KO,GO,qO];function wn(e){return e.split("-")[0]}function bt(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Gr(e){var t=bt(e).Element;return e instanceof t||e instanceof Element}function Sn(e){var t=bt(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function mh(e){if(typeof ShadowRoot>"u")return!1;var t=bt(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}var Dr=Math.max,Ml=Math.min,Jo=Math.round;function Ed(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Jw(){return!/^((?!chrome|android).)*safari/i.test(Ed())}function Zo(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,i=1;t&&Sn(e)&&(o=e.offsetWidth>0&&Jo(r.width)/e.offsetWidth||1,i=e.offsetHeight>0&&Jo(r.height)/e.offsetHeight||1);var s=Gr(e)?bt(e):window,a=s.visualViewport,l=!Jw()&&n,u=(r.left+(l&&a?a.offsetLeft:0))/o,c=(r.top+(l&&a?a.offsetTop:0))/i,d=r.width/o,f=r.height/i;return{width:d,height:f,top:c,right:u+d,bottom:c+f,left:u,x:u,y:c}}function yh(e){var t=Zo(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function Zw(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&mh(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function kr(e){return e?(e.nodeName||"").toLowerCase():null}function Gn(e){return bt(e).getComputedStyle(e)}function YO(e){return["table","td","th"].indexOf(kr(e))>=0}function $r(e){return((Gr(e)?e.ownerDocument:e.document)||window.document).documentElement}function Ou(e){return kr(e)==="html"?e:e.assignedSlot||e.parentNode||(mh(e)?e.host:null)||$r(e)}function Uy(e){return!Sn(e)||Gn(e).position==="fixed"?null:e.offsetParent}function XO(e){var t=/firefox/i.test(Ed()),n=/Trident/i.test(Ed());if(n&&Sn(e)){var r=Gn(e);if(r.position==="fixed")return null}var o=Ou(e);for(mh(o)&&(o=o.host);Sn(o)&&["html","body"].indexOf(kr(o))<0;){var i=Gn(o);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||t&&i.willChange==="filter"||t&&i.filter&&i.filter!=="none")return o;o=o.parentNode}return null}function Ws(e){for(var t=bt(e),n=Uy(e);n&&YO(n)&&Gn(n).position==="static";)n=Uy(n);return n&&(kr(n)==="html"||kr(n)==="body"&&Gn(n).position==="static")?t:n||XO(e)||t}function vh(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function es(e,t,n){return Dr(e,Ml(t,n))}function JO(e,t,n){var r=es(e,t,n);return r>n?n:r}function eS(){return{top:0,right:0,bottom:0,left:0}}function tS(e){return Object.assign({},eS(),e)}function nS(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var ZO=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,tS(typeof t!="number"?t:nS(t,Us))};function e2(e){var t,n=e.state,r=e.name,o=e.options,i=n.elements.arrow,s=n.modifiersData.popperOffsets,a=wn(n.placement),l=vh(a),u=[mt,Ut].indexOf(a)>=0,c=u?"height":"width";if(!(!i||!s)){var d=ZO(o.padding,n),f=yh(i),v=l==="y"?ht:mt,g=l==="y"?zt:Ut,S=n.rects.reference[c]+n.rects.reference[l]-s[l]-n.rects.popper[c],k=s[l]-n.rects.reference[l],m=Ws(i),p=m?l==="y"?m.clientHeight||0:m.clientWidth||0:0,y=S/2-k/2,E=d[v],C=p-f[c]-d[g],x=p/2-f[c]/2+y,b=es(E,x,C),O=l;n.modifiersData[r]=(t={},t[O]=b,t.centerOffset=b-x,t)}}function t2(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||Zw(t.elements.popper,o)&&(t.elements.arrow=o))}const n2={name:"arrow",enabled:!0,phase:"main",fn:e2,effect:t2,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function ei(e){return e.split("-")[1]}var r2={top:"auto",right:"auto",bottom:"auto",left:"auto"};function o2(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Jo(n*o)/o||0,y:Jo(r*o)/o||0}}function Wy(e){var t,n=e.popper,r=e.popperRect,o=e.placement,i=e.variation,s=e.offsets,a=e.position,l=e.gpuAcceleration,u=e.adaptive,c=e.roundOffsets,d=e.isFixed,f=s.x,v=f===void 0?0:f,g=s.y,S=g===void 0?0:g,k=typeof c=="function"?c({x:v,y:S}):{x:v,y:S};v=k.x,S=k.y;var m=s.hasOwnProperty("x"),p=s.hasOwnProperty("y"),y=mt,E=ht,C=window;if(u){var x=Ws(n),b="clientHeight",O="clientWidth";if(x===bt(n)&&(x=$r(n),Gn(x).position!=="static"&&a==="absolute"&&(b="scrollHeight",O="scrollWidth")),x=x,o===ht||(o===mt||o===Ut)&&i===Os){E=zt;var T=d&&x===C&&C.visualViewport?C.visualViewport.height:x[b];S-=T-r.height,S*=l?1:-1}if(o===mt||(o===ht||o===zt)&&i===Os){y=Ut;var $=d&&x===C&&C.visualViewport?C.visualViewport.width:x[O];v-=$-r.width,v*=l?1:-1}}var A=Object.assign({position:a},u&&r2),U=c===!0?o2({x:v,y:S},bt(n)):{x:v,y:S};if(v=U.x,S=U.y,l){var B;return Object.assign({},A,(B={},B[E]=p?"0":"",B[y]=m?"0":"",B.transform=(C.devicePixelRatio||1)<=1?"translate("+v+"px, "+S+"px)":"translate3d("+v+"px, "+S+"px, 0)",B))}return Object.assign({},A,(t={},t[E]=p?S+"px":"",t[y]=m?v+"px":"",t.transform="",t))}function i2(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,i=n.adaptive,s=i===void 0?!0:i,a=n.roundOffsets,l=a===void 0?!0:a,u={placement:wn(t.placement),variation:ei(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Wy(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:s,roundOffsets:l})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Wy(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const s2={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:i2,data:{}};var ya={passive:!0};function a2(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,i=o===void 0?!0:o,s=r.resize,a=s===void 0?!0:s,l=bt(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return i&&u.forEach(function(c){c.addEventListener("scroll",n.update,ya)}),a&&l.addEventListener("resize",n.update,ya),function(){i&&u.forEach(function(c){c.removeEventListener("scroll",n.update,ya)}),a&&l.removeEventListener("resize",n.update,ya)}}const l2={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:a2,data:{}};var u2={left:"right",right:"left",bottom:"top",top:"bottom"};function Wa(e){return e.replace(/left|right|bottom|top/g,function(t){return u2[t]})}var c2={start:"end",end:"start"};function Hy(e){return e.replace(/start|end/g,function(t){return c2[t]})}function gh(e){var t=bt(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function wh(e){return Zo($r(e)).left+gh(e).scrollLeft}function f2(e,t){var n=bt(e),r=$r(e),o=n.visualViewport,i=r.clientWidth,s=r.clientHeight,a=0,l=0;if(o){i=o.width,s=o.height;var u=Jw();(u||!u&&t==="fixed")&&(a=o.offsetLeft,l=o.offsetTop)}return{width:i,height:s,x:a+wh(e),y:l}}function d2(e){var t,n=$r(e),r=gh(e),o=(t=e.ownerDocument)==null?void 0:t.body,i=Dr(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),s=Dr(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),a=-r.scrollLeft+wh(e),l=-r.scrollTop;return Gn(o||n).direction==="rtl"&&(a+=Dr(n.clientWidth,o?o.clientWidth:0)-i),{width:i,height:s,x:a,y:l}}function Sh(e){var t=Gn(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function rS(e){return["html","body","#document"].indexOf(kr(e))>=0?e.ownerDocument.body:Sn(e)&&Sh(e)?e:rS(Ou(e))}function ts(e,t){var n;t===void 0&&(t=[]);var r=rS(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),i=bt(r),s=o?[i].concat(i.visualViewport||[],Sh(r)?r:[]):r,a=t.concat(s);return o?a:a.concat(ts(Ou(s)))}function kd(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function p2(e,t){var n=Zo(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Vy(e,t,n){return t===Yw?kd(f2(e,n)):Gr(t)?p2(t,n):kd(d2($r(e)))}function h2(e){var t=ts(Ou(e)),n=["absolute","fixed"].indexOf(Gn(e).position)>=0,r=n&&Sn(e)?Ws(e):e;return Gr(r)?t.filter(function(o){return Gr(o)&&Zw(o,r)&&kr(o)!=="body"}):[]}function m2(e,t,n,r){var o=t==="clippingParents"?h2(e):[].concat(t),i=[].concat(o,[n]),s=i[0],a=i.reduce(function(l,u){var c=Vy(e,u,r);return l.top=Dr(c.top,l.top),l.right=Ml(c.right,l.right),l.bottom=Ml(c.bottom,l.bottom),l.left=Dr(c.left,l.left),l},Vy(e,s,r));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function oS(e){var t=e.reference,n=e.element,r=e.placement,o=r?wn(r):null,i=r?ei(r):null,s=t.x+t.width/2-n.width/2,a=t.y+t.height/2-n.height/2,l;switch(o){case ht:l={x:s,y:t.y-n.height};break;case zt:l={x:s,y:t.y+t.height};break;case Ut:l={x:t.x+t.width,y:a};break;case mt:l={x:t.x-n.width,y:a};break;default:l={x:t.x,y:t.y}}var u=o?vh(o):null;if(u!=null){var c=u==="y"?"height":"width";switch(i){case Xo:l[u]=l[u]-(t[c]/2-n[c]/2);break;case Os:l[u]=l[u]+(t[c]/2-n[c]/2);break}}return l}function $s(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,i=n.strategy,s=i===void 0?e.strategy:i,a=n.boundary,l=a===void 0?BO:a,u=n.rootBoundary,c=u===void 0?Yw:u,d=n.elementContext,f=d===void 0?_i:d,v=n.altBoundary,g=v===void 0?!1:v,S=n.padding,k=S===void 0?0:S,m=tS(typeof k!="number"?k:nS(k,Us)),p=f===_i?DO:_i,y=e.rects.popper,E=e.elements[g?p:f],C=m2(Gr(E)?E:E.contextElement||$r(e.elements.popper),l,c,s),x=Zo(e.elements.reference),b=oS({reference:x,element:y,strategy:"absolute",placement:o}),O=kd(Object.assign({},y,b)),T=f===_i?O:x,$={top:C.top-T.top+m.top,bottom:T.bottom-C.bottom+m.bottom,left:C.left-T.left+m.left,right:T.right-C.right+m.right},A=e.modifiersData.offset;if(f===_i&&A){var U=A[o];Object.keys($).forEach(function(B){var K=[Ut,zt].indexOf(B)>=0?1:-1,W=[ht,zt].indexOf(B)>=0?"y":"x";$[B]+=U[W]*K})}return $}function y2(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,i=n.rootBoundary,s=n.padding,a=n.flipVariations,l=n.allowedAutoPlacements,u=l===void 0?Xw:l,c=ei(r),d=c?a?zy:zy.filter(function(g){return ei(g)===c}):Us,f=d.filter(function(g){return u.indexOf(g)>=0});f.length===0&&(f=d);var v=f.reduce(function(g,S){return g[S]=$s(e,{placement:S,boundary:o,rootBoundary:i,padding:s})[wn(S)],g},{});return Object.keys(v).sort(function(g,S){return v[g]-v[S]})}function v2(e){if(wn(e)===hh)return[];var t=Wa(e);return[Hy(e),t,Hy(t)]}function g2(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,i=o===void 0?!0:o,s=n.altAxis,a=s===void 0?!0:s,l=n.fallbackPlacements,u=n.padding,c=n.boundary,d=n.rootBoundary,f=n.altBoundary,v=n.flipVariations,g=v===void 0?!0:v,S=n.allowedAutoPlacements,k=t.options.placement,m=wn(k),p=m===k,y=l||(p||!g?[Wa(k)]:v2(k)),E=[k].concat(y).reduce(function(X,re){return X.concat(wn(re)===hh?y2(t,{placement:re,boundary:c,rootBoundary:d,padding:u,flipVariations:g,allowedAutoPlacements:S}):re)},[]),C=t.rects.reference,x=t.rects.popper,b=new Map,O=!0,T=E[0],$=0;$=0,W=K?"width":"height",G=$s(t,{placement:A,boundary:c,rootBoundary:d,altBoundary:f,padding:u}),V=K?B?Ut:mt:B?zt:ht;C[W]>x[W]&&(V=Wa(V));var _=Wa(V),I=[];if(i&&I.push(G[U]<=0),a&&I.push(G[V]<=0,G[_]<=0),I.every(function(X){return X})){T=A,O=!1;break}b.set(A,I)}if(O)for(var F=g?3:1,Y=function(re){var ge=E.find(function(Me){var qe=b.get(Me);if(qe)return qe.slice(0,re).every(function(_t){return _t})});if(ge)return T=ge,"break"},Z=F;Z>0;Z--){var ve=Y(Z);if(ve==="break")break}t.placement!==T&&(t.modifiersData[r]._skip=!0,t.placement=T,t.reset=!0)}}const w2={name:"flip",enabled:!0,phase:"main",fn:g2,requiresIfExists:["offset"],data:{_skip:!1}};function Ky(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Gy(e){return[ht,Ut,zt,mt].some(function(t){return e[t]>=0})}function S2(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,i=t.modifiersData.preventOverflow,s=$s(t,{elementContext:"reference"}),a=$s(t,{altBoundary:!0}),l=Ky(s,r),u=Ky(a,o,i),c=Gy(l),d=Gy(u);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:c,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":d})}const x2={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:S2};function E2(e,t,n){var r=wn(e),o=[mt,ht].indexOf(r)>=0?-1:1,i=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,s=i[0],a=i[1];return s=s||0,a=(a||0)*o,[mt,Ut].indexOf(r)>=0?{x:a,y:s}:{x:s,y:a}}function k2(e){var t=e.state,n=e.options,r=e.name,o=n.offset,i=o===void 0?[0,0]:o,s=Xw.reduce(function(c,d){return c[d]=E2(d,t.rects,i),c},{}),a=s[t.placement],l=a.x,u=a.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=u),t.modifiersData[r]=s}const b2={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:k2};function C2(e){var t=e.state,n=e.name;t.modifiersData[n]=oS({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const O2={name:"popperOffsets",enabled:!0,phase:"read",fn:C2,data:{}};function $2(e){return e==="x"?"y":"x"}function _2(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,i=o===void 0?!0:o,s=n.altAxis,a=s===void 0?!1:s,l=n.boundary,u=n.rootBoundary,c=n.altBoundary,d=n.padding,f=n.tether,v=f===void 0?!0:f,g=n.tetherOffset,S=g===void 0?0:g,k=$s(t,{boundary:l,rootBoundary:u,padding:d,altBoundary:c}),m=wn(t.placement),p=ei(t.placement),y=!p,E=vh(m),C=$2(E),x=t.modifiersData.popperOffsets,b=t.rects.reference,O=t.rects.popper,T=typeof S=="function"?S(Object.assign({},t.rects,{placement:t.placement})):S,$=typeof T=="number"?{mainAxis:T,altAxis:T}:Object.assign({mainAxis:0,altAxis:0},T),A=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,U={x:0,y:0};if(x){if(i){var B,K=E==="y"?ht:mt,W=E==="y"?zt:Ut,G=E==="y"?"height":"width",V=x[E],_=V+k[K],I=V-k[W],F=v?-O[G]/2:0,Y=p===Xo?b[G]:O[G],Z=p===Xo?-O[G]:-b[G],ve=t.elements.arrow,X=v&&ve?yh(ve):{width:0,height:0},re=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:eS(),ge=re[K],Me=re[W],qe=es(0,b[G],X[G]),_t=y?b[G]/2-F-qe-ge-$.mainAxis:Y-qe-ge-$.mainAxis,_n=y?-b[G]/2+F+qe+Me+$.mainAxis:Z+qe+Me+$.mainAxis,Tn=t.elements.arrow&&Ws(t.elements.arrow),Rn=Tn?E==="y"?Tn.clientTop||0:Tn.clientLeft||0:0,Qe=(B=A==null?void 0:A[E])!=null?B:0,de=V+_t-Qe-Rn,H=V+_n-Qe,Ue=es(v?Ml(_,de):_,V,v?Dr(I,H):I);x[E]=Ue,U[E]=Ue-V}if(a){var nt,vt=E==="x"?ht:mt,vi=E==="x"?zt:Ut,we=x[C],Gt=C==="y"?"height":"width",eo=we+k[vt],to=we-k[vi],Rr=[ht,mt].indexOf(m)!==-1,gi=(nt=A==null?void 0:A[C])!=null?nt:0,no=Rr?eo:we-b[Gt]-O[Gt]-gi+$.altAxis,Zn=Rr?we+b[Gt]+O[Gt]-gi-$.altAxis:to,N=v&&Rr?JO(no,we,Zn):es(v?no:eo,we,v?Zn:to);x[C]=N,U[C]=N-we}t.modifiersData[r]=U}}const T2={name:"preventOverflow",enabled:!0,phase:"main",fn:_2,requiresIfExists:["offset"]};function R2(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function N2(e){return e===bt(e)||!Sn(e)?gh(e):R2(e)}function A2(e){var t=e.getBoundingClientRect(),n=Jo(t.width)/e.offsetWidth||1,r=Jo(t.height)/e.offsetHeight||1;return n!==1||r!==1}function P2(e,t,n){n===void 0&&(n=!1);var r=Sn(t),o=Sn(t)&&A2(t),i=$r(t),s=Zo(e,o,n),a={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(r||!r&&!n)&&((kr(t)!=="body"||Sh(i))&&(a=N2(t)),Sn(t)?(l=Zo(t,!0),l.x+=t.clientLeft,l.y+=t.clientTop):i&&(l.x=wh(i))),{x:s.left+a.scrollLeft-l.x,y:s.top+a.scrollTop-l.y,width:s.width,height:s.height}}function j2(e){var t=new Map,n=new Set,r=[];e.forEach(function(i){t.set(i.name,i)});function o(i){n.add(i.name);var s=[].concat(i.requires||[],i.requiresIfExists||[]);s.forEach(function(a){if(!n.has(a)){var l=t.get(a);l&&o(l)}}),r.push(i)}return e.forEach(function(i){n.has(i.name)||o(i)}),r}function L2(e){var t=j2(e);return QO.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function I2(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function M2(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qy={placement:"bottom",modifiers:[],strategy:"absolute"};function Qy(){for(var e=arguments.length,t=new Array(e),n=0;n=0)&&(n[o]=e[o]);return n}const U2={name:"applyStyles",enabled:!1,phase:"afterWrite",fn:()=>{}},W2={name:"ariaDescribedBy",enabled:!0,phase:"afterWrite",effect:({state:e})=>()=>{const{reference:t,popper:n}=e.elements;if("removeAttribute"in t){const r=(t.getAttribute("aria-describedby")||"").split(",").filter(o=>o.trim()!==n.id);r.length?t.setAttribute("aria-describedby",r.join(",")):t.removeAttribute("aria-describedby")}},fn:({state:e})=>{var t;const{popper:n,reference:r}=e.elements,o=(t=n.getAttribute("role"))==null?void 0:t.toLowerCase();if(n.id&&o==="tooltip"&&"setAttribute"in r){const i=r.getAttribute("aria-describedby");if(i&&i.split(",").indexOf(n.id)!==-1)return;r.setAttribute("aria-describedby",i?`${i},${n.id}`:n.id)}}},H2=[];function V2(e,t,n={}){let{enabled:r=!0,placement:o="bottom",strategy:i="absolute",modifiers:s=H2}=n,a=z2(n,F2);const l=h.useRef(s),u=h.useRef(),c=h.useCallback(()=>{var k;(k=u.current)==null||k.update()},[]),d=h.useCallback(()=>{var k;(k=u.current)==null||k.forceUpdate()},[]),[f,v]=MO(h.useState({placement:o,update:c,forceUpdate:d,attributes:{},styles:{popper:{},arrow:{}}})),g=h.useMemo(()=>({name:"updateStateModifier",enabled:!0,phase:"write",requires:["computeStyles"],fn:({state:k})=>{const m={},p={};Object.keys(k.elements).forEach(y=>{m[y]=k.styles[y],p[y]=k.attributes[y]}),v({state:k,styles:m,attributes:p,update:c,forceUpdate:d,placement:k.placement})}}),[c,d,v]),S=h.useMemo(()=>(Zi(l.current,s)||(l.current=s),l.current),[s]);return h.useEffect(()=>{!u.current||!r||u.current.setOptions({placement:o,strategy:i,modifiers:[...S,g,U2]})},[i,o,g,r,S]),h.useEffect(()=>{if(!(!r||e==null||t==null))return u.current=D2(e,t,Object.assign({},a,{placement:o,strategy:i,modifiers:[...S,W2,g]})),()=>{u.current!=null&&(u.current.destroy(),u.current=void 0,v(k=>Object.assign({},k,{attributes:{},styles:{popper:{}}})))}},[r,e,t]),f}function _s(e,t){if(e.contains)return e.contains(t);if(e.compareDocumentPosition)return e===t||!!(e.compareDocumentPosition(t)&16)}var K2=function(){},G2=K2;const q2=si(G2),Yy=()=>{};function Q2(e){return e.button===0}function Y2(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}const Ha=e=>e&&("current"in e?e.current:e),Xy={click:"mousedown",mouseup:"mousedown",pointerup:"pointerdown"};function X2(e,t=Yy,{disabled:n,clickTrigger:r="click"}={}){const o=h.useRef(!1),i=h.useRef(!1),s=h.useCallback(u=>{const c=Ha(e);q2(!!c,"ClickOutside captured a close event but does not have a ref to compare it to. useClickOutside(), should be passed a ref that resolves to a DOM node"),o.current=!c||Y2(u)||!Q2(u)||!!_s(c,u.target)||i.current,i.current=!1},[e]),a=it(u=>{const c=Ha(e);c&&_s(c,u.target)&&(i.current=!0)}),l=it(u=>{o.current||t(u)});h.useEffect(()=>{var u,c;if(n||e==null)return;const d=Is(Ha(e)),f=d.defaultView||window;let v=(u=f.event)!=null?u:(c=f.parent)==null?void 0:c.event,g=null;Xy[r]&&(g=Dn(d,Xy[r],a,!0));const S=Dn(d,r,s,!0),k=Dn(d,r,p=>{if(p===v){v=void 0;return}l(p)});let m=[];return"ontouchstart"in d.documentElement&&(m=[].slice.call(d.body.children).map(p=>Dn(p,"mousemove",Yy))),()=>{g==null||g(),S(),k(),m.forEach(p=>p())}},[e,n,r,s,a,l])}function J2(e){const t={};return Array.isArray(e)?(e==null||e.forEach(n=>{t[n.name]=n}),t):e||t}function Z2(e={}){return Array.isArray(e)?e:Object.keys(e).map(t=>(e[t].name=t,e[t]))}function e$({enabled:e,enableEvents:t,placement:n,flip:r,offset:o,fixed:i,containerPadding:s,arrowElement:a,popperConfig:l={}}){var u,c,d,f,v;const g=J2(l.modifiers);return Object.assign({},l,{placement:n,enabled:e,strategy:i?"fixed":l.strategy,modifiers:Z2(Object.assign({},g,{eventListeners:{enabled:t,options:(u=g.eventListeners)==null?void 0:u.options},preventOverflow:Object.assign({},g.preventOverflow,{options:s?Object.assign({padding:s},(c=g.preventOverflow)==null?void 0:c.options):(d=g.preventOverflow)==null?void 0:d.options}),offset:{options:Object.assign({offset:o},(f=g.offset)==null?void 0:f.options)},arrow:Object.assign({},g.arrow,{enabled:!!a,options:Object.assign({},(v=g.arrow)==null?void 0:v.options,{element:a})}),flip:Object.assign({enabled:!!r},g.flip)}))})}const t$=h.createContext(null),n$="data-rr-ui-";function r$(e){return`${n$}${e}`}const iS=h.createContext(ku?window:void 0);iS.Provider;function xh(){return h.useContext(iS)}const sS=h.createContext(null);sS.displayName="InputGroupContext";const ci=h.createContext(null);ci.displayName="NavbarContext";pe.string,pe.bool,pe.bool,pe.bool,pe.bool;const aS=h.forwardRef(({bsPrefix:e,className:t,fluid:n=!1,rounded:r=!1,roundedCircle:o=!1,thumbnail:i=!1,...s},a)=>(e=z(e,"img"),w.jsx("img",{ref:a,...s,className:M(t,n&&`${e}-fluid`,r&&"rounded",o&&"rounded-circle",i&&`${e}-thumbnail`)})));aS.displayName="Image";const o$={type:pe.string,tooltip:pe.bool,as:pe.elementType},$u=h.forwardRef(({as:e="div",className:t,type:n="valid",tooltip:r=!1,...o},i)=>w.jsx(e,{...o,ref:i,className:M(t,`${n}-${r?"tooltip":"feedback"}`)}));$u.displayName="Feedback";$u.propTypes=o$;const qn=h.createContext({}),Hs=h.forwardRef(({id:e,bsPrefix:t,className:n,type:r="checkbox",isValid:o=!1,isInvalid:i=!1,as:s="input",...a},l)=>{const{controlId:u}=h.useContext(qn);return t=z(t,"form-check-input"),w.jsx(s,{...a,ref:l,type:r,id:e||u,className:M(n,t,o&&"is-valid",i&&"is-invalid")})});Hs.displayName="FormCheckInput";const Bl=h.forwardRef(({bsPrefix:e,className:t,htmlFor:n,...r},o)=>{const{controlId:i}=h.useContext(qn);return e=z(e,"form-check-label"),w.jsx("label",{...r,ref:o,htmlFor:n||i,className:M(t,e)})});Bl.displayName="FormCheckLabel";const lS=h.forwardRef(({id:e,bsPrefix:t,bsSwitchPrefix:n,inline:r=!1,reverse:o=!1,disabled:i=!1,isValid:s=!1,isInvalid:a=!1,feedbackTooltip:l=!1,feedback:u,feedbackType:c,className:d,style:f,title:v="",type:g="checkbox",label:S,children:k,as:m="input",...p},y)=>{t=z(t,"form-check"),n=z(n,"form-switch");const{controlId:E}=h.useContext(qn),C=h.useMemo(()=>({controlId:e||E}),[E,e]),x=!k&&S!=null&&S!==!1||jO(k,Bl),b=w.jsx(Hs,{...p,type:g==="switch"?"checkbox":g,ref:y,isValid:s,isInvalid:a,disabled:i,as:m});return w.jsx(qn.Provider,{value:C,children:w.jsx("div",{style:f,className:M(d,x&&t,r&&`${t}-inline`,o&&`${t}-reverse`,g==="switch"&&n),children:k||w.jsxs(w.Fragment,{children:[b,x&&w.jsx(Bl,{title:v,children:S}),u&&w.jsx($u,{type:c,tooltip:l,children:u})]})})})});lS.displayName="FormCheck";const Dl=Object.assign(lS,{Input:Hs,Label:Bl}),uS=h.forwardRef(({bsPrefix:e,type:t,size:n,htmlSize:r,id:o,className:i,isValid:s=!1,isInvalid:a=!1,plaintext:l,readOnly:u,as:c="input",...d},f)=>{const{controlId:v}=h.useContext(qn);return e=z(e,"form-control"),w.jsx(c,{...d,type:t,size:r,ref:f,readOnly:u,id:o||v,className:M(i,l?`${e}-plaintext`:e,n&&`${e}-${n}`,t==="color"&&`${e}-color`,s&&"is-valid",a&&"is-invalid")})});uS.displayName="FormControl";const i$=Object.assign(uS,{Feedback:$u}),cS=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"form-floating"),w.jsx(n,{ref:o,className:M(e,t),...r})));cS.displayName="FormFloating";const Eh=h.forwardRef(({controlId:e,as:t="div",...n},r)=>{const o=h.useMemo(()=>({controlId:e}),[e]);return w.jsx(qn.Provider,{value:o,children:w.jsx(t,{...n,ref:r})})});Eh.displayName="FormGroup";const fS=h.forwardRef(({as:e="label",bsPrefix:t,column:n=!1,visuallyHidden:r=!1,className:o,htmlFor:i,...s},a)=>{const{controlId:l}=h.useContext(qn);t=z(t,"form-label");let u="col-form-label";typeof n=="string"&&(u=`${u} ${u}-${n}`);const c=M(o,t,r&&"visually-hidden",n&&u);return i=i||l,n?w.jsx(dn,{ref:a,as:"label",className:c,htmlFor:i,...s}):w.jsx(e,{ref:a,className:c,htmlFor:i,...s})});fS.displayName="FormLabel";const dS=h.forwardRef(({bsPrefix:e,className:t,id:n,...r},o)=>{const{controlId:i}=h.useContext(qn);return e=z(e,"form-range"),w.jsx("input",{...r,type:"range",ref:o,className:M(t,e),id:n||i})});dS.displayName="FormRange";const pS=h.forwardRef(({bsPrefix:e,size:t,htmlSize:n,className:r,isValid:o=!1,isInvalid:i=!1,id:s,...a},l)=>{const{controlId:u}=h.useContext(qn);return e=z(e,"form-select"),w.jsx("select",{...a,size:n,ref:l,className:M(r,e,t&&`${e}-${t}`,o&&"is-valid",i&&"is-invalid"),id:s||u})});pS.displayName="FormSelect";const hS=h.forwardRef(({bsPrefix:e,className:t,as:n="small",muted:r,...o},i)=>(e=z(e,"form-text"),w.jsx(n,{...o,ref:i,className:M(t,e,r&&"text-muted")})));hS.displayName="FormText";const mS=h.forwardRef((e,t)=>w.jsx(Dl,{...e,ref:t,type:"switch"}));mS.displayName="Switch";const s$=Object.assign(mS,{Input:Dl.Input,Label:Dl.Label}),yS=h.forwardRef(({bsPrefix:e,className:t,children:n,controlId:r,label:o,...i},s)=>(e=z(e,"form-floating"),w.jsxs(Eh,{ref:s,className:M(t,e),controlId:r,...i,children:[n,w.jsx("label",{htmlFor:r,children:o})]})));yS.displayName="FloatingLabel";const a$={_ref:pe.any,validated:pe.bool,as:pe.elementType},kh=h.forwardRef(({className:e,validated:t,as:n="form",...r},o)=>w.jsx(n,{...r,ref:o,className:M(e,t&&"was-validated")}));kh.displayName="Form";kh.propTypes=a$;const ot=Object.assign(kh,{Group:Eh,Control:i$,Floating:cS,Check:Dl,Switch:s$,Label:fS,Text:hS,Range:dS,Select:pS,FloatingLabel:yS}),_u=h.forwardRef(({className:e,bsPrefix:t,as:n="span",...r},o)=>(t=z(t,"input-group-text"),w.jsx(n,{ref:o,className:M(e,t),...r})));_u.displayName="InputGroupText";const l$=e=>w.jsx(_u,{children:w.jsx(Hs,{type:"checkbox",...e})}),u$=e=>w.jsx(_u,{children:w.jsx(Hs,{type:"radio",...e})}),vS=h.forwardRef(({bsPrefix:e,size:t,hasValidation:n,className:r,as:o="div",...i},s)=>{e=z(e,"input-group");const a=h.useMemo(()=>({}),[]);return w.jsx(sS.Provider,{value:a,children:w.jsx(o,{ref:s,...i,className:M(r,e,t&&`${e}-${t}`,n&&"has-validation")})})});vS.displayName="InputGroup";const Un=Object.assign(vS,{Text:_u,Radio:u$,Checkbox:l$});function Gc(e){e===void 0&&(e=Is());try{var t=e.activeElement;return!t||!t.nodeName?null:t}catch{return e.body}}function c$(e=document){const t=e.defaultView;return Math.abs(t.innerWidth-e.documentElement.clientWidth)}const Jy=r$("modal-open");class bh{constructor({ownerDocument:t,handleContainerOverflow:n=!0,isRTL:r=!1}={}){this.handleContainerOverflow=n,this.isRTL=r,this.modals=[],this.ownerDocument=t}getScrollbarWidth(){return c$(this.ownerDocument)}getElement(){return(this.ownerDocument||document).body}setModalAttributes(t){}removeModalAttributes(t){}setContainerStyle(t){const n={overflow:"hidden"},r=this.isRTL?"paddingLeft":"paddingRight",o=this.getElement();t.style={overflow:o.style.overflow,[r]:o.style[r]},t.scrollBarWidth&&(n[r]=`${parseInt(Fn(o,r)||"0",10)+t.scrollBarWidth}px`),o.setAttribute(Jy,""),Fn(o,n)}reset(){[...this.modals].forEach(t=>this.remove(t))}removeContainerStyle(t){const n=this.getElement();n.removeAttribute(Jy),Object.assign(n.style,t.style)}add(t){let n=this.modals.indexOf(t);return n!==-1||(n=this.modals.length,this.modals.push(t),this.setModalAttributes(t),n!==0)||(this.state={scrollBarWidth:this.getScrollbarWidth(),style:{}},this.handleContainerOverflow&&this.setContainerStyle(this.state)),n}remove(t){const n=this.modals.indexOf(t);n!==-1&&(this.modals.splice(n,1),!this.modals.length&&this.handleContainerOverflow&&this.removeContainerStyle(this.state),this.removeModalAttributes(t))}isTopModal(t){return!!this.modals.length&&this.modals[this.modals.length-1]===t}}const qc=(e,t)=>ku?e==null?(t||Is()).body:(typeof e=="function"&&(e=e()),e&&"current"in e&&(e=e.current),e&&("nodeType"in e||e.getBoundingClientRect)?e:null):null;function bd(e,t){const n=xh(),[r,o]=h.useState(()=>qc(e,n==null?void 0:n.document));if(!r){const i=qc(e);i&&o(i)}return h.useEffect(()=>{},[t,r]),h.useEffect(()=>{const i=qc(e);i!==r&&o(i)},[e,r]),r}function f$({children:e,in:t,onExited:n,mountOnEnter:r,unmountOnExit:o}){const i=h.useRef(null),s=h.useRef(t),a=it(n);h.useEffect(()=>{t?s.current=!0:a(i.current)},[t,a]);const l=Yr(i,e.ref),u=h.cloneElement(e,{ref:l});return t?u:o||!s.current&&r?null:u}function gS(e){return e.code==="Escape"||e.keyCode===27}function d$(){const e=h.version.split(".");return{major:+e[0],minor:+e[1],patch:+e[2]}}const p$=["onEnter","onEntering","onEntered","onExit","onExiting","onExited","addEndListener","children"];function h$(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i=0)&&(n[o]=e[o]);return n}function m$(e){let{onEnter:t,onEntering:n,onEntered:r,onExit:o,onExiting:i,onExited:s,addEndListener:a,children:l}=e,u=h$(e,p$);const{major:c}=d$(),d=c>=19?l.props.ref:l.ref,f=h.useRef(null),v=Yr(f,typeof l=="function"?null:d),g=x=>b=>{x&&f.current&&x(f.current,b)},S=h.useCallback(g(t),[t]),k=h.useCallback(g(n),[n]),m=h.useCallback(g(r),[r]),p=h.useCallback(g(o),[o]),y=h.useCallback(g(i),[i]),E=h.useCallback(g(s),[s]),C=h.useCallback(g(a),[a]);return Object.assign({},u,{nodeRef:f},t&&{onEnter:S},n&&{onEntering:k},r&&{onEntered:m},o&&{onExit:p},i&&{onExiting:y},s&&{onExited:E},a&&{addEndListener:C},{children:typeof l=="function"?(x,b)=>l(x,Object.assign({},b,{ref:v})):h.cloneElement(l,{ref:v})})}const y$=["component"];function v$(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i=0)&&(n[o]=e[o]);return n}const g$=h.forwardRef((e,t)=>{let{component:n}=e,r=v$(e,y$);const o=m$(r);return w.jsx(n,Object.assign({ref:t},o))});function w$({in:e,onTransition:t}){const n=h.useRef(null),r=h.useRef(!0),o=it(t);return Il(()=>{if(!n.current)return;let i=!1;return o({in:e,element:n.current,initial:r.current,isStale:()=>i}),()=>{i=!0}},[e,o]),Il(()=>(r.current=!1,()=>{r.current=!0}),[]),n}function S$({children:e,in:t,onExited:n,onEntered:r,transition:o}){const[i,s]=h.useState(!t);t&&i&&s(!1);const a=w$({in:!!t,onTransition:u=>{const c=()=>{u.isStale()||(u.in?r==null||r(u.element,u.initial):(s(!0),n==null||n(u.element)))};Promise.resolve(o(u)).then(c,d=>{throw u.in||s(!0),d})}}),l=Yr(a,e.ref);return i&&!t?null:h.cloneElement(e,{ref:l})}function Cd(e,t,n){return e?w.jsx(g$,Object.assign({},n,{component:e})):t?w.jsx(S$,Object.assign({},n,{transition:t})):w.jsx(f$,Object.assign({},n))}const x$=["show","role","className","style","children","backdrop","keyboard","onBackdropClick","onEscapeKeyDown","transition","runTransition","backdropTransition","runBackdropTransition","autoFocus","enforceFocus","restoreFocus","restoreFocusOptions","renderDialog","renderBackdrop","manager","container","onShow","onHide","onExit","onExited","onExiting","onEnter","onEntering","onEntered"];function E$(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i=0)&&(n[o]=e[o]);return n}let Qc;function k$(e){return Qc||(Qc=new bh({ownerDocument:e==null?void 0:e.document})),Qc}function b$(e){const t=xh(),n=e||k$(t),r=h.useRef({dialog:null,backdrop:null});return Object.assign(r.current,{add:()=>n.add(r.current),remove:()=>n.remove(r.current),isTopModal:()=>n.isTopModal(r.current),setDialogRef:h.useCallback(o=>{r.current.dialog=o},[]),setBackdropRef:h.useCallback(o=>{r.current.backdrop=o},[])})}const wS=h.forwardRef((e,t)=>{let{show:n=!1,role:r="dialog",className:o,style:i,children:s,backdrop:a=!0,keyboard:l=!0,onBackdropClick:u,onEscapeKeyDown:c,transition:d,runTransition:f,backdropTransition:v,runBackdropTransition:g,autoFocus:S=!0,enforceFocus:k=!0,restoreFocus:m=!0,restoreFocusOptions:p,renderDialog:y,renderBackdrop:E=H=>w.jsx("div",Object.assign({},H)),manager:C,container:x,onShow:b,onHide:O=()=>{},onExit:T,onExited:$,onExiting:A,onEnter:U,onEntering:B,onEntered:K}=e,W=E$(e,x$);const G=xh(),V=bd(x),_=b$(C),I=dh(),F=EO(n),[Y,Z]=h.useState(!n),ve=h.useRef(null);h.useImperativeHandle(t,()=>_,[_]),ku&&!F&&n&&(ve.current=Gc(G==null?void 0:G.document)),n&&Y&&Z(!1);const X=it(()=>{if(_.add(),_n.current=Dn(document,"keydown",qe),_t.current=Dn(document,"focus",()=>setTimeout(ge),!0),b&&b(),S){var H,Ue;const nt=Gc((H=(Ue=_.dialog)==null?void 0:Ue.ownerDocument)!=null?H:G==null?void 0:G.document);_.dialog&&nt&&!_s(_.dialog,nt)&&(ve.current=nt,_.dialog.focus())}}),re=it(()=>{if(_.remove(),_n.current==null||_n.current(),_t.current==null||_t.current(),m){var H;(H=ve.current)==null||H.focus==null||H.focus(p),ve.current=null}});h.useEffect(()=>{!n||!V||X()},[n,V,X]),h.useEffect(()=>{Y&&re()},[Y,re]),Kw(()=>{re()});const ge=it(()=>{if(!k||!I()||!_.isTopModal())return;const H=Gc(G==null?void 0:G.document);_.dialog&&H&&!_s(_.dialog,H)&&_.dialog.focus()}),Me=it(H=>{H.target===H.currentTarget&&(u==null||u(H),a===!0&&O())}),qe=it(H=>{l&&gS(H)&&_.isTopModal()&&(c==null||c(H),H.defaultPrevented||O())}),_t=h.useRef(),_n=h.useRef(),Tn=(...H)=>{Z(!0),$==null||$(...H)};if(!V)return null;const Rn=Object.assign({role:r,ref:_.setDialogRef,"aria-modal":r==="dialog"?!0:void 0},W,{style:i,className:o,tabIndex:-1});let Qe=y?y(Rn):w.jsx("div",Object.assign({},Rn,{children:h.cloneElement(s,{role:"document"})}));Qe=Cd(d,f,{unmountOnExit:!0,mountOnEnter:!0,appear:!0,in:!!n,onExit:T,onExiting:A,onExited:Tn,onEnter:U,onEntering:B,onEntered:K,children:Qe});let de=null;return a&&(de=E({ref:_.setBackdropRef,onClick:Me}),de=Cd(v,g,{in:!!n,appear:!0,mountOnEnter:!0,unmountOnExit:!0,children:de})),w.jsx(w.Fragment,{children:Ir.createPortal(w.jsxs(w.Fragment,{children:[de,Qe]}),V)})});wS.displayName="Modal";const C$=Object.assign(wS,{Manager:bh});function Od(e,t){return e.classList?!!t&&e.classList.contains(t):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")!==-1}function O$(e,t){e.classList?e.classList.add(t):Od(e,t)||(typeof e.className=="string"?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}function Zy(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function $$(e,t){e.classList?e.classList.remove(t):typeof e.className=="string"?e.className=Zy(e.className,t):e.setAttribute("class",Zy(e.className&&e.className.baseVal||"",t))}const ao={FIXED_CONTENT:".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",STICKY_CONTENT:".sticky-top",NAVBAR_TOGGLER:".navbar-toggler"};class SS extends bh{adjustAndStore(t,n,r){const o=n.style[t];n.dataset[t]=o,Fn(n,{[t]:`${parseFloat(Fn(n,t))+r}px`})}restore(t,n){const r=n.dataset[t];r!==void 0&&(delete n.dataset[t],Fn(n,{[t]:r}))}setContainerStyle(t){super.setContainerStyle(t);const n=this.getElement();if(O$(n,"modal-open"),!t.scrollBarWidth)return;const r=this.isRTL?"paddingLeft":"paddingRight",o=this.isRTL?"marginLeft":"marginRight";so(n,ao.FIXED_CONTENT).forEach(i=>this.adjustAndStore(r,i,t.scrollBarWidth)),so(n,ao.STICKY_CONTENT).forEach(i=>this.adjustAndStore(o,i,-t.scrollBarWidth)),so(n,ao.NAVBAR_TOGGLER).forEach(i=>this.adjustAndStore(o,i,t.scrollBarWidth))}removeContainerStyle(t){super.removeContainerStyle(t);const n=this.getElement();$$(n,"modal-open");const r=this.isRTL?"paddingLeft":"paddingRight",o=this.isRTL?"marginLeft":"marginRight";so(n,ao.FIXED_CONTENT).forEach(i=>this.restore(r,i)),so(n,ao.STICKY_CONTENT).forEach(i=>this.restore(o,i)),so(n,ao.NAVBAR_TOGGLER).forEach(i=>this.restore(o,i))}}let Yc;function _$(e){return Yc||(Yc=new SS(e)),Yc}const xS=h.createContext({onHide(){}}),T$=h.forwardRef(({closeLabel:e="Close",closeVariant:t,closeButton:n=!1,onHide:r,children:o,...i},s)=>{const a=h.useContext(xS),l=it(()=>{a==null||a.onHide(),r==null||r()});return w.jsxs("div",{ref:s,...i,children:[o,n&&w.jsx(Cu,{"aria-label":e,variant:t,onClick:l})]})}),ES=h.forwardRef(({bsPrefix:e,className:t,as:n,...r},o)=>{e=z(e,"navbar-brand");const i=n||(r.href?"a":"span");return w.jsx(i,{...r,ref:o,className:M(t,e)})});ES.displayName="NavbarBrand";const kS=h.forwardRef(({children:e,bsPrefix:t,...n},r)=>{t=z(t,"navbar-collapse");const o=h.useContext(ci);return w.jsx(bu,{in:!!(o&&o.expanded),...n,children:w.jsx("div",{ref:r,className:t,children:e})})});kS.displayName="NavbarCollapse";const bS=h.forwardRef(({bsPrefix:e,className:t,children:n,label:r="Toggle navigation",as:o="button",onClick:i,...s},a)=>{e=z(e,"navbar-toggler");const{onToggle:l,expanded:u}=h.useContext(ci)||{},c=it(d=>{i&&i(d),l&&l()});return o==="button"&&(s.type="button"),w.jsx(o,{...s,ref:a,onClick:c,"aria-label":r,className:M(t,e,!u&&"collapsed"),children:n||w.jsx("span",{className:`${e}-icon`})})});bS.displayName="NavbarToggle";const $d=new WeakMap,ev=(e,t)=>{if(!e||!t)return;const n=$d.get(t)||new Map;$d.set(t,n);let r=n.get(e);return r||(r=t.matchMedia(e),r.refCount=0,n.set(r.media,r)),r};function R$(e,t=typeof window>"u"?void 0:window){const n=ev(e,t),[r,o]=h.useState(()=>n?n.matches:!1);return Il(()=>{let i=ev(e,t);if(!i)return o(!1);let s=$d.get(t);const a=()=>{o(i.matches)};return i.refCount++,i.addListener(a),a(),()=>{i.removeListener(a),i.refCount--,i.refCount<=0&&(s==null||s.delete(i.media)),i=void 0}},[e]),r}function N$(e){const t=Object.keys(e);function n(a,l){return a===l?l:a?`${a} and ${l}`:l}function r(a){return t[Math.min(t.indexOf(a)+1,t.length-1)]}function o(a){const l=r(a);let u=e[l];return typeof u=="number"?u=`${u-.2}px`:u=`calc(${u} - 0.2px)`,`(max-width: ${u})`}function i(a){let l=e[a];return typeof l=="number"&&(l=`${l}px`),`(min-width: ${l})`}function s(a,l,u){let c;typeof a=="object"?(c=a,u=l,l=!0):(l=l||!0,c={[a]:l});let d=h.useMemo(()=>Object.entries(c).reduce((f,[v,g])=>((g==="up"||g===!0)&&(f=n(f,i(v))),(g==="down"||g===!0)&&(f=n(f,o(v))),f),""),[JSON.stringify(c)]);return R$(d,u)}return s}const A$=N$({xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400}),CS=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"offcanvas-body"),w.jsx(n,{ref:o,className:M(e,t),...r})));CS.displayName="OffcanvasBody";const P$={[Pt]:"show",[In]:"show"},OS=h.forwardRef(({bsPrefix:e,className:t,children:n,in:r=!1,mountOnEnter:o=!1,unmountOnExit:i=!1,appear:s=!1,...a},l)=>(e=z(e,"offcanvas"),w.jsx(ch,{ref:l,addEndListener:uh,in:r,mountOnEnter:o,unmountOnExit:i,appear:s,...a,childRef:n.ref,children:(u,c)=>h.cloneElement(n,{...c,className:M(t,n.props.className,(u===Pt||u===Yo)&&`${e}-toggling`,P$[u])})})));OS.displayName="OffcanvasToggling";const $S=h.forwardRef(({bsPrefix:e,className:t,closeLabel:n="Close",closeButton:r=!1,...o},i)=>(e=z(e,"offcanvas-header"),w.jsx(T$,{ref:i,...o,className:M(t,e),closeLabel:n,closeButton:r})));$S.displayName="OffcanvasHeader";const j$=fh("h5"),_S=h.forwardRef(({className:e,bsPrefix:t,as:n=j$,...r},o)=>(t=z(t,"offcanvas-title"),w.jsx(n,{ref:o,className:M(e,t),...r})));_S.displayName="OffcanvasTitle";function L$(e){return w.jsx(OS,{...e})}function I$(e){return w.jsx(Cs,{...e})}const TS=h.forwardRef(({bsPrefix:e,className:t,children:n,"aria-labelledby":r,placement:o="start",responsive:i,show:s=!1,backdrop:a=!0,keyboard:l=!0,scroll:u=!1,onEscapeKeyDown:c,onShow:d,onHide:f,container:v,autoFocus:g=!0,enforceFocus:S=!0,restoreFocus:k=!0,restoreFocusOptions:m,onEntered:p,onExit:y,onExiting:E,onEnter:C,onEntering:x,onExited:b,backdropClassName:O,manager:T,renderStaticNode:$=!1,...A},U)=>{const B=h.useRef();e=z(e,"offcanvas");const{onToggle:K}=h.useContext(ci)||{},[W,G]=h.useState(!1),V=A$(i||"xs","up");h.useEffect(()=>{G(i?s&&!V:s)},[s,i,V]);const _=it(()=>{K==null||K(),f==null||f()}),I=h.useMemo(()=>({onHide:_}),[_]);function F(){return T||(u?(B.current||(B.current=new SS({handleContainerOverflow:!1})),B.current):_$())}const Y=(re,...ge)=>{re&&(re.style.visibility="visible"),C==null||C(re,...ge)},Z=(re,...ge)=>{re&&(re.style.visibility=""),b==null||b(...ge)},ve=h.useCallback(re=>w.jsx("div",{...re,className:M(`${e}-backdrop`,O)}),[O,e]),X=re=>w.jsx("div",{...re,...A,className:M(t,i?`${e}-${i}`:e,`${e}-${o}`),"aria-labelledby":r,children:n});return w.jsxs(w.Fragment,{children:[!W&&(i||$)&&X({}),w.jsx(xS.Provider,{value:I,children:w.jsx(C$,{show:W,ref:U,backdrop:a,container:v,keyboard:l,autoFocus:g,enforceFocus:S&&!u,restoreFocus:k,restoreFocusOptions:m,onEscapeKeyDown:c,onShow:d,onHide:_,onEnter:Y,onEntering:x,onEntered:p,onExit:y,onExiting:E,onExited:Z,manager:F(),transition:L$,backdropTransition:I$,renderBackdrop:ve,renderDialog:X})})]})});TS.displayName="Offcanvas";const Fi=Object.assign(TS,{Body:CS,Header:$S,Title:_S}),RS=h.forwardRef((e,t)=>{const n=h.useContext(ci);return w.jsx(Fi,{ref:t,show:!!(n!=null&&n.expanded),...e,renderStaticNode:!0})});RS.displayName="NavbarOffcanvas";const NS=h.forwardRef(({className:e,bsPrefix:t,as:n="span",...r},o)=>(t=z(t,"navbar-text"),w.jsx(n,{ref:o,className:M(e,t),...r})));NS.displayName="NavbarText";const AS=h.forwardRef((e,t)=>{const{bsPrefix:n,expand:r=!0,variant:o="light",bg:i,fixed:s,sticky:a,className:l,as:u="nav",expanded:c,onToggle:d,onSelect:f,collapseOnSelect:v=!1,...g}=Hk(e,{expanded:"onToggle"}),S=z(n,"navbar"),k=h.useCallback((...y)=>{f==null||f(...y),v&&c&&(d==null||d(!1))},[f,v,c,d]);g.role===void 0&&u!=="nav"&&(g.role="navigation");let m=`${S}-expand`;typeof r=="string"&&(m=`${m}-${r}`);const p=h.useMemo(()=>({onToggle:()=>d==null?void 0:d(!c),bsPrefix:S,expanded:!!c,expand:r}),[S,c,r,d]);return w.jsx(ci.Provider,{value:p,children:w.jsx(t$.Provider,{value:k,children:w.jsx(u,{ref:t,...g,className:M(l,S,r&&m,o&&`${S}-${o}`,i&&`bg-${i}`,a&&`sticky-${a}`,s&&`fixed-${s}`)})})})});AS.displayName="Navbar";const Xc=Object.assign(AS,{Brand:ES,Collapse:kS,Offcanvas:RS,Text:NS,Toggle:bS}),M$=()=>{};function B$(e,t,{disabled:n,clickTrigger:r}={}){const o=t||M$;X2(e,o,{disabled:n,clickTrigger:r});const i=it(s=>{gS(s)&&o(s)});h.useEffect(()=>{if(n||e==null)return;const s=Is(Ha(e));let a=(s.defaultView||window).event;const l=Dn(s,"keyup",u=>{if(u===a){a=void 0;return}i(u)});return()=>{l()}},[e,n,i])}const PS=h.forwardRef((e,t)=>{const{flip:n,offset:r,placement:o,containerPadding:i,popperConfig:s={},transition:a,runTransition:l}=e,[u,c]=By(),[d,f]=By(),v=Yr(c,t),g=bd(e.container),S=bd(e.target),[k,m]=h.useState(!e.show),p=V2(S,u,e$({placement:o,enableEvents:!!e.show,containerPadding:i||5,flip:n,offset:r,arrowElement:d,popperConfig:s}));e.show&&k&&m(!1);const y=(...A)=>{m(!0),e.onExited&&e.onExited(...A)},E=e.show||!k;if(B$(u,e.onHide,{disabled:!e.rootClose||e.rootCloseDisabled,clickTrigger:e.rootCloseEvent}),!E)return null;const{onExit:C,onExiting:x,onEnter:b,onEntering:O,onEntered:T}=e;let $=e.children(Object.assign({},p.attributes.popper,{style:p.styles.popper,ref:v}),{popper:p,placement:o,show:!!e.show,arrowProps:Object.assign({},p.attributes.arrow,{style:p.styles.arrow,ref:f})});return $=Cd(a,l,{in:!!e.show,appear:!0,mountOnEnter:!0,unmountOnExit:!0,children:$,onExit:C,onExiting:x,onExited:y,onEnter:b,onEntering:O,onEntered:T}),g?Ir.createPortal($,g):null});PS.displayName="Overlay";const jS=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"popover-header"),w.jsx(n,{ref:o,className:M(e,t),...r})));jS.displayName="PopoverHeader";const Ch=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"popover-body"),w.jsx(n,{ref:o,className:M(e,t),...r})));Ch.displayName="PopoverBody";function LS(e,t){let n=e;return e==="left"?n=t?"end":"start":e==="right"&&(n=t?"start":"end"),n}function IS(e="absolute"){return{position:e,top:"0",left:"0",opacity:"0",pointerEvents:"none"}}const D$=h.forwardRef(({bsPrefix:e,placement:t="right",className:n,style:r,children:o,body:i,arrowProps:s,hasDoneInitialMeasure:a,popper:l,show:u,...c},d)=>{const f=z(e,"popover"),v=O0(),[g]=(t==null?void 0:t.split("-"))||[],S=LS(g,v);let k=r;return u&&!a&&(k={...r,...IS(l==null?void 0:l.strategy)}),w.jsxs("div",{ref:d,role:"tooltip",style:k,"x-placement":g,className:M(n,f,g&&`bs-popover-${S}`),...c,children:[w.jsx("div",{className:"popover-arrow",...s}),i?w.jsx(Ch,{children:o}):o]})}),F$=Object.assign(D$,{Header:jS,Body:Ch,POPPER_OFFSET:[0,8]}),MS=h.forwardRef(({bsPrefix:e,placement:t="right",className:n,style:r,children:o,arrowProps:i,hasDoneInitialMeasure:s,popper:a,show:l,...u},c)=>{e=z(e,"tooltip");const d=O0(),[f]=(t==null?void 0:t.split("-"))||[],v=LS(f,d);let g=r;return l&&!s&&(g={...r,...IS(a==null?void 0:a.strategy)}),w.jsxs("div",{ref:c,style:g,role:"tooltip","x-placement":f,className:M(n,e,`bs-tooltip-${v}`),...u,children:[w.jsx("div",{className:"tooltip-arrow",...i}),w.jsx("div",{className:`${e}-inner`,children:o})]})});MS.displayName="Tooltip";const BS=Object.assign(MS,{TOOLTIP_OFFSET:[0,6]});function z$(e){const t=h.useRef(null),n=z(void 0,"popover"),r=z(void 0,"tooltip"),o=h.useMemo(()=>({name:"offset",options:{offset:()=>{if(e)return e;if(t.current){if(Od(t.current,n))return F$.POPPER_OFFSET;if(Od(t.current,r))return BS.TOOLTIP_OFFSET}return[0,0]}}}),[e,n,r]);return[t,[o]]}function U$(e,t){const{ref:n}=e,{ref:r}=t;e.ref=n.__wrapped||(n.__wrapped=o=>n(Ll(o))),t.ref=r.__wrapped||(r.__wrapped=o=>r(Ll(o)))}const DS=h.forwardRef(({children:e,transition:t=Cs,popperConfig:n={},rootClose:r=!1,placement:o="top",show:i=!1,...s},a)=>{const l=h.useRef({}),[u,c]=h.useState(null),[d,f]=z$(s.offset),v=Yr(a,d),g=t===!0?Cs:t||void 0,S=it(k=>{c(k),n==null||n.onFirstUpdate==null||n.onFirstUpdate(k)});return Il(()=>{u&&s.target&&(l.current.scheduleUpdate==null||l.current.scheduleUpdate())},[u,s.target]),h.useEffect(()=>{i||c(null)},[i]),w.jsx(PS,{...s,ref:v,popperConfig:{...n,modifiers:f.concat(n.modifiers||[]),onFirstUpdate:S},transition:g,rootClose:r,placement:o,show:i,children:(k,{arrowProps:m,popper:p,show:y})=>{var E;U$(k,m);const C=p==null?void 0:p.placement,x=Object.assign(l.current,{state:p==null?void 0:p.state,scheduleUpdate:p==null?void 0:p.update,placement:C,outOfBoundaries:(p==null||(E=p.state)==null||(E=E.modifiersData.hide)==null?void 0:E.isReferenceHidden)||!1,strategy:n.strategy}),b=!!u;return typeof e=="function"?e({...k,placement:C,show:y,...!t&&y&&{className:"show"},popper:x,arrowProps:m,hasDoneInitialMeasure:b}):h.cloneElement(e,{...k,placement:C,arrowProps:m,popper:x,hasDoneInitialMeasure:b,className:M(e.props.className,!t&&y&&"show"),style:{...e.props.style,...k.style}})}})});DS.displayName="Overlay";function W$(e){return e&&typeof e=="object"?e:{show:e,hide:e}}function tv(e,t,n){const[r]=t,o=r.currentTarget,i=r.relatedTarget||r.nativeEvent[n];(!i||i!==o)&&!_s(o,i)&&e(...t)}pe.oneOf(["click","hover","focus"]);const H$=({trigger:e=["hover","focus"],overlay:t,children:n,popperConfig:r={},show:o,defaultShow:i=!1,onToggle:s,delay:a,placement:l,flip:u=l&&l.indexOf("auto")!==-1,...c})=>{const d=h.useRef(null),f=Yr(d,n.ref),v=qw(),g=h.useRef(""),[S,k]=k0(o,i,s),m=W$(a),{onFocus:p,onBlur:y,onClick:E}=typeof n!="function"?h.Children.only(n).props:{},C=W=>{f(Ll(W))},x=h.useCallback(()=>{if(v.clear(),g.current="show",!m.show){k(!0);return}v.set(()=>{g.current==="show"&&k(!0)},m.show)},[m.show,k,v]),b=h.useCallback(()=>{if(v.clear(),g.current="hide",!m.hide){k(!1);return}v.set(()=>{g.current==="hide"&&k(!1)},m.hide)},[m.hide,k,v]),O=h.useCallback((...W)=>{x(),p==null||p(...W)},[x,p]),T=h.useCallback((...W)=>{b(),y==null||y(...W)},[b,y]),$=h.useCallback((...W)=>{k(!S),E==null||E(...W)},[E,k,S]),A=h.useCallback((...W)=>{tv(x,W,"fromElement")},[x]),U=h.useCallback((...W)=>{tv(b,W,"toElement")},[b]),B=e==null?[]:[].concat(e),K={ref:C};return B.indexOf("click")!==-1&&(K.onClick=$),B.indexOf("focus")!==-1&&(K.onFocus=O,K.onBlur=T),B.indexOf("hover")!==-1&&(K.onMouseOver=A,K.onMouseOut=U),w.jsxs(w.Fragment,{children:[typeof n=="function"?n(K):h.cloneElement(n,K),w.jsx(DS,{...c,show:S,onHide:b,flip:u,placement:l,popperConfig:r,target:d.current,children:t})]})},Fl=h.forwardRef(({bsPrefix:e,className:t,as:n="div",...r},o)=>{const i=z(e,"row"),s=b0(),a=C0(),l=`${i}-cols`,u=[];return s.forEach(c=>{const d=r[c];delete r[c];let f;d!=null&&typeof d=="object"?{cols:f}=d:f=d;const v=c!==a?`-${c}`:"";f!=null&&u.push(`${l}${v}-${f}`)}),w.jsx(n,{ref:o,...r,className:M(t,i,...u)})});Fl.displayName="Row";const FS=h.forwardRef(({bsPrefix:e,variant:t,animation:n="border",size:r,as:o="div",className:i,...s},a)=>{e=z(e,"spinner");const l=`${e}-${n}`;return w.jsx(o,{ref:a,...s,className:M(i,l,r&&`${l}-${r}`,t&&`text-${t}`)})});FS.displayName="Spinner";const V$={[Pt]:"showing",[Yo]:"showing show"},zS=h.forwardRef((e,t)=>w.jsx(Cs,{...e,ref:t,transitionClasses:V$}));zS.displayName="ToastFade";const US=h.createContext({onClose(){}}),WS=h.forwardRef(({bsPrefix:e,closeLabel:t="Close",closeVariant:n,closeButton:r=!0,className:o,children:i,...s},a)=>{e=z(e,"toast-header");const l=h.useContext(US),u=it(c=>{l==null||l.onClose==null||l.onClose(c)});return w.jsxs("div",{ref:a,...s,className:M(e,o),children:[i,r&&w.jsx(Cu,{"aria-label":t,variant:n,onClick:u,"data-dismiss":"toast"})]})});WS.displayName="ToastHeader";const HS=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"toast-body"),w.jsx(n,{ref:o,className:M(e,t),...r})));HS.displayName="ToastBody";const VS=h.forwardRef(({bsPrefix:e,className:t,transition:n=zS,show:r=!0,animation:o=!0,delay:i=5e3,autohide:s=!1,onClose:a,onEntered:l,onExit:u,onExiting:c,onEnter:d,onEntering:f,onExited:v,bg:g,...S},k)=>{e=z(e,"toast");const m=h.useRef(i),p=h.useRef(a);h.useEffect(()=>{m.current=i,p.current=a},[i,a]);const y=qw(),E=!!(s&&r),C=h.useCallback(()=>{E&&(p.current==null||p.current())},[E]);h.useEffect(()=>{y.set(C,m.current)},[y,C]);const x=h.useMemo(()=>({onClose:a}),[a]),b=!!(n&&o),O=w.jsx("div",{...S,ref:k,className:M(e,t,g&&`bg-${g}`,!b&&(r?"show":"hide")),role:"alert","aria-live":"assertive","aria-atomic":"true"});return w.jsx(US.Provider,{value:x,children:b&&n?w.jsx(n,{in:r,onEnter:d,onEntering:f,onEntered:l,onExit:u,onExiting:c,onExited:v,unmountOnExit:!0,children:O}):O})});VS.displayName="Toast";const ns=Object.assign(VS,{Body:HS,Header:WS}),K$={"top-start":"top-0 start-0","top-center":"top-0 start-50 translate-middle-x","top-end":"top-0 end-0","middle-start":"top-50 start-0 translate-middle-y","middle-center":"top-50 start-50 translate-middle","middle-end":"top-50 end-0 translate-middle-y","bottom-start":"bottom-0 start-0","bottom-center":"bottom-0 start-50 translate-middle-x","bottom-end":"bottom-0 end-0"},Oh=h.forwardRef(({bsPrefix:e,position:t,containerPosition:n,className:r,as:o="div",...i},s)=>(e=z(e,"toast-container"),w.jsx(o,{ref:s,...i,className:M(e,t&&K$[t],n&&`position-${n}`,r)})));Oh.displayName="ToastContainer";const G$=()=>{},$h=h.forwardRef(({bsPrefix:e,name:t,className:n,checked:r,type:o,onChange:i,value:s,disabled:a,id:l,inputRef:u,...c},d)=>(e=z(e,"btn-check"),w.jsxs(w.Fragment,{children:[w.jsx("input",{className:e,name:t,type:o,value:s,ref:u,autoComplete:"off",checked:!!r,disabled:!!a,onChange:i||G$,id:l}),w.jsx(zs,{...c,ref:d,className:M(n,a&&"disabled"),type:void 0,role:void 0,as:"label",htmlFor:l})]})));$h.displayName="ToggleButton";const bn=Object.create(null);bn.open="0";bn.close="1";bn.ping="2";bn.pong="3";bn.message="4";bn.upgrade="5";bn.noop="6";const Va=Object.create(null);Object.keys(bn).forEach(e=>{Va[bn[e]]=e});const _d={type:"error",data:"parser error"},KS=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",GS=typeof ArrayBuffer=="function",qS=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,_h=({type:e,data:t},n,r)=>KS&&t instanceof Blob?n?r(t):nv(t,r):GS&&(t instanceof ArrayBuffer||qS(t))?n?r(t):nv(new Blob([t]),r):r(bn[e]+(t||"")),nv=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function rv(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let Jc;function q$(e,t){if(KS&&e.data instanceof Blob)return e.data.arrayBuffer().then(rv).then(t);if(GS&&(e.data instanceof ArrayBuffer||qS(e.data)))return t(rv(e.data));_h(e,!1,n=>{Jc||(Jc=new TextEncoder),t(Jc.encode(n))})}const ov="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",zi=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let e=0;e{let t=e.length*.75,n=e.length,r,o=0,i,s,a,l;e[e.length-1]==="="&&(t--,e[e.length-2]==="="&&t--);const u=new ArrayBuffer(t),c=new Uint8Array(u);for(r=0;r>4,c[o++]=(s&15)<<4|a>>2,c[o++]=(a&3)<<6|l&63;return u},Y$=typeof ArrayBuffer=="function",Th=(e,t)=>{if(typeof e!="string")return{type:"message",data:QS(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:X$(e.substring(1),t)}:Va[n]?e.length>1?{type:Va[n],data:e.substring(1)}:{type:Va[n]}:_d},X$=(e,t)=>{if(Y$){const n=Q$(e);return QS(n,t)}else return{base64:!0,data:e}},QS=(e,t)=>{switch(t){case"blob":return e instanceof Blob?e:new Blob([e]);case"arraybuffer":default:return e instanceof ArrayBuffer?e:e.buffer}},YS="",J$=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((i,s)=>{_h(i,!1,a=>{r[s]=a,++o===n&&t(r.join(YS))})})},Z$=(e,t)=>{const n=e.split(YS),r=[];for(let o=0;o{const r=n.length;let o;if(r<126)o=new Uint8Array(1),new DataView(o.buffer).setUint8(0,r);else if(r<65536){o=new Uint8Array(3);const i=new DataView(o.buffer);i.setUint8(0,126),i.setUint16(1,r)}else{o=new Uint8Array(9);const i=new DataView(o.buffer);i.setUint8(0,127),i.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(o[0]|=128),t.enqueue(o),t.enqueue(n)})}})}let Zc;function va(e){return e.reduce((t,n)=>t+n.length,0)}function ga(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let o=0;oMath.pow(2,21)-1){a.enqueue(_d);break}o=c*Math.pow(2,32)+u.getUint32(4),r=3}else{if(va(n)e){a.enqueue(_d);break}}}})}const XS=4;function je(e){if(e)return n_(e)}function n_(e){for(var t in je.prototype)e[t]=je.prototype[t];return e}je.prototype.on=je.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this};je.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this};je.prototype.off=je.prototype.removeListener=je.prototype.removeAllListeners=je.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks["$"+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var r,o=0;o(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const r_=jt.setTimeout,o_=jt.clearTimeout;function Tu(e,t){t.useNativeTimers?(e.setTimeoutFn=r_.bind(jt),e.clearTimeoutFn=o_.bind(jt)):(e.setTimeoutFn=jt.setTimeout.bind(jt),e.clearTimeoutFn=jt.clearTimeout.bind(jt))}const i_=1.33;function s_(e){return typeof e=="string"?a_(e):Math.ceil((e.byteLength||e.size)*i_)}function a_(e){let t=0,n=0;for(let r=0,o=e.length;r=57344?n+=3:(r++,n+=4);return n}function l_(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function u_(e){let t={},n=e.split("&");for(let r=0,o=n.length;r0);return t}function ex(){const e=av(+new Date);return e!==sv?(iv=0,sv=e):e+"."+av(iv++)}for(;wa{this.readyState="paused",t()};if(this.polling||!this.writable){let r=0;this.polling&&(r++,this.once("pollComplete",function(){--r||n()})),this.writable||(r++,this.once("drain",function(){--r||n()}))}else n()}poll(){this.polling=!0,this.doPoll(),this.emitReserved("poll")}onData(t){const n=r=>{if(this.readyState==="opening"&&r.type==="open"&&this.onOpen(),r.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(r)};Z$(t,this.socket.binaryType).forEach(n),this.readyState!=="closed"&&(this.polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this.poll())}doClose(){const t=()=>{this.write([{type:"close"}])};this.readyState==="open"?t():this.once("open",t)}write(t){this.writable=!1,J$(t,n=>{this.doWrite(n,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const t=this.opts.secure?"https":"http",n=this.query||{};return this.opts.timestampRequests!==!1&&(n[this.opts.timestampParam]=ex()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}request(t={}){return Object.assign(t,{xd:this.xd,cookieJar:this.cookieJar},this.opts),new xn(this.uri(),t)}doWrite(t,n){const r=this.request({method:"POST",data:t});r.on("success",n),r.on("error",(o,i)=>{this.onError("xhr post error",o,i)})}doPoll(){const t=this.request();t.on("data",this.onData.bind(this)),t.on("error",(n,r)=>{this.onError("xhr poll error",n,r)}),this.pollXhr=t}}class xn extends je{constructor(t,n){super(),Tu(this,n),this.opts=n,this.method=n.method||"GET",this.uri=t,this.data=n.data!==void 0?n.data:null,this.create()}create(){var t;const n=JS(this.opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this.opts.xd;const r=this.xhr=new nx(n);try{r.open(this.method,this.uri,!0);try{if(this.opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let o in this.opts.extraHeaders)this.opts.extraHeaders.hasOwnProperty(o)&&r.setRequestHeader(o,this.opts.extraHeaders[o])}}catch{}if(this.method==="POST")try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{r.setRequestHeader("Accept","*/*")}catch{}(t=this.opts.cookieJar)===null||t===void 0||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this.opts.withCredentials),this.opts.requestTimeout&&(r.timeout=this.opts.requestTimeout),r.onreadystatechange=()=>{var o;r.readyState===3&&((o=this.opts.cookieJar)===null||o===void 0||o.parseCookies(r)),r.readyState===4&&(r.status===200||r.status===1223?this.onLoad():this.setTimeoutFn(()=>{this.onError(typeof r.status=="number"?r.status:0)},0))},r.send(this.data)}catch(o){this.setTimeoutFn(()=>{this.onError(o)},0);return}typeof document<"u"&&(this.index=xn.requestsCount++,xn.requests[this.index]=this)}onError(t){this.emitReserved("error",t,this.xhr),this.cleanup(!0)}cleanup(t){if(!(typeof this.xhr>"u"||this.xhr===null)){if(this.xhr.onreadystatechange=p_,t)try{this.xhr.abort()}catch{}typeof document<"u"&&delete xn.requests[this.index],this.xhr=null}}onLoad(){const t=this.xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this.cleanup())}abort(){this.cleanup()}}xn.requestsCount=0;xn.requests={};if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",lv);else if(typeof addEventListener=="function"){const e="onpagehide"in jt?"pagehide":"unload";addEventListener(e,lv,!1)}}function lv(){for(let e in xn.requests)xn.requests.hasOwnProperty(e)&&xn.requests[e].abort()}const Nh=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),Sa=jt.WebSocket||jt.MozWebSocket,uv=!0,y_="arraybuffer",cv=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class v_ extends Rh{constructor(t){super(t),this.supportsBinary=!t.forceBase64}get name(){return"websocket"}doOpen(){if(!this.check())return;const t=this.uri(),n=this.opts.protocols,r=cv?{}:JS(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(r.headers=this.opts.extraHeaders);try{this.ws=uv&&!cv?n?new Sa(t,n):new Sa(t):new Sa(t,n,r)}catch(o){return this.emitReserved("error",o)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=t=>this.onClose({description:"websocket connection closed",context:t}),this.ws.onmessage=t=>this.onData(t.data),this.ws.onerror=t=>this.onError("websocket error",t)}write(t){this.writable=!1;for(let n=0;n{const s={};try{uv&&this.ws.send(i)}catch{}o&&Nh(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.close(),this.ws=null)}uri(){const t=this.opts.secure?"wss":"ws",n=this.query||{};return this.opts.timestampRequests&&(n[this.opts.timestampParam]=ex()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}check(){return!!Sa}}class g_ extends Rh{get name(){return"webtransport"}doOpen(){typeof WebTransport=="function"&&(this.transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name]),this.transport.closed.then(()=>{this.onClose()}).catch(t=>{this.onError("webtransport error",t)}),this.transport.ready.then(()=>{this.transport.createBidirectionalStream().then(t=>{const n=t_(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=e_();o.readable.pipeTo(t.writable),this.writer=o.writable.getWriter();const i=()=>{r.read().then(({done:a,value:l})=>{a||(this.onPacket(l),i())}).catch(a=>{})};i();const s={type:"open"};this.query.sid&&(s.data=`{"sid":"${this.query.sid}"}`),this.writer.write(s).then(()=>this.onOpen())})}))}write(t){this.writable=!1;for(let n=0;n{o&&Nh(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this.transport)===null||t===void 0||t.close()}}const w_={websocket:v_,webtransport:g_,polling:m_},S_=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,x_=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Rd(e){if(e.length>2e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let o=S_.exec(e||""),i={},s=14;for(;s--;)i[x_[s]]=o[s]||"";return n!=-1&&r!=-1&&(i.source=t,i.host=i.host.substring(1,i.host.length-1).replace(/;/g,":"),i.authority=i.authority.replace("[","").replace("]","").replace(/;/g,":"),i.ipv6uri=!0),i.pathNames=E_(i,i.path),i.queryKey=k_(i,i.query),i}function E_(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");return(t.slice(0,1)=="/"||t.length===0)&&r.splice(0,1),t.slice(-1)=="/"&&r.splice(r.length-1,1),r}function k_(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,i){o&&(n[o]=i)}),n}let rx=class vo extends je{constructor(t,n={}){super(),this.binaryType=y_,this.writeBuffer=[],t&&typeof t=="object"&&(n=t,t=null),t?(t=Rd(t),n.hostname=t.host,n.secure=t.protocol==="https"||t.protocol==="wss",n.port=t.port,t.query&&(n.query=t.query)):n.host&&(n.hostname=Rd(n.host).host),Tu(this,n),this.secure=n.secure!=null?n.secure:typeof location<"u"&&location.protocol==="https:",n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.hostname=n.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=n.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=n.transports||["polling","websocket","webtransport"],this.writeBuffer=[],this.prevBufferLen=0,this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},n),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=u_(this.opts.query)),this.id=null,this.upgrades=null,this.pingInterval=null,this.pingTimeout=null,this.pingTimeoutTimer=null,typeof addEventListener=="function"&&(this.opts.closeOnBeforeunload&&(this.beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this.beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this.offlineEventListener=()=>{this.onClose("transport close",{description:"network connection lost"})},addEventListener("offline",this.offlineEventListener,!1))),this.open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=XS,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new w_[t](r)}open(){let t;if(this.opts.rememberUpgrade&&vo.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1)t="websocket";else if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}else t=this.transports[0];this.readyState="opening";try{t=this.createTransport(t)}catch{this.transports.shift(),this.open();return}t.open(),this.setTransport(t)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this.onDrain.bind(this)).on("packet",this.onPacket.bind(this)).on("error",this.onError.bind(this)).on("close",n=>this.onClose("transport close",n))}probe(t){let n=this.createTransport(t),r=!1;vo.priorWebsocketSuccess=!1;const o=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",d=>{if(!r)if(d.type==="pong"&&d.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;vo.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(c(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const f=new Error("probe error");f.transport=n.name,this.emitReserved("upgradeError",f)}}))};function i(){r||(r=!0,c(),n.close(),n=null)}const s=d=>{const f=new Error("probe error: "+d);f.transport=n.name,i(),this.emitReserved("upgradeError",f)};function a(){s("transport closed")}function l(){s("socket closed")}function u(d){n&&d.name!==n.name&&i()}const c=()=>{n.removeListener("open",o),n.removeListener("error",s),n.removeListener("close",a),this.off("close",l),this.off("upgrading",u)};n.once("open",o),n.once("error",s),n.once("close",a),this.once("close",l),this.once("upgrading",u),this.upgrades.indexOf("webtransport")!==-1&&t!=="webtransport"?this.setTimeoutFn(()=>{r||n.open()},200):n.open()}onOpen(){if(this.readyState="open",vo.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush(),this.readyState==="open"&&this.opts.upgrade){let t=0;const n=this.upgrades.length;for(;t{this.onClose("ping timeout")},this.pingInterval+this.pingTimeout),this.opts.autoUnref&&this.pingTimeoutTimer.unref()}onDrain(){this.writeBuffer.splice(0,this.prevBufferLen),this.prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this.getWritablePackets();this.transport.send(t),this.prevBufferLen=t.length,this.emitReserved("flush")}}getWritablePackets(){if(!(this.maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r0&&n>this.maxPayload)return this.writeBuffer.slice(0,r);n+=2}return this.writeBuffer}write(t,n,r){return this.sendPacket("message",t,n,r),this}send(t,n,r){return this.sendPacket("message",t,n,r),this}sendPacket(t,n,r,o){if(typeof n=="function"&&(o=n,n=void 0),typeof r=="function"&&(o=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const i={type:t,data:n,options:r};this.emitReserved("packetCreate",i),this.writeBuffer.push(i),o&&this.once("flush",o),this.flush()}close(){const t=()=>{this.onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}onError(t){vo.priorWebsocketSuccess=!1,this.emitReserved("error",t),this.onClose("transport error",t)}onClose(t,n){(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")&&(this.clearTimeoutFn(this.pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),typeof removeEventListener=="function"&&(removeEventListener("beforeunload",this.beforeunloadEventListener,!1),removeEventListener("offline",this.offlineEventListener,!1)),this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this.prevBufferLen=0)}filterUpgrades(t){const n=[];let r=0;const o=t.length;for(;rtypeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,ox=Object.prototype.toString,$_=typeof Blob=="function"||typeof Blob<"u"&&ox.call(Blob)==="[object BlobConstructor]",__=typeof File=="function"||typeof File<"u"&&ox.call(File)==="[object FileConstructor]";function Ah(e){return C_&&(e instanceof ArrayBuffer||O_(e))||$_&&e instanceof Blob||__&&e instanceof File}function Ka(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n=0&&e.num{delete this.acks[t];for(let a=0;a{this.io.clearTimeoutFn(i),n.apply(this,a)};s.withError=!0,this.acks[t]=s}emitWithAck(t,...n){return new Promise((r,o)=>{const i=(s,a)=>s?o(s):r(a);i.withError=!0,n.push(i),this.emit(t,...n)})}_addToQueue(t){let n;typeof t[t.length-1]=="function"&&(n=t.pop());const r={id:this._queueSeq++,tryCount:0,pending:!1,args:t,flags:Object.assign({fromQueue:!0},this.flags)};t.push((o,...i)=>r!==this._queue[0]?void 0:(o!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(o)):(this._queue.shift(),n&&n(null,...i)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type:J.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},t):t})}onerror(t){this.connected||this.emitReserved("connect_error",t)}onclose(t,n){this.connected=!1,delete this.id,this.emitReserved("disconnect",t,n),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(t=>{if(!this.sendBuffer.some(r=>String(r.id)===t)){const r=this.acks[t];delete this.acks[t],r.withError&&r.call(this,new Error("socket has been disconnected"))}})}onpacket(t){if(t.nsp===this.nsp)switch(t.type){case J.CONNECT:t.data&&t.data.sid?this.onconnect(t.data.sid,t.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case J.EVENT:case J.BINARY_EVENT:this.onevent(t);break;case J.ACK:case J.BINARY_ACK:this.onack(t);break;case J.DISCONNECT:this.ondisconnect();break;case J.CONNECT_ERROR:this.destroy();const r=new Error(t.data.message);r.data=t.data.data,this.emitReserved("connect_error",r);break}}onevent(t){const n=t.data||[];t.id!=null&&n.push(this.ack(t.id)),this.connected?this.emitEvent(n):this.receiveBuffer.push(Object.freeze(n))}emitEvent(t){if(this._anyListeners&&this._anyListeners.length){const n=this._anyListeners.slice();for(const r of n)r.apply(this,t)}super.emit.apply(this,t),this._pid&&t.length&&typeof t[t.length-1]=="string"&&(this._lastOffset=t[t.length-1])}ack(t){const n=this;let r=!1;return function(...o){r||(r=!0,n.packet({type:J.ACK,id:t,data:o}))}}onack(t){const n=this.acks[t.id];typeof n=="function"&&(delete this.acks[t.id],n.withError&&t.data.unshift(null),n.apply(this,t.data))}onconnect(t,n){this.id=t,this.recovered=n&&this._pid===n,this._pid=n,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:J.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(t){return this.flags.compress=t,this}get volatile(){return this.flags.volatile=!0,this}timeout(t){return this.flags.timeout=t,this}onAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(t),this}prependAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(t),this}offAny(t){if(!this._anyListeners)return this;if(t){const n=this._anyListeners;for(let r=0;r0&&e.jitter<=1?e.jitter:0,this.attempts=0}fi.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=Math.floor(t*10)&1?e+n:e-n}return Math.min(e,this.max)|0};fi.prototype.reset=function(){this.attempts=0};fi.prototype.setMin=function(e){this.ms=e};fi.prototype.setMax=function(e){this.max=e};fi.prototype.setJitter=function(e){this.jitter=e};class Pd extends je{constructor(t,n){var r;super(),this.nsps={},this.subs=[],t&&typeof t=="object"&&(n=t,t=void 0),n=n||{},n.path=n.path||"/socket.io",this.opts=n,Tu(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new fi({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const o=n.parser||L_;this.encoder=new o.Encoder,this.decoder=new o.Decoder,this._autoConnect=n.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(t){return arguments.length?(this._reconnection=!!t,this):this._reconnection}reconnectionAttempts(t){return t===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=t,this)}reconnectionDelay(t){var n;return t===void 0?this._reconnectionDelay:(this._reconnectionDelay=t,(n=this.backoff)===null||n===void 0||n.setMin(t),this)}randomizationFactor(t){var n;return t===void 0?this._randomizationFactor:(this._randomizationFactor=t,(n=this.backoff)===null||n===void 0||n.setJitter(t),this)}reconnectionDelayMax(t){var n;return t===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=t,(n=this.backoff)===null||n===void 0||n.setMax(t),this)}timeout(t){return arguments.length?(this._timeout=t,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(t){if(~this._readyState.indexOf("open"))return this;this.engine=new rx(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const o=Zt(n,"open",function(){r.onopen(),t&&t()}),i=a=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",a),t?t(a):this.maybeReconnectOnOpen()},s=Zt(n,"error",i);if(this._timeout!==!1){const a=this._timeout,l=this.setTimeoutFn(()=>{o(),i(new Error("timeout")),n.close()},a);this.opts.autoUnref&&l.unref(),this.subs.push(()=>{this.clearTimeoutFn(l)})}return this.subs.push(o),this.subs.push(s),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(Zt(t,"ping",this.onping.bind(this)),Zt(t,"data",this.ondata.bind(this)),Zt(t,"error",this.onerror.bind(this)),Zt(t,"close",this.onclose.bind(this)),Zt(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(t){try{this.decoder.add(t)}catch(n){this.onclose("parse error",n)}}ondecoded(t){Nh(()=>{this.emitReserved("packet",t)},this.setTimeoutFn)}onerror(t){this.emitReserved("error",t)}socket(t,n){let r=this.nsps[t];return r?this._autoConnect&&!r.active&&r.connect():(r=new ix(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;rt()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close"),this.engine&&this.engine.close()}disconnect(){return this._close()}onclose(t,n){this.cleanup(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(o=>{o?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",o)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const Ti={};function Ga(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=b_(e,t.path||"/socket.io"),r=n.source,o=n.id,i=n.path,s=Ti[o]&&i in Ti[o].nsps,a=t.forceNew||t["force new connection"]||t.multiplex===!1||s;let l;return a?l=new Pd(r,t):(Ti[o]||(Ti[o]=new Pd(r,t)),l=Ti[o]),n.query&&!t.query&&(t.query=n.queryKey),l.socket(n.path,t)}Object.assign(Ga,{Manager:Pd,Socket:ix,io:Ga,connect:Ga});const sx=(e,t)=>{if(typeof e=="number")return{full_access_path:t,doc:null,readonly:!1,type:Number.isInteger(e)?"int":"float",value:e};if(typeof e=="boolean")return{full_access_path:t,doc:null,readonly:!1,type:"bool",value:e};if(typeof e=="string")return{full_access_path:t,doc:null,readonly:!1,type:"str",value:e};if(e===null)return{full_access_path:t,doc:null,readonly:!1,type:"None",value:null};throw new Error("Unsupported type for serialization")},M_=(e,t="")=>{const r=e.map((o,i)=>{(typeof o=="number"||typeof o=="boolean"||typeof o=="string"||o===null)&&sx(o,`${t}[${i}]`)});return{full_access_path:t,type:"list",value:r,readonly:!1,doc:null}},B_=(e,t="")=>{const r=Object.entries(e).reduce((o,[i,s])=>{const a=`${t}["${i}"]`;return(typeof s=="number"||typeof s=="boolean"||typeof s=="string"||s===null)&&(o[i]=sx(s,a)),o},{});return{full_access_path:t,type:"dict",value:r,readonly:!1,doc:null}},Ui=window.location.hostname,Wi=window.location.port,D_=`ws://${Ui}:${Wi}/`,Ln=Ga(D_,{path:"/ws/socket.io",transports:["websocket"]}),F_=(e,t)=>{t?Ln.emit("update_value",{access_path:e.full_access_path,value:e},t):Ln.emit("update_value",{access_path:e.full_access_path,value:e})},ax=(e,t=[],n={},r)=>{const o=M_(t),i=B_(n);Ln.emit("trigger_method",{access_path:e,args:o,kwargs:i})},lx=ne.memo(e=>{const{showNotification:t,notifications:n,removeNotificationById:r}=e;return w.jsx(Oh,{className:"navbarOffset toastContainer",position:"top-end",children:n.map(o=>o.levelname==="ERROR"||o.levelname==="CRITICAL"||t&&["WARNING","INFO","DEBUG"].includes(o.levelname)?w.jsxs(ns,{className:o.levelname.toLowerCase()+"Toast",onClose:()=>r(o.id),onClick:()=>r(o.id),onMouseLeave:()=>{o.levelname!=="ERROR"&&r(o.id)},show:!0,autohide:o.levelname==="WARNING"||o.levelname==="INFO"||o.levelname==="DEBUG",delay:o.levelname==="WARNING"||o.levelname==="INFO"||o.levelname==="DEBUG"?2e3:void 0,children:[w.jsxs(ns.Header,{closeButton:!1,className:o.levelname.toLowerCase()+"Toast text-right",children:[w.jsx("strong",{className:"me-auto",children:o.levelname}),w.jsx("small",{children:o.timeStamp})]}),w.jsx(ns.Body,{children:o.message})]},o.id):null)})});lx.displayName="Notifications";const jd=ne.memo(({connectionStatus:e})=>{const[t,n]=h.useState(!0);h.useEffect(()=>{n(!0)},[e]);const r=()=>n(!1),o=()=>{switch(e){case"connecting":return{message:"Connecting...",bg:"info",delay:void 0};case"connected":return{message:"Connected",bg:"success",delay:1e3};case"disconnected":return{message:"Disconnected",bg:"danger",delay:void 0};case"reconnecting":return{message:"Reconnecting...",bg:"info",delay:void 0};default:return{message:"",bg:"info",delay:void 0}}},{message:i,bg:s,delay:a}=o();return w.jsx(Oh,{position:"bottom-center",className:"toastContainer",children:w.jsx(ns,{show:t,onClose:r,delay:a,autohide:a!==void 0,bg:s,children:w.jsxs(ns.Body,{className:"d-flex justify-content-between",children:[i,w.jsx(zs,{variant:"close",size:"sm",onClick:r})]})})})});jd.displayName="ConnectionToast";function ux(e){const t=/\w+|\[\d+\.\d+\]|\[\d+\]|\["[^"]*"\]|\['[^']*'\]/g;return e.match(t)??[]}function z_(e){if(e.startsWith("[")&&e.endsWith("]")&&(e=e.slice(1,-1)),e.startsWith("'")&&e.endsWith("'")||e.startsWith('"')&&e.endsWith('"'))return e.slice(1,-1);const t=parseFloat(e);return isNaN(t)?e:t}function U_(e,t,n){if(t in e)return e[t];if(Array.isArray(e)){if(n&&t===e.length)return e.push(pv()),e[t];throw new Error(`Index out of bounds: ${t}`)}else{if(n)return e[t]=pv(),e[t];throw new Error(`Key not found: ${t}`)}}function dv(e,t,n=!1){const r=z_(t);try{return U_(e,r,n)}catch(o){throw o instanceof RangeError?new Error(`Index '${r}': ${o.message}`):o instanceof Error?new Error(`Key '${r}': ${o.message}`):o}}function W_(e,t,n){const r=ux(t),o=JSON.parse(JSON.stringify(e));let i=o;try{for(let l=0;l{const{docString:t}=e;if(!t)return null;const n=w.jsx(BS,{id:"tooltip",children:t});return w.jsx(H$,{placement:"bottom",overlay:n,children:w.jsx(Lw,{pill:!0,className:"tooltip-trigger",bg:"light",text:"dark",children:"?"})})});ln.displayName="DocStringComponent";function Cn(){const e=h.useRef(0);return h.useEffect(()=>{e.current+=1}),e.current}const cx=ne.memo(e=>{const{value:t,fullAccessPath:n,readOnly:r,docString:o,addNotification:i,changeCallback:s=()=>{},displayName:a,id:l}=e;Cn(),h.useEffect(()=>{i(`${n} changed to ${t}.`)},[e.value]);const u=c=>{s({type:"bool",value:c,full_access_path:n,readonly:r,doc:o})};return w.jsxs("div",{className:"component buttonComponent",id:l,children:[!1,w.jsxs($h,{id:`toggle-check-${l}`,type:"checkbox",variant:t?"success":"secondary",checked:t,value:a,disabled:r,onChange:c=>u(c.currentTarget.checked),children:[a,w.jsx(ln,{docString:o})]})]})});cx.displayName="ButtonComponent";const H_=(e,t,n)=>{const r=t.split("."),o=r[0].length,i=r[1]?r[1].length:0,s=n>o;let a=0;s?a=Math.pow(10,o+1-n):a=Math.pow(10,o-n);const u=(parseFloat(t)+(e==="ArrowUp"?a:-a)).toFixed(i),c=u.split(".")[0].length;return c>o?n+=1:cn>t?{value:e.slice(0,t)+e.slice(n),selectionStart:t}:t>0?{value:e.slice(0,t-1)+e.slice(t),selectionStart:t-1}:{value:e,selectionStart:t},K_=(e,t,n)=>n>t?{value:e.slice(0,t)+e.slice(n),selectionStart:t}:t{if(e==="."&&t.includes("."))return{value:t,selectionStart:n};let o=t;return r>n?o=t.slice(0,n)+e+t.slice(r):o=t.slice(0,n)+e+t.slice(n),{value:o,selectionStart:n+1}},zl=ne.memo(e=>{const{fullAccessPath:t,value:n,readOnly:r,type:o,docString:i,isInstantUpdate:s,unit:a,addNotification:l,changeCallback:u=()=>{},displayName:c,id:d}=e,[f,v]=h.useState(null),[g,S]=h.useState(n.toString());Cn();const k=p=>{const{key:y,target:E}=p,C=E;if(y==="F1"||y==="F5"||y==="F12"||y==="Tab"||y==="ArrowRight"||y==="ArrowLeft")return;p.preventDefault();const{value:x}=C,b=C.selectionEnd??0;let O=C.selectionStart??0,T=x;if(p.ctrlKey&&y==="a"){C.setSelectionRange(0,x.length);return}else if(y==="-")if(O===0&&!x.startsWith("-"))T="-"+x,O++;else if(x.startsWith("-")&&O===1)T=x.substring(1),O--;else return;else if(y>="0"&&y<="9")({value:T,selectionStart:O}=hv(y,x,O,b));else if(y==="."&&(o==="float"||o==="Quantity"))({value:T,selectionStart:O}=hv(y,x,O,b));else if(y==="ArrowUp"||y==="ArrowDown")({value:T,selectionStart:O}=H_(y,x,O));else if(y==="Backspace")({value:T,selectionStart:O}=V_(x,O,b));else if(y==="Delete")({value:T,selectionStart:O}=K_(x,O,b));else if(y==="Enter"&&!s){let $;o==="Quantity"?$={type:"Quantity",value:{magnitude:Number(T),unit:a},full_access_path:t,readonly:r,doc:i}:$={type:o,value:Number(T),full_access_path:t,readonly:r,doc:i},u($);return}else return;if(s){let $;o==="Quantity"?$={type:"Quantity",value:{magnitude:Number(T),unit:a},full_access_path:t,readonly:r,doc:i}:$={type:o,value:Number(T),full_access_path:t,readonly:r,doc:i},u($)}S(T),v(O)},m=()=>{if(!s){let p;o==="Quantity"?p={type:"Quantity",value:{magnitude:Number(g),unit:a},full_access_path:t,readonly:r,doc:i}:p={type:o,value:Number(g),full_access_path:t,readonly:r,doc:i},u(p)}};return h.useEffect(()=>{const p=o==="int"?parseInt(g):parseFloat(g);n!==p&&S(n.toString());let y=`${t} changed to ${e.value}`;a===void 0?y+=".":y+=` ${a}.`,l(y)},[n]),h.useEffect(()=>{const p=document.getElementsByName(d)[0];p&&f!==null&&p.setSelectionRange(f,f)}),w.jsxs("div",{className:"component numberComponent",id:d,children:[!1,w.jsxs(Un,{children:[c&&w.jsxs(Un.Text,{children:[c,w.jsx(ln,{docString:i})]}),w.jsx(ot.Control,{type:"text",value:g,disabled:r,onChange:()=>{},name:d,onKeyDown:k,onBlur:m,className:s&&!r?"instantUpdate":""}),a&&w.jsx(Un.Text,{children:a})]})]})});zl.displayName="NumberComponent";const Ts={black:"#000",white:"#fff"},lo={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},uo={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},co={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},fo={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},po={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},Ri={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},G_={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"};function Rs(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n0?Ve(di,--yt):0,ti--,Ae===10&&(ti=1,Nu--),Ae}function Et(){return Ae=yt2||As(Ae)>3?"":" "}function fT(e,t){for(;--t&&Et()&&!(Ae<48||Ae>102||Ae>57&&Ae<65||Ae>70&&Ae<97););return Vs(e,qa()+(t<6&&En()==32&&Et()==32))}function Id(e){for(;Et();)switch(Ae){case e:return yt;case 34:case 39:e!==34&&e!==39&&Id(Ae);break;case 40:e===41&&Id(e);break;case 92:Et();break}return yt}function dT(e,t){for(;Et()&&e+Ae!==57;)if(e+Ae===84&&En()===47)break;return"/*"+Vs(t,yt-1)+"*"+Ru(e===47?e:Et())}function pT(e){for(;!As(En());)Et();return Vs(e,yt)}function hT(e){return vx(Ya("",null,null,null,[""],e=yx(e),0,[0],e))}function Ya(e,t,n,r,o,i,s,a,l){for(var u=0,c=0,d=s,f=0,v=0,g=0,S=1,k=1,m=1,p=0,y="",E=o,C=i,x=r,b=y;k;)switch(g=p,p=Et()){case 40:if(g!=108&&Ve(b,d-1)==58){Ld(b+=ae(Qa(p),"&","&\f"),"&\f")!=-1&&(m=-1);break}case 34:case 39:case 91:b+=Qa(p);break;case 9:case 10:case 13:case 32:b+=cT(g);break;case 92:b+=fT(qa()-1,7);continue;case 47:switch(En()){case 42:case 47:xa(mT(dT(Et(),qa()),t,n),l);break;default:b+="/"}break;case 123*S:a[u++]=pn(b)*m;case 125*S:case 59:case 0:switch(p){case 0:case 125:k=0;case 59+c:m==-1&&(b=ae(b,/\f/g,"")),v>0&&pn(b)-d&&xa(v>32?yv(b+";",r,n,d-1):yv(ae(b," ","")+";",r,n,d-2),l);break;case 59:b+=";";default:if(xa(x=mv(b,t,n,u,c,o,a,y,E=[],C=[],d),i),p===123)if(c===0)Ya(b,t,x,x,E,i,d,a,C);else switch(f===99&&Ve(b,3)===110?100:f){case 100:case 108:case 109:case 115:Ya(e,x,x,r&&xa(mv(e,x,x,0,0,o,a,y,o,E=[],d),C),o,C,d,a,r?E:C);break;default:Ya(b,x,x,x,[""],C,0,a,C)}}u=c=v=0,S=m=1,y=b="",d=s;break;case 58:d=1+pn(b),v=g;default:if(S<1){if(p==123)--S;else if(p==125&&S++==0&&uT()==125)continue}switch(b+=Ru(p),p*S){case 38:m=c>0?1:(b+="\f",-1);break;case 44:a[u++]=(pn(b)-1)*m,m=1;break;case 64:En()===45&&(b+=Qa(Et())),f=En(),c=d=pn(y=b+=pT(qa())),p++;break;case 45:g===45&&pn(b)==2&&(S=0)}}return i}function mv(e,t,n,r,o,i,s,a,l,u,c){for(var d=o-1,f=o===0?i:[""],v=Mh(f),g=0,S=0,k=0;g0?f[m]+" "+p:ae(p,/&\f/g,f[m])))&&(l[k++]=y);return Au(e,t,n,o===0?Lh:a,l,u,c)}function mT(e,t,n){return Au(e,t,n,dx,Ru(lT()),Ns(e,2,-2),0)}function yv(e,t,n,r){return Au(e,t,n,Ih,Ns(e,0,r),Ns(e,r+1,-1),r)}function Fo(e,t){for(var n="",r=Mh(e),o=0;o6)switch(Ve(e,t+1)){case 109:if(Ve(e,t+4)!==45)break;case 102:return ae(e,/(.+:)(.+)-([^]+)/,"$1"+se+"$2-$3$1"+Ul+(Ve(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~Ld(e,"stretch")?gx(ae(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Ve(e,t+1)!==115)break;case 6444:switch(Ve(e,pn(e)-3-(~Ld(e,"!important")&&10))){case 107:return ae(e,":",":"+se)+e;case 101:return ae(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+se+(Ve(e,14)===45?"inline-":"")+"box$3$1"+se+"$2$3$1"+Je+"$2box$3")+e}break;case 5936:switch(Ve(e,t+11)){case 114:return se+e+Je+ae(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return se+e+Je+ae(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return se+e+Je+ae(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return se+e+Je+e+e}return e}var bT=function(t,n,r,o){if(t.length>-1&&!t.return)switch(t.type){case Ih:t.return=gx(t.value,t.length);break;case px:return Fo([Ni(t,{value:ae(t.value,"@","@"+se)})],o);case Lh:if(t.length)return aT(t.props,function(i){switch(sT(i,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Fo([Ni(t,{props:[ae(i,/:(read-\w+)/,":"+Ul+"$1")]})],o);case"::placeholder":return Fo([Ni(t,{props:[ae(i,/:(plac\w+)/,":"+se+"input-$1")]}),Ni(t,{props:[ae(i,/:(plac\w+)/,":"+Ul+"$1")]}),Ni(t,{props:[ae(i,/:(plac\w+)/,Je+"input-$1")]})],o)}return""})}},CT=[bT],wx=function(t){var n=t.key;if(n==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(S){var k=S.getAttribute("data-emotion");k.indexOf(" ")!==-1&&(document.head.appendChild(S),S.setAttribute("data-s",""))})}var o=t.stylisPlugins||CT,i={},s,a=[];s=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(S){for(var k=S.getAttribute("data-emotion").split(" "),m=1;m<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=s.createElement(n,{is:r.is}):(e=s.createElement(n),n==="select"&&(s=e,r.multiple?s.multiple=!0:r.size&&(s.size=r.size))):e=s.createElementNS(e,n),e[yn]=t,e[gs]=r,fw(e,t,!1,!1),t.stateNode=e;e:{switch(s=Bf(n,r),n){case"dialog":me("cancel",e),me("close",e),o=r;break;case"iframe":case"object":case"embed":me("load",e),o=r;break;case"video":case"audio":for(o=0;oQo&&(t.flags|=128,r=!0,Ci(i,!1),t.lanes=4194304)}else{if(!r)if(e=$l(s),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Ci(i,!0),i.tail===null&&i.tailMode==="hidden"&&!s.alternate&&!xe)return Xe(t),null}else 2*_e()-i.renderingStartTime>Qo&&n!==1073741824&&(t.flags|=128,r=!0,Ci(i,!1),t.lanes=4194304);i.isBackwards?(s.sibling=t.child,t.child=s):(n=i.last,n!==null?n.sibling=s:t.child=s,i.last=s)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=_e(),t.sibling=null,n=Ee.current,he(Ee,r?n&1|2:n&1),t):(Xe(t),null);case 22:case 23:return nh(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?gt&1073741824&&(Xe(t),t.subtreeFlags&6&&(t.flags|=8192)):Xe(t),null;case 24:return null;case 25:return null}throw Error(R(156,t.tag))}function HC(e,t){switch(Ip(t),t.tag){case 1:return dt(t.type)&&Sl(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Go(),ye(ft),ye(et),Vp(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Hp(t),null;case 13:if(ye(Ee),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(R(340));Vo()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ye(Ee),null;case 4:return Go(),null;case 10:return Fp(t.type._context),null;case 22:case 23:return nh(),null;case 24:return null;default:return null}}var pa=!1,Ze=!1,VC=typeof WeakSet=="function"?WeakSet:Set,L=null;function Ro(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){$e(e,t,r)}else n.current=null}function fd(e,t,n){try{n()}catch(r){$e(e,t,r)}}var Cy=!1;function KC(e,t){if(qf=yl,e=g1(),jp(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var o=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var s=0,a=-1,l=-1,u=0,c=0,d=e,f=null;t:for(;;){for(var v;d!==n||o!==0&&d.nodeType!==3||(a=s+o),d!==i||r!==0&&d.nodeType!==3||(l=s+r),d.nodeType===3&&(s+=d.nodeValue.length),(v=d.firstChild)!==null;)f=d,d=v;for(;;){if(d===e)break t;if(f===n&&++u===o&&(a=s),f===i&&++c===r&&(l=s),(v=d.nextSibling)!==null)break;d=f,f=d.parentNode}d=v}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Qf={focusedElem:e,selectionRange:n},yl=!1,L=t;L!==null;)if(t=L,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,L=e;else for(;L!==null;){t=L;try{var g=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(g!==null){var S=g.memoizedProps,k=g.memoizedState,m=t.stateNode,p=m.getSnapshotBeforeUpdate(t.elementType===t.type?S:Xt(t.type,S),k);m.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var y=t.stateNode.containerInfo;y.nodeType===1?y.textContent="":y.nodeType===9&&y.documentElement&&y.removeChild(y.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(R(163))}}catch(E){$e(t,t.return,E)}if(e=t.sibling,e!==null){e.return=t.return,L=e;break}L=t.return}return g=Cy,Cy=!1,g}function Yi(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var o=r=r.next;do{if((o.tag&e)===e){var i=o.destroy;o.destroy=void 0,i!==void 0&&fd(t,n,i)}o=o.next}while(o!==r)}}function yu(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function dd(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function hw(e){var t=e.alternate;t!==null&&(e.alternate=null,hw(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[yn],delete t[gs],delete t[Jf],delete t[_C],delete t[TC])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function mw(e){return e.tag===5||e.tag===3||e.tag===4}function Oy(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||mw(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function pd(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=wl));else if(r!==4&&(e=e.child,e!==null))for(pd(e,t,n),e=e.sibling;e!==null;)pd(e,t,n),e=e.sibling}function hd(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(hd(e,t,n),e=e.sibling;e!==null;)hd(e,t,n),e=e.sibling}var He=null,Jt=!1;function er(e,t,n){for(n=n.child;n!==null;)yw(e,t,n),n=n.sibling}function yw(e,t,n){if(vn&&typeof vn.onCommitFiberUnmount=="function")try{vn.onCommitFiberUnmount(lu,n)}catch{}switch(n.tag){case 5:Ze||Ro(n,t);case 6:var r=He,o=Jt;He=null,er(e,t,n),He=r,Jt=o,He!==null&&(Jt?(e=He,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):He.removeChild(n.stateNode));break;case 18:He!==null&&(Jt?(e=He,n=n.stateNode,e.nodeType===8?Ic(e.parentNode,n):e.nodeType===1&&Ic(e,n),ps(e)):Ic(He,n.stateNode));break;case 4:r=He,o=Jt,He=n.stateNode.containerInfo,Jt=!0,er(e,t,n),He=r,Jt=o;break;case 0:case 11:case 14:case 15:if(!Ze&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){o=r=r.next;do{var i=o,s=i.destroy;i=i.tag,s!==void 0&&(i&2||i&4)&&fd(n,t,s),o=o.next}while(o!==r)}er(e,t,n);break;case 1:if(!Ze&&(Ro(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){$e(n,t,a)}er(e,t,n);break;case 21:er(e,t,n);break;case 22:n.mode&1?(Ze=(r=Ze)||n.memoizedState!==null,er(e,t,n),Ze=r):er(e,t,n);break;default:er(e,t,n)}}function $y(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new VC),t.forEach(function(r){var o=tO.bind(null,e,r);n.has(r)||(n.add(r),r.then(o,o))})}}function Qt(e,t){var n=t.deletions;if(n!==null)for(var r=0;ro&&(o=s),r&=~i}if(r=o,r=_e()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*qC(r/1960))-r,10e?16:e,cr===null)var r=!1;else{if(e=cr,cr=null,Al=0,te&6)throw Error(R(331));var o=te;for(te|=4,L=e.current;L!==null;){var i=L,s=i.child;if(L.flags&16){var a=i.deletions;if(a!==null){for(var l=0;l_e()-eh?Mr(e,0):Zp|=n),pt(e,t)}function bw(e,t){t===0&&(e.mode&1?(t=oa,oa<<=1,!(oa&130023424)&&(oa=4194304)):t=1);var n=st();e=Vn(e,t),e!==null&&(Ms(e,t,n),pt(e,n))}function eO(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),bw(e,n)}function tO(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,o=e.memoizedState;o!==null&&(n=o.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(R(314))}r!==null&&r.delete(t),bw(e,n)}var Cw;Cw=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||ft.current)ct=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return ct=!1,UC(e,t,n);ct=!!(e.flags&131072)}else ct=!1,xe&&t.flags&1048576&&T1(t,kl,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Da(e,t),e=t.pendingProps;var o=Ho(t,et.current);Mo(t,n),o=Gp(null,t,r,e,o,n);var i=qp();return t.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,dt(r)?(i=!0,xl(t)):i=!1,t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,Up(t),o.updater=mu,t.stateNode=o,o._reactInternals=t,od(t,r,e,n),t=ad(null,t,r,!0,i,n)):(t.tag=0,xe&&i&&Lp(t),rt(null,t,o,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Da(e,t),e=t.pendingProps,o=r._init,r=o(r._payload),t.type=r,o=t.tag=rO(r),e=Xt(r,e),o){case 0:t=sd(null,t,r,e,n);break e;case 1:t=Ey(null,t,r,e,n);break e;case 11:t=Sy(null,t,r,e,n);break e;case 14:t=xy(null,t,r,Xt(r.type,e),n);break e}throw Error(R(306,r,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Xt(r,o),sd(e,t,r,o,n);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Xt(r,o),Ey(e,t,r,o,n);case 3:e:{if(lw(t),e===null)throw Error(R(387));r=t.pendingProps,i=t.memoizedState,o=i.element,L1(e,t),Ol(t,r,null,n);var s=t.memoizedState;if(r=s.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){o=qo(Error(R(423)),t),t=ky(e,t,r,n,o);break e}else if(r!==o){o=qo(Error(R(424)),t),t=ky(e,t,r,n,o);break e}else for(St=mr(t.stateNode.containerInfo.firstChild),xt=t,xe=!0,en=null,n=P1(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Vo(),r===o){t=Kn(e,t,n);break e}rt(e,t,r,n)}t=t.child}return t;case 5:return I1(t),e===null&&td(t),r=t.type,o=t.pendingProps,i=e!==null?e.memoizedProps:null,s=o.children,Yf(r,o)?s=null:i!==null&&Yf(r,i)&&(t.flags|=32),aw(e,t),rt(e,t,s,n),t.child;case 6:return e===null&&td(t),null;case 13:return uw(e,t,n);case 4:return Wp(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ko(t,null,r,n):rt(e,t,r,n),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Xt(r,o),Sy(e,t,r,o,n);case 7:return rt(e,t,t.pendingProps,n),t.child;case 8:return rt(e,t,t.pendingProps.children,n),t.child;case 12:return rt(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,o=t.pendingProps,i=t.memoizedProps,s=o.value,he(bl,r._currentValue),r._currentValue=s,i!==null)if(sn(i.value,s)){if(i.children===o.children&&!ft.current){t=Kn(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){s=i.child;for(var l=a.firstContext;l!==null;){if(l.context===r){if(i.tag===1){l=zn(-1,n&-n),l.tag=2;var u=i.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}i.lanes|=n,l=i.alternate,l!==null&&(l.lanes|=n),nd(i.return,n,t),a.lanes|=n;break}l=l.next}}else if(i.tag===10)s=i.type===t.type?null:i.child;else if(i.tag===18){if(s=i.return,s===null)throw Error(R(341));s.lanes|=n,a=s.alternate,a!==null&&(a.lanes|=n),nd(s,n,t),s=i.sibling}else s=i.child;if(s!==null)s.return=i;else for(s=i;s!==null;){if(s===t){s=null;break}if(i=s.sibling,i!==null){i.return=s.return,s=i;break}s=s.return}i=s}rt(e,t,o.children,n),t=t.child}return t;case 9:return o=t.type,r=t.pendingProps.children,Mo(t,n),o=Dt(o),r=r(o),t.flags|=1,rt(e,t,r,n),t.child;case 14:return r=t.type,o=Xt(r,t.pendingProps),o=Xt(r.type,o),xy(e,t,r,o,n);case 15:return iw(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Xt(r,o),Da(e,t),t.tag=1,dt(r)?(e=!0,xl(t)):e=!1,Mo(t,n),nw(t,r,o),od(t,r,o,n),ad(null,t,r,!0,e,n);case 19:return cw(e,t,n);case 22:return sw(e,t,n)}throw Error(R(156,t.tag))};function Ow(e,t){return Z0(e,t)}function nO(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function It(e,t,n,r){return new nO(e,t,n,r)}function oh(e){return e=e.prototype,!(!e||!e.isReactComponent)}function rO(e){if(typeof e=="function")return oh(e)?1:0;if(e!=null){if(e=e.$$typeof,e===kp)return 11;if(e===bp)return 14}return 2}function wr(e,t){var n=e.alternate;return n===null?(n=It(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Ua(e,t,n,r,o,i){var s=2;if(r=e,typeof e=="function")oh(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case xo:return Br(n.children,o,i,t);case Ep:s=8,o|=8;break;case _f:return e=It(12,n,t,o|2),e.elementType=_f,e.lanes=i,e;case Tf:return e=It(13,n,t,o),e.elementType=Tf,e.lanes=i,e;case Rf:return e=It(19,n,t,o),e.elementType=Rf,e.lanes=i,e;case I0:return gu(n,o,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case j0:s=10;break e;case L0:s=9;break e;case kp:s=11;break e;case bp:s=14;break e;case nr:s=16,r=null;break e}throw Error(R(130,e==null?e:typeof e,""))}return t=It(s,n,t,o),t.elementType=e,t.type=r,t.lanes=i,t}function Br(e,t,n,r){return e=It(7,e,r,t),e.lanes=n,e}function gu(e,t,n,r){return e=It(22,e,r,t),e.elementType=I0,e.lanes=n,e.stateNode={isHidden:!1},e}function Hc(e,t,n){return e=It(6,e,null,t),e.lanes=n,e}function Vc(e,t,n){return t=It(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function oO(e,t,n,r,o){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Cc(0),this.expirationTimes=Cc(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Cc(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function ih(e,t,n,r,o,i,s,a,l){return e=new oO(e,t,n,a,l),t===1?(t=1,i===!0&&(t|=8)):t=0,i=It(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Up(i),e}function iO(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Rw)}catch{}}Rw(),R0.exports=Ct;var Nw=R0.exports;const Ir=si(Nw),Ly={disabled:!1},Aw=ne.createContext(null);var cO=function(t){return t.scrollTop},Di="unmounted",or="exited",Pt="entering",In="entered",Yo="exiting",Jn=function(e){Vk(t,e);function t(r,o){var i;i=e.call(this,r,o)||this;var s=o,a=s&&!s.isMounting?r.enter:r.appear,l;return i.appearStatus=null,r.in?a?(l=or,i.appearStatus=Pt):l=In:r.unmountOnExit||r.mountOnEnter?l=Di:l=or,i.state={status:l},i.nextCallback=null,i}t.getDerivedStateFromProps=function(o,i){var s=o.in;return s&&i.status===Di?{status:or}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var i=null;if(o!==this.props){var s=this.state.status;this.props.in?s!==Pt&&s!==In&&(i=Pt):(s===Pt||s===In)&&(i=Yo)}this.updateStatus(!1,i)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,i,s,a;return i=s=a=o,o!=null&&typeof o!="number"&&(i=o.exit,s=o.enter,a=o.appear!==void 0?o.appear:s),{exit:i,enter:s,appear:a}},n.updateStatus=function(o,i){if(o===void 0&&(o=!1),i!==null)if(this.cancelNextCallback(),i===Pt){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:Ir.findDOMNode(this);s&&cO(s)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===or&&this.setState({status:Di})},n.performEnter=function(o){var i=this,s=this.props.enter,a=this.context?this.context.isMounting:o,l=this.props.nodeRef?[a]:[Ir.findDOMNode(this),a],u=l[0],c=l[1],d=this.getTimeouts(),f=a?d.appear:d.enter;if(!o&&!s||Ly.disabled){this.safeSetState({status:In},function(){i.props.onEntered(u)});return}this.props.onEnter(u,c),this.safeSetState({status:Pt},function(){i.props.onEntering(u,c),i.onTransitionEnd(f,function(){i.safeSetState({status:In},function(){i.props.onEntered(u,c)})})})},n.performExit=function(){var o=this,i=this.props.exit,s=this.getTimeouts(),a=this.props.nodeRef?void 0:Ir.findDOMNode(this);if(!i||Ly.disabled){this.safeSetState({status:or},function(){o.props.onExited(a)});return}this.props.onExit(a),this.safeSetState({status:Yo},function(){o.props.onExiting(a),o.onTransitionEnd(s.exit,function(){o.safeSetState({status:or},function(){o.props.onExited(a)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,i){i=this.setNextCallback(i),this.setState(o,i)},n.setNextCallback=function(o){var i=this,s=!0;return this.nextCallback=function(a){s&&(s=!1,i.nextCallback=null,o(a))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},n.onTransitionEnd=function(o,i){this.setNextCallback(i);var s=this.props.nodeRef?this.props.nodeRef.current:Ir.findDOMNode(this),a=o==null&&!this.props.addEndListener;if(!s||a){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var l=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],u=l[0],c=l[1];this.props.addEndListener(u,c)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===Di)return null;var i=this.props,s=i.children;i.in,i.mountOnEnter,i.unmountOnExit,i.appear,i.enter,i.exit,i.timeout,i.addEndListener,i.onEnter,i.onEntering,i.onEntered,i.onExit,i.onExiting,i.onExited,i.nodeRef;var a=an(i,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return ne.createElement(Aw.Provider,{value:null},typeof s=="function"?s(o,a):ne.cloneElement(ne.Children.only(s),a))},t}(ne.Component);Jn.contextType=Aw;Jn.propTypes={};function io(){}Jn.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:io,onEntering:io,onEntered:io,onExit:io,onExiting:io,onExited:io};Jn.UNMOUNTED=Di;Jn.EXITED=or;Jn.ENTERING=Pt;Jn.ENTERED=In;Jn.EXITING=Yo;const ku=!!(typeof window<"u"&&window.document&&window.document.createElement);var wd=!1,Sd=!1;try{var Kc={get passive(){return wd=!0},get once(){return Sd=wd=!0}};ku&&(window.addEventListener("test",Kc,Kc),window.removeEventListener("test",Kc,!0))}catch{}function fO(e,t,n,r){if(r&&typeof r!="boolean"&&!Sd){var o=r.once,i=r.capture,s=n;!Sd&&o&&(s=n.__once||function a(l){this.removeEventListener(t,a,i),n.call(this,l)},n.__once=s),e.addEventListener(t,s,wd?r:i)}e.addEventListener(t,n,r)}function dO(e,t,n,r){var o=r&&typeof r!="boolean"?r.capture:r;e.removeEventListener(t,n,o),n.__once&&e.removeEventListener(t,n.__once,o)}function Dn(e,t,n,r){return fO(e,t,n,r),function(){dO(e,t,n,r)}}function pO(e,t,n,r){if(r===void 0&&(r=!0),e){var o=document.createEvent("HTMLEvents");o.initEvent(t,n,r),e.dispatchEvent(o)}}function hO(e){var t=Fn(e,"transitionDuration")||"",n=t.indexOf("ms")===-1?1e3:1;return parseFloat(t)*n}function mO(e,t,n){n===void 0&&(n=5);var r=!1,o=setTimeout(function(){r||pO(e,"transitionend",!0)},t+n),i=Dn(e,"transitionend",function(){r=!0},{once:!0});return function(){clearTimeout(o),i()}}function yO(e,t,n,r){n==null&&(n=hO(e)||0);var o=mO(e,n,r),i=Dn(e,"transitionend",t);return function(){o(),i()}}function Iy(e,t){const n=Fn(e,t)||"",r=n.indexOf("ms")===-1?1e3:1;return parseFloat(n)*r}function uh(e,t){const n=Iy(e,"transitionDuration"),r=Iy(e,"transitionDelay"),o=yO(e,i=>{i.target===e&&(o(),t(i))},n+r)}function $i(...e){return e.filter(t=>t!=null).reduce((t,n)=>{if(typeof n!="function")throw new Error("Invalid Argument Type, must only provide functions, undefined, or null.");return t===null?n:function(...o){t.apply(this,o),n.apply(this,o)}},null)}function Pw(e){e.offsetHeight}const My=e=>!e||typeof e=="function"?e:t=>{e.current=t};function vO(e,t){const n=My(e),r=My(t);return o=>{n&&n(o),r&&r(o)}}function Yr(e,t){return h.useMemo(()=>vO(e,t),[e,t])}function Ll(e){return e&&"setState"in e?Ir.findDOMNode(e):e??null}const ch=ne.forwardRef(({onEnter:e,onEntering:t,onEntered:n,onExit:r,onExiting:o,onExited:i,addEndListener:s,children:a,childRef:l,...u},c)=>{const d=h.useRef(null),f=Yr(d,l),v=x=>{f(Ll(x))},g=x=>b=>{x&&d.current&&x(d.current,b)},S=h.useCallback(g(e),[e]),k=h.useCallback(g(t),[t]),m=h.useCallback(g(n),[n]),p=h.useCallback(g(r),[r]),y=h.useCallback(g(o),[o]),E=h.useCallback(g(i),[i]),C=h.useCallback(g(s),[s]);return w.jsx(Jn,{ref:c,...u,onEnter:S,onEntered:m,onEntering:k,onExit:p,onExited:E,onExiting:y,addEndListener:C,nodeRef:d,children:typeof a=="function"?(x,b)=>a(x,{...b,ref:v}):ne.cloneElement(a,{ref:v})})}),gO={height:["marginTop","marginBottom"],width:["marginLeft","marginRight"]};function wO(e,t){const n=`offset${e[0].toUpperCase()}${e.slice(1)}`,r=t[n],o=gO[e];return r+parseInt(Fn(t,o[0]),10)+parseInt(Fn(t,o[1]),10)}const SO={[or]:"collapse",[Yo]:"collapsing",[Pt]:"collapsing",[In]:"collapse show"},bu=ne.forwardRef(({onEnter:e,onEntering:t,onEntered:n,onExit:r,onExiting:o,className:i,children:s,dimension:a="height",in:l=!1,timeout:u=300,mountOnEnter:c=!1,unmountOnExit:d=!1,appear:f=!1,getDimensionValue:v=wO,...g},S)=>{const k=typeof a=="function"?a():a,m=h.useMemo(()=>$i(x=>{x.style[k]="0"},e),[k,e]),p=h.useMemo(()=>$i(x=>{const b=`scroll${k[0].toUpperCase()}${k.slice(1)}`;x.style[k]=`${x[b]}px`},t),[k,t]),y=h.useMemo(()=>$i(x=>{x.style[k]=null},n),[k,n]),E=h.useMemo(()=>$i(x=>{x.style[k]=`${v(k,x)}px`,Pw(x)},r),[r,v,k]),C=h.useMemo(()=>$i(x=>{x.style[k]=null},o),[k,o]);return w.jsx(ch,{ref:S,addEndListener:uh,...g,"aria-expanded":g.role?l:null,onEnter:m,onEntering:p,onEntered:y,onExit:E,onExiting:C,childRef:s.ref,in:l,timeout:u,mountOnEnter:c,unmountOnExit:d,appear:f,children:(x,b)=>ne.cloneElement(s,{...b,className:M(i,s.props.className,SO[x],k==="width"&&"collapse-horizontal")})})});function xO(e){const t=h.useRef(e);return h.useEffect(()=>{t.current=e},[e]),t}function it(e){const t=xO(e);return h.useCallback(function(...n){return t.current&&t.current(...n)},[t])}const fh=e=>h.forwardRef((t,n)=>w.jsx("div",{...t,ref:n,className:M(t.className,e)}));function By(){return h.useState(null)}function dh(){const e=h.useRef(!0),t=h.useRef(()=>e.current);return h.useEffect(()=>(e.current=!0,()=>{e.current=!1}),[]),t.current}function EO(e){const t=h.useRef(null);return h.useEffect(()=>{t.current=e}),t.current}const kO=typeof global<"u"&&global.navigator&&global.navigator.product==="ReactNative",bO=typeof document<"u",Il=bO||kO?h.useLayoutEffect:h.useEffect,CO=["as","disabled"];function OO(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i=0)&&(n[o]=e[o]);return n}function $O(e){return!e||e.trim()==="#"}function jw({tagName:e,disabled:t,href:n,target:r,rel:o,role:i,onClick:s,tabIndex:a=0,type:l}){e||(n!=null||r!=null||o!=null?e="a":e="button");const u={tagName:e};if(e==="button")return[{type:l||"button",disabled:t},u];const c=f=>{if((t||e==="a"&&$O(n))&&f.preventDefault(),t){f.stopPropagation();return}s==null||s(f)},d=f=>{f.key===" "&&(f.preventDefault(),c(f))};return e==="a"&&(n||(n="#"),t&&(n=void 0)),[{role:i??"button",disabled:void 0,tabIndex:t?void 0:a,href:n,target:e==="a"?r:void 0,"aria-disabled":t||void 0,rel:e==="a"?o:void 0,onClick:c,onKeyDown:d},u]}const _O=h.forwardRef((e,t)=>{let{as:n,disabled:r}=e,o=OO(e,CO);const[i,{tagName:s}]=jw(Object.assign({tagName:n,disabled:r},o));return w.jsx(s,Object.assign({},o,i,{ref:t}))});_O.displayName="Button";const TO={[Pt]:"show",[In]:"show"},Cs=h.forwardRef(({className:e,children:t,transitionClasses:n={},onEnter:r,...o},i)=>{const s={in:!1,timeout:300,mountOnEnter:!1,unmountOnExit:!1,appear:!1,...o},a=h.useCallback((l,u)=>{Pw(l),r==null||r(l,u)},[r]);return w.jsx(ch,{ref:i,addEndListener:uh,...s,onEnter:a,childRef:t.ref,children:(l,u)=>h.cloneElement(t,{...u,className:M("fade",e,t.props.className,TO[l],n[l])})})});Cs.displayName="Fade";const RO={"aria-label":pe.string,onClick:pe.func,variant:pe.oneOf(["white"])},Cu=h.forwardRef(({className:e,variant:t,"aria-label":n="Close",...r},o)=>w.jsx("button",{ref:o,type:"button",className:M("btn-close",t&&`btn-close-${t}`,e),"aria-label":n,...r}));Cu.displayName="CloseButton";Cu.propTypes=RO;const Lw=h.forwardRef(({bsPrefix:e,bg:t="primary",pill:n=!1,text:r,className:o,as:i="span",...s},a)=>{const l=z(e,"badge");return w.jsx(i,{ref:a,...s,className:M(o,l,n&&"rounded-pill",r&&`text-${r}`,t&&`bg-${t}`)})});Lw.displayName="Badge";const zs=h.forwardRef(({as:e,bsPrefix:t,variant:n="primary",size:r,active:o=!1,disabled:i=!1,className:s,...a},l)=>{const u=z(t,"btn"),[c,{tagName:d}]=jw({tagName:e,disabled:i,...a}),f=d;return w.jsx(f,{...c,...a,ref:l,disabled:i,className:M(s,u,o&&"active",n&&`${u}-${n}`,r&&`${u}-${r}`,a.href&&i&&"disabled")})});zs.displayName="Button";const ph=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"card-body"),w.jsx(n,{ref:o,className:M(e,t),...r})));ph.displayName="CardBody";const Iw=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"card-footer"),w.jsx(n,{ref:o,className:M(e,t),...r})));Iw.displayName="CardFooter";const Mw=h.createContext(null);Mw.displayName="CardHeaderContext";const Bw=h.forwardRef(({bsPrefix:e,className:t,as:n="div",...r},o)=>{const i=z(e,"card-header"),s=h.useMemo(()=>({cardHeaderBsPrefix:i}),[i]);return w.jsx(Mw.Provider,{value:s,children:w.jsx(n,{ref:o,...r,className:M(t,i)})})});Bw.displayName="CardHeader";const Dw=h.forwardRef(({bsPrefix:e,className:t,variant:n,as:r="img",...o},i)=>{const s=z(e,"card-img");return w.jsx(r,{ref:i,className:M(n?`${s}-${n}`:s,t),...o})});Dw.displayName="CardImg";const Fw=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"card-img-overlay"),w.jsx(n,{ref:o,className:M(e,t),...r})));Fw.displayName="CardImgOverlay";const zw=h.forwardRef(({className:e,bsPrefix:t,as:n="a",...r},o)=>(t=z(t,"card-link"),w.jsx(n,{ref:o,className:M(e,t),...r})));zw.displayName="CardLink";const NO=fh("h6"),Uw=h.forwardRef(({className:e,bsPrefix:t,as:n=NO,...r},o)=>(t=z(t,"card-subtitle"),w.jsx(n,{ref:o,className:M(e,t),...r})));Uw.displayName="CardSubtitle";const Ww=h.forwardRef(({className:e,bsPrefix:t,as:n="p",...r},o)=>(t=z(t,"card-text"),w.jsx(n,{ref:o,className:M(e,t),...r})));Ww.displayName="CardText";const AO=fh("h5"),Hw=h.forwardRef(({className:e,bsPrefix:t,as:n=AO,...r},o)=>(t=z(t,"card-title"),w.jsx(n,{ref:o,className:M(e,t),...r})));Hw.displayName="CardTitle";const Vw=h.forwardRef(({bsPrefix:e,className:t,bg:n,text:r,border:o,body:i=!1,children:s,as:a="div",...l},u)=>{const c=z(e,"card");return w.jsx(a,{ref:u,...l,className:M(t,c,n&&`bg-${n}`,r&&`text-${r}`,o&&`border-${o}`),children:i?w.jsx(ph,{children:s}):s})});Vw.displayName="Card";const Do=Object.assign(Vw,{Img:Dw,Title:Hw,Subtitle:Uw,Body:ph,Link:zw,Text:Ww,Header:Bw,Footer:Iw,ImgOverlay:Fw});function PO(e){const t=h.useRef(e);return t.current=e,t}function Kw(e){const t=PO(e);h.useEffect(()=>()=>t.current(),[])}const xd=2**31-1;function Gw(e,t,n){const r=n-Date.now();e.current=r<=xd?setTimeout(t,r):setTimeout(()=>Gw(e,t,n),xd)}function qw(){const e=dh(),t=h.useRef();return Kw(()=>clearTimeout(t.current)),h.useMemo(()=>{const n=()=>clearTimeout(t.current);function r(o,i=0){e()&&(n(),i<=xd?t.current=setTimeout(o,i):Gw(t,o,Date.now()+i))}return{set:r,clear:n,handleRef:t}},[])}function jO(e,t){return h.Children.toArray(e).some(n=>h.isValidElement(n)&&n.type===t)}function LO({as:e,bsPrefix:t,className:n,...r}){t=z(t,"col");const o=b0(),i=C0(),s=[],a=[];return o.forEach(l=>{const u=r[l];delete r[l];let c,d,f;typeof u=="object"&&u!=null?{span:c,offset:d,order:f}=u:c=u;const v=l!==i?`-${l}`:"";c&&s.push(c===!0?`${t}${v}`:`${t}${v}-${c}`),f!=null&&a.push(`order${v}-${f}`),d!=null&&a.push(`offset${v}-${d}`)}),[{...r,className:M(n,...s,...a)},{as:e,bsPrefix:t,spans:s}]}const dn=h.forwardRef((e,t)=>{const[{className:n,...r},{as:o="div",bsPrefix:i,spans:s}]=LO(e);return w.jsx(o,{...r,ref:t,className:M(n,!s.length&&i)})});dn.displayName="Col";const Qw=h.forwardRef(({bsPrefix:e,fluid:t=!1,as:n="div",className:r,...o},i)=>{const s=z(e,"container"),a=typeof t=="string"?`-${t}`:"-fluid";return w.jsx(n,{ref:i,...o,className:M(r,t?`${s}${a}`:s)})});Qw.displayName="Container";var IO=Function.prototype.bind.call(Function.prototype.call,[].slice);function so(e,t){return IO(e.querySelectorAll(t))}var Dy=Object.prototype.hasOwnProperty;function Fy(e,t,n){for(n of e.keys())if(Zi(n,t))return n}function Zi(e,t){var n,r,o;if(e===t)return!0;if(e&&t&&(n=e.constructor)===t.constructor){if(n===Date)return e.getTime()===t.getTime();if(n===RegExp)return e.toString()===t.toString();if(n===Array){if((r=e.length)===t.length)for(;r--&&Zi(e[r],t[r]););return r===-1}if(n===Set){if(e.size!==t.size)return!1;for(r of e)if(o=r,o&&typeof o=="object"&&(o=Fy(t,o),!o)||!t.has(o))return!1;return!0}if(n===Map){if(e.size!==t.size)return!1;for(r of e)if(o=r[0],o&&typeof o=="object"&&(o=Fy(t,o),!o)||!Zi(r[1],t.get(o)))return!1;return!0}if(n===ArrayBuffer)e=new Uint8Array(e),t=new Uint8Array(t);else if(n===DataView){if((r=e.byteLength)===t.byteLength)for(;r--&&e.getInt8(r)===t.getInt8(r););return r===-1}if(ArrayBuffer.isView(e)){if((r=e.byteLength)===t.byteLength)for(;r--&&e[r]===t[r];);return r===-1}if(!n||typeof e=="object"){r=0;for(n in e)if(Dy.call(e,n)&&++r&&!Dy.call(t,n)||!(n in t)||!Zi(e[n],t[n]))return!1;return Object.keys(t).length===r}}return e!==e&&t!==t}function MO(e){const t=dh();return[e[0],h.useCallback(n=>{if(t())return e[1](n)},[t,e[1]])]}var ht="top",zt="bottom",Ut="right",mt="left",hh="auto",Us=[ht,zt,Ut,mt],Xo="start",Os="end",BO="clippingParents",Yw="viewport",_i="popper",DO="reference",zy=Us.reduce(function(e,t){return e.concat([t+"-"+Xo,t+"-"+Os])},[]),Xw=[].concat(Us,[hh]).reduce(function(e,t){return e.concat([t,t+"-"+Xo,t+"-"+Os])},[]),FO="beforeRead",zO="read",UO="afterRead",WO="beforeMain",HO="main",VO="afterMain",KO="beforeWrite",GO="write",qO="afterWrite",QO=[FO,zO,UO,WO,HO,VO,KO,GO,qO];function wn(e){return e.split("-")[0]}function bt(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Gr(e){var t=bt(e).Element;return e instanceof t||e instanceof Element}function Sn(e){var t=bt(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function mh(e){if(typeof ShadowRoot>"u")return!1;var t=bt(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}var Dr=Math.max,Ml=Math.min,Jo=Math.round;function Ed(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Jw(){return!/^((?!chrome|android).)*safari/i.test(Ed())}function Zo(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,i=1;t&&Sn(e)&&(o=e.offsetWidth>0&&Jo(r.width)/e.offsetWidth||1,i=e.offsetHeight>0&&Jo(r.height)/e.offsetHeight||1);var s=Gr(e)?bt(e):window,a=s.visualViewport,l=!Jw()&&n,u=(r.left+(l&&a?a.offsetLeft:0))/o,c=(r.top+(l&&a?a.offsetTop:0))/i,d=r.width/o,f=r.height/i;return{width:d,height:f,top:c,right:u+d,bottom:c+f,left:u,x:u,y:c}}function yh(e){var t=Zo(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function Zw(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&mh(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function kr(e){return e?(e.nodeName||"").toLowerCase():null}function Gn(e){return bt(e).getComputedStyle(e)}function YO(e){return["table","td","th"].indexOf(kr(e))>=0}function $r(e){return((Gr(e)?e.ownerDocument:e.document)||window.document).documentElement}function Ou(e){return kr(e)==="html"?e:e.assignedSlot||e.parentNode||(mh(e)?e.host:null)||$r(e)}function Uy(e){return!Sn(e)||Gn(e).position==="fixed"?null:e.offsetParent}function XO(e){var t=/firefox/i.test(Ed()),n=/Trident/i.test(Ed());if(n&&Sn(e)){var r=Gn(e);if(r.position==="fixed")return null}var o=Ou(e);for(mh(o)&&(o=o.host);Sn(o)&&["html","body"].indexOf(kr(o))<0;){var i=Gn(o);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||t&&i.willChange==="filter"||t&&i.filter&&i.filter!=="none")return o;o=o.parentNode}return null}function Ws(e){for(var t=bt(e),n=Uy(e);n&&YO(n)&&Gn(n).position==="static";)n=Uy(n);return n&&(kr(n)==="html"||kr(n)==="body"&&Gn(n).position==="static")?t:n||XO(e)||t}function vh(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function es(e,t,n){return Dr(e,Ml(t,n))}function JO(e,t,n){var r=es(e,t,n);return r>n?n:r}function eS(){return{top:0,right:0,bottom:0,left:0}}function tS(e){return Object.assign({},eS(),e)}function nS(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var ZO=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,tS(typeof t!="number"?t:nS(t,Us))};function e2(e){var t,n=e.state,r=e.name,o=e.options,i=n.elements.arrow,s=n.modifiersData.popperOffsets,a=wn(n.placement),l=vh(a),u=[mt,Ut].indexOf(a)>=0,c=u?"height":"width";if(!(!i||!s)){var d=ZO(o.padding,n),f=yh(i),v=l==="y"?ht:mt,g=l==="y"?zt:Ut,S=n.rects.reference[c]+n.rects.reference[l]-s[l]-n.rects.popper[c],k=s[l]-n.rects.reference[l],m=Ws(i),p=m?l==="y"?m.clientHeight||0:m.clientWidth||0:0,y=S/2-k/2,E=d[v],C=p-f[c]-d[g],x=p/2-f[c]/2+y,b=es(E,x,C),O=l;n.modifiersData[r]=(t={},t[O]=b,t.centerOffset=b-x,t)}}function t2(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||Zw(t.elements.popper,o)&&(t.elements.arrow=o))}const n2={name:"arrow",enabled:!0,phase:"main",fn:e2,effect:t2,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function ei(e){return e.split("-")[1]}var r2={top:"auto",right:"auto",bottom:"auto",left:"auto"};function o2(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Jo(n*o)/o||0,y:Jo(r*o)/o||0}}function Wy(e){var t,n=e.popper,r=e.popperRect,o=e.placement,i=e.variation,s=e.offsets,a=e.position,l=e.gpuAcceleration,u=e.adaptive,c=e.roundOffsets,d=e.isFixed,f=s.x,v=f===void 0?0:f,g=s.y,S=g===void 0?0:g,k=typeof c=="function"?c({x:v,y:S}):{x:v,y:S};v=k.x,S=k.y;var m=s.hasOwnProperty("x"),p=s.hasOwnProperty("y"),y=mt,E=ht,C=window;if(u){var x=Ws(n),b="clientHeight",O="clientWidth";if(x===bt(n)&&(x=$r(n),Gn(x).position!=="static"&&a==="absolute"&&(b="scrollHeight",O="scrollWidth")),x=x,o===ht||(o===mt||o===Ut)&&i===Os){E=zt;var T=d&&x===C&&C.visualViewport?C.visualViewport.height:x[b];S-=T-r.height,S*=l?1:-1}if(o===mt||(o===ht||o===zt)&&i===Os){y=Ut;var $=d&&x===C&&C.visualViewport?C.visualViewport.width:x[O];v-=$-r.width,v*=l?1:-1}}var A=Object.assign({position:a},u&&r2),U=c===!0?o2({x:v,y:S},bt(n)):{x:v,y:S};if(v=U.x,S=U.y,l){var B;return Object.assign({},A,(B={},B[E]=p?"0":"",B[y]=m?"0":"",B.transform=(C.devicePixelRatio||1)<=1?"translate("+v+"px, "+S+"px)":"translate3d("+v+"px, "+S+"px, 0)",B))}return Object.assign({},A,(t={},t[E]=p?S+"px":"",t[y]=m?v+"px":"",t.transform="",t))}function i2(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,i=n.adaptive,s=i===void 0?!0:i,a=n.roundOffsets,l=a===void 0?!0:a,u={placement:wn(t.placement),variation:ei(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Wy(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:s,roundOffsets:l})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Wy(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const s2={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:i2,data:{}};var ya={passive:!0};function a2(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,i=o===void 0?!0:o,s=r.resize,a=s===void 0?!0:s,l=bt(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return i&&u.forEach(function(c){c.addEventListener("scroll",n.update,ya)}),a&&l.addEventListener("resize",n.update,ya),function(){i&&u.forEach(function(c){c.removeEventListener("scroll",n.update,ya)}),a&&l.removeEventListener("resize",n.update,ya)}}const l2={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:a2,data:{}};var u2={left:"right",right:"left",bottom:"top",top:"bottom"};function Wa(e){return e.replace(/left|right|bottom|top/g,function(t){return u2[t]})}var c2={start:"end",end:"start"};function Hy(e){return e.replace(/start|end/g,function(t){return c2[t]})}function gh(e){var t=bt(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function wh(e){return Zo($r(e)).left+gh(e).scrollLeft}function f2(e,t){var n=bt(e),r=$r(e),o=n.visualViewport,i=r.clientWidth,s=r.clientHeight,a=0,l=0;if(o){i=o.width,s=o.height;var u=Jw();(u||!u&&t==="fixed")&&(a=o.offsetLeft,l=o.offsetTop)}return{width:i,height:s,x:a+wh(e),y:l}}function d2(e){var t,n=$r(e),r=gh(e),o=(t=e.ownerDocument)==null?void 0:t.body,i=Dr(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),s=Dr(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),a=-r.scrollLeft+wh(e),l=-r.scrollTop;return Gn(o||n).direction==="rtl"&&(a+=Dr(n.clientWidth,o?o.clientWidth:0)-i),{width:i,height:s,x:a,y:l}}function Sh(e){var t=Gn(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function rS(e){return["html","body","#document"].indexOf(kr(e))>=0?e.ownerDocument.body:Sn(e)&&Sh(e)?e:rS(Ou(e))}function ts(e,t){var n;t===void 0&&(t=[]);var r=rS(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),i=bt(r),s=o?[i].concat(i.visualViewport||[],Sh(r)?r:[]):r,a=t.concat(s);return o?a:a.concat(ts(Ou(s)))}function kd(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function p2(e,t){var n=Zo(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Vy(e,t,n){return t===Yw?kd(f2(e,n)):Gr(t)?p2(t,n):kd(d2($r(e)))}function h2(e){var t=ts(Ou(e)),n=["absolute","fixed"].indexOf(Gn(e).position)>=0,r=n&&Sn(e)?Ws(e):e;return Gr(r)?t.filter(function(o){return Gr(o)&&Zw(o,r)&&kr(o)!=="body"}):[]}function m2(e,t,n,r){var o=t==="clippingParents"?h2(e):[].concat(t),i=[].concat(o,[n]),s=i[0],a=i.reduce(function(l,u){var c=Vy(e,u,r);return l.top=Dr(c.top,l.top),l.right=Ml(c.right,l.right),l.bottom=Ml(c.bottom,l.bottom),l.left=Dr(c.left,l.left),l},Vy(e,s,r));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function oS(e){var t=e.reference,n=e.element,r=e.placement,o=r?wn(r):null,i=r?ei(r):null,s=t.x+t.width/2-n.width/2,a=t.y+t.height/2-n.height/2,l;switch(o){case ht:l={x:s,y:t.y-n.height};break;case zt:l={x:s,y:t.y+t.height};break;case Ut:l={x:t.x+t.width,y:a};break;case mt:l={x:t.x-n.width,y:a};break;default:l={x:t.x,y:t.y}}var u=o?vh(o):null;if(u!=null){var c=u==="y"?"height":"width";switch(i){case Xo:l[u]=l[u]-(t[c]/2-n[c]/2);break;case Os:l[u]=l[u]+(t[c]/2-n[c]/2);break}}return l}function $s(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,i=n.strategy,s=i===void 0?e.strategy:i,a=n.boundary,l=a===void 0?BO:a,u=n.rootBoundary,c=u===void 0?Yw:u,d=n.elementContext,f=d===void 0?_i:d,v=n.altBoundary,g=v===void 0?!1:v,S=n.padding,k=S===void 0?0:S,m=tS(typeof k!="number"?k:nS(k,Us)),p=f===_i?DO:_i,y=e.rects.popper,E=e.elements[g?p:f],C=m2(Gr(E)?E:E.contextElement||$r(e.elements.popper),l,c,s),x=Zo(e.elements.reference),b=oS({reference:x,element:y,strategy:"absolute",placement:o}),O=kd(Object.assign({},y,b)),T=f===_i?O:x,$={top:C.top-T.top+m.top,bottom:T.bottom-C.bottom+m.bottom,left:C.left-T.left+m.left,right:T.right-C.right+m.right},A=e.modifiersData.offset;if(f===_i&&A){var U=A[o];Object.keys($).forEach(function(B){var K=[Ut,zt].indexOf(B)>=0?1:-1,W=[ht,zt].indexOf(B)>=0?"y":"x";$[B]+=U[W]*K})}return $}function y2(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,i=n.rootBoundary,s=n.padding,a=n.flipVariations,l=n.allowedAutoPlacements,u=l===void 0?Xw:l,c=ei(r),d=c?a?zy:zy.filter(function(g){return ei(g)===c}):Us,f=d.filter(function(g){return u.indexOf(g)>=0});f.length===0&&(f=d);var v=f.reduce(function(g,S){return g[S]=$s(e,{placement:S,boundary:o,rootBoundary:i,padding:s})[wn(S)],g},{});return Object.keys(v).sort(function(g,S){return v[g]-v[S]})}function v2(e){if(wn(e)===hh)return[];var t=Wa(e);return[Hy(e),t,Hy(t)]}function g2(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,i=o===void 0?!0:o,s=n.altAxis,a=s===void 0?!0:s,l=n.fallbackPlacements,u=n.padding,c=n.boundary,d=n.rootBoundary,f=n.altBoundary,v=n.flipVariations,g=v===void 0?!0:v,S=n.allowedAutoPlacements,k=t.options.placement,m=wn(k),p=m===k,y=l||(p||!g?[Wa(k)]:v2(k)),E=[k].concat(y).reduce(function(X,re){return X.concat(wn(re)===hh?y2(t,{placement:re,boundary:c,rootBoundary:d,padding:u,flipVariations:g,allowedAutoPlacements:S}):re)},[]),C=t.rects.reference,x=t.rects.popper,b=new Map,O=!0,T=E[0],$=0;$=0,W=K?"width":"height",G=$s(t,{placement:A,boundary:c,rootBoundary:d,altBoundary:f,padding:u}),V=K?B?Ut:mt:B?zt:ht;C[W]>x[W]&&(V=Wa(V));var _=Wa(V),I=[];if(i&&I.push(G[U]<=0),a&&I.push(G[V]<=0,G[_]<=0),I.every(function(X){return X})){T=A,O=!1;break}b.set(A,I)}if(O)for(var F=g?3:1,Y=function(re){var ge=E.find(function(Me){var qe=b.get(Me);if(qe)return qe.slice(0,re).every(function(_t){return _t})});if(ge)return T=ge,"break"},Z=F;Z>0;Z--){var ve=Y(Z);if(ve==="break")break}t.placement!==T&&(t.modifiersData[r]._skip=!0,t.placement=T,t.reset=!0)}}const w2={name:"flip",enabled:!0,phase:"main",fn:g2,requiresIfExists:["offset"],data:{_skip:!1}};function Ky(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Gy(e){return[ht,Ut,zt,mt].some(function(t){return e[t]>=0})}function S2(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,i=t.modifiersData.preventOverflow,s=$s(t,{elementContext:"reference"}),a=$s(t,{altBoundary:!0}),l=Ky(s,r),u=Ky(a,o,i),c=Gy(l),d=Gy(u);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:c,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":d})}const x2={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:S2};function E2(e,t,n){var r=wn(e),o=[mt,ht].indexOf(r)>=0?-1:1,i=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,s=i[0],a=i[1];return s=s||0,a=(a||0)*o,[mt,Ut].indexOf(r)>=0?{x:a,y:s}:{x:s,y:a}}function k2(e){var t=e.state,n=e.options,r=e.name,o=n.offset,i=o===void 0?[0,0]:o,s=Xw.reduce(function(c,d){return c[d]=E2(d,t.rects,i),c},{}),a=s[t.placement],l=a.x,u=a.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=u),t.modifiersData[r]=s}const b2={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:k2};function C2(e){var t=e.state,n=e.name;t.modifiersData[n]=oS({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const O2={name:"popperOffsets",enabled:!0,phase:"read",fn:C2,data:{}};function $2(e){return e==="x"?"y":"x"}function _2(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,i=o===void 0?!0:o,s=n.altAxis,a=s===void 0?!1:s,l=n.boundary,u=n.rootBoundary,c=n.altBoundary,d=n.padding,f=n.tether,v=f===void 0?!0:f,g=n.tetherOffset,S=g===void 0?0:g,k=$s(t,{boundary:l,rootBoundary:u,padding:d,altBoundary:c}),m=wn(t.placement),p=ei(t.placement),y=!p,E=vh(m),C=$2(E),x=t.modifiersData.popperOffsets,b=t.rects.reference,O=t.rects.popper,T=typeof S=="function"?S(Object.assign({},t.rects,{placement:t.placement})):S,$=typeof T=="number"?{mainAxis:T,altAxis:T}:Object.assign({mainAxis:0,altAxis:0},T),A=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,U={x:0,y:0};if(x){if(i){var B,K=E==="y"?ht:mt,W=E==="y"?zt:Ut,G=E==="y"?"height":"width",V=x[E],_=V+k[K],I=V-k[W],F=v?-O[G]/2:0,Y=p===Xo?b[G]:O[G],Z=p===Xo?-O[G]:-b[G],ve=t.elements.arrow,X=v&&ve?yh(ve):{width:0,height:0},re=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:eS(),ge=re[K],Me=re[W],qe=es(0,b[G],X[G]),_t=y?b[G]/2-F-qe-ge-$.mainAxis:Y-qe-ge-$.mainAxis,_n=y?-b[G]/2+F+qe+Me+$.mainAxis:Z+qe+Me+$.mainAxis,Tn=t.elements.arrow&&Ws(t.elements.arrow),Rn=Tn?E==="y"?Tn.clientTop||0:Tn.clientLeft||0:0,Qe=(B=A==null?void 0:A[E])!=null?B:0,de=V+_t-Qe-Rn,H=V+_n-Qe,Ue=es(v?Ml(_,de):_,V,v?Dr(I,H):I);x[E]=Ue,U[E]=Ue-V}if(a){var nt,vt=E==="x"?ht:mt,vi=E==="x"?zt:Ut,we=x[C],Gt=C==="y"?"height":"width",eo=we+k[vt],to=we-k[vi],Rr=[ht,mt].indexOf(m)!==-1,gi=(nt=A==null?void 0:A[C])!=null?nt:0,no=Rr?eo:we-b[Gt]-O[Gt]-gi+$.altAxis,Zn=Rr?we+b[Gt]+O[Gt]-gi-$.altAxis:to,N=v&&Rr?JO(no,we,Zn):es(v?no:eo,we,v?Zn:to);x[C]=N,U[C]=N-we}t.modifiersData[r]=U}}const T2={name:"preventOverflow",enabled:!0,phase:"main",fn:_2,requiresIfExists:["offset"]};function R2(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function N2(e){return e===bt(e)||!Sn(e)?gh(e):R2(e)}function A2(e){var t=e.getBoundingClientRect(),n=Jo(t.width)/e.offsetWidth||1,r=Jo(t.height)/e.offsetHeight||1;return n!==1||r!==1}function P2(e,t,n){n===void 0&&(n=!1);var r=Sn(t),o=Sn(t)&&A2(t),i=$r(t),s=Zo(e,o,n),a={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(r||!r&&!n)&&((kr(t)!=="body"||Sh(i))&&(a=N2(t)),Sn(t)?(l=Zo(t,!0),l.x+=t.clientLeft,l.y+=t.clientTop):i&&(l.x=wh(i))),{x:s.left+a.scrollLeft-l.x,y:s.top+a.scrollTop-l.y,width:s.width,height:s.height}}function j2(e){var t=new Map,n=new Set,r=[];e.forEach(function(i){t.set(i.name,i)});function o(i){n.add(i.name);var s=[].concat(i.requires||[],i.requiresIfExists||[]);s.forEach(function(a){if(!n.has(a)){var l=t.get(a);l&&o(l)}}),r.push(i)}return e.forEach(function(i){n.has(i.name)||o(i)}),r}function L2(e){var t=j2(e);return QO.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function I2(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function M2(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qy={placement:"bottom",modifiers:[],strategy:"absolute"};function Qy(){for(var e=arguments.length,t=new Array(e),n=0;n=0)&&(n[o]=e[o]);return n}const U2={name:"applyStyles",enabled:!1,phase:"afterWrite",fn:()=>{}},W2={name:"ariaDescribedBy",enabled:!0,phase:"afterWrite",effect:({state:e})=>()=>{const{reference:t,popper:n}=e.elements;if("removeAttribute"in t){const r=(t.getAttribute("aria-describedby")||"").split(",").filter(o=>o.trim()!==n.id);r.length?t.setAttribute("aria-describedby",r.join(",")):t.removeAttribute("aria-describedby")}},fn:({state:e})=>{var t;const{popper:n,reference:r}=e.elements,o=(t=n.getAttribute("role"))==null?void 0:t.toLowerCase();if(n.id&&o==="tooltip"&&"setAttribute"in r){const i=r.getAttribute("aria-describedby");if(i&&i.split(",").indexOf(n.id)!==-1)return;r.setAttribute("aria-describedby",i?`${i},${n.id}`:n.id)}}},H2=[];function V2(e,t,n={}){let{enabled:r=!0,placement:o="bottom",strategy:i="absolute",modifiers:s=H2}=n,a=z2(n,F2);const l=h.useRef(s),u=h.useRef(),c=h.useCallback(()=>{var k;(k=u.current)==null||k.update()},[]),d=h.useCallback(()=>{var k;(k=u.current)==null||k.forceUpdate()},[]),[f,v]=MO(h.useState({placement:o,update:c,forceUpdate:d,attributes:{},styles:{popper:{},arrow:{}}})),g=h.useMemo(()=>({name:"updateStateModifier",enabled:!0,phase:"write",requires:["computeStyles"],fn:({state:k})=>{const m={},p={};Object.keys(k.elements).forEach(y=>{m[y]=k.styles[y],p[y]=k.attributes[y]}),v({state:k,styles:m,attributes:p,update:c,forceUpdate:d,placement:k.placement})}}),[c,d,v]),S=h.useMemo(()=>(Zi(l.current,s)||(l.current=s),l.current),[s]);return h.useEffect(()=>{!u.current||!r||u.current.setOptions({placement:o,strategy:i,modifiers:[...S,g,U2]})},[i,o,g,r,S]),h.useEffect(()=>{if(!(!r||e==null||t==null))return u.current=D2(e,t,Object.assign({},a,{placement:o,strategy:i,modifiers:[...S,W2,g]})),()=>{u.current!=null&&(u.current.destroy(),u.current=void 0,v(k=>Object.assign({},k,{attributes:{},styles:{popper:{}}})))}},[r,e,t]),f}function _s(e,t){if(e.contains)return e.contains(t);if(e.compareDocumentPosition)return e===t||!!(e.compareDocumentPosition(t)&16)}var K2=function(){},G2=K2;const q2=si(G2),Yy=()=>{};function Q2(e){return e.button===0}function Y2(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}const Ha=e=>e&&("current"in e?e.current:e),Xy={click:"mousedown",mouseup:"mousedown",pointerup:"pointerdown"};function X2(e,t=Yy,{disabled:n,clickTrigger:r="click"}={}){const o=h.useRef(!1),i=h.useRef(!1),s=h.useCallback(u=>{const c=Ha(e);q2(!!c,"ClickOutside captured a close event but does not have a ref to compare it to. useClickOutside(), should be passed a ref that resolves to a DOM node"),o.current=!c||Y2(u)||!Q2(u)||!!_s(c,u.target)||i.current,i.current=!1},[e]),a=it(u=>{const c=Ha(e);c&&_s(c,u.target)&&(i.current=!0)}),l=it(u=>{o.current||t(u)});h.useEffect(()=>{var u,c;if(n||e==null)return;const d=Is(Ha(e)),f=d.defaultView||window;let v=(u=f.event)!=null?u:(c=f.parent)==null?void 0:c.event,g=null;Xy[r]&&(g=Dn(d,Xy[r],a,!0));const S=Dn(d,r,s,!0),k=Dn(d,r,p=>{if(p===v){v=void 0;return}l(p)});let m=[];return"ontouchstart"in d.documentElement&&(m=[].slice.call(d.body.children).map(p=>Dn(p,"mousemove",Yy))),()=>{g==null||g(),S(),k(),m.forEach(p=>p())}},[e,n,r,s,a,l])}function J2(e){const t={};return Array.isArray(e)?(e==null||e.forEach(n=>{t[n.name]=n}),t):e||t}function Z2(e={}){return Array.isArray(e)?e:Object.keys(e).map(t=>(e[t].name=t,e[t]))}function e$({enabled:e,enableEvents:t,placement:n,flip:r,offset:o,fixed:i,containerPadding:s,arrowElement:a,popperConfig:l={}}){var u,c,d,f,v;const g=J2(l.modifiers);return Object.assign({},l,{placement:n,enabled:e,strategy:i?"fixed":l.strategy,modifiers:Z2(Object.assign({},g,{eventListeners:{enabled:t,options:(u=g.eventListeners)==null?void 0:u.options},preventOverflow:Object.assign({},g.preventOverflow,{options:s?Object.assign({padding:s},(c=g.preventOverflow)==null?void 0:c.options):(d=g.preventOverflow)==null?void 0:d.options}),offset:{options:Object.assign({offset:o},(f=g.offset)==null?void 0:f.options)},arrow:Object.assign({},g.arrow,{enabled:!!a,options:Object.assign({},(v=g.arrow)==null?void 0:v.options,{element:a})}),flip:Object.assign({enabled:!!r},g.flip)}))})}const t$=h.createContext(null),n$="data-rr-ui-";function r$(e){return`${n$}${e}`}const iS=h.createContext(ku?window:void 0);iS.Provider;function xh(){return h.useContext(iS)}const sS=h.createContext(null);sS.displayName="InputGroupContext";const ci=h.createContext(null);ci.displayName="NavbarContext";pe.string,pe.bool,pe.bool,pe.bool,pe.bool;const aS=h.forwardRef(({bsPrefix:e,className:t,fluid:n=!1,rounded:r=!1,roundedCircle:o=!1,thumbnail:i=!1,...s},a)=>(e=z(e,"img"),w.jsx("img",{ref:a,...s,className:M(t,n&&`${e}-fluid`,r&&"rounded",o&&"rounded-circle",i&&`${e}-thumbnail`)})));aS.displayName="Image";const o$={type:pe.string,tooltip:pe.bool,as:pe.elementType},$u=h.forwardRef(({as:e="div",className:t,type:n="valid",tooltip:r=!1,...o},i)=>w.jsx(e,{...o,ref:i,className:M(t,`${n}-${r?"tooltip":"feedback"}`)}));$u.displayName="Feedback";$u.propTypes=o$;const qn=h.createContext({}),Hs=h.forwardRef(({id:e,bsPrefix:t,className:n,type:r="checkbox",isValid:o=!1,isInvalid:i=!1,as:s="input",...a},l)=>{const{controlId:u}=h.useContext(qn);return t=z(t,"form-check-input"),w.jsx(s,{...a,ref:l,type:r,id:e||u,className:M(n,t,o&&"is-valid",i&&"is-invalid")})});Hs.displayName="FormCheckInput";const Bl=h.forwardRef(({bsPrefix:e,className:t,htmlFor:n,...r},o)=>{const{controlId:i}=h.useContext(qn);return e=z(e,"form-check-label"),w.jsx("label",{...r,ref:o,htmlFor:n||i,className:M(t,e)})});Bl.displayName="FormCheckLabel";const lS=h.forwardRef(({id:e,bsPrefix:t,bsSwitchPrefix:n,inline:r=!1,reverse:o=!1,disabled:i=!1,isValid:s=!1,isInvalid:a=!1,feedbackTooltip:l=!1,feedback:u,feedbackType:c,className:d,style:f,title:v="",type:g="checkbox",label:S,children:k,as:m="input",...p},y)=>{t=z(t,"form-check"),n=z(n,"form-switch");const{controlId:E}=h.useContext(qn),C=h.useMemo(()=>({controlId:e||E}),[E,e]),x=!k&&S!=null&&S!==!1||jO(k,Bl),b=w.jsx(Hs,{...p,type:g==="switch"?"checkbox":g,ref:y,isValid:s,isInvalid:a,disabled:i,as:m});return w.jsx(qn.Provider,{value:C,children:w.jsx("div",{style:f,className:M(d,x&&t,r&&`${t}-inline`,o&&`${t}-reverse`,g==="switch"&&n),children:k||w.jsxs(w.Fragment,{children:[b,x&&w.jsx(Bl,{title:v,children:S}),u&&w.jsx($u,{type:c,tooltip:l,children:u})]})})})});lS.displayName="FormCheck";const Dl=Object.assign(lS,{Input:Hs,Label:Bl}),uS=h.forwardRef(({bsPrefix:e,type:t,size:n,htmlSize:r,id:o,className:i,isValid:s=!1,isInvalid:a=!1,plaintext:l,readOnly:u,as:c="input",...d},f)=>{const{controlId:v}=h.useContext(qn);return e=z(e,"form-control"),w.jsx(c,{...d,type:t,size:r,ref:f,readOnly:u,id:o||v,className:M(i,l?`${e}-plaintext`:e,n&&`${e}-${n}`,t==="color"&&`${e}-color`,s&&"is-valid",a&&"is-invalid")})});uS.displayName="FormControl";const i$=Object.assign(uS,{Feedback:$u}),cS=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"form-floating"),w.jsx(n,{ref:o,className:M(e,t),...r})));cS.displayName="FormFloating";const Eh=h.forwardRef(({controlId:e,as:t="div",...n},r)=>{const o=h.useMemo(()=>({controlId:e}),[e]);return w.jsx(qn.Provider,{value:o,children:w.jsx(t,{...n,ref:r})})});Eh.displayName="FormGroup";const fS=h.forwardRef(({as:e="label",bsPrefix:t,column:n=!1,visuallyHidden:r=!1,className:o,htmlFor:i,...s},a)=>{const{controlId:l}=h.useContext(qn);t=z(t,"form-label");let u="col-form-label";typeof n=="string"&&(u=`${u} ${u}-${n}`);const c=M(o,t,r&&"visually-hidden",n&&u);return i=i||l,n?w.jsx(dn,{ref:a,as:"label",className:c,htmlFor:i,...s}):w.jsx(e,{ref:a,className:c,htmlFor:i,...s})});fS.displayName="FormLabel";const dS=h.forwardRef(({bsPrefix:e,className:t,id:n,...r},o)=>{const{controlId:i}=h.useContext(qn);return e=z(e,"form-range"),w.jsx("input",{...r,type:"range",ref:o,className:M(t,e),id:n||i})});dS.displayName="FormRange";const pS=h.forwardRef(({bsPrefix:e,size:t,htmlSize:n,className:r,isValid:o=!1,isInvalid:i=!1,id:s,...a},l)=>{const{controlId:u}=h.useContext(qn);return e=z(e,"form-select"),w.jsx("select",{...a,size:n,ref:l,className:M(r,e,t&&`${e}-${t}`,o&&"is-valid",i&&"is-invalid"),id:s||u})});pS.displayName="FormSelect";const hS=h.forwardRef(({bsPrefix:e,className:t,as:n="small",muted:r,...o},i)=>(e=z(e,"form-text"),w.jsx(n,{...o,ref:i,className:M(t,e,r&&"text-muted")})));hS.displayName="FormText";const mS=h.forwardRef((e,t)=>w.jsx(Dl,{...e,ref:t,type:"switch"}));mS.displayName="Switch";const s$=Object.assign(mS,{Input:Dl.Input,Label:Dl.Label}),yS=h.forwardRef(({bsPrefix:e,className:t,children:n,controlId:r,label:o,...i},s)=>(e=z(e,"form-floating"),w.jsxs(Eh,{ref:s,className:M(t,e),controlId:r,...i,children:[n,w.jsx("label",{htmlFor:r,children:o})]})));yS.displayName="FloatingLabel";const a$={_ref:pe.any,validated:pe.bool,as:pe.elementType},kh=h.forwardRef(({className:e,validated:t,as:n="form",...r},o)=>w.jsx(n,{...r,ref:o,className:M(e,t&&"was-validated")}));kh.displayName="Form";kh.propTypes=a$;const ot=Object.assign(kh,{Group:Eh,Control:i$,Floating:cS,Check:Dl,Switch:s$,Label:fS,Text:hS,Range:dS,Select:pS,FloatingLabel:yS}),_u=h.forwardRef(({className:e,bsPrefix:t,as:n="span",...r},o)=>(t=z(t,"input-group-text"),w.jsx(n,{ref:o,className:M(e,t),...r})));_u.displayName="InputGroupText";const l$=e=>w.jsx(_u,{children:w.jsx(Hs,{type:"checkbox",...e})}),u$=e=>w.jsx(_u,{children:w.jsx(Hs,{type:"radio",...e})}),vS=h.forwardRef(({bsPrefix:e,size:t,hasValidation:n,className:r,as:o="div",...i},s)=>{e=z(e,"input-group");const a=h.useMemo(()=>({}),[]);return w.jsx(sS.Provider,{value:a,children:w.jsx(o,{ref:s,...i,className:M(r,e,t&&`${e}-${t}`,n&&"has-validation")})})});vS.displayName="InputGroup";const Un=Object.assign(vS,{Text:_u,Radio:u$,Checkbox:l$});function Gc(e){e===void 0&&(e=Is());try{var t=e.activeElement;return!t||!t.nodeName?null:t}catch{return e.body}}function c$(e=document){const t=e.defaultView;return Math.abs(t.innerWidth-e.documentElement.clientWidth)}const Jy=r$("modal-open");class bh{constructor({ownerDocument:t,handleContainerOverflow:n=!0,isRTL:r=!1}={}){this.handleContainerOverflow=n,this.isRTL=r,this.modals=[],this.ownerDocument=t}getScrollbarWidth(){return c$(this.ownerDocument)}getElement(){return(this.ownerDocument||document).body}setModalAttributes(t){}removeModalAttributes(t){}setContainerStyle(t){const n={overflow:"hidden"},r=this.isRTL?"paddingLeft":"paddingRight",o=this.getElement();t.style={overflow:o.style.overflow,[r]:o.style[r]},t.scrollBarWidth&&(n[r]=`${parseInt(Fn(o,r)||"0",10)+t.scrollBarWidth}px`),o.setAttribute(Jy,""),Fn(o,n)}reset(){[...this.modals].forEach(t=>this.remove(t))}removeContainerStyle(t){const n=this.getElement();n.removeAttribute(Jy),Object.assign(n.style,t.style)}add(t){let n=this.modals.indexOf(t);return n!==-1||(n=this.modals.length,this.modals.push(t),this.setModalAttributes(t),n!==0)||(this.state={scrollBarWidth:this.getScrollbarWidth(),style:{}},this.handleContainerOverflow&&this.setContainerStyle(this.state)),n}remove(t){const n=this.modals.indexOf(t);n!==-1&&(this.modals.splice(n,1),!this.modals.length&&this.handleContainerOverflow&&this.removeContainerStyle(this.state),this.removeModalAttributes(t))}isTopModal(t){return!!this.modals.length&&this.modals[this.modals.length-1]===t}}const qc=(e,t)=>ku?e==null?(t||Is()).body:(typeof e=="function"&&(e=e()),e&&"current"in e&&(e=e.current),e&&("nodeType"in e||e.getBoundingClientRect)?e:null):null;function bd(e,t){const n=xh(),[r,o]=h.useState(()=>qc(e,n==null?void 0:n.document));if(!r){const i=qc(e);i&&o(i)}return h.useEffect(()=>{},[t,r]),h.useEffect(()=>{const i=qc(e);i!==r&&o(i)},[e,r]),r}function f$({children:e,in:t,onExited:n,mountOnEnter:r,unmountOnExit:o}){const i=h.useRef(null),s=h.useRef(t),a=it(n);h.useEffect(()=>{t?s.current=!0:a(i.current)},[t,a]);const l=Yr(i,e.ref),u=h.cloneElement(e,{ref:l});return t?u:o||!s.current&&r?null:u}function gS(e){return e.code==="Escape"||e.keyCode===27}function d$(){const e=h.version.split(".");return{major:+e[0],minor:+e[1],patch:+e[2]}}const p$=["onEnter","onEntering","onEntered","onExit","onExiting","onExited","addEndListener","children"];function h$(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i=0)&&(n[o]=e[o]);return n}function m$(e){let{onEnter:t,onEntering:n,onEntered:r,onExit:o,onExiting:i,onExited:s,addEndListener:a,children:l}=e,u=h$(e,p$);const{major:c}=d$(),d=c>=19?l.props.ref:l.ref,f=h.useRef(null),v=Yr(f,typeof l=="function"?null:d),g=x=>b=>{x&&f.current&&x(f.current,b)},S=h.useCallback(g(t),[t]),k=h.useCallback(g(n),[n]),m=h.useCallback(g(r),[r]),p=h.useCallback(g(o),[o]),y=h.useCallback(g(i),[i]),E=h.useCallback(g(s),[s]),C=h.useCallback(g(a),[a]);return Object.assign({},u,{nodeRef:f},t&&{onEnter:S},n&&{onEntering:k},r&&{onEntered:m},o&&{onExit:p},i&&{onExiting:y},s&&{onExited:E},a&&{addEndListener:C},{children:typeof l=="function"?(x,b)=>l(x,Object.assign({},b,{ref:v})):h.cloneElement(l,{ref:v})})}const y$=["component"];function v$(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i=0)&&(n[o]=e[o]);return n}const g$=h.forwardRef((e,t)=>{let{component:n}=e,r=v$(e,y$);const o=m$(r);return w.jsx(n,Object.assign({ref:t},o))});function w$({in:e,onTransition:t}){const n=h.useRef(null),r=h.useRef(!0),o=it(t);return Il(()=>{if(!n.current)return;let i=!1;return o({in:e,element:n.current,initial:r.current,isStale:()=>i}),()=>{i=!0}},[e,o]),Il(()=>(r.current=!1,()=>{r.current=!0}),[]),n}function S$({children:e,in:t,onExited:n,onEntered:r,transition:o}){const[i,s]=h.useState(!t);t&&i&&s(!1);const a=w$({in:!!t,onTransition:u=>{const c=()=>{u.isStale()||(u.in?r==null||r(u.element,u.initial):(s(!0),n==null||n(u.element)))};Promise.resolve(o(u)).then(c,d=>{throw u.in||s(!0),d})}}),l=Yr(a,e.ref);return i&&!t?null:h.cloneElement(e,{ref:l})}function Cd(e,t,n){return e?w.jsx(g$,Object.assign({},n,{component:e})):t?w.jsx(S$,Object.assign({},n,{transition:t})):w.jsx(f$,Object.assign({},n))}const x$=["show","role","className","style","children","backdrop","keyboard","onBackdropClick","onEscapeKeyDown","transition","runTransition","backdropTransition","runBackdropTransition","autoFocus","enforceFocus","restoreFocus","restoreFocusOptions","renderDialog","renderBackdrop","manager","container","onShow","onHide","onExit","onExited","onExiting","onEnter","onEntering","onEntered"];function E$(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i=0)&&(n[o]=e[o]);return n}let Qc;function k$(e){return Qc||(Qc=new bh({ownerDocument:e==null?void 0:e.document})),Qc}function b$(e){const t=xh(),n=e||k$(t),r=h.useRef({dialog:null,backdrop:null});return Object.assign(r.current,{add:()=>n.add(r.current),remove:()=>n.remove(r.current),isTopModal:()=>n.isTopModal(r.current),setDialogRef:h.useCallback(o=>{r.current.dialog=o},[]),setBackdropRef:h.useCallback(o=>{r.current.backdrop=o},[])})}const wS=h.forwardRef((e,t)=>{let{show:n=!1,role:r="dialog",className:o,style:i,children:s,backdrop:a=!0,keyboard:l=!0,onBackdropClick:u,onEscapeKeyDown:c,transition:d,runTransition:f,backdropTransition:v,runBackdropTransition:g,autoFocus:S=!0,enforceFocus:k=!0,restoreFocus:m=!0,restoreFocusOptions:p,renderDialog:y,renderBackdrop:E=H=>w.jsx("div",Object.assign({},H)),manager:C,container:x,onShow:b,onHide:O=()=>{},onExit:T,onExited:$,onExiting:A,onEnter:U,onEntering:B,onEntered:K}=e,W=E$(e,x$);const G=xh(),V=bd(x),_=b$(C),I=dh(),F=EO(n),[Y,Z]=h.useState(!n),ve=h.useRef(null);h.useImperativeHandle(t,()=>_,[_]),ku&&!F&&n&&(ve.current=Gc(G==null?void 0:G.document)),n&&Y&&Z(!1);const X=it(()=>{if(_.add(),_n.current=Dn(document,"keydown",qe),_t.current=Dn(document,"focus",()=>setTimeout(ge),!0),b&&b(),S){var H,Ue;const nt=Gc((H=(Ue=_.dialog)==null?void 0:Ue.ownerDocument)!=null?H:G==null?void 0:G.document);_.dialog&&nt&&!_s(_.dialog,nt)&&(ve.current=nt,_.dialog.focus())}}),re=it(()=>{if(_.remove(),_n.current==null||_n.current(),_t.current==null||_t.current(),m){var H;(H=ve.current)==null||H.focus==null||H.focus(p),ve.current=null}});h.useEffect(()=>{!n||!V||X()},[n,V,X]),h.useEffect(()=>{Y&&re()},[Y,re]),Kw(()=>{re()});const ge=it(()=>{if(!k||!I()||!_.isTopModal())return;const H=Gc(G==null?void 0:G.document);_.dialog&&H&&!_s(_.dialog,H)&&_.dialog.focus()}),Me=it(H=>{H.target===H.currentTarget&&(u==null||u(H),a===!0&&O())}),qe=it(H=>{l&&gS(H)&&_.isTopModal()&&(c==null||c(H),H.defaultPrevented||O())}),_t=h.useRef(),_n=h.useRef(),Tn=(...H)=>{Z(!0),$==null||$(...H)};if(!V)return null;const Rn=Object.assign({role:r,ref:_.setDialogRef,"aria-modal":r==="dialog"?!0:void 0},W,{style:i,className:o,tabIndex:-1});let Qe=y?y(Rn):w.jsx("div",Object.assign({},Rn,{children:h.cloneElement(s,{role:"document"})}));Qe=Cd(d,f,{unmountOnExit:!0,mountOnEnter:!0,appear:!0,in:!!n,onExit:T,onExiting:A,onExited:Tn,onEnter:U,onEntering:B,onEntered:K,children:Qe});let de=null;return a&&(de=E({ref:_.setBackdropRef,onClick:Me}),de=Cd(v,g,{in:!!n,appear:!0,mountOnEnter:!0,unmountOnExit:!0,children:de})),w.jsx(w.Fragment,{children:Ir.createPortal(w.jsxs(w.Fragment,{children:[de,Qe]}),V)})});wS.displayName="Modal";const C$=Object.assign(wS,{Manager:bh});function Od(e,t){return e.classList?!!t&&e.classList.contains(t):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")!==-1}function O$(e,t){e.classList?e.classList.add(t):Od(e,t)||(typeof e.className=="string"?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}function Zy(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function $$(e,t){e.classList?e.classList.remove(t):typeof e.className=="string"?e.className=Zy(e.className,t):e.setAttribute("class",Zy(e.className&&e.className.baseVal||"",t))}const ao={FIXED_CONTENT:".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",STICKY_CONTENT:".sticky-top",NAVBAR_TOGGLER:".navbar-toggler"};class SS extends bh{adjustAndStore(t,n,r){const o=n.style[t];n.dataset[t]=o,Fn(n,{[t]:`${parseFloat(Fn(n,t))+r}px`})}restore(t,n){const r=n.dataset[t];r!==void 0&&(delete n.dataset[t],Fn(n,{[t]:r}))}setContainerStyle(t){super.setContainerStyle(t);const n=this.getElement();if(O$(n,"modal-open"),!t.scrollBarWidth)return;const r=this.isRTL?"paddingLeft":"paddingRight",o=this.isRTL?"marginLeft":"marginRight";so(n,ao.FIXED_CONTENT).forEach(i=>this.adjustAndStore(r,i,t.scrollBarWidth)),so(n,ao.STICKY_CONTENT).forEach(i=>this.adjustAndStore(o,i,-t.scrollBarWidth)),so(n,ao.NAVBAR_TOGGLER).forEach(i=>this.adjustAndStore(o,i,t.scrollBarWidth))}removeContainerStyle(t){super.removeContainerStyle(t);const n=this.getElement();$$(n,"modal-open");const r=this.isRTL?"paddingLeft":"paddingRight",o=this.isRTL?"marginLeft":"marginRight";so(n,ao.FIXED_CONTENT).forEach(i=>this.restore(r,i)),so(n,ao.STICKY_CONTENT).forEach(i=>this.restore(o,i)),so(n,ao.NAVBAR_TOGGLER).forEach(i=>this.restore(o,i))}}let Yc;function _$(e){return Yc||(Yc=new SS(e)),Yc}const xS=h.createContext({onHide(){}}),T$=h.forwardRef(({closeLabel:e="Close",closeVariant:t,closeButton:n=!1,onHide:r,children:o,...i},s)=>{const a=h.useContext(xS),l=it(()=>{a==null||a.onHide(),r==null||r()});return w.jsxs("div",{ref:s,...i,children:[o,n&&w.jsx(Cu,{"aria-label":e,variant:t,onClick:l})]})}),ES=h.forwardRef(({bsPrefix:e,className:t,as:n,...r},o)=>{e=z(e,"navbar-brand");const i=n||(r.href?"a":"span");return w.jsx(i,{...r,ref:o,className:M(t,e)})});ES.displayName="NavbarBrand";const kS=h.forwardRef(({children:e,bsPrefix:t,...n},r)=>{t=z(t,"navbar-collapse");const o=h.useContext(ci);return w.jsx(bu,{in:!!(o&&o.expanded),...n,children:w.jsx("div",{ref:r,className:t,children:e})})});kS.displayName="NavbarCollapse";const bS=h.forwardRef(({bsPrefix:e,className:t,children:n,label:r="Toggle navigation",as:o="button",onClick:i,...s},a)=>{e=z(e,"navbar-toggler");const{onToggle:l,expanded:u}=h.useContext(ci)||{},c=it(d=>{i&&i(d),l&&l()});return o==="button"&&(s.type="button"),w.jsx(o,{...s,ref:a,onClick:c,"aria-label":r,className:M(t,e,!u&&"collapsed"),children:n||w.jsx("span",{className:`${e}-icon`})})});bS.displayName="NavbarToggle";const $d=new WeakMap,ev=(e,t)=>{if(!e||!t)return;const n=$d.get(t)||new Map;$d.set(t,n);let r=n.get(e);return r||(r=t.matchMedia(e),r.refCount=0,n.set(r.media,r)),r};function R$(e,t=typeof window>"u"?void 0:window){const n=ev(e,t),[r,o]=h.useState(()=>n?n.matches:!1);return Il(()=>{let i=ev(e,t);if(!i)return o(!1);let s=$d.get(t);const a=()=>{o(i.matches)};return i.refCount++,i.addListener(a),a(),()=>{i.removeListener(a),i.refCount--,i.refCount<=0&&(s==null||s.delete(i.media)),i=void 0}},[e]),r}function N$(e){const t=Object.keys(e);function n(a,l){return a===l?l:a?`${a} and ${l}`:l}function r(a){return t[Math.min(t.indexOf(a)+1,t.length-1)]}function o(a){const l=r(a);let u=e[l];return typeof u=="number"?u=`${u-.2}px`:u=`calc(${u} - 0.2px)`,`(max-width: ${u})`}function i(a){let l=e[a];return typeof l=="number"&&(l=`${l}px`),`(min-width: ${l})`}function s(a,l,u){let c;typeof a=="object"?(c=a,u=l,l=!0):(l=l||!0,c={[a]:l});let d=h.useMemo(()=>Object.entries(c).reduce((f,[v,g])=>((g==="up"||g===!0)&&(f=n(f,i(v))),(g==="down"||g===!0)&&(f=n(f,o(v))),f),""),[JSON.stringify(c)]);return R$(d,u)}return s}const A$=N$({xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400}),CS=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"offcanvas-body"),w.jsx(n,{ref:o,className:M(e,t),...r})));CS.displayName="OffcanvasBody";const P$={[Pt]:"show",[In]:"show"},OS=h.forwardRef(({bsPrefix:e,className:t,children:n,in:r=!1,mountOnEnter:o=!1,unmountOnExit:i=!1,appear:s=!1,...a},l)=>(e=z(e,"offcanvas"),w.jsx(ch,{ref:l,addEndListener:uh,in:r,mountOnEnter:o,unmountOnExit:i,appear:s,...a,childRef:n.ref,children:(u,c)=>h.cloneElement(n,{...c,className:M(t,n.props.className,(u===Pt||u===Yo)&&`${e}-toggling`,P$[u])})})));OS.displayName="OffcanvasToggling";const $S=h.forwardRef(({bsPrefix:e,className:t,closeLabel:n="Close",closeButton:r=!1,...o},i)=>(e=z(e,"offcanvas-header"),w.jsx(T$,{ref:i,...o,className:M(t,e),closeLabel:n,closeButton:r})));$S.displayName="OffcanvasHeader";const j$=fh("h5"),_S=h.forwardRef(({className:e,bsPrefix:t,as:n=j$,...r},o)=>(t=z(t,"offcanvas-title"),w.jsx(n,{ref:o,className:M(e,t),...r})));_S.displayName="OffcanvasTitle";function L$(e){return w.jsx(OS,{...e})}function I$(e){return w.jsx(Cs,{...e})}const TS=h.forwardRef(({bsPrefix:e,className:t,children:n,"aria-labelledby":r,placement:o="start",responsive:i,show:s=!1,backdrop:a=!0,keyboard:l=!0,scroll:u=!1,onEscapeKeyDown:c,onShow:d,onHide:f,container:v,autoFocus:g=!0,enforceFocus:S=!0,restoreFocus:k=!0,restoreFocusOptions:m,onEntered:p,onExit:y,onExiting:E,onEnter:C,onEntering:x,onExited:b,backdropClassName:O,manager:T,renderStaticNode:$=!1,...A},U)=>{const B=h.useRef();e=z(e,"offcanvas");const{onToggle:K}=h.useContext(ci)||{},[W,G]=h.useState(!1),V=A$(i||"xs","up");h.useEffect(()=>{G(i?s&&!V:s)},[s,i,V]);const _=it(()=>{K==null||K(),f==null||f()}),I=h.useMemo(()=>({onHide:_}),[_]);function F(){return T||(u?(B.current||(B.current=new SS({handleContainerOverflow:!1})),B.current):_$())}const Y=(re,...ge)=>{re&&(re.style.visibility="visible"),C==null||C(re,...ge)},Z=(re,...ge)=>{re&&(re.style.visibility=""),b==null||b(...ge)},ve=h.useCallback(re=>w.jsx("div",{...re,className:M(`${e}-backdrop`,O)}),[O,e]),X=re=>w.jsx("div",{...re,...A,className:M(t,i?`${e}-${i}`:e,`${e}-${o}`),"aria-labelledby":r,children:n});return w.jsxs(w.Fragment,{children:[!W&&(i||$)&&X({}),w.jsx(xS.Provider,{value:I,children:w.jsx(C$,{show:W,ref:U,backdrop:a,container:v,keyboard:l,autoFocus:g,enforceFocus:S&&!u,restoreFocus:k,restoreFocusOptions:m,onEscapeKeyDown:c,onShow:d,onHide:_,onEnter:Y,onEntering:x,onEntered:p,onExit:y,onExiting:E,onExited:Z,manager:F(),transition:L$,backdropTransition:I$,renderBackdrop:ve,renderDialog:X})})]})});TS.displayName="Offcanvas";const Fi=Object.assign(TS,{Body:CS,Header:$S,Title:_S}),RS=h.forwardRef((e,t)=>{const n=h.useContext(ci);return w.jsx(Fi,{ref:t,show:!!(n!=null&&n.expanded),...e,renderStaticNode:!0})});RS.displayName="NavbarOffcanvas";const NS=h.forwardRef(({className:e,bsPrefix:t,as:n="span",...r},o)=>(t=z(t,"navbar-text"),w.jsx(n,{ref:o,className:M(e,t),...r})));NS.displayName="NavbarText";const AS=h.forwardRef((e,t)=>{const{bsPrefix:n,expand:r=!0,variant:o="light",bg:i,fixed:s,sticky:a,className:l,as:u="nav",expanded:c,onToggle:d,onSelect:f,collapseOnSelect:v=!1,...g}=Hk(e,{expanded:"onToggle"}),S=z(n,"navbar"),k=h.useCallback((...y)=>{f==null||f(...y),v&&c&&(d==null||d(!1))},[f,v,c,d]);g.role===void 0&&u!=="nav"&&(g.role="navigation");let m=`${S}-expand`;typeof r=="string"&&(m=`${m}-${r}`);const p=h.useMemo(()=>({onToggle:()=>d==null?void 0:d(!c),bsPrefix:S,expanded:!!c,expand:r}),[S,c,r,d]);return w.jsx(ci.Provider,{value:p,children:w.jsx(t$.Provider,{value:k,children:w.jsx(u,{ref:t,...g,className:M(l,S,r&&m,o&&`${S}-${o}`,i&&`bg-${i}`,a&&`sticky-${a}`,s&&`fixed-${s}`)})})})});AS.displayName="Navbar";const Xc=Object.assign(AS,{Brand:ES,Collapse:kS,Offcanvas:RS,Text:NS,Toggle:bS}),M$=()=>{};function B$(e,t,{disabled:n,clickTrigger:r}={}){const o=t||M$;X2(e,o,{disabled:n,clickTrigger:r});const i=it(s=>{gS(s)&&o(s)});h.useEffect(()=>{if(n||e==null)return;const s=Is(Ha(e));let a=(s.defaultView||window).event;const l=Dn(s,"keyup",u=>{if(u===a){a=void 0;return}i(u)});return()=>{l()}},[e,n,i])}const PS=h.forwardRef((e,t)=>{const{flip:n,offset:r,placement:o,containerPadding:i,popperConfig:s={},transition:a,runTransition:l}=e,[u,c]=By(),[d,f]=By(),v=Yr(c,t),g=bd(e.container),S=bd(e.target),[k,m]=h.useState(!e.show),p=V2(S,u,e$({placement:o,enableEvents:!!e.show,containerPadding:i||5,flip:n,offset:r,arrowElement:d,popperConfig:s}));e.show&&k&&m(!1);const y=(...A)=>{m(!0),e.onExited&&e.onExited(...A)},E=e.show||!k;if(B$(u,e.onHide,{disabled:!e.rootClose||e.rootCloseDisabled,clickTrigger:e.rootCloseEvent}),!E)return null;const{onExit:C,onExiting:x,onEnter:b,onEntering:O,onEntered:T}=e;let $=e.children(Object.assign({},p.attributes.popper,{style:p.styles.popper,ref:v}),{popper:p,placement:o,show:!!e.show,arrowProps:Object.assign({},p.attributes.arrow,{style:p.styles.arrow,ref:f})});return $=Cd(a,l,{in:!!e.show,appear:!0,mountOnEnter:!0,unmountOnExit:!0,children:$,onExit:C,onExiting:x,onExited:y,onEnter:b,onEntering:O,onEntered:T}),g?Ir.createPortal($,g):null});PS.displayName="Overlay";const jS=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"popover-header"),w.jsx(n,{ref:o,className:M(e,t),...r})));jS.displayName="PopoverHeader";const Ch=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"popover-body"),w.jsx(n,{ref:o,className:M(e,t),...r})));Ch.displayName="PopoverBody";function LS(e,t){let n=e;return e==="left"?n=t?"end":"start":e==="right"&&(n=t?"start":"end"),n}function IS(e="absolute"){return{position:e,top:"0",left:"0",opacity:"0",pointerEvents:"none"}}const D$=h.forwardRef(({bsPrefix:e,placement:t="right",className:n,style:r,children:o,body:i,arrowProps:s,hasDoneInitialMeasure:a,popper:l,show:u,...c},d)=>{const f=z(e,"popover"),v=O0(),[g]=(t==null?void 0:t.split("-"))||[],S=LS(g,v);let k=r;return u&&!a&&(k={...r,...IS(l==null?void 0:l.strategy)}),w.jsxs("div",{ref:d,role:"tooltip",style:k,"x-placement":g,className:M(n,f,g&&`bs-popover-${S}`),...c,children:[w.jsx("div",{className:"popover-arrow",...s}),i?w.jsx(Ch,{children:o}):o]})}),F$=Object.assign(D$,{Header:jS,Body:Ch,POPPER_OFFSET:[0,8]}),MS=h.forwardRef(({bsPrefix:e,placement:t="right",className:n,style:r,children:o,arrowProps:i,hasDoneInitialMeasure:s,popper:a,show:l,...u},c)=>{e=z(e,"tooltip");const d=O0(),[f]=(t==null?void 0:t.split("-"))||[],v=LS(f,d);let g=r;return l&&!s&&(g={...r,...IS(a==null?void 0:a.strategy)}),w.jsxs("div",{ref:c,style:g,role:"tooltip","x-placement":f,className:M(n,e,`bs-tooltip-${v}`),...u,children:[w.jsx("div",{className:"tooltip-arrow",...i}),w.jsx("div",{className:`${e}-inner`,children:o})]})});MS.displayName="Tooltip";const BS=Object.assign(MS,{TOOLTIP_OFFSET:[0,6]});function z$(e){const t=h.useRef(null),n=z(void 0,"popover"),r=z(void 0,"tooltip"),o=h.useMemo(()=>({name:"offset",options:{offset:()=>{if(e)return e;if(t.current){if(Od(t.current,n))return F$.POPPER_OFFSET;if(Od(t.current,r))return BS.TOOLTIP_OFFSET}return[0,0]}}}),[e,n,r]);return[t,[o]]}function U$(e,t){const{ref:n}=e,{ref:r}=t;e.ref=n.__wrapped||(n.__wrapped=o=>n(Ll(o))),t.ref=r.__wrapped||(r.__wrapped=o=>r(Ll(o)))}const DS=h.forwardRef(({children:e,transition:t=Cs,popperConfig:n={},rootClose:r=!1,placement:o="top",show:i=!1,...s},a)=>{const l=h.useRef({}),[u,c]=h.useState(null),[d,f]=z$(s.offset),v=Yr(a,d),g=t===!0?Cs:t||void 0,S=it(k=>{c(k),n==null||n.onFirstUpdate==null||n.onFirstUpdate(k)});return Il(()=>{u&&s.target&&(l.current.scheduleUpdate==null||l.current.scheduleUpdate())},[u,s.target]),h.useEffect(()=>{i||c(null)},[i]),w.jsx(PS,{...s,ref:v,popperConfig:{...n,modifiers:f.concat(n.modifiers||[]),onFirstUpdate:S},transition:g,rootClose:r,placement:o,show:i,children:(k,{arrowProps:m,popper:p,show:y})=>{var E;U$(k,m);const C=p==null?void 0:p.placement,x=Object.assign(l.current,{state:p==null?void 0:p.state,scheduleUpdate:p==null?void 0:p.update,placement:C,outOfBoundaries:(p==null||(E=p.state)==null||(E=E.modifiersData.hide)==null?void 0:E.isReferenceHidden)||!1,strategy:n.strategy}),b=!!u;return typeof e=="function"?e({...k,placement:C,show:y,...!t&&y&&{className:"show"},popper:x,arrowProps:m,hasDoneInitialMeasure:b}):h.cloneElement(e,{...k,placement:C,arrowProps:m,popper:x,hasDoneInitialMeasure:b,className:M(e.props.className,!t&&y&&"show"),style:{...e.props.style,...k.style}})}})});DS.displayName="Overlay";function W$(e){return e&&typeof e=="object"?e:{show:e,hide:e}}function tv(e,t,n){const[r]=t,o=r.currentTarget,i=r.relatedTarget||r.nativeEvent[n];(!i||i!==o)&&!_s(o,i)&&e(...t)}pe.oneOf(["click","hover","focus"]);const H$=({trigger:e=["hover","focus"],overlay:t,children:n,popperConfig:r={},show:o,defaultShow:i=!1,onToggle:s,delay:a,placement:l,flip:u=l&&l.indexOf("auto")!==-1,...c})=>{const d=h.useRef(null),f=Yr(d,n.ref),v=qw(),g=h.useRef(""),[S,k]=k0(o,i,s),m=W$(a),{onFocus:p,onBlur:y,onClick:E}=typeof n!="function"?h.Children.only(n).props:{},C=W=>{f(Ll(W))},x=h.useCallback(()=>{if(v.clear(),g.current="show",!m.show){k(!0);return}v.set(()=>{g.current==="show"&&k(!0)},m.show)},[m.show,k,v]),b=h.useCallback(()=>{if(v.clear(),g.current="hide",!m.hide){k(!1);return}v.set(()=>{g.current==="hide"&&k(!1)},m.hide)},[m.hide,k,v]),O=h.useCallback((...W)=>{x(),p==null||p(...W)},[x,p]),T=h.useCallback((...W)=>{b(),y==null||y(...W)},[b,y]),$=h.useCallback((...W)=>{k(!S),E==null||E(...W)},[E,k,S]),A=h.useCallback((...W)=>{tv(x,W,"fromElement")},[x]),U=h.useCallback((...W)=>{tv(b,W,"toElement")},[b]),B=e==null?[]:[].concat(e),K={ref:C};return B.indexOf("click")!==-1&&(K.onClick=$),B.indexOf("focus")!==-1&&(K.onFocus=O,K.onBlur=T),B.indexOf("hover")!==-1&&(K.onMouseOver=A,K.onMouseOut=U),w.jsxs(w.Fragment,{children:[typeof n=="function"?n(K):h.cloneElement(n,K),w.jsx(DS,{...c,show:S,onHide:b,flip:u,placement:l,popperConfig:r,target:d.current,children:t})]})},Fl=h.forwardRef(({bsPrefix:e,className:t,as:n="div",...r},o)=>{const i=z(e,"row"),s=b0(),a=C0(),l=`${i}-cols`,u=[];return s.forEach(c=>{const d=r[c];delete r[c];let f;d!=null&&typeof d=="object"?{cols:f}=d:f=d;const v=c!==a?`-${c}`:"";f!=null&&u.push(`${l}${v}-${f}`)}),w.jsx(n,{ref:o,...r,className:M(t,i,...u)})});Fl.displayName="Row";const FS=h.forwardRef(({bsPrefix:e,variant:t,animation:n="border",size:r,as:o="div",className:i,...s},a)=>{e=z(e,"spinner");const l=`${e}-${n}`;return w.jsx(o,{ref:a,...s,className:M(i,l,r&&`${l}-${r}`,t&&`text-${t}`)})});FS.displayName="Spinner";const V$={[Pt]:"showing",[Yo]:"showing show"},zS=h.forwardRef((e,t)=>w.jsx(Cs,{...e,ref:t,transitionClasses:V$}));zS.displayName="ToastFade";const US=h.createContext({onClose(){}}),WS=h.forwardRef(({bsPrefix:e,closeLabel:t="Close",closeVariant:n,closeButton:r=!0,className:o,children:i,...s},a)=>{e=z(e,"toast-header");const l=h.useContext(US),u=it(c=>{l==null||l.onClose==null||l.onClose(c)});return w.jsxs("div",{ref:a,...s,className:M(e,o),children:[i,r&&w.jsx(Cu,{"aria-label":t,variant:n,onClick:u,"data-dismiss":"toast"})]})});WS.displayName="ToastHeader";const HS=h.forwardRef(({className:e,bsPrefix:t,as:n="div",...r},o)=>(t=z(t,"toast-body"),w.jsx(n,{ref:o,className:M(e,t),...r})));HS.displayName="ToastBody";const VS=h.forwardRef(({bsPrefix:e,className:t,transition:n=zS,show:r=!0,animation:o=!0,delay:i=5e3,autohide:s=!1,onClose:a,onEntered:l,onExit:u,onExiting:c,onEnter:d,onEntering:f,onExited:v,bg:g,...S},k)=>{e=z(e,"toast");const m=h.useRef(i),p=h.useRef(a);h.useEffect(()=>{m.current=i,p.current=a},[i,a]);const y=qw(),E=!!(s&&r),C=h.useCallback(()=>{E&&(p.current==null||p.current())},[E]);h.useEffect(()=>{y.set(C,m.current)},[y,C]);const x=h.useMemo(()=>({onClose:a}),[a]),b=!!(n&&o),O=w.jsx("div",{...S,ref:k,className:M(e,t,g&&`bg-${g}`,!b&&(r?"show":"hide")),role:"alert","aria-live":"assertive","aria-atomic":"true"});return w.jsx(US.Provider,{value:x,children:b&&n?w.jsx(n,{in:r,onEnter:d,onEntering:f,onEntered:l,onExit:u,onExiting:c,onExited:v,unmountOnExit:!0,children:O}):O})});VS.displayName="Toast";const ns=Object.assign(VS,{Body:HS,Header:WS}),K$={"top-start":"top-0 start-0","top-center":"top-0 start-50 translate-middle-x","top-end":"top-0 end-0","middle-start":"top-50 start-0 translate-middle-y","middle-center":"top-50 start-50 translate-middle","middle-end":"top-50 end-0 translate-middle-y","bottom-start":"bottom-0 start-0","bottom-center":"bottom-0 start-50 translate-middle-x","bottom-end":"bottom-0 end-0"},Oh=h.forwardRef(({bsPrefix:e,position:t,containerPosition:n,className:r,as:o="div",...i},s)=>(e=z(e,"toast-container"),w.jsx(o,{ref:s,...i,className:M(e,t&&K$[t],n&&`position-${n}`,r)})));Oh.displayName="ToastContainer";const G$=()=>{},$h=h.forwardRef(({bsPrefix:e,name:t,className:n,checked:r,type:o,onChange:i,value:s,disabled:a,id:l,inputRef:u,...c},d)=>(e=z(e,"btn-check"),w.jsxs(w.Fragment,{children:[w.jsx("input",{className:e,name:t,type:o,value:s,ref:u,autoComplete:"off",checked:!!r,disabled:!!a,onChange:i||G$,id:l}),w.jsx(zs,{...c,ref:d,className:M(n,a&&"disabled"),type:void 0,role:void 0,as:"label",htmlFor:l})]})));$h.displayName="ToggleButton";const bn=Object.create(null);bn.open="0";bn.close="1";bn.ping="2";bn.pong="3";bn.message="4";bn.upgrade="5";bn.noop="6";const Va=Object.create(null);Object.keys(bn).forEach(e=>{Va[bn[e]]=e});const _d={type:"error",data:"parser error"},KS=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",GS=typeof ArrayBuffer=="function",qS=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,_h=({type:e,data:t},n,r)=>KS&&t instanceof Blob?n?r(t):nv(t,r):GS&&(t instanceof ArrayBuffer||qS(t))?n?r(t):nv(new Blob([t]),r):r(bn[e]+(t||"")),nv=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function rv(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let Jc;function q$(e,t){if(KS&&e.data instanceof Blob)return e.data.arrayBuffer().then(rv).then(t);if(GS&&(e.data instanceof ArrayBuffer||qS(e.data)))return t(rv(e.data));_h(e,!1,n=>{Jc||(Jc=new TextEncoder),t(Jc.encode(n))})}const ov="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",zi=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let e=0;e{let t=e.length*.75,n=e.length,r,o=0,i,s,a,l;e[e.length-1]==="="&&(t--,e[e.length-2]==="="&&t--);const u=new ArrayBuffer(t),c=new Uint8Array(u);for(r=0;r>4,c[o++]=(s&15)<<4|a>>2,c[o++]=(a&3)<<6|l&63;return u},Y$=typeof ArrayBuffer=="function",Th=(e,t)=>{if(typeof e!="string")return{type:"message",data:QS(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:X$(e.substring(1),t)}:Va[n]?e.length>1?{type:Va[n],data:e.substring(1)}:{type:Va[n]}:_d},X$=(e,t)=>{if(Y$){const n=Q$(e);return QS(n,t)}else return{base64:!0,data:e}},QS=(e,t)=>{switch(t){case"blob":return e instanceof Blob?e:new Blob([e]);case"arraybuffer":default:return e instanceof ArrayBuffer?e:e.buffer}},YS="",J$=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((i,s)=>{_h(i,!1,a=>{r[s]=a,++o===n&&t(r.join(YS))})})},Z$=(e,t)=>{const n=e.split(YS),r=[];for(let o=0;o{const r=n.length;let o;if(r<126)o=new Uint8Array(1),new DataView(o.buffer).setUint8(0,r);else if(r<65536){o=new Uint8Array(3);const i=new DataView(o.buffer);i.setUint8(0,126),i.setUint16(1,r)}else{o=new Uint8Array(9);const i=new DataView(o.buffer);i.setUint8(0,127),i.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(o[0]|=128),t.enqueue(o),t.enqueue(n)})}})}let Zc;function va(e){return e.reduce((t,n)=>t+n.length,0)}function ga(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let o=0;oMath.pow(2,21)-1){a.enqueue(_d);break}o=c*Math.pow(2,32)+u.getUint32(4),r=3}else{if(va(n)e){a.enqueue(_d);break}}}})}const XS=4;function je(e){if(e)return n_(e)}function n_(e){for(var t in je.prototype)e[t]=je.prototype[t];return e}je.prototype.on=je.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this};je.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this};je.prototype.off=je.prototype.removeListener=je.prototype.removeAllListeners=je.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks["$"+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var r,o=0;o(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const r_=jt.setTimeout,o_=jt.clearTimeout;function Tu(e,t){t.useNativeTimers?(e.setTimeoutFn=r_.bind(jt),e.clearTimeoutFn=o_.bind(jt)):(e.setTimeoutFn=jt.setTimeout.bind(jt),e.clearTimeoutFn=jt.clearTimeout.bind(jt))}const i_=1.33;function s_(e){return typeof e=="string"?a_(e):Math.ceil((e.byteLength||e.size)*i_)}function a_(e){let t=0,n=0;for(let r=0,o=e.length;r=57344?n+=3:(r++,n+=4);return n}function l_(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function u_(e){let t={},n=e.split("&");for(let r=0,o=n.length;r0);return t}function ex(){const e=av(+new Date);return e!==sv?(iv=0,sv=e):e+"."+av(iv++)}for(;wa{this.readyState="paused",t()};if(this.polling||!this.writable){let r=0;this.polling&&(r++,this.once("pollComplete",function(){--r||n()})),this.writable||(r++,this.once("drain",function(){--r||n()}))}else n()}poll(){this.polling=!0,this.doPoll(),this.emitReserved("poll")}onData(t){const n=r=>{if(this.readyState==="opening"&&r.type==="open"&&this.onOpen(),r.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(r)};Z$(t,this.socket.binaryType).forEach(n),this.readyState!=="closed"&&(this.polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this.poll())}doClose(){const t=()=>{this.write([{type:"close"}])};this.readyState==="open"?t():this.once("open",t)}write(t){this.writable=!1,J$(t,n=>{this.doWrite(n,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const t=this.opts.secure?"https":"http",n=this.query||{};return this.opts.timestampRequests!==!1&&(n[this.opts.timestampParam]=ex()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}request(t={}){return Object.assign(t,{xd:this.xd,cookieJar:this.cookieJar},this.opts),new xn(this.uri(),t)}doWrite(t,n){const r=this.request({method:"POST",data:t});r.on("success",n),r.on("error",(o,i)=>{this.onError("xhr post error",o,i)})}doPoll(){const t=this.request();t.on("data",this.onData.bind(this)),t.on("error",(n,r)=>{this.onError("xhr poll error",n,r)}),this.pollXhr=t}}class xn extends je{constructor(t,n){super(),Tu(this,n),this.opts=n,this.method=n.method||"GET",this.uri=t,this.data=n.data!==void 0?n.data:null,this.create()}create(){var t;const n=JS(this.opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this.opts.xd;const r=this.xhr=new nx(n);try{r.open(this.method,this.uri,!0);try{if(this.opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let o in this.opts.extraHeaders)this.opts.extraHeaders.hasOwnProperty(o)&&r.setRequestHeader(o,this.opts.extraHeaders[o])}}catch{}if(this.method==="POST")try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{r.setRequestHeader("Accept","*/*")}catch{}(t=this.opts.cookieJar)===null||t===void 0||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this.opts.withCredentials),this.opts.requestTimeout&&(r.timeout=this.opts.requestTimeout),r.onreadystatechange=()=>{var o;r.readyState===3&&((o=this.opts.cookieJar)===null||o===void 0||o.parseCookies(r)),r.readyState===4&&(r.status===200||r.status===1223?this.onLoad():this.setTimeoutFn(()=>{this.onError(typeof r.status=="number"?r.status:0)},0))},r.send(this.data)}catch(o){this.setTimeoutFn(()=>{this.onError(o)},0);return}typeof document<"u"&&(this.index=xn.requestsCount++,xn.requests[this.index]=this)}onError(t){this.emitReserved("error",t,this.xhr),this.cleanup(!0)}cleanup(t){if(!(typeof this.xhr>"u"||this.xhr===null)){if(this.xhr.onreadystatechange=p_,t)try{this.xhr.abort()}catch{}typeof document<"u"&&delete xn.requests[this.index],this.xhr=null}}onLoad(){const t=this.xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this.cleanup())}abort(){this.cleanup()}}xn.requestsCount=0;xn.requests={};if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",lv);else if(typeof addEventListener=="function"){const e="onpagehide"in jt?"pagehide":"unload";addEventListener(e,lv,!1)}}function lv(){for(let e in xn.requests)xn.requests.hasOwnProperty(e)&&xn.requests[e].abort()}const Nh=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),Sa=jt.WebSocket||jt.MozWebSocket,uv=!0,y_="arraybuffer",cv=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class v_ extends Rh{constructor(t){super(t),this.supportsBinary=!t.forceBase64}get name(){return"websocket"}doOpen(){if(!this.check())return;const t=this.uri(),n=this.opts.protocols,r=cv?{}:JS(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(r.headers=this.opts.extraHeaders);try{this.ws=uv&&!cv?n?new Sa(t,n):new Sa(t):new Sa(t,n,r)}catch(o){return this.emitReserved("error",o)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=t=>this.onClose({description:"websocket connection closed",context:t}),this.ws.onmessage=t=>this.onData(t.data),this.ws.onerror=t=>this.onError("websocket error",t)}write(t){this.writable=!1;for(let n=0;n{const s={};try{uv&&this.ws.send(i)}catch{}o&&Nh(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.close(),this.ws=null)}uri(){const t=this.opts.secure?"wss":"ws",n=this.query||{};return this.opts.timestampRequests&&(n[this.opts.timestampParam]=ex()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}check(){return!!Sa}}class g_ extends Rh{get name(){return"webtransport"}doOpen(){typeof WebTransport=="function"&&(this.transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name]),this.transport.closed.then(()=>{this.onClose()}).catch(t=>{this.onError("webtransport error",t)}),this.transport.ready.then(()=>{this.transport.createBidirectionalStream().then(t=>{const n=t_(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=e_();o.readable.pipeTo(t.writable),this.writer=o.writable.getWriter();const i=()=>{r.read().then(({done:a,value:l})=>{a||(this.onPacket(l),i())}).catch(a=>{})};i();const s={type:"open"};this.query.sid&&(s.data=`{"sid":"${this.query.sid}"}`),this.writer.write(s).then(()=>this.onOpen())})}))}write(t){this.writable=!1;for(let n=0;n{o&&Nh(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this.transport)===null||t===void 0||t.close()}}const w_={websocket:v_,webtransport:g_,polling:m_},S_=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,x_=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Rd(e){if(e.length>2e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let o=S_.exec(e||""),i={},s=14;for(;s--;)i[x_[s]]=o[s]||"";return n!=-1&&r!=-1&&(i.source=t,i.host=i.host.substring(1,i.host.length-1).replace(/;/g,":"),i.authority=i.authority.replace("[","").replace("]","").replace(/;/g,":"),i.ipv6uri=!0),i.pathNames=E_(i,i.path),i.queryKey=k_(i,i.query),i}function E_(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");return(t.slice(0,1)=="/"||t.length===0)&&r.splice(0,1),t.slice(-1)=="/"&&r.splice(r.length-1,1),r}function k_(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,i){o&&(n[o]=i)}),n}let rx=class vo extends je{constructor(t,n={}){super(),this.binaryType=y_,this.writeBuffer=[],t&&typeof t=="object"&&(n=t,t=null),t?(t=Rd(t),n.hostname=t.host,n.secure=t.protocol==="https"||t.protocol==="wss",n.port=t.port,t.query&&(n.query=t.query)):n.host&&(n.hostname=Rd(n.host).host),Tu(this,n),this.secure=n.secure!=null?n.secure:typeof location<"u"&&location.protocol==="https:",n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.hostname=n.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=n.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=n.transports||["polling","websocket","webtransport"],this.writeBuffer=[],this.prevBufferLen=0,this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},n),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=u_(this.opts.query)),this.id=null,this.upgrades=null,this.pingInterval=null,this.pingTimeout=null,this.pingTimeoutTimer=null,typeof addEventListener=="function"&&(this.opts.closeOnBeforeunload&&(this.beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this.beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this.offlineEventListener=()=>{this.onClose("transport close",{description:"network connection lost"})},addEventListener("offline",this.offlineEventListener,!1))),this.open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=XS,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new w_[t](r)}open(){let t;if(this.opts.rememberUpgrade&&vo.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1)t="websocket";else if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}else t=this.transports[0];this.readyState="opening";try{t=this.createTransport(t)}catch{this.transports.shift(),this.open();return}t.open(),this.setTransport(t)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this.onDrain.bind(this)).on("packet",this.onPacket.bind(this)).on("error",this.onError.bind(this)).on("close",n=>this.onClose("transport close",n))}probe(t){let n=this.createTransport(t),r=!1;vo.priorWebsocketSuccess=!1;const o=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",d=>{if(!r)if(d.type==="pong"&&d.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;vo.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(c(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const f=new Error("probe error");f.transport=n.name,this.emitReserved("upgradeError",f)}}))};function i(){r||(r=!0,c(),n.close(),n=null)}const s=d=>{const f=new Error("probe error: "+d);f.transport=n.name,i(),this.emitReserved("upgradeError",f)};function a(){s("transport closed")}function l(){s("socket closed")}function u(d){n&&d.name!==n.name&&i()}const c=()=>{n.removeListener("open",o),n.removeListener("error",s),n.removeListener("close",a),this.off("close",l),this.off("upgrading",u)};n.once("open",o),n.once("error",s),n.once("close",a),this.once("close",l),this.once("upgrading",u),this.upgrades.indexOf("webtransport")!==-1&&t!=="webtransport"?this.setTimeoutFn(()=>{r||n.open()},200):n.open()}onOpen(){if(this.readyState="open",vo.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush(),this.readyState==="open"&&this.opts.upgrade){let t=0;const n=this.upgrades.length;for(;t{this.onClose("ping timeout")},this.pingInterval+this.pingTimeout),this.opts.autoUnref&&this.pingTimeoutTimer.unref()}onDrain(){this.writeBuffer.splice(0,this.prevBufferLen),this.prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this.getWritablePackets();this.transport.send(t),this.prevBufferLen=t.length,this.emitReserved("flush")}}getWritablePackets(){if(!(this.maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r0&&n>this.maxPayload)return this.writeBuffer.slice(0,r);n+=2}return this.writeBuffer}write(t,n,r){return this.sendPacket("message",t,n,r),this}send(t,n,r){return this.sendPacket("message",t,n,r),this}sendPacket(t,n,r,o){if(typeof n=="function"&&(o=n,n=void 0),typeof r=="function"&&(o=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const i={type:t,data:n,options:r};this.emitReserved("packetCreate",i),this.writeBuffer.push(i),o&&this.once("flush",o),this.flush()}close(){const t=()=>{this.onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}onError(t){vo.priorWebsocketSuccess=!1,this.emitReserved("error",t),this.onClose("transport error",t)}onClose(t,n){(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")&&(this.clearTimeoutFn(this.pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),typeof removeEventListener=="function"&&(removeEventListener("beforeunload",this.beforeunloadEventListener,!1),removeEventListener("offline",this.offlineEventListener,!1)),this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this.prevBufferLen=0)}filterUpgrades(t){const n=[];let r=0;const o=t.length;for(;rtypeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,ox=Object.prototype.toString,$_=typeof Blob=="function"||typeof Blob<"u"&&ox.call(Blob)==="[object BlobConstructor]",__=typeof File=="function"||typeof File<"u"&&ox.call(File)==="[object FileConstructor]";function Ah(e){return C_&&(e instanceof ArrayBuffer||O_(e))||$_&&e instanceof Blob||__&&e instanceof File}function Ka(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n=0&&e.num{delete this.acks[t];for(let a=0;a{this.io.clearTimeoutFn(i),n.apply(this,a)};s.withError=!0,this.acks[t]=s}emitWithAck(t,...n){return new Promise((r,o)=>{const i=(s,a)=>s?o(s):r(a);i.withError=!0,n.push(i),this.emit(t,...n)})}_addToQueue(t){let n;typeof t[t.length-1]=="function"&&(n=t.pop());const r={id:this._queueSeq++,tryCount:0,pending:!1,args:t,flags:Object.assign({fromQueue:!0},this.flags)};t.push((o,...i)=>r!==this._queue[0]?void 0:(o!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(o)):(this._queue.shift(),n&&n(null,...i)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type:J.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},t):t})}onerror(t){this.connected||this.emitReserved("connect_error",t)}onclose(t,n){this.connected=!1,delete this.id,this.emitReserved("disconnect",t,n),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(t=>{if(!this.sendBuffer.some(r=>String(r.id)===t)){const r=this.acks[t];delete this.acks[t],r.withError&&r.call(this,new Error("socket has been disconnected"))}})}onpacket(t){if(t.nsp===this.nsp)switch(t.type){case J.CONNECT:t.data&&t.data.sid?this.onconnect(t.data.sid,t.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case J.EVENT:case J.BINARY_EVENT:this.onevent(t);break;case J.ACK:case J.BINARY_ACK:this.onack(t);break;case J.DISCONNECT:this.ondisconnect();break;case J.CONNECT_ERROR:this.destroy();const r=new Error(t.data.message);r.data=t.data.data,this.emitReserved("connect_error",r);break}}onevent(t){const n=t.data||[];t.id!=null&&n.push(this.ack(t.id)),this.connected?this.emitEvent(n):this.receiveBuffer.push(Object.freeze(n))}emitEvent(t){if(this._anyListeners&&this._anyListeners.length){const n=this._anyListeners.slice();for(const r of n)r.apply(this,t)}super.emit.apply(this,t),this._pid&&t.length&&typeof t[t.length-1]=="string"&&(this._lastOffset=t[t.length-1])}ack(t){const n=this;let r=!1;return function(...o){r||(r=!0,n.packet({type:J.ACK,id:t,data:o}))}}onack(t){const n=this.acks[t.id];typeof n=="function"&&(delete this.acks[t.id],n.withError&&t.data.unshift(null),n.apply(this,t.data))}onconnect(t,n){this.id=t,this.recovered=n&&this._pid===n,this._pid=n,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:J.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(t){return this.flags.compress=t,this}get volatile(){return this.flags.volatile=!0,this}timeout(t){return this.flags.timeout=t,this}onAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(t),this}prependAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(t),this}offAny(t){if(!this._anyListeners)return this;if(t){const n=this._anyListeners;for(let r=0;r0&&e.jitter<=1?e.jitter:0,this.attempts=0}fi.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=Math.floor(t*10)&1?e+n:e-n}return Math.min(e,this.max)|0};fi.prototype.reset=function(){this.attempts=0};fi.prototype.setMin=function(e){this.ms=e};fi.prototype.setMax=function(e){this.max=e};fi.prototype.setJitter=function(e){this.jitter=e};class Pd extends je{constructor(t,n){var r;super(),this.nsps={},this.subs=[],t&&typeof t=="object"&&(n=t,t=void 0),n=n||{},n.path=n.path||"/socket.io",this.opts=n,Tu(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new fi({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const o=n.parser||L_;this.encoder=new o.Encoder,this.decoder=new o.Decoder,this._autoConnect=n.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(t){return arguments.length?(this._reconnection=!!t,this):this._reconnection}reconnectionAttempts(t){return t===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=t,this)}reconnectionDelay(t){var n;return t===void 0?this._reconnectionDelay:(this._reconnectionDelay=t,(n=this.backoff)===null||n===void 0||n.setMin(t),this)}randomizationFactor(t){var n;return t===void 0?this._randomizationFactor:(this._randomizationFactor=t,(n=this.backoff)===null||n===void 0||n.setJitter(t),this)}reconnectionDelayMax(t){var n;return t===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=t,(n=this.backoff)===null||n===void 0||n.setMax(t),this)}timeout(t){return arguments.length?(this._timeout=t,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(t){if(~this._readyState.indexOf("open"))return this;this.engine=new rx(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const o=Zt(n,"open",function(){r.onopen(),t&&t()}),i=a=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",a),t?t(a):this.maybeReconnectOnOpen()},s=Zt(n,"error",i);if(this._timeout!==!1){const a=this._timeout,l=this.setTimeoutFn(()=>{o(),i(new Error("timeout")),n.close()},a);this.opts.autoUnref&&l.unref(),this.subs.push(()=>{this.clearTimeoutFn(l)})}return this.subs.push(o),this.subs.push(s),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(Zt(t,"ping",this.onping.bind(this)),Zt(t,"data",this.ondata.bind(this)),Zt(t,"error",this.onerror.bind(this)),Zt(t,"close",this.onclose.bind(this)),Zt(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(t){try{this.decoder.add(t)}catch(n){this.onclose("parse error",n)}}ondecoded(t){Nh(()=>{this.emitReserved("packet",t)},this.setTimeoutFn)}onerror(t){this.emitReserved("error",t)}socket(t,n){let r=this.nsps[t];return r?this._autoConnect&&!r.active&&r.connect():(r=new ix(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;rt()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close"),this.engine&&this.engine.close()}disconnect(){return this._close()}onclose(t,n){this.cleanup(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(o=>{o?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",o)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const Ti={};function Ga(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=b_(e,t.path||"/socket.io"),r=n.source,o=n.id,i=n.path,s=Ti[o]&&i in Ti[o].nsps,a=t.forceNew||t["force new connection"]||t.multiplex===!1||s;let l;return a?l=new Pd(r,t):(Ti[o]||(Ti[o]=new Pd(r,t)),l=Ti[o]),n.query&&!t.query&&(t.query=n.queryKey),l.socket(n.path,t)}Object.assign(Ga,{Manager:Pd,Socket:ix,io:Ga,connect:Ga});const sx=(e,t)=>{if(typeof e=="number")return{full_access_path:t,doc:null,readonly:!1,type:Number.isInteger(e)?"int":"float",value:e};if(typeof e=="boolean")return{full_access_path:t,doc:null,readonly:!1,type:"bool",value:e};if(typeof e=="string")return{full_access_path:t,doc:null,readonly:!1,type:"str",value:e};if(e===null)return{full_access_path:t,doc:null,readonly:!1,type:"None",value:null};throw new Error("Unsupported type for serialization")},M_=(e,t="")=>{const r=e.map((o,i)=>{(typeof o=="number"||typeof o=="boolean"||typeof o=="string"||o===null)&&sx(o,`${t}[${i}]`)});return{full_access_path:t,type:"list",value:r,readonly:!1,doc:null}},B_=(e,t="")=>{const r=Object.entries(e).reduce((o,[i,s])=>{const a=`${t}["${i}"]`;return(typeof s=="number"||typeof s=="boolean"||typeof s=="string"||s===null)&&(o[i]=sx(s,a)),o},{});return{full_access_path:t,type:"dict",value:r,readonly:!1,doc:null}},Ui=window.location.hostname,Wi=window.location.port,D_=`ws://${Ui}:${Wi}/`,Ln=Ga(D_,{path:"/ws/socket.io",transports:["websocket"]}),F_=(e,t)=>{t?Ln.emit("update_value",{access_path:e.full_access_path,value:e},t):Ln.emit("update_value",{access_path:e.full_access_path,value:e})},ax=(e,t=[],n={},r)=>{const o=M_(t),i=B_(n);Ln.emit("trigger_method",{access_path:e,args:o,kwargs:i})},lx=ne.memo(e=>{const{showNotification:t,notifications:n,removeNotificationById:r}=e;return w.jsx(Oh,{className:"navbarOffset toastContainer",position:"top-end",children:n.map(o=>o.levelname==="ERROR"||o.levelname==="CRITICAL"||t&&["WARNING","INFO","DEBUG"].includes(o.levelname)?w.jsxs(ns,{className:o.levelname.toLowerCase()+"Toast",onClose:()=>r(o.id),onClick:()=>r(o.id),onMouseLeave:()=>{o.levelname!=="ERROR"&&r(o.id)},show:!0,autohide:o.levelname==="WARNING"||o.levelname==="INFO"||o.levelname==="DEBUG",delay:o.levelname==="WARNING"||o.levelname==="INFO"||o.levelname==="DEBUG"?2e3:void 0,children:[w.jsxs(ns.Header,{closeButton:!1,className:o.levelname.toLowerCase()+"Toast text-right",children:[w.jsx("strong",{className:"me-auto",children:o.levelname}),w.jsx("small",{children:o.timeStamp})]}),w.jsx(ns.Body,{children:o.message})]},o.id):null)})});lx.displayName="Notifications";const jd=ne.memo(({connectionStatus:e})=>{const[t,n]=h.useState(!0);h.useEffect(()=>{n(!0)},[e]);const r=()=>n(!1),o=()=>{switch(e){case"connecting":return{message:"Connecting...",bg:"info",delay:void 0};case"connected":return{message:"Connected",bg:"success",delay:1e3};case"disconnected":return{message:"Disconnected",bg:"danger",delay:void 0};case"reconnecting":return{message:"Reconnecting...",bg:"info",delay:void 0};default:return{message:"",bg:"info",delay:void 0}}},{message:i,bg:s,delay:a}=o();return w.jsx(Oh,{position:"bottom-center",className:"toastContainer",children:w.jsx(ns,{show:t,onClose:r,delay:a,autohide:a!==void 0,bg:s,children:w.jsxs(ns.Body,{className:"d-flex justify-content-between",children:[i,w.jsx(zs,{variant:"close",size:"sm",onClick:r})]})})})});jd.displayName="ConnectionToast";function ux(e){const t=/\w+|\[\d+\.\d+\]|\[\d+\]|\["[^"]*"\]|\['[^']*'\]/g;return e.match(t)??[]}function z_(e){if(e.startsWith("[")&&e.endsWith("]")&&(e=e.slice(1,-1)),e.startsWith("'")&&e.endsWith("'")||e.startsWith('"')&&e.endsWith('"'))return e.slice(1,-1);const t=parseFloat(e);return isNaN(t)?e:t}function U_(e,t,n){if(t in e)return e[t];if(Array.isArray(e)){if(n&&t===e.length)return e.push(pv()),e[t];throw new Error(`Index out of bounds: ${t}`)}else{if(n)return e[t]=pv(),e[t];throw new Error(`Key not found: ${t}`)}}function dv(e,t,n=!1){const r=z_(t);try{return U_(e,r,n)}catch(o){throw o instanceof RangeError?new Error(`Index '${r}': ${o.message}`):o instanceof Error?new Error(`Key '${r}': ${o.message}`):o}}function W_(e,t,n){const r=ux(t),o=JSON.parse(JSON.stringify(e));let i=o;try{for(let l=0;l{const{docString:t}=e;if(!t)return null;const n=w.jsx(BS,{id:"tooltip",children:t});return w.jsx(H$,{placement:"bottom",overlay:n,children:w.jsx(Lw,{pill:!0,className:"tooltip-trigger",bg:"light",text:"dark",children:"?"})})});ln.displayName="DocStringComponent";function Cn(){const e=h.useRef(0);return h.useEffect(()=>{e.current+=1}),e.current}const cx=ne.memo(e=>{const{value:t,fullAccessPath:n,readOnly:r,docString:o,addNotification:i,changeCallback:s=()=>{},displayName:a,id:l}=e;Cn(),h.useEffect(()=>{i(`${n} changed to ${t}.`)},[e.value]);const u=c=>{s({type:"bool",value:c,full_access_path:n,readonly:r,doc:o})};return w.jsxs("div",{className:"component buttonComponent",id:l,children:[!1,w.jsxs($h,{id:`toggle-check-${l}`,type:"checkbox",variant:t?"success":"secondary",checked:t,value:a,disabled:r,onChange:c=>u(c.currentTarget.checked),children:[a,w.jsx(ln,{docString:o})]})]})});cx.displayName="ButtonComponent";const H_=(e,t,n)=>{const r=t.split("."),o=r[0].length,i=r[1]?r[1].length:0,s=n>o;let a=0;s?a=Math.pow(10,o+1-n):a=Math.pow(10,o-n);const u=(parseFloat(t)+(e==="ArrowUp"?a:-a)).toFixed(i),c=u.split(".")[0].length;return c>o?n+=1:cn>t?{value:e.slice(0,t)+e.slice(n),selectionStart:t}:t>0?{value:e.slice(0,t-1)+e.slice(t),selectionStart:t-1}:{value:e,selectionStart:t},K_=(e,t,n)=>n>t?{value:e.slice(0,t)+e.slice(n),selectionStart:t}:t{let o=t;return e==="."&&t.includes(".")?{value:t,selectionStart:n}:e==="-"?(n===0&&r>n?(o="-"+t.slice(r),n=1):n===0&&!t.startsWith("-")?(o="-"+t,n=1):(n===0||n===1)&&t.startsWith("-")&&(o=t.slice(1),n=0),{value:o,selectionStart:n}):(r>n?o=t.slice(0,n)+e+t.slice(r):o=t.slice(0,n)+e+t.slice(n),{value:o,selectionStart:n+1})},zl=ne.memo(e=>{const{fullAccessPath:t,value:n,readOnly:r,type:o,docString:i,isInstantUpdate:s,unit:a,addNotification:l,changeCallback:u=()=>{},displayName:c,id:d}=e,[f,v]=h.useState(null),[g,S]=h.useState(n.toString());Cn();const k=p=>{const{key:y,target:E}=p,C=E;if(y==="F1"||y==="F5"||y==="F12"||y==="Tab"||y==="ArrowRight"||y==="ArrowLeft")return;p.preventDefault();const{value:x}=C,b=C.selectionEnd??0;let O=C.selectionStart??0,T=x;if(p.ctrlKey&&y==="a"){C.setSelectionRange(0,x.length);return}else if(y>="0"&&y<="9"||y==="-")({value:T,selectionStart:O}=hv(y,x,O,b));else if(y==="."&&(o==="float"||o==="Quantity"))({value:T,selectionStart:O}=hv(y,x,O,b));else if(y==="ArrowUp"||y==="ArrowDown")({value:T,selectionStart:O}=H_(y,x,O));else if(y==="Backspace")({value:T,selectionStart:O}=V_(x,O,b));else if(y==="Delete")({value:T,selectionStart:O}=K_(x,O,b));else if(y==="Enter"&&!s){let $;o==="Quantity"?$={type:"Quantity",value:{magnitude:Number(T),unit:a},full_access_path:t,readonly:r,doc:i}:$={type:o,value:Number(T),full_access_path:t,readonly:r,doc:i},u($);return}else return;if(s){let $;o==="Quantity"?$={type:"Quantity",value:{magnitude:Number(T),unit:a},full_access_path:t,readonly:r,doc:i}:$={type:o,value:Number(T),full_access_path:t,readonly:r,doc:i},u($)}S(T),v(O)},m=()=>{if(!s){let p;o==="Quantity"?p={type:"Quantity",value:{magnitude:Number(g),unit:a},full_access_path:t,readonly:r,doc:i}:p={type:o,value:Number(g),full_access_path:t,readonly:r,doc:i},u(p)}};return h.useEffect(()=>{const p=o==="int"?parseInt(g):parseFloat(g);n!==p&&S(n.toString());let y=`${t} changed to ${e.value}`;a===void 0?y+=".":y+=` ${a}.`,l(y)},[n]),h.useEffect(()=>{const p=document.getElementsByName(d)[0];p&&f!==null&&p.setSelectionRange(f,f)}),w.jsxs("div",{className:"component numberComponent",id:d,children:[!1,w.jsxs(Un,{children:[c&&w.jsxs(Un.Text,{children:[c,w.jsx(ln,{docString:i})]}),w.jsx(ot.Control,{type:"text",value:g,disabled:r,onChange:()=>{},name:d,onKeyDown:k,onBlur:m,className:s&&!r?"instantUpdate":""}),a&&w.jsx(Un.Text,{children:a})]})]})});zl.displayName="NumberComponent";const Ts={black:"#000",white:"#fff"},lo={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},uo={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},co={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},fo={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},po={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},Ri={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},G_={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"};function Rs(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n0?Ve(di,--yt):0,ti--,Ae===10&&(ti=1,Nu--),Ae}function Et(){return Ae=yt2||As(Ae)>3?"":" "}function fT(e,t){for(;--t&&Et()&&!(Ae<48||Ae>102||Ae>57&&Ae<65||Ae>70&&Ae<97););return Vs(e,qa()+(t<6&&En()==32&&Et()==32))}function Id(e){for(;Et();)switch(Ae){case e:return yt;case 34:case 39:e!==34&&e!==39&&Id(Ae);break;case 40:e===41&&Id(e);break;case 92:Et();break}return yt}function dT(e,t){for(;Et()&&e+Ae!==57;)if(e+Ae===84&&En()===47)break;return"/*"+Vs(t,yt-1)+"*"+Ru(e===47?e:Et())}function pT(e){for(;!As(En());)Et();return Vs(e,yt)}function hT(e){return vx(Ya("",null,null,null,[""],e=yx(e),0,[0],e))}function Ya(e,t,n,r,o,i,s,a,l){for(var u=0,c=0,d=s,f=0,v=0,g=0,S=1,k=1,m=1,p=0,y="",E=o,C=i,x=r,b=y;k;)switch(g=p,p=Et()){case 40:if(g!=108&&Ve(b,d-1)==58){Ld(b+=ae(Qa(p),"&","&\f"),"&\f")!=-1&&(m=-1);break}case 34:case 39:case 91:b+=Qa(p);break;case 9:case 10:case 13:case 32:b+=cT(g);break;case 92:b+=fT(qa()-1,7);continue;case 47:switch(En()){case 42:case 47:xa(mT(dT(Et(),qa()),t,n),l);break;default:b+="/"}break;case 123*S:a[u++]=pn(b)*m;case 125*S:case 59:case 0:switch(p){case 0:case 125:k=0;case 59+c:m==-1&&(b=ae(b,/\f/g,"")),v>0&&pn(b)-d&&xa(v>32?yv(b+";",r,n,d-1):yv(ae(b," ","")+";",r,n,d-2),l);break;case 59:b+=";";default:if(xa(x=mv(b,t,n,u,c,o,a,y,E=[],C=[],d),i),p===123)if(c===0)Ya(b,t,x,x,E,i,d,a,C);else switch(f===99&&Ve(b,3)===110?100:f){case 100:case 108:case 109:case 115:Ya(e,x,x,r&&xa(mv(e,x,x,0,0,o,a,y,o,E=[],d),C),o,C,d,a,r?E:C);break;default:Ya(b,x,x,x,[""],C,0,a,C)}}u=c=v=0,S=m=1,y=b="",d=s;break;case 58:d=1+pn(b),v=g;default:if(S<1){if(p==123)--S;else if(p==125&&S++==0&&uT()==125)continue}switch(b+=Ru(p),p*S){case 38:m=c>0?1:(b+="\f",-1);break;case 44:a[u++]=(pn(b)-1)*m,m=1;break;case 64:En()===45&&(b+=Qa(Et())),f=En(),c=d=pn(y=b+=pT(qa())),p++;break;case 45:g===45&&pn(b)==2&&(S=0)}}return i}function mv(e,t,n,r,o,i,s,a,l,u,c){for(var d=o-1,f=o===0?i:[""],v=Mh(f),g=0,S=0,k=0;g0?f[m]+" "+p:ae(p,/&\f/g,f[m])))&&(l[k++]=y);return Au(e,t,n,o===0?Lh:a,l,u,c)}function mT(e,t,n){return Au(e,t,n,dx,Ru(lT()),Ns(e,2,-2),0)}function yv(e,t,n,r){return Au(e,t,n,Ih,Ns(e,0,r),Ns(e,r+1,-1),r)}function Fo(e,t){for(var n="",r=Mh(e),o=0;o6)switch(Ve(e,t+1)){case 109:if(Ve(e,t+4)!==45)break;case 102:return ae(e,/(.+:)(.+)-([^]+)/,"$1"+se+"$2-$3$1"+Ul+(Ve(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~Ld(e,"stretch")?gx(ae(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Ve(e,t+1)!==115)break;case 6444:switch(Ve(e,pn(e)-3-(~Ld(e,"!important")&&10))){case 107:return ae(e,":",":"+se)+e;case 101:return ae(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+se+(Ve(e,14)===45?"inline-":"")+"box$3$1"+se+"$2$3$1"+Je+"$2box$3")+e}break;case 5936:switch(Ve(e,t+11)){case 114:return se+e+Je+ae(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return se+e+Je+ae(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return se+e+Je+ae(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return se+e+Je+e+e}return e}var bT=function(t,n,r,o){if(t.length>-1&&!t.return)switch(t.type){case Ih:t.return=gx(t.value,t.length);break;case px:return Fo([Ni(t,{value:ae(t.value,"@","@"+se)})],o);case Lh:if(t.length)return aT(t.props,function(i){switch(sT(i,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Fo([Ni(t,{props:[ae(i,/:(read-\w+)/,":"+Ul+"$1")]})],o);case"::placeholder":return Fo([Ni(t,{props:[ae(i,/:(plac\w+)/,":"+se+"input-$1")]}),Ni(t,{props:[ae(i,/:(plac\w+)/,":"+Ul+"$1")]}),Ni(t,{props:[ae(i,/:(plac\w+)/,Je+"input-$1")]})],o)}return""})}},CT=[bT],wx=function(t){var n=t.key;if(n==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(S){var k=S.getAttribute("data-emotion");k.indexOf(" ")!==-1&&(document.head.appendChild(S),S.setAttribute("data-s",""))})}var o=t.stylisPlugins||CT,i={},s,a=[];s=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(S){for(var k=S.getAttribute("data-emotion").split(" "),m=1;m - +